diff --git a/homeassistant/components/aemet/const.py b/homeassistant/components/aemet/const.py index 46742a85beb..7058257d808 100644 --- a/homeassistant/components/aemet/const.py +++ b/homeassistant/components/aemet/const.py @@ -209,6 +209,7 @@ FORECAST_SENSOR_TYPES: tuple[SensorEntityDescription, ...] = ( key=ATTR_API_FORECAST_PRECIPITATION, name="Precipitation", native_unit_of_measurement=UnitOfVolumetricFlux.MILLIMETERS_PER_HOUR, + device_class=SensorDeviceClass.PRECIPITATION_INTENSITY, ), SensorEntityDescription( key=ATTR_API_FORECAST_PRECIPITATION_PROBABILITY, @@ -266,6 +267,7 @@ WEATHER_SENSOR_TYPES: tuple[SensorEntityDescription, ...] = ( key=ATTR_API_RAIN, name="Rain", native_unit_of_measurement=UnitOfVolumetricFlux.MILLIMETERS_PER_HOUR, + device_class=SensorDeviceClass.PRECIPITATION_INTENSITY, ), SensorEntityDescription( key=ATTR_API_RAIN_PROB, @@ -277,6 +279,7 @@ WEATHER_SENSOR_TYPES: tuple[SensorEntityDescription, ...] = ( key=ATTR_API_SNOW, name="Snow", native_unit_of_measurement=UnitOfVolumetricFlux.MILLIMETERS_PER_HOUR, + device_class=SensorDeviceClass.PRECIPITATION_INTENSITY, ), SensorEntityDescription( key=ATTR_API_SNOW_PROB, diff --git a/homeassistant/components/ambient_station/sensor.py b/homeassistant/components/ambient_station/sensor.py index 48ee70f9c84..b1e98261c6e 100644 --- a/homeassistant/components/ambient_station/sensor.py +++ b/homeassistant/components/ambient_station/sensor.py @@ -194,9 +194,9 @@ SENSOR_DESCRIPTIONS = ( SensorEntityDescription( key=TYPE_HOURLYRAININ, name="Hourly rain rate", - icon="mdi:water", native_unit_of_measurement=UnitOfVolumetricFlux.INCHES_PER_HOUR, state_class=SensorStateClass.MEASUREMENT, + device_class=SensorDeviceClass.PRECIPITATION_INTENSITY, ), SensorEntityDescription( key=TYPE_HUMIDITY10, diff --git a/homeassistant/components/buienradar/sensor.py b/homeassistant/components/buienradar/sensor.py index 52e1129dfa8..bf44c884147 100644 --- a/homeassistant/components/buienradar/sensor.py +++ b/homeassistant/components/buienradar/sensor.py @@ -184,8 +184,8 @@ SENSOR_TYPES: tuple[SensorEntityDescription, ...] = ( key="precipitation", name="Precipitation", native_unit_of_measurement=UnitOfVolumetricFlux.MILLIMETERS_PER_HOUR, - icon="mdi:weather-pouring", state_class=SensorStateClass.MEASUREMENT, + device_class=SensorDeviceClass.PRECIPITATION_INTENSITY, ), SensorEntityDescription( key="irradiance", @@ -198,7 +198,7 @@ SENSOR_TYPES: tuple[SensorEntityDescription, ...] = ( key="precipitation_forecast_average", name="Precipitation forecast average", native_unit_of_measurement=UnitOfVolumetricFlux.MILLIMETERS_PER_HOUR, - icon="mdi:weather-pouring", + device_class=SensorDeviceClass.PRECIPITATION_INTENSITY, ), SensorEntityDescription( key="precipitation_forecast_total", diff --git a/homeassistant/components/ecowitt/sensor.py b/homeassistant/components/ecowitt/sensor.py index 35e929ae2c2..200ae1d73fc 100644 --- a/homeassistant/components/ecowitt/sensor.py +++ b/homeassistant/components/ecowitt/sensor.py @@ -158,11 +158,13 @@ ECOWITT_SENSORS_MAPPING: Final = { key="RAIN_RATE_MM", native_unit_of_measurement=UnitOfVolumetricFlux.MILLIMETERS_PER_HOUR, state_class=SensorStateClass.MEASUREMENT, + device_class=SensorDeviceClass.PRECIPITATION_INTENSITY, ), EcoWittSensorTypes.RAIN_RATE_INCHES: SensorEntityDescription( key="RAIN_RATE_INCHES", native_unit_of_measurement=UnitOfVolumetricFlux.INCHES_PER_HOUR, state_class=SensorStateClass.MEASUREMENT, + device_class=SensorDeviceClass.PRECIPITATION_INTENSITY, ), EcoWittSensorTypes.LIGHTNING_DISTANCE_KM: SensorEntityDescription( key="LIGHTNING_DISTANCE_KM", diff --git a/homeassistant/components/rfxtrx/sensor.py b/homeassistant/components/rfxtrx/sensor.py index 6be2d0cf725..5f85f344e9b 100644 --- a/homeassistant/components/rfxtrx/sensor.py +++ b/homeassistant/components/rfxtrx/sensor.py @@ -173,6 +173,7 @@ SENSOR_TYPES = ( name="Rain rate", state_class=SensorStateClass.MEASUREMENT, native_unit_of_measurement=UnitOfVolumetricFlux.MILLIMETERS_PER_HOUR, + device_class=SensorDeviceClass.PRECIPITATION_INTENSITY, ), RfxtrxSensorEntityDescription( key="Sound", diff --git a/homeassistant/components/tellduslive/sensor.py b/homeassistant/components/tellduslive/sensor.py index ecccba8b734..ed3efeb4344 100644 --- a/homeassistant/components/tellduslive/sensor.py +++ b/homeassistant/components/tellduslive/sensor.py @@ -58,8 +58,8 @@ SENSOR_TYPES: dict[str, SensorEntityDescription] = { key=SENSOR_TYPE_RAINRATE, name="Rain rate", native_unit_of_measurement=UnitOfVolumetricFlux.MILLIMETERS_PER_HOUR, - icon="mdi:water", state_class=SensorStateClass.MEASUREMENT, + device_class=SensorDeviceClass.PRECIPITATION_INTENSITY, ), SENSOR_TYPE_RAINTOTAL: SensorEntityDescription( key=SENSOR_TYPE_RAINTOTAL,