2008-07-30 06:20 PM
x1, x2 multiplier before TIM2 to TIM7?
2011-05-17 03:40 AM
Looking at the STM32 Clock Tree I have SYSCLK=72 MHz. The APB1 Prescaler is set to /2 sending a 36 MHz PCLK1 to APB1 peripherals.
That same 36 MHz clocks TIM2 to TIM7. That’s what I thought until TIM3 setup to make a 1 KHz interrupt actually made a 2 KHz interrupt. Then I saw something - - there is a x1, x2 multiplier between my 36 MHz APB1 clock and the timers. What register does one set to specify x1 or x2? There is an equivalent x1, x2 multiplier before timer 1 and timer 8. I suspect the docs for both controls are tucked away where I can’t find them. I have looked. Silicon Valley ST support sent my request for documentation “back through Technical support� whatever that means. Does someone here know where thicontrol is?2011-05-17 03:40 AM
Hi Picguy,
See attached Figure from datasheet. This is fixed by hardware internally if the APP prescaler is <> 1 then the Timer clock is multiplied by x2. I believe that no control is provided to software. Regards, Magigimix.2011-05-17 03:40 AM
Thanks, I had an old clock tree diagram.