Enable statistics for WLED WiFi RSSI/Signal sensors (#76789)
parent
8f0f734c28
commit
f443edfef4
|
@ -96,6 +96,7 @@ SENSORS: tuple[WLEDSensorEntityDescription, ...] = (
|
|||
name="Wi-Fi signal",
|
||||
icon="mdi:wifi",
|
||||
native_unit_of_measurement=PERCENTAGE,
|
||||
state_class=SensorStateClass.MEASUREMENT,
|
||||
entity_category=EntityCategory.DIAGNOSTIC,
|
||||
entity_registry_enabled_default=False,
|
||||
value_fn=lambda device: device.info.wifi.signal if device.info.wifi else None,
|
||||
|
@ -105,6 +106,7 @@ SENSORS: tuple[WLEDSensorEntityDescription, ...] = (
|
|||
name="Wi-Fi RSSI",
|
||||
native_unit_of_measurement=SIGNAL_STRENGTH_DECIBELS_MILLIWATT,
|
||||
device_class=SensorDeviceClass.SIGNAL_STRENGTH,
|
||||
state_class=SensorStateClass.MEASUREMENT,
|
||||
entity_category=EntityCategory.DIAGNOSTIC,
|
||||
entity_registry_enabled_default=False,
|
||||
value_fn=lambda device: device.info.wifi.rssi if device.info.wifi else None,
|
||||
|
|
Loading…
Reference in New Issue