Created
June 29, 2023 15:09
-
-
Save georgeh/1d2f3a353d51ec6bf1ad12b9d35aa360 to your computer and use it in GitHub Desktop.
Home Assistant automation to run fans based on AQI
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alias: Run Fans Based on Indoor AQI | |
description: "" | |
trigger: | |
- platform: numeric_state | |
entity_id: sensor.indoor_aqi | |
below: 50 | |
id: aqi_1 | |
- platform: numeric_state | |
entity_id: sensor.indoor_aqi | |
above: 50 | |
below: 100 | |
id: aqi_2 | |
- platform: numeric_state | |
entity_id: sensor.indoor_aqi | |
above: 100 | |
id: aqi_3 | |
condition: [] | |
action: | |
- choose: | |
- conditions: | |
- condition: trigger | |
id: aqi_1 | |
sequence: | |
- service: fan.set_percentage | |
data: | |
percentage: 33 | |
target: | |
entity_id: | |
- fan.mi_air_purifier_3_3h | |
- fan.mi_air_purifier_3_3h2 | |
- service: ecobee.set_fan_min_on_time | |
data: | |
entity_id: climate.mr_heat_miser | |
fan_min_on_time: 10 | |
- conditions: | |
- condition: trigger | |
id: aqi_2 | |
sequence: | |
- service: fan.set_percentage | |
data: | |
percentage: 66 | |
target: | |
entity_id: | |
- fan.mi_air_purifier_3_3h | |
- fan.mi_air_purifier_3_3h2 | |
- service: ecobee.set_fan_min_on_time | |
data: | |
entity_id: climate.mr_heat_miser | |
fan_min_on_time: 30 | |
- conditions: | |
- condition: trigger | |
id: aqi_3 | |
sequence: | |
- service: fan.set_percentage | |
data: | |
percentage: 100 | |
target: | |
entity_id: | |
- fan.mi_air_purifier_3_3h | |
- fan.mi_air_purifier_3_3h2 | |
- service: ecobee.set_fan_min_on_time | |
data: | |
entity_id: climate.mr_heat_miser | |
fan_min_on_time: 60 | |
mode: single |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment