Hey,
So I have a Dyson Hot+Cool fan setup alongside my Broadlink to remotely control the fan from Home Assistant and other devices, it’s pretty cool, but I wanted to make it even cooler, literally.
So I am setting up an automation that will turn the fan on/off depending on the temperature, at the moment I have this hooked up to a weather sensor, however, I am going to fit a room sensor soon.
Here’s my current config for that:
# Dyson fan on when it is too hot
- id: auto_dyson_fan_off
alias: Dyson Fan on above 16C
trigger:
platform: numeric_state
entity_id: sensor.weather_apparent_temperature
above: 16
action:
- service: switch.turn_on
entity_id: switch.dyson_fan
- service: notify.ios_ng_iphone
data:
message: 'IT IS HOT!!! {{ sensor.weather_apparent_temperature }}%'
# Dyson fan off when it is too hot
- id: auto_dyson_fan_off
alias: Dyson Fan off below 16C
trigger:
platform: numeric_state
entity_id: sensor.weather_apparent_temperature
below: 16
action:
- service: switch.turn_off
entity_id: switch.dyson_fan
- service: notify.ios_ng_iphone
data:
message: 'IT IS COLD!!! {{ sensor.weather_apparent_temperature }}%'
So that works great but it definitely isn’t enough. I also want it to be able to change the strength of the fan depending on the temperature.
That’s where things get tricky and that’s the reason for this topic.
I am looking for a way to set the current number of the fan in Home Assistant with a sleek bit of code that will increase each time the strength button is pressed up or down, and remember that for the purpose of automating it to go to a set number.
Basically, Home Assistant would have to work out the difference between the current strength and the target and then tell broadlink the amount of times to press the button.
Here’s an image of the Dyson remote if this helps to provide an idea of what I want to do:
https://images-na.ssl-images-amazon.com/images/I/41GLB5KKtVL.SY300.jpg
Does anyone know of a possible way to do that?