Hey guys, I have been struggling to find a good example/tutorial on how to set up a cloud based OTA firmware update scheme. Everything I come across is where you push an OTA firmware update through the local network via local server. I want to be able to put the binaries in the cloud, have the ESP32 periodically check the version number, and then download the binary and run it if the version number is greater than its current running one.
I am willing to use Azure IoT, Google Storage, AWS, etc. to manage the firmware deployments to the ESP32.
I have been searching around and trying misc exaples in Visual Studio Code - both PlatformIO and Azure IoT Device Workbench.
Thanks and any help or advice is greatly appreciated!
As long as these services provide an API to get the version number + download link to the .bin file, existing code examples like httpUpdateSecure.ino for Arduino-ESP32 or examples/system/ota for ESP-IDF already cover this. The code can be easily adapted to a new URL, though the extra logic for possible authenticating + checking wether an update is available must be custom-written.
Code that is already adapted to one of these platforms is e.g.:
If you could that would be amazing!
There’s an example in the beta branch of the esp-aws-iot repo of OTA over MQTT, but being new to CMake I’m still trying to wrap my head around how the build process even works.