Small change in DX mode scan detector
This commit is contained in:
+21
-21
@@ -803,6 +803,27 @@ void loop() {
|
|||||||
if (digitalRead(BANDBUTTON) == LOW ) BANDBUTTONPress();
|
if (digitalRead(BANDBUTTON) == LOW ) BANDBUTTONPress();
|
||||||
|
|
||||||
if (scandxmode) {
|
if (scandxmode) {
|
||||||
|
if (millis() >= scantimer + (scanhold * 1000)) {
|
||||||
|
if (scanmem) {
|
||||||
|
memorypos++;
|
||||||
|
if (memorypos > scanstop) memorypos = scanstart;
|
||||||
|
while (IsStationEmpty() || presets[memorypos].band != BAND_FM) {
|
||||||
|
memorypos++;
|
||||||
|
if (memorypos > scanstop) {
|
||||||
|
memorypos = scanstart;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
DoMemoryPosTune();
|
||||||
|
ShowMemoryPos();
|
||||||
|
} else {
|
||||||
|
TuneUp();
|
||||||
|
ShowFreq(0);
|
||||||
|
if (XDRGTKUSB || XDRGTKTCP) DataPrint("T" + String((frequency + ConverterSet * 100) * 10) + "\n");
|
||||||
|
}
|
||||||
|
scantimer = millis();
|
||||||
|
}
|
||||||
|
|
||||||
if (millis() >= flashingtimer + 500) {
|
if (millis() >= flashingtimer + 500) {
|
||||||
flashing = !flashing;
|
flashing = !flashing;
|
||||||
if (flashing) {
|
if (flashing) {
|
||||||
@@ -830,27 +851,6 @@ void loop() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (scandxmode && millis() >= scantimer + (scanhold * 1000)) {
|
|
||||||
if (scanmem) {
|
|
||||||
memorypos++;
|
|
||||||
if (memorypos > scanstop) memorypos = scanstart;
|
|
||||||
while (IsStationEmpty() || presets[memorypos].band != BAND_FM) {
|
|
||||||
memorypos++;
|
|
||||||
if (memorypos > scanstop) {
|
|
||||||
memorypos = scanstart;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
DoMemoryPosTune();
|
|
||||||
ShowMemoryPos();
|
|
||||||
} else {
|
|
||||||
TuneUp();
|
|
||||||
ShowFreq(0);
|
|
||||||
if (XDRGTKUSB || XDRGTKTCP) DataPrint("T" + String((frequency + ConverterSet * 100) * 10) + "\n");
|
|
||||||
}
|
|
||||||
scantimer = millis();
|
|
||||||
}
|
|
||||||
|
|
||||||
if (millis() >= tuningtimer + 200) {
|
if (millis() >= tuningtimer + 200) {
|
||||||
if (store) {
|
if (store) {
|
||||||
detachInterrupt(digitalPinToInterrupt(ROTARY_PIN_A));
|
detachInterrupt(digitalPinToInterrupt(ROTARY_PIN_A));
|
||||||
|
|||||||
Reference in New Issue
Block a user