bwssytems / ha-bridge

Home automation bridge that emulates a Philips Hue light system and can control other systems such as a Vera, Harmony Hub, Nest, MiLight bulbs or any other system that has an http/https/tcp/udp interface. This is a compact impl to run on small format computers. This is impl started from this project https://github.com/armzilla/amazon-echo-ha-bridge.
Apache License 2.0
1.45k stars 199 forks source link

Alexa doesn´t find the ha-bridge #973

Closed McNose closed 6 years ago

McNose commented 6 years ago

Hi,

I am sorry for asking a very popular question but nothing I have seen so far helped me. I got a raspberry pi 3 with the newest version of the ha-bridge. The port is 80. I want to control my fibaro devices and connected it in the configurations of the ha-bridge. Using the web-interface of the ha-bridge I can control the devices. So far so good.

But alexa does not find any device of the ha-bridge. I also tried a fresh raspberry installation and an older version of the ha-bridge with no luck.

The ha-bridge log file shows me two warnings:

Level | Message | Component | INFO | HA Bridge startup sequence... | com.bwssystems.HABridge.HABridge | INFO | reading from config file: /home/pi/habridge/data/habridge.config | com.bwssystems.HABridge.BridgeSettings | WARN | The upnp config address, 192.168.178.31, does not match any known IP's on this host. | com.bwssystems.HABridge.BridgeSettings | INFO | HA Bridge (v5.2.1) initializing.... | com.bwssystems.HABridge.HABridge | INFO | StaticResourceHandler configured with folder = /public | spark.staticfiles.StaticFilesConfiguration | INFO | System control service started.... | com.bwssystems.HABridge.SystemControl | INFO | Initializing UDP response Socket... | com.bwssystems.HABridge.util.UDPDatagramSender INFO | UDP response Socket initialized to: 50000 | com.bwssystems.HABridge.util.UDPDatagramSender | INFO | HTTP Home created. | com.bwssystems.HABridge.plugins.http.HTTPHome | INFO | Harmony Home created. No Harmony devices configured. | com.bwssystems.HABridge.plugins.harmony.HarmonyHome | INFO | Nest Home created. No Nest configured. | com.bwssystems.HABridge.plugins.NestBridge.NestHome | INFO | Hue passthru Home created. No Hue passtrhu systems configured. | com.bwssystems.HABridge.plugins.hue.HueHome | INFO | HAL Home created. No HAL devices configured. | com.bwssystems.HABridge.plugins.hal.HalHome | INFO | MQTT Home created. No MQTT Clients configured. | com.bwssystems.HABridge.plugins.mqtt.MQTTHome | INFO | HomeAssistant Home created. No HomeAssistants configured. | com.bwssystems.HABridge.plugins.hass.HassHome | INFO | HomeWizard Home created. No HomeWizard gateways configured. | com.bwssystems.HABridge.plugins.homewizard.HomeWizardHome | INFO | Command Home for system program execution created. | com.bwssystems.HABridge.plugins.exec.CommandHome | INFO | TCP Home created. | com.bwssystems.HABridge.plugins.tcp.TCPHome | INFO | UDP Home created. | com.bwssystems.HABridge.plugins.udp.UDPHome | INFO | Vera Home created. No Veras configured. | com.bwssystems.HABridge.plugins.vera.VeraHome | INFO | Fibaro Home created. | com.bwssystems.HABridge.plugins.fibaro.FibaroHome | INFO | Domoticz Home created. No Domoticz devices configured. | com.bwssystems.HABridge.plugins.domoticz.DomoticzHome | INFO | Somfy Home created. No Somfys configured. | com.bwssystems.HABridge.plugins.somfy.SomfyHome | INFO | LifxDevice Home created. No LifxDevices configured. | com.bwssystems.HABridge.plugins.lifx.LifxHome | INFO | OpenHAB Home created. No OpenHABs configured. | com.bwssystems.HABridge.plugins.openhab.OpenHABHome | INFO | FHEM Home created. No FHEMs configured. | com.bwssystems.HABridge.plugins.fhem.FHEMHome | INFO | Broadlink Home created. No Broadlinks configured. | com.bwssystems.HABridge.plugins.broadlink.BroadlinkHome | INFO | == Spark has ignited ... | spark.embeddedserver.jetty.EmbeddedJettyServer | INFO | >> Listening on 0.0.0.0:80 | spark.embeddedserver.jetty.EmbeddedJettyServer | WARN | Error reading the file: data/group.db - Does not exist or is not readable. continuing... | com.bwssystems.HABridge.dao.GroupRepository | INFO | HABridge device management service started.... | com.bwssystems.HABridge.devicemanagmeent.DeviceResource | INFO | Hue emulator service started.... | com.bwssystems.HABridge.hue.HueMulator | INFO | Traceupnp: upnp config address: 192.168.178.31-useIface:false on web server: 0.0.0.0:80 | com.bwssystems.HABridge.HABridge | INFO | Description xml service started.... | com.bwssystems.HABridge.upnp.UpnpSettingsResource | INFO | UPNP Discovery Listener starting.... | com.bwssystems.HABridge.upnp.UpnpListener | INFO | Traceupnp: Interface: wlan0 valid usable IP address: /192.168.178.31 | com.bwssystems.HABridge.upnp.UpnpListener | INFO | Traceupnp: Adding wlan0 to our upnp join interface set. | com.bwssystems.HABridge.upnp.UpnpListener | INFO | Traceupnp: Interface: lo valid usable IP address: /127.0.0.1 | com.bwssystems.HABridge.upnp.UpnpListener | INFO | Traceupnp: Adding lo to our upnp join interface set. | com.bwssystems.HABridge.upnp.UpnpListener | INFO | UPNP Discovery Listener running and ready.... | com.bwssystems.HABridge.upnp.UpnpListener | INFO | Traceupnp: hue api user create requested for device type: test_ha_bridge#192.168.178.25 and username: 19b92b5cd8d8436b9abd7a60806bc027 | com.bwssystems.HABridge.hue.HueMulator

