PROJECT FOUNDRY
Sign up free — track your progress, earn mastery, get the project files
Build guide

Card04 / 08PhaseLAYOUTProjectL1.01 WROOM breakoutBuild

PHASE 04LAYOUT

Now you place the parts into copper and route the connections. The circuit is settled; what turns the board from 'works' into 'barely boots' is where the parts sit and how the copper flows. On this board, one rule stands above the rest: protect the antenna.

Layout is where the schematic meets physics. The very same circuit can work flawlessly or barely boot, depending on where the parts sit and how the copper flows between them. Three placements decide this board: the empty zone under the antenna, the decoupling caps right at the pins, and the USB pair.

01 · The antenna keep-out

U1's antenna only works over empty board.

The WROOM module sends out its signal from a printed antenna at one end. Under and around that antenna you keep an : no copper, no , no traces — ideally the module even hangs off the edge of the board. Copper there detunes the antenna and quietly kills your wireless range. This is the headline item on the LAYOUT review, and it's the one mistake you can't fix without making a whole new board.

Board top view: ground pour fills the copper everywhere except a red dashed keep-out zone under the WROOM module's antenna, reaching the board edge.
Top view — the antenna keep-out: no copper, no pour, no traces (often a board cut-out).
Loading 3D model…
U1 — the antenna sits at one end; keep all copper out from under it
Check yourself

You pour ground everywhere for a clean return path. Why must it stop short of U1's antenna? Copper near the antenna detunes it — the keep-out has to stay bare.

Deep dive· Why nearby copper detunes the antenna

The WROOM's printed antenna is tuned to radiate at 2.4 GHz — its shape and its surroundings are designed for exactly that frequency. Bring copper close (a , a trace, even thick silkscreen) and you add stray capacitance that shifts the tuning, like detuning a guitar string by hanging a weight on it. The antenna still 'works,' but its sweet spot slides off 2.4 GHz and most of your transmit power reflects back into the chip instead of leaving the board — range drops from across-the-house to across-the-desk. No firmware setting recovers it; the only cure is keeping the keep-out genuinely empty, which is why the module is usually placed hanging off the board edge.

02 · Decoupling caps go first, and close

Remember C2/C3/C7? Their whole value is decided here, by where you place them.

A only does its job parked right against the pin it feeds, with a short, fat path to ground. So place C2, C3, and C7 right at U1's 3V3 pins before you route anything else — and put C1, the , near where power enters the module. Route them the long way around and the trace inductance throttles the fast current they exist to deliver; they turn into decoration.

Two panels: a decoupling cap right at the IC pin makes a small current loop (low inductance); the same cap placed far makes a large loop that chokes the fast current.
Why placement matters — the current-loop area sets the inductance.
Check yourself

A decoupling cap is electrically correct in the schematic but placed 15 mm from the pin. Does it still work? Barely — trace inductance chokes the fast current, so being close to the pin is the entire point.

Deep dive· Loop area becomes inductance becomes droop

When the ESP32 suddenly demands current, that current flows out of the , into the pin, and back through ground — a little loop. Every loop of conductor has inductance, and inductance fights sudden changes in current: the voltage it costs you is V = L × (di/dt). The chip's demand changes incredibly fast — a big di/dt — so even a few nanohenries of trace inductance becomes a real voltage dip right at the pin, exactly when the chip needs the rail to hold steady. The fix is pure geometry: a shorter, fatter path from cap to pin to ground makes a smaller loop, which means less inductance and less droop. So 'close to the pin' isn't a nicety — it's the whole mechanism.

03 · The USB data pair

D+ and D− are a team — route them like one.

USB D+ and D− form a : keep them short, side by side, equal in length, and away from noisy nets. Run them through D1, the array, right at the connector, so a static zap is clamped before it can travel into the module. A alongside the pair gives a clean return path and a little shielding.

Check yourself

Why route USB D+ and D− together and length-matched? They're a differential pair — the receiver reads the difference between them, so mismatched length or stray noise on one line corrupts the signal.

Quick check — layout

1. The WROOM module has a printed antenna at one end. What goes under and around it?
2. Why must the small decoupling caps sit right against the chip's power pins?
3. How should USB D+ and D− be routed?
4. Where should the ESD protection (D1) sit on the USB lines?
5. Which layout mistake on this board usually can't be fixed without making a new board?
Exit this stage

Complete the LAYOUT review (antenna keep-out, isolation, decoupling placement). The BOM freezes here — after this, a parts change means a new revision.