From abfa6b89f72ee09fc453a3b20dace577778d1534 Mon Sep 17 00:00:00 2001 From: Sjef Verhoeven PE5PVB Date: Tue, 24 Oct 2023 15:31:13 +0200 Subject: [PATCH] RDS error indicators are now always written, to prevent wrong values --- TEF6686_ESP32.ino | 4 ---- src/gui.cpp | 4 ---- src/gui.h | 4 ---- src/rds.cpp | 23 ++++------------------- src/rds.h | 4 ---- 5 files changed, 4 insertions(+), 35 deletions(-) diff --git a/TEF6686_ESP32.ino b/TEF6686_ESP32.ino index fca18cd..585329a 100644 --- a/TEF6686_ESP32.ino +++ b/TEF6686_ESP32.ino @@ -61,10 +61,6 @@ bool direction; bool dropout; bool dynamicPTYold; bool edgebeep; -bool errorAold; -bool errorBold; -bool errorCold; -bool errorDold; bool externaltune; bool fullsearchrds; bool hasafold; diff --git a/src/gui.cpp b/src/gui.cpp index 3b065aa..8cc48ad 100644 --- a/src/gui.cpp +++ b/src/gui.cpp @@ -699,10 +699,6 @@ void BuildAdvancedRDS() { TAold = false; TPold = false; hastmcold = false; - errorAold = true; - errorBold = true; - errorCold = true; - errorDold = true; dynamicPTYold = false; artheadold = false; compressedold = false; diff --git a/src/gui.h b/src/gui.h index a5086e4..67c6f38 100644 --- a/src/gui.h +++ b/src/gui.h @@ -37,10 +37,6 @@ extern bool change; extern bool compressedold; extern bool dynamicPTYold; extern bool edgebeep; -extern bool errorAold; -extern bool errorBold; -extern bool errorCold; -extern bool errorDold; extern bool hasafold; extern bool haseonold; extern bool hasrtplusold; diff --git a/src/rds.cpp b/src/rds.cpp index cb14a56..033179b 100644 --- a/src/rds.cpp +++ b/src/rds.cpp @@ -4,25 +4,10 @@ #include void ShowAdvancedRDS() { - if (radio.rds.rdsAerror != errorAold || rdsreset) { - if (radio.rds.rdsAerror) tft.fillCircle(86, 41, 5, SignificantColor); else tft.fillCircle(86, 41, 5, InsignificantColor); - errorAold = radio.rds.rdsAerror; - } - - if (radio.rds.rdsBerror != errorBold || rdsreset) { - if (radio.rds.rdsBerror) tft.fillCircle(124, 41, 5, SignificantColor); else tft.fillCircle(124, 41, 5, InsignificantColor); - errorBold = radio.rds.rdsBerror; - } - - if (radio.rds.rdsCerror != errorCold || rdsreset) { - if (radio.rds.rdsCerror) tft.fillCircle(162, 41, 5, SignificantColor); else tft.fillCircle(162, 41, 5, InsignificantColor); - errorCold = radio.rds.rdsCerror; - } - - if (radio.rds.rdsDerror != errorDold || rdsreset) { - if (radio.rds.rdsDerror) tft.fillCircle(200, 41, 5, SignificantColor); else tft.fillCircle(200, 41, 5, InsignificantColor); - errorDold = radio.rds.rdsDerror; - } + if (radio.rds.rdsAerror) tft.fillCircle(86, 41, 5, SignificantColor); else tft.fillCircle(86, 41, 5, InsignificantColor); + if (radio.rds.rdsBerror) tft.fillCircle(124, 41, 5, SignificantColor); else tft.fillCircle(124, 41, 5, InsignificantColor); + if (radio.rds.rdsCerror) tft.fillCircle(162, 41, 5, SignificantColor); else tft.fillCircle(162, 41, 5, InsignificantColor); + if (radio.rds.rdsDerror) tft.fillCircle(200, 41, 5, SignificantColor); else tft.fillCircle(200, 41, 5, InsignificantColor); if (radio.rds.hasDynamicPTY != dynamicPTYold) { if (radio.rds.hasDynamicPTY) tft.fillCircle(310, 137, 5, InsignificantColor); else tft.fillCircle(310, 137, 5, SignificantColor); diff --git a/src/rds.h b/src/rds.h index 56cc5aa..a9566e4 100644 --- a/src/rds.h +++ b/src/rds.h @@ -17,10 +17,6 @@ extern bool compressedold; extern bool clearrds; extern bool dropout; extern bool dynamicPTYold; -extern bool errorAold; -extern bool errorBold; -extern bool errorCold; -extern bool errorDold; extern bool fullsearchrds; extern bool hasafold; extern bool haseonold;