originallyus / node-red-contrib-alexa-local

An easy-to-use NodeRED node for adding Alexa capability to NodeRED. NO Alexa Skills required.
108 stars 25 forks source link

Discovery fails #42

Closed hannes-angst closed 6 years ago

hannes-angst commented 6 years ago

Setup:

After telling Alexa to scan I see the following node-red logs and the flow node switches to "discovery" :

e9e8b842c87c58 Wohnzimmer GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.13.103
Sending setup.xml to ::ffff:192.168.13.103
e9e8b842c87c58 Wohnzimmer GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.13.103
Sending setup.xml to ::ffff:192.168.13.103
e9e8b842c87c58 Wohnzimmer GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.13.127
Sending setup.xml to ::ffff:192.168.13.127 
e9e8b842c87c58 Wohnzimmer GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.13.127
Sending setup.xml to ::ffff:192.168.13.127
e9e8b842c87c58 Wohnzimmer GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.13.128
Sending setup.xml to ::ffff:192.168.13.128
e9e8b842c87c58 Wohnzimmer GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.13.128
Sending setup.xml to ::ffff:192.168.13.128

However, after a while Alexa gives up telling no devices were found.

See attached the setup.xml file which looks like pretty regular.

After a while, I see the following in the logs:

 e9e8b842c87c58 Wohnzimmer POST / ::ffff:192.168.13.200
 e9e8b842c87c58 Wohnzimmer POST / ::ffff:192.168.13.200 
 e9e8b842c87c58 Wohnzimmer POST / ::ffff:192.168.13.200
 e9e8b842c87c58 Wohnzimmer POST / ::ffff:192.168.13.200

Update: .200 is not so related to the process (mqtt sits there). It should be .128, .127 or .103 (my Alexas). -> mqqt keep-alive packets...

lbr88 commented 6 years ago

I am currently experiencing the same issues and had to another plugin for nodered to get alexa to work. Let me know if i can provide any additional assistance during debugging.

DHDSP commented 6 years ago

Maybe I can help with this. I had exactly the same Problem with my setup (Noder Red running in a Docker container on a Qnap but also native on a Macbook, Echo 2nd gen).

My "solution" is really simple (after hours and hours maybe days of debugging) : I took my older Alexa Dot and everything started to work. The newer model does not yet work.

I would strongly suggest documenting this in the README.md

lbr88 commented 6 years ago

@DHDSP I don't get it. what did you do? i don't have a dot but an echo.

marci144 commented 6 years ago

Yes, with the SECOND generation Dot it does not work!

DHDSP commented 6 years ago

@lbr88 I have 2 Echos: one older Echo dot, and a newer 2nd gen Echo. Only the older Echo (dot) works for now. I could not get the newer 2nd gen Echo working. So @marci144 is right.

edpvic commented 6 years ago

Hello, I have exactly the same behavior with an echo 2nd generation!

nicinuse commented 6 years ago

Hi there, i experience the same issue and found that there is also an issue on ha-bridge. Maybe the possbile fix will help in this case? https://github.com/bwssytems/ha-bridge/issues/860

zuernm commented 6 years ago

Hey, same problem with (German) Amazon Echo (2nd gen). Node switches to discovery but is not regognized as a device by Alexa

Nonsense112 commented 6 years ago

Hi, i also have an Echo Dot gen 2 and i had this problem with the discovery, but on the after a few discoveries attempts it worked.

nicinuse commented 6 years ago

Theres an update on my setup: I am running node-red inside a docker container. After using "--net=host" for running this container (before i only used -p 1880:1880) the discovery started to work (because the echo device is able to access the ports). Seems to be my fault, but will test a little further.

[EDIT] I was able to create 6 devices and all were discovered and can be switched on/off and for the lights the brightness can be controlled. Would be great if setting color would be supported. [/EDIT]

Berthold38 commented 6 years ago

Hey, same problem with (German) Amazon Echo Plus(2nd gen). Alexa will not find the created Node. Thx for helping

alustig commented 6 years ago

I am also having the same issue. Setup:

Everything is on the same network. I am not using docker. When I click "discovery" on my online Amazon Alexa account, this line shows up...

99124a025ad138 Kitchen Lights Local GET /api/uUdCT4RTuTWwIa4GkF9dIHlgQmxkZwABA5WM95tg/lights ::ffff:192.168.1.151 Sending all lights json to ::ffff:192.168.1.151

31 Jan 14:52:37 - [debug] {"state": {"on": true, "bri": 126, "hue": 15823, "sat": 88, "effect": "none", "ct": 313, "alert": "none", "colormode": "ct", "ct": 365, "reachable": true, "xy": [0.4255, 0.3998]}, "type": "Extended color light", "name": "Kitchen Lights Local", "modelid": "LCT004", "manufacturername": "Philips", "uniqueid": "99124a025ad138", "swversion": "65003148", "pointsymbol": {"1": "none", "2": "none", "3": "none", "4": "none", "5": "none", "6": "none", "7": "none", "8": "none"}}

