ESP32 Inspector: read the board that is connected to your computer
Connect an ESP32 board with a USB cable. Then click Read chip info. The page talks to the ROM bootloader of the chip and shows the chip model, features, MAC address, flash chip and USB-to-serial bridge. You do not need a sketch for this step. The page also has a serial monitor and a small info sketch that sends live data (memory, uptime, reset reason) to a dashboard. Section 4 has checks and repair tools for a board that does not start or does not accept an upload.
This page uses the Web Serial API. Use Chrome or Edge on a desktop computer (Firefox 151 and later also works). Browsers without Web Serial, such as Safari, can show the demo data only. Refer to Online tools.
Reading the chip info resets the board. Your sketch stops, the chip starts the bootloader, and then the page resets the board again so that your sketch starts from the beginning.
- Chip
- —
- Features
- —
- Crystal
- —
- MAC address (base)
- —
- Flash manufacturer
- —
- Flash device ID
- —
- Flash size
- —
- USB bridge
- —
2 · Serial monitor
Reset board sets RTS for 100 ms while DTR stays off. On most boards, this pulls EN LOW and then releases it, so the chip starts your sketch again. This is the same signal sequence as the “hard reset” of esptool. The ROM boot messages of the ESP32 family use 115200 baud. The 74880 setting is for the ESP8266.
3 · Live dashboard with the info sketch
The ROM bootloader cannot tell you about memory use, the CPU speed or the reason for the last reset. Your sketch
can. Upload the sketch below, then connect the serial monitor at 115200 baud. Each ESPINFO line updates the dashboard.
Info sketch (Arduino-ESP32 core 3.x)
esp32_info.ino
// ESP32 info sketch for the ESP32 Inspector page (Arduino-ESP32 core 3.x).
// Every 3 s, it prints one line: "ESPINFO " followed by JSON data.
#include <WiFi.h>
#include "esp_system.h" // esp_reset_reason()
const uint32_t INTERVAL_MS = 3000;
uint32_t sketchBytes = 0;
uint32_t sketchMaxBytes = 0; // size of one app partition = largest possible sketch
const char *resetText = "";
const char *resetReasonName(esp_reset_reason_t r) {
switch (r) {
case ESP_RST_POWERON: return "power-on";
case ESP_RST_EXT: return "external pin";
case ESP_RST_SW: return "software restart";
case ESP_RST_PANIC: return "panic (crash)";
case ESP_RST_INT_WDT: return "interrupt watchdog";
case ESP_RST_TASK_WDT: return "task watchdog";
case ESP_RST_WDT: return "other watchdog";
case ESP_RST_DEEPSLEEP: return "wake from deep sleep";
case ESP_RST_BROWNOUT: return "brownout (low voltage)";
default: return "other";
}
}
const char *flashModeName(FlashMode_t m) {
switch (m) {
case FM_QIO: return "QIO";
case FM_QOUT: return "QOUT";
case FM_DIO: return "DIO";
case FM_DOUT: return "DOUT";
case FM_FAST_READ: return "FAST_READ";
case FM_SLOW_READ: return "SLOW_READ";
default: return "unknown";
}
}
String efuseMacText() {
uint64_t mac = ESP.getEfuseMac(); // byte 0 is the first byte of the MAC
char buf[18];
snprintf(buf, sizeof(buf), "%02X:%02X:%02X:%02X:%02X:%02X",
(uint8_t)(mac), (uint8_t)(mac >> 8), (uint8_t)(mac >> 16),
(uint8_t)(mac >> 24), (uint8_t)(mac >> 32), (uint8_t)(mac >> 40));
return String(buf);
}
void setup() {
Serial.begin(115200);
WiFi.mode(WIFI_STA); // start the Wi-Fi driver, so macAddress() has a value
sketchBytes = ESP.getSketchSize(); // slow call, so read it one time
sketchMaxBytes = ESP.getFreeSketchSpace(); // size of the next OTA app partition
resetText = resetReasonName(esp_reset_reason());
}
void loop() {
float t = temperatureRead(); // NAN if the chip has no usable sensor
String temp = isnan(t) ? String("null") : String(t, 1);
String efuseMac = efuseMacText();
String wifiMac = WiFi.macAddress();
Serial.printf(
"ESPINFO {\"model\":\"%s\",\"rev\":%u,\"cores\":%u,\"cpuMHz\":%lu,"
"\"flashSize\":%lu,\"flashSpeed\":%lu,\"flashMode\":\"%s\","
"\"heap\":%lu,\"freeHeap\":%lu,\"minFreeHeap\":%lu,"
"\"psram\":%lu,\"freePsram\":%lu,\"sketch\":%lu,\"sketchMax\":%lu,"
"\"sdk\":\"%s\",\"core\":\"%s\",\"efuseMac\":\"%s\",\"wifiMac\":\"%s\","
"\"tempC\":%s,\"uptimeMs\":%lu,\"reset\":\"%s\"}\n",
ESP.getChipModel(), (unsigned)ESP.getChipRevision(), (unsigned)ESP.getChipCores(),
(unsigned long)ESP.getCpuFreqMHz(),
(unsigned long)ESP.getFlashChipSize(), (unsigned long)ESP.getFlashChipSpeed(),
flashModeName(ESP.getFlashChipMode()),
(unsigned long)ESP.getHeapSize(), (unsigned long)ESP.getFreeHeap(),
(unsigned long)ESP.getMinFreeHeap(),
(unsigned long)ESP.getPsramSize(), (unsigned long)ESP.getFreePsram(),
(unsigned long)sketchBytes, (unsigned long)sketchMaxBytes,
ESP.getSdkVersion(), ESP_ARDUINO_VERSION_STR, efuseMac.c_str(), wifiMac.c_str(),
temp.c_str(), (unsigned long)millis(), resetText);
delay(INTERVAL_MS);
}
- Copy and uploadPaste the sketch into the Arduino IDE. Select your board and port. Click Upload. Refer to IDE setup.
- Close the Arduino Serial MonitorThe browser cannot open a port that another program uses.
- Connect the monitor on this pageSet 115200 baud and click Connect. The dashboard updates every 3 s.
The sketch needs Arduino-ESP32 core 3.0 or later. On the classic ESP32, temperatureRead() uses an
undocumented sensor. Many chips return a fixed value (often 53.3 °C), so do not use it as a measurement. Some newer chips have
no supported sensor. If the sketch does not compile for your chip, change temperatureRead() to NAN.
The dashboard then shows “not available”.
- Chip model
- —
- Revision
- —
- CPU
- —
- Uptime
- —
- Flash
- —
- PSRAM
- —
- Chip temperature
- —
- Last reset
- —
- eFuse MAC
- —
- Wi-Fi MAC
- —
- Software
- —
Waiting for an ESPINFO line from the serial monitor.
4 · Diagnose and repair
Use these tools when a board does not start, restarts again and again, or does not accept an upload. Start with the checks. The checks only read data. Use a repair tool only if a check shows a problem that the tool can correct.
Checks
The page resets the board and records its start messages for 6 s at 115200 baud. It finds boot loops, crashes, brownouts, an empty flash and a BOOT pin that is held LOW. This check operates without an internet connection.
The page starts the ROM bootloader and reads the flash ID, the bootloader, the partition table and the app partitions. It finds an empty or damaged flash, a program for a different chip and an incorrect Flash Size setting. It does not write to the flash.
No check done yet.
| Label | Type | Offset | Size | Content |
|---|
Repair tools
-
Restart the board
safePulses EN (reset) through the RTS line. The sketch starts again from the beginning. Nothing in the flash changes.
-
Back up the flash
read onlyReads the full flash and saves it as a .bin file. First, select the folder and the file name in the save dialog. Then the page reads the flash. This takes 1–6 minutes. Use this before an erase. If your browser has no save dialog, the file goes to your downloads folder.
-
Erase saved settings (NVS)
cautionErases Wi-Fi passwords, Preferences values and Bluetooth pairings. The sketch stays. Use this when the board connects to an old network, or when the log shows an NVS error.
-
Erase all flash (factory reset)
erases everythingWARNING: this erases the sketch or the preinstalled firmware, all settings and all files. The ESP32 has no factory copy of its firmware, so the board does nothing until you upload a new sketch. Use this when uploads fail, the board restarts again and again, or the flash data is damaged. The ROM bootloader, the eFuses and the MAC address do not change.
-
Write a backup file
overwrites everythingWrites a full backup .bin file to the board from address 0x0. WARNING: this replaces all data on the board. Use only a backup from a board with the same chip type and flash size.
You cannot damage the chip with these tools, because the ROM bootloader is in read-only memory. If an erase or a write stops before the end, hold BOOT, connect the board again, and upload a sketch from the Arduino IDE. Do not use these tools on a board with flash encryption or Secure Boot enabled.
What happens when you read the chip
The ROM bootloader
Each ESP32 chip has a small program in read-only memory (ROM). Espressif writes it at the factory, so you cannot erase it. When the chip starts with GPIO 0 LOW, the ROM bootloader runs instead of your sketch. It waits for commands on the serial port. The Arduino IDE uses the same bootloader to upload sketches. Read chip info and the flash check only read registers, eFuses and the flash. Only the repair tools in section 4 write to the flash.
Auto-reset and the BOOT button
Most development boards have two transistors between the USB chip and the ESP32. The DTR and RTS signals of the serial port control EN (reset) and GPIO 0 (BOOT). The software uses them to put the chip into the bootloader. Some boards, cables and USB hubs do not pass these signals correctly. On those boards, hold BOOT while the log shows “Connecting...”.
The flasher stub
After the connection, esptool-js copies a small helper program (the “stub”) into the RAM of the chip. The stub reads the flash ID faster and more reliably than the ROM. The stub is gone after the reset. Your sketch in flash does not change.
What each field means
| Field | Meaning |
|---|---|
| Chip and revision | The chip family and package (for example ESP32-D0WD-V3, ESP32-S3, ESP32-C3) and the silicon revision. Newer revisions correct hardware errors. Some ESP-IDF features need a minimum revision. |
| Features | Values from the eFuses (one-time programmable bits): Wi-Fi, Bluetooth (BT or BLE), one or two CPU cores, maximum CPU speed, flash or PSRAM in the chip package. |
| Crystal | The frequency of the quartz crystal on the board, usually 40 MHz. The chip makes all its clocks (CPU, Wi-Fi, UART) from this crystal. |
| MAC address | The base MAC address in the eFuses. It is different on each chip. The Wi-Fi station uses this address. The access point, Bluetooth and Ethernet use the next addresses (+1, +2, +3). Many school and campus networks need this address to register a device. |
| Flash ID | The JEDEC ID of the SPI flash chip: one byte for the manufacturer, two bytes for the type and capacity. The capacity byte gives the flash size. |
| USB bridge | The chip that converts USB to serial (UART). The page reads the USB vendor ID (VID) and product ID (PID) from the browser. Each bridge needs the correct driver. Refer to USB drivers. |
| Heap | The free RAM for your variables, strings and libraries. If the free heap goes down all the time, your sketch has a memory leak. |
| App partition | The part of the flash that holds your sketch. If it is almost full, select a different partition scheme in the Tools menu. |
| Last reset | The cause of the last start: power-on, a watchdog, a crash (panic) or a brownout. A brownout means that the supply voltage was too low. Refer to Power supplies. |
Troubleshooting
No port in the list
Use a USB cable with data wires. Install the driver for the bridge chip (USB drivers). Select Show all serial ports in the list if your board uses a different USB chip. Do not use a USB hub during tests.
“Failed to open serial port”
Another program uses the port. Close the Arduino IDE Serial Monitor, PlatformIO, other browser tabs and terminal programs.
Then try again. On Linux, add your user to the dialout group.
“Failed to connect with the device”
The chip did not start the bootloader. Hold BOOT, click Read chip info, and release BOOT when the log shows “Connecting...”. Disconnect wires from GPIO 0, 2, 12 and 15, because these pins set the boot mode.
Unreadable text in the monitor
The baud rate is incorrect. Use the same value as Serial.begin(). The ROM boot messages of the classic ESP32 use 115200 baud.
Boot messages from a different baud rate look like random characters for a short time. This is normal.
Native USB boards (ESP32-S3, ESP32-C3)
These boards can connect without a bridge chip (VID 0x303A). After a reset, the port can disappear for a short time and come back. If the page loses the port, click Connect again. If your sketch prints nothing, set USB CDC On Boot: Enabled in the Tools menu.
The dashboard does not update
Make sure that the info sketch runs and that the monitor shows lines that start with ESPINFO. Set the baud rate to 115200.
If the line is broken, a different Serial.print in your code can mix into it.
The board does not start or restarts again and again
Run the boot check. It reads the start messages and tells you the cause: a crash, a brownout, a watchdog, an empty flash or a BOOT pin that is held LOW. Then run the flash check. Use Erase all flash only as the last step.
Resources
- esptool-js (Espressif)The JavaScript library that this page uses to talk to the ROM bootloader.
- esptool: boot mode selectionThe auto-reset circuit, the BOOT button and the strapping pins.
- Arduino-ESP32 documentationThe ESP class, Wi-Fi and the other core APIs that the info sketch uses.
- Chrome: Web Serial APIHow a web page can open a serial port, with permission from the user.
- USB driversIdentify the CP2102, CH340 or CH9102 chip and install the driver.
- IDE setupInstall the Arduino IDE and the ESP32 board package to upload the info sketch.