Alexa and Hue Emulation - No devices discovered

Hello,

I went through the discussions but couldn’t find a solution for my issue so far. I’m running on the nightly build of OpenHAB on port 7080 (so don’t get confused it’s the same in the log) and have installed Hue Emulation and tagged a couple of switches. So far so good but when I asked Alexa to discover devices, it discovers none.

I’ve set the Hue Emulation binding to log level TRACE and got this:

14:18:11.492 [TRACE] [ation.internal.HueEmulationUpnpServer] - Got SSDP Discovery packet from 10.0.2.91:50000
14:18:11.492 [TRACE] [ation.internal.HueEmulationUpnpServer] - Sending to 10.0.2.91 : HTTP/1.1 200 OK
HOST: 239.255.255.250:1900
EXT:
CACHE-CONTROL: max-age=100
LOCATION: http://10.0.1.1:7080/api/description.xml
SERVER: FreeRTOS/7.4.2, UPnP/1.0, IpBridge/1.15.0
hue-bridgeid: 24C3931C1578
ST: upnp:rootdevice
USN: uuid:08b031a3-fefc-45e0-8ce9-24c3931c1578::upnp:rootdevice


14:18:11.494 [TRACE] [ation.internal.HueEmulationUpnpServer] - Sending to 10.0.2.91 : HTTP/1.1 200 OK
HOST: 239.255.255.250:1900
EXT:
CACHE-CONTROL: max-age=100
LOCATION: http://10.0.1.1:7080/api/description.xml
SERVER: FreeRTOS/7.4.2, UPnP/1.0, IpBridge/1.15.0
hue-bridgeid: 24C3931C1578
ST: urn:schemas-upnp-org:device:basic:1
USN: uuid:08b031a3-fefc-45e0-8ce9-24c3931c1578::upnp:rootdevice


14:18:11.495 [TRACE] [ation.internal.HueEmulationUpnpServer] - Sending to 10.0.2.91 : HTTP/1.1 200 OK
HOST: 239.255.255.250:1900
EXT:
CACHE-CONTROL: max-age=100
LOCATION: http://10.0.1.1:7080/api/description.xml
SERVER: FreeRTOS/7.4.2, UPnP/1.0, IpBridge/1.15.0
hue-bridgeid: 24C3931C1578
ST: uuid:08b031a3-fefc-45e0-8ce9-24c3931c1578
USN: uuid:08b031a3-fefc-45e0-8ce9-24c3931c1578::upnp:rootdevice

What makes me suspicious is that it calls Alexa to location description.xml (which I also see a GET request to that URL comes from) but not to discovery.xml which most other posts have described.

Does anybody know why / when Alexa does not call the discovery.xml and does not show any devices. If I call the discovery.xml manually in a browser, I see the tagged devices there.

Thanks a lot for any help!

One possibility is that If you have a real Hue HUB, you need to unplug it during the Alexa discovery process. If you do not, Alexa discovery gets “stuck” on the real hub instead of getting to OH Hue Emulation.

Once discovery is complete, you can plug the hub back in.

1 Like

Hello @bob_dickenson

that would be indeed the easy one, but unfortunately I don’t have a Hue HUB in my home.

Additional question: in the tutorials I didn’t see that I need to install an Alexa skill for this. I suppose I don’t have to, correct?

By the way, this is what the discovery.xml looks like:

