[stm32wb0] Add support for the stm32wb0. Add stm32wb0 nucleo board#45
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
Adds STM32WB0 platform support and a NUCLEO-WB05KZ board to wolfHAL. Most peripherals (UART/SPI/I2C/IWDG/DMA/PKA) are exposed as alias headers + thin wrapper source files that compile the existing STM32WB drivers under WB0-prefixed config macros. GPIO, RNG, Flash, and RCC get dedicated WB0 implementations because the hardware diverges (1 MB GPIO port stride, 16-bit RNG_VAL with 32-bit-only access, command-based flash controller, BLE-oriented RCC). The board is also added to the CI matrix.
Changes:
- New STM32WB0 alias headers/sources mapping WB0 symbols and
WHAL_CFG_STM32WB0_*macros onto the STM32WB driver implementations, plus extension of the WB headers' single-instance/direct-API-mapping conditionals to include WB0. - New dedicated WB0 drivers: GPIO (1 MB port stride), RNG, Flash (command-based), and an RCC helper header; new platform header
stm32wb05kz.hcentralizing base addresses and clock-gate descriptors. - New
stm32wb05kz_nucleoboard (board.c/board.h/board.mk/ivt.c/linker.ld), README entry, and CI matrix update.
Reviewed changes
Copilot reviewed 31 out of 31 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| wolfHAL/watchdog/stm32wb0_iwdg.h | WB0 IWDG alias header (typedef + symbol macros to STM32WB IWDG). |
| wolfHAL/uart/stm32wb0_uart.h | WB0 UART alias header re-exporting STM32WB UART symbols. |
| wolfHAL/uart/stm32wb_uart.h | Adds WB0 to single-instance / direct-API-mapping conditionals. |
| wolfHAL/spi/stm32wb0_spi.h | WB0 SPI alias header re-exporting STM32WB SPI symbols. |
| wolfHAL/spi/stm32wb_spi.h | Adds WB0 to single-instance / direct-API-mapping conditionals. |
| wolfHAL/i2c/stm32wb0_i2c.h | WB0 I2C alias header re-exporting STM32WB I2C symbols. |
| wolfHAL/i2c/stm32wb_i2c.h | Adds WB0 to single-instance conditional. |
| wolfHAL/dma/stm32wb0_dma.h | WB0 DMA alias header (typedef + symbol macros to STM32WB DMA). |
| wolfHAL/dma/stm32wb_dma.h | Adds WB0 to single-instance / direct-API-mapping conditionals. |
| wolfHAL/crypto/stm32wb0_pka.h | WB0 PKA alias header re-exporting STM32WB PKA symbols. |
| wolfHAL/rng/stm32wb0_rng.h | Dedicated WB0 RNG driver API + config struct. |
| wolfHAL/gpio/stm32wb0_gpio.h | Dedicated WB0 GPIO driver API with 1 MB port stride encoding. |
| wolfHAL/flash/stm32wb0_flash.h | Dedicated WB0 flash driver API (command-based controller). |
| wolfHAL/clock/stm32wb0_rcc.h | New WB0 RCC helper inline functions and register definitions. |
| wolfHAL/platform/st/stm32wb05kz.h | WB05KZ platform header: base addresses + RCC clock descriptors. |
| src/watchdog/stm32wb0_iwdg.c | Thin wrapper that re-includes the STM32WB IWDG source under WB0 macros. |
| src/uart/stm32wb0_uart.c | Thin wrapper that re-includes the STM32WB UART source under WB0 macros. |
| src/spi/stm32wb0_spi.c | Thin wrapper that re-includes the STM32WB SPI source under WB0 macros. |
| src/i2c/stm32wb0_i2c.c | Thin wrapper that re-includes the STM32WB I2C source under WB0 macros. |
| src/dma/stm32wb0_dma.c | Thin wrapper that re-includes the STM32WB DMA source under WB0 macros. |
| src/crypto/stm32wb0_pka.c | Thin wrapper that re-includes the STM32WB PKA source under WB0 macros. |
| src/gpio/stm32wb0_gpio.c | Dedicated WB0 GPIO driver implementation with 1 MB port stride. |
| src/rng/stm32wb0_rng.c | Dedicated WB0 RNG driver implementation. |
| src/flash/stm32wb0_flash.c | Dedicated WB0 flash driver implementation. |
| boards/stm32wb05kz_nucleo/board.h | Board pinout, peripheral device initializers, BOARD_* macros. |
| boards/stm32wb05kz_nucleo/board.c | Board clock bring-up and Init/Deinit sequence. |
| boards/stm32wb05kz_nucleo/ivt.c | Cortex-M0+ vector table and reset handler. |
| boards/stm32wb05kz_nucleo/linker.ld | Linker script for STM32WB05KZ flash/SRAM layout. |
| boards/stm32wb05kz_nucleo/board.mk | Board build rules, direct-API-mapping flags, and OpenOCD flash target. |
| boards/README.md | Adds the NUCLEO-WB05KZ entry to the supported boards table. |
| .github/workflows/boards.yml | Adds stm32wb05kz_nucleo to the CI board matrix. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.