Hard Fault inside a RTC_Alarm_IRQ_Handler
- November 28, 2022
- 3 replies
- 2034 views
Hello,
I'm dealing with a problem in a STM32WB55, but the doubt is general about STM32 and FreeRTOS.
Among the different tasks initialised in my program, I have a task running that puts the MCU in STOP2 mode. In parallel there is an RTC Alarm programmed every 30 seconds, with a higher priority than the FreeRTOS one. When the MCU is in stop mode (inside the task mentioned before) and the RTC Alarm Handler jumps, sometimes I get a Hard Fault.
The question is, could it be a problem related to the task stack memory? I've read about it, and when there is a system interruption (independent of the FreeRTOS), the RAM utilisation is taken from the memory reserved to the main initialisation, is it true? Should I increase the stack size of any task?
Thank you in advance.
