- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
My application uses HIDoff to save power and wakes up from one of several GPIO interrupts.
Is there any way to tell which line generated the interrupt that cause the wakeup?
Is there a way to tell whether the wakeup was due to an interrupt, or due to some other cause (such as powerup)?
Solved! Go to Solution.
- Labels:
-
GPIO
-
Sleep Modes
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Try to use gpio_getPinInterruptStatus() or gpio_getPortInterruptStatus().
If it is a timed wake up, the mia_isResetReasonPor() will return false and gpio_getPinInterruptStatus(GPIO_PIN_P39/16, GPIO_PIN_P39%16) will return 1.
Otherwise, the wake up source should be some other GPIO (it mia_isResetReasonPor() return false).
gpio_getPinInterruptStatus() or gpio_getPortInterruptStatus should indicate the pin number.
Hope it helps.