mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-06 15:59:52 +03:00
show wwtapactivated as value
This commit is contained in:
@@ -86,7 +86,7 @@ Boiler::Boiler(uint8_t device_type, int8_t device_id, uint8_t product_id, const
|
|||||||
}
|
}
|
||||||
// MQTT commands for boiler topic
|
// MQTT commands for boiler topic
|
||||||
register_device_value(
|
register_device_value(
|
||||||
TAG_BOILER_DATA, &dummybool_, DeviceValueType::BOOL, nullptr, FL_(wwtapactivated), DeviceValueUOM::BOOLEAN, MAKE_CF_CB(set_tapwarmwater_activated));
|
TAG_BOILER_DATA, &wWTapActivated_, DeviceValueType::BOOL, nullptr, FL_(wwtapactivated), DeviceValueUOM::BOOLEAN, MAKE_CF_CB(set_tapwarmwater_activated));
|
||||||
register_device_value(TAG_BOILER_DATA, &dummy8u_, DeviceValueType::ENUM, FL_(enum_reset), FL_(reset), DeviceValueUOM::NONE, MAKE_CF_CB(set_reset));
|
register_device_value(TAG_BOILER_DATA, &dummy8u_, DeviceValueType::ENUM, FL_(enum_reset), FL_(reset), DeviceValueUOM::NONE, MAKE_CF_CB(set_reset));
|
||||||
|
|
||||||
// add values
|
// add values
|
||||||
@@ -303,6 +303,11 @@ void Boiler::check_active(const bool force) {
|
|||||||
Mqtt::publish(F_(heating_active), Helpers::render_boolean(s, b));
|
Mqtt::publish(F_(heating_active), Helpers::render_boolean(s, b));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// check if we can use tapactivated in flow systems
|
||||||
|
if ((wWType_ == 1) && !Helpers::hasValue(wWTapActivated_, EMS_VALUE_BOOL)) {
|
||||||
|
wWTapActivated_= 1;
|
||||||
|
}
|
||||||
|
|
||||||
// check if tap water is active, bits 1 and 4 must be set
|
// check if tap water is active, bits 1 and 4 must be set
|
||||||
// also check if there is a flowsensor and flow-type
|
// also check if there is a flowsensor and flow-type
|
||||||
static bool flowsensor = false;
|
static bool flowsensor = false;
|
||||||
@@ -1150,14 +1155,16 @@ bool Boiler::set_tapwarmwater_activated(const char * value, const int8_t id) {
|
|||||||
// a setting of 0x00 puts it back into normal operating mode
|
// a setting of 0x00 puts it back into normal operating mode
|
||||||
// when in test mode we're able to mess around with the 3-way valve settings
|
// when in test mode we're able to mess around with the 3-way valve settings
|
||||||
if (!v) {
|
if (!v) {
|
||||||
// on
|
// DHW off
|
||||||
message_data[0] = 0x5A; // test mode on
|
message_data[0] = 0x5A; // test mode on
|
||||||
message_data[1] = 0x00; // burner output 0%
|
message_data[1] = 0x00; // burner output 0%
|
||||||
message_data[3] = 0x64; // boiler pump capacity 100%
|
message_data[3] = 0x64; // boiler pump capacity 100%
|
||||||
message_data[4] = 0xFF; // 3-way valve hot water only
|
message_data[4] = 0xFF; // 3-way valve hot water only
|
||||||
|
wWTapActivated_= 0;
|
||||||
} else {
|
} else {
|
||||||
// get out of test mode. Send all zeros.
|
// get out of test mode. Send all zeros.
|
||||||
// telegram: 0B 08 1D 00 00
|
// telegram: 0B 08 1D 00 00
|
||||||
|
wWTapActivated_ = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
write_command(EMS_TYPE_UBAFunctionTest, 0, message_data, sizeof(message_data), 0);
|
write_command(EMS_TYPE_UBAFunctionTest, 0, message_data, sizeof(message_data), 0);
|
||||||
|
|||||||
@@ -85,6 +85,7 @@ class Boiler : public EMSdevice {
|
|||||||
uint32_t wWWorkM_; // Warm Water # minutes
|
uint32_t wWWorkM_; // Warm Water # minutes
|
||||||
int8_t wWHystOn_;
|
int8_t wWHystOn_;
|
||||||
int8_t wWHystOff_;
|
int8_t wWHystOff_;
|
||||||
|
uint8_t wWTapActivated_; // maintenance-mode to switch DHW off
|
||||||
|
|
||||||
uint16_t mixerTemp_; // mixing temperature
|
uint16_t mixerTemp_; // mixing temperature
|
||||||
uint16_t tankMiddleTemp_; // Tank middle temperature (TS3)
|
uint16_t tankMiddleTemp_; // Tank middle temperature (TS3)
|
||||||
|
|||||||
Reference in New Issue
Block a user