AMS1117 LDO + Brown-Out Supervisor

A clean 3.3 V rail for an MCU, plus a reset line that holds the chip in reset until the rail is healthy.

Difficulty: Surface-mount. Estimated build time: about 60 minutes. Estimated parts cost: about US$5.00. 9-line bill of materials. Compare supplier offers when available. Two SMD building blocks every MCU board needs, on one tiny board: an AMS1117-3.3 LDO turning a 5 V input into a stable 3.3 V rail, and an external reset supervisor that holds the MCU's RESET line low until the 3.3 V is above its safe…

Lay out the LDO with proper input/output caps

Place the AMS1117-3.3 in SOT-223 with its tab as the GND pin (pin 1, lower left). Place a 10 µF tantalum or ceramic capacitor as close as possible to the input pin (pin 3, top); 22 µF on the output pin (pin 2, lower right). The AMS1117 datasheet specifies output capacitance of at least 22 µF for stability — undersize this and the LDO will oscillate.

Solder the LDO and caps

Tin the SOT-223 pads, place the chip with tweezers, reflow the tab first (it sinks heat), then the two small pins. Solder the input/output caps in 0805 — keep their leads short, especially on the output side.

Validate the rail

Apply 5 V to V_in. Measure between V_out and GND — you should see 3.30 V ± 0.04 V. Load the rail with a 100 Ω resistor (33 mA load) — voltage should stay within 1% of nominal. If it drops to 2.8 V you have an under-spec input cap or a poor solder joint.

Add the brown-out reset supervisor

Place a TL431 voltage reference set to ~3.0 V (R1 = 47 kΩ, R2 = 22 kΩ, REF tied to the divider). Pull-up the open-collector cathode to V_out through 10 kΩ. The output of this network goes to the MCU RESET pin. Whenever V_out drops below 3.0 V, the TL431 turns off, the pull-up wins, and RESET goes high — releasing the MCU. When the rail is healthy, the TL431 pulls RESET low, which is the safe state for AVR/ARM/STM8 RESET-active-low parts. (For active-high RESET parts you'd invert with an MMBT3904.)

Add the power-on delay capacitor

Place a 100 nF ceramic capacitor from the RESET line to GND. Combined with the 10 kΩ pull-up, this gives a ~1 ms RC time so the MCU stays in reset for a few milliseconds after the rail is healthy — long enough for clocks and PLLs to settle. Bigger cap = longer delay.

Brown-out test

Power the board, watch the RESET line on a scope. Slowly drop V_in from 5 V toward 4.4 V — you should see RESET go high (or stay low if you wired active-low) the moment V_out dips below 3.0 V. Bring V_in back up — RESET should release ~1 ms after V_out crosses 3.0 V going back up. That clean release is what was missing from your last 'why did the firmware boot weird?' bug.