Ideal-diode OR-ing: USB plus battery
Two supplies feed one load and must never feed each other. Schottky diodes would waste 0.3 V. Here each supply goes through a P-MOSFET that a matched PNP pair turns fully on while its side is higher, and off the moment the other side is higher: a diode with almost no drop.

Open this lesson in the labFree, in your browser, no account needed.
How it works
Both PNPs carry the same current when their emitters are equal. Q_A’s side is higher, so its mirror transistor carries less, R2 pulls the gate to about 1 V and the MOSFET is fully on: the drop is I × R_DS(on) ≈ 2.3 mV at 50 mA.
On the battery side the output is above the battery, so that mirror transistor conducts hard, lifts the gate to the output and holds Q_B off: no current flows back into the battery.
Try it on the bench
- Swap in Schottky diodes (variant) and compare the output: 0.3 V lower.
Parts on the bench
- Bench power supply
- 18650 Li-ion cell
- 2 × P-channel MOSFET
- 2 × Matched transistor pair
- 5 × Resistor
- Electrolytic capacitor
In the course
Electronics Engineering, module “Transistor amplifiers”.