Part 76

Digital Oscillators & Lookup Tables

Every digital synthesizer plays sound the same way: reading stored waveform data from memory, one sample at a time. The speed of reading determines the pitch.

From Voltage to Numbers

So far, every oscillator we've used has computed its output in real time, whether a sine wave, sawtooth, or the complex shapes from wavefolding. This works beautifully in the analog world, where circuits naturally produce continuous waveforms. But digital synthesizers work differently. Instead of computing a waveform continuously, they store one complete cycle of the waveform in memory (a lookup table) and read through it repeatedly.

The Phasor

The heart of a digital oscillator is the phasor: a counter that steps through the table from start to finish, then wraps back to the beginning. How fast the phasor advances determines the pitch. Double the speed, and you double the frequency, the same relationship between speed and pitch that governs a tape machine or turntable. At sub-audio rates, you can watch the phasor crawl through the table. Speed it up past 20 Hz and it becomes a tone.

One Table, Many Timbres

The shape stored in the table determines the timbre. A sine table produces a pure tone. A sawtooth table produces a bright, buzzy sound rich in harmonics. A square table gives a hollow, clarinet-like quality with only odd harmonics. Same phasor, same reading mechanism; different table data, different sound. This is the foundation of wavetable synthesis, which we'll explore next.

Try it: start with "Sine Table" at a low frequency and watch the read position sweep through the waveform. Then switch to "Sawtooth Table" and hear the difference in brightness.

Preset
Table
Pitch
The dot traces the read position through the stored waveform

References