Daikin ac check state to trigger automation

Hello all,

I have recently bought a daikin ac unit with the wifi controller and I integrated it in HA. I can turn it on and off etc. What I cannot seem to be able to do is to check if the AC changed states with an automation.

I want to be able to automatically turn it off after 1 hour and I was thinking to have an automation that checks if the state has changed from off and the start a delay timer for 1 hour and then turn the AC off.

However, this doesn’t seem to happen. Here is the automation that I currently have:

alias: AC off
description: ''
trigger:
  - platform: state
    entity_id: climate.birou
    attribute: hvac_modes
    from: 'off'
condition: []
action:
  - delay:
      hours: 1
      minutes: 0
      seconds: 0
      milliseconds: 0
  - service: climate.set_hvac_mode
    data:
      hvac_mode: 'off'
    target:
      entity_id: climate.birou
mode: single

The action part works because I checked. What doesn’t work is the trigger part.

Delete this from the trigger:

You want the climate entity’s state (off or heat or cool or fan …etc).

The attribute hvac_modes is just a list of available modes. It does not change.

Also trigger it like this:

alias: AC off
description: ''
trigger:
  - platform: state
    entity_id: climate.birou
    from: 'off'
    for:
      hours: 1
condition: []
action:
  - service: climate.set_hvac_mode
    data:
      hvac_mode: 'off'
    target:
      entity_id: climate.birou
mode: single

No need to keep the automation waiting in a delay. This will trigger an hour after the state has changed from off and stayed something other than off.

2 Likes

Thanks a lot! Works great I just tried it!

Also now it is clearer to me what the hvac_modes attribute is!

1 Like

Note if you change the mode this automation wont trigger.

e.g. you switch it from off to auto, then before the hour is up you change from auto to heat.

yes I can imagine that will not work. to be honest we use the unit for cooling only and we tend to forget it running for too long. so I wanted a way to turn it off automatically. 1 hour is more than enough to get to a nice temperature here!

thanks again for your help!

1 Like