Corrected RSSI float to int and added SNR

RSSI display was wrong as it was lloking for a float. It is an int
This commit is contained in:
Philippe 2021-01-03 19:24:03 +01:00 committed by GitHub
commit 20a6abddbc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -42,8 +42,10 @@ void loop()
char buf[256];
u8g2->drawStr(0, 12, "Received OK!");
u8g2->drawStr(0, 26, recv.c_str());
snprintf(buf, sizeof(buf), "RSSI:%.2f", LoRa.packetRssi());
snprintf(buf, sizeof(buf), "RSSI:%i", LoRa.packetRssi());
u8g2->drawStr(0, 40, buf);
snprintf(buf, sizeof(buf), "SNR:%.1f", LoRa.packetSnr());
u8g2->drawStr(0, 56, buf);
u8g2->sendBuffer();
}
#endif