Daikin Component - no climate entities created - task exception

Perfect thanks for the info. Below is my feedback based on all the info you provided.

A: Based on your answer to question 3 where u’re saying that u can’t control it from the application it means that I can apply a fix to be able to get rid of that error and control the same things that u can control from the mobile app.
This basically means that u won’t still be able to control fan speed.
I’ll try to make this fix asap, probably during this weekend.

Other solution for you in order to be able control fan speed is to upgrade your controller to a newer version, BRP 43,44 or 45 but this won’t guarantee that it will work but u can try and simply return the controller according to UE regulations.

B: Based on what I see on your firmware version from the Basic_info output where it says ver=2_9_0 I can tell you that the latest versions is 3_3_1 so check in the Android/IOS app if you can upgrade it and again u might have a chance that it will work. However I doubt it since even when I used older FW versions (2 years ago) I was able to control the fan speed from then so u’re AC device simply might not support it :frowning:

I’ll keep you guys that have BRP42 updated regarding the fix I promised on point A anyway and hopefully I’ll manage to fix it during weekend so u get rid of that error and control at least temperature and operation mode (auto, cold, heat, etc).

@rofrantz - Thanks for your efforts so far

After a little more research overnight, the app does indeed have an area and controls for fan speed down the bottom where the line is in the above screenshot (If i launch the app in demo mode i see those controls i don’t see when connected to my system)

I had a read through the help files of the app and it mentions the following “Displays settings for other functions (Displayed items may vary by unit model)”

The app asked me to update the firmware when i first installed and commissioned the adaptor (prompted me to update to firmware version 2.9.0) - It is not prompting me to update firmware any longer.

I’d be interested to hear if @brettjonesoz also does not have those additional options displayed in the dlink app (if thats what he used to setup the adaptor)

I’ve been digging around re the firmware versions, and i found a post on github suggesting that someone is running wirelss firmware version 3.3.1 but for the life of me i can’t find where this would be available from

I guess some control (without fan) is better than none at all

---- snip ----
WiFiControllerID: BRP072A42
WiFiController firmware version: 3.3.1

Yep same issue no fan speed controls in the android app.

Looks like our only real choice in Australia is the BRP072A42 from what i can see from availability.

Looks like we need to lobby Daikin to provide a firmware update, when i purchased the adapters i was told that fan swing options wouldn’t work but was expecting to be able to set the fan rate…

Indeed guys so option A from my suggestion (fix component without fan speed and fan direction) is ur only option :frowning:

Created https://github.com/home-assistant/home-assistant/pull/11840 and https://github.com/home-assistant/home-assistant/pull/11841 for the fix guys.

Once they are both merged then everything should be fine for you guys.

nice @rofrantz
I’ll wait for the merge and give it a run

Both pr’s merged guys. Let me know how it is @peterho and/or @brettjonesoz

Just wanted to chime in on this. I’m in Australia also using the BRP072A42 adapter and I have fan speed control. I haven’t looked through the PR, but it isn’t going to break fan speed based on the adapter model number is it?

Here is my output:
ret=OK,pow=0,mode=0,adv=,stemp=23.0,shum=0,dt1=23.0,dt2=M,dt3=22.0,dt4=25.0,dt5=25.0,dt7=23.0,dh1=0,dh2=0,dh3=0,dh4=0,dh5=0,dh7=0,dhh=50,b_mode=0,b_stemp=23.0,b_shum=0,alert=255,f_rate=A,f_dir=0,b_f_rate=A,b_f_dir=0,dfr1=A,dfr2=A,dfr3=A,dfr4=5,dfr5=5,dfr6=5,dfr7=A,dfrh=5,dfd1=0,dfd2=0,dfd3=0,dfd4=0,dfd5=0,dfd6=0,dfd7=0,dfdh=0

Currently Home Assistant only lets me see current temp (no idea if indoor our outdoor) which was 21 when I pulled that data and target temp (currently 23). The D-Mobile iPhone app actually lets me see indoor and outdoor temp separately (both 21 currently).

For your info, in case it helps:

  1. Daikin Zena (FTXJ35PVMAS)
  2. Yes, fan speed/mode control is possible
  3. Yes, fan speed/mode control is possible

No it won’t break it…because my code checks if the device provides f_rate & f_dir values from the output u just provided. I didn’t hardcoded for that exact model :smiley:

Climate components always show just inside and target temperatures which is normal for ac; any additional infos are provided by sensors.
For the outside temperature simply use the sensors from the docs https://home-assistant.io/components/sensor.daikin/. Let me know if it helped @mynameisdaniel.

Out of curiosity @mynameisdaniel can u control from the ios app also the humidity because I cant on my two daikins but i would like to provide it to others. In case u can, would u help me test it on ur HA after I develop it ?

Brilliant - sounds like you’re all over it :smiley:

I misread that part about manually setting up the sensors in the docs, I’ll add that to my config tonight!

Unfortunately I don’t get any humidity control or reporting on my Daikin unit either. Apart from the ‘Dry’ mode.

1 Like

Update @mynameisdaniel: on the next release autodiscovery has been also enabled which will automatically discover climate and add sensors. PR has been merged already into the dev bramch of HA :slight_smile:

@rofrantz

forgive my ignorance when it comes to homeassistant.

Given i am not running in dev mode, i assume that the original daikin.py is what is still loading. I could however place the merged daikin.py in my customised directory, and have it load in advance of the inbuilt daikin.py when running homeassistant V61.1 as a test to see how it goes?

Is this the only file i would need to place in there? I believe it would need to be in a directory called “climate”?

