From 46fce85b65ebbd4b869a29221901b57436e2db75 Mon Sep 17 00:00:00 2001 From: petretiandrea Date: Sat, 11 Sep 2021 11:45:22 +0000 Subject: [PATCH] added kwh factor --- custom_components/tapo/sensor.py | 2 +- hacs.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/custom_components/tapo/sensor.py b/custom_components/tapo/sensor.py index dd30f12..7153742 100644 --- a/custom_components/tapo/sensor.py +++ b/custom_components/tapo/sensor.py @@ -56,6 +56,6 @@ def native_unit_of_measurement(self) -> Optional[str]: @property def native_value(self) -> StateType: if self.coordinator.data.energy_info != None: - return self.coordinator.data.energy_info.today_energy + return self.coordinator.data.energy_info.today_energy / 1000 else: return None diff --git a/hacs.json b/hacs.json index bcfa067..9b7c8e1 100644 --- a/hacs.json +++ b/hacs.json @@ -8,5 +8,5 @@ ], "iot_class": "Local Polling", "render_readme": true, - "homeassistant": "0.118.0" + "homeassistant": "2021.9.0" } \ No newline at end of file