Remove test code
This commit is contained in:
parent
640e8cd1fe
commit
6491a7c3a0
|
@ -1,5 +1,5 @@
|
|||
cmake_minimum_required(VERSION 3.10)
|
||||
project(pinetime VERSION 0.2.99 LANGUAGES C CXX ASM)
|
||||
project(pinetime VERSION 0.2.1 LANGUAGES C CXX ASM)
|
||||
|
||||
set(NRF_TARGET "nrf52")
|
||||
|
||||
|
|
|
@ -26,8 +26,7 @@ DisplayApp::DisplayApp(Pinetime::Drivers::St7789& lcd,
|
|||
batteryController{batteryController},
|
||||
bleController{bleController},
|
||||
dateTimeController{dateTimeController},
|
||||
clockScreen{gfx},
|
||||
messageScreen{gfx} {
|
||||
clockScreen{gfx} {
|
||||
msgQueue = xQueueCreate(queueSize, itemSize);
|
||||
currentScreen = &clockScreen;
|
||||
}
|
||||
|
@ -61,25 +60,6 @@ uint32_t acc = 0;
|
|||
uint32_t count = 0;
|
||||
bool toggle = true;
|
||||
void DisplayApp::Refresh() {
|
||||
#if 0
|
||||
uint32_t before = nrf_rtc_counter_get(portNRF_RTC_REG);
|
||||
if(toggle) {
|
||||
gfx.FillRectangle(0,0,240,240,0x0000);
|
||||
} else {
|
||||
gfx.FillRectangle(0,0,240,240,0xffff);
|
||||
}
|
||||
uint32_t after = nrf_rtc_counter_get(portNRF_RTC_REG);
|
||||
|
||||
acc += (after - before);
|
||||
if((count % 10) == 0) {
|
||||
NRF_LOG_INFO("DRAW : %d ms", (uint32_t)(acc/10));
|
||||
acc = 0;
|
||||
}
|
||||
count++;
|
||||
toggle = !toggle;
|
||||
#endif
|
||||
|
||||
#if 1
|
||||
TickType_t queueTimeout;
|
||||
switch (state) {
|
||||
case States::Idle:
|
||||
|
@ -130,29 +110,16 @@ void DisplayApp::Refresh() {
|
|||
break;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
void DisplayApp::RunningState() {
|
||||
clockScreen.SetCurrentDateTime(dateTimeController.CurrentDateTime());
|
||||
|
||||
// if(currentScreen != nullptr) {
|
||||
// currentScreen->Refresh(false);
|
||||
// }
|
||||
|
||||
if(currentScreen != nullptr) {
|
||||
currentScreen->Refresh(true);
|
||||
currentScreen->Refresh(false);
|
||||
}
|
||||
|
||||
if(screenState) {
|
||||
currentScreen = &clockScreen;
|
||||
} else {
|
||||
currentScreen = &messageScreen;
|
||||
}
|
||||
screenState = !screenState;
|
||||
}
|
||||
|
||||
|
||||
void DisplayApp::IdleState() {
|
||||
|
||||
}
|
||||
|
|
|
@ -59,8 +59,6 @@ namespace Pinetime {
|
|||
|
||||
Screens::Clock clockScreen;
|
||||
Screens::Screen* currentScreen = nullptr;
|
||||
Screens::Message messageScreen;
|
||||
bool screenState = false;
|
||||
static constexpr uint8_t pinLcdBacklight1 = 14;
|
||||
static constexpr uint8_t pinLcdBacklight2 = 22;
|
||||
static constexpr uint8_t pinLcdBacklight3 = 23;
|
||||
|
|
|
@ -8452,15 +8452,15 @@
|
|||
// <e> NRF_LOG_ENABLED - nrf_log - Logger
|
||||
//==========================================================
|
||||
#ifndef NRF_LOG_ENABLED
|
||||
#define NRF_LOG_ENABLED 1
|
||||
#define NRF_LOG_ENABLED 0
|
||||
#endif
|
||||
|
||||
#ifndef NRF_LOG_BACKEND_RTT_ENABLED
|
||||
#define NRF_LOG_BACKEND_RTT_ENABLED 1
|
||||
#define NRF_LOG_BACKEND_RTT_ENABLED 0
|
||||
#endif
|
||||
|
||||
#ifndef NRF_LOG_BACKEND_SERIAL_USES_RTT
|
||||
#define NRF_LOG_BACKEND_SERIAL_USES_RTT 1
|
||||
#define NRF_LOG_BACKEND_SERIAL_USES_RTT 0
|
||||
#endif
|
||||
// <h> Log message pool - Configuration of log message pool
|
||||
|
||||
|
|
Loading…
Reference in a new issue