From ed9ef19d38e046f4df017886ad4eecd665bff3dc Mon Sep 17 00:00:00 2001 From: Sjef Verhoeven PE5PVB Date: Thu, 26 Oct 2023 10:49:49 +0200 Subject: [PATCH] Fixed time display in AF screen and old time was sometimes displayed too. --- TEF6686_ESP32.ino | 2 +- src/rds.cpp | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/TEF6686_ESP32.ino b/TEF6686_ESP32.ino index 9ddab71..d6f0e87 100644 --- a/TEF6686_ESP32.ino +++ b/TEF6686_ESP32.ino @@ -953,7 +953,7 @@ void loop() { } void GetData() { - showCT(); + if (!afscreen) showCT(); if (band < BAND_GAP) ShowStereoStatus(); if (band < BAND_GAP && !menu) { if (advancedRDS && !afscreen && !screenmute) ShowAdvancedRDS(); diff --git a/src/rds.cpp b/src/rds.cpp index 4e321ef..2582bde 100644 --- a/src/rds.cpp +++ b/src/rds.cpp @@ -480,7 +480,13 @@ void showCT() { if (rtcset) { if (advancedRDS) tftReplace(1, rds_clockold, rds_clock, 205, 109, SecondaryColor, SecondaryColorSmooth, 16); else tftReplace(1, rds_clockold, rds_clock, 205, 163, SecondaryColor, SecondaryColorSmooth, 16); } else { - if (advancedRDS) tftPrint(1, rds_clock, 205, 109, BackgroundColor, BackgroundColor, 16); else tftPrint(1, rds_clock, 205, 163, BackgroundColor, BackgroundColor, 16); + if (advancedRDS) { + tftPrint(1, rds_clockold, 205, 109, BackgroundColor, BackgroundColor, 16); + tftPrint(1, rds_clock, 205, 109, BackgroundColor, BackgroundColor, 16); + } else { + tftPrint(1, rds_clockold, 205, 163, BackgroundColor, BackgroundColor, 16); + tftPrint(1, rds_clock, 205, 163, BackgroundColor, BackgroundColor, 16); + } } } }