Forgotten component

What a ‘nana! I spent ages trying to figure out why the piezo sounder was silent. Testing with the oscilloscope proved that the Teensy was outputting a square wave on the appropriate pin, and that it was carried via a resistor to the base of the 2N3904 transistor. There was nothing to be seen at the collector — Maybe the transistor was dud? Changed it and no difference…

I ‘scoped the collector again at higher temporal resolution and spotted what at first appeared to be noise. Then the penny dropped! The piezo disc behaves like a capacitor and that’s why the ‘reset’ resistor is required to discharge, or reset it between each pulse.

I temporarily added a 215Ω resistor (chosen to limit the current draw) across the piezo and tested it in the living room. And it’s now loud enough to make us all jump!!

Reset resistor