Skip to main content
Wissem Chouchene
Visitor II
November 18, 2018
Solved

about enabling peripheral in STM32CubeMx

  • November 18, 2018
  • 1 reply
  • 671 views

When enabling a peripheral in STM32CubeMx (switch from disable to enable) Does this mean that its clock wil be activated in the program after generating the initialization code for a given IDE 

and we don't need to insert the   __HAL_RCC_peripheral_CLK_ENABLE() function ? 

thank you 

Wissem

This topic has been closed for replies.
Best answer by After Forever

Yes, STM32CubeMX's code generator takes care of that.

<grumpy mode>

You could have easily checked it yourself in a minute by enabling a peripheral and observing the generated code, but I guess it's easier to ask :)

</grumpy mode>

1 reply

After Forever
Senior III
November 19, 2018

Yes, STM32CubeMX's code generator takes care of that.

<grumpy mode>

You could have easily checked it yourself in a minute by enabling a peripheral and observing the generated code, but I guess it's easier to ask :)

</grumpy mode>