So I wanted to do something fun, so I built a custom ESP32 bootloader lol.
Basically, I grabbed the ESP-IDF framework, wrote the bootloader code in C inside a
@Docker container, and shifted the partition table offset to 0x9000 to avoid sector collisions.
To test it, I made two firmware versions. Version 1 (slow blink) went directly onto App Slot A (0x10000), and Version 2 (rapid blink) was hosted on my headless Debian server.
When V1 boots up, it connects to my wifi, hits the server, streams down the update blocks, and tells the bootloader to flip the active pointer to Slot B (0x1F0000). On reset, the bootloader cleanly jumps to the new slot, and instant V2 upgrade. So frikin coool.
#embeddedsoftwareengineering #bootloader #coolstuff #espidf #esp32 #docker