From e6597a726b8feb9d602e32bd3d37e33f576d1027 Mon Sep 17 00:00:00 2001 From: Brendan Haines Date: Fri, 2 Dec 2016 20:10:42 -0700 Subject: [PATCH] rssi led fix --- Hohm_Phone.ino | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Hohm_Phone.ino b/Hohm_Phone.ino index 6e0a5c9..4be2dc3 100644 --- a/Hohm_Phone.ino +++ b/Hohm_Phone.ino @@ -22,7 +22,7 @@ #define SLEEP_TIMEOUT 120000 // RSSI value below which No Signal LED will light -#define RSSI_THRESHOLD +#define RSSI_THRESHOLD 5 // Keypad pinout byte rowPins[4] = {5, 10, 9, 7}; @@ -180,10 +180,10 @@ void loop() { uint8_t rssi; rssi = fona.getRSSI(); - if( rssi < RSSI_THRESHOLD ) { - digitalWrite( LED_NO_SIGNAL, HIGH ); + if( rssi < RSSI_THRESHOLD | rssi == 99 ) { + digitalWrite( LED_NO_SERVICE, HIGH ); } else { - digitalWrite( LED_NO_SIGNAL, LOW ); + digitalWrite( LED_NO_SERVICE, LOW ); } } else {