Add new irradiance device class (#83452)
parent
90438edc17
commit
c4326ed1ef
|
@ -143,6 +143,14 @@ class NumberDeviceClass(StrEnum):
|
|||
Unit of measurement: `lx`, `lm`
|
||||
"""
|
||||
|
||||
IRRADIANCE = "irradiance"
|
||||
"""Irradiance.
|
||||
|
||||
Unit of measurement:
|
||||
- SI / metric: `W/m²`
|
||||
- USCS / imperial: `BTU/(h⋅ft²)`
|
||||
"""
|
||||
|
||||
MOISTURE = "moisture"
|
||||
"""Moisture.
|
||||
|
||||
|
|
|
@ -207,6 +207,14 @@ class SensorDeviceClass(StrEnum):
|
|||
Unit of measurement: `lx`, `lm`
|
||||
"""
|
||||
|
||||
IRRADIANCE = "irradiance"
|
||||
"""Irradiance.
|
||||
|
||||
Unit of measurement:
|
||||
- SI / metric: `W/m²`
|
||||
- USCS / imperial: `BTU/(h⋅ft²)`
|
||||
"""
|
||||
|
||||
MOISTURE = "moisture"
|
||||
"""Moisture.
|
||||
|
||||
|
|
|
@ -44,6 +44,7 @@ CONF_IS_FREQUENCY = "is_frequency"
|
|||
CONF_IS_HUMIDITY = "is_humidity"
|
||||
CONF_IS_GAS = "is_gas"
|
||||
CONF_IS_ILLUMINANCE = "is_illuminance"
|
||||
CONF_IS_IRRADIANCE = "is_irradiance"
|
||||
CONF_IS_MOISTURE = "is_moisture"
|
||||
CONF_IS_NITROGEN_DIOXIDE = "is_nitrogen_dioxide"
|
||||
CONF_IS_NITROGEN_MONOXIDE = "is_nitrogen_monoxide"
|
||||
|
@ -84,6 +85,7 @@ ENTITY_CONDITIONS = {
|
|||
SensorDeviceClass.GAS: [{CONF_TYPE: CONF_IS_GAS}],
|
||||
SensorDeviceClass.HUMIDITY: [{CONF_TYPE: CONF_IS_HUMIDITY}],
|
||||
SensorDeviceClass.ILLUMINANCE: [{CONF_TYPE: CONF_IS_ILLUMINANCE}],
|
||||
SensorDeviceClass.IRRADIANCE: [{CONF_TYPE: CONF_IS_IRRADIANCE}],
|
||||
SensorDeviceClass.MOISTURE: [{CONF_TYPE: CONF_IS_MOISTURE}],
|
||||
SensorDeviceClass.NITROGEN_DIOXIDE: [{CONF_TYPE: CONF_IS_NITROGEN_DIOXIDE}],
|
||||
SensorDeviceClass.NITROGEN_MONOXIDE: [{CONF_TYPE: CONF_IS_NITROGEN_MONOXIDE}],
|
||||
|
@ -134,6 +136,7 @@ CONDITION_SCHEMA = vol.All(
|
|||
CONF_IS_GAS,
|
||||
CONF_IS_HUMIDITY,
|
||||
CONF_IS_ILLUMINANCE,
|
||||
CONF_IS_IRRADIANCE,
|
||||
CONF_IS_MOISTURE,
|
||||
CONF_IS_NITROGEN_DIOXIDE,
|
||||
CONF_IS_NITROGEN_MONOXIDE,
|
||||
|
|
|
@ -43,6 +43,7 @@ CONF_FREQUENCY = "frequency"
|
|||
CONF_GAS = "gas"
|
||||
CONF_HUMIDITY = "humidity"
|
||||
CONF_ILLUMINANCE = "illuminance"
|
||||
CONF_IRRADIANCE = "irradiance"
|
||||
CONF_MOISTURE = "moisture"
|
||||
CONF_NITROGEN_DIOXIDE = "nitrogen_dioxide"
|
||||
CONF_NITROGEN_MONOXIDE = "nitrogen_monoxide"
|
||||
|
@ -83,6 +84,7 @@ ENTITY_TRIGGERS = {
|
|||
SensorDeviceClass.GAS: [{CONF_TYPE: CONF_GAS}],
|
||||
SensorDeviceClass.HUMIDITY: [{CONF_TYPE: CONF_HUMIDITY}],
|
||||
SensorDeviceClass.ILLUMINANCE: [{CONF_TYPE: CONF_ILLUMINANCE}],
|
||||
SensorDeviceClass.IRRADIANCE: [{CONF_TYPE: CONF_IRRADIANCE}],
|
||||
SensorDeviceClass.MOISTURE: [{CONF_TYPE: CONF_MOISTURE}],
|
||||
SensorDeviceClass.NITROGEN_DIOXIDE: [{CONF_TYPE: CONF_NITROGEN_DIOXIDE}],
|
||||
SensorDeviceClass.NITROGEN_MONOXIDE: [{CONF_TYPE: CONF_NITROGEN_MONOXIDE}],
|
||||
|
@ -134,6 +136,7 @@ TRIGGER_SCHEMA = vol.All(
|
|||
CONF_GAS,
|
||||
CONF_HUMIDITY,
|
||||
CONF_ILLUMINANCE,
|
||||
CONF_IRRADIANCE,
|
||||
CONF_MOISTURE,
|
||||
CONF_NITROGEN_DIOXIDE,
|
||||
CONF_NITROGEN_MONOXIDE,
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
"is_gas": "Current {entity_name} gas",
|
||||
"is_humidity": "Current {entity_name} humidity",
|
||||
"is_illuminance": "Current {entity_name} illuminance",
|
||||
"is_irradiance": "Current {entity_name} irradiance",
|
||||
"is_moisture": "Current {entity_name} moisture",
|
||||
"is_nitrogen_dioxide": "Current {entity_name} nitrogen dioxide concentration level",
|
||||
"is_nitrogen_monoxide": "Current {entity_name} nitrogen monoxide concentration level",
|
||||
|
@ -51,6 +52,7 @@
|
|||
"gas": "{entity_name} gas changes",
|
||||
"humidity": "{entity_name} humidity changes",
|
||||
"illuminance": "{entity_name} illuminance changes",
|
||||
"irradiance": "{entity_name} irradiance changes",
|
||||
"moisture": "{entity_name} moisture changes",
|
||||
"nitrogen_dioxide": "{entity_name} nitrogen dioxide concentration changes",
|
||||
"nitrogen_monoxide": "{entity_name} nitrogen monoxide concentration changes",
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
"is_gas": "Current {entity_name} gas",
|
||||
"is_humidity": "Current {entity_name} humidity",
|
||||
"is_illuminance": "Current {entity_name} illuminance",
|
||||
"is_irradiance": "Current {entity_name} irradiance",
|
||||
"is_moisture": "Current {entity_name} moisture",
|
||||
"is_nitrogen_dioxide": "Current {entity_name} nitrogen dioxide concentration level",
|
||||
"is_nitrogen_monoxide": "Current {entity_name} nitrogen monoxide concentration level",
|
||||
|
@ -51,6 +52,7 @@
|
|||
"gas": "{entity_name} gas changes",
|
||||
"humidity": "{entity_name} humidity changes",
|
||||
"illuminance": "{entity_name} illuminance changes",
|
||||
"irradiance": "{entity_name} irradiance changes",
|
||||
"moisture": "{entity_name} moisture changes",
|
||||
"nitrogen_dioxide": "{entity_name} nitrogen dioxide concentration changes",
|
||||
"nitrogen_monoxide": "{entity_name} nitrogen monoxide concentration changes",
|
||||
|
|
Loading…
Reference in New Issue