I have a WH45 and I’m pretty sure the android app is calculating the AQI based off the raw pm2.5 values which is why you don’t see them in HA since they don’t technically exist.
You can use this template sensor to get the AQI for pm2.5 into HA:
indoor_aqi:
friendly_name: 'Indoor AQI'
unique_id: indoor_aqi
# Set this sensor to be the AQI value.
#
# Code translated from JavaScript found at:
# https://docs.google.com/document/d/15ijz94dXJ-YAZLi9iZ_RaBwrZ4KtYeCy08goGBwnbCU/edit#
value_template: >
{% macro calcAQI(Cp, Ih, Il, BPh, BPl) -%}
{{ (((Ih - Il)/(BPh - BPl)) * (Cp - BPl) + Il)|round }}
{%- endmacro %}
{% set pm25 = states('sensor.easyweatherpro_v5_1_1_wh45_pm2_5_co2')|float(0) %}
{% if pm25 > 1000 %}
invalid
{% elif pm25 > 350.5 %}
{{ calcAQI(pm25, 500.0, 401.0, 500.0, 350.5) }}
{% elif pm25 > 250.5 %}
{{ calcAQI(pm25, 400.0, 301.0, 350.4, 250.5) }}
{% elif pm25 > 150.5 %}
{{ calcAQI(pm25, 300.0, 201.0, 250.4, 150.5) }}
{% elif pm25 > 55.5 %}
{{ calcAQI(pm25, 200.0, 151.0, 150.4, 55.5) }}
{% elif pm25 > 35.5 %}
{{ calcAQI(pm25, 150.0, 101.0, 55.4, 35.5) }}
{% elif pm25 > 12.1 %}
{{ calcAQI(pm25, 100.0, 51.0, 35.4, 12.1) }}
{% elif pm25 >= 0.0 %}
{{ calcAQI(pm25, 50.0, 0.0, 12.0, 0.0) }}
{% else %}
invalid
{% endif %}
unit_of_measurement: "AQI"
availability_template: >-
{{ states('sensor.easyweatherpro_v5_1_1_wh45_pm2_5_co2') not in ['none', 'unknown', 'unavailable'] }}
Once that is working you can use this statistics sesnor(or the average integration from HACS) to get the 24h average:
- platform: statistics
name: "Average Indoor AQI (24h)"
entity_id: sensor.indoor_aqi
state_characteristic: mean
max_age:
hours: 23.98