Blue-out AF/EON/RT+ ticker on RDS loss
This commit is contained in:
+1
-6
@@ -256,13 +256,11 @@ int8_t CNold;
|
|||||||
int8_t VolSet;
|
int8_t VolSet;
|
||||||
float batteryVold;
|
float batteryVold;
|
||||||
IPAddress remoteip;
|
IPAddress remoteip;
|
||||||
String afstringold;
|
|
||||||
String AIDString;
|
String AIDString;
|
||||||
String cryptedpassword;
|
String cryptedpassword;
|
||||||
String CurrentThemeString;
|
String CurrentThemeString;
|
||||||
String ECColdtxt;
|
String ECColdtxt;
|
||||||
String eonpsold[20];
|
String eonpsold[20];
|
||||||
String eonstringold;
|
|
||||||
String LIColdString;
|
String LIColdString;
|
||||||
String pinstringold;
|
String pinstringold;
|
||||||
String PIold;
|
String PIold;
|
||||||
@@ -274,7 +272,6 @@ String rds_clockold;
|
|||||||
String RDSSPYRDS;
|
String RDSSPYRDS;
|
||||||
String RDSSPYRDSold;
|
String RDSSPYRDSold;
|
||||||
String RTold;
|
String RTold;
|
||||||
String rtplusstringold;
|
|
||||||
String salt;
|
String salt;
|
||||||
String saltkey = " ";
|
String saltkey = " ";
|
||||||
String stationIDold;
|
String stationIDold;
|
||||||
@@ -2348,9 +2345,7 @@ void ShowFreq(int mode) {
|
|||||||
}
|
}
|
||||||
attachInterrupt(digitalPinToInterrupt(ROTARY_PIN_A), read_encoder, CHANGE);
|
attachInterrupt(digitalPinToInterrupt(ROTARY_PIN_A), read_encoder, CHANGE);
|
||||||
attachInterrupt(digitalPinToInterrupt(ROTARY_PIN_B), read_encoder, CHANGE);
|
attachInterrupt(digitalPinToInterrupt(ROTARY_PIN_B), read_encoder, CHANGE);
|
||||||
rtplusstringold = "";
|
|
||||||
eonstringold = "";
|
|
||||||
afstringold = "";
|
|
||||||
rdsreset = true;
|
rdsreset = true;
|
||||||
licold = 254;
|
licold = 254;
|
||||||
ECCold = 253;
|
ECCold = 253;
|
||||||
|
|||||||
@@ -710,9 +710,6 @@ void BuildAdvancedRDS() {
|
|||||||
BWreset = true;
|
BWreset = true;
|
||||||
pinstringold = "";
|
pinstringold = "";
|
||||||
hasrtplusold = false;
|
hasrtplusold = false;
|
||||||
eonstringold = "";
|
|
||||||
afstringold = "";
|
|
||||||
rtplusstringold = "";
|
|
||||||
afmethodBold = false;
|
afmethodBold = false;
|
||||||
rds_clockold = "";
|
rds_clockold = "";
|
||||||
ShowMemoryPos();
|
ShowMemoryPos();
|
||||||
|
|||||||
@@ -145,16 +145,13 @@ extern int16_t SStatus;
|
|||||||
extern int8_t LevelOffset;
|
extern int8_t LevelOffset;
|
||||||
extern int8_t LowLevelSet;
|
extern int8_t LowLevelSet;
|
||||||
extern int8_t VolSet;
|
extern int8_t VolSet;
|
||||||
extern String afstringold;
|
|
||||||
extern String CurrentThemeString;
|
extern String CurrentThemeString;
|
||||||
extern String eonpsold[20];
|
extern String eonpsold[20];
|
||||||
extern String eonstringold;
|
|
||||||
extern String PIold;
|
extern String PIold;
|
||||||
extern String pinstringold;
|
extern String pinstringold;
|
||||||
extern String PSold;
|
extern String PSold;
|
||||||
extern String ptynold;
|
extern String ptynold;
|
||||||
extern String rds_clockold;
|
extern String rds_clockold;
|
||||||
extern String rtplusstringold;
|
|
||||||
extern String stationIDold;
|
extern String stationIDold;
|
||||||
extern String stationStateold;
|
extern String stationStateold;
|
||||||
extern String XDRGTK_key;
|
extern String XDRGTK_key;
|
||||||
|
|||||||
+39
-69
@@ -69,34 +69,23 @@ void ShowAdvancedRDS() {
|
|||||||
hasafold = radio.rds.hasAF;
|
hasafold = radio.rds.hasAF;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (afstring.length() < 20) {
|
if (millis() - afticker >= 15) {
|
||||||
if (afstringold != afstring) {
|
if (xPos2 == 0) {
|
||||||
xPos2 = 0;
|
if (millis() - aftickerhold >= 2000) {
|
||||||
RDSSprite.fillSprite(BackgroundColor);
|
|
||||||
RDSSprite.setTextColor(PrimaryColor, PrimaryColorSmooth, false);
|
|
||||||
RDSSprite.drawString(afstring, xPos2, 2);
|
|
||||||
RDSSprite.pushSprite(35, 197);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
if (millis() - afticker >= 15) {
|
|
||||||
if (xPos2 == 0) {
|
|
||||||
if (millis() - aftickerhold >= 2000) {
|
|
||||||
xPos2 --;
|
|
||||||
aftickerhold = millis();
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
xPos2 --;
|
xPos2 --;
|
||||||
aftickerhold = millis();
|
aftickerhold = millis();
|
||||||
}
|
}
|
||||||
if (xPos2 < -tft.textWidth(afstring) + (charWidth * 14)) xPos2 = 0;
|
} else {
|
||||||
RDSSprite.fillSprite(BackgroundColor);
|
xPos2 --;
|
||||||
RDSSprite.setTextColor(PrimaryColor, PrimaryColorSmooth, false);
|
aftickerhold = millis();
|
||||||
RDSSprite.drawString(afstring, xPos2, 2);
|
|
||||||
RDSSprite.pushSprite(35, 197);
|
|
||||||
afticker = millis();
|
|
||||||
}
|
}
|
||||||
|
if (xPos2 < -tft.textWidth(afstring) + (charWidth * 14)) xPos2 = 0;
|
||||||
|
RDSSprite.fillSprite(BackgroundColor);
|
||||||
|
if (RDSstatus) RDSSprite.setTextColor(PrimaryColor, PrimaryColorSmooth, false); else RDSSprite.setTextColor(SecondaryColor, SecondaryColorSmooth, false);
|
||||||
|
RDSSprite.drawString(afstring, xPos2, 2);
|
||||||
|
RDSSprite.pushSprite(35, 197);
|
||||||
|
afticker = millis();
|
||||||
}
|
}
|
||||||
afstringold = afstring;
|
|
||||||
|
|
||||||
String eonstring;
|
String eonstring;
|
||||||
if (radio.rds.hasEON) for (byte i = 0; i < radio.eon_counter; i++) eonstring += String(radio.eon[i].picode) + (radio.eon[i].ps.length() > 0 ? String(": " + String(radio.eon[i].ps)) : "") + (radio.eon[i].mappedfreq > 0 ? String(" " + String(radio.eon[i].mappedfreq / 100) + "." + String((radio.eon[i].mappedfreq % 100) / 10)) : "") + (radio.eon[i].mappedfreq2 > 0 ? String(" / " + String(radio.eon[i].mappedfreq2 / 100) + "." + String((radio.eon[i].mappedfreq2 % 100) / 10)) : "") + (radio.eon[i].mappedfreq3 > 0 ? String(" / " + String(radio.eon[i].mappedfreq3 / 100) + "." + String((radio.eon[i].mappedfreq3 % 100) / 10)) : "") + (i == radio.eon_counter - 1 ? " " : " | "); else eonstring = myLanguage[language][88];
|
if (radio.rds.hasEON) for (byte i = 0; i < radio.eon_counter; i++) eonstring += String(radio.eon[i].picode) + (radio.eon[i].ps.length() > 0 ? String(": " + String(radio.eon[i].ps)) : "") + (radio.eon[i].mappedfreq > 0 ? String(" " + String(radio.eon[i].mappedfreq / 100) + "." + String((radio.eon[i].mappedfreq % 100) / 10)) : "") + (radio.eon[i].mappedfreq2 > 0 ? String(" / " + String(radio.eon[i].mappedfreq2 / 100) + "." + String((radio.eon[i].mappedfreq2 % 100) / 10)) : "") + (radio.eon[i].mappedfreq3 > 0 ? String(" / " + String(radio.eon[i].mappedfreq3 / 100) + "." + String((radio.eon[i].mappedfreq3 % 100) / 10)) : "") + (i == radio.eon_counter - 1 ? " " : " | "); else eonstring = myLanguage[language][88];
|
||||||
@@ -106,34 +95,25 @@ void ShowAdvancedRDS() {
|
|||||||
}
|
}
|
||||||
haseonold = radio.rds.hasEON;
|
haseonold = radio.rds.hasEON;
|
||||||
}
|
}
|
||||||
if (eonstring.length() < 20) {
|
|
||||||
if (eonstringold != eonstring) {
|
if (millis() - eonticker >= 15) {
|
||||||
xPos3 = 0;
|
if (xPos3 == 0) {
|
||||||
RDSSprite.fillSprite(BackgroundColor);
|
if (millis() - eontickerhold >= 2000) {
|
||||||
RDSSprite.setTextColor(PrimaryColor, PrimaryColorSmooth, false);
|
|
||||||
RDSSprite.drawString(eonstring, xPos3, 2);
|
|
||||||
RDSSprite.pushSprite(35, 172);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
if (millis() - eonticker >= 15) {
|
|
||||||
if (xPos3 == 0) {
|
|
||||||
if (millis() - eontickerhold >= 2000) {
|
|
||||||
xPos3 --;
|
|
||||||
eontickerhold = millis();
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
xPos3 --;
|
xPos3 --;
|
||||||
eontickerhold = millis();
|
eontickerhold = millis();
|
||||||
}
|
}
|
||||||
if (xPos3 < -tft.textWidth(eonstring) + (charWidth * 14)) xPos3 = 0;
|
} else {
|
||||||
RDSSprite.fillSprite(BackgroundColor);
|
xPos3 --;
|
||||||
RDSSprite.setTextColor(PrimaryColor, PrimaryColorSmooth, false);
|
eontickerhold = millis();
|
||||||
RDSSprite.drawString(eonstring, xPos3, 2);
|
|
||||||
RDSSprite.pushSprite(35, 172);
|
|
||||||
eonticker = millis();
|
|
||||||
}
|
}
|
||||||
|
if (xPos3 < -tft.textWidth(eonstring) + (charWidth * 14)) xPos3 = 0;
|
||||||
|
RDSSprite.fillSprite(BackgroundColor);
|
||||||
|
if (RDSstatus) RDSSprite.setTextColor(PrimaryColor, PrimaryColorSmooth, false); else RDSSprite.setTextColor(SecondaryColor, SecondaryColorSmooth, false);
|
||||||
|
RDSSprite.drawString(eonstring, xPos3, 2);
|
||||||
|
RDSSprite.pushSprite(35, 172);
|
||||||
|
eonticker = millis();
|
||||||
}
|
}
|
||||||
eonstringold = eonstring;
|
|
||||||
|
|
||||||
String rtplusstring;
|
String rtplusstring;
|
||||||
if (radio.rds.hasRDSplus) rtplusstring = (radio.rds.rdsplusTag1 != 169 ? String(myLanguage[language][radio.rds.rdsplusTag1]) + ": " + String(radio.rds.RTContent1) : "") + (radio.rds.rdsplusTag2 != 169 ? " - " + String(myLanguage[language][radio.rds.rdsplusTag2]) + ": " + String(radio.rds.RTContent2) : "") + " "; else rtplusstring = myLanguage[language][89];
|
if (radio.rds.hasRDSplus) rtplusstring = (radio.rds.rdsplusTag1 != 169 ? String(myLanguage[language][radio.rds.rdsplusTag1]) + ": " + String(radio.rds.RTContent1) : "") + (radio.rds.rdsplusTag2 != 169 ? " - " + String(myLanguage[language][radio.rds.rdsplusTag2]) + ": " + String(radio.rds.RTContent2) : "") + " "; else rtplusstring = myLanguage[language][89];
|
||||||
@@ -143,34 +123,24 @@ void ShowAdvancedRDS() {
|
|||||||
}
|
}
|
||||||
hasrtplusold = radio.rds.hasRDSplus;
|
hasrtplusold = radio.rds.hasRDSplus;
|
||||||
}
|
}
|
||||||
if (rtplusstring.length() < 20) {
|
|
||||||
if (rtplusstringold != rtplusstring) {
|
if (millis() - rtplusticker >= 15) {
|
||||||
xPos4 = 0;
|
if (xPos4 == 0) {
|
||||||
RDSSprite.fillSprite(BackgroundColor);
|
if (millis() - rtplustickerhold >= 2000) {
|
||||||
RDSSprite.setTextColor(PrimaryColor, PrimaryColorSmooth, false);
|
|
||||||
RDSSprite.drawString(rtplusstring, xPos4, 2);
|
|
||||||
RDSSprite.pushSprite(35, 146);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
if (millis() - rtplusticker >= 15) {
|
|
||||||
if (xPos4 == 0) {
|
|
||||||
if (millis() - rtplustickerhold >= 2000) {
|
|
||||||
xPos4 --;
|
|
||||||
rtplustickerhold = millis();
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
xPos4 --;
|
xPos4 --;
|
||||||
rtplustickerhold = millis();
|
rtplustickerhold = millis();
|
||||||
}
|
}
|
||||||
if (xPos4 < -tft.textWidth(rtplusstring) + (charWidth * 14)) xPos4 = 0;
|
} else {
|
||||||
RDSSprite.fillSprite(BackgroundColor);
|
xPos4 --;
|
||||||
RDSSprite.setTextColor(PrimaryColor, PrimaryColorSmooth, false);
|
rtplustickerhold = millis();
|
||||||
RDSSprite.drawString(rtplusstring, xPos4, 2);
|
|
||||||
RDSSprite.pushSprite(35, 146);
|
|
||||||
rtplusticker = millis();
|
|
||||||
}
|
}
|
||||||
|
if (xPos4 < -tft.textWidth(rtplusstring) + (charWidth * 14)) xPos4 = 0;
|
||||||
|
RDSSprite.fillSprite(BackgroundColor);
|
||||||
|
if (RDSstatus) RDSSprite.setTextColor(PrimaryColor, PrimaryColorSmooth, false); else RDSSprite.setTextColor(SecondaryColor, SecondaryColorSmooth, false);
|
||||||
|
RDSSprite.drawString(rtplusstring, xPos4, 2);
|
||||||
|
RDSSprite.pushSprite(35, 146);
|
||||||
|
rtplusticker = millis();
|
||||||
}
|
}
|
||||||
rtplusstringold = rtplusstring;
|
|
||||||
|
|
||||||
if (TPold != radio.rds.hasTP) {
|
if (TPold != radio.rds.hasTP) {
|
||||||
if (!screenmute) {
|
if (!screenmute) {
|
||||||
|
|||||||
@@ -71,11 +71,9 @@ extern int xPos2;
|
|||||||
extern int xPos3;
|
extern int xPos3;
|
||||||
extern int xPos4;
|
extern int xPos4;
|
||||||
extern IPAddress remoteip;
|
extern IPAddress remoteip;
|
||||||
extern String afstringold;
|
|
||||||
extern String AIDString;
|
extern String AIDString;
|
||||||
extern String ECColdtxt;
|
extern String ECColdtxt;
|
||||||
extern String eonpsold[20];
|
extern String eonpsold[20];
|
||||||
extern String eonstringold;
|
|
||||||
extern String LIColdString;
|
extern String LIColdString;
|
||||||
extern String pinstringold;
|
extern String pinstringold;
|
||||||
extern String PIold;
|
extern String PIold;
|
||||||
@@ -87,7 +85,6 @@ extern String rds_clockold;
|
|||||||
extern String RDSSPYRDS;
|
extern String RDSSPYRDS;
|
||||||
extern String RDSSPYRDSold;
|
extern String RDSSPYRDSold;
|
||||||
extern String RTold;
|
extern String RTold;
|
||||||
extern String rtplusstringold;
|
|
||||||
extern String stationIDold;
|
extern String stationIDold;
|
||||||
extern String stationStateold;
|
extern String stationStateold;
|
||||||
extern String XDRGTKRDS;
|
extern String XDRGTKRDS;
|
||||||
|
|||||||
Reference in New Issue
Block a user