Dyson Component Not Working

Recently got a Dyson Pure Cool couldn’t wait to get it integrated into Home Assistant.
I just simply cannot get it to work this is the first time a component just simply doesn’t work for me.

My Config… With obvious amendments.

dyson:
  username: [email protected]
  password: !secret dyson_password
  language: UK
  devices:
    - device_id: AAA-UK-AAA0000A
      device_ip: 192.168.1.100

I get the below error

I simply cannot see what I’m doing wrong I strangely also get the below in the error logs.

2017-07-16 11:07:41 ERROR (SyncWorker_0) [homeassistant.components.dyson] Not connected to Dyson account. Unable to add devices
2017-07-16 11:07:42 ERROR (MainThread) [homeassistant.setup] Setup failed for dyson: Component failed to initialize.

I have waited until the release of 0.49.0 due to the new release of Dyson sensors might clear up the issues but no joy.

Any help, pointers or clarity would be apreciated.

Change your language to ‘GB’ instead of UK
also, try getting rid of the all the devices: you have in there, it should discover it fine without this

2 Likes

Changing to GB seams to have done the trick thanks @elPaulio appreciate the help! :slight_smile:

OK, I had exactly the same issue, I’ll test when I can, it appears that documentation needs revising for this component.

Yeah, Ive notified the author yesterday - he is to change it ASAP

How can I help debug?

I have changed language to GB and I am still not able to connect.
I have confirmed my user info & device id/ip is all correct.

running tail -f on home-assistant.log I see:

2017-07-21 23:04:04 WARNING (MainThread) [homeassistant.setup] Setup of dyson is taking over 10 seconds.

And boot of HA stops

dyson:
  username: !secret dyson_username
  password: !secret dyson_password
  language: GB
  devices:
    - device_id: PE9-UK-XXX5301A
      device_ip: 192.168.0.99

(I’d like to point out that I have commented out devices and am seeing the same issue)

Thanks

I cant see anything wrong with your code… is the device available on your phones dyson app?

Yes, Android - Using an S8+ at the moment, was a 6P last week… can control the device no issues

stumped then mate, unless your user/pass combination is failing it, but id expect that to show as such in the log file

@CharlesBlonde may be able to assist further?

Hi and thanks @elPaulio to have notified me! I wasn’t aware of this thread. I regularly read the Github issues in order to check if there are issues about this component but not this forum. My bad.

I confirm that I’ll upgrade the documentation to replace UK with GB language code.

@nodinosaur Your issue seems quite strange. Are you able to configure the log level for this component to debug ?

logger:
  default: warn
  logs:
    homeassistant.components.sensor.dyson: debug
    homeassistant.components.fan.dyson: debug
    homeassistant.components.dyson: debug

I hope that with more outputs, I’ll be able to understand where it is blocking. Just note that the first run can be quite long on low CPU devices (like Raspberry Pi) because it has to download and compile cryptographic libraries who can be quite CPU intensive.

FYI, I just submitted a PR to fix the documentation about GB language code

I added

logger:
  default: warn
  logs:
    homeassistant.components.sensor.dyson: debug
    homeassistant.components.fan.dyson: debug
    homeassistant.components.dyson: debug

I have:

dyson:
  username: !secret dyson_username
  password: !secret dyson_password
  language: GB
#  devices:
#    - device_id: PE9-UK-XXX5301A
#      device_ip: 192.168.0.99

in configuration.yaml

And running tail -f on home-assistant.log I see:

2017-07-23 20:34:56 INFO (Thread-8) [homeassistant.components.dyson] Connected to Dyson account
2017-07-23 20:34:57 INFO (Thread-8) [homeassistant.components.dyson] Trying to connect to device DysonDevice(PE9-UK-XXX5301A,True,Pure Hot+Cool,21.03.08,True,False,455,None) with timeout=5 and retry=10
2017-07-23 20:35:03 WARNING (MainThread) [homeassistant.setup] Setup of dyson is taking over 10 seconds.

UPDATE:
When I ensure the Dyson fan IS was running when restarting HASS - switched on via the Android App - restart of HASS & set up of the Fan appears to be correct as I now see fan.pure_hotcool in http://192.168.0.42:8123/dev-state :face_with_raised_eyebrow:

So it appears the problem is when the fan is in a stand-by state when HASS is rebooting

My configuration in the configuration.yaml is:

dyson:
  username: !secret dyson_username
  password: !secret dyson_password
  language: GB
  devices:
    - device_id: PE9-UK-XXX5301A
      device_ip: 192.168.0.99

Logging returns:

