question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unable to discover the device

See original GitHub issue

A couple of versions back my Air Purifier 2 stopped appearing in HASS and I just got these errors:

2018-03-06 18:14:06 ERROR (Thread-12) [miio.device] Unable to discover a device at address 10.0.2.26
2018-03-06 18:14:06 ERROR (MainThread) [homeassistant.components.fan.xiaomi_miio] Got exception while fetching the state: Unable to discover the device 10.0.2.26

I’ve done a factory reset of the purifier and retrieved the token more then once from my iPhone so it should be correct. I’ve also got a Mi Vacuum and it works without problems.

Right now I’m on version 0.65.5 and this is my configuration.yaml:

logger:
  default: warn
  logs:
    miio: debug
    homeassistant.components.fan.xiaomi_miio: debug

fan:
  - platform: xiaomi_miio
    name: Mi Purifier
    host: 10.0.2.26
    token: *token*

This is the log when starting HASS with debug enabled (and disabling the vacuum):

2018-03-29 01:05:47 INFO (MainThread) [homeassistant.components.fan.xiaomi_miio] Initializing with host 10.0.2.26 (token c53b5...)
2018-03-29 01:05:52 ERROR (Thread-10) [miio.device] Unable to discover a device at address 10.0.2.26
2018-03-29 01:05:52 ERROR (MainThread) [homeassistant.components.fan.xiaomi_miio] Got exception while fetching the state: Unable to discover the device 10.0.2.26

I’ve tried looking around but can’t seem to figure out what it’s not working.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:15 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
syssicommented, Feb 9, 2019
1reaction
Andunescommented, Jun 13, 2018

So I just factory reset the device (and updated it to 1.2.9_64), extracted a new token, and got the exact same errors…

I might try to setup miio on somthing else and see if the problem is with the RPi.

Read more comments on GitHub >

github_iconTop Results From Across the Web

xiaomi_miio: Unable to discover the device (deerma ... - GitHub
If there are no problems with discovery and executing commands using miiocli , something changed in the homeassistant integration that broke it: ...
Read more >
[SOLVED] Xiaomi devices: Unable to discover a device
Hi, EDIT: Solved this by adding my RPi to the same network as IOT devices (before it was in a different subnet). I'm...
Read more >
Error Message: Unable to discover the device to be managed ...
Error Message. Unable to discover the device to be managed, reason(Duplicate item. Key already exists: deviceUri: https://<IP-Address>:443).
Read more >
Unable to discover or rescan a device - Progress Community
First, check the status of the discovery(discoveryservice.exe) service on Settings>System services. This service must be running at all ...
Read more >
What to do when Arlo is unable to discover your device during ...
Use the following troubleshooting if you attempted to connect your Arlo device directly to a Wi-Fi router and Arlo failed to discover the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found