[sdiy] DIY polyphony handler
Brian Willoughby
brianw at audiobanshee.com
Wed Jan 23 08:42:49 CET 2019
On Jan 22, 2019, at 11:05 AM, ulfur hansson <ulfurh at gmail.com> wrote:
> i have a few diy voice “cards” (meaning various prototypes ziptied together) of my own design laying around, and have been thinking it’d be neat to build a 6-voice midi CV/gate handler for polyphonic playing.
Shouldn’t be too hard. They were able to do this in the eighties with 8-bit processors. You might be using a 32-bit ARM that runs hundreds of times faster...
> all parameters are currently voltage controlled, so building a rudimentary knob control panel is easy - however, when it comes to choosing DAC’s and microcontroller platforms, i’m a little lost!
First of all, don’t select an audio DAC with 24 bits. Those all are sigma-delta and have latency, where the value you give it doesn’t appear on the output until hundreds of samples later. The largest you want is a 16-bit DAC. Look for ladder or hybrid converters. You can get by with less than 16, but you’ll want more than 8 bits. There might even be some DAC chips with more than 16 bits, but just make sure that there isn’t any digital filtering or synchronous clocks. You’ll want to be able to perform conversions without being tied to a fixed sample rate. There are parallel and serial versions - but you might be forced to use the one that will interface with your processor.
For every parameter, you’ll need 6 CV channels. The way this has been done for decades is to use an analog mux where each output is a sample and hold. Then you can buy one DAC, interface it to your processor once, and use the mux to select which CV you’re changing. The Prophet VS has 60 channels of CV, using two 30-channel mux chips. You can get by with 16-channel mux chips ganged together - no need to put them in series, because you can turn them off, allowing parallel combinations.
You might think that you could send the same CV to every voice for a given parameter, but if you have, e.g., keyboard tracking for the VCF then you’ll need a different CV for each voice. In fact, every parameter should be able to be varied across the voices, for many reasons related to interesting patch design.
> does anyone have experience building a basic setup like this? i’m thinking up to 8x round robin pitch CV’s and Gates.
Look at the schematics for just about any analog synth with presets since the Prophet 5. You’ll see all of the basics in the service manual.
As for round robin, look at the Xpander owners manual for a description of the many other voice allocation options. If you implement them all, then you can pick the one that’s right for a given performance.
> (bonus feature; DIY autotune anyone?)
All you need is an input to the processor. You might need some wave shaping to make the VCO into a square wave - or you could just hook up the square wave output to the processor. In the latter case, you’ll just need to scale down the +/-10V square wave to +5/0V digital levels plus insert series resistance to protect the processor inputs.
Some processors even have Timer peripherals that can count based on an external pin. You’ll need a mux unless your processor has 6 or 12 or 18 Timers with dedicated pins. It’s possible even with a single Timer and a single input pin. Just dial in the mux for each voice VCO, one at a time, and measure the frequency for a range of CV values. You’re measuring the period of the waveform, but you can calculate the target period in advance, based on the desired frequency. Once your processor measures how far off the VCO is in several octaves, it should be possible to calculate a correction that is specific to each VCO. Whether you measure two points, three, or more is up to you. Usually, linear is enough (two points), but sometimes the error can change near the extremes, and perhaps you could even compensate for that with enough math.
Brian Willoughby
Sound Consulting
More information about the Synth-diy
mailing list