This is the last part (for now) in a series of posts describing how I’ve approached building a “universal synthesizer panel” to house a range of microcontroller synthesis projects.
- In the first part, I detailed the general idea and overall design of the panel.
- In part 2 I built the IO panel.
- In part 3 I built the panel IO board.
- In part 4 I built a microcontroller board for an Arduino Nano.
- In part 5 I walked through the final assembly and test code for the whole thing.
- In this part I will port the Arduino Multi-pot Mozzi FM Synthesis to the panel and show it in action.
Warning! I strongly recommend using old or second hand equipment for your experiments. I am not responsible for any damage to expensive instruments!
The Code
This uses the Arduino Multi-pot Mozzi FM Synthesis code which has six potentiometers, MIDI IN and audio out. It won’t be using the I2C display or the switches for now.
The potentiometers have the following functions:
- Top left: Waveform – choosing between sine, triangle, saw, square.
- Top right: Modulation Ratio – zero being no modulation, then applying increasingly large ratios.
- Mid left: Modulation Rate – zero means a steady modulation applied, turning starts with a low-frequency modulation, increasing as the pot turns.
- Mid right: Modulation Intensity – adjusts the amount of modulation applied.
- Bottom left: ADSR Attack time.
- Bottom right: ADSR Delay time.
In order to take the code and use it with the synth panel, the pin definitions for the pots need to be updated as follows:
#define WAVT_PIN 0 // Wavetable
#define INTS_PIN 3 // FM intensity
#define RATE_PIN 2 // Modulation Rate
#define MODR_PIN 1 // Modulation Ratio
#define AD_A_PIN 6 // ADSR Attack
#define AD_D_PIN 7 // ADSR Delay
Apart from this, it can be used “as is”.
Find the original code on GitHub here.
Closing Thoughts
I’m really pleased with how this has turned out. Now to get it mounted properly, add the knobs and start to programme some proper synth projects. I want to take some of the code that exists online and port it over to my panel. I also plan to build some different microcontroller boards for it.
It would also be really good to get a “CD rack” version of my Multi-Mode MIDI Step Sequencer so watch this space.
Kevin