Why is my STM32 TIM16 interrupt speed not changing when I change the APB2DIV?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-02-16 7:49 PM
I'm building an elf file, SCPing it to the controller and using the fw_cortex_m4.sh to load it on the m4, but no matter what I set the APB2DIV scaler to the number of times per second TIM16 is called doesn't change.
The only thing that does seem to affect the frequency is the prescaler on the TIM16 pin, but I've already got it set to 0 and I only get about 1.4kH.
- Labels:
-
STM32MP15 Lines
-
TIM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-02-17 2:12 AM
APB2DIV is part of RCC and can influence more than just TIM16. The system is probavbly not configured to let the M4 do that.
hth
KnarfB
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-02-17 11:38 AM
Thanks for your answer, the problem turned out to be that I was counting the amount of times the ADC callback was hit not the timer counting.
