15 static const char *
const TAG =
"ota.arduino_rp2040";
17 std::unique_ptr<ota::OTABackend>
make_ota_backend() {
return make_unique<ota::ArduinoRP2040OTABackend>(); }
20 bool ret = Update.begin(image_size, U_FLASH);
26 uint8_t error = Update.getError();
27 if (error == UPDATE_ERROR_BOOTSTRAP)
29 if (error == UPDATE_ERROR_NEW_FLASH_CONFIG)
31 if (error == UPDATE_ERROR_FLASH_CONFIG)
33 if (error == UPDATE_ERROR_SPACE)
36 ESP_LOGE(TAG,
"Begin error: %d", error);
44 size_t written = Update.write(data, len);
49 uint8_t error = Update.getError();
50 ESP_LOGE(TAG,
"Write error: %d", error);
60 uint8_t error = Update.getError();
61 ESP_LOGE(TAG,
"End error: %d", error);
OTAResponseTypes end() override
OTAResponseTypes write(uint8_t *data, size_t len) override
void preferences_prevent_write(bool prevent)
std::unique_ptr< ota::OTABackend > make_ota_backend()
void set_update_md5(const char *md5) override
Implementation of SPI Controller mode.
OTAResponseTypes begin(size_t image_size) override