Open-source drone generator inspired by the Drone & Drama project (Barry Joseph Cullen). Three bandlimited-saw oscillators through a state-variable filter, waveshaper, and stereo reverb. Built for Teensy 4.0 with a PCM5102 DAC on I2S2. Optional OLED scope (Adafruit SH110x + GFX; I2C).
- Board: Teensy 4.0
- Audio: PCM5102 DAC on I2S2 (Teensy’s second I2S port; level via mixer gains, no codec control)
- Optional: SH1106 128×64 I2C OLED for scope display
- PCM5102 (I2S2): Teensy → DAC: 2 = DIN, 3 = LRCLK (LRC/WS), 4 = BCLK; 33 = MCLK (optional on some breakouts). GND and 3.3 V in common.
- SH1106 (I2C): Teensy 18 = SDA, 19 = SCL; 3.3 V and GND. External 2.2–4.7 kΩ pull-ups to 3.3 V on SDA/SCL are recommended if the display does not respond.
pio run -e teensy40
pio run -e teensy40 -t uploadSerial monitor (e.g. filter frequency debug):
pio device monitor -b 115200- Display: SH1106 shows the live output waveform (post-reverb, to I2S) as a scope trace. I2C address is set in
src/display.hasDisplay::kI2CAddr(default 0x3C; try 0x3D if the display stays off). - Knobs: A0/A1 → oscillator 1 frequency and amplitude; A2/A3 → oscillator 2; A6/A7 → oscillator 3; A8 → filter frequency (exp-scaled); A9 → reverb room size (0–1). When room size is 0, the reverb is bypassed and the dry signal is heard.
- Display: Confirm SDA=18, SCL=19, 3.3 V and GND. Add 2.2–4.7 kΩ pull-ups on SDA and SCL to 3.3 V if missing. Try
DISPLAY_I2C_ADDR0x3D insrc/main.cppif 0x3C fails. This project uses the Adafruit SH110x library (with slower I2C clock) for better Teensy 4.0 I2C compatibility; if U8g2 did not work for you, the Adafruit stack may resolve the issue. - DAC: Confirm Teensy pins 2 (DIN), 3 (LRCLK), 4 (BCLK) to PCM5102; GND and 3.3 V in common. Some PCM5102 boards need MCLK on pin 33; others work from BCLK only.
platformio.ini— Teensy 4.0 env, Adafruit SH110x + GFX (display).src/main.cpp— Audio graph, knobs; delegates display and scope toDisplay.src/display.h,src/display.cpp— Display class: SH1106 init, splash, scope ring buffer and throttled scope drawing.- Legacy sketch:
D_D_teensy_v6_bc.ino(reference only; firmware is insrc/main.cpp).