Add new DSMR Reader fields that were added to MQTT (#36337)

This commit is contained in:
Wim Haanstra 2020-06-01 14:10:09 +02:00 committed by GitHub
parent d0fedad000
commit aa1b32ad36
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,6 +1,11 @@
"""Definitions for DSMR Reader sensors added to MQTT."""
from homeassistant.const import ENERGY_KILO_WATT_HOUR, VOLT, VOLUME_CUBIC_METERS
from homeassistant.const import (
ELECTRICAL_CURRENT_AMPERE,
ENERGY_KILO_WATT_HOUR,
VOLT,
VOLUME_CUBIC_METERS,
)
def dsmr_transform(value):
@ -98,6 +103,21 @@ DEFINITIONS = {
"icon": "mdi:flash",
"unit": VOLT,
},
"dsmr/reading/phase_power_current_l1": {
"name": "Phase power current L1",
"icon": "mdi:flash",
"unit": ELECTRICAL_CURRENT_AMPERE,
},
"dsmr/reading/phase_power_current_l2": {
"name": "Phase power current L2",
"icon": "mdi:flash",
"unit": ELECTRICAL_CURRENT_AMPERE,
},
"dsmr/reading/phase_power_current_l3": {
"name": "Phase power current L3",
"icon": "mdi:flash",
"unit": ELECTRICAL_CURRENT_AMPERE,
},
"dsmr/consumption/gas/delivered": {
"name": "Gas usage",
"icon": "mdi:fire",