Also, i attempted to grab your merge from the github website, grab the raw text, save it as daikin.py (not a txt file) mentioned above, but it didn’t seem to change (logs suggest it loaded from the customised directory/daikin.py, but still has same error)

I noticed there was reference to a init.py. Does this also need to be in the customised directory?

I’m a bit challenged at the moment with a laptop that is not playing nice so i won’t have a chance to try again till possibly over the weekend.

Do i assume correctly that the updated daikin.py on the climate side will be bought down next time there is a .version update of homeassistant?

Pete

@peterho follow the docs from https://home-assistant.io/docs/installation/updating/
pip3 install --upgrade git+git://github.com/home-assistant/home-assistant.git@dev

Its safer and easier that instead of hacking locally. Otherwise just wait for the release. I really recommend u to delete any custom file if u dont know what ur messing with. Any custom file overwrittes original HA behaviours

Hacking locally can cause u a lot of troubles. Many users forget about those custom files they manually added and then they say “its not working”

Looking forward to this release! I just added the BRP072A43 to the AC unit in my office and it looks lto be missing the fan control as well:

➜  /config git:(master) curl http://172.20.20.220/aircon/get_control_info
ret=OK,pow=0,mode=4,adv=,stemp=21.0,shum=0,dt1=25.0,dt2=M,dt3=25.0,dt4=21.0,dt5=21.0,dt7=25.0,dh1=AUTO,dh2=50,dh3=0,dh4=0,dh5=0,dh7=AUTO,dhh=50,b_mode=4,b_stemp=21.0,b_shum=0,alert=255#

I tried adding the files you changed in your merge to my custom components to do some testing, but still received the error below. I have used custom components before when troubleshooting, but it is always possible that I missed something.

Thu Jan 25 2018 13:45:14 GMT-0600 (Central Standard Time)

Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/lib/python3.6/asyncio/tasks.py", line 180, in _step
    result = coro.send(None)
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity_component.py", line 399, in async_process_entity
    new_entity, self, update_before_add=update_before_add
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity_component.py", line 247, in async_add_entity
    yield from entity.async_update_ha_state()
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 217, in async_update_ha_state
    attr = self.state_attributes or {}
  File "/usr/lib/python3.6/site-packages/homeassistant/components/climate/__init__.py", line 521, in state_attributes
    fan_mode = self.current_fan_mode
  File "/config/custom_components/climate/daikin.py", line 235, in current_fan_mode
    return self.get(ATTR_FAN_MODE)
  File "/config/custom_components/climate/daikin.py", line 126, in get
    value = self._api.device.represent(daikin_attr)[1].title()
  File "/usr/lib/python3.6/site-packages/pydaikin/appliance.py", line 145, in represent
    v = self.values[key]
KeyError: 'f_rate'

I removed the custom component and am seeing the standard error everyone else is/was seeing:

Thu Jan 25 2018 14:03:06 GMT-0600 (Central Standard Time)

Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/lib/python3.6/asyncio/tasks.py", line 180, in _step
    result = coro.send(None)
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity_component.py", line 399, in async_process_entity
    new_entity, self, update_before_add=update_before_add
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity_component.py", line 247, in async_add_entity
    yield from entity.async_update_ha_state()
  File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 217, in async_update_ha_state
    attr = self.state_attributes or {}
  File "/usr/lib/python3.6/site-packages/homeassistant/components/climate/__init__.py", line 521, in state_attributes
    fan_mode = self.current_fan_mode
  File "/usr/lib/python3.6/site-packages/homeassistant/components/climate/daikin.py", line 229, in current_fan_mode
    return self.get(ATTR_FAN_MODE)
  File "/usr/lib/python3.6/site-packages/homeassistant/components/climate/daikin.py", line 120, in get
    value = self._api.device.represent('f_rate')[1].title()
  File "/usr/lib/python3.6/site-packages/pydaikin/appliance.py", line 145, in represent
    v = self.values[key]
KeyError: 'f_rate'

Thanks for all the work on this!

Dan W.

As stated to the others @dancwilliams u should remove those “custom” files and just try to use WITHOUT any code changes directly the dev branch.

That’s why I’ll say it again: don’t use custom files unless u know how to use them otherwise even after the release HA will always use ur “custom” files ignoring my fix :frowning_face:.

My fix includes two PR’s: https://github.com/home-assistant/home-assistant/pull/11840 and https://github.com/home-assistant/home-assistant/pull/11841 where BOTH FILES climate/daikin.py and climate/init.py have been modified. U probably modified only daikin.py file.

I (once again) encourage u guys to use the docs from https://home-assistant.io/docs/installation/updating/ for deploying the dev branch instead of modifying (wrong) files directly.

Let me know if u still have the any error.

Like I said in my post, I already deleted everything I had in custom components and was seeing the same error. Just waiting for the next release.

Thanks,

Dan W.

Thanks for the additional information.

I did have the new __init__.py from your PR, but from what I am seeing from the output above and the test I just ran, the __init__.py in the custom_components/climate/ directory is not being picked up when HASS restarts. But, the daikin.py file is being picked up. I am running HASSIO and am not familiar enough to troubleshoot why the init file is not recognized.

I just went ahead and removed all of the files again and restarted. I will just wait for the next release cycle and test then. Unless I get some free time later and decide to actually dive into it further :slight_smile:.

Again…thanks,

Dan W.

0.62 released guys. How is it on ur side, can u finally see the climate component @dancwilliams, @peterho, @brettjonesoz ?

Just waiting for the hassio update to come out and I will test and let you know. I expect it to be on the street tomorrow.