ADR display

This commit is contained in:
Klaus K Wilting 2018-05-21 20:35:33 +02:00
parent 7b8367fa4a
commit 92cc55a36a
2 changed files with 9 additions and 3 deletions

View File

@ -153,7 +153,8 @@ Note: all settings are stored in NVRAM and will be reloaded when device starts.
0 = ADR off 0 = ADR off
1 = ADR on [default] 1 = ADR on [default]
note: set ADR to off, if device is moving, set to on, if not. Note: set ADR to off, if device is moving, set to on, if not.
If ADR is set to on, SF value is shown inverted on display.
0x08 do nothing 0x08 do nothing

View File

@ -318,7 +318,12 @@ uint64_t uptime() {
// update LoRa SF display (line 3) // update LoRa SF display (line 3)
u8x8.setCursor(11,3); u8x8.setCursor(11,3);
u8x8.printf("SF:%c%c", lora_datarate[LMIC.datarate * 2], lora_datarate[LMIC.datarate * 2 + 1]); u8x8.printf("SF:");
if (cfg.adrmode) // if ADR=on then display SF value inverse
u8x8.setInverseFont(1);
u8x8.printf("%c%c", lora_datarate[LMIC.datarate * 2], lora_datarate[LMIC.datarate * 2 + 1]);
if (cfg.adrmode) // switch off inverse if it was turned on
u8x8.setInverseFont(0);
// update wifi channel display (line 4) // update wifi channel display (line 4)
u8x8.setCursor(11,4); u8x8.setCursor(11,4);