diff --git a/CO2_Gadget_Preferences.h b/CO2_Gadget_Preferences.h index 28e5ebcc..cd04b3f2 100644 --- a/CO2_Gadget_Preferences.h +++ b/CO2_Gadget_Preferences.h @@ -165,7 +165,7 @@ void initPreferences() { wifiPass.trim(); hostName.trim(); preferences.end(); -// #define DEBUG_PREFERENCES +#define DEBUG_PREFERENCES #ifdef DEBUG_PREFERENCES printPreferences(); #endif @@ -237,6 +237,10 @@ void putPreferences() { preferences.putUInt("timeBtwnBzr", timeBetweenBuzzerBeeps); // Time between beeps preferences.end(); + +#ifdef DEBUG_PREFERENCES + printPreferences(); +#endif } String getPreferencesAsJson() { diff --git a/CO2_Gadget_WIFI.h b/CO2_Gadget_WIFI.h index 3125ebc3..2402c1ca 100644 --- a/CO2_Gadget_WIFI.h +++ b/CO2_Gadget_WIFI.h @@ -737,6 +737,8 @@ void wifiClientLoop() { // Only checks for SSID changed (not password) if ((WiFi.SSID() != wifiSSID) && (!inMenu)) { Serial.println("-->[WiFi] Wi-Fi SSID changed. Old SSID: " + wifiSSID + ", new SSID: " + WiFi.SSID()); + Serial.println("-->[WiFi] IP address: " + WiFi.localIP().toString()); + Serial.println("-->[WiFi] RSSI: " + String(WiFi.RSSI()) + " dBm"); wifiSSID = WiFi.SSID(); activeWIFI = true; putPreferences();