# HG changeset patch # User William Welliver # Date 1659814083 14400 # Sat Aug 06 15:28:03 2022 -0400 # Node ID f09b4bb00e0af416ba04a634a7d1979175aa528c # Parent 2233ad5a16c0c23bc0d404ecdcafeceeeeb69f40 correct extraction of room temperature: had a mis-placed bit causing erroneous readings diff --git a/include/config.h b/include/config.h --- a/include/config.h +++ b/include/config.h @@ -2,7 +2,7 @@ #define WANT_OTA 1 #define WANT_MDNS 1 -#define FIRMWARE_REVISION "1027" +#define FIRMWARE_REVISION "1028" #define RESET_INTERVAL (1000 * 3600 * 24 * 7) diff --git a/platformio.ini b/platformio.ini --- a/platformio.ini +++ b/platformio.ini @@ -9,9 +9,9 @@ ; https://docs.platformio.org/page/projectconf.html [env:nodemcuv2] -upload_protocol = espota -upload_port = 192.168.5.96 -upload_flags = --auth=0123 +#upload_protocol = espota +#upload_port = 192.168.5.96 +#upload_flags = --auth=0123 #upload_port = /dev/cu.usbserial-2240 platform = espressif8266 platform_packages = diff --git a/src/main.cpp b/src/main.cpp --- a/src/main.cpp +++ b/src/main.cpp @@ -553,7 +553,7 @@ bitWrite(roomTempByte,2, bitRead(charBuff[7],2)); bitWrite(roomTempByte,3, bitRead(charBuff[7],3)); bitWrite(roomTempByte,4, bitRead(charBuff[7],4)); - bitWrite(roomTempByte,6, bitRead(charBuff[7],5)); + bitWrite(roomTempByte,5, bitRead(charBuff[7],5)); //Set Temp - Binary 0011 -> 1111 = 18 - 30 Deg (decimal 3 offset in value, starts at 18, possibly cool can be set at 15?) bitWrite(tempByte,0, bitRead(charBuff[6],0)); @@ -665,6 +665,8 @@ //reset settings - for testing wifiManager.resetSettings(); + // after 3 minutes, we want to reset and try to connect again, in case the outage was temporary + wifiManager.setConfigPortalTimeout(180); //tries to connect to last known settings //if it does not connect it starts an access point with the specified name