From 3f3e7ec38cc7e162687b3c8cc881474e8487f82e Mon Sep 17 00:00:00 2001 From: Nick Nissen Date: Thu, 21 Sep 2023 18:55:33 +0000 Subject: [PATCH] Add last meter reading which provide the last charge in kWh --- custom_components/monta/sensor.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/custom_components/monta/sensor.py b/custom_components/monta/sensor.py index 7bd13ed..90484d6 100644 --- a/custom_components/monta/sensor.py +++ b/custom_components/monta/sensor.py @@ -49,6 +49,13 @@ class MontaSensorEntityDescription(SensorEntityDescription): device_class=SensorDeviceClass.ENUM, options=[x.value for x in ChargerStatus], ), + SensorEntityDescription( + key="charger_lastMeterReadingKwh", + name="Last meter reading", + icon="mdi:counter", + device_class=SensorDeviceClass.ENERGY, + native_unit_of_measurement="kWh", + ), )