soif / EspBuddy

Wrapper to easily upload (OTA or Serial), backup, batch query, monitor ESP8266 boards using Esptool.py, Espota.py and Platformio
GNU General Public License v3.0
51 stars 10 forks source link

Support for .bin.gz images #22

Open TD-er opened 4 years ago

TD-er commented 4 years ago

I was looking for updating our old 2-step updater image to be built using the latest core 2.7.0, so it can support .bin.gz images.

But why re-invent the wheel if there is EspBuddy :)

So do you think it is possible you can make EspBuddy our default 2-step updater, supporting .gz images?

I was thinking about how to make the build fit, as the core 2.7.0 builds are quite a bit larger than the older core versions. So maybe we can leave out the SPIFFS lib and let ESPEasy save some basic needed settings into the EEPROM section (which we don't yet use). For example:

This way we don't need to interpret the settings files, or even have to bother looking at the SPIFFS. Just allow to have a very basic interface to upload the new (.bin.gz) image.

soif commented 4 years ago

Hi @TD-er

Happy that you've finally tested EspBuddy ;-)

I'm not sure to fully understand your request...

What would you like that I change in EspBuddy?

Adding the ability to use another minimalOtaFirstStep.bin.gz instead of the current one (firmwares/ESPEasyUploader.OTA.1m128.esp8266.bin)? right?

TD-er commented 4 years ago

Well the 2-step OTA build must be based on the latest core version. Then it supports to flash compressed bin files. This also means the 2-step OTA build can be compressed if used to upgrade a node running core 2.7.0 So the added size of the newer core can be compensated by compressing it.

This also makes it slightly more complex to determine the max. size of a bin file, as the total sketch space must be able to hold an uncompressed file + the other in compressed form.

I have not yet tested the entire ESP-buddy system myself, but I was thinking you've been working on it for a while so you will have a much better understanding of what's needed here and I do like the concept of assisted web backend for deployment. And by using your 2-step OTA binary we also may help each other in further development.

For example something I think may also be possible in the future is to patch or upgrade settings or maybe even switch file systems (SPIFFS => LittleFS) which would otherwise be a very cumbersome exercise.