Bugfix on RDS error meter. When tuning fast, one bar was still on the screen

This commit is contained in:
Sjef Verhoeven PE5PVB
2024-02-12 00:08:18 +01:00
parent 94c347bccb
commit 58502a4e8b
2 changed files with 4 additions and 1 deletions

View File

@@ -2527,6 +2527,7 @@ void ShowFreq(int mode) {
attachInterrupt(digitalPinToInterrupt(ROTARY_PIN_B), read_encoder, CHANGE); attachInterrupt(digitalPinToInterrupt(ROTARY_PIN_B), read_encoder, CHANGE);
rdsreset = true; rdsreset = true;
RDSstatus = false;
licold = 254; licold = 254;
ECCold = 253; ECCold = 253;
afmethodBold = false; afmethodBold = false;

View File

@@ -448,6 +448,7 @@ void readRds() {
void ShowErrors() { void ShowErrors() {
uint8_t calc = 4; uint8_t calc = 4;
if (RDSstatus) {
if (!radio.rds.rdsAerror) calc--; if (!radio.rds.rdsAerror) calc--;
if (!radio.rds.rdsBerror) calc--; if (!radio.rds.rdsBerror) calc--;
if (!radio.rds.rdsCerror) calc--; if (!radio.rds.rdsCerror) calc--;
@@ -455,7 +456,8 @@ void ShowErrors() {
SAvg3 = (((SAvg3 * 9) + 5) / 10) + calc; SAvg3 = (((SAvg3 * 9) + 5) / 10) + calc;
calc = SAvg3 / 10; calc = SAvg3 / 10;
if (!RDSstatus) calc = 4; }
if (calc != rdsqualityold || BWreset) { if (calc != rdsqualityold || BWreset) {
switch (calc) { switch (calc) {
case 0: case 0: