2025-03-11 9:15 PM
Hello STM support,
It seems that the depiction of the TIM15 TPCLK on the clock configuration tab of STM32Cube incorrectly shows TPCLK as 2x16MHz=32MHz when should be 16MHz, same as PCLK.
I found this issue after setting TIM15 as shown in the attached screenshot. The resulting clock configuration should trigger the IRQ every 1 second, however I measured 2 seconds between each trigger. Recalculating the prescaler and counter period for a 16MHz clock yields the correct behavior.
Figure 11 in RM0503 also seems to show that there is no 2x multiplication from PCLK to TIMPCLK. Is this an error in STM32Cube or something I am misinterpreting? My selected MCU reference in my ioc file is STM32U031R8Tx.
2025-03-12 4:43 AM - edited 2025-03-12 4:45 AM
Hello @yichen15922,
This issue was spotted recently in this post: Solved: Re: STM32U0 timer clocks x2 - STMicroelectronics Community
As already mentioned, the RM needs to be updated (tracked internally), when the PCLK is too low the TIMPCLK is set higher as shown in the STM32CubeMX screenshot:
Hope that helps!
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.