diff --git a/src/devices/boiler.cpp b/src/devices/boiler.cpp index d01e247ee..54c7fa571 100644 --- a/src/devices/boiler.cpp +++ b/src/devices/boiler.cpp @@ -410,18 +410,18 @@ Boiler::Boiler(uint8_t device_type, int8_t device_id, uint8_t product_id, const DeviceValueNumOp::DV_NUMOP_DIV100, FL_(meterEHeat), DeviceValueUOM::KWH); - register_device_value(DeviceValueTAG::TAG_BOILER_DATA_WW, - &meterWw_, - DeviceValueType::ULONG, - DeviceValueNumOp::DV_NUMOP_DIV100, - FL_(meterWw), - DeviceValueUOM::KWH); register_device_value(DeviceValueTAG::TAG_DEVICE_DATA, &meterHeat_, DeviceValueType::ULONG, DeviceValueNumOp::DV_NUMOP_DIV100, FL_(meterHeat), DeviceValueUOM::KWH); + register_device_value(DeviceValueTAG::TAG_BOILER_DATA_WW, + &meterWw_, + DeviceValueType::ULONG, + DeviceValueNumOp::DV_NUMOP_DIV100, + FL_(meterWw), + DeviceValueUOM::KWH); register_device_value(DeviceValueTAG::TAG_DEVICE_DATA, &upTimeTotal_, DeviceValueType::TIME, diff --git a/src/devices/heatpump.cpp b/src/devices/heatpump.cpp index 065884496..5b101d761 100644 --- a/src/devices/heatpump.cpp +++ b/src/devices/heatpump.cpp @@ -149,7 +149,7 @@ Heatpump::Heatpump(uint8_t device_type, uint8_t device_id, uint8_t product_id, c MAKE_CF_CB(set_heatDrainPan)); register_device_value(DeviceValueTAG::TAG_DEVICE_DATA, &heatCable_, DeviceValueType::BOOL, FL_(heatCable), DeviceValueUOM::NONE, MAKE_CF_CB(set_heatCable)); register_device_value(DeviceValueTAG::TAG_DEVICE_DATA, &nrgTotal_, DeviceValueType::ULONG, DeviceValueNumOp::DV_NUMOP_DIV100, FL_(nrgTotal), DeviceValueUOM::KWH); - register_device_value(DeviceValueTAG::TAG_BOILER_DATA_WW, &nrgWw_, DeviceValueType::ULONG, DeviceValueNumOp::DV_NUMOP_DIV100, FL_(nrgWw), DeviceValueUOM::KWH); + register_device_value(DeviceValueTAG::TAG_DEVICE_DATA_WW, &nrgWw_, DeviceValueType::ULONG, DeviceValueNumOp::DV_NUMOP_DIV100, FL_(nrgWw), DeviceValueUOM::KWH); register_device_value(DeviceValueTAG::TAG_DEVICE_DATA, &nrgHeat_, DeviceValueType::ULONG, DeviceValueNumOp::DV_NUMOP_DIV100, FL_(nrgHeat), DeviceValueUOM::KWH); register_device_value(DeviceValueTAG::TAG_DEVICE_DATA, &meterTotal_, @@ -175,6 +175,7 @@ Heatpump::Heatpump(uint8_t device_type, uint8_t device_id, uint8_t product_id, c DeviceValueNumOp::DV_NUMOP_DIV100, FL_(meterHeat), DeviceValueUOM::KWH); + register_device_value(DeviceValueTAG::TAG_DEVICE_DATA_WW, &meterWw_, DeviceValueType::ULONG, DeviceValueNumOp::DV_NUMOP_DIV100, FL_(meterWw), DeviceValueUOM::KWH); } /* @@ -271,6 +272,7 @@ void Heatpump::process_HpMeters(std::shared_ptr telegram) { has_update(telegram, meterComp_, 4); has_update(telegram, meterEHeat_, 8); has_update(telegram, meterHeat_, 24); + has_update(telegram, meterWw_, 32); } /* diff --git a/src/devices/heatpump.h b/src/devices/heatpump.h index 5512e2b77..117e788c2 100644 --- a/src/devices/heatpump.h +++ b/src/devices/heatpump.h @@ -74,6 +74,7 @@ class Heatpump : public EMSdevice { uint32_t meterComp_; uint32_t meterEHeat_; uint32_t meterHeat_; + uint32_t meterWw_; void process_HPMonitor1(std::shared_ptr telegram); diff --git a/src/devices/thermostat.cpp b/src/devices/thermostat.cpp index 992b738b0..a6f174db8 100644 --- a/src/devices/thermostat.cpp +++ b/src/devices/thermostat.cpp @@ -1839,7 +1839,9 @@ bool Thermostat::set_remotetemp(const char * value, const int8_t id) { } else if ((model() == EMSdevice::EMS_DEVICE_FLAG_BC400) || model() == EMSdevice::EMS_DEVICE_FLAG_RC300) { if (hc->control == 1) { Roomctrl::set_remotetemp(Roomctrl::RC200, hc->hc(), hc->remotetemp); // RC200 - } else { + } else if (hc->control == 0) { + Roomctrl::set_remotetemp(Roomctrl::SENSOR, hc->hc(), hc->remotetemp); // RF Sensor + } else { // RC100(2) and RC100H(3) Roomctrl::set_remotetemp(Roomctrl::RC100H, hc->hc(), hc->remotetemp); // RC100H } } diff --git a/src/roomcontrol.cpp b/src/roomcontrol.cpp index 62f10f690..6dd0e5e9f 100644 --- a/src/roomcontrol.cpp +++ b/src/roomcontrol.cpp @@ -114,7 +114,7 @@ void Roomctrl::send(uint8_t addr) { } else if (type_ == FB10) { rc_time_[hc] = uuid::get_uptime(); temperature(addr, 0x10, hc); // send to master-thermostat (https://github.com/emsesp/EMS-ESP32/issues/336) - } else { // type==RC20 + } else { // type==RC20 or SENSOR rc_time_[hc] = uuid::get_uptime(); temperature(addr, 0x00, hc); // send to all } @@ -131,8 +131,11 @@ void Roomctrl::send(uint8_t addr) { * check if there is a message for the remote room controller */ void Roomctrl::check(uint8_t addr, const uint8_t * data, const uint8_t length) { - uint8_t hc = get_hc(addr); + if (type_ == SENSOR) { + return; + } + uint8_t hc = get_hc(addr); // check address, reply only on addresses 0x18..0x1B if (hc >= HCS || length < 5) { return; diff --git a/src/version.h b/src/version.h index 98efed320..494ba5d68 100644 --- a/src/version.h +++ b/src/version.h @@ -1 +1 @@ -#define EMSESP_APP_VERSION "3.6.5-test.12a" +#define EMSESP_APP_VERSION "3.6.5-test.12b"