Back to resources
HIL
Testing
CI
Firmware

ESP32 Hardware-in-the-Loop Testing: Flash Over UART and Test on Real Boards

Flash an ESP32, S3, C3 or C6 from CI through its ROM bootloader, without esptool, then power-cycle it and assert on its console. Tested on an ESP32-WROOM-32 with a BenchPod.

Edward Viaene · November 23, 2026 · 2 min read

An ESP32 has no SWD port, so the usual debug-probe flow doesn't apply. What it has is a ROM bootloader on its UART, and that is enough: a BenchPod can hold the boot pin, reset the chip, and write the image itself. No esptool on the CI machine, and no USB cable to the board.

What is tested, and what is supported

The original ESP32 is Tested: we flash an ESP32-WROOM-32 board with this path on our bench. The S2, S3, C2, C3, C6 and H2 use the same ROM bootloader protocol and are Supported. If one of them misbehaves on your board, tell us the board and what you see and we fix it. The ESP8266 is not supported.

Wiring

Five wires, all at 3.3 V:

PodESP32
An LA pinTXD0
An LA pinRXD0
An LA pinIO0 (IO9 on the C3 and C6)
Reset pinEN
GNDGND

The pod drives the boot pin open-drain and holds it low through reset to enter the bootloader. With --nreset it pulses EN to start the chip afterwards. The ESP32 page has the full table.

Flash an ESP-IDF build

An ESP-IDF build writes a flasher_args.json that names every image and its offset. Point the pod at it:

benchpod flash --target esp32s3 --file build/flasher_args.json --boot 6 --nreset

For a single image at an address:

benchpod flash --target esp32 --file build/app.bin --load-address 0x10000 --rx 3 --tx 4 --boot 6 --nreset

The SDK has the same call, flash(target="esp32", ...), so a pytest can flash and then read the console. It needs pod firmware 3.10.7, CLI 0.8.11 or SDK 2.13.19 or later.

Then test it

After the flash, the pod owns the UART and the power rail, so the usual tests apply: power-cycle and match the boot banner, break the I2C bus on purpose to see how the firmware recovers, or cut power mid-update to check the rollback. Boards that also expose USB can be flashed over USB instead.

Next steps