modm: 2 notable changes in the week of Nov 16
Power-loss safe Zephyr Memory Storage (ZMS) on block devices; [fiber] Implement hosted fibers with threads

modm: a C++23 library generator for AVR and ARM Cortex-M devices.
Follow-up to #1437, where I explicitly left out hosted, because TLS there is annoying: the compilers hardcode it to the OS thread. So instead of fighting that, every hosted fiber is now simply an OS thread, and the context switch hands…
We need somewhere to keep settings and the occasional fault dump in flash, so I compared FlashDB and Zephyr's ZMS (Zephyr Memory Storage). It turns out that both lose data after the very first power loss in the wrong place, lol. So I wrote…
ST released three new families with the new HAL2 packs, so here's the port of the STM32C5, STM32G5 and STM32H7P plus BSPs for the two Nucleos I could get my hands on. The C5 is the funny one: no PLL at all, just the new PSI clock source.…
Our flash driver only knew F1, F4, G0, G4 and H7, all squashed into one template with %% if family everywhere, and its geometry was hand-written per family. So I surveyed the FLASH registers of all CMSIS headers (26 register signatures)…
I compared the hardware CI board list with our BSPs, and it turns out I own a bunch of boards that modm doesn't know about yet. So here they are, plus the three bugs that fell out while running all the examples on them. [x] NUCLEO-L4R5ZI…
The tree had no way to capture a parallel bus without loading the CPU: the GpioSampler uses interrupts and can only record pins through EXTI, so it cannot sample the same pin number on two ports at once, which is exactly what I2C and SPI…
I stress tested our heap allocators on the hardware CI and, well, they had some bugs. calloc(n, m) only allocated n bytes with the block and TLSF heaps (whoops), memalign wasn't wrapped at all, aligned new ignored the alignment everywhere,…
The STM32H5, H7R/S, U3 and U5 have the new linked-list DMA controllers (GPDMA, HPDMA, LPDMA) and modm had no DMA driver for them at all. This adds one with the same API as the old STM32 DMA driver, so the SPI DMA wrapper just works. Fixes…
Adds a driver for the Microchip USB3803, a 3-port high-speed USB 2.0 hub with battery charging and a bypass switch for mobile devices. The USB3803 has a sharp edge: its I2C serial port is only available from the release of RESET_N until…
The STM32H7R/S looks like an H7 on the outside, but it has its own RCC (CDCFGR/BMCFGR/APBCFGR prescalers, one PLL source for all PLLs, a write-once SMPS supply config) and a bunch of renamed peripherals, so it was ignored until now. I…
Plus a fix for flash aliased flash memory
Power-loss safe Zephyr Memory Storage (ZMS) on block devices; [fiber] Implement hosted fibers with threads
Add the NUCLEO-L4R5ZI, -U5A5ZJ-Q, -H7A3ZI-Q, -H7S3L8 and WeAct G030F6 boards; Flash driver for all STM32 families; Add STM32C5, STM32G5 and STM32H7P support with NUCLEO-C5A3ZG and NUCLEO-G564RE
Replace the TLSF and block heaps with the Zephyr heap and o1heap; Add a DMA logic analyzer for one to four GPIO ports
[driver] Add USB3803 USB 2.0 hub driver; Add a DMA driver for the STM32 GPDMA, HPDMA and LPDMA
The STM32H7R/S looks like an H7 on the outside, but it has its own RCC (CDCFGR/BMCFGR/APBCFGR prescalers, one PLL source for all PLLs, a write-once SMPS supply config) and a bunch of renamed peripherals, so it was ignored until now. I…
Plus a fix for flash aliased flash memory
This release covers everything from 2026-07-01 and has been tested with avr-gcc v14.2.0 from upstream and arm-none-eabi-gcc v14.2.1 from xpack. Breaking changes: modm::math::crc8_ccitt discarded the MSB of every input byte on non-AVR targets and now computes the correct CRC. This changes the AMNB header CRCs on the…
This release covers everything from 2026-04-19 and has been tested with avr-gcc v14.2.0 from upstream and arm-none-eabi-gcc v14.2.1 from xpack. Features: Support for watchdog timer on nRF51, nRF52 and nRF53 device families. Fixes: Fix GenericTimeout::wait() to wait while timer is armed. Reset fiber stop token on fiber…
This release covers everything from 2026-01-01 and has been tested with avr-gcc v14.2.0 from upstream and arm-none-eabi-gcc v14.2.1 from xpack. Breaking changes: The RCC APIs for STM32C0, F0, F1, F2, F3, F4, G0, L0 and U5 have been migrated to the new naming and configuration API. Existing clock setup code on these…
This release covers everything from 2025-10-01 and has been tested with avr-gcc v14.2.0 from upstream and arm-none-eabi-gcc v14.2.1 from xpack. Features: libeigen integration added. Support for precision() and width() added to IOStream. Integrated Projects: CMSIS Core upgraded from v6.1.0 to v6.2.0. Eigen added at…
This release covers everything from 2025-07-01 and has been tested with avr-gcc v14.2.0 from upstream and arm-none-eabi-gcc v14.2.1 from xpack. Breaking changes: Protothreads and Resumables are removed! They were announced as deprecated in 2024q4 and now all usage of them has been removed from modm's code base. The…
This release covers everything from 2025-04-01 and has been tested with avr-gcc v14.2.0 from upstream and arm-none-eabi-gcc v14.2.1 from xpack. Features: Support for GCC14. Support for 48 more STM32 devices. Integrated Projects: ETL upgraded from v20.39.4 to v20.40.0. FatFS upgraded from v0.15a to v0.15a_p1. JSON…
This release covers everything from 2025-01-01 and has been tested with avr-gcc v13.2.0 from upstream and arm-none-eabi-gcc v13.2.1 from xpack. Features: Add missing HSI48-related functionality for some STM32. Enable Cortex-M7 I/D-Cache via lbuild. Speed up startup copying and zeroing of data sections. Fixes: Fix…
This release covers everything from 2024-10-01 and has been tested with avr-gcc v13.2.0 from Upstream and arm-none-eabi-gcc v13.2.1 from xpack. Breaking changes: Protothreads and Resumables are deprecated! Please use Fibers instead! Note that you can disable the deprecation by resetting the option…
This release covers everything from 2024-07-01 and has been tested with avr-gcc v12.2.0 from Upstream and arm-none-eabi-gcc v12.2.1 from xpack. Breaking changes: Deprecate modm::allocator::Dynamic in favor of std::allocator. STM32 FDCAN queue mode is switched from queue to FIFO mode. Features: Add empty polyfill for…
This release covers everything from 2024-04-01 and has been tested with avr-gcc v12.2.0 from Upstream and arm-none-eabi-gcc v12.2.1 from xpack. Breaking changes: The STM32 UART peripheral moves the buffer configuration from lbuild to C++. Renames modm::fiber::yield() to modm::this_fiber::yield(). Renames…
No published opportunities
Each signal is normalized to 0–1 with fixed thresholds; scores are weighted sums × 100. Stars are not an input.