Board Support
Zenbedded currently ships with three Tier-1 targets. Each board provides:
- a linker script in
src/bsp/<board>/memory.ld - a console backend under
src/board/console/<board>.zig .misetasks for cross builds and Renode simulations
STM32F4 Discovery (stm32f4-discovery)
- MCU: STM32F407VG (Cortex-M4F @ 168 MHz)
- Flash: 1 MB, RAM: 192 KB
- Console: USART1 routed to the ST-Link VCOM bridge
- Notes: Linker script places the vector table at
0x08000000; Renode description lives upstream so we reuse the bundled board file.
STM32F103 “Blue Pill” (stm32f103-bluepill)
- MCU: STM32F103C8T6 (Cortex-M3 @ 72 MHz)
- Flash: 64 KB, RAM: 20 KB
- Console: USART1 via GPIO A9/A10; requires an external USB-TTL or ST-Link
- Notes: Our
gpioPortAwrites only touch MODE bits to keep Renode logs clean.
nRF52840 DK (nrf52840-dk)
- MCU: nRF52840 (Cortex-M4F @ 64 MHz)
- Flash: 1 MB, RAM: 256 KB
- Console: UART0 mapped to P0.06 (USB CDC on the DK)
- Notes: EasyDMA is disabled in the Renode CPU description to avoid unimplemented register warnings.
ST7789 Display Peripheral
- Driver lives in
src/drivers/st7789.zigand uses the common SPI/pin contracts. - All SPI transfers are bounded (
MAX_TRANSFER_SIZE) and command sequences are declared at compile time. - Tests rely on the SPI/pin test doubles to verify exact byte streams without hardware.
Adding New Boards
- Create a linker script under
src/bsp/<board>/memory.ld. - Implement a console backend that exposes
banner,init,writeByte. - Extend
build.zigwith the new board metadata (exe_name, CPU model, linker path). - Vendor appropriate Renode
.replfiles and add build/sim tasks to.mise.toml. - Update the GitHub Actions workflow matrix so CI exercises the new target.
- Document the board here (flash/RAM, console details, special considerations).
- Keep Renode logs warning-free; if the simulator surfaces noise, stub or adjust until silence is restored.