The first warning is very stange because that is the IP of the raspberry where ha-bridge is running. Close to the end the log says: "UPNP Discovery Listener running and ready"; so maybe the first warning is not important? But the second one is strange. There is no such file. Where should it be?

Could somebody please help me? Thank you.

henits commented 6 years ago

I think there should be no problem with the group.db file not existing. It used to work for me without the group.db file but maybe things have changed and that is why it is not working for me too.

McNose commented 6 years ago

And? Did you find a solution? Or do you have any hint where I can look for it?

bwssytems commented 6 years ago

The group.db file is informational and not an issue.

The ha-bridge seems to not have access to the interface that the IP you specify. Please run ifconfig with no parameters and make sure your pi has that address.

McNose commented 6 years ago

Hi,

thank you for helping me. Maybe I am totally wrong or don´t understand it. Which address do I have to enter in the UPNP IP address? I entered the same address I run the ha-bridge on. This one is shown too when entering ifconfig on the pi. My setting is as followed:

Do I have to install alexa on another Pi? What is the UPNP IP address for? I dont understand the explanation writen here: Description. For a test I just entered something wrong and could still controll my home using the webinterface.

Thank you.

audiofreak9 commented 6 years ago

@McNose

You need a physical Echo to discover the ha-bridge per the README:

"This requires a physical Amazon Echo, Dot or Tap and does not work with prototype devices built using the Alexa Voice Service e.g. Amazon's Alexa AVS Sample App and Sam Machin's AlexaPi. The AVS version does not have any capability for Hue Bridge discovery!"

McNose commented 6 years ago

Oh no. What a pitty. I haven´t read this. Thank you.

If anybody knows a similar method which works with the avs version, please let me know.