Show "sleeping" on eink while in deep sleep

This commit is contained in:
Kevin Hester
2020-11-13 07:49:01 +08:00
parent 67e657f10f
commit 93afc71e2e
3 changed files with 47 additions and 7 deletions

View File

@@ -99,6 +99,12 @@ class Screen : public concurrency::OSThread
enqueueCmd(ScreenCmd{.cmd = on ? Cmd::SET_ON : Cmd::SET_OFF});
}
/**
* Prepare the display for the unit going to the lowest power mode possible. Most screens will just
* poweroff, but eink screens will show a "I'm sleeping" graphic, possibly with a QR code
*/
void doDeepSleep();
/// Handles a button press.
void onPress() { enqueueCmd(ScreenCmd{.cmd = Cmd::ON_PRESS}); }