From 31137d4e15f0c7ab2de0439cf4f69a1d237780e0 Mon Sep 17 00:00:00 2001 From: MichaelDvP Date: Sun, 31 Jan 2021 17:52:20 +0100 Subject: [PATCH] remove unused defaults, invert esp32 led-default, typos --- CHANGELOG_LATEST.md | 2 +- lib/framework/MqttSettingsService.cpp | 2 -- lib/framework/MqttSettingsService.h | 4 ---- src/WebSettingsService.h | 4 ++++ src/console.cpp | 2 +- 5 files changed, 6 insertions(+), 8 deletions(-) diff --git a/CHANGELOG_LATEST.md b/CHANGELOG_LATEST.md index 109230c5..d5b0e917 100644 --- a/CHANGELOG_LATEST.md +++ b/CHANGELOG_LATEST.md @@ -6,7 +6,7 @@ ### Fixed - telegrams matched to masterthermostat 0x18 - Boiler Junkers Cerapur Aero -- multible roomcontrollers +- multiple roomcontrollers - readback after write with delay (give ems-devices time to set the value) ### Changed diff --git a/lib/framework/MqttSettingsService.cpp b/lib/framework/MqttSettingsService.cpp index 9157d38e..ee123bf0 100644 --- a/lib/framework/MqttSettingsService.cpp +++ b/lib/framework/MqttSettingsService.cpp @@ -180,7 +180,6 @@ void MqttSettings::read(MqttSettings & settings, JsonObject & root) { root["client_id"] = settings.clientId; root["keep_alive"] = settings.keepAlive; root["clean_session"] = settings.cleanSession; - // root["max_topic_length"] = settings.maxTopicLength; // added by proddy for EMS-ESP root["publish_time_boiler"] = settings.publish_time_boiler; @@ -206,7 +205,6 @@ StateUpdateResult MqttSettings::update(JsonObject & root, MqttSettings & setting newSettings.clientId = root["client_id"] | FACTORY_MQTT_CLIENT_ID; newSettings.keepAlive = root["keep_alive"] | FACTORY_MQTT_KEEP_ALIVE; newSettings.cleanSession = root["clean_session"] | FACTORY_MQTT_CLEAN_SESSION; - // newSettings.maxTopicLength = root["max_topic_length"] | FACTORY_MQTT_MAX_TOPIC_LENGTH; newSettings.publish_time_boiler = root["publish_time_boiler"] | EMSESP_DEFAULT_PUBLISH_TIME; newSettings.publish_time_thermostat = root["publish_time_thermostat"] | EMSESP_DEFAULT_PUBLISH_TIME; diff --git a/lib/framework/MqttSettingsService.h b/lib/framework/MqttSettingsService.h index b4fb37e6..3d5e0cbf 100644 --- a/lib/framework/MqttSettingsService.h +++ b/lib/framework/MqttSettingsService.h @@ -60,10 +60,6 @@ static String generateClientId() { #define FACTORY_MQTT_CLEAN_SESSION true #endif -#ifndef FACTORY_MQTT_MAX_TOPIC_LENGTH -#define FACTORY_MQTT_MAX_TOPIC_LENGTH 128 -#endif - #define EMSESP_DEFAULT_MQTT_FORMAT 2 // nested #define EMSESP_DEFAULT_MQTT_QOS 0 #define EMSESP_DEFAULT_MQTT_RETAIN false diff --git a/src/WebSettingsService.h b/src/WebSettingsService.h index 1edda0f6..bc539858 100644 --- a/src/WebSettingsService.h +++ b/src/WebSettingsService.h @@ -36,7 +36,11 @@ #define EMSESP_DEFAULT_MASTER_THERMOSTAT 0 // not set #define EMSESP_DEFAULT_SHOWER_TIMER false #define EMSESP_DEFAULT_SHOWER_ALERT false +#if defined(ESP32) +#define EMSESP_DEFAULT_HIDE_LED true +#else #define EMSESP_DEFAULT_HIDE_LED false +#endif #define EMSESP_DEFAULT_DALLAS_PARASITE false #define EMSESP_DEFAULT_API_ENABLED false // turn off, because its insecure #define EMSESP_DEFAULT_BOOL_FORMAT 1 // on/off diff --git a/src/console.cpp b/src/console.cpp index 44255b77..7094509d 100644 --- a/src/console.cpp +++ b/src/console.cpp @@ -313,7 +313,7 @@ void EMSESPShell::add_console_commands() { } else { watch_id = Helpers::hextoint(arguments[0].c_str()); if (watch_id && ((emsesp::EMSESP::watch() == EMSESP::WATCH_OFF) || (emsesp::EMSESP::watch() == EMSESP::WATCH_UNKNOWN))) { - emsesp::EMSESP::watch(EMSESP::WATCH_ON); // on + emsesp::EMSESP::watch(EMSESP::WATCH_ON); // on } else if (!watch_id) { return; }