HAL library 1.5- GPIO for STM32Fxxx

GPIO library is second mainly used library in your project. It is designed to be very easily used for initializing GPIO pins without making sure if clock is enabled or not because this will library do for you.

It can init pin as normal or alternate with passing alternate function, it can deinit pin to set it as analog input, it can read pin, set pin and more.


Read more about new HAL libraries


  • Initialize pins with single function clock,
  • Initialize pins as alternate,
  • Deinitialize pin,
  • Fast set pull resistors,
  • Read GPIO pin,
  • Set GPIO pin,


  • HAL
    • GPIO
  • TM
    • STM32Fxxx HAL
    • defines.h

Functions and enumerations


For this library is example not shown because GPIO lib is used everywhere. In future libs you will be able to see example of using this library.


Owner of this site. Application engineer, currently employed by STMicroelectronics. Exploring latest technologies and owner of different libraries posted on Github.

You may also like...