cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F4 standard peripheral libraries and a CubeMX HAL project

Alexander Hoffman
Associate III
Posted on August 13, 2017 at 18:25

Hi all,

I am not the most skilled when it comes to putting projects together with various libraries. So this entire area is a steep learning curve for me. I am trying to get a FreeRTOS project for the stm32F429i-DISC1 board going using CubeMX to generate the basic FreeRTOS project code then I am hoping to use the uGFX library as I have worked with it a lot in the past.

After generating a ''generic'' FreeRTOS project through Cube and adding in all the necessary uGFX libraries I can get uGFX to compile, with one small error. It looks for the header stm32f429i_discovery_lcd.h which I believe is part of the standard peripheral libraries. As such I started again, this time just trying to get a FreeRTOS project to compile whilst including the standard peripheral libraries for the stm32f429i discovery board.

I downloaded the STM32F429 discovery firmware package from here 

http://www.st.com/en/evaluation-tools/32f429idiscovery.html

 and have then included the following directories in my project 0690X00000607eaQAA.png

This seems leads me to many errors similar to ''Description Resource Path Location Type

conflicting types for 'DMA_InitTypeDef' stm32f4xx_dma.h /DiscWRTOSWugfx/Libraries/STM32F429I-Discovery/Libraries/STM32F4xx_StdPeriph_Driver/inc line 110 C/C++ Problem'' where there is obvious clashes between the HAL libraries and the standard peripheral libraries. So my biggest question/s is, how does one integrate the two libraries or if that is not possible how would one generate an RTOS project for the discovery board using the standard peripheral libraries?

Or somewhere I can go to read up on this topic? I have not been able to find anything.

Thank you in advance

#rtos #standard-peripheral-library #cube-mx #hal
1 REPLY 1
Amel NASRI
ST Employee
Posted on August 15, 2017 at 15:02

Hi

Hoffman.Alexande

‌,

SPL & HAL are 2 different libraries to be used seprately for STM

So, you cannot use SPL with CubeMX generated code which is based on HAL.

To use FreeRTOS with STM32F429, you can start from CubeMX and generate your project after enabling RTOS.

http://www.st.com/content/ccc/resource/technical/document/user_manual/10/c5/1a/43/3a/70/43/7d/DM001047pdf/files/DM001047pdf/jcr:content/translations/en.DM001047pdf

provides some guidelines.

As a second choice, you have the ready to use example:STM32Cube_FW_F4_V1.0\Projects\STM32F429I-Discovery\Applications\FreeRTOS.

-Amel

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.