Adaptations for new sensors

This commit is contained in:
Gunnar Skjold
2024-01-06 20:10:33 +01:00
parent 333169ef8f
commit 8a59fcb89a
7 changed files with 52 additions and 22 deletions

View File

@@ -110,7 +110,13 @@ bool HomeAssistantMqttHandler::publishList4(AmsData* data, EnergyAccounting* ea)
data->getPowerFactor() == 0 ? 1 : data->getPowerFactor(),
data->getPowerFactor() == 0 ? 1 : data->getL1PowerFactor(),
data->getPowerFactor() == 0 ? 1 : data->getL2PowerFactor(),
data->getPowerFactor() == 0 ? 1 : data->getL3PowerFactor()
data->getPowerFactor() == 0 ? 1 : data->getL3PowerFactor(),
data->getL1ActiveImportCounter(),
data->getL2ActiveImportCounter(),
data->getL3ActiveImportCounter(),
data->getL1ActiveExportCounter(),
data->getL2ActiveExportCounter(),
data->getL3ActiveExportCounter()
);
return mqtt.publish(topic + "/power", json);
}