AF screen will now also refresh when Method B is detected

This commit is contained in:
Sjef Verhoeven PE5PVB
2023-10-12 15:13:40 +02:00
parent c0780d3b4d
commit e16ffedbdc
3 changed files with 5 additions and 1 deletions
+2
View File
@@ -46,6 +46,7 @@ TFT_eSPI tft = TFT_eSPI(240, 320);
bool advancedRDS; bool advancedRDS;
bool af; bool af;
bool afmethodBold;
bool afpage; bool afpage;
bool afscreen; bool afscreen;
bool aftest; bool aftest;
@@ -2266,6 +2267,7 @@ void ShowFreq(int mode) {
rdsreset = true; rdsreset = true;
licold = 254; licold = 254;
ECCold = 253; ECCold = 253;
afmethodBold = false;
if (wifi) { if (wifi) {
Udp.beginPacket(remoteip, 9030); Udp.beginPacket(remoteip, 9030);
+2 -1
View File
@@ -832,7 +832,7 @@ void ShowAFEON() {
afpagenr = 0; afpagenr = 0;
} }
if (af_counterold != radio.af_counter) { if (af_counterold != radio.af_counter || radio.afmethodB != afmethodBold) {
tft.fillRect(2, 48, 166, 150, BackgroundColor); tft.fillRect(2, 48, 166, 150, BackgroundColor);
for (byte i = 0; i < radio.af_counter; i++) { for (byte i = 0; i < radio.af_counter; i++) {
byte x = i - (afpagenr == 2 ? 30 : 0); byte x = i - (afpagenr == 2 ? 30 : 0);
@@ -851,6 +851,7 @@ void ShowAFEON() {
if (afpage && !screenmute) tftPrint(1, String(afpagenr) + "/2", 315, 222, SecondaryColor, SecondaryColorSmooth, 16); if (afpage && !screenmute) tftPrint(1, String(afpagenr) + "/2", 315, 222, SecondaryColor, SecondaryColorSmooth, 16);
} }
af_counterold = radio.af_counter; af_counterold = radio.af_counter;
afmethodBold = radio.afmethodB;
} }
if (radio.rds.hasEON) { if (radio.rds.hasEON) {
+1
View File
@@ -8,6 +8,7 @@
#include <WiFi.h> #include <WiFi.h>
extern bool advancedRDS; extern bool advancedRDS;
extern bool afmethodBold;
extern bool afpage; extern bool afpage;
extern bool afscreen; extern bool afscreen;
extern bool aftest; extern bool aftest;