Electron using SLEEP_NETWORK_STANDBY and SLEEP_DISABLE_WKP_PIN

Hi All,

I'm trying to figure out how to use SLEEP_NETWORK_STANDBY and SLEEP_DISABLE_WKP_PIN with Deep Sleep - electron with 1.2.0 -beta

Using this:

System.sleep(SLEEP_MODE_DEEP, 300, SLEEP_DISABLE_WKP_PIN, SLEEP_NETWORK_STANDBY);

Or this:

System.sleep(SLEEP_MODE_DEEP, 300, SLEEP_NETWORK_STANDBY, SLEEP_DISABLE_WKP_PIN);

doesn't seem to work. Is there something that I'm missing? Seems like the first one should work.

I'm trying to stop an external watchdog from waking my electron with a rising edge on the WKP pin. The watchdog gets pet every time the firmware runs, and it wakes frequently enough to pet the watchdog without the WKP - BTW the watchdog will use the RST pin to reset the electron if the watchdog is not pet.

You can try “ORing” the flags

 System.sleep(SLEEP_MODE_DEEP, 300, SLEEP_DISABLE_WKP_PIN | SLEEP_NETWORK_STANDBY);

Cool, didn't know about that, will try!