How to Follow a Drummer
A developer built a system where a live drummer controls tempo instead of following a machine clock. The post covers the core technical challenges: why kick-drum triggers fail as clocks, why clock multiplication requires a tempo model, and how a software phase-locked loop with a beat-aware front end solves the problem. Key insights include distinguishing feel (small deviations) from real tempo drift, the critical 'coasting' behavior that keeps the system running during fills or confidence dips, and scheduling notes against a forecast rather than reacting to hits. The result is DrumMate, an Android app where a generated band follows a drummer's tempo and dynamics over USB MIDI.