Skip to main content
EKame.1
Associate
Dec 29, 2021 5:19 PM UTC
Question

Hi, I am using STM32WLE5CCU6 MCU and I am trying to enable RTC Wakeup Interrupt. I use HAL_NVIC_EnableIRQ(RTC_WKUP_IRQn) but seems like my code is stuck inside it. Any ideas what can be causing that?

..

This topic has been closed for replies.

9 replies

TDK
Dec 29, 2021 8:41 PM UTC

Sounds like it’s stuck in an IRQ handler. Make sure flags are cleared appropriately. Debug your code. Hit pause. See where it’s at.

"If you feel a post has answered your question, please click ""Accept as Solution""."
EKame.1
EKame.1Author
Associate
Dec 29, 2021 11:17 PM UTC

how is it stuck inside IRQ handler? I have printed some logs and It doesn't get out from this HAL_NVIC_EnableIRQ(RTC_WKUP_IRQn)

TDK
Dec 30, 2021 12:13 AM UTC
You enable an interrupt. Code doesn’t progress from that point. What other explanation would there be?
Debugging is likely to be more fruitful than guessing.
"If you feel a post has answered your question, please click ""Accept as Solution""."
Dana Myers
Senior
Dec 29, 2021 9:52 PM UTC

Do you have an ST/Link ? Relatively inexpensive. Highly recommended.

Dana K6JQ

EKame.1
EKame.1Author
Associate
Dec 29, 2021 11:18 PM UTC

yes I have it

Dana Myers
Senior
Dec 29, 2021 11:28 PM UTC

Have you tried running under the debugger, then halting to see what the MCU is doing when it's stuck?

Subramanya A
Associate II
Apr 4, 2023 3:22 PM UTC

Hi @EKame.1​ ,

Any update for aforementioned issue ? even I faced same issue [https://community.st.com/s/question/0D53W00002DAe0dSAD/stm32wl-rtc-hangs]

Thanks in Advance.