TLDR; how to make a MIDI input withstand shorting to \$\pm12V\$?
This is a counterpart to this question, I'm asking this as I was inspired by the great answer I got there.
I'm designing a MIDI input in a eurorack modular synth module on a TRS jack (this is a semi-standard non-standard way to save space), where it's quite possible for the user to accidentally plug in anything between ±12𝑉 to the input. I obviously need to protect the input, while keeping the circuit maximally compatible with other MIDI devices.
The standard MIDI input circuit adapted to the TRS connector:
where tip, ring and sleeve are of course the pins of the TRS input connector. The LED represents the opto-coupler, which is in this case a 6N137. The MIDI standard really just specifies a 5mA current loop as the signaling method, and gives an example circuit.
Now, assume that the user plugs in say \$+12V\$ on the tip and \$0V\$ on the ring. Then the current through the optocoupler and resistor is 46mA, which is just within absolute maximum for the 6N137, and gives a power dissipation of 500mW in the resistor, so a not-impossible-but-hefty 3/4W resistor will survive. The situation is the same in the reverse voltage case.
However, it is not impossible (although requires a stereo lead which is rare in the eurorack environment) that the tip could be at \$+12V\$ while the ring is at \$-12V\$ (or vice versa), giving a total voltage difference of \$24V\$, in which case the absolute maximums of basically all the components is exceeded.
The reason I'm having difficulty coming up with a nice protection circuit is that:
- the circuit should be floating, to maintain the opto-isolation
- Because of this, I can't clamp things to ground or the power rails etc
- the usual driving circuit on the other end is just a simple two-resistor "current source", so the voltage drops introduced by diodes tend to throw things off.
Since the \$\pm12V\$ case is quite unlikely to happen by accident, I'm considering just keeping this circuit as is, with R1 a 3/4W resistor, but if there's any nice way to protect against \$24V\$ I'd be very interested in hearing that. Bonus points for staying a bit further clear of the absolute maximums of the components, and of course the circuit should be maximally compatible with the various MIDI output circuits out in the wild.