Skip to main content
Visitor II
August 3, 2021
Question

STM32F407 software trigger a one pulse timer using HAL library

  • August 3, 2021
  • 2 replies
  • 774 views

Hello,

I have a question about STM32F407.

I was wondering how to software trigger (not external trigger) a "one pulse" timer, using HAL library?

Thanks for the help.

    This topic has been closed for replies.

    2 replies

    Super User
    August 3, 2021

    After having set up timer for the one-pulse mode (i.e. set TIMx_CR1.OPM), simply write 1 to TIMx_CR1.CEN.

    I don't know if there's a Cube/HAL incantation for it; Cube/HAL is open source, you can look it up yourself.

    JW

    Super User
    August 3, 2021

    __HAL_TIM_ENABLE(htimx);