Periodic Timing on STM32: WKUP Interrupt vs. RTC ALARM A Mask
Hi,
I want to use the RTC timer on the STM32WB to run FreeRTOS in both normal and STOP modes (For HAL time base I use Systick). When the MCU has no work, it goes into STOP mode. If the MCU needs to wake up for timing, like from a FreeRTOS timer, I set the RTC ALARM A to wake it up. When the processor is running, it needs to tick for FreeRTOS every 1 ms.
My question is, should I use the WKUP (wake-up periodic interrupt) to tick every 1 ms, or set ALARM A with a mask for periodic timing like this:
LL_RTC_ALMA_SetMask(RTC, LL_RTC_ALMA_MASK_ALL);
LL_RTC_ALMA_SetSubSecondMask(RTC, 3);Which option is better? Or is there a downside to one of them?
It looks to me that every option is possible.
Best regards Jan
