mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-07 08:19:52 +03:00
add settings for #1389
This commit is contained in:
@@ -1108,6 +1108,9 @@ void Thermostat::process_RC300Summer2(std::shared_ptr<const Telegram> telegram)
|
||||
has_update(hc->summersetmode, EMS_VALUE_UINT_NOTSET);
|
||||
}
|
||||
has_update(telegram, hc->summertemp, 1);
|
||||
has_update(telegram, hc->heatondelay, 2);
|
||||
has_update(telegram, hc->heatoffdelay, 3);
|
||||
has_update(telegram, hc->instantstart, 4);
|
||||
}
|
||||
|
||||
// types 0x29B ff
|
||||
@@ -2728,6 +2731,48 @@ bool Thermostat::set_boosttime(const char * value, const int8_t id) {
|
||||
return true;
|
||||
}
|
||||
|
||||
bool Thermostat::set_heatondelay(const char * value, const int8_t id) {
|
||||
uint8_t hc_num = (id == -1) ? AUTO_HEATING_CIRCUIT : id;
|
||||
std::shared_ptr<Thermostat::HeatingCircuit> hc = heating_circuit(hc_num);
|
||||
if (hc == nullptr) {
|
||||
return false;
|
||||
}
|
||||
int v;
|
||||
if (!Helpers::value2number(value, v)) {
|
||||
return false;
|
||||
}
|
||||
write_command(summer2_typeids[hc->hc()], 2, (uint8_t)v, summer2_typeids[hc->hc()]);
|
||||
return true;
|
||||
}
|
||||
|
||||
bool Thermostat::set_heatoffdelay(const char * value, const int8_t id) {
|
||||
uint8_t hc_num = (id == -1) ? AUTO_HEATING_CIRCUIT : id;
|
||||
std::shared_ptr<Thermostat::HeatingCircuit> hc = heating_circuit(hc_num);
|
||||
if (hc == nullptr) {
|
||||
return false;
|
||||
}
|
||||
int v;
|
||||
if (!Helpers::value2number(value, v)) {
|
||||
return false;
|
||||
}
|
||||
write_command(summer2_typeids[hc->hc()], 3, (uint8_t)v, summer2_typeids[hc->hc()]);
|
||||
return true;
|
||||
}
|
||||
|
||||
bool Thermostat::set_instantstart(const char * value, const int8_t id) {
|
||||
uint8_t hc_num = (id == -1) ? AUTO_HEATING_CIRCUIT : id;
|
||||
std::shared_ptr<Thermostat::HeatingCircuit> hc = heating_circuit(hc_num);
|
||||
if (hc == nullptr) {
|
||||
return false;
|
||||
}
|
||||
int v;
|
||||
if (!Helpers::value2number(value, v)) {
|
||||
return false;
|
||||
}
|
||||
write_command(summer2_typeids[hc->hc()], 4, (uint8_t)v, summer2_typeids[hc->hc()]);
|
||||
return true;
|
||||
}
|
||||
|
||||
// sets the thermostat reducemode for RC35 and RC310
|
||||
bool Thermostat::set_reducemode(const char * value, const int8_t id) {
|
||||
uint8_t hc_num = (id == -1) ? AUTO_HEATING_CIRCUIT : id;
|
||||
@@ -4350,6 +4395,9 @@ void Thermostat::register_device_values_hc(std::shared_ptr<Thermostat::HeatingCi
|
||||
-1,
|
||||
101);
|
||||
register_device_value(tag, &hc->remotehum, DeviceValueType::UINT, FL_(remotehum), DeviceValueUOM::PERCENT, MAKE_CF_CB(set_remotehum), -1, 101);
|
||||
register_device_value(tag, &hc->heatondelay, DeviceValueType::UINT, FL_(heatondelay), DeviceValueUOM::HOURS, MAKE_CF_CB(set_heatondelay), 1, 48);
|
||||
register_device_value(tag, &hc->heatoffdelay, DeviceValueType::UINT, FL_(heatoffdelay), DeviceValueUOM::HOURS, MAKE_CF_CB(set_heatoffdelay), 1, 48);
|
||||
register_device_value(tag, &hc->instantstart, DeviceValueType::UINT, FL_(instantstart), DeviceValueUOM::K, MAKE_CF_CB(set_instantstart), 1, 10);
|
||||
register_device_value(tag, &hc->boost, DeviceValueType::BOOL, FL_(boost), DeviceValueUOM::NONE, MAKE_CF_CB(set_boost));
|
||||
register_device_value(tag, &hc->boosttime, DeviceValueType::UINT, FL_(boosttime), DeviceValueUOM::HOURS, MAKE_CF_CB(set_boosttime));
|
||||
|
||||
|
||||
@@ -98,8 +98,12 @@ class Thermostat : public EMSdevice {
|
||||
uint8_t hpmode;
|
||||
uint8_t cooling;
|
||||
uint8_t coolingon;
|
||||
// RC300
|
||||
uint8_t heatoffdelay; // 1-48h
|
||||
uint8_t heatondelay; // 1-48h
|
||||
uint8_t instantstart; // 1-10K
|
||||
uint8_t boost;
|
||||
uint8_t boosttime;
|
||||
uint8_t boosttime; // hours
|
||||
|
||||
uint8_t hc_num() const {
|
||||
return hc_num_;
|
||||
@@ -441,6 +445,9 @@ class Thermostat : public EMSdevice {
|
||||
bool set_wwprio(const char * value, const int8_t id);
|
||||
bool set_fastheatup(const char * value, const int8_t id);
|
||||
bool set_switchonoptimization(const char * value, const int8_t id);
|
||||
bool set_heatondelay(const char * value, const int8_t id);
|
||||
bool set_heatoffdelay(const char * value, const int8_t id);
|
||||
bool set_instantstart(const char * value, const int8_t id);
|
||||
bool set_boost(const char * value, const int8_t id);
|
||||
bool set_boosttime(const char * value, const int8_t id);
|
||||
|
||||
|
||||
@@ -459,6 +459,9 @@ MAKE_TRANSLATION(hpEA0, "hpea0", "condensate reservoir heating (EA0)", "Heizung
|
||||
MAKE_TRANSLATION(boost, "boost", "boost mode", "Boost", "", "", "", "", "", "", "") // TODO translate
|
||||
MAKE_TRANSLATION(boosttime, "boosttime", "boost time", "Boost Dauer", "", "", "", "", "", "", "") // TODO translate
|
||||
MAKE_TRANSLATION(hpPumpMode, "hppumpmode", "primary heatpump mode", "Modus Hauptpumpe", "", "", "", "", "", "", "") // TODO translate
|
||||
MAKE_TRANSLATION(instantstart, "instantstart", "instant start", "Sofortstart", "", "", "", "", "", "", "") // TODO translate
|
||||
MAKE_TRANSLATION(heatondelay, "heatondelay", "heat-on delay", "Einschaltverzögerung Heizen", "", "", "", "", "", "", "") // TODO translate
|
||||
MAKE_TRANSLATION(heatoffdelay, "heatoffdelay", "heat-off delay", "Ausschaltverzögerung Heizen", "", "", "", "", "", "", "") // TODO translate
|
||||
|
||||
// hybrid heatpump
|
||||
MAKE_TRANSLATION(hybridStrategy, "hybridstrategy", "hybrid control strategy", "Hybrid Strategie", "Hybride strategie", "Hybrid kontrollstrategi", "strategia sterowania hybrydowego", "hybrid kontrollstrategi", "stratégie contrôle hybride", "hibrit kontrol stratejisi", "strategia comtrollo ibrido")
|
||||
|
||||
Reference in New Issue
Block a user