RC20RF tap water one time loading function

This commit is contained in:
Christian Weithe
2019-10-28 19:26:29 +01:00
parent 13f86edd8a
commit c62502052d
5 changed files with 41 additions and 1 deletions

View File

@@ -1292,6 +1292,28 @@ void _process_UBAMonitorWWMessage(_EMS_RxTelegram * EMS_RxTelegram) {
EMS_Boiler.wWCurFlow = _toByte(9);
}
/**
* Activate / De-activate One Time warm water 0x35
* true = on, false = off
*/
void ems_setWarmWaterOnetime(bool activated) {
myDebug_P(PSTR("Setting boiler warm water OneTime loading %s"), activated ? "on" : "off");
_EMS_TxTelegram EMS_TxTelegram = EMS_TX_TELEGRAM_NEW; // create new Tx
EMS_TxTelegram.timestamp = millis(); // set timestamp
EMS_Sys_Status.txRetryCount = 0; // reset retry counter
EMS_TxTelegram.action = EMS_TX_TELEGRAM_WRITE;
EMS_TxTelegram.dest = EMS_Boiler.device_id;
EMS_TxTelegram.type = EMS_TYPE_UBAFlags;
EMS_TxTelegram.offset = EMS_OFFSET_UBAParameterWW_wwOneTime;
EMS_TxTelegram.length = EMS_MIN_TELEGRAM_LENGTH;
EMS_TxTelegram.type_validate = EMS_ID_NONE; // don't validate
EMS_TxTelegram.dataValue = (activated ? 0x22 : 0x02); // 0x22 is on, 0x02 is off for RC20RF
EMS_TxQueue.push(EMS_TxTelegram);
}
/**
* UBAMonitorFast - type 0x18 - central heating monitor part 1 (25 bytes long)
* received every 10 seconds