Fix Error ''max' must be > 'min'' when processing MQTT

This commit is contained in:
Yurii
2023-10-19 02:18:39 +03:00
parent 2615e9106e
commit dc00fdcdb6
2 changed files with 5 additions and 5 deletions

View File

@@ -382,7 +382,7 @@ public:
doc[F("command_topic")] = _prefix + F("/settings/set");
doc[F("command_template")] = F("{\"heating\": {\"target\" : {{ value }}}}");
doc[F("min")] = minTemp;
doc[F("max")] = maxTemp <= minTemp ? maxTemp : maxTemp;
doc[F("max")] = maxTemp;
doc[F("step")] = 0.5;
doc[F("mode")] = "box";

View File

@@ -107,11 +107,11 @@ struct Variables {
struct {
bool heatingEnabled = false;
byte heatingMinTemp = 0;
byte heatingMaxTemp = 0;
byte heatingMinTemp = 20;
byte heatingMaxTemp = 90;
byte heatingSetpoint = 0.0f;
byte dhwMinTemp = 0;
byte dhwMaxTemp = 0;
byte dhwMinTemp = 30;
byte dhwMaxTemp = 60;
uint8_t slaveMemberIdCode;
uint8_t slaveType;
uint8_t slaveVersion;