Hello HA Community,
I have a air quality sensor with different sensors that are defined this way is the Yaml ESPHome: (I can share the complete code if that helps)
sensors:
- name: "${friendly_name} PM1"
id: daikinpm1
unit_of_measurement: "μg/m³"
accuracy_decimals: 0
device_class: pm1
- name: "${friendly_name} PM2.5"
id: daikinpm25
unit_of_measurement: "μg/m³"
accuracy_decimals: 0
device_class: pm25
- name: "${friendly_name} PM10"
id: daikinpm10
unit_of_measurement: "μg/m³"
accuracy_decimals: 0
device_class: pm10
- platform: sgp30
i2c_id: sgp30_bus
eco2:
name: "${friendly_name} eCO2"
accuracy_decimals: 1
tvoc:
name: "${friendly_name} TVOC"
id: daikintvocppb
filters:
- lambda: return x * 2.3; #ppd -> μg/m³
- exponential_moving_average:
alpha: 0.1
send_every: 10
send_first_at: 1
unit_of_measurement: "μg/m³"
device_class: volatile_organic_compounds
accuracy_decimals: 0
And Im getting the following warnings in the Home Assistant log:
2023-06-12 13:33:44.531 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.daikin_air_sensor_floor_1_pm1 (<class 'homeassistant.components.esphome.sensor.EsphomeSensor'>) is using native unit of measurement 'μg/m³' which is not a valid unit for the device class ('pm1') it is using; expected one of ['µg/m³']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+esphome%22
2023-06-12 13:33:44.546 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.daikin_air_sensor_floor_1_pm2_5 (<class 'homeassistant.components.esphome.sensor.EsphomeSensor'>) is using native unit of measurement 'μg/m³' which is not a valid unit for the device class ('pm25') it is using; expected one of ['µg/m³']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+esphome%22
2023-06-12 13:33:44.619 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.daikin_air_sensor_floor_1_tvoc (<class 'homeassistant.components.esphome.sensor.EsphomeSensor'>) is using native unit of measurement 'μg/m³' which is not a valid unit for the device class ('volatile_organic_compounds') it is using; expected one of ['µg/m³']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+esphome%22
2023-06-12 13:33:44.639 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.daikin_air_sensor_floor_1_pm10 (<class 'homeassistant.components.esphome.sensor.EsphomeSensor'>) is using native unit of measurement 'μg/m³' which is not a valid unit for the device class ('pm10') it is using; expected one of ['µg/m³']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+esphome%22
What is wrong or missing?
The ESPHome version is 2023.2.4 and Home Assistant is 2023.4.6. If somebody is looking after the same this is how it looks like: