MCU Testing & CI
STM32H7 digital twin CI for H743 & H747
Run 480 MHz STM32H7 binaries on NUCLEO-H743ZI2, Arduino Portenta H7 and Arduino GIGA R1 twins—with 7 of 8 board-dashboard suites passing.
STM32H7 devices introduce domain power gating (D1/D2/D3), FDCAN message RAM layouts and MPU cache-region rules that break quietly when memory attributes or peripheral clocks are misconfigured. Checking the exact compiled H7 ELF on a twin catches these faults on every commit.
All three H7 boards in board-dashboard.json (NUCLEO-H743ZI2, Arduino GIGA R1, Arduino Portenta H7) pass all four Zephyr L1 boot suites (blinky, hello_world, philosophers, shell) plus ARMv7E-M FPv5-D16 CPU differential checks.
STM32H7 target coverage
| Target | Dashboard suites passing | Highlights |
|---|---|---|
nucleo-h743zi2 | 7 / 8 | STM32H743 HAL TIM oracle + 4/4 Zephyr L1 boots |
arduino-portenta-h7 | 7 / 8 | Dual-core STM32H747 industrial carrier |
arduino-giga-r1 | 7 / 8 | STM32H747 Cortex-M7 + M4 board |
Pixhawk 6C (PX4) | Showcase | PX4 v1.16.2 autopilot ELF + 6 attached sensor twins |
Local CLI workflow
Shell — run STM32H743 binary
ct run --json --board nucleo-h743zi2 --timeout-ms 4000 build/h743_app.elf
ct test run --json --recheck tests/h7-fdcan.suite.yamlSuite & fault configuration
tests/h7-fdcan.suite.yaml
version: 1
board: nucleo-h743zi2
firmware: build/h743_app.elf
tests:
- name: fdcan-nominal-and-data-phase
timeout_ms: 3000
expect:
console_contains: "FDCAN_TX_OK"
exit_code: 0
- name: spi-barometer-frozen-reading
faults:
- at_ms: 200
part: bmp388
kind: frozen_reading
expect:
console_contains: "BARO_STALE_FLAG"CI pipeline integration
.github/workflows/stm32h7.yml
name: STM32H7 CI
on: [push, pull_request]
jobs:
h743:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: west build -b nucleo_h743zi app/
- uses: circuittwin/action@v1
with:
board: nucleo-h743zi2
firmware: build/zephyr/zephyr.elf
suite: tests/h7-fdcan.suite.yamlTroubleshooting checklist
| Symptom | Fix |
|---|---|
| Boot loops in SystemClock_Config() waiting on VOSRDY | Confirm PWR_CR3 supply config (LDO vs SMPS) matches your board wiring (NUCLEO-H743ZI2 uses LDO). |
| FDCAN frames rejected or wrong bitrate | Verify FDCAN kernel clock (PLL1Q / PLL2Q) and NBTP register bits with the CAN Bit Timing Calculator. |
| DMA reads stale zeros from DTCM | On STM32H7, DMA1/DMA2 cannot access DTCM (0x20000000); place DMA buffers in AXI SRAM (0x24000000) or SRAM1/2. |
| Exit code 4 on unmodelled cache/RNG register | Read the JSON diagnostic PC and offset; verify whether the peripheral is required for the test path. |