- Native OTA needs two OTA partitions and a partition table decided on board one. A single factory partition cannot swap images.
- Flash size on the module must match the table. A 4MB table on a 2MB part will fail in the field.
- Rollback and a factory app are product choices. The official example proves the download path, not your recovery story.
- Do not leave a debug console that can brick partitions in the hands of end users.
Short answer
ESP32 OTA fails after the first update. What should be on the board?
中文
短答
ESP32 第一次 OTA 之后就失败,板上要先定什么?
- Native OTA 需要两套 OTA 分区,分区表在第一块板就要定。只有 factory 分区不能轮换镜像。
- 模组 Flash 容量要和分区表一致。4MB 的表烧到 2MB 的料,到现场会失败。
- 回滚和 factory 应用是产品选择。官方案例证明下载路径,不是你的恢复策略。
- 不要把能写坏分区的调试台留给最终用户。