<root xmlns="urn:schemas-upnp-org:device-1-0">
<specVersion>
<major>1</major>
<minor>0</minor>
</specVersion>
<URLBase>http://10.0.1.1:7080/</URLBase>
<device>
<deviceType>urn:schemas-upnp-org:device:Basic:1</deviceType>
<friendlyName>openHAB Hue Emulation</friendlyName>
<manufacturer>Royal Philips Electronics</manufacturer>
<manufacturerURL>http://www.philips.com</manufacturerURL>
<modelDescription>Philips hue Personal Wireless Lighting</modelDescription>
<modelName>Philips hue bridge 2015</modelName>
<modelNumber>929000226503</modelNumber>
<modelURL>http://www.meethue.com</modelURL>
<serialNumber>0017880ae670</serialNumber>
<UDN>uuid:08b031a3-fefc-45e0-8ce9-24c3931c1578</UDN>
<serviceList>
<service>
<serviceType>(null)</serviceType>
<serviceId>(null)</serviceId>
<controlURL>(null)</controlURL>
<eventSubURL>(null)</eventSubURL>
<SCPDURL>(null)</SCPDURL>
</service>
</serviceList>
<presentationURL>index.html</presentationURL>
<iconList>
<icon>
<mimetype>image/png</mimetype>
<height>48</height>
<width>48</width>
<depth>24</depth>
<url>hue_logo_0.png</url>
</icon>
<icon>
<mimetype>image/png</mimetype>
<height>120</height>
<width>120</width>
<depth>24</depth>
<url>hue_logo_3.png</url>
</icon>
</iconList>
</device>
</root>

The discovery.xml on my system, however, shows the one “Switchable” I tagged

{"lights":{"3":{"state":{"on":false,"bri":-1,"hue":0,"sat":0,"xy":[0.0,0.0],"ct":500,"alert":"none","effect":"none","colormode":"ct","reachable":true},"type":"Dimmable Light","name":"Wandheizung","modelid":"LWB004","uniqueid":"3","manufacturername":"openHAB","swversion":"66009461","pointsymbol":{"1":"none","2":"none","3":"none","4":"none","5":"none","6":"none","7":"none","8":"none"}}}}

Thanks a lot on any help!

You do not have to install an Alexa skill.

Is it possible you have a neighbor who has a Hue hub ? They would have to be pretty close – maybe with a shared interior wall ?

Hello @bob_dickenson

not that I know and they would be on a different Wifi, wouldn’t they? I am curious about something else - should the default Philips Hue App on Android also work with this? I installed it but the Hue Emulation is not found - I don’t know whether that’s expected or not.

Could this also be related to me being on OpenHAB 2.2 nightly instead on 2.1?

I have the same problem. I had everything running fine, then got a new Echo today. The new Echo always reported all my items as not reachable, so I removed them and tried to add them again using the alexa app. The app does not find the things any more, even though it has worked with the same configuration without problems.

My Hue lights are discovered, so the Echo does not seem to have a hardware problem.

The log only shows two entries (with DEBUG level):

2017-11-24 17:39:00.283 [DEBUG] [ulation.internal.HueEmulationServlet] - 192.168.178.55: GET /api/description.xml
2017-11-24 17:39:00.333 [DEBUG] [ulation.internal.HueEmulationServlet] - 192.168.178.55: GET /api/description.xml

Hi @vbier

I perhaps should have mentioned that I got my Echo (2nd generation) today as well brand-new (as it was cheaper in the Black Monday week).

This sounds as it could be that Amazon changed something with the software / discovery process. Does somebody else have a new device (2nd generation Echo with latest software) where it works?

For IKEA Tradfri Amazon Echo works, so this has to be a problem on the Hue Emulation. :frowning:

I have once again connected my Echo Dot and discovery works as expected. As long as I have the Dot connected, I can even control devices with the new Echo. But as soon as I plug out the Dot, I can no longer control the devices and also can not discover them (after I removed them using the alexa web page).

I am also on openHAB 2.2.0 (#1044), I am not sure if that makes a difference, it looks more as if there is a incompatibility with the 2nd gen Echo.

I can confirm what @vbier says. I just received my Echo Dot (2nd generation) and this one is able to find the lights from the Hue Emulation and I can control them from both - the Echo and Echo Dot. Without Echo Dot, however, it does not work.

Also what I figured is that my Thermostats are not recognized but only Lighting and Switchable items.

Anybody else out there with Echo experiencing that and/or who found a solution? :thinking:

@antares2001

tag [ “Thermostat” ] is not supported with Hue Emulation.

Only tag [ “TargetTemperature” "] is supported. See here Link

Like this example:

Number  TestNumber4     "Temperature Set Point" [ "TargetTemperature" ] {channel="..."}

Not supported:

Hi @Celaeno1

thanks for that info. So it’s different there to the OpenHAB cloud connector. Got that. Is there any way to ask for current temperature then or is it just possible to set temperatures?

Also I have it defined as follows, but Echo / Echo Dot do not discover it:

Number HEAT_DG_Kind "Kinderzimmer Heizung [%.1f °C]" <heating> (gKind,gHeatingDG) [ "TargetTemperature" ]

Did I do anything wrong there?

tag [ “CurrentTemperature” ] is not supported (with hueemulation).

Number	HEAT_DG_Kind	"Kinderzimmer Heizung [%.1f °C]"	<heating>	(gKind,gHeatingDG)	[ "TargetTemperature" ]

It looks OK, but your channel is missing… (but that’s not the problem!)

First of all, your device should be shown in Alexa App.

see also this topic: Link

Maybe you need to use tag [ “Themostat” ] but only the line [ “TargetTemperature” ] is running?

Group gDownstairsThermostat "Downstairs Thermostat" (gFF) [ "Thermostat" ]
Number DownstairsThermostatCurrentTemp "Downstairs Thermostat Current Temperature" (gDownstairsThermostat) [ "CurrentTemperature" ]
Number DownstairsThermostatTargetTemperature "Downstairs Thermostat Target Temperature" (gDownstairsThermostat) [ "TargetTemperature" ]
String DownstairsThermostatHeatingCoolingMode "Downstairs Thermostat Heating/Cooling Mode" (gDownstairsThermostat) [ "homekit:HeatingCoolingMode" ]

Then, you have to tell: “Alexa, set ‘Downstairs Thermostat’ to 20 degrees” (like in this example above!)

I did use hueemulation only for 2 or 3 days. Then I switched to “Openhab Cloud Service”, long time ago. I could not remember exactly what I tagged there… sorry! The only thing I can tell: TargetTemperature was running with hueemulation! (but only TargetTemperature!!)

1 Like

Hi @Celaeno1

thanks for your reply. I’ll investigate further then. The channel is missing because I have multiple OpenHAB instances running in my house synced through MQTT and eventbus, so not every item has a channel on the main instance. :slight_smile:

Do you know who maintains the Hue Emulation binding or whether it’s dead, because I added an issue on the openhab-addons issue tracker on Github but seems those for Hue Emulation are not looked at, since there’s other issues as well without comments.

digitaldan

Thanks @Celaeno1.

So let’s ping @digitaldan :slight_smile:

I’ve been trying to ping Dan for about a month with other HUE Emulation issues…but it looks as if he may have gone silent.

I’m hopeful he will come up for air soon…he has always been of great assistance.

I’m sure he probably has real world issues requiring his attention.

https://community.openhab.org/t/hue-emulation-alexa-not-responding-after-2-2-upgrade/
1 Like

Dan is quite busy with updates and fixes for the IOS and Android apps

@antares2001 @hmerk

The reason why “TargetTemperature” is not running anymore, could be:

“TargetTemperature” is missing in Line94.

@digitaldan Do you know about this? Was it ever there?

see also here in Line83:

https://programtalk.com/vs/openhab2-addons/addons/io/org.openhab.io.hueemulation/src/main/java/org/openhab/io/hueemulation/internal/HueEmulationServlet.java/

@Kai Maybe you know the reason why “TargetTemperature” is gone?

1 Like

I have the Echo 2gen working now. You have to change discovery port to 80 and forward all requests on port 80 to 8080 (or whatever you openHAB port is). On linux this can easily be done using iptables.

Afterwards, the Echo detects the devices and can switch them on and off. You get an error message when turning things on, but it works. You can get rid of the error message with a change to the hue emulation code.

See the related issue for details: