interrupt full heat cycle when pump starts
This commit is contained in:
parent
39a8ecde85
commit
3a5f1a3a74
@ -62,7 +62,10 @@ void Heating::init(unsigned mode, const SettingState *settings, HeatingInfoServi
|
|||||||
});
|
});
|
||||||
|
|
||||||
mHeizungTicker.attach(10, [this]() {
|
mHeizungTicker.attach(10, [this]() {
|
||||||
|
// only check if no pump cycle is active
|
||||||
|
if (!mPumpCycleActive) {
|
||||||
sensor.read();
|
sensor.read();
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
break;
|
break;
|
||||||
@ -78,10 +81,8 @@ void Heating::handleHeatingEvents() {
|
|||||||
// turn off active turnoff timers
|
// turn off active turnoff timers
|
||||||
mLuefterTicker.detach();
|
mLuefterTicker.detach();
|
||||||
//Serial.println("heating should run now!");
|
//Serial.println("heating should run now!");
|
||||||
// turn on heating and fan
|
|
||||||
if (!mPumpCycleActive) {
|
|
||||||
digitalWrite(LuefterPin, HIGH);
|
digitalWrite(LuefterPin, HIGH);
|
||||||
}
|
|
||||||
|
|
||||||
digitalWrite(HeizungPin, HIGH);
|
digitalWrite(HeizungPin, HIGH);
|
||||||
|
|
||||||
@ -150,9 +151,21 @@ void Heating::setPumCycleActive(bool active) {
|
|||||||
// turn off fan if pumpcycleactive
|
// turn off fan if pumpcycleactive
|
||||||
if (active) {
|
if (active) {
|
||||||
digitalWrite(LuefterPin, LOW);
|
digitalWrite(LuefterPin, LOW);
|
||||||
} else {
|
digitalWrite(HeizungPin, LOW);
|
||||||
|
|
||||||
|
mHeizungTicker.detach();
|
||||||
|
|
||||||
if (mHeatingStatus) {
|
if (mHeatingStatus) {
|
||||||
digitalWrite(LuefterPin, HIGH);
|
// to add the correct time to the heat min counter!
|
||||||
|
mheatingservice->addHeatTime(Timer::getSystemSeconds() - mheatingservice->getLastHeatingStartTime());
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
mHeizungTicker.detach();
|
||||||
|
mHeizungTicker.attach(10, [this]() {
|
||||||
|
// only check if no pump cycle is active
|
||||||
|
if (!mPumpCycleActive) {
|
||||||
|
sensor.read();
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user