I'm just reading about timers and they seem more sophisticated than I imagined.
One thing I'm not clear is whether we can assign a timer directly to a GPIO in some way other than through software.
I have a rudimentary app for the STM32F407G-DISC1 board that uses TIM2 in interrupt mode, in the handler I toggle pin PD15 and I can see on the scope a (slightly unstable) square wave - as I expect.
I've got that toggling at around 24.6 KHz (using some trial and error values in the prescaler and period settings).
Is there a way though to tell the timer to simply "drive" a GPIO directly without the need to have a handler and interrupts etc.
I'd imagine that the frequency of such a signal could then be higher and its stability greater.
Thanks
One thing I'm not clear is whether we can assign a timer directly to a GPIO in some way other than through software.
I have a rudimentary app for the STM32F407G-DISC1 board that uses TIM2 in interrupt mode, in the handler I toggle pin PD15 and I can see on the scope a (slightly unstable) square wave - as I expect.
I've got that toggling at around 24.6 KHz (using some trial and error values in the prescaler and period settings).
Is there a way though to tell the timer to simply "drive" a GPIO directly without the need to have a handler and interrupts etc.
I'd imagine that the frequency of such a signal could then be higher and its stability greater.
Thanks