TIMx->PSC=16; has no effect. Can you please explain why? Is there any pre-condition to load the prescaler?
Prescaler gets effective only upon Update Event, see e.g. 2 mS timer immideately fires interrupt on a first run
also not working.
Then please tell us more: exactly what is the observed behaviour and how does it differ from the expected one.
Also read out and post the respective timer's registers' content.
Prescaler value is not updating. I've put code snippets here. Some bits like UDIS in CR1 along with PSC and ARR are not getting updated with atomic instruction like TIM21->CR1=0x02;
No, you want
Thanks for your reply. The code is working now. I've re-generated the whole code from STM32CubeMX with timer settings corrected after full deletion of the faulty project. Now everything is working fine. Thanks again.
Retrieving data ...