Skip to main content

E40 — WRONG_PARTITION_TABLE

The NVS partition table on the device does not match what the firmware expects.

What happens

main enters an infinite loop — it logs the error and waits 1 second, forever. The device is effectively halted; it will not proceed to Wi-Fi or any other functionality until it is reflashed. This is the only error that causes a true firmware halt.

Possible causes

  • The device was flashed with only an application binary, without also writing the correct partition table. The partition table in flash is from an older or incompatible firmware version.
  • A manual flash operation using esptool or a similar tool wrote the wrong binary to the wrong address.

How to fix

  1. Reflash with the full image — Use espflash or the official release process to flash the complete firmware image, which includes the partition table (partitions.csv). Do not flash only the application .bin.
  2. Full chip erase — Run espflash erase-flash before reflashing to start from a completely clean state.