cancel
Showing results for 
Search instead for 
Did you mean: 

Issue with Stop Mode 2 on STM32WLE using EXTI + RTC Alarm + SPI

Eldryad
Visitor

Hi everyone,
I’m working on an application using an STM32WLE where the main loop is task-based, and Sub-GHz communication is handled through a message system. I’m currently trying to implement Stop Mode 2 to reduce power consumption.

Scenario:

  • Upon receiving a specific command, the device must enter Stop Mode 2.

  • Wake-up should occur only via an EXTI on a WakeUp Pin (GPIO).

  • At the same time, I have:

    • An active RTC Alarm used for Sub-GHz events and software timers.

    • SPI IRQ Handler (which shares the same IRQ with EXTI) for receiving SPI data.

Issue:

  • If I don’t disable the RTC Alarm before entering stop mode, the MCU wakes up immediately.

  • However, if I disable the RTC Alarm, the device stays in stop mode, but after wake-up:

    • The power consumption is higher than before entering Stop Mode.

    • The SPI communication stops working properly.

Questions:

  1. Is it correct to disable the RTC Alarm before entering Stop Mode 2? Is there a better way to handle wake-up without RTC interfering?

  2. After wake-up, which peripherals should I reinitialize to restore SPI communication and bring power consumption back to normal?

  3. Do I need to perform a full re-initialization of the Sub-GHz/SPI stack after waking up from Stop Mode 2?

Thanks in advance for any advice!

0 REPLIES 0