From fab220d0b9c6868b4fa96ce5f3e3f41b5454a0c7 Mon Sep 17 00:00:00 2001 From: JF Date: Sat, 13 Jun 2020 17:33:49 +0200 Subject: [PATCH] Fix idle timer bug that would prevent the screen from waking up. --- src/SystemTask/SystemTask.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/SystemTask/SystemTask.cpp b/src/SystemTask/SystemTask.cpp index b0f58d17..61b3c638 100644 --- a/src/SystemTask/SystemTask.cpp +++ b/src/SystemTask/SystemTask.cpp @@ -16,6 +16,8 @@ using namespace Pinetime::System; void IdleTimerCallback(TimerHandle_t xTimer) { + + NRF_LOG_INFO("IdleTimerCallback"); auto sysTask = static_cast(pvTimerGetTimerID(xTimer)); sysTask->OnIdle(); } @@ -113,6 +115,7 @@ void SystemTask::Work() { break; case Messages::GoToSleep: NRF_LOG_INFO("[SystemTask] Going to sleep"); + xTimerStop(idleTimer, 0); displayApp->PushMessage(Pinetime::Applications::DisplayApp::Messages::GoToSleep); isSleeping = true; break;