Skip to main content
arnold_w
Senior II
September 18, 2018
Solved

Possible to trigger timer events from software on STM32F4?

  • September 18, 2018
  • 3 replies
  • 1403 views

I am working with the STM32F4 family. External interrupts have a register called EXTI->SWIER that makes it possible to generate external interrupt from software. Do the timers have something similar, a register that I can use to generate timer interrupts in software?

    This topic has been closed for replies.
    Best answer by waclawek.jan

    TIMx_EGR

    JW

    3 replies

    waclawek.jan
    waclawek.janBest answer
    Super User
    September 18, 2018

    TIMx_EGR

    JW

    arnold_w
    arnold_wAuthor
    Senior II
    September 18, 2018

    Thanks!

    Khouloud GARSI
    ST Employee
    September 18, 2018

    Hi @arnold_w​ ,

    Correct you have to use the TIMx_EGR as suggested by Jan.

    Just do not forget to enable the interrupt in TIMx_DIER register.

    Khouloud.