...then it repeats 4 times.

Full debug output:

31 Jan 14:52:19 - [info]

Welcome to Node-RED ===============

31 Jan 14:52:19 - [info] Node-RED version: v0.17.5 31 Jan 14:52:19 - [info] Node.js version: v6.12.3 31 Jan 14:52:19 - [info] Linux 4.9.59-v7+ arm LE 31 Jan 14:52:20 - [info] Loading palette nodes 31 Jan 14:52:26 - [warn] ------------------------------------------------------ 31 Jan 14:52:26 - [warn] [sensehat] Error: Can't find Sense HAT python libraries. Run sudo apt-get install sense-hat 31 Jan 14:52:26 - [warn] ------------------------------------------------------ 31 Jan 14:52:26 - [info] Settings file : /home/pi/.node-red/settings.js 31 Jan 14:52:26 - [info] User directory : /home/pi/.node-red 31 Jan 14:52:26 - [info] Flows file : /home/pi/.node-red/flows_hassbian.json 31 Jan 14:52:26 - [info] Server now running at http://127.0.0.1:1880/ 31 Jan 14:52:26 - [debug] loaded flow revision: c0d30f2671122b19508ee22a2af57644 31 Jan 14:52:26 - [debug] red/runtime/nodes/credentials.load : no user key present 31 Jan 14:52:26 - [debug] red/runtime/nodes/credentials.load : using default key 31 Jan 14:52:26 - [info] Starting flows 31 Jan 14:52:26 - [debug] red/nodes/flows.start : starting flow : global 31 Jan 14:52:26 - [debug] red/nodes/flows.start : starting flow : 8bb69995.c6d3d8 31 Jan 14:52:26 - [debug] red/nodes/flows.start : starting flow : aab5d987.0bef28 31 Jan 14:52:26 - [info] Started flows 99124a025ad138 Kitchen Lights Local GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.1.112 Sending setup.xml to ::ffff:192.168.1.112 99124a025ad138 Kitchen Lights Local GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.1.151 Sending setup.xml to ::ffff:192.168.1.151 99124a025ad138 Kitchen Lights Local GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.1.151 Sending setup.xml to ::ffff:192.168.1.151 99124a025ad138 Kitchen Lights Local GET /api/uUdCT4RTuTWwIa4GkF9dIHlgQmxkZwABA5WM95tg/lights ::ffff:192.168.1.151 Sending all lights json to ::ffff:192.168.1.151 31 Jan 14:52:37 - [debug] {"state": {"on": true, "bri": 126, "hue": 15823, "sat": 88, "effect": "none", "ct": 313, "alert": "none", "colormode": "ct", "ct": 365, "reachable": true, "xy": [0.4255, 0.3998]}, "type": "Extended color light", "name": "Kitchen Lights Local", "modelid": "LCT004", "manufacturername": "Philips", "uniqueid": "99124a025ad138", "swversion": "65003148", "pointsymbol": {"1": "none", "2": "none", "3": "none", "4": "none", "5": "none", "6": "none", "7": "none", "8": "none"}} 99124a025ad138 Kitchen Lights Local GET /api/uUdCT4RTuTWwIa4GkF9dIHlgQmxkZwABA5WM95tg/lights ::ffff:192.168.1.151 Sending all lights json to ::ffff:192.168.1.151 31 Jan 14:52:37 - [debug] {"state": {"on": true, "bri": 126, "hue": 15823, "sat": 88, "effect": "none", "ct": 313, "alert": "none", "colormode": "ct", "ct": 365, "reachable": true, "xy": [0.4255, 0.3998]}, "type": "Extended color light", "name": "Kitchen Lights Local", "modelid": "LCT004", "manufacturername": "Philips", "uniqueid": "99124a025ad138", "swversion": "65003148", "pointsymbol": {"1": "none", "2": "none", "3": "none", "4": "none", "5": "none", "6": "none", "7": "none", "8": "none"}} 99124a025ad138 Kitchen Lights Local GET /api/uUdCT4RTuTWwIa4GkF9dIHlgQmxkZwABA5WM95tg ::ffff:192.168.1.151 Sending all lights json to ::ffff:192.168.1.151 31 Jan 14:52:38 - [debug] {"state": {"on": true, "bri": 126, "hue": 15823, "sat": 88, "effect": "none", "ct": 313, "alert": "none", "colormode": "ct", "ct": 365, "reachable": true, "xy": [0.4255, 0.3998]}, "type": "Extended color light", "name": "Kitchen Lights Local", "modelid": "LCT004", "manufacturername": "Philips", "uniqueid": "99124a025ad138", "swversion": "65003148", "pointsymbol": {"1": "none", "2": "none", "3": "none", "4": "none", "5": "none", "6": "none", "7": "none", "8": "none"}} 99124a025ad138 Kitchen Lights Local GET /api/uUdCT4RTuTWwIa4GkF9dIHlgQmxkZwABA5WM95tg ::ffff:192.168.1.151 Sending all lights json to ::ffff:192.168.1.151 31 Jan 14:52:38 - [debug] {"state": {"on": true, "bri": 126, "hue": 15823, "sat": 88, "effect": "none", "ct": 313, "alert": "none", "colormode": "ct", "ct": 365, "reachable": true, "xy": [0.4255, 0.3998]}, "type": "Extended color light", "name": "Kitchen Lights Local", "modelid": "LCT004", "manufacturername": "Philips", "uniqueid": "99124a025ad138", "swversion": "65003148", "pointsymbol": {"1": "none", "2": "none", "3": "none", "4": "none", "5": "none", "6": "none", "7": "none", "8": "none"}} 99124a025ad138 Kitchen Lights Local GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.1.112 Sending setup.xml to ::ffff:192.168.1.112

