Hello @Vignesh_V ,
If the WFI instruction is used to enter Sleep mode, any peripheral interrupt acknowledged by the nested vectored interrupt controller (NVIC) can wake up the device from Sleep mode.
I recommend you to get inspired from these examples to configure your own project:
- PWR_SLEEP for STM32F1 device and PWR_CurrentConsumption for STM32F407 device: These examples explain how to enter the Sleep mode and wake up from this mode by using an interrupt.
- How to configure the RTC to wake up the STM32 periodically from Low Power modes: This FAQ descripts how to configure the RTC peripheral of the STM32 to wake up the STM32 periodically from a low power mode.
I hope this help you.
Kaouthar
To give better visibility on the answered topics, please click on "Best answer" on the reply which solved your issue or answered your question.