In this guide
Every project needs power, and the power is never at the right voltage. The adapter gives 12 V, the Arduino wants 5 V, the ESP32 wants 3.3 V, the sensor wants 12 V from a 5 V USB bank. You have three ways to change DC voltage: a linear regulator (simple, wasteful), a buck converter (steps down, efficient), or a boost converter (steps up, efficient). Students who default to the 7805 linear regulator for everything end up with hot regulators, dead batteries, and brownouts — the switching converters in this guide fix all three, and the ready-made modules cost less than the heatsink the linear approach needs.
This guide explains how buck and boost converters actually work (inductor, switch, diode/catch FET, and the duty-cycle math), compares them against linear regulators with real efficiency numbers, covers inductor and capacitor selection, and gives module recommendations with wiring rules. The companion batteries and regulators guide covers the wider power-supply picture — batteries, adapters, and linear regulators — that this guide builds on.
The 30-second mental model
Both converters store energy in an inductor's magnetic field and release it at a different voltage, thousands of times per second:
- Buck (step-down): a switch connects the input to the inductor for a fraction D of each cycle (duty cycle D), then the inductor freewheels through a diode into the output. Output voltage ≈ D × input voltage. 12 V in, D = 0.42 → ~5 V out.
- Boost (step-up): a switch connects the inductor across the input to charge it (fraction D of the cycle), then the inductor's collapsing field stacks on top of the input voltage into the output. Output voltage ≈ input / (1 − D). 5 V in, D = 0.58 → ~12 V out.
The controller chip adjusts D continuously by watching the output through a feedback divider — that is the entire regulation mechanism. No energy is deliberately burned as heat, which is why efficiencies of 85–95% are routine.
Buck vs boost vs linear: the efficiency math that decides
Take the canonical student case: 12 V in, 5 V out, 1 A load.
Linear regulator (7805): output power = 5 V × 1 A = 5 W. Input power = 12 V × 1 A = 12 W (a linear regulator passes the same current through). Wasted as heat: 7 W. Efficiency = 5/12 ≈ 42%. That 7 W needs a real heatsink — without one, the 7805 hits thermal shutdown in minutes. At 2 A it is 14 W of heat: a small room heater.
Buck converter at 90% efficiency: output 5 W, input ≈ 5.56 W, waste ≈ 0.56 W. The module stays barely warm. Input current is only ~0.46 A at 12 V — the converter draws less current than it delivers, which surprises students the first time they measure it. (Power in ≈ power out; current transforms inversely to voltage.)
Boost example (5 V USB to 12 V, 0.5 A): output 6 W; at 88% efficiency input ≈ 6.8 W, so the 5 V source must supply ~1.36 A. This is the number students miss: boosting voltage multiplies the input current. A USB port rated 500 mA cannot feed a 12 V/0.5 A load through a boost converter — the input side needs ~1.4 A. Size the source for the input current, not the output.
Rule of thumb: if the voltage drop is small (5 V → 3.3 V at low current) and the current is modest, a linear LDO is fine and simpler. If the drop is large (12 V → 5 V) or the current is above ~0.5 A, use a buck converter. If you need a higher voltage than your source, use a boost converter — and check the source can supply the multiplied input current.
How a buck converter works, step by step
One switching cycle at frequency f (typically 150 kHz–1.5 MHz on modules):
- Switch ON (fraction D): input voltage connects across the inductor. Current ramps up linearly, storing energy in the magnetic field: di/dt = (Vin − Vout)/L.
- Switch OFF (fraction 1−D): the inductor current cannot stop instantly — it freewheels through the diode (or synchronous FET) into the output capacitor and load. Current ramps down: di/dt = −Vout/L.
- Steady state: the ramp-up equals the ramp-down over a cycle, giving Vout = D × Vin (ideal). The output capacitor smooths the ripple into DC.
- Regulation: the controller measures Vout via a feedback divider and nudges D up or down — thousands of times per second — to hold Vout constant as load and input change.
Ripple current — the inductor current's triangular wobble — is typically designed at 20–40% of the load current. Bigger inductor → less ripple but slower transient response and a physically larger part. Module makers have already made this tradeoff; you only revisit it if you are designing the converter from scratch (or winding your own inductor, which this guide does not recommend for a first build).
Synchronous vs non-synchronous
Cheap modules (LM2596) use a diode for the freewheeling path — simple, but the diode drops ~0.5 V, costing efficiency at low output voltages. Synchronous bucks replace the diode with a second MOSFET (near-zero drop), gaining several efficiency points — this is why most modern converter ICs are synchronous. For student module selection it is a "nice to know": given two modules, prefer the synchronous one if the price is close.
How a boost converter works, step by step
- Switch ON (fraction D): the inductor connects directly across the input. Current ramps up: di/dt = Vin/L. Energy stored: ½LI².
- Switch OFF: the inductor current must keep flowing — it now flows through the diode into the output, and the inductor voltage adds to the input: Vout = Vin + L×di/dt, regulated to the target by the controller varying D.
- Steady state: Vout = Vin/(1 − D) (ideal). D = 0.5 doubles the voltage; D = 0.75 quadruples it — but efficiency and component stress degrade as D pushes past ~0.8, so practical boosts top out around 4–6×.
The boost gotcha students hit: a boost converter cannot limit its output below the input voltage. With the switch off, the input feeds straight through the inductor and diode to the output — so a "12 V" boost module fed 12 V outputs ~12 V minus a diode drop even at D = 0. If your input can exceed the target output, you need a buck-boost (SEPIC) topology, not a plain boost. The second gotcha: short the output of a boost converter and the input dumps current through the inductor and diode with no switching to limit it — most cheap modules have no short-circuit protection on the output side.
Inductor basics: the one component people fear
The inductor is just a coil whose current cannot change instantly — that property is the entire energy-storage mechanism above. What you need to know for module selection and (rare) custom designs:
- Inductance (µH): sets the ripple current for a given frequency and voltage. Higher inductance → lower ripple. Module values (22–100 µH typical) are chosen by the designer; trust them.
- Saturation current (Isat): the current at which the core saturates and inductance collapses. The inductor's Isat must exceed your peak current (load current + half the ripple), with margin. A saturated inductor looks like a short — current spikes, the switch overheats. This is the #1 inductor failure.
- DC resistance (DCR): copper loss = I² × DCR. Lower DCR = cooler, more efficient. Toroidal inductors (the donut-shaped copper coils) generally have lower DCR and less EMI leakage than cheap drum cores.
- Shielded vs unshielded: shielded inductors contain their magnetic field — worth it near sensitive analog circuits or radios.
For module buyers: you do not select the inductor, but you do read the module's current rating and derate it — a "3 A" LM2596 module is comfortable at 1.5–2 A continuous in a warm enclosure; the 3 A figure assumes ideal cooling.
Capacitors: input, output, and why low-ESR matters
- Input capacitor: the switch draws pulsed current from the source; the input cap supplies those pulses locally. Undersize it (or place it far from the module) and the input rail rings, efficiency drops, and nearby circuits pick up noise. Modules include one — add 100–470 µF electrolytic in parallel if your supply leads are long.
- Output capacitor: smooths the ripple. Low-ESR types (solid polymer, or quality electrolytics) matter because ripple voltage ≈ ripple current × ESR. A tired high-ESR capacitor is why old buck modules develop large output ripple.
- Ceramic bypass: a 100 nF ceramic at the module's input pins kills high-frequency noise the electrolytic cannot touch.
The modules to actually buy
| Module | Topology | Input | Output | Current | Notes |
|---|---|---|---|---|---|
| LM2596 buck (blue PCB, common) | Buck, non-sync | 4.5–40 V | 1.25–37 V adjustable | ~2 A practical (3 A rated) | The default student buck. 150 kHz. Verify output with a meter before connecting the load — the trim pot ships at a random setting. |
| Mini-360 / MP1584 buck | Buck, synchronous | 4.5–28 V | 0.8–20 V adjustable | ~1.5 A practical | Smaller, more efficient than LM2596, 1.5 MHz (smaller inductor). Good for 5 V→3.3 V rails. |
| MT3608 boost | Boost | 2–24 V | 5–28 V adjustable | ~1–2 A practical | The default student boost. Remember: input current = output current × (Vout/Vin) / efficiency. |
| XL6009 boost | Boost | 3–32 V | 5–35 V adjustable | ~2–3 A practical | Beefier boost for higher power (LED drivers, 12 V rails from batteries). |
| Fixed 5 V / 3.3 V buck modules | Buck | varies | fixed | varies | Prefer fixed-output modules for the final build — no trim pot to drift or get bumped. |
The trim-pot ritual: every adjustable module ships with its potentiometer at an arbitrary position — sometimes near maximum output. Always set the output with a multimeter (no load connected) before wiring it to your circuit. Turning the pot the wrong way on a 35 V-capable module can send 30+ V into your 5 V Arduino. This single precaution prevents the most expensive five seconds in student power electronics. The project testing and debugging guide shows the measurement technique.
Wiring rules that prevent the common failures
- Common ground, star-connected: the converter's input ground, output ground, and load ground must share a reference — but run them as a star (single common point) rather than daisy-chaining, so the switching currents do not modulate your sensor ground.
- Short, thick leads on the high-current side: a metre of thin wire at 2 A drops noticeable voltage and radiates switching noise. Keep the battery→converter→load path short.
- Fuse the input: converters fail short more often than open. A fuse (or polyfuse) rated just above your maximum input current protects the battery and wiring.
- Do not parallel cheap modules for more current unless they are designed for it — current sharing is uneven and one module hogs the load. Buy the bigger module.
- Enable/EN pin: many modules expose an enable pin — use it to switch the whole rail from your MCU instead of adding a separate high-side switch.
Efficiency is not one number: the load curve
A converter rated "92% efficient" is 92% at one sweet-spot load — usually 50–80% of its rated current. The full picture is a curve:
- Very light load (<10% of rating): efficiency sags because the controller's own operating current and switching losses are fixed overhead. A 3 A buck delivering 50 mA might run at 70–75% — still far ahead of a linear regulator at a large drop, but not the headline figure.
- Mid load (30–80%): the peak-efficiency zone. Size your module so the typical load lands here.
- Near rated current: efficiency dips again as I²R losses in the switch, inductor DCR, and diode grow. Heat rises steeply — this is why the derating rule (run at ~60% of the printed rating) exists.
Worked comparison across the range — 12 V to 5 V at three load points, buck at realistic efficiencies vs 7805 linear:
| Load | Buck (assumed eff.) | Buck waste heat | 7805 waste heat |
|---|---|---|---|
| 0.1 A (0.5 W out) | 75% → 0.67 W in | 0.17 W | 0.7 W |
| 1 A (5 W out) | 90% → 5.56 W in | 0.56 W | 7 W |
| 2 A (10 W out) | 87% → 11.5 W in | 1.5 W | 14 W |
Even at light load the buck wastes 4× less heat; at 1–2 A the linear regulator is not a serious option without a substantial heatsink. This table is the quantitative answer to "can I just use a 7805?" — yes at 100 mA with a small drop, no almost everywhere else.
Design example: a dual-rail sensor node supply
A common student requirement: 12 V adapter in, 5 V at up to 1.5 A for the Arduino/sensors, 3.3 V at 300 mA for the ESP32 radio board. Two-stage design:
- Stage 1: LM2596 buck module, 12 V → 5 V. At 1.8 A total draw (1.5 A + 0.3 A via stage 2), output power ≈ 9 W; at ~88% efficiency the module dissipates ~1.2 W — warm but fine without extra heatsinking in open air.
- Stage 2: Mini-360 buck, 5 V → 3.3 V at 300 mA. Small drop, synchronous, ~90%+ efficient — waste ~0.1 W.
- Why two stages instead of 12 V → 3.3 V directly? A single buck from 12 V to 3.3 V at low current runs at a very low duty cycle (~27%), where many cheap controllers get noisy and less efficient. Cascading keeps each stage in its comfortable zone, and the 5 V rail is useful on its own.
- Protection: fuse the 12 V input (2 A slow-blow), 470 µF bulk cap at the LM2596 input, 100 nF ceramics at each module's input pins, star ground back to the adapter return.
- Verification: set both outputs with a multimeter before connecting any load (the trim-pot ritual), then power the system and measure each rail at the load end under full operation. If the 3.3 V rail sags when the radio transmits, the stage-2 module or its wiring is undersized — not the code.
Total cost: two modules + fuse + caps, well under ₹300. Total heat: ~1.3 W spread across two modules, versus ~15 W from linear regulators doing the same job.
EMI: keeping the switcher from polluting your own circuit
A buck converter is a radio transmitter you did not intend to build — the switch node slews volts in nanoseconds, and the loop formed by input cap → switch → inductor → output cap radiates. In practice, student builds notice EMI as: noisy ADC readings that clean up when the converter is unpowered, a GSM module that behaves near the power stage, or AM-radio buzz. The fixes, cheapest first:
- Keep the high-current switching loop physically small: input cap right at the module pins, short leads.
- Put the converter away from analog sensor wiring; never run sensor leads parallel to the switcher's input/output leads.
- A ferrite bead or small LC filter on the rail feeding analog circuits (10 µH + 47 µF) drops switching ripple from tens of millivolts to single digits.
- If the module has a metal shield can option, use it near radios — or simply move the converter a few centimetres further from the antenna.
You do not need an EMC chamber for a final-year project; you need short loops, separation, and one LC filter on the analog rail. That handles every EMI symptom students actually encounter.
Troubleshooting table
| Symptom | Likely cause | Fix |
|---|---|---|
| Output voltage wrong / drifting | Trim pot at random position, or bumped | Set with multimeter, no load; prefer fixed-output modules for finals |
| Module gets very hot | Running near rated current in a warm box; high Vin−Vout drop at load | Derate to ~60% of the printed rating; add airflow; check the efficiency math |
| Load resets when motor/pump starts | Input source sags under the pulsed input current; thin leads | Bigger input capacitor; shorter, thicker leads; source rated for peak input current |
| Whining / audible noise | Inductor magnetostriction at light load (pulse-skipping), or ceramic cap singing | Usually harmless; add slight load; a dab of silicone on the inductor damps it |
| Boost output won't go below input voltage | Normal — boost cannot step down (input feeds through) | Use buck-boost/SEPIC if input can exceed output |
| Output ripple too large for analog sensors | High-ESR output cap; long leads; switching noise coupling | Low-ESR output cap; LC filter or ferrite bead on the analog rail; separate analog ground return |
| 5 V rail measures 5 V but MCU browns out | Ripple or transient dips the meter averages out | Add bulk capacitance; check input current headroom; shorten leads |
Putting it together
The decision tree for a student power rail: voltage too high → buck; voltage too low → boost (and check the source current); small drop at low current → linear LDO is fine. Buy the module one size bigger than the math says, set adjustable outputs with a meter before connecting anything, keep high-current leads short, and fuse the input. Two worked examples from real student builds: a solar charge controller is a buck converter with a maximum-power-point brain on top — the power stage is exactly what this guide describes — and an EV battery management system lives or dies on clean, efficient rails for its sensing and balancing circuits. Get the power stage right and half your "mysterious" bugs — resets, noisy ADCs, hot regulators — never appear.