AnsweredAssumed Answered

help with timers

Question asked by giuseppe.scarpi on Apr 15, 2015
Latest reply on Apr 21, 2015 by giuseppe.scarpi
I just created this simple project for an STM32F429 discovery board:

1) TIM1 is configured to produce a square waves on OC2 (PA9)
2) TIM2 is configured to use the ETR pin as clock source (PA5)
3) USB periodically sends a message with the value of TIM2.CNT

By connecting PA9 and PA5 I would expect to see TIM2.CNT increasing, but this is not the case.
I checked PA9 with a logic state analyser, and the expected output is there. So the problem is in the configuration of the input.
I used STM32CubeMX to create the configuration, and everything seems ok.
The registers of TIM2 are:
- in SMCR, SMS = 0b111 and TS = 0b111. According to the manual this sets ETR as clock source
- in CR1, CEN = 1
Every other register is 0.

Can someone help me in finding my error?

I am experimenting a discovery board with F429.