Add Backlight and PowerSaveTimer

This commit is contained in:
Terrence
2025-03-05 09:37:13 +08:00
parent 3609aaa412
commit cead024698
61 changed files with 1331 additions and 3840 deletions

View File

@@ -820,3 +820,16 @@ void Application::WakeWordInvoke(const std::string& wake_word) {
});
}
}
bool Application::CanEnterSleepMode() {
if (device_state_ != kDeviceStateIdle) {
return false;
}
if (protocol_ && protocol_->IsAudioChannelOpened()) {
return false;
}
// Now it is safe to enter sleep mode
return true;
}