From c29306e0741b586b1effd60aea6461c3b174940d Mon Sep 17 00:00:00 2001 From: rejoe2 Date: Thu, 16 May 2024 08:31:17 +0200 Subject: [PATCH] Fix MI overnight behaviour will now calculate AC values after midnight reset of state array --- src/hm/Communication.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/hm/Communication.h b/src/hm/Communication.h index c4881535..3192c513 100644 --- a/src/hm/Communication.h +++ b/src/hm/Communication.h @@ -895,7 +895,7 @@ class Communication : public CommQueue<> { uint8_t oldState = rec->record[q->iv->getPosByChFld(0, FLD_EVT, rec)]; if ( prntsts != oldState ) { // sth.'s changed? stsok = false; - if(!oldState) { // initial zero value? => just write this channel to main state and raise changed flags + if( (!oldState) || (!q->iv->alarmCnt) ) { // initial zero value? => just write this channel to main state and raise changed flags changedStatus = true; q->iv->alarmCnt = 1; // minimum... } else {