Search found 2 matches
- Sat Mar 26, 2022 11:35 am
- Forum: ESP32 Arduino
- Topic: Invalid magic byte after esp_partition_write
- Replies: 1
- Views: 1655
Re: Invalid magic byte after esp_partition_write
Fixed by writing the new partition in a for loop if (SD.exists("/firmware.bin")) { File f = SD.open("/firmware.bin"); esp_partition_erase_range(ota0, 0x0, ota0->size); for (int i = 0; i < f.size() + 16; i += 16) { char buf[16]; f.readBytes(buf, 16); esp_partition_write(ota0, i, &buf, 16); } SD.remov...
- Fri Mar 25, 2022 1:04 pm
- Forum: ESP32 Arduino
- Topic: Invalid magic byte after esp_partition_write
- Replies: 1
- Views: 1655
Invalid magic byte after esp_partition_write
I am trying to use a small factory partition to write a bin file to the ota0 partition. My goal is to use a small partition to facilitate updates via an SD card to a larger partition that hold the actual app. The issue that I am having is that while esp_partition_write gives my an ok result, esp_ota...