From 6dac0a62f4dfdb4b8b480aa03a3eb4ac08feebaa Mon Sep 17 00:00:00 2001 From: Riku Isokoski Date: Mon, 6 Sep 2021 11:59:54 +0300 Subject: [PATCH] Remove lcd from DisplayApp --- src/displayapp/DisplayApp.cpp | 2 -- src/drivers/St7789.h | 6 +++--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/src/displayapp/DisplayApp.cpp b/src/displayapp/DisplayApp.cpp index 32280615..bd5412ea 100644 --- a/src/displayapp/DisplayApp.cpp +++ b/src/displayapp/DisplayApp.cpp @@ -163,12 +163,10 @@ void DisplayApp::Refresh() { brightnessController.Lower(); vTaskDelay(100); } - lcd.DisplayOff(); PushMessageToSystemTask(Pinetime::System::Messages::OnDisplayTaskSleeping); state = States::Idle; break; case Messages::GoToRunning: - lcd.DisplayOn(); brightnessController.Restore(); state = States::Running; break; diff --git a/src/drivers/St7789.h b/src/drivers/St7789.h index a2f10447..8c2ac093 100644 --- a/src/drivers/St7789.h +++ b/src/drivers/St7789.h @@ -22,9 +22,6 @@ namespace Pinetime { void DrawBuffer(uint16_t x, uint16_t y, uint16_t width, uint16_t height, const uint8_t* data, size_t size); - void DisplayOn(); - void DisplayOff(); - void Sleep(); void Wakeup(); @@ -42,6 +39,9 @@ namespace Pinetime { void DisplayInversionOn(); void NormalModeOn(); void WriteToRam(); + void DisplayOn(); + void DisplayOff(); + void SetAddrWindow(uint16_t x0, uint16_t y0, uint16_t x1, uint16_t y1); void SetVdv(); void WriteCommand(uint8_t cmd);