mirror of
https://github.com/home-assistant/core.git
synced 2025-08-07 14:45:09 +02:00
Enable Optional Indoor Humidity sensor for Lyric (#81420)
This commit is contained in:
@@ -90,6 +90,22 @@ async def async_setup_entry(
|
||||
device,
|
||||
)
|
||||
)
|
||||
if device.indoorHumidity:
|
||||
entities.append(
|
||||
LyricSensor(
|
||||
coordinator,
|
||||
LyricSensorEntityDescription(
|
||||
key=f"{device.macID}_indoor_humidity",
|
||||
name="Indoor Humidity",
|
||||
device_class=SensorDeviceClass.HUMIDITY,
|
||||
state_class=SensorStateClass.MEASUREMENT,
|
||||
native_unit_of_measurement=PERCENTAGE,
|
||||
value=lambda device: device.indoorHumidity,
|
||||
),
|
||||
location,
|
||||
device,
|
||||
)
|
||||
)
|
||||
if device.outdoorTemperature:
|
||||
entities.append(
|
||||
LyricSensor(
|
||||
|
Reference in New Issue
Block a user