Page 1 of 1

Disappointment of OTA

Posted: Sat May 13, 2023 8:35 pm
by BlueCoder
Just an expression of disappointment. I thought OTA was something different than it is. I thought it was going to be sort of automatic background process to implement wireless com ports for uploading firmware and maybe debugging.

What it actually is is a support API to implement updating partitions from within your working program. It's nothing special that you couldn't reimplement yourself very simply. But since it's already there: there no reason not to use it.

From within your own program it's up you to receive the new firmware one way or another and write it to a partition. You can then switch partitions, reboot, and finally your new firmware has to verify that it booted property and validate itself or else revert to the old firmware. The update API you implement yourself in your program and only if it didn't crash. And If you want wireless debugging you have to implement it yourself similarly.

In summary there is nothing "Over the Air" about the API. It should rather be called the "Partition Management API".

Re: Disappointment of OTA

Posted: Sun May 14, 2023 2:35 pm
by ESP_Sprite
It's got a bit more specialized stuff in there than just partition things, e.g. rollback and anti-rollback features, but you're right that there's nothing to do with the 'air' in the 'over-the-air' API. Fyi, we have esp_https_ota, which implements something that perhaps is closer to your expectations.