Tinyboot
Current
tinyboot v0.4.0 Released — The API is Stable
You may have noticed v0.3.0 came and went without an announcement. That was deliberate. Crates were merging, APIs were shifting, the wire protocol was being reworked, and I didn’t want to ship a writeup that’d be stale in two weeks. v0.4.0 is the release where the dust finally settles. If you’re new here, tinyboot is a minimal Rust bootloader for resource-constrained MCUs. It fits in 1920 bytes of system flash and gives you CRC-validated firmware updates over UART, with trial boot and automatic fallback to service mode. I’m building it as part of OpenServoCore so you can OTA-update servo firmware over the same single-wire DXL TTL bus, without tearing the robot apart. What’s in v0.4.0: full CH32V00x family support (V002 through V007, including the V006 that the OSC dev board runs on), TX_EN now fits in system flash on every supported variant, the three tinyboot-ch32-* crates collapsed into one, 24-bit protocol addresses with per-command flag bits, two nasty half-duplex bugs squashed during dev-board validation, and a docs rewrite aimed at users instead of maintainers. Plus a quiet announcement: with the API stable, active feature work pauses while my attention shifts to the OSC firmware rewrite.
tinyboot v0.2.1 Released - User-Flash Path Fixes
Turns out shipping a bootloader and actually booting real firmware through it are two different things. The user-flash path was quietly broken, and the week after the initial release was mostly spent hunting down the bugs that only show up once an application is sitting behind the bootloader. If you’re new here, tinyboot is my minimal serial bootloader for the CH32V003 and friends, squeezed into 1920 bytes of system flash. The 0.2.0 release got the protocol and the system-flash variant solid. 0.2.1 is the follow-up that makes the user-flash variant actually usable. The headline fixes: a hardcoded mtvec in qingke-rt that pointed the interrupt vector table at the wrong place, APB2 peripherals leaking state from the bootloader into the app, a broken app_version read, an alignment UB in the boot metadata path, and a defmt panic on reset-into-bootloader. Plus another ~180 bytes shaved off the system-flash build, because every byte matters when you have 1920 of them.
tinyboot - Initial Release for CH32V003
While I was waiting for the CH32V006 dev board to arrive, I ended up going on a side quest: making firmware updates less painful for future OpenServoCore-based servos. Once a servo is built into a system, it is not really practical to pull it back out, open the case, desolder the board, and hook up a debugger just to flash new firmware. Updating over the existing one-wire UART bus is a must-have feature if I wanted to keep both you and me sane. And that is how tinyboot was born. If you’re new here, OpenServoCore is my effort to turn cheap MG90S-class servos into networked smart actuators with sensor feedback, cascade control, and a DYNAMIXEL-style TTL bus. tinyboot is the bootloader half of that story: a small Rust bootloader that lives where the WCH factory bootloader normally sits, so a deployed servo can take firmware updates over the same one-wire UART bus it already speaks on. This first release targets the CH32V003, fits in 1920 bytes of system flash, and ships with CRC validation, a trial-boot counter that rolls back bad updates on its own, a modular transport layer (standard UART plus DXL TTL with TX_EN), and a tinyboot-cli for driving updates from the host. It is, in the author’s words, a little unhinged on the inside. But it works.
tinyboot - A Minimal Rust Bootloader for CH32
A Rust bootloader that squeezes into the CH32V003’s 1920-byte system flash, with CRC16 validation and trial boot, and still leaves the entire 16KB user flash free for your application. tinyboot is the bootloader half of OpenServoCore , my effort to turn cheap MG90S-class servos into networked smart actuators. Servos need field updates over the same TTL bus they take commands on, and they have very little flash to spare. So tinyboot has to be tiny, robust enough to never brick the part, and portable across the CH32 family. This post is the project overview: what tinyboot is, the feature set, the chips it targets (V003 working today, V103 in progress, the rest of the V0/V2/V3/X line planned), and the transports it speaks (UART and RS485 working, USB planned). If “Rust in 1920 bytes” sounds like a typo, that’s fair, it surprised me too.