From c698337b955a864728935800cf68b0a63e3299e6 Mon Sep 17 00:00:00 2001 From: Yurii Date: Tue, 20 Oct 2026 05:26:31 +0300 Subject: [PATCH] fix: always send initial OpenTherm setpoints --- src/OpenThermTask.h | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/src/OpenThermTask.h b/src/OpenThermTask.h index 7d3074c..bc9cf5c 100644 --- a/src/OpenThermTask.h +++ b/src/OpenThermTask.h @@ -93,6 +93,9 @@ protected: this->instanceOutGpio = settings.opentherm.outGpio; this->resetBusTime = millis(); this->initialized = false; + this->heatingSetTempTime = 0; + this->dhwSetTempTime = 0; + this->ch2SetTempTime = 0; this->roomSetTempTime = 0; this->roomSetTempCh2Time = 0; @@ -1584,17 +1587,20 @@ protected: } bool needSetDhwTemp(const float target) { - return millis() - this->dhwSetTempTime > this->dhwSetTempInterval + return !this->dhwSetTempTime + || millis() - this->dhwSetTempTime > this->dhwSetTempInterval || fabsf(target - vars.slave.dhw.targetTemp) > 0.05f; } bool needSetHeatingTemp(const float target) { - return millis() - this->heatingSetTempTime > this->heatingSetTempInterval + return !this->heatingSetTempTime + || millis() - this->heatingSetTempTime > this->heatingSetTempInterval || fabsf(target - vars.slave.heating.targetTemp) > 0.05f; } bool needSetCh2Temp(const float target) { - return millis() - this->ch2SetTempTime > this->ch2SetTempInterval + return !this->ch2SetTempTime + || millis() - this->ch2SetTempTime > this->ch2SetTempInterval || fabsf(target - vars.slave.ch2.targetTemp) > 0.05f; }