2017-07-23 20:45:51 INFO (Thread-8) [homeassistant.components.dyson] Creating new Dyson component
2017-07-23 20:46:00 INFO (Thread-8) [homeassistant.components.dyson] Connected to Dyson account
2017-07-23 20:46:01 WARNING (MainThread) [homeassistant.setup] Setup of dyson is taking over 10 seconds.
2017-07-23 20:46:01 INFO (Thread-8) [homeassistant.components.dyson] Connected to device DysonDevice(PE9-UK-XXX5301A,True,Pure Hot+Cool,21.03.08,True,False,455,NetworkDevice(Pure Hot+Cool,192.168.0.99,1883))
2017-07-23 20:46:01 DEBUG (Thread-8) [homeassistant.components.dyson] Starting sensor/fan components
2017-07-23 20:46:01 INFO (Thread-1) [homeassistant.components.sensor.dyson] Creating new Dyson fans
2017-07-23 20:46:01 DEBUG (Thread-13) [homeassistant.components.sensor.dyson] Message received for Pure Hot+Cool filter life device: DysonEnvironmentalSensorState(75,0,292.3,0,0)
2017-07-23 20:46:01 DEBUG (Thread-13) [homeassistant.components.sensor.dyson] Message received for Pure Hot+Cool humidity device: DysonEnvironmentalSensorState(75,0,292.3,0,0)
2017-07-23 20:46:01 DEBUG (Thread-13) [homeassistant.components.sensor.dyson] Message received for Pure Hot+Cool dust device: DysonEnvironmentalSensorState(75,0,292.3,0,0)
2017-07-23 20:46:01 DEBUG (Thread-13) [homeassistant.components.sensor.dyson] Message received for Pure Hot+Cool temperature device: DysonEnvironmentalSensorState(75,0,292.3,0,0)
2017-07-23 20:46:01 DEBUG (Thread-13) [homeassistant.components.sensor.dyson] Message received for Pure Hot+Cool air quality device: DysonEnvironmentalSensorState(75,0,292.3,0,0)
2017-07-23 20:46:01 INFO (Thread-9) [homeassistant.components.fan.dyson] Creating new Dyson fans
2017-07-23 20:46:01 INFO (Thread-9) [homeassistant.components.fan.dyson] Creating device Pure Hot+Cool
2017-07-23 20:46:31 DEBUG (Thread-13) [homeassistant.components.sensor.dyson] Message received for Pure Hot+Cool temperature device: DysonEnvironmentalSensorState(75,0,292.2,0,0)
2017-07-23 20:47:01 DEBUG (Thread-13) [homeassistant.components.sensor.dyson] Message received for Pure Hot+Cool temperature device: DysonEnvironmentalSensorState(75,0,292.1,0,0)

Also, once the fan is turned off from HASS and left for a few minutes, it cannot be woken up from HASS again.
Turning the fan on via the app, the HASS interface does not update either.

UPDATE 2
What appears to be typical thing for us devs, disabling logging the problem reoccurs, LOL!

Thanks

any progress?
Is this related:

Hi @nodinosaur.
Sorry for the delay, I was quite busy during last weeks.
Next HA will better manage devices when fans are in standby but I don’t think it will resolve all your issues.
I re-read your messages and I just understood that the component is unable to connect while the device is in standby …after a few minutes. During my last tests, I didn’t test this case (but I discovered a similar behavior) …

So I’ll need more time to fix this (if it’s possible) because I have to understand how the mobile app is able to connect to the device if the device is in standby and refuse the connections …

There is no official documentation or API so my only tool is tcpdump in order to understand how it is working. Maybe a broadcast mDNS message.

I think, for now, the only reliable workaround is to disable standby monitoring. But I can understand it is not what you want.

Were you ever able to get your device connected? Its really frustrating that this component is so spotty. I haven’t been able to get it to work since day 1

Hi Everyone,

I’m struggling with my Dyson fan.

Discovery wasn’t working, and I get the below error when adding my device manually:

“Unable to find device VS7-UK-KCA1324A in Dyson account”

Anyone got any tips?

I’m also getting this error. I just changed my fan for a newer model the previous connection was spotty but worked now all I get is this error message.

My previous fans started with NN6, my new fan starts the same as yours with VS7. I wonder if this might be something to do with the problem? Maybe @CharlesBlonde might know more.

Mine was working flawlessly for the first week now I get this error:

2018-12-05 18:14:28 INFO (SyncWorker_8) [homeassistant.components.dyson] Creating new Dyson component
2018-12-05 18:14:35 INFO (SyncWorker_8) [homeassistant.components.dyson] Connected to Dyson account
2018-12-05 18:14:36 ERROR (SyncWorker_8) [homeassistant.components.dyson] Unable to connect to device NetworkDevice(name=Master bedroom,address=192.168.1.225,port=1883): [Errno 61] Connection refused
2018-12-05 18:14:40 WARNING (MainThread) [homeassistant.setup] Setup of dyson is taking over 10 seconds.
2018-12-05 18:14:41 INFO (MainThread) [homeassistant.setup] Setup of domain dyson took 12.6 seconds.
2018-12-05 18:14:41 DEBUG (MainThread) [homeassistant.core] Bus:Handling <Event component_loaded[L]: component=dyson>

I used to get this on my previous model intermittently. Having the app open when rebooting Home Assistant would sometimes cure it.

I’ll give that a try. Thanks