SDFS "OTA" Updates #1961
-
Hi there, the title is pretty self-explanatory: is it possible to use the Updater library (Updater.h) to pull firmware files from SDFS and apply them like with a "normal" OTA update, just skipping the over-the-air part? ;) Given you can pull a Update.begin(firmwareLengthInBytes);
Update.writeStream(streamVar);
Update.end(); like described in the docs or am I completely on the wrong track here? Please let me know if something similar was already asked here, I didn't find anything related on my search. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Yes, it is possible to read a file from SDFS, send it to the Updater who will then write it to onboard flash as a file in LittleFS, and then reboot and write from onboard LittleFS to onboard flash. If you mean, can you directly use SDFS files to update w/o an onboard LittleFS partition, then that is not possible to do today. The actual OTA is handled here, and it doesn't know anything about SPI or the FAT filesystem. To make that work, you'd need to make a minimal bare-metal (non-Arduino) FAT filesystem driver, a minimal (non-Arduino) SPI driver, and define a new partition table structure. It's definitely possible, but not a quick job I would think |
Beta Was this translation helpful? Give feedback.
Yes, it is possible to read a file from SDFS, send it to the Updater who will then write it to onboard flash as a file in LittleFS, and then reboot and write from onboard LittleFS to onboard flash.
If you mean, can you directly use SDFS files to update w/o an onboard LittleFS partition, then that is not possible to do today. The actual OTA is handled here, and it doesn't know anything about SPI or the FAT filesystem.
To make that work, you'd need to make a minimal bare-metal (non-Arduino) FAT filesystem driver, a minimal (non-Arduino) SPI driver, and define a new partition table structure. It's definitely possible, but not a quick job I would think