Espressif open-sources esp-emulator: ESP32 firmware without a board
Running ESP32 firmware has always required the firmware's other half: a board on a desk, a USB cable, and a serial port that behaves. Espressif has now published an official emulator, esp-emulator, that takes the board out of the loop. It is written in Rust, loads the merged firmware image an ESP-IDF build produces, and simulates the chip from its boot sequence onward, either in a terminal or compiled to WebAssembly and run in a browser tab.
The project is public on GitHub under Espressif's organisation and is labelled Beta. It is not a demo that only prints a boot banner: the repository's support matrix lists esptool and espefuse commands verified across seven chips, and the model includes the memory map, the interrupt controller and multi-core execution that firmware depends on. What it does not yet do is reproduce every peripheral, and the classic ESP32 is absent from the supported list.
What the emulator actually simulates
esp-emulator does not run a hand-written example. It takes the merged image produced by an ESP-IDF build and starts at the chip's reset, so the bootloader, the partition table and the application all execute as they would on silicon. Memory mapping, the interrupt controller and dual-core scheduling are part of the model.
Two architectures are covered:
| Architecture | Chips |
|---|---|
| RISC-V | ESP32-C3, ESP32-C5, ESP32-C6, ESP32-H2, ESP32-P4, and ESP32-S31 in early adaptation |
| Xtensa LX7, dual-core | ESP32-S3 |
The simulation goes beyond the instruction set. The floating-point unit, the PMP and PMA permission controls, the MMU and the crypto accelerators are modelled, which means AES, SHA, RSA, ECC, digital signatures and flash encryption can be exercised in the emulator rather than only on hardware.
The peripheral list is long, but it should be read as a starting point. Espressif names UART, USB Serial JTAG, GPIO, I2C with a built-in EEPROM slave, general-purpose SPI, SPI flash, the system and general-purpose timers, the watchdog, RMT, LEDC, PCNT, MCPWM, eFuse and GDMA. The project's own caveat is that per-chip coverage and behavioural fidelity still need to be checked item by item.
Wi-Fi, BLE and Thread, simulated
For an ESP32 the radio is the point, and this is where the emulator goes past a CPU model.
- Wi-Fi. A built-in soft access point supports the WPA2-PSK and WPA3-SAE handshakes, 802.1X enterprise authentication forwarded to a RADIUS server, and a DHCP service.
- Networking. The default user-space NAT mode needs no sudo and no TAP interface; TCP and UDP forwarding work out of the box, and mDNS records can be rewritten, which matters for provisioning flows built on Matter or HomeKit. Where a lower-level link is needed, Linux can use TAP and macOS can use vmnet, so the local build can reach the real internet.
- BLE. Every Bluetooth-capable chip runs the NimBLE stack. The HCI transport can attach to Google's Bumble virtual controller for pure-software simulation, or to a real Bluetooth adapter on Linux.
- Thread. ESP32-C6 and ESP32-H2 can run OpenThread's ot_cli and ot_br. Two emulator instances bridged over local UDP form a two-node 802.15.4 Thread mesh.
That last item is the one developers notice. Scenarios that used to need two or three boards on a desk, such as provisioning, mesh formation and an enterprise Wi-Fi join, can now be reproduced on a single machine.
Fitting into the existing workflow
An emulator is only useful if it slots into the toolchain people already use, rather than being a demonstration of a boot log. Three options carry most of that weight.
- Flashing. The --uart-tcp option bridges UART0 to a TCP port. In download mode, esptool.py, espefuse.py and idf.py flash can flash firmware and read or write eFuse over a socket address, the same way they address a real board.
- Debugging. The --gdb option starts a GDB remote stub on a chosen port, so a debugger for the matching architecture can set breakpoints and inspect registers. Adding --gdb-halt stops the CPU at reset until the debugger attaches.
- Tracing. The --trace option writes a Chrome Trace file that opens in Perfetto. FreeRTOS task scheduling and CPU time become visible without instrumenting the firmware; an ELF file has to be supplied alongside.
Together these make the emulator a candidate for continuous integration: compile, flash into the emulator, run tests and produce a trace on every commit, with no board farm to maintain. The support matrix backs the flashing half of that claim, listing esptool and espefuse operations verified on the supported chips, with a note that S31 reports a MAC address where other chips report a chip ID.
Two ways to run it
The local build installs with a single command that places esp-emu in a user-level bin directory, currently for Linux on x86_64 and arm64 and for Apple Silicon macOS, and updates with esp-emu update.
The web build is the lower-friction option: the emulator is compiled to WebAssembly and served from GitHub Pages. A merged firmware image dragged into the page starts running, with console output, instruction rate, core state, GPIO, registers and memory visible live. The firmware stays in the browser tab and is not uploaded to a server.

The trade-off is network access. The web build cannot reach the network, so any test that involves real Wi-Fi traffic has to move to the local build, or to a locally configured proxy.
Three things to know before relying on it
- The classic ESP32 is not supported. The list is C3, C5, C6, H2, P4, S31 and S3. A project still running on the original ESP32 cannot use the emulator yet.
- The web build has no network. It is good for demos, teaching and quick logic checks, but Wi-Fi behaviour requires the local build.
- The source is not published. The repository carries an Apache-2.0 licence, but it currently holds the install script, prebuilt binaries, documentation and helper tools rather than the emulator's own source. Whether the source will be opened is, according to the project's issue tracker, still undecided.
Two further points belong with those. The project is marked Beta, so emulated behaviour can still diverge from a real chip, and peripheral coverage is the part most likely to differ.
Where it fits, and where it does not
The emulator does not replace a bench. It replaces the parts of the loop that do not need electricity: continuous integration, protocol-stack validation for Wi-Fi enterprise authentication, Matter provisioning and Thread formation, reproducing a logic fault when no board is at hand, and demonstrating firmware by dropping a file into a browser tab.
For teams that already test on hardware, the value is in the pipeline: firmware that builds and boots in CI before anyone picks up a board. For teams without a board yet, it is a way to start.
Official resources
IOTTourChina covers open-source IoT hardware and the tooling around it as part of its developer resource. This is editorial coverage, not an endorsement; features, licensing and chip support should be confirmed against Espressif's documentation before you rely on them.