# antilog (1)

Thu Aug 10 20:10:58 CEST 2000

>
>
> > I've been interested for a while in the possibility of making an
> exponential
> > convertor using a micro, and multiplexing it, so that all the problems of
> stability in
> > the expo cells would be a thing of the past.
> > But, i'm not a programmer.
>
> Im hopeing to use this for converting PITCHwheel information via midi.
> But have plans for a wavetables VCO using a phase accumulator oscillator
> and an AD and doing the log function in the micro.
>
> > I know 12 bits would be enough, though 16 bit serial D to A convertors are
> > cheapest.
> > (Though not guaranteed for DC, I have never had trouble with them).
> >
>
> 12bits for AD would be more than enough.. 4bits at the top for the octave
> (16 octaves) and 8 bits for spread over 1v for resolution of octave, which
> should be fine.

About 1.5 year ago I made plans for such a 100% digital phase
accumulator VCO (I think I even posted smthing about it to
this list)...
After several weeks of simulation, I came to the conclusion
that the best approach was to use a LUT and a fixed sampling
rate, and to consider expo conv. and VCO as 1 single entity.

Actually, I used the "classical" Matthews algorithm (as used
in MusicV music software), where the output frequency of
the osc is given by :

F (in Hz) = sampling rate / samples per period

and

Samples per period = WFT length / increment (in samples)

>From the above, we have :

F (in Hz) = sampling rate * increment / WFT length

and

Increment (in samples) - WFT length * F (in Hz) / sampling rate

For instance :

for a sampling rate of 48 KHz and a 256 words LUT, the increment
(in samples) for a 440 Hz freq is :

Inc = 256 * 440 / 48000 = 2.3466666667

The expo converter itself is just a LUT which gives the adequate
increment value for each successive output value of the digital osc,
according to the CV in converted to 16 bits.

I also found out that 16 bits were necessary for an acceptable frequency
resolution.

And depending on the length of the WFT you use,
linear interpolation between increment values is a great plus (typically
for WFT under 1024 samples).

Hope that helps...

jbv