v3.0.4 First Time Setup No Discovery

Posted on
Sun Aug 13, 2017 9:32 am
blakekrone offline
Posts: 16
Joined: Sep 13, 2011

v3.0.4 First Time Setup No Discovery

Installed the 3.0.4 version from the GitHub repository setting it up net new with a brand new out of the box dot. I have the bridge setup and devices added with the logging enabled but never see anything in the logs and the dot can't discover any devices. I've quit Plex and one of my other apps that was using 1900 UPnP still no go. What's odd to me is that there isn't anything in the logs at all, almost like the dot isn't attempting to do a discovery but it does find my Nest thermostat with the Nest skill enabled. I don't have any other skills enabled. Looking at the log file I don't see any requests from the dot IP address.

I have reloaded the plugin, reset the echo, waiting 12 hours before trying to discovery, etc. All other alexa functions work fine, just won't discover devices I have assigned in the plugin.

Posted on
Sun Aug 13, 2017 9:42 am
autolog offline
Posts: 3988
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: v3.0.4 First Time Setup No Discovery

I assume that you have discovery turned on for the Alexa-Hue Bridge?
How many devices have you defined to the Alexa-Hue Bridge?

I will probably need to see the debug logs. See the sticky post on how to do that and then attach the log to a reply post and I will take a look. After turning on all debugging, reload the plugin and then try and do a discovery so that I can see what happens. :)

Posted on
Sun Aug 13, 2017 10:32 am
blakekrone offline
Posts: 16
Joined: Sep 13, 2011

Re: v3.0.4 First Time Setup No Discovery

Did you read the question? I answered all of your questions minus the number of devices so I'll answer that now as 8 devices.

Like I said debugs show nothing. I'm not an idiot, I have developed plugins. There are no requests being logged by the dot in either the console log nor your log file showing a request nor response. Plugin launches and states it has 8 devices.

It's very familiar to the Echo Show thread where the Show isn't being detected as doing discovery.

Posted on
Sun Aug 13, 2017 10:50 am
autolog offline
Posts: 3988
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: v3.0.4 First Time Setup No Discovery

I asked two questions. Your first post didn't state that you had discovery turned on for the Alexa-Hue Bridge, hence my first question. Thank you for answering the second. :)

I don't think my reply implied that you are an idiot, I was just trying to help you.

However, I can't do that in a vacuum. I want to look at the logs to see what plugin is doing from start-up to see if there is a plugin problem.

If you don't want to provide me with the logs, then I can't help you. :)

Posted on
Sun Aug 13, 2017 11:23 am
blakekrone offline
Posts: 16
Joined: Sep 13, 2011

Re: v3.0.4 First Time Setup No Discovery

Discovery is turned on by default, so I assumed you would assume that 8P

Code: Select all
2017-08-13 12:18:11.650   INFO           Plugin.general.__init__                  Alexa-Hue Bridge initialising . . .
2017-08-13 12:18:11.653   INFO           Plugin.general.closedPrefsConfigUi       Alexa discovery request logging enabled
2017-08-13 12:18:11.654   WARNING        Plugin.general.setDebuggingLevels        Debugging enabled for Alexa-Hue Bridge: General, Server, Broadcaster, Responder, Method Trace
2017-08-13 12:18:11.672   THREADDEBUG    Plugin.method.startup                   CLASS: Plugin
2017-08-13 12:18:11.672   INFO           Plugin.general.startup                   Alexa-Hue Bridge checking network access by attempting to access 'www.google.com'
2017-08-13 12:18:11.744   INFO           Plugin.general.is_connected              Alexa-Hue Bridge network access check to www.google.com successfully completed.
2017-08-13 12:18:11.745   INFO           Plugin.general.startup                   Alexa-Hue Bridge initialization complete
2017-08-13 12:18:11.748   DEBUG          Plugin.server.run                       Discovery Logging thread initialised.
2017-08-13 12:18:11.751   THREADDEBUG    Plugin.method.deviceStartComm           CLASS: Plugin
2017-08-13 12:18:11.752   DEBUG          Plugin.general.deviceStartComm           DEVICE START: Alexa Hue Bridge
2017-08-13 12:18:12.075   INFO           Plugin.general.deviceStartComm           Hue Bridge 'Alexa Hue Bridge' Host: 192.168.10.100
2017-08-13 12:18:12.082   THREADDEBUG    Plugin.method.didDeviceCommPropertyChange CLASS: Plugin
2017-08-13 12:18:12.082   DEBUG          Plugin.general.didDeviceCommPropertyChange DID-DEVICE-COMM-PROPERTY-CHANGE: Old [Alexa Hue Bridge] vs New [Alexa Hue Bridge]
2017-08-13 12:18:12.082   THREADDEBUG    Plugin.method.deviceStopComm            CLASS: Plugin
2017-08-13 12:18:12.083   THREADDEBUG    Plugin.method.deviceStartComm           CLASS: Plugin
2017-08-13 12:18:12.083   DEBUG          Plugin.general.deviceStartComm           DEVICE START: Alexa Hue Bridge
2017-08-13 12:18:12.083   THREADDEBUG    Plugin.method.runConcurrentThread       CLASS: Plugin
2017-08-13 12:18:12.084   INFO           Plugin.general.deviceStartComm           Hue Bridge 'Alexa Hue Bridge' Host: 192.168.10.100
2017-08-13 12:18:12.085   INFO           Plugin.general.retrievePublishedDevices  'Alexa Hue Bridge' has 6 Alexa Devices published
2017-08-13 12:18:12.085   INFO           Plugin.general.deviceStartComm           Starting Hue Bridge 'Alexa Hue Bridge' web server thread
2017-08-13 12:18:12.093   INFO           Plugin.general.deviceStartComm           Starting Hue Bridge 'Alexa Hue Bridge' discovery thread as 'Auto Start Discovery' requested
2017-08-13 12:18:12.093   DEBUG          Plugin.broadcaster.__init__                  Broadcaster.__init__ for 'Alexa Hue Bridge' is running
2017-08-13 12:18:12.096   DEBUG          Plugin.server.run                       Httpd.run called
2017-08-13 12:18:12.096   DEBUG          Plugin.server.run                       Httpd.run SocketServer.ThreadingTCPServer
2017-08-13 12:18:12.096   DEBUG          Plugin.server.run                       Httpd.run calling server.serve_forever()
2017-08-13 12:18:12.097   DEBUG          Plugin.responder.__init__                  Responder.__init__ for 'Alexa Hue Bridge' is running
2017-08-13 12:18:12.097   DEBUG          Plugin.broadcaster.run                       Broadcaster.run called
2017-08-13 12:18:12.098   DEBUG          Plugin.broadcaster.run                       Broadcaster.run: sending first broadcast:
NOTIFY * HTTP/1.1
HOST: 239.255.255.250:1900
CACHE-CONTROL: max-age=100
LOCATION: http://192.168.10.100:8178/description.xml
SERVER: FreeRTOS/7.4.2, UPnP/1.0, IpBridge/1.7.0
NTS: ssdp:alive
NT: uuid:a6215907-804a-11e7-88cc-0026b0f3ff2a
USN: uuid:a6215907-804a-11e7-88cc-0026b0f3ff2a

