|
PM on Modwiggler has developed V1.6 and released the code on Modwiggler. I have been communicating via email with individuals who have V1 and am providing additional documentation here in one place. Since I do not have a V1, and no one has yet made these modifications, I have marked these as unverified.
Software Enhancements (from PM's V1.6 release notes)
Release Notes
Version 2.66
June 2022
Functional changes
This release brings the V2 MARF up to feature parity with Buchla's original unit and duplicates the 200 series module's behavior to the best of our knowledge. It includes a large number of functional improvements over the earlier firmware.
1. Programmed pulses fire correctly in all modes, whenever a step changes.
2. Reference signal present in all modes, whenever a step changes.
3. Steps set to sloped mode will now slew correctly in all modes including advance, strobe and continuous address.
4. Quantize mode works correctly on full range steps.
5. Loop behavior is correct. Loops now search backwards from a "last" step to the closest "first" step. Multiple loops are now possible.
6. The "level 2" programming is organized into a single bank. It is no longer different between AFG1 and AFG2.
7. External inputs no longer have audible slewing.
8. Glitches in voltage output fixed.
9. Step times match panel legend exactly.
Internal performance, operational and code health improvements
This release required significant refactoring to almost 100% of the codebase, including all of the core function generation logic, all of the interface code, and much of the internal scheduling logic. This release is able to run at 8x the timing resolution of the previous version.
1. Using a much better filtering algorithm consistently on all adc inputs. Fixes slewing on large jumps and jitter on steady state signals.
2. Output sample rate increased from 4kHz to 32kHz.
3. Voltage quantization and timing computations use higher precision floating point calculations.
4. Numerous bugs with start/stop and sustain/enable modes ironed out.
5. Slow code moved out of IRQs into main loop and scheduling tightened up.
6. Inlining small methods and compiling with speed optimizations.
7. Reduced function call overhead in peripheral drivers.
8. Improved display update system LEDs better when the clock is at high speeds.
9. Applied consistent code style guide including capitilization, indentation.
10. Improved naming conventions using Buchla standard terminology.
11. Double buffering scheme to reduce glitches at stage transitions
Manual Addendum
Calibration Procedure
1. Hold Stage Address 1 Advance down during start up.
2. Leds start cycling.
3. Turn all pots to maximum, and apply 10v to all 4 external inputs.
4. Select pulse 2 up if you need to swap the pulse LEDs. Led will move to pulse 2.
5. Select pulse 1 up to swap it back to normal.
6. Press Stage Address 2 Advance down to save calibration.
7. It will ERASE the entire eprom, including saved programs.
AFG Section Shift (unexpanded units only)
1. AFGs 1 and 2 both access the same memory unless you use section shift.
2. Press Stage Address Display 1 + Stage No Right to move AFG1 to steps [16-32].
3. Press Stage Address Display 1 + Stage No Left to move AFG1 back to steps [1-16].
3. Press Stage Address Display 2 + Stage No Right to move AFG2 to steps [16-32].
4. Press Stage Address Display 2 + Stage No Left to move AFG2 back to steps [1-16].
Save Program
1. This version supports saving and loading 16 programs (even with expander).
2. Slider data is always saved along with the program.
3. Press the Clear switch _down_ briefly to enter save mode.
4. The pulse LEDs will toggle to indicate that you are in save mode.
5. To abort saving, press one of the Display switches.
6. Use the Stage No switch to select one of the 16 memory locations.
7. Press Clear switch _down_ again briefly to save the program.
8. LEDs with flash downwards when the program is saved.
9. Note that the MARF does not stop running while saving a program.
Load Program
1. Press the Clear switch _up_ briefly to enter load mode.
2. The pulse LEDs will toggle to indicate that you are in load mode.
3. To abort loading, press one of the Display switches.
4. Use the Stage No switch to select one of the 16 memory locations.
5. Press Clear switch _up_ again briefly to load the program.
6. LEDs will flash upwards when the program is loaded.
7. Note that the MARF does not stop running when loading a program.
8. Once the program is loaded, all sliders will be "pinned" at their saved value.
9. To restore slider activity, the slider must be moved through the saved value.
Pulse Tricks
1. A simultaneous pulse to start and stop is the same as the manual advance switch.
2. A simultaneous pulse to strobe and start will correctly start on the strobed step.
The main drawback with the V1 hardware is the strobe inputs are polled in the switch serial loop. As such, narrow pulses will likely be missed as they will not occur during the active polling window.
V1.6 hex code for stock hardware ZIP file
Improved Strobe Functionality
The code has a compile option to move the strobe inputs to two "unused" pins which allow interrupt instead of polled operation. PM desrcribes the following mod with this caveat:
This mod should probably be reviewed by someone who knows more about electrical circuits than me, but on my marf, it works.
Here is my analysis of his modifications.
PM describes the modification as:
I found that PB2 and PB14 are not used on the stm32f405: PB2 is connected to ground via 10k and PB14 is defined as “EXPANDER_PIN” in the V1 code, but seems like it’s never used. So I used PB14 as interrupt for strobe B. I changed R113 and R115 to 49K9 and connected it with a cable to pin 10 of IC 52 which then goes from pin 14 to PB14.
The Expander Pin is grounded when the expander is installed so this this pin on the expander must be cut so as to not interfere with this modification. It is pin 1 of IDC16, the header to connect to the Master. I do not know how difficult it is to cut this pin free. One could always heat up the pad and simply pull the pin from the header. Changing R113 and R115 increases the input impedance from 10K to 100K. The 5V zener still provides protection as this signal is on the 5V side of IC52. It is still connected to the switch serial polled input which is fine. This mod is fine as described.
The other one, for strobe A involves cutting some traces: For Strobe A, I changed R72 to 10K, cut the trace between R74 and Z4, cut the ground trace between Z5 and R74. Removed Z5 and R74. Put a jumper cable between Z5 ground side to R75 or Z4 ground side (facing the bottom of the PCB). Put a SD103B in place of R74 with cathode to the right. From the C7 3.3V side (just above IC3) I put a jumper cable to the cathode of the SD103B. And a cable from R72 left side to STM32F405 PB2 which is accessible via the little via just under the STM32F405.
This mod is a bit complex and involves cutting traces. I dislike cutting traces and propose a simpler modification. The issue is this strobe is now on a 3.3V input to the processor. Change Z5 to a 3.3V zener to provide over voltage protection to the processor. PB2 is connected to ground through R145, a 10K. This is unfortunate as I would want to increase this value, but it is on the front of the PCB and changing it is difficult. Leaving it at 10K will lower our input impedance for Strobe1
We can remove R74 as it will be in parallel with R145. Strobe2 is 100K with a threshold at 7V. If we make the threshold for Strobe1 also 7V, then we need to know the threshold of the STM32F405. I believe it is 0.7(Vcc) or 2.31V. With the same 7V threshold R72 should be 20K. This makes Strobe1 input impedance 30K, less than Strobe2. It is still connected to the switch serial polled input and 3.3V is 200 mV below the guaranteed Vih specification but should be fine at room temperature.
Other alternatives would be to raise the threshold voltage, or lower the input impedance of Strobe2 to match at the same threshold (R113=R115=15K).
The via is likely covered a bit by solder mask so will need to have this scraped clean to solder to. Here is a board image for the strobe resistors. unverified
Here is a board image for PB2 and PB14. These two points for each strobe need to be wired together. unverified
V1.6 hex code for modified strobe hardware ZIP file
Start / Stop Impedance and Levels
The software has been enhanced to enable external clocking by simultaneous driving both the Start and Stop input jacks. The Start and Stop circuitry candidly is a bit of a mess. It is two circuits that have been kludged together and are somewhat incompatible. What is interesting is there are two processor inputs for Start as if the thought was to detect the trigger portion and the gate portion of a Buchla combination trigger/gate. However, this feature isn't used. This means two processor inputs could be freed up for the Strobe mods but would require additional code modification.
I worked with an individual and verified that disabling the Start trigger circuit did not affect operation, so this signal could be freed up. I also worked with him to increase the input impedance and also allow a 5V threshold for triggering from Eurorack modules. While we were able to verify an increased input impedance, the voltage threshold was not accurate and by email could not troubleshoot the issue, so paused the investigation. I have another opportunity locally that may pick up the investigation when time permits.