PWM configuration with CubeMx
Hello,
I'm working with an STM32F401RE (on a Nucleo), and I have some problem with the TIMER frequency.
a) The frequency APBx is 84Mhz, and I want a 500Hz PWM frequency on TIM3.
I set prescaler to 167 (168-1) and period to 999 (1000-1), is it correct ?
b) I also want a 500uS interrupt from TIM1 and i set prescaler to 0 and period to 41999 (42000-1), is it correct ?
In both case the frequency isn't the expected value (checked with oscilloscope), so I was wondering if it's my fault of that is due to the accuracy of the internal oscillator.
Thanks
Riccardo
