correct extraction of room temperature: had a mis-placed bit causing erroneous readings
3 files changed, 7 insertions(+), 5 deletions(-)

M include/config.h
M platformio.ini
M src/main.cpp
M include/config.h +1 -1
@@ 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)
 

          
M platformio.ini +3 -3
@@ 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 = 

          
M src/main.cpp +3 -1
@@ 553,7 553,7 @@ void publishSettings(){
     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 @@ void setup() {
   //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