MIDI in circuit
MIDI in circuit
Converts the MIDI current loop into a logic‑level signal while maintaining galvanic isolation.
DIN input wiring
- DIN Pin 4 → 220 Ω resistor → 6N138 Pin 2
- DIN Pin 5 → 6N138 Pin 3
- DIN Pin 2 → Ground
This forms the standard MIDI current loop into the optocoupler.
Optocoupler power and bias
- 6N138 Pin 5 → Ground
- 6N138 Pin 8 → +5 V
- 6N138 Pin 7 (VB) → Leave unconnected for MIDI applications
- (VB is used for CTR tuning in other applications, but not needed here)
Optocoupler output stage
- 6N138 Pin 6 (VO) → 10 kΩ pull‑up resistor → +5 V
- 6N138 Pin 6 (VO) → 470 Ω resistor → MPS6514 NPN Base
- MPS6514 NPN Emitter → Ground
- MPS6514 NPN Collector → +5 V through 10 kΩ pull‑up
This transistor stage strengthens the optocoupler output and ensures clean edges.
Logic output to 74HC14
- MPS6514 NPN Collector → 74HC14 Pin 1
- 74HC14 Pin 2 = cleaned, conditioned MIDI logic signal.
IN Activity LED
- MPS6514 NPN Collector → 1 kΩ resistor → LED anode
- LED cathode → Ground
The LED flashes on incoming MIDI activity.