[stm32f0] Implement initial support for stm32f0#33
Merged
AlexLanzano merged 1 commit intowolfSSL:mainfrom Apr 22, 2026
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
Adds initial STM32F0 (STM32F091RC) platform support to wolfHAL, including a new board target and core peripheral drivers/aliases.
Changes:
- Introduce STM32F0 RCC, flash, UART, and WWDG implementations; reuse STM32WB implementations for GPIO/SPI/I2C/IWDG via alias headers/stubs.
- Add STM32F091RC Nucleo board support (startup/IVT, linker script, board init, Makefile).
- Extend existing STM32WB GPIO/SPI/I2C code to recognize STM32F0 API-mapping defines; add STM32F0 GPIO test alias and update board documentation.
Reviewed changes
Copilot reviewed 30 out of 30 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| wolfHAL/watchdog/stm32f0_wwdg.h | Declares STM32F0 WWDG config + API/driver symbol. |
| wolfHAL/watchdog/stm32f0_iwdg.h | Re-exports STM32WB IWDG API/types under STM32F0 names. |
| wolfHAL/uart/stm32f0_uart.h | Declares STM32F0 polled UART config + API/driver symbol. |
| wolfHAL/spi/stm32f0_spi.h | Re-exports STM32WB SPI API/types under STM32F0 names. |
| wolfHAL/platform/st/stm32f091xx.h | Provides STM32F091 peripheral regmap/clock-gate convenience macros. |
| wolfHAL/platform/arm/cortex_m0.h | Adds Cortex-M0 SysTick regmap/driver convenience macros. |
| wolfHAL/i2c/stm32f0_i2c.h | Re-exports STM32WB I2C API/types under STM32F0 names. |
| wolfHAL/gpio/stm32wb_gpio.h | Updates STM32WB GPIO header mapping conditions to include STM32F0. |
| wolfHAL/gpio/stm32f0_gpio.h | Re-exports STM32WB GPIO API/types/constants under STM32F0 names. |
| wolfHAL/flash/stm32f0_flash.h | Declares STM32F0 flash config + API/driver symbol and latency enum. |
| wolfHAL/clock/stm32f0_rcc.h | Declares STM32F0 RCC config structs/enums + API/driver symbol. |
| tests/gpio/test_stm32f0_gpio.c | Aliases STM32F0 GPIO platform test to STM32WB GPIO test. |
| src/watchdog/stm32f0_wwdg.c | Implements STM32F0 WWDG init/deinit/refresh + optional driver symbol. |
| src/watchdog/stm32f0_iwdg.c | Includes STM32WB IWDG implementation under STM32F0 build. |
| src/uart/stm32f0_uart.c | Implements STM32F0 polled UART init/deinit/send/recv (+ async stubs). |
| src/spi/stm32wb_spi.c | Extends mapping conditionals to support STM32F0 API-mapping define. |
| src/spi/stm32f0_spi.c | Includes STM32WB SPI implementation under STM32F0 build. |
| src/i2c/stm32wb_i2c.c | Extends mapping conditionals to support STM32F0 API-mapping define. |
| src/i2c/stm32f0_i2c.c | Includes STM32WB I2C implementation under STM32F0 build. |
| src/gpio/stm32wb_gpio.c | Extends mapping conditionals to support STM32F0 API-mapping define. |
| src/gpio/stm32f0_gpio.c | Includes STM32WB GPIO implementation under STM32F0 build. |
| src/flash/stm32f0_flash.c | Implements STM32F0 flash read/program/erase/lock/unlock + latency helper. |
| src/clock/stm32f0_rcc.c | Implements STM32F0 RCC clock-source selection, PLL config, clock gating. |
| boards/stm32f091rc_nucleo/linker.ld | Linker script for STM32F091RC (256K flash / 32K RAM). |
| boards/stm32f091rc_nucleo/ivt.c | Minimal startup + vector table for STM32F091RC. |
| boards/stm32f091rc_nucleo/board.h | Declares board globals, pins, flash layout, init helpers. |
| boards/stm32f091rc_nucleo/board.c | Board init/deinit wiring for clock/gpio/uart/spi/i2c/flash/systick. |
| boards/stm32f091rc_nucleo/Makefile.inc | Build flags/sources for STM32F091RC Nucleo board target. |
| boards/README.md | Adds STM32F091RC Nucleo to supported boards table. |
| .claude/skills/port-stm32-platform/SKILL.md | Documents test alias pattern + GPIO pin conflict check + README table note. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
9394d64 to
3d35466
Compare
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.