thmeger commented 6 years ago

Same problem here:

`109d956559ca93 Langes Fenster GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.178.24

Sending setup.xml to ::ffff:192.168.178.24

6aa165be16eabc Ausblick GET /(null) ::ffff:192.168.178.24

109d956559ca93 Langes Fenster GET /(null) ::ffff:192.168.178.24

34e0ffccd58b68 Rechts GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.178.24

Sending setup.xml to ::ffff:192.168.178.24

c2f00f0d3fd29 Mitte GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.178.24

Sending setup.xml to ::ffff:192.168.178.24

62aaf578b91f64 Bodenstrahler GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.178.24

Sending setup.xml to ::ffff:192.168.178.24

1d94b0ecc28797 Wohnzimmerlicht GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.178.24

Sending setup.xml to ::ffff:192.168.178.24

28ad41cc94502e Küchenstrahler GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.178.24

Sending setup.xml to ::ffff:192.168.178.24

5aa41154addcd Abendessen GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.178.24

Sending setup.xml to ::ffff:192.168.178.24

287d81b72d058e WC-Temperatur GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.178.24

Sending setup.xml to ::ffff:192.168.178.24

2d8d72c4941906 Zentral GET /upnp/amazon-ha-bridge/setup.xml ::ffff:192.168.178.24

Sending setup.xml to ::ffff:192.168.178.24

34e0ffccd58b68 Rechts GET /(null) ::ffff:192.168.178.24

c2f00f0d3fd29 Mitte GET /(null) ::ffff:192.168.178.24

62aaf578b91f64 Bodenstrahler GET /(null) ::ffff:192.168.178.24

1d94b0ecc28797 Wohnzimmerlicht GET /(null) ::ffff:192.168.178.24

28ad41cc94502e Küchenstrahler GET /(null) ::ffff:192.168.178.24

5aa41154addcd Abendessen GET /(null) ::ffff:192.168.178.24

287d81b72d058e WC-Temperatur GET /(null) ::ffff:192.168.178.24

2d8d72c4941906 Zentral GET /(null) ::ffff:192.168.178.24`

Any progress on this? I'm usinf an echo dot 2.generation. This crab floods my logs.

torinnguyen commented 6 years ago

Version 0.3.18 contains a possible fix for Echo Dot Gen 2 implemented by the folks at habridge. Please give it a try.

ManuelW77 commented 6 years ago

Hey there, it would not work for me. I see the Nodes are going to discovery mode while scanning, but Alexa does not find anything, also after a lot of try's. I see a debug message in the nodes

[warn] light state is null in storage

don't know if it have to do with the problem.

I have 2 Dots 2. gen and 1 Echo Plus running. Version 0.3.18 is used.

bsnoop commented 6 years ago

Same here, five Echos 2nd generation. Installed 0.3.18, restarted all Echos, no devices found. They have the yellow discovery indicator but they are not found.

eagleye2 commented 6 years ago

Same problem here. It worked some couple of weeks before. I don't know what changed. I did not change anything on my settings. Now it is not working anymore.

Receiving a debug message in the nodes when trying to find new devices:

[warn] light state is null in storage

Nothing is found.

I have 2x Dots 2. gen and 3x Echo v2 running. Version 0.3.18 is used.

Poquaruse commented 6 years ago

Same for me. It used to work, now I'm still able to talk to existing devices but cannot discover any new devices. I had successfully added and controlled more than ten end points, now no new endpoints are discovered... Perhaps a new firmware update?

Echo 2 and Echo Dot 2...

torinnguyen commented 6 years ago

I had problem discovering devices about 12h hours earlier, even with Echo 1st gen. Now it's working again. I didn't change anything.

torinnguyen commented 6 years ago

Close this issue, please continue discussion in issue #47