Electronic – (ab)use a transistor as an ESD protection diode


The MIDI specification suggests a fast switching diode to protect the optocoupler's LED against ESD that could exceed its reverse voltage:

MIDI input, diode highlighted

But this is the only diode used; I could simplify the BOM if I could replace it with some component already used elsewhere in the circuit.
So why not use a PN junction of a general-purpose transistor?

Compared to the 1N4148, the 2N3904 has smaller reverse breakdown voltages, but this would not matter in this application because the LED clamps such voltages.
Other parameters like capacitance or maximum current are comparable.
So this looks as if the transistor would work, wouldn't it?

BJT as diode - choices

And which junction should be used, base/emitter, base/collector, or both?
And what to do with the unused junction?

Best Answer

Yes, there is no problem. Just connect collector to base and use that as the diode. No abuse involved. A diode, even an LL4148, is a bit more rugged than a diode-connected transistor but that should not be an issue here.

Here is the slight overshoot in the response with the LED open and a 2N3904 connected as I suggested (+/-10V input through a 220R resistor), 10ns rise and fall times simulated in LTSpice with 1ns maximum step size:

enter image description here