mirror of
https://github.com/lumapu/ahoy.git
synced 2025-07-27 13:17:11 +02:00
Fix MI overnight behaviour
will now calculate AC values after midnight reset of state array
This commit is contained in:
parent
85e3dea281
commit
c29306e074
1 changed files with 1 additions and 1 deletions
|
@ -895,7 +895,7 @@ class Communication : public CommQueue<> {
|
||||||
uint8_t oldState = rec->record[q->iv->getPosByChFld(0, FLD_EVT, rec)];
|
uint8_t oldState = rec->record[q->iv->getPosByChFld(0, FLD_EVT, rec)];
|
||||||
if ( prntsts != oldState ) { // sth.'s changed?
|
if ( prntsts != oldState ) { // sth.'s changed?
|
||||||
stsok = false;
|
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;
|
changedStatus = true;
|
||||||
q->iv->alarmCnt = 1; // minimum...
|
q->iv->alarmCnt = 1; // minimum...
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue