Skip to main content
CTabo.1
Senior
May 6, 2024 12:06 PM UTC
Solved

Enabling timer compare interrupt only on rising edges or falling edges

Hello,
I have programmed one of the advanced timers in up/down mode and I have used one of the compare units to generate a PWM signal.

I would also like to generate an interrupt on compare events, but only on the falling edges.
Is it possible to specify the edge directon when enabling the compare event interrupt?
Or I have to distingush the edge direction only after the interrupt has been triggered on compare event, by checking the counter direction?

Thank you,
Carlo

 

This topic has been closed for replies.
waclawek.jan
waclawek.janBest answer
Super User
May 6, 2024 5:32 PM UTC

> Is it possible to specify the edge directon when enabling the compare event interrupt?

 

waclawekjan_0-1715016721699.png

JW

2 replies

waclawek.jan
waclawek.janBest answer
Super User
May 6, 2024 5:32 PM UTC

> Is it possible to specify the edge directon when enabling the compare event interrupt?

 

waclawekjan_0-1715016721699.png

JW

CTabo.1
CTabo.1Author
Senior
May 7, 2024 7:36 AM UTC

Thank you very much!

Regards,
Carlo