Set OTA on NINA W106 00B


I am currently using an evalkit Nina W106-00B board that incorporates an ESP32.

I am desperately trying to implement OTA (Over-The-Air) updates.

I started by modifying my partitions.csv file, which looks like this (without OTA) and works well:

nvs, data, nvs, 0x9000, 0x6000,
phy_init, data, phy, 0xf000, 0x1000,
factory, app, factory, 0x10000, 1M,
storage, data, spiffs, , 0xF0000,

The “factory” partition corresponds to my .bin file containing the code.
The “storage” partition corresponds to my .bin file containing the web pages and .js files.

I tried to modify it so that when I add a new .bin file containing the code, it goes into the “ota_0” partition, for example, and then boots without using the “factory” partition.

This is what it looks like now:

nvs, data, nvs, 0x9000, 0x6000,
otadata, data, ota, 0xf000, 0x2000,
phy_init, data, phy, 0x11000, 0x1000,
factory, app, factory, 0x20000, 1M,
storage, data, spiffs, 0x120000, 0xF0000,
ota_0, app, ota_0, 0x210000, 1M,
ota_1, app, ota_1, 0x310000, 1M,

I can compile and flash it, but when I start my board, an error message appears in the logs:

ELF file SHA256: 73241a5f6639ca7a

ets Jul 29 2019 12:21:46

rst:0xc (SW_CPU_RESET),boot:0x33 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
mode:DIO, clock div:2
ho 0 tail 12 room 4
entry 0x40080598

assert failed: do_core_init startup.c:339 (flash_ret == ESP_OK)

Backtrace: 0x40081ee2:0x3ffe3a90 0x4008a4bd:0x3ffe3ab0 0x40090fdd:0x3ffe3ad0 0x400d2a13:0x3ffe3bf0 0x400d2abe:0x3ffe3c10 0x4008165e:0x3ffe3c40 0x4007927e:0x3ffe3c90 |<-CORRUPTED

This message keeps looping, and the board attempts to restart without success.

How should I modify my partitions.csv file for it to work correctly?


Can you refer this OTA example which works on esp - esp-aws-iot/examples/ota/ota_mqtt at master · espressif/esp-aws-iot · GitHub

Thanks, but the partition table is :

pre_prov, 0x3F, , 0xD000, 0x6000, encrypted
nvs, data, nvs, , 0x4000,
otadata, data, ota, , 0x2000,
phy_init, data, phy, , 0x1000,
ota_0, app, ota_0, , 1M,
ota_1, app, ota_1, , 1M,
storage, data, nvs, , 0x4000,

And i don’t know how to adapt it for mine, because it doesn’t have factory partition. And i need to have it because my source code is in, and i’m trying to set the OTA on it.

I try to modify it so that when I add a new .bin file containing the code (normaly in the factory partition), it goes into the “ota_0” partition, for example, and then boots without using the “factory” partition but ota_0 with the new code.

Does using ota_0 work for you or not?

No, the partition table doesn’t work for me

This seems like a Espressif specific problem - you are likely to get better response on Espressif forums. While searching for it, I found this issue. In case you are facing the same issue, you can try to change the flash mode as described here - SPI Flash Modes - ESP32 - — latest documentation.

I tried to change the flash mode with all differents mode qio / qout / dio / dout but I have the same problem no matter the choice

Did you try contacting Espressif?


Looks like the esp_flash_init_default_chip() call in the second stage bootloader is returning an error thus triggering the assert. This could be due to multiple reasons.

Anyhow, it looks like an ESP-IDF specific issue. Could you open an issue in at the ESP-IDF Github repository and include details such as:

  • ESP-IDF version
  • sdkconfig of your build
  • Hardware used (if possible, which ESP32 chip/module version is integrated into the Nina board).



No I did not try, I kept this solution as a last resort


Yes i will open an issue, but can you send me a link to know where put it, because i don’t masteries Github so i don’t know where open it ?

Thanks! :slight_smile:


ESP-IDF issues can be reported via Issues · espressif/esp-idf · GitHub

Thanks @Dazza0 ,

I’m writing the issue, but my sdkconfig do 1692 lines, it’s maybe to muche to add it in my issue ?

You can attach the sdkconfig file.

Thanks !

I did the issue number 11553