r/embedded • • 1d ago

A configurable microcontroller bootloader, unified across boards, inspired by kconfig

https://github.com/MilkmanAbi/MimiBoot-Mu

So back in late 2025 (November-December iirc?) I was messing around with the rp2040/2350 trying to build a smartwatch OS, needed a quick bootloader with custom features so I cobbled together a really badly designeed ELF loader written in arduino IDE - it worked but ended up being bloated of course. shelved it after a few months in Jan-Feb this year, kinda just lost interest in hardware and had like some mental health stuff going on.

This Oct 2026, my friend at poly was developing a cubesat payload on an stm32 with 20kb flash and he was trying to develope a custom bootloader - needed something ultra light with fault hardiness, OS hooks and on boot media verification. we ended up going down a rabbit hole about modular design, OS hooks, image verification, golden image fallback, a hybrid Atomic/Monotonic boot structure (whacky stuff I tell ya). separately i also ended up needing a bootloader for an atmega-based parcel tracker that had to survive odd field conditions - not a big project, just a module project but the lecturer was trying to ask me to account for unrealistic field conditions.

So I picked it back up properly. He donated his code, his team donated me their abandoned code, I mixed in my own existing abandoned code and design and kinda reimplemented whatever existing bootloaders already do - all the real features real proper bootloaders have, and ended up with this project - a minimalist approach to bootloaders - kconfig-style configurability where the code for stuff you don't enable is literally gone - the code is literally excluded from the build. Scales from a 1-2kb AVR stub to full A/B+golden slots with post-quantum signatures if you need it. Supports bare metal code to booting FreeRTOS to Zephyr, covered the basics.

Obv, it's like a silly kinda exploratory project of mine - literally a reinventing the wheel kind of project. Built out of necessity if anything.

Moreso as a research project and learning experience than anything. It's slightly functional alr, STM32F10 and RP2040 for example I've tested it on alr. Idk, it's a project that's literally made from abandoned code I was donated, that's it, felt I might share it for fun since I'm just bored.

https://github.com/MilkmanAbi/MimiBoot-Mu

10 Upvotes

2 comments sorted by

2

u/SignedInt32 1d ago

That looks awesome dude! ⭐ πŸ‘ from me !

0

u/rainboww_J 1d ago

Nice! A bootloader is always a fun and rewarding project to work on ☺️ I see it has crash loop prevention, does that mean it can recover from an unfortunate reset during image swapping as well? And nice that it can be used for already existing image formats as well! Saw in the readme that mcuboot is for zephyr but thats not entirely accurate. It can run on any 32bit mcu since one needs to add their own image loading and flash driver