36. Backup power circuit

An electronic device uses a main supply MAIN_IN = 5 V and backup battery BACKUP_IN = 4.2 V to power R_LOAD = 1 kΩ.

Design a circuit using two diodes and one capacitor so that:

  • The main supply powers the load when available.
  • The backup battery automatically takes over when the main supply is unavailable.
  • Reverse current into either supply remains negligible (≤1 µA).
  • When both supplies disappear, the load voltage remains ≥3 V at 10 ms and falls to ≤2 V within 100 ms.

Select one capacitor from:

22 µF, 47 µF, 100 µF, 220 µF

Example test cases:

MAIN_INBACKUP_INConditionVoltage Across R_LOAD
5 V4.2 VNormal operation4.2–5 V
0 V4.2 VBackup operation3.4–4.2 V
0 V0 V10 ms after shutdown≥3 V
0 V0 V100 ms after shutdown≤2 V

For the hold-up test, start with the output settled on backup power.