I built a synthesizer.
Three chips, eight voices, and a lot of dead ends.

A polyphonic hardware synthesizer — designed, wired, and coded from scratch. Custom PCB, a full effects chain, Bluetooth MIDI, a web control interface, and a password-protected volume limiter built for grandchildren whose parents turned out to be the main users.

Synthesis engine
STM32F411 + PCM5102A
Control & MIDI
2× ESP32
Voices
8 polyphonic, adaptive scaling
Oscillators per voice
2 main + sub + noise + 2 LFO
Effects
Chorus, delay, ring mod
Status
Playable, in active development

This isn't a tutorial. It's a build log — the real decisions, the dead ends, the bugs that took weeks to find, and how AI-assisted development changed the way I work through problems. The goal is to show that a project that looks impossibly complicated can be broken into pieces small enough to actually tackle.

The project is unfinished. The site reflects that.

What I built — and where it stands

The complete Poly-Synth system

📷  The complete system — synthesizer unit with web control interface and BLE MIDI keyboard

The project started as an analog design using the AD9833 waveform generator, then pivoted to a fully digital architecture when the limitations of single-channel synthesis became clear. The current design runs on three microcontrollers: an STM32F411 as the synthesis engine driving a PCM5102A DAC over I2S, and two ESP32 modules handling control, connectivity, and Bluetooth MIDI.

Voice engine
Polyphonic voices8, with envelope-based voice scaling
Main oscillators per voice2 (sine, sawtooth, square, triangle), alias-free band-limited wavetables
Osc2Independent level & detune (0–100 cents)
Sub oscillatorSine or square, −1 or −2 octaves
Noise oscillatorWhite noise, adjustable level
Ring modulatorContinuously blendable, additive to full ring mod
PortamentoLegato glide, 0–500ms
Pitch bendAdjustable range
Volume envelopeAnalog-style exponential ADSR per voice, times 1ms–3s
FilterGlobal resonant 2-pole (12 dB/oct) low-pass, with ADSR
LFOs2 independent (0.1–20Hz), 5 waveforms each
LFO targetsPitch, filter cutoff, amplitude, Osc2 detune
ChorusModulated stereo chorus
DelayStereo, 10–400ms, 4 presets, ping-pong mode
StereoVoices panned by pitch, stereo effects
Voice stealingClick-free — takes the quietest releasing voice, else the oldest note
Factory presets16 (Fat Bass, TB-303 Acid, Bell Chime, Piano, and more), each with its own level
User presets12 slots, stored in non-volatile memory
Web interface4 tabs: Sound, Modulation, FX, Presets; always shows the synth's current settings
BLE MIDIAuto-discovery, preferred device priority
MIDI PlayLaptop app plays MIDI files over USB, with sustain pedal
Volume ceilingWeb UI, passcode protected (enforced by the controller); MIDI CC7 respects it
Build status
Voice engineWorking
MIDI DIN input (STM32)Wired — disabled; its UART pin now serves the web ESP32
BLE MIDI (ESP32 #2 → STM32)Working
Web control interfaceWorking
PCBDone
3D printed housingDone
MIDI Play (laptop → USB)Working (proof of concept)
Auto music generationIn design
3D housing files
Firmware tools
Arduino IDE

Chapter by chapter

Comments on this chapter

Questions, ideas or your own build stories are welcome. Commenting needs a free GitHub account; comments also appear in the project's GitHub Discussions.

What actually helped

Not a comprehensive list. These are the tools and references I personally used — with straightforward notes on where they help and where they don't.

Design & development tools
EasyEDA
Used for all schematics and PCB layout. Browser-based, no installation required, handles the full workflow from schematic to Gerber export. Accessible without a professional EDA background.
Arduino IDE
Used for all firmware across all three MCUs — ESP32 and STM32 targets with the appropriate board packages. One IDE for the whole project kept things consistent.
Claude (Anthropic)
Used for the majority of code generation, debugging, and working through architectural decisions. AI assistance was central to the project — a way to move through problems that would otherwise have taken much longer. The quality of what you get back depends heavily on how clearly you describe what you're trying to do and what's going wrong.
Reference documentation
STM32F411 Reference Manual
Dense, but the authoritative source on the chip's peripherals. Search for the specific section you need rather than reading linearly.
Espressif ESP32 Technical Reference
Better organized than expected. The I2S, BLE, and memory management sections were all useful at different points in this project.
PCM5102A Datasheet
Essential for understanding I2S configuration and the DAC's filter modes. Read alongside an I2S tutorial if you're new to the protocol.

The current frontier

In progress

Refining the engine

Before adding anything new, I went back through the existing firmware to fix the remaining bugs and get more out of the current hardware. The bug-fixing round is done (the story is in the build log, chapter 08), and the processor time it freed went into sound: stereo output, a real modulated chorus, a ping-pong delay, a resonant filter, alias-free oscillators, analog-style envelopes and rebuilt presets. The synth can now also play MIDI files from a laptop (MIDI Play), and a piano preset tuned by ear makes recorded piano performances sound remarkably good. Next comes hardware: the first candidate is bringing the 5-pin DIN MIDI input back to life.

Planned

Automatic music generation

The longer-term goal is making the synth generate its own music — algorithmically, possibly driven by external inputs such as sensors. Nothing is built yet. The idea for a starting point is a simple melody generator (a Markov chain that keeps to a chosen scale) running on the web controller ESP32 and sending notes to the STM32 the same way the keyboard does.

MIDI Play has already proved the other half of the path: notes coming from outside — today from a MIDI file on a laptop — reach the synth with millisecond timing. The same USB route could one day carry music generated by AI on the laptop or in the cloud, while the STM32 stays what it is now: a pure synthesis engine.

Under consideration

Instrument preset emulation

A longer-term question: can the synth emulate real musical instruments convincingly? Realistic instrument emulation — through physical modeling or detailed wavetables — is computationally heavier than the current subtractive synthesis engine. The STM32F411 may not have enough headroom for this without an upgrade to a more powerful MCU. It's an open question worth exploring, not a committed roadmap item.

This site updates as the project evolves. The build log is written as things happen — including the parts that don't work yet.

If you're working on something similar, have a question, or want to compare notes, join the conversation in the project's GitHub Discussions (a free GitHub account is needed to post). Found a bug in the firmware? Please report it as an issue.