Google Summer of Code | Improving the STM32F4 BSP (#86)
Atharv Dubey (@atharvdubey101)
gitlab at rtems.org
Thu Mar 20 15:12:58 UTC 2025
Atharv Dubey created an issue: https://gitlab.rtems.org/rtems/programs/gsoc/-/issues/86
## Background
The STM32F4 BSP in RTEMS currently supports RCC, USART, and I2C, which is just enough to run RTEMS on the board. However, it lacks support for GPIO, SPI, and DMA, limiting its functionality.
This project aims to expand the STM32F4 BSP by adding support for these peripherals. The goal is to implement basic GPIO configuration, SPI communication, and DMA transfers, making the BSP more useful for real applications.
The implementation will take inspiration from the STM32H7 BSP and use HAL and LL drivers as a backend to keep it maintainable and aligned with other STM32 BSPs.
## Approach
1. **GPIO Support**: The STM32F4 BSP currently provides a GPIO driver in the bsp/io.h header. Adding a configuration option to enable the HAL layer would be beneficial, as it eliminates the need to work directly with register definitions. A generic GPIO interface with essential functionalities such as set_pin, get_pin, read_pin, and set_pin_exti, along with proper status code returns, would greatly improve usability within the STM32F4XX Boards.
2. **SPI Support**: RTEMS provides SPI support across various BSPs, such as arm/stm32h7 and BeagleBoard platforms, which serve as excellent references. Implementing SPI functionality for the STM32F4 BSP can be guided by the existing STM32H7 support and insights from Chapter 28 of the [RM0090 reference manual](https://www.st.com/resource/en/reference_manual/dm00031020-stm32f405-415-stm32f407-417-stm32f427-437-and-stm32f429-439-advanced-arm-based-32-bit-mcus-stmicroelectronics.pdf).
3. **DMA Support**: The STM32F4 series includes a dual-channel DMA controller (DMA1 and DMA2), with 8 independent streams and 8 channels per streams supporting peripherals like SPI,I2C.This task would involve setting up a proper generic BSP API for data transfer,Direction,Size,Stream,channels and interupt handling.
## Knowledge/Skills
* C, assembly
* Hardware-level debugging
## Possible Mentors
--
View it on GitLab: https://gitlab.rtems.org/rtems/programs/gsoc/-/issues/86
You're receiving this email because of your account on gitlab.rtems.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/bugs/attachments/20250320/12cb6569/attachment-0001.htm>
More information about the bugs
mailing list