Question
Best practice for waking STM32 from STOP mode via multiple GPIO interrupts?
I'm working on a battery-powered sensor node using an STM32L4 series MCU. I need to wake from STOP2 mode on either of two GPIO interrupts (button press or external sensor trigger) and want to identify which one triggered the wake before running my main loop.
What's the recommended way to configure and distinguish the wake source cleanly — checking EXTI pending register flags right after wake, or is there a better pattern people use for this?
