Adding support for HmIP-SLO (outdoor brightness sensor) (#17413)

* Add IPBrightnessSensor

* Add ILLUMINATION unit & icon

* Update homematic.py

* Added missing entry
pull/17419/head
noxhirsch 2018-10-13 22:58:41 +02:00 committed by Fabian Affolter
parent d0da265166
commit 0dd3640c78
2 changed files with 9 additions and 1 deletions

View File

@ -76,7 +76,7 @@ HM_DEVICE_TYPES = {
'IPSmoke', 'RFSiren', 'PresenceIP', 'IPAreaThermostat',
'IPWeatherSensor', 'RotaryHandleSensorIP', 'IPPassageSensor',
'IPKeySwitchPowermeter', 'IPThermostatWall230V', 'IPWeatherSensorPlus',
'IPWeatherSensorBasic'],
'IPWeatherSensorBasic', 'IPBrightnessSensor'],
DISCOVER_CLIMATE: [
'Thermostat', 'ThermostatWall', 'MAXThermostat', 'ThermostatWall2',
'MAXWallThermostat', 'IPThermostat', 'IPThermostatWall',

View File

@ -48,6 +48,10 @@ HM_UNIT_HA_CAST = {
'GAS_POWER': 'm3',
'GAS_ENERGY_COUNTER': 'm3',
'LUX': 'lx',
'CURRENT_ILLUMINATION': 'lx',
'AVERAGE_ILLUMINATION': 'lx',
'LOWEST_ILLUMINATION': 'lx',
'HIGHEST_ILLUMINATION': 'lx',
'RAIN_COUNTER': 'mm',
'WIND_SPEED': 'km/h',
'WIND_DIRECTION': '°',
@ -64,6 +68,10 @@ HM_ICON_HA_CAST = {
'TEMPERATURE': 'mdi:thermometer',
'ACTUAL_TEMPERATURE': 'mdi:thermometer',
'LUX': 'mdi:weather-sunny',
'CURRENT_ILLUMINATION': 'mdi:weather-sunny',
'AVERAGE_ILLUMINATION': 'mdi:weather-sunny',
'LOWEST_ILLUMINATION': 'mdi:weather-sunny',
'HIGHEST_ILLUMINATION': 'mdi:weather-sunny',
'BRIGHTNESS': 'mdi:invert-colors',
'POWER': 'mdi:flash-red-eye',
'CURRENT': 'mdi:flash-red-eye',