Centrally define Watt (#21570)

* centralize Watt definition

* lint
This commit is contained in:
Diogo Gomes authored and Daniel Høyer Iversen committed 2019-03-02 11:29:59 +01:00
1 parent e55ce61100
commit ed2b9e5483
26 files changed
+70 -58

No files matched your search

+2 -2
View File
@@ -2,7 +2,7 @@
import logging
from homeassistant.components.homematic import ATTR_DISCOVER_DEVICES, HMDevice
from homeassistant.const import STATE_UNKNOWN
from homeassistant.const import STATE_UNKNOWN, POWER_WATT
_LOGGER = logging.getLogger(__name__)
@@ -24,7 +24,7 @@ HM_UNIT_HA_CAST = {
'TEMPERATURE': '°C',
'ACTUAL_TEMPERATURE': '°C',
'BRIGHTNESS': '#',
'POWER': 'W',
'POWER': POWER_WATT,
'CURRENT': 'mA',
'VOLTAGE': 'V',
'ENERGY_COUNTER': 'Wh',