Variable PWM from a comparator
Attibution: DivKid, Luke TeafordA comparator will only go high when a voltage crosses the threshold you set
A comparator outputs a binary (high or low) signal, indistinguishable from a pulse or gate stream. If you feed the comparator with a regular triangle, saw or ramp wave, you will get a regular pulse wave out of the comparator, and the width of the pulses will depend on the voltage the comparator is comparing the signal to.
Example:
- patch a saw or ramp wave from an oscillator to the input on a comparator
- patch the output of the comparator to where you can hear it
- adjust the value of the comparator with the offset knob and listen to the pulse width modulate
- instead of manually adjusting the offset knob, patch a triangle LFO to the second input on the comparator for automated PWM
Note: you can also use a mixer to combine your saw or ramp wave with an LFO signal, patch the result to the input of the comparator, and leave the comparator’s offset at zero to a somewhat similar effect.
This same general strategy can be used to add variable per-step gate length to any step sequencer. Use a step sequence to modulate the comparator, and clock the step sequence with the same saw wave you’re sending the comparator.
If you have access to a window comparator (e.g., Joranalogue Compare 2) and pass it a triangle wave as your input, by adjusting or modulating the parameters on the window comparator, you can create PWM with pairs of pulses that separate and combine, resulting in both PWM-style timbres and octave shifts.
Video example (begins at 3:19):