Homebridge Installation w/WLAN

  • Hallo, ich fange gerade an mit der Heimautomatisierung.

    Ich bin nun hier auf die Homebridge aufmerksam geworden - juhu! Endlich eine Verwendung für den RasPi.

    Die Installation auf dem RasPi war easy, die iOS App ist soweit okay.


    Aktuell scheitere ich daran meinen RasPi und meinen Apple TV-4K miteinander zu verknüpfen.


    Ich kann in der "Home" App über manuelles Hinzufügen (Gerät Hinzufügen -> Code fehlt -> Code eingeben... -> Code eingeben -> warten.....nix passiert)


    Mein AppleTV steht im EG und ist per LAN verbunden.

    Der RasPi steht im UG und ist auch per LAN verbunden.


    Was mache ich hier falsch? Wo kann ich nachsehen was falsch sein könnte? Die Logs in /var/log geben jetzt nicht viel her.


    Danke & vg, oli

  • Probier mal in einer anderen HomeKit App die Homebridge hinzuzufügen z.B. Elgato Eve. Wenn das nicht klappt eventuell man den Accessoires Ordner löschen.

  • Einfach ist das nicht.

    Accessories Ordner gelöscht und Homebridge via Console gestartet.

    Dann dan 2D Barcode scannen - voila. Kurz jedenfalls.

    Auf der Consolte gab es jede Menge Fehler:

    events.js:183

    throw er; // Unhandled 'error' event

    ^


    Error: listen EADDRINUSE :::51826

    at Object._errnoException (util.js:1022:11)

    at _exceptionWithHostPort (util.js:1044:20)

    at Server.setupListenHandle [as _listen2] (net.js:1351:14)

    at listenInCluster (net.js:1392:12)

    at Server.listen (net.js:1476:7)

    at EventedHTTPServer.listen (/usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/lib/util/eventedhttp.js:60:19)

    at HAPServer.listen (/usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/lib/HAPServer.js:158:20)

    at Bridge.Accessory.publish (/usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/lib/Accessory.js:607:16)

    at Server._publish (/usr/local/lib/node_modules/homebridge/lib/server.js:126:16)

    at Server.run (/usr/local/lib/node_modules/homebridge/lib/server.js:96:10)

    at module.exports (/usr/local/lib/node_modules/homebridge/lib/cli.js:40:10)

    at Object.<anonymous> (/usr/local/lib/node_modules/homebridge/bin/homebridge:17:22)

    at Module._compile (module.js:643:30)

    at Object.Module._extensions..js (module.js:654:10)

    at Module.load (module.js:556:32)

    at tryModuleLoad (module.js:499:12)


    Die Home App hat "kurz" funktioniert, jetzt ist alles offline.



  • EADDRINUSE :::51826 bedeutet, dass der Port "51826" bereits in Verwendung ist. Wahrscheinlich läuft deine Homebridge bereits als Service.


    Schau mal mit sudo service homebridge status ob die nicht schon läuft.

  • Merci für die Hilfe - mein Fehler.

    Jetzt aber richtig - stop und start

    pi@raspberrypi:~ $ sudo /etc/init.d/homebridge stop

    Stopping homebridge...

    Stopped

    pi@raspberrypi:~ $ sudo homebridge

    *** WARNING *** The program 'node' uses the Apple Bonjour compatibility layer of Avahi.

    *** WARNING *** Please fix your application to use the native API of Avahi!

    *** WARNING *** For more information see <http://0pointer.de/avahi-compat?s=libdns_sd&e=node>

    *** WARNING *** The program 'node' called 'DNSServiceRegister()' which is not supported (or only supported partially) in the Apple Bonjour compatibility layer of Avahi.

    *** WARNING *** Please fix your application to use the native API of Avahi!

    *** WARNING *** For more information see <http://0pointer.de/avahi-compa…node&f=DNSServiceRegister>

    [2018-2-13 15:34:09] Loaded plugin: homebridge-fritz

    [2018-2-13 15:34:09] Registering platform 'homebridge-fritz.Fritz!Box'

    [2018-2-13 15:34:09] ---

    [2018-2-13 15:34:09] Loaded plugin: homebridge-people

    [2018-2-13 15:34:09] Registering accessory 'homebridge-people.people'

    [2018-2-13 15:34:09] ---

    [2018-2-13 15:34:09] Loaded plugin: homebridge-raspberrypi-temperature

    [2018-2-13 15:34:09] Registering accessory 'homebridge-raspberrypi-temperature.RaspberryPiTemperature'

    [2018-2-13 15:34:09] ---

    [2018-2-13 15:34:10] Loaded plugin: homebridge-synology

    [2018-2-13 15:34:10] Registering accessory 'homebridge-synology.Synology'

    [2018-2-13 15:34:10] ---

    [2018-2-13 15:34:10] Loaded plugin: homebridge-wol

    [2018-2-13 15:34:10] Registering accessory 'homebridge-wol.NetworkDevice'

    [2018-2-13 15:34:10] ---

    [2018-2-13 15:34:10] Loaded config.json with 3 accessories and 1 platforms.

    [2018-2-13 15:34:10] ---

    [2018-2-13 15:34:10] Loading 1 platforms...

    [2018-2-13 15:34:10] [Fritz!Box] Initializing Fritz!Box platform...

    [2018-2-13 15:34:10] Loading 3 accessories...

    [2018-2-13 15:34:10] [Example PC] Initializing NetworkDevice accessory...

    [2018-2-13 15:34:10] [Pi Temp] Initializing RaspberryPiTemperature accessory...

    [2018-2-13 15:34:10] [Synology] Initializing Synology accessory...

    [2018-2-13 15:34:10] [Synology] s

    [2018-2-13 15:34:10] [Synology] start polling...

    [2018-2-13 15:34:10] [Synology] do poll...

    [2018-2-13 15:34:11] [Example PC] NetworkDevice "Example PC" (192.168.178.1) went from status "Offline" to "Online"

    [2018-2-13 15:34:11] [Fritz!Box] Fritz!Box platform login failed

    [2018-2-13 15:34:11] [Synology] current power state is: false

    [2018-2-13 15:34:11] [Synology] poll end, state: false



    Aber in der Home App bleibt es bei "Keine Antwort"

  • Deine Homebridge ist auch noch nicht am laufen da scheinbar deine logindaten der Fritzbox verkehrt sind.


    Wenn die Hb läuft bekommst du eine HK Code angezeigt am ende des Log.

  • Du solltest deine Homebridge besser mit

    Bash
    sudo /etc/init.d/homebridge start

    starten.


    Das Log kannst du dir ansehen mit:

    Bash
    tail -f /var/log/daemon


    und es sollte etwa so enden (wobei möglicherweise ein paar Plugins danach noch weiteres ins Log schreiben)

    Bash
    Feb 13 19:02:36 raspberrypi homebridge[1704]: Or enter this code with your HomeKit app on your iOS device to pair with Homebridge:
    Feb 13 19:02:36 raspberrypi homebridge[1704]: ??????????????
    Feb 13 19:02:36 raspberrypi homebridge[1704]: ? 031-45-199  ?
    Feb 13 19:02:36 raspberrypi homebridge[1704]: ??????????????
    Feb 13 19:02:36 raspberrypi homebridge[1704]: [2018-2-13 19:02:36] Homebridge is running on port 51826.

    Solange das da nicht steht, läuft auch deine Homebridge nicht.


    Stefan

  • Ist schon tricky wenn die Homebridge nicht startet wenn ein Plugin nicht korrekt konfiguriert ist. :-o

    Man gewöhnt sich dran. Ist manchmal wie basteln :D