From b57814209946ae021e50a927bbfebd944e00f14e Mon Sep 17 00:00:00 2001 From: SchiZzA Date: Sun, 21 Jun 2026 11:17:38 +0200 Subject: [PATCH] fix(wslink): Definiton of HCHO, VOC, T9 battery diplicates. --- custom_components/sws12500/sensors_wslink.py | 35 -------------------- 1 file changed, 35 deletions(-) diff --git a/custom_components/sws12500/sensors_wslink.py b/custom_components/sws12500/sensors_wslink.py index 9b981d1..d0f9e22 100644 --- a/custom_components/sws12500/sensors_wslink.py +++ b/custom_components/sws12500/sensors_wslink.py @@ -551,39 +551,4 @@ SENSOR_TYPES_WSLINK: tuple[WeatherSensorEntityDescription, ...] = ( suggested_display_precision=0, value_fn=battery_5step_to_pct, ), - WeatherSensorEntityDescription( - key=HCHO, - translation_key=HCHO, - device_class=SensorDeviceClass.VOLATILE_ORGANIC_COMPOUNDS_PARTS, - native_unit_of_measurement=CONCENTRATION_PARTS_PER_BILLION, - state_class=SensorStateClass.MEASUREMENT, - icon="mdi:molecule", - value_fn=to_int, - ), - WeatherSensorEntityDescription( - key=HCHO, - translation_key=HCHO, - device_class=SensorDeviceClass.VOLATILE_ORGANIC_COMPOUNDS_PARTS, - native_unit_of_measurement=CONCENTRATION_PARTS_PER_BILLION, - state_class=SensorStateClass.MEASUREMENT, - icon="mdi:molecule", - value_fn=to_int, - ), - WeatherSensorEntityDescription( - key=VOC, - translation_key=VOC, - device_class=SensorDeviceClass.ENUM, - options=list(VOCLevel), - icon="mdi:air-filter", - value_from_data_fn=lambda data: voc_level_to_text(data.get(VOC, None)), - ), - WeatherSensorEntityDescription( - key=T9_BATTERY, - translation_key=T9_BATTERY, - device_class=SensorDeviceClass.BATTERY, - native_unit_of_measurement=PERCENTAGE, - state_class=SensorStateClass.MEASUREMENT, - suggested_display_precision=0, - value_fn=battery_5step_to_pct, - ), )