HTTPS OTA error: Passive OTA partition not found

Good Morning. I am using platformIO to develop projects with ESP32 (ESP-IDF). In one of my projects, I am using OTA with HTTP server. ESP32 is able to access the .bin, however, when writing the new binary to the other OTA partition, it presents the following error (function esp_err_t ret = esp_https_ota (& ota_client_config)): Passive OTA partition not found.

I already checked sdkconfig, and it is configured like this:
# CONFIG_PARTITION_TABLE_SINGLE_APP is not set
CONFIG_PARTITION_TABLE_TWO_OTA = y
# CONFIG_PARTITION_TABLE_CUSTOM is not set
CONFIG_PARTITION_TABLE_CUSTOM_FILENAME = ā€œpartitions.csvā€
CONFIG_PARTITION_TABLE_FILENAME = ā€œpartitions_two_ota.csvā€
CONFIG_PARTITION_TABLE_OFFSET = 0x8000

My platformio.ini:

[env: esp32dev]
platform = espressif32
board = esp32dev
framework = espidf

monitor_speed = 115200

board_build.embed_txtfiles =
  src / cert / certs.pem

Error like this: ERROR ESP32

I managed to run this project on ESP-IDF 3.3.2 and OTA works perfectly.

Can you help me with this problem?

Thank you!

What partition table does the MCU print at the start?

boot: Chip Revision: 1
(60) boot_comm: chip revision: 1, min. bootloader chip revision: 0
(44) boot: ESP-IDF HEAD-HASH-NOTFOUND 2nd stage bootloader
(44) boot: compile time 15:23:09
(53) boot: Enabling RNG early entropy sourceā€¦
(53) boot: SPI Speed : 40MHz
(53) boot: SPI Mode : DIO
(57) boot: SPI Flash Size : 4MB
(61) boot: Partition Table
(65) boot: ## Label Usage Type ST Offset Length
(72) boot: 0 nvs WiFi data 01 02 00009000 00006000
(80) boot: 1 phy_init RF data 01 01 0000f000 00001000
(87) boot: 2 factory factory app 00 00 00010000 00100000
(95) boot: End of partition table
(99) boot_comm: chip revision: 1, min. application chip revision: 0

Guys, good afternoon. I found that, even though I modified sdkconfig, the project did not take information from partitions_two_ota.csv. It always takes partitions_singleapp.csv. When I modified this file, it worked OTA, that is, it created other partitions.

Thank you for your help.

For future reference (and preventing an platform update from mucking your project up when partitions_singleapp.csv is overwritten with the correct values), have a look at the board_build.partitions platformio.ini parameter :wink:

2 Likes