[sdiy] continuous tuning of analog oscillators
brianw at audiobanshee.com
Sat Jul 13 04:36:58 CEST 2019
Besides PWM, you don’t want Pitch Bend? what about Vibrato?
When would the frequency be adjusted? Would that happen while each note is audible? … or would the microprocessor leave the frequency as it started and gather information that could be used to make the next note perfect pitch?
You do not need 16 microprocessors. All you really need is one microprocessor with 16 inputs. One of the ARM Cortex-M4 processors that I’m designing with has 8 32-bit timers that can be divided into 16 16-bit timers. I don’t recall whether this particular chip has enough pins to feed each 16-bit timer individually, though.
The slickest solution would be an FPGA with the equivalent of 16 timers inside, and dedicated pins for each voice. Of course, FPGA design is more daunting than embedded microprocessor firmware development. But you wouldn’t have to worry about whether the chip manufacturer allows external capture/compare for all timers.
You talk about avoiding stepped intervals, but if the reference is digital then you’ll be correcting the frequency of an analog oscillator to match a digital oscillator. Although you can achieve rather small steps in a digital system, there are two things to consider: First, lower frequencies will have smaller steps in pitch than higher frequencies. Second, in the end, you’ll be forcing the continuous analog frequency of the oscillators to match the stepped digital clock periods. In other words, the purity of the continuous analog frequency cannot be maintained if you correct the frequency based on a digital reference.
I’m actually wondering what it would sound like if each note started off out of tune, but then drifted into tune over time. Keep in mind that you can’t know the frequency of an analog oscillator instantaneously. At least one full period of the waveform must occur before the first estimate of frequency can be made, and each additional period adds to the accuracy of the frequency estimation while also adding to the latency of the correction. You could certainly keep a log of the necessary corrections so that new notes start out on pitch, but that might sound really strange during the “tuning” phase of the performance.
What you call archaic makes more sense to me. Going back to the Prophet-5 from the seventies, these 8-bit microprocessors used a digital timer to tune the oscillators, but they did all of this while muting the oscillators so that we poor humans don’t have to listen to the tuning process. Once the correction data is gathered, the system stops tuning and just works with what it has. Sure, temperature changes after the tuning phase will allow the frequencies to drift, but usually there’s an option to manually trigger a new tune-up.
On Jul 10, 2019, at 2:02 PM, ulfur hansson <ulfurh at gmail.com> wrote:
> hello list,
> I have a really nice synth voice up and running on my bench, and have always dreamt of making my own poly.
> all parameters are voltage controlled, but the tuning is... well... not perfect.
> currently I'm quite happy to omit oscillator FM, so in theory the oscillators would not "need" any modulation other than PWM.
> autotune feels a bit archaic at this point, so i'm wondering - a tiny microcontroller listening for zero crossings should be able to adjust the frequency of each oscillator for near perfect tuning, no?
> so far, i sadly haven't developed the skills required for digital solutions - but I wonder how crazy it would really be to implement something like this - can anyone think of a project / reading material that could help guide the way towards creating a tiny (preferably REALLY small) ADC/DAC listener circuit that could correct the resulting frequency of a sawtooth oscillator?
> it would be amazing to put 8 of these voices together with perfect tuning without any divide down or stepped interval solutions...... but then again it would also mean i'd need at least 16 micros to listen to all the oscillators at once!!
> any thoughts would be greatly appreciated, or even better yet - if someone would be interested in a collaborative effort, i'd be happy to send hand soldered smd prototypes between continents if necessary!
> many thanks,
More information about the Synth-diy