8 Commits

Author SHA1 Message Date
Yurii
8641f9f1e4 feat: added OT option alwaysSetIndoorTemp #180 2025-12-10 17:31:19 +03:00
Yurii
c9fee6f1eb chore: bump version to 1.6.0 2025-12-10 17:16:20 +03:00
Yurii
eafb33cb6a refactor: fix typo 2025-12-09 21:10:23 +03:00
Yurii
0038a200ca refactor: some fixes localization 2025-12-09 20:21:10 +03:00
Yurii
1112a25172 chore: bump h2zero/NimBLE-Arduino from 2.3.3 to 2.3.7 2025-12-09 20:20:44 +03:00
Yurii
69b3cdf05a refactor: fixed localization for equitherm 2025-12-09 19:56:33 +03:00
Yurii
01192a59f5 Advanced hysteresis settings (#201)
* feat: added more hysteresis settings

* fix: heating hysteresis switch fixed

* refactor: added localization for hysteresis
2025-12-09 19:27:47 +03:00
Yurii
cb8251dd40 Implementation of the new Equitherm algorithm (#146)
* feat: new equitherm algorithm and chart for it (#144)

* refactor: refactoring after #144

* refactor: cosmetic changes (equitherm chart)

* chore: fix typo

* refactor: cosmetic changes

* chore: remove unused files

* chore: resolve conflicts

* refactor: added notes for equitherm parameters

* fix: decimation for Equitherm chart fixed; chartjs updated

* style: HTML code formatting

* chore: added additional description of the ``T`` parameter for Equitherm

* flx: typo

* refactor: after merge

---------

Co-authored-by: P43YM <ip43ym@gmail.com>
2025-12-09 19:27:12 +03:00
16 changed files with 261 additions and 62 deletions

View File

@@ -14,7 +14,7 @@ extra_configs = secrets.default.ini
core_dir = .pio core_dir = .pio
[env] [env]
version = 1.5.6 version = 1.6.0
framework = arduino framework = arduino
lib_deps = lib_deps =
bblanchon/ArduinoJson@^7.4.2 bblanchon/ArduinoJson@^7.4.2
@@ -98,7 +98,7 @@ board_build.partitions = esp32_partitions.csv
lib_deps = lib_deps =
${env.lib_deps} ${env.lib_deps}
laxilef/ESP32Scheduler@^1.0.1 laxilef/ESP32Scheduler@^1.0.1
nimble_lib = h2zero/NimBLE-Arduino@2.3.3 nimble_lib = h2zero/NimBLE-Arduino@2.3.7
lib_ignore = lib_ignore =
extra_scripts = extra_scripts =
post:tools/esp32.py post:tools/esp32.py
@@ -234,7 +234,7 @@ build_flags =
${esp32_defaults.build_flags} ${esp32_defaults.build_flags}
-D ARDUINO_USB_MODE=0 -D ARDUINO_USB_MODE=0
-D ARDUINO_USB_CDC_ON_BOOT=1 -D ARDUINO_USB_CDC_ON_BOOT=1
-D CONFIG_BT_NIMBLE_EXT_ADV=1 -D MYNEWT_VAL_BLE_EXT_ADV=1
-D USE_BLE=1 -D USE_BLE=1
-D DEFAULT_OT_IN_GPIO=35 -D DEFAULT_OT_IN_GPIO=35
-D DEFAULT_OT_OUT_GPIO=36 -D DEFAULT_OT_OUT_GPIO=36
@@ -260,7 +260,7 @@ build_unflags =
build_type = ${esp32_defaults.build_type} build_type = ${esp32_defaults.build_type}
build_flags = build_flags =
${esp32_defaults.build_flags} ${esp32_defaults.build_flags}
-D CONFIG_BT_NIMBLE_EXT_ADV=1 -D MYNEWT_VAL_BLE_EXT_ADV=1
-D USE_BLE=1 -D USE_BLE=1
-D DEFAULT_OT_IN_GPIO=8 -D DEFAULT_OT_IN_GPIO=8
-D DEFAULT_OT_OUT_GPIO=10 -D DEFAULT_OT_OUT_GPIO=10
@@ -366,7 +366,7 @@ build_unflags =
build_type = ${esp32_defaults.build_type} build_type = ${esp32_defaults.build_type}
build_flags = build_flags =
${esp32_defaults.build_flags} ${esp32_defaults.build_flags}
-D CONFIG_BT_NIMBLE_EXT_ADV=1 -D MYNEWT_VAL_BLE_EXT_ADV=1
-D USE_BLE=1 -D USE_BLE=1
-D DEFAULT_OT_IN_GPIO=3 -D DEFAULT_OT_IN_GPIO=3
-D DEFAULT_OT_OUT_GPIO=1 -D DEFAULT_OT_OUT_GPIO=1

View File

@@ -443,6 +443,28 @@ public:
return this->publish(this->makeConfigTopic(FPSTR(HA_ENTITY_SWITCH), F("heating_turbo")).c_str(), doc); return this->publish(this->makeConfigTopic(FPSTR(HA_ENTITY_SWITCH), F("heating_turbo")).c_str(), doc);
} }
bool publishSwitchHeatingHysteresis(bool enabledByDefault = true) {
JsonDocument doc;
doc[FPSTR(HA_AVAILABILITY)][FPSTR(HA_TOPIC)] = this->statusTopic.c_str();
doc[FPSTR(HA_ENABLED_BY_DEFAULT)] = enabledByDefault;
doc[FPSTR(HA_UNIQUE_ID)] = this->getUniqueIdWithPrefix(F("heating_hysteresis"));
doc[FPSTR(HA_DEFAULT_ENTITY_ID)] = this->getEntityIdWithPrefix(FPSTR(HA_ENTITY_SWITCH), F("heating_hysteresis"));
doc[FPSTR(HA_ENTITY_CATEGORY)] = FPSTR(HA_ENTITY_CATEGORY_CONFIG);
doc[FPSTR(HA_NAME)] = F("Use heating hysteresis");
doc[FPSTR(HA_ICON)] = F("mdi:altimeter");
doc[FPSTR(HA_STATE_TOPIC)] = this->settingsTopic.c_str();
doc[FPSTR(HA_STATE_ON)] = true;
doc[FPSTR(HA_STATE_OFF)] = false;
doc[FPSTR(HA_VALUE_TEMPLATE)] = F("{{ value_json.heating.hysteresis.enabled }}");
doc[FPSTR(HA_COMMAND_TOPIC)] = this->setSettingsTopic.c_str();
doc[FPSTR(HA_PAYLOAD_ON)] = F("{\"heating\": {\"hysteresis\" : {\"enabled\" : true}}}");
doc[FPSTR(HA_PAYLOAD_OFF)] = F("{\"heating\": {\"hysteresis\" : {\"enabled\" : false}}}");
doc[FPSTR(HA_EXPIRE_AFTER)] = this->expireAfter;
doc.shrinkToFit();
return this->publish(this->makeConfigTopic(FPSTR(HA_ENTITY_SWITCH), F("heating_hysteresis")).c_str(), doc);
}
bool publishInputHeatingHysteresis(UnitSystem unit = UnitSystem::METRIC, bool enabledByDefault = true) { bool publishInputHeatingHysteresis(UnitSystem unit = UnitSystem::METRIC, bool enabledByDefault = true) {
JsonDocument doc; JsonDocument doc;
doc[FPSTR(HA_AVAILABILITY)][FPSTR(HA_TOPIC)] = this->statusTopic.c_str(); doc[FPSTR(HA_AVAILABILITY)][FPSTR(HA_TOPIC)] = this->statusTopic.c_str();
@@ -462,9 +484,9 @@ public:
doc[FPSTR(HA_NAME)] = F("Heating hysteresis"); doc[FPSTR(HA_NAME)] = F("Heating hysteresis");
doc[FPSTR(HA_ICON)] = F("mdi:altimeter"); doc[FPSTR(HA_ICON)] = F("mdi:altimeter");
doc[FPSTR(HA_STATE_TOPIC)] = this->settingsTopic.c_str(); doc[FPSTR(HA_STATE_TOPIC)] = this->settingsTopic.c_str();
doc[FPSTR(HA_VALUE_TEMPLATE)] = F("{{ value_json.heating.hysteresis|float(0)|round(2) }}"); doc[FPSTR(HA_VALUE_TEMPLATE)] = F("{{ value_json.heating.hysteresis.value|float(0)|round(2) }}");
doc[FPSTR(HA_COMMAND_TOPIC)] = this->setSettingsTopic.c_str(); doc[FPSTR(HA_COMMAND_TOPIC)] = this->setSettingsTopic.c_str();
doc[FPSTR(HA_COMMAND_TEMPLATE)] = F("{\"heating\": {\"hysteresis\" : {{ value }}}}"); doc[FPSTR(HA_COMMAND_TEMPLATE)] = F("{\"heating\": {\"hysteresis\" : {\"value\" : {{ value }}}}}");
doc[FPSTR(HA_MIN)] = 0; doc[FPSTR(HA_MIN)] = 0;
doc[FPSTR(HA_MAX)] = 15; doc[FPSTR(HA_MAX)] = 15;
doc[FPSTR(HA_STEP)] = 0.01f; doc[FPSTR(HA_STEP)] = 0.01f;

View File

@@ -486,6 +486,7 @@ protected:
void publishHaEntities() { void publishHaEntities() {
// heating // heating
this->haHelper->publishSwitchHeatingTurbo(false); this->haHelper->publishSwitchHeatingTurbo(false);
this->haHelper->publishSwitchHeatingHysteresis();
this->haHelper->publishInputHeatingHysteresis(settings.system.unitSystem); this->haHelper->publishInputHeatingHysteresis(settings.system.unitSystem);
this->haHelper->publishInputHeatingTurboFactor(false); this->haHelper->publishInputHeatingTurboFactor(false);
this->haHelper->publishInputHeatingMinTemp(settings.system.unitSystem); this->haHelper->publishInputHeatingMinTemp(settings.system.unitSystem);

View File

@@ -171,7 +171,7 @@ protected:
vars.master.heating.enabled = this->isReady() vars.master.heating.enabled = this->isReady()
&& settings.heating.enabled && settings.heating.enabled
&& vars.cascadeControl.input && vars.cascadeControl.input
&& !vars.master.heating.blocking && (!vars.master.heating.blocking || settings.heating.hysteresis.action != HysteresisAction::DISABLE_HEATING)
&& !vars.master.heating.overheat; && !vars.master.heating.overheat;
// DHW settings // DHW settings
@@ -1209,8 +1209,8 @@ protected:
} }
} }
// Native heating control // Set indoor temp for Native heating control/Always set indoor temp
if (settings.opentherm.options.nativeHeatingControl) { if (settings.opentherm.options.nativeHeatingControl || settings.opentherm.options.alwaysSetIndoorTemp) {
// Converted current indoor temp // Converted current indoor temp
float convertedTemp = convertTemp(vars.master.heating.indoorTemp, settings.system.unitSystem, settings.opentherm.unitSystem); float convertedTemp = convertTemp(vars.master.heating.indoorTemp, settings.system.unitSystem, settings.opentherm.unitSystem);
@@ -1237,10 +1237,13 @@ protected:
Log.swarningln(FPSTR(L_OT_HEATING), F("Failed set current CH2 indoor temp")); Log.swarningln(FPSTR(L_OT_HEATING), F("Failed set current CH2 indoor temp"));
} }
} }
}
// Native heating control
if (settings.opentherm.options.nativeHeatingControl) {
// Converted target indoor temp // Converted target indoor temp
convertedTemp = convertTemp(vars.master.heating.targetTemp, settings.system.unitSystem, settings.opentherm.unitSystem); float convertedTemp = convertTemp(vars.master.heating.targetTemp, settings.system.unitSystem, settings.opentherm.unitSystem);
// Set target indoor temp // Set target indoor temp
if (this->needSetHeatingTemp(convertedTemp)) { if (this->needSetHeatingTemp(convertedTemp)) {

View File

@@ -57,12 +57,23 @@ protected:
this->turbo(); this->turbo();
this->hysteresis(); this->hysteresis();
if (vars.master.heating.blocking && settings.heating.hysteresis.action == HysteresisAction::SET_ZERO_TARGET) {
vars.master.heating.targetTemp = 0.0f;
vars.master.heating.setpointTemp = 0.0f;
// tick if PID enabled
if (settings.pid.enabled) {
this->getHeatingSetpointTemp();
}
} else {
vars.master.heating.targetTemp = settings.heating.target; vars.master.heating.targetTemp = settings.heating.target;
vars.master.heating.setpointTemp = roundf(constrain( vars.master.heating.setpointTemp = roundf(constrain(
this->getHeatingSetpointTemp(), this->getHeatingSetpointTemp(),
this->getHeatingMinSetpointTemp(), this->getHeatingMinSetpointTemp(),
this->getHeatingMaxSetpointTemp() this->getHeatingMaxSetpointTemp()
), 0); ), 0);
}
Sensors::setValueByType( Sensors::setValueByType(
Sensors::Type::HEATING_SETPOINT_TEMP, vars.master.heating.setpointTemp, Sensors::Type::HEATING_SETPOINT_TEMP, vars.master.heating.setpointTemp,
@@ -90,15 +101,15 @@ protected:
void hysteresis() { void hysteresis() {
bool useHyst = false; bool useHyst = false;
if (settings.heating.hysteresis > 0.01f && this->indoorSensorsConnected) { if (settings.heating.hysteresis.enabled && this->indoorSensorsConnected) {
useHyst = settings.equitherm.enabled || settings.pid.enabled || settings.opentherm.options.nativeHeatingControl; useHyst = settings.equitherm.enabled || settings.pid.enabled || settings.opentherm.options.nativeHeatingControl;
} }
if (useHyst) { if (useHyst) {
if (!vars.master.heating.blocking && vars.master.heating.indoorTemp - settings.heating.target + 0.0001f >= settings.heating.hysteresis) { if (!vars.master.heating.blocking && vars.master.heating.indoorTemp - settings.heating.target + 0.0001f >= settings.heating.hysteresis.value) {
vars.master.heating.blocking = true; vars.master.heating.blocking = true;
} else if (vars.master.heating.blocking && vars.master.heating.indoorTemp - settings.heating.target - 0.0001f <= -(settings.heating.hysteresis)) { } else if (vars.master.heating.blocking && vars.master.heating.indoorTemp - settings.heating.target - 0.0001f <= -(settings.heating.hysteresis.value)) {
vars.master.heating.blocking = false; vars.master.heating.blocking = false;
} }

View File

@@ -149,7 +149,7 @@ public:
static int16_t getIdByName(const char* name) { static int16_t getIdByName(const char* name) {
if (settings == nullptr) { if (settings == nullptr) {
return 0; return -1;
} }
for (uint8_t id = 0; id <= getMaxSensorId(); id++) { for (uint8_t id = 0; id <= getMaxSensorId(); id++) {
@@ -163,7 +163,7 @@ public:
static int16_t getIdByObjectId(const char* objectId) { static int16_t getIdByObjectId(const char* objectId) {
if (settings == nullptr) { if (settings == nullptr) {
return 0; return -1;
} }
String refObjectId; String refObjectId;
@@ -329,12 +329,12 @@ public:
static float getMeanValueByPurpose(Purpose purpose, const ValueType valueType, bool onlyConnected = true) { static float getMeanValueByPurpose(Purpose purpose, const ValueType valueType, bool onlyConnected = true) {
if (settings == nullptr || results == nullptr) { if (settings == nullptr || results == nullptr) {
return 0; return 0.0f;
} }
uint8_t valueId = (uint8_t) valueType; uint8_t valueId = (uint8_t) valueType;
if (!isValidValueId(valueId)) { if (!isValidValueId(valueId)) {
return 0; return 0.0f;
} }
float value = 0.0f; float value = 0.0f;
@@ -363,7 +363,7 @@ public:
static bool existsConnectedSensorsByPurpose(Purpose purpose) { static bool existsConnectedSensorsByPurpose(Purpose purpose) {
if (settings == nullptr || results == nullptr) { if (settings == nullptr || results == nullptr) {
return 0; return false;
} }
for (uint8_t id = 0; id <= getMaxSensorId(); id++) { for (uint8_t id = 0; id <= getMaxSensorId(); id++) {

View File

@@ -78,6 +78,7 @@ struct Settings {
bool autoFaultReset = false; bool autoFaultReset = false;
bool autoDiagReset = false; bool autoDiagReset = false;
bool setDateAndTime = false; bool setDateAndTime = false;
bool alwaysSetIndoorTemp = true;
bool nativeHeatingControl = false; bool nativeHeatingControl = false;
bool immergasFix = false; bool immergasFix = false;
} options; } options;
@@ -103,12 +104,17 @@ struct Settings {
bool enabled = true; bool enabled = true;
bool turbo = false; bool turbo = false;
float target = DEFAULT_HEATING_TARGET_TEMP; float target = DEFAULT_HEATING_TARGET_TEMP;
float hysteresis = 0.5f;
float turboFactor = 7.5f; float turboFactor = 7.5f;
uint8_t minTemp = DEFAULT_HEATING_MIN_TEMP; uint8_t minTemp = DEFAULT_HEATING_MIN_TEMP;
uint8_t maxTemp = DEFAULT_HEATING_MAX_TEMP; uint8_t maxTemp = DEFAULT_HEATING_MAX_TEMP;
uint8_t maxModulation = 100; uint8_t maxModulation = 100;
struct {
bool enabled = true;
float value = 0.5f;
HysteresisAction action = HysteresisAction::DISABLE_HEATING;
} hysteresis;
struct { struct {
uint8_t highTemp = 95; uint8_t highTemp = 95;
uint8_t lowTemp = 90; uint8_t lowTemp = 90;

View File

@@ -163,4 +163,9 @@ enum class UnitSystem : uint8_t {
IMPERIAL = 1 IMPERIAL = 1
}; };
enum class HysteresisAction : uint8_t {
DISABLE_HEATING = 0,
SET_ZERO_TARGET = 1
};
char buffer[255]; char buffer[255];

View File

@@ -34,9 +34,11 @@ const char L_CASCADE_OUTPUT[] PROGMEM = "CASCADE.OUTPUT";
const char L_EXTPUMP[] PROGMEM = "EXTPUMP"; const char L_EXTPUMP[] PROGMEM = "EXTPUMP";
const char S_ACTION[] PROGMEM = "action";
const char S_ACTIONS[] PROGMEM = "actions"; const char S_ACTIONS[] PROGMEM = "actions";
const char S_ACTIVE[] PROGMEM = "active"; const char S_ACTIVE[] PROGMEM = "active";
const char S_ADDRESS[] PROGMEM = "address"; const char S_ADDRESS[] PROGMEM = "address";
const char S_ALWAYS_SET_INDOOR_TEMP[] PROGMEM = "alwaysSetIndoorTemp";
const char S_ANTI_STUCK_INTERVAL[] PROGMEM = "antiStuckInterval"; const char S_ANTI_STUCK_INTERVAL[] PROGMEM = "antiStuckInterval";
const char S_ANTI_STUCK_TIME[] PROGMEM = "antiStuckTime"; const char S_ANTI_STUCK_TIME[] PROGMEM = "antiStuckTime";
const char S_AP[] PROGMEM = "ap"; const char S_AP[] PROGMEM = "ap";

View File

@@ -468,6 +468,7 @@ void settingsToJson(const Settings& src, JsonVariant dst, bool safe = false) {
otOptions[FPSTR(S_AUTO_FAULT_RESET)] = src.opentherm.options.autoFaultReset; otOptions[FPSTR(S_AUTO_FAULT_RESET)] = src.opentherm.options.autoFaultReset;
otOptions[FPSTR(S_AUTO_DIAG_RESET)] = src.opentherm.options.autoDiagReset; otOptions[FPSTR(S_AUTO_DIAG_RESET)] = src.opentherm.options.autoDiagReset;
otOptions[FPSTR(S_SET_DATE_AND_TIME)] = src.opentherm.options.setDateAndTime; otOptions[FPSTR(S_SET_DATE_AND_TIME)] = src.opentherm.options.setDateAndTime;
otOptions[FPSTR(S_ALWAYS_SET_INDOOR_TEMP)] = src.opentherm.options.alwaysSetIndoorTemp;
otOptions[FPSTR(S_NATIVE_HEATING_CONTROL)] = src.opentherm.options.nativeHeatingControl; otOptions[FPSTR(S_NATIVE_HEATING_CONTROL)] = src.opentherm.options.nativeHeatingControl;
otOptions[FPSTR(S_IMMERGAS_FIX)] = src.opentherm.options.immergasFix; otOptions[FPSTR(S_IMMERGAS_FIX)] = src.opentherm.options.immergasFix;
@@ -490,7 +491,9 @@ void settingsToJson(const Settings& src, JsonVariant dst, bool safe = false) {
heating[FPSTR(S_ENABLED)] = src.heating.enabled; heating[FPSTR(S_ENABLED)] = src.heating.enabled;
heating[FPSTR(S_TURBO)] = src.heating.turbo; heating[FPSTR(S_TURBO)] = src.heating.turbo;
heating[FPSTR(S_TARGET)] = roundf(src.heating.target, 2); heating[FPSTR(S_TARGET)] = roundf(src.heating.target, 2);
heating[FPSTR(S_HYSTERESIS)] = roundf(src.heating.hysteresis, 3); heating[FPSTR(S_HYSTERESIS)][FPSTR(S_ENABLED)] = src.heating.hysteresis.enabled;
heating[FPSTR(S_HYSTERESIS)][FPSTR(S_VALUE)] = roundf(src.heating.hysteresis.value, 3);
heating[FPSTR(S_HYSTERESIS)][FPSTR(S_ACTION)] = static_cast<uint8_t>(src.heating.hysteresis.action);
heating[FPSTR(S_TURBO_FACTOR)] = roundf(src.heating.turboFactor, 3); heating[FPSTR(S_TURBO_FACTOR)] = roundf(src.heating.turboFactor, 3);
heating[FPSTR(S_MIN_TEMP)] = src.heating.minTemp; heating[FPSTR(S_MIN_TEMP)] = src.heating.minTemp;
heating[FPSTR(S_MAX_TEMP)] = src.heating.maxTemp; heating[FPSTR(S_MAX_TEMP)] = src.heating.maxTemp;
@@ -1001,6 +1004,15 @@ bool jsonToSettings(const JsonVariantConst src, Settings& dst, bool safe = false
} }
} }
if (src[FPSTR(S_OPENTHERM)][FPSTR(S_OPTIONS)][FPSTR(S_ALWAYS_SET_INDOOR_TEMP)].is<bool>()) {
bool value = src[FPSTR(S_OPENTHERM)][FPSTR(S_OPTIONS)][FPSTR(S_ALWAYS_SET_INDOOR_TEMP)].as<bool>();
if (value != dst.opentherm.options.alwaysSetIndoorTemp) {
dst.opentherm.options.alwaysSetIndoorTemp = value;
changed = true;
}
}
if (src[FPSTR(S_OPENTHERM)][FPSTR(S_OPTIONS)][FPSTR(S_NATIVE_HEATING_CONTROL)].is<bool>()) { if (src[FPSTR(S_OPENTHERM)][FPSTR(S_OPTIONS)][FPSTR(S_NATIVE_HEATING_CONTROL)].is<bool>()) {
bool value = src[FPSTR(S_OPENTHERM)][FPSTR(S_OPTIONS)][FPSTR(S_NATIVE_HEATING_CONTROL)].as<bool>(); bool value = src[FPSTR(S_OPENTHERM)][FPSTR(S_OPTIONS)][FPSTR(S_NATIVE_HEATING_CONTROL)].as<bool>();
@@ -1314,15 +1326,41 @@ bool jsonToSettings(const JsonVariantConst src, Settings& dst, bool safe = false
} }
} }
if (!src[FPSTR(S_HEATING)][FPSTR(S_HYSTERESIS)].isNull()) { if (src[FPSTR(S_HEATING)][FPSTR(S_HYSTERESIS)][FPSTR(S_ENABLED)].is<bool>()) {
float value = src[FPSTR(S_HEATING)][FPSTR(S_HYSTERESIS)].as<float>(); bool value = src[FPSTR(S_HEATING)][FPSTR(S_HYSTERESIS)][FPSTR(S_ENABLED)].as<bool>();
if (value >= 0.0f && value <= 15.0f && fabsf(value - dst.heating.hysteresis) > 0.0001f) { if (value != dst.heating.hysteresis.enabled) {
dst.heating.hysteresis = roundf(value, 2); dst.heating.hysteresis.enabled = value;
changed = true; changed = true;
} }
} }
if (!src[FPSTR(S_HEATING)][FPSTR(S_HYSTERESIS)][FPSTR(S_VALUE)].isNull()) {
float value = src[FPSTR(S_HEATING)][FPSTR(S_HYSTERESIS)][FPSTR(S_VALUE)].as<float>();
if (value >= 0.0f && value <= 15.0f && fabsf(value - dst.heating.hysteresis.value) > 0.0001f) {
dst.heating.hysteresis.value = roundf(value, 2);
changed = true;
}
}
if (!src[FPSTR(S_HEATING)][FPSTR(S_HYSTERESIS)][FPSTR(S_ACTION)].isNull()) {
uint8_t value = src[FPSTR(S_HEATING)][FPSTR(S_HYSTERESIS)][FPSTR(S_ACTION)].as<uint8_t>();
switch (value) {
case static_cast<uint8_t>(HysteresisAction::DISABLE_HEATING):
case static_cast<uint8_t>(HysteresisAction::SET_ZERO_TARGET):
if (static_cast<uint8_t>(dst.heating.hysteresis.action) != value) {
dst.heating.hysteresis.action = static_cast<HysteresisAction>(value);
changed = true;
}
break;
default:
break;
}
}
if (!src[FPSTR(S_HEATING)][FPSTR(S_TURBO_FACTOR)].isNull()) { if (!src[FPSTR(S_HEATING)][FPSTR(S_TURBO_FACTOR)].isNull()) {
float value = src[FPSTR(S_HEATING)][FPSTR(S_TURBO_FACTOR)].as<float>(); float value = src[FPSTR(S_HEATING)][FPSTR(S_TURBO_FACTOR)].as<float>();

View File

@@ -356,7 +356,16 @@
}, },
"heating": { "heating": {
"hyst": "滞后值<small>(单位:度)</small>", "hyst": {
"title": "滞回",
"desc": "滞回有助于维持设定的室内温度在使用«Equitherm»和/或«PID»时。强制禁用加热当<code>current indoor > target + value</code>,启用加热当<code>current indoor < (target - value)</code>。",
"value": "值 <small>(以度为单位)</small>",
"action": {
"title": "行动",
"disableHeating": "禁用加热",
"set0target": "设置空目标"
}
},
"turboFactor": "Turbo 模式系数" "turboFactor": "Turbo 模式系数"
}, },
@@ -371,11 +380,26 @@
}, },
"equitherm": { "equitherm": {
"n": "N 系数", "slope": {
"k": "K 系数", "title": "斜率",
"t": { "note": "热损失补偿。主要调谐参数。"
"title": "T 系数", },
"note": "启用PID时此参数无效" "exponent": {
"title": "指数",
"note": "散热器效率。典型值:<code>1.1</code> - 地板采暖,<code>1.2</code> - 铸铁,<code>1.3</code> - 面板散热器,<code>1.4</code> - 对流器。"
},
"shift": {
"title": "偏移",
"note": "补偿额外热损失(例如,在管道中)或额外热源。"
},
"targetDiffFactor": {
"title": "T 因子",
"note": "如果启用 PID则不使用。将目标和当前室内温度之间的差值添加到设定点<code>setpoint = setpoint + ((target - indoor) * T)</code>。"
},
"chart": {
"targetTemp": "目标室内温度",
"setpointTemp": "热载体温度",
"outdoorTemp": "室外温度"
} }
}, },

View File

@@ -356,7 +356,16 @@
}, },
"heating": { "heating": {
"hyst": "Hysteresis <small>(in degrees)</small>", "hyst": {
"title": "Hysteresis",
"desc": "Hysteresis is useful for maintaining a set indoor temp (when using «Equitherm» and/or «PID»). Forces disable heating when <code>current indoor > target + value</code> and enable heating when <code>current indoor < (target - value)</code>.",
"value": "Value <small>(in degrees)</small>",
"action": {
"title": "Action",
"disableHeating": "Disable heating",
"set0target": "Set null target"
}
},
"turboFactor": "Turbo mode coeff." "turboFactor": "Turbo mode coeff."
}, },
@@ -448,6 +457,7 @@
"autoFaultReset": "Auto fault reset <small>(not recommended!)</small>", "autoFaultReset": "Auto fault reset <small>(not recommended!)</small>",
"autoDiagReset": "Auto diag reset <small>(not recommended!)</small>", "autoDiagReset": "Auto diag reset <small>(not recommended!)</small>",
"setDateAndTime": "Set date & time on boiler", "setDateAndTime": "Set date & time on boiler",
"alwaysSetIndoorTemp": "Always set indoor temperature",
"immergasFix": "Fix for Immergas boilers" "immergasFix": "Fix for Immergas boilers"
}, },

View File

@@ -356,7 +356,16 @@
}, },
"heating": { "heating": {
"hyst": "Isteresi <small>(in gradi)</small>", "hyst": {
"title": "Isteresi",
"desc": "L'isteresi è utile per mantenere una temperatura interna impostata (quando si utilizza «Equitherm» e/o «PID»). Forza la disabilitazione del riscaldamento quando <code>current indoor > target + value</code> e abilita il riscaldamento quando <code>current indoor < (target - value)</code>.",
"value": "Valore <small>(in gradi)</small>",
"action": {
"title": "Azione",
"disableHeating": "Disabilita riscaldamento",
"set0target": "Imposta target nullo"
}
},
"turboFactor": "Turbo mode coeff." "turboFactor": "Turbo mode coeff."
}, },
@@ -373,23 +382,23 @@
"equitherm": { "equitherm": {
"slope": { "slope": {
"title": "Pendenza", "title": "Pendenza",
"note": "Compensazione delle perdite di calore. Principale parametro di regolazione." "note": "Compensazione della perdita di calore. Parametro di regolazione principale."
}, },
"exponent": { "exponent": {
"title": "Esponente", "title": "Esponente",
"note": "Efficienza del radiatore. Valori tipici: <code>1.1</code> - Riscaldamento a pavimento, <code>1.2</code> - Radiatori in ghisa, <code>1.3</code> - Radiatori a pannelli, <code>1.4</code> - Convetttori." "note": "Efficienza del radiatore. Valori tipici: <code>1.1</code> - Riscaldamento a pavimento, <code>1.2</code> - Ghisa, <code>1.3</code> - Radiatori a pannello, <code>1.4</code> - Convettori."
}, },
"shift": { "shift": {
"title": "Spostare", "title": "Spostamento",
"note": "Compensa le perdite di calore aggiuntive (ad esempio, nelle tubature) o fonti di calore extra." "note": "Compensa perdite di calore aggiuntive (ad es., nelle tubature) o fonti di calore extra."
}, },
"targetDiffFactor": { "targetDiffFactor": {
"title": "Fattore T", "title": "Fattore T",
"note": "Non usato se PID è attivato. Aggiunge al setpoint la differenza tra la temperatura interna target e quella attuale: <code>setpoint = setpoint + ((target - indoor) * T)</code>." "note": "Non utilizzato se PID è abilitato. Aggiunge al setpoint la differenza tra la temperatura target e quella interna attuale: <code>setpoint = setpoint + ((target - indoor) * T)</code>."
}, },
"chart": { "chart": {
"targetTemp": "Temperatura interna target", "targetTemp": "Temperatura interna target",
"setpointTemp": "Temperatura del portatore di calore", "setpointTemp": "Temperatura del vettore termico",
"outdoorTemp": "Temperatura esterna" "outdoorTemp": "Temperatura esterna"
} }
}, },

View File

@@ -327,7 +327,16 @@
} }
}, },
"heating": { "heating": {
"hyst": "Hysterese <small>(in graden)</small>", "hyst": {
"title": "Hysterese",
"desc": "Hysterese is nuttig voor het handhaven van een ingestelde binnentemperatuur (bij gebruik van «Equitherm» en/of «PID»). Forceert uitschakelen van verwarming wanneer <code>current indoor > target + value</code> en inschakelen van verwarming wanneer <code>current indoor < (target - value)</code>.",
"value": "Waarde <small>(in graden)</small>",
"action": {
"title": "Actie",
"disableHeating": "Verwarming uitschakelen",
"set0target": "Stel null target in"
}
},
"turboFactor": "Turbomodus coëff." "turboFactor": "Turbomodus coëff."
}, },
"emergency": { "emergency": {
@@ -339,11 +348,26 @@
"treshold": "Drempeltijd <small>(sec)</small>" "treshold": "Drempeltijd <small>(sec)</small>"
}, },
"equitherm": { "equitherm": {
"n": "N-factor", "slope": {
"k": "K-factor", "title": "Helling",
"t": { "note": "Compensatie voor warmteverlies. Hoofdafstelparameter."
"title": "T-factor", },
"note": "Niet gebruikt als PID is ingeschakeld" "exponent": {
"title": "Exponent",
"note": "Radiator efficiëntie. Typische waarden: <code>1.1</code> - Vloerverwarming, <code>1.2</code> - Gietijzer, <code>1.3</code> - Paneelradiatoren, <code>1.4</code> - Convectors."
},
"shift": {
"title": "Verschuiving",
"note": "Compenseert voor extra warmteverliezen (bijv. in leidingen) of extra warmtebronnen."
},
"targetDiffFactor": {
"title": "T factor",
"note": "Niet gebruikt als PID is ingeschakeld. Voegt aan de setpoint de verschil tussen de target en huidige binnentemperatuur toe: <code>setpoint = setpoint + ((target - indoor) * T)</code>."
},
"chart": {
"targetTemp": "Doel binnentemperatuur",
"setpointTemp": "Warmtedrager temperatuur",
"outdoorTemp": "Buitentemperatuur"
} }
}, },
"pid": { "pid": {

View File

@@ -356,7 +356,16 @@
}, },
"heating": { "heating": {
"hyst": "Гистерезис <small>(в градусах)</small>", "hyst": {
"title": "Гистерезис",
"desc": "Гистерезис полезен для поддержания заданной внутр. темп. (при использовании «ПЗА» и/или «ПИД»). Принудительно откл. отопление, когда <code>current indoor > target + value</code>, и вкл. отопление, когда <code>current indoor < (target - value)</code>.",
"value": "Значение <small>(в градусах)</small>",
"action": {
"title": "Действие",
"disableHeating": "Отключить отопление",
"set0target": "Установить 0 в качестве целевой темп."
}
},
"turboFactor": "Коэфф. турбо режима" "turboFactor": "Коэфф. турбо режима"
}, },

View File

@@ -193,21 +193,48 @@
</div> </div>
<div class="grid"> <div class="grid">
<label>
<span data-i18n>settings.heating.hyst</span>
<input type="number" inputmode="decimal" name="heating[hysteresis]" min="0" max="5" step="0.05" required>
</label>
<label> <label>
<span data-i18n>settings.heating.turboFactor</span> <span data-i18n>settings.heating.turboFactor</span>
<input type="number" inputmode="decimal" name="heating[turboFactor]" min="1.5" max="10" step="0.1" required> <input type="number" inputmode="decimal" name="heating[turboFactor]" min="1.5" max="10" step="0.1" required>
</label> </label>
</div>
<label> <label>
<span data-i18n>settings.maxModulation</span> <span data-i18n>settings.maxModulation</span>
<input type="number" inputmode="numeric" name="heating[maxModulation]" min="1" max="100" step="1" required> <input type="number" inputmode="numeric" name="heating[maxModulation]" min="1" max="100" step="1" required>
</label> </label>
</div>
<hr />
<details>
<summary><b data-i18n>settings.heating.hyst.title</b></summary>
<div>
<fieldset>
<label>
<input type="checkbox" name="heating[hysteresis][enabled]" value="true">
<span data-i18n>settings.enable</span>
</label>
</fieldset>
<div class="grid">
<label>
<span data-i18n>settings.heating.hyst.value</span>
<input type="number" inputmode="decimal" name="heating[hysteresis][value]" min="0" max="5" step="0.05" required>
</label>
<label>
<span data-i18n>settings.heating.hyst.action.title</span>
<select name="heating[hysteresis][action]">
<option value="0" data-i18n>settings.heating.hyst.action.disableHeating</option>
<option value="1" data-i18n>settings.heating.hyst.action.set0target</option>
</select>
</label>
</div>
</div>
<small data-i18n>settings.heating.hyst.desc</small>
</details>
<hr /> <hr />
@@ -660,6 +687,11 @@
<span data-i18n>settings.ot.options.setDateAndTime</span> <span data-i18n>settings.ot.options.setDateAndTime</span>
</label> </label>
<label>
<input type="checkbox" name="opentherm[options][alwaysSetIndoorTemp]" value="true">
<span data-i18n>settings.ot.options.alwaysSetIndoorTemp</span>
</label>
<label> <label>
<input type="checkbox" name="opentherm[options][immergasFix]" value="true"> <input type="checkbox" name="opentherm[options][immergasFix]" value="true">
<span data-i18n>settings.ot.options.immergasFix</span> <span data-i18n>settings.ot.options.immergasFix</span>
@@ -1090,6 +1122,7 @@
setCheckboxValue("[name='opentherm[options][autoFaultReset]']", data.opentherm.options.autoFaultReset); setCheckboxValue("[name='opentherm[options][autoFaultReset]']", data.opentherm.options.autoFaultReset);
setCheckboxValue("[name='opentherm[options][autoDiagReset]']", data.opentherm.options.autoDiagReset); setCheckboxValue("[name='opentherm[options][autoDiagReset]']", data.opentherm.options.autoDiagReset);
setCheckboxValue("[name='opentherm[options][setDateAndTime]']", data.opentherm.options.setDateAndTime); setCheckboxValue("[name='opentherm[options][setDateAndTime]']", data.opentherm.options.setDateAndTime);
setCheckboxValue("[name='opentherm[options][alwaysSetIndoorTemp]']", data.opentherm.options.alwaysSetIndoorTemp);
setCheckboxValue("[name='opentherm[options][nativeHeatingControl]']", data.opentherm.options.nativeHeatingControl); setCheckboxValue("[name='opentherm[options][nativeHeatingControl]']", data.opentherm.options.nativeHeatingControl);
setCheckboxValue("[name='opentherm[options][immergasFix]']", data.opentherm.options.immergasFix); setCheckboxValue("[name='opentherm[options][immergasFix]']", data.opentherm.options.immergasFix);
setBusy('#ot-settings-busy', '#ot-settings', false); setBusy('#ot-settings-busy', '#ot-settings', false);
@@ -1138,7 +1171,9 @@
"min": data.system.unitSystem == 0 ? 1 : 33, "min": data.system.unitSystem == 0 ? 1 : 33,
"max": data.system.unitSystem == 0 ? 100 : 212 "max": data.system.unitSystem == 0 ? 100 : 212
}); });
setInputValue("[name='heating[hysteresis]']", data.heating.hysteresis); setCheckboxValue("[name='heating[hysteresis][enabled]']", data.heating.hysteresis.enabled);
setInputValue("[name='heating[hysteresis][value]']", data.heating.hysteresis.value);
setSelectValue("[name='heating[hysteresis][action]']", data.heating.hysteresis.action);
setInputValue("[name='heating[turboFactor]']", data.heating.turboFactor); setInputValue("[name='heating[turboFactor]']", data.heating.turboFactor);
setInputValue("[name='heating[maxModulation]']", data.heating.maxModulation); setInputValue("[name='heating[maxModulation]']", data.heating.maxModulation);
setInputValue("[name='heating[overheatProtection][highTemp]']", data.heating.overheatProtection.highTemp, { setInputValue("[name='heating[overheatProtection][highTemp]']", data.heating.overheatProtection.highTemp, {