AnsweredAssumed Answered

Is stm32f4xx_gpio.c broken - missing BSRR register?

Question asked by darek.max on Mar 26, 2015
Latest reply on Mar 26, 2015 by Clive One

Dear All,
I am new to an  embedded world in general and to the STM32F4xx controllers in particular.  In order to learn the  trade, I got the STM32429I-Discovery board and along with the hardware, I have installed:

  •    emIDE development environment version 2.20
  • STM32F4xx DSP and Peripherals Library ver. 1.5.0 ( 06 March’15)
  • STM32Cube version 1.5.0
  • And other tools for flashing/monitoring  the board

I found an example in (which is not exactly for the Discovery board) :

added all (I hope) required  *.h , and *c files, and tried to build the binary.
The compiler failed to  produce a valid output,  and instead I got the following error message:

C:\Users\Work\STM32F4xx_DSP_StdPeriph_Lib\Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_gpio.c: In function 'GPIO_SetBits':

C:\Users\Work\STM32F4xx_DSP_StdPeriph_Lib\Libraries\STM32F4xx_StdPeriph_Driver\src\stm32f4xx_gpio.c:418:8: error: 'GPIO_TypeDef' has no member named 'BSRRL'

The gcc compiler includes the  file stm32f429xx.h where the ‘GIO_TypeDef’ is defined.

It seems that the stm32f4xx_gpio.c is broken because the whole file uses the old  register definition.

Extra compiler #defines:

  •   DEBUG=1
  •   USE_STM32F429_439xx
  •   STM32F429xx

 How to fix this issue ? Or maybe I did miss something ?

 Your help is highly appreciated.