CAF: Latch register for all button GPIOS are set when wakeup from deep sleep by single button press, making it impossible to know which button that did the wakeup

I used the Common Application Framework preview sample, with the following additions at end of prj.conf:

# Power management
CONFIG_PM_POLICY_APP=y
CONFIG_CAF_POWER_MANAGER=y
CONFIG_CAF_POWER_MANAGER_TIMEOUT=10
CONFIG_CAF_BUTTONS_PM_EVENTS=y
CONFIG_CAF_LEDS_PM_EVENTS=y

NCS 1.9.1 was used

The nrf52840dk then enters deep sleep after 10 seconds.

When I then perform a button wakeup, by clicking one of the DK buttons, then the GPIO LATCH bits for all 4 buttons are set.

I would expect that only the LATCH bit is set corresponding to the button that was pressed.

Since the LATCH bit is set for all four buttons, this makes it impossible to see the cause of wakeup.

Could this be a bug in the CAF Buttons module?

BTW: This issue was discovered when looking at the case in devzone.nordicsemi.com/.../how-to-detect-gpio-interrupt-source-from-deep-sleep , but using CAF and ncs instead

Parents Reply Children
Related