From 73d03bdf1d34a40cca52372f109769243ec40190 Mon Sep 17 00:00:00 2001 From: Franck Nijhof Date: Wed, 18 Aug 2021 10:14:03 +0200 Subject: [PATCH] Add Gas device class to DSMR Reader (#54748) --- homeassistant/components/dsmr_reader/definitions.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/homeassistant/components/dsmr_reader/definitions.py b/homeassistant/components/dsmr_reader/definitions.py index 6edf2972aa4..533b2f0dd38 100644 --- a/homeassistant/components/dsmr_reader/definitions.py +++ b/homeassistant/components/dsmr_reader/definitions.py @@ -13,6 +13,7 @@ from homeassistant.const import ( CURRENCY_EURO, DEVICE_CLASS_CURRENT, DEVICE_CLASS_ENERGY, + DEVICE_CLASS_GAS, DEVICE_CLASS_POWER, DEVICE_CLASS_TIMESTAMP, DEVICE_CLASS_VOLTAGE, @@ -201,14 +202,14 @@ SENSORS: tuple[DSMRReaderSensorEntityDescription, ...] = ( DSMRReaderSensorEntityDescription( key="dsmr/consumption/gas/delivered", name="Gas usage", - icon="mdi:fire", + device_class=DEVICE_CLASS_GAS, native_unit_of_measurement=VOLUME_CUBIC_METERS, state_class=STATE_CLASS_TOTAL_INCREASING, ), DSMRReaderSensorEntityDescription( key="dsmr/consumption/gas/currently_delivered", name="Current gas usage", - icon="mdi:fire", + device_class=DEVICE_CLASS_GAS, native_unit_of_measurement=VOLUME_CUBIC_METERS, state_class=STATE_CLASS_MEASUREMENT, ),