When using the HAL (Hardware Abstraction Library) for any of the STM32 micro controllers:
For a given peripheral, why do you have to call an HAL_…init() , as well as a HAL…_MspInit() – why are several 'inits' separated?
hal-librarymicrocontrollerprogrammingstm32stm32f3
When using the HAL (Hardware Abstraction Library) for any of the STM32 micro controllers:
For a given peripheral, why do you have to call an HAL_…init() , as well as a HAL…_MspInit() – why are several 'inits' separated?
Best Answer
The ST User Manual UM1725 - Description of STM32F4 HAL and LL drivers, see pages 61 - 63, gives an explanation:
(MSP: MCU Support Package)
and
2.12.2 HAL global initialization: