From 6da612caa94cb39d2e0afede340cc8f2dc231882 Mon Sep 17 00:00:00 2001 From: Ruffalo Lavoisier Date: Fri, 22 Nov 2024 00:07:19 +0900 Subject: [PATCH] Demo: add test notification test feature --- src/services/OswServiceTaskConsole.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/services/OswServiceTaskConsole.cpp b/src/services/OswServiceTaskConsole.cpp index a0956b023..62b7bcea3 100644 --- a/src/services/OswServiceTaskConsole.cpp +++ b/src/services/OswServiceTaskConsole.cpp @@ -126,6 +126,10 @@ void OswServiceTaskConsole::runPrompt() { NotifierClient notify("osw.console"); notify.showToast(toast); #endif + // Test + } else if (this->m_inputBuffer.find("notify ") == 0 and this->m_inputBuffer.length() > 7) { + auto value = this->m_inputBuffer.substr(7); + OswUI::getInstance()->showNotification(value, false); } else if (this->m_inputBuffer == "time") { Serial.println(OswHal::getInstance()->getUTCTime()); } else if (this->m_inputBuffer == "wipe") {