2017-08-13 12:18:12.098   THREADDEBUG    Plugin.method.setDeviceDiscoveryState   CLASS: Plugin
2017-08-13 12:18:12.098   DEBUG          Plugin.general.setDeviceDiscoveryState   SET DEVICE DISCOVERY STATE = True
2017-08-13 12:18:12.107   THREADDEBUG    Plugin.method.didDeviceCommPropertyChange CLASS: Plugin
2017-08-13 12:18:12.107   DEBUG          Plugin.general.didDeviceCommPropertyChange DID-DEVICE-COMM-PROPERTY-CHANGE: Old [Alexa Hue Bridge] vs New [Alexa Hue Bridge]
2017-08-13 12:18:12.108   THREADDEBUG    Plugin.method.didDeviceCommPropertyChange CLASS: Plugin
2017-08-13 12:18:12.108   DEBUG          Plugin.general.didDeviceCommPropertyChange DID-DEVICE-COMM-PROPERTY-CHANGE: Old [Alexa Hue Bridge] vs New [Alexa Hue Bridge]
2017-08-13 12:18:12.109   DEBUG          Plugin.responder.run                       Responder.run called
2017-08-13 12:18:12.149   THREADDEBUG    Plugin.method.didDeviceCommPropertyChange CLASS: Plugin
2017-08-13 12:18:12.149   DEBUG          Plugin.general.didDeviceCommPropertyChange DID-DEVICE-COMM-PROPERTY-CHANGE: Old [Alexa Hue Bridge] vs New [Alexa Hue Bridge]
2017-08-13 12:18:17.084   INFO           Plugin.general.runConcurrentThread       Alexa-Hue Bridge checking for Plugin update
2017-08-13 12:18:17.085   INFO           Plugin.general._log                      Checking for updates...
2017-08-13 12:18:17.085   DEBUG          Plugin.general._debug                    Plugin version detected: 3.0.4
2017-08-13 12:18:17.086   DEBUG          Plugin.general._debug                    Current version is: 3.0.4
2017-08-13 12:18:17.086   DEBUG          Plugin.general._debug                    Getting latest release from IndigoDomotics/alexa-hue-bridge...
2017-08-13 12:18:17.086   DEBUG          Plugin.general._debug                    GET /repos/IndigoDomotics/alexa-hue-bridge/releases/latest
2017-08-13 12:18:17.813   DEBUG          Plugin.general._debug                    HTTP 200 OK
2017-08-13 12:18:17.814   DEBUG          Plugin.general._debug                    Latest release is: 2.0.11
2017-08-13 12:18:17.814   INFO           Plugin.general._log                      No updates are available
2017-08-13 12:18:17.814   INFO           Plugin.general.runConcurrentThread       Alexa-Hue Bridge next update check scheduled for: Monday, 2017-Aug-14 at 12:18


Other than that, nothing. I was wondering if the Synology was doing something funky, shut that off and no longer see the requests from it come in, but have yet to see a single dot request come in. So nothing i can really show you in the log because well there isn't anything! I did just uninstall the plugin, reinstall and try again. No love.

Posted on
Sun Aug 13, 2017 11:53 am
autolog offline
Posts: 3988
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: v3.0.4 First Time Setup No Discovery

Thanks for the log. :)

The plugin start-up looks normal AFAICS. As you suggested, it looks like nothing is getting through to the plugin from the Network as it isn't detecting any responses.

Things to look at (just in case you haven't done so already :wink: ) is whether you have a firewall preventing the response getting through.
Another possibility is that you may have ethernet and wi-fi enabled. In this case it is best to override and specify the host address.

You mentioned stopping other programs that were using port 1900. It may be worth trying this again and after having stopped them, double check nothing is using 1900 and the reload the plugin and run a discovery but again you may have already done this.

It's a bit of a conundrum! Let me know how you get on. :)

Posted on
Sun Aug 13, 2017 12:00 pm
blakekrone offline
Posts: 16
Joined: Sep 13, 2011

Re: v3.0.4 First Time Setup No Discovery

I've tried everything suggested already and there is no firewall. I design networks for a living, deal with this all the time. Next step will be to eventually grab a pcap and see but it seemed oddly familiar with the echo show so wasn't sure if something changed in any firmware or anything on the dot too.

Code: Select all
bacuri:opensource.alexa-hue-bridge blake$ sudo lsof -i :1900
Password:
COMMAND    PID  USER   FD   TYPE             DEVICE SIZE/OFF NODE NAME
IndigoPlu 8384 blake   14u  IPv4 0x4e0e9709f4608fb3      0t0  UDP *:ssdp

Posted on
Mon Aug 14, 2017 12:57 am
autolog offline
Posts: 3988
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: v3.0.4 First Time Setup No Discovery

My Amazon Echos and Amazon Echo Dots work perfectly with Version 3.0.4.
My Echo firmware version is 582001920 and my Echo Dot firmware version is 582230020.

As I am running out of ideas, it might be worth trying a reset on the Echo Dot and starting from square one. :)

Posted on
Mon Aug 14, 2017 10:21 am
blakekrone offline
Posts: 16
Joined: Sep 13, 2011

Re: v3.0.4 First Time Setup No Discovery

Same version. Did the factory reset, still not seeing the requests.

Not sure what the deal is, it's quite odd.

Posted on
Mon Aug 28, 2017 2:11 pm
blakekrone offline
Posts: 16
Joined: Sep 13, 2011

Re: v3.0.4 First Time Setup No Discovery

Still fighting with this. Shouldn't I see the discovery announcement from the Indigo box when this plugin is running? Running a packet capture on the wired side of the Mac Mini running Indigo and the plugin I don't ever see the response from Indigo to any Echo requests for services. I assume that if this plugin is always "discovery: on" that means that it should be sending out a response to any SSDP query. Is that the case? If yes then that is my problem, it's not sending anything!

Posted on
Wed Aug 30, 2017 12:09 pm
autolog offline
Posts: 3988
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: v3.0.4 First Time Setup No Discovery

Despite having done significant changes to the Alexa-Hue Bridge plugin I am not that knowledgeable on networking - I just inherited the previous working code and modified it slightly. :wink:

When discovery is turned 'on' for an Indigo Alexa-Hue Bridge device, the plugin broadcasts that it is alive and discoverable.

When you say to Alexa "Alexa discover devices" it looks for this broadcast and then replies by requesting the device info from the plugin.
The plugin then replies to that request by sending details of the devices to Alexa.

Anyway, that is my understanding (although I stand to be corrected). :)

Posted on
Wed Aug 30, 2017 12:40 pm
jay (support) offline
Site Admin
User avatar
Posts: 18185
Joined: Mar 19, 2008
Location: Austin, Texas

Re: v3.0.4 First Time Setup No Discovery

@autolog - it looks to me like the broadcast thread is still automatically stopping after a certain amount of time (in discovery.py) - are you just restarting it to keep discovery on all the time?

@blakekrone - the process is this: while discovery is turned on, there's a broadcast thread that runs sending out it's advertisement packet every second or so. When you tell the Alexa to discover, it watches for those broadcasts and when it sees one it uses that data to send the request for the URL that will describe the devices connected to the (virtual) hub. So, if broadcast is on, you should see an broadcast packet that looks something like this happening every second or so:

Code: Select all
broadcast_packet = """NOTIFY * HTTP/1.1
HOST: %(broadcast_ip)s:%(upnp_port)s
CACHE-CONTROL: max-age=100
LOCATION: http://%(server_ip)s:%(server_port)s/description.xml
SERVER: FreeRTOS/7.4.2, UPnP/1.0, IpBridge/1.7.0
NTS: ssdp:alive
NT: uuid:%(uuid)s
USN: uuid:%(uuid)s


but with each of those substitutions filled out (ips, ports, uuids, etc). If you don't see that, then the plugin isn't sending the broadcast packet or your sniffer is somehow missing it.

If you have both wired and wireless enabled on your Mac then that's likely the issue. When you're running servers it's not recommended that you have multiple network interfaces active since network binding to apps seems to be unreliable.

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Posted on
Wed Aug 30, 2017 2:25 pm
autolog offline
Posts: 3988
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: v3.0.4 First Time Setup No Discovery

jay (support) wrote:
@autolog - it looks to me like the broadcast thread is still automatically stopping after a certain amount of time (in discovery.py) - are you just restarting it to keep discovery on all the time?


No it doesn't automatically stop if discovery is on.

The value of self._timeout in discovery.py can be from 0 to 10 where 0 means always on.
The code (in lines 99 & 182):
Code: Select all
if self._timeout and time.time() > end_time:
will give False if self._timeout is zero otherwise True. :)

Maybe I should document that in the code.
I'll add it to the list when I fix the other issue tomorrow. :wink:

Posted on
Wed Aug 30, 2017 3:10 pm
jay (support) offline
Site Admin
User avatar
Posts: 18185
Joined: Mar 19, 2008
Location: Austin, Texas

Re: v3.0.4 First Time Setup No Discovery

Gotcha - should have looked at that code more closely... ;)

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 3 guests