Skip to main content
rildank
Associate
Jul 27, 2020 3:03 PM UTC
Solved

STM32f417ig: Is it possible to set the TIM1 to a specific non-zero value when a trigger event occurs ?

Hello,

I'm using the STM32f417ig. I'm trying to configure TIM1 in a specific way, but I couldn't find information about this in the reference manual or on the web.

TIM1 is configured to be reset by a trigger event coming from TIM2 (slavemode set in the SMCR register). It is working well and the imter resets to 0 on a trigger event.

My question is : Is it possible to set the timer to a specific non-zero value when the trigger event occurs ?

Thanks for the help,

Ril

This topic has been closed for replies.
TDK
TDKBest answer
Jul 27, 2020 3:35 PM UTC

Not really. There might be a hook where you could set it via DMA but even then there would a bit of delay. You could handle reset manually but then you’d be introducing jitter and delay.

Might be another way to achieve what you’re trying to do.

"If you feel a post has answered your question, please click ""Accept as Solution""."

2 replies

TDK
TDKBest answer
Jul 27, 2020 3:35 PM UTC

Not really. There might be a hook where you could set it via DMA but even then there would a bit of delay. You could handle reset manually but then you’d be introducing jitter and delay.

Might be another way to achieve what you’re trying to do.

"If you feel a post has answered your question, please click ""Accept as Solution""."
rildank
rildankAuthor
Associate
Jul 29, 2020 8:28 AM UTC

Ok, thanks for answering!