JeroenVdb / homebridge-daikin-cloud

This Homebrige plugin connects to the Daikin Cloud and loads all your devices to be controled via Homebridge and Homekit.
https://www.npmjs.com/package/homebridge-daikin-cloud
Apache License 2.0
32 stars 10 forks source link

Force AC Unit to start when changing values in cooling type #7

Closed 0x1d1 closed 1 year ago

JeroenVdb commented 2 years ago

Hi @0x1d1, thanks for your pull request!

If I understand correctly you want to start the AC when you change the operation mode to auto, cooling or heating. And turn the AC off when you set the operation mode to off.

When I try this in the Home app, this already works like that. When the operation mode is moved to auto, cooling or heating the handleTargetHeaterCoolerStateSet AND handleActiveStateSet are both called. So the AC is turn on/off and the mode is set correctly.

Some steps I took to test this:

  1. AC is ON and operation mode is cooling
  2. Move operation mode to off -> AC shuts down
  3. Move operation mode to cooling -> AC starts and operation mode is set to cooling
  4. From the Home app, click the AC tile -> AC shuts down and operation mode is set to off
  5. Move operation mode to cooling -> AC starts and operation mode is set to cooling

This is what I see in the logging when I move the operation mode from off to cooling:

[6/15/2022, 9:22:14 AM] [DaikinCloud] [Airco zolder] SET ActiveState, state: 1
[6/15/2022, 9:22:14 AM] [DaikinCloud] [Airco zolder] SET TargetHeaterCoolerState, OperationMode to: 2
[6/15/2022, 9:22:14 AM] [DaikinCloud] [Airco zolder] SET TargetHeaterCoolerState, daikinOperationMode to: cooling

Are you using the Home app? Can you post the Homebridge logs of what happens when you change the operation mode?

0x1d1 commented 2 years ago

Hi @JeroenVdb , Thanks for your reply, and you are correct. However, I'm using this homebridge addon with homeassistant, and if you add the controller from homeassistant to your home app you won't be able to turn on the AC, only modify the settings. That's why I added this "forcing" procedure.

My flow: Home app -> Homeassistant controler -> Homebridge -> Daikin Cloud

JeroenVdb commented 2 years ago

@0x1d1 I'm a bit confused about the setup. Are you using the Home app or Home Assistant and feeding devices to HA via Homebridge? Maybe a screenshot?

Probably the current implementation is (too) much focused on working with the Home app. But I never used Homebridge with HA or Eve.

Can you post the log of what happens when you change the operation mode?

0x1d1 commented 2 years ago

Hi @JeroenVdb , I use the Home app from iOS and my wife uses the google Home app, but we also have an android tablet with home assistant that controls everything automation related. So what we have is:

So currently what I have is: Daikin Cloud -> Homebridge (version that I changed, running in a Docker container) -> HomeAssistant (to control everything related with automation) -> Google Home (for my Wife) and Home app (for me)

0x1d1 commented 2 years ago

I totally understand if you reject my pull request, the use case that I have is an edge case, but for future reference if someone else has the same problem as me, at least knows how to solve it.

Kind regards

JeroenVdb commented 1 year ago

Released in homebridge-daikin-cloud@1.3.1. Sorry for the many questions and the delay but I wanted to make sure it didn't break any other things. And I was on holiday 😅

0x1d1 commented 1 year ago

Thanks so much for all the help!! And continuation of a good vacation !! Cheers !