Repository navigation
Tinymovr Firmware 2.5.1
Pre-release
Pre-release
Preserve NVM config during DFU firmware updates
This release fixes a critical issue where firmware updates via DFU would reset the CAN node ID to 1, causing conflicts on multi-device CAN buses.
Changes
- DFU NVM preservation: The DFU script now backs up and restores the NVM config region (pages 120-127) around the erase operation, preventing config loss during firmware updates
- Documentation: Added documentation about bootloader CAN ID behavior (reads from slot 0, not wear-leveled latest)
Technical Details
The bootloader's erase_all command wipes pages 4-127, including the NVM config region. The DFU script (tinymovr_dfu) now:
- Reads the entire 8 KB NVM region before erasing
- Performs the firmware flash
- Writes the NVM data back before reset
This ensures the CAN node ID and all other settings survive firmware updates without the device ever appearing at default ID 1 on the bus.
Files Changed
studio/Python/tinymovr/dfu.py: Addedread_nvm_region()andwrite_nvm_region()functionsARCHITECTURE.md: Documented DFU NVM preservation and bootloader CAN ID behaviorCLAUDE.md: Added gotcha about bootloader reading from slot 0