diff --git a/src/platformio.ini b/src/platformio.ini index 4e2e92fd..179a9fd8 100644 --- a/src/platformio.ini +++ b/src/platformio.ini @@ -48,7 +48,8 @@ lib_deps = platform = espressif8266 board = esp12e board_build.f_cpu = 80000000L -build_flags = -D RELEASE -Wl,-Map,output.map +build_flags = -D RELEASE + ;-Wl,-Map,output.map monitor_filters = ;default ; Remove typical terminal control codes from input ;time ; Add timestamp with milliseconds for each new line diff --git a/src/publisher/pubMqtt.h b/src/publisher/pubMqtt.h index 7629f96a..b008d8d2 100644 --- a/src/publisher/pubMqtt.h +++ b/src/publisher/pubMqtt.h @@ -101,7 +101,7 @@ class PubMqtt { if (mIntervalTimeout > 0) mIntervalTimeout--; - if(!mClient.connected()) { + if(mClient.disconnected()) { mClient.connect(); return; // next try in a second }