Replies: 3 comments 7 replies
-
Thanks! |
Beta Was this translation helpful? Give feedback.
0 replies
-
Thank you! I have used the mp-image-tool-esp32. Worked very well. It saved the time to install the tool chain and recompile Micropython for a new flash size. |
Beta Was this translation helpful? Give feedback.
0 replies
-
Do you think it would be possible to...
(All without having any dedicated OTA partition of course) I am trying to think of some way to have updatable devices in-the-field, without having to waste 50% of the storage on OTA partitions... |
Beta Was this translation helpful? Give feedback.
7 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
As some of you may have seen me mention already, I have posted a few new tools which might be useful for ESP32 users.
One runs on your esp32 board to execute Over-The-Air (OTA) firmware updates and the other runs on your computer to manipulate micropython firmware images and devices.
I have found these to be very useful for my use cases, maybe they will be for you too. See a brief summary below. For all the details checkout the
README.md
in each repo.micropython-esp32-ota: supports esp32 Over The Air firmware updates and rollback control:
.app-bin
) to the next available OTA partition and set it as the boot partition:firmware will be checked against these:
ota.rollback.cancel()
.mpremote mip install github:glenn20/micropython-esp32-ota/mip/ota/mpy
NOTE: You must be using an OTA-enabled firmware for this to work, which brings me to the next tool:
mp-image-tool-esp32: manipulates esp32 firmware files and firmware installed on esp32 devices:
Typical use cases include:
mp-image-tool-esp32 filename --resize-flash 16M
--table ota
--table nvs=6B,phy_init=1B,factory=0x1f0B,vfs=0
--resize factory=0x2M,vfs=0x400K
,--add vfs2=fat:2M:1M
,--delete phy_init
--read factory=micropython.app-bin,nvs=nvs.bin
,--write factory=micropython.app-bin
--erase nvs,otadata
,--erase-fs vfs
micropython will automatically build a fresh filesystem or 'nvs' partitionon the next boot
--ota-update micropython.app-bin
BONUS: Did you know that micropython does not use the
phy_init
partition which is installed by default in all micropython esp32 firmware?nvs
partition with:--delete phy_init --resize nvs
.nvs
partition and micropython will automatically, on the next boot, initialise a newnvs
store using the extra space.Install and use it with (will print a summary of the partition tables in the firmware and on the device):
If you have any questions, checkout the
README.md
file in each repository or feel free to ask here. If you find any problems, or have suggestions, please post an issue on the github repositories of each tool.Beta Was this translation helpful? Give feedback.
All reactions