[gelöst] Homekit / Homebridge mit Debian 11 (Bullseye)

Begonnen von Micky, 27 August 2023, 20:09:01

Vorheriges Thema - Nächstes Thema

Micky

Abends Zusammen,

nach neuinstallation auf Debian 11 (Bullseye), habe ich durch Ottos Fhem backup Blog das meiste wieder zurückspielen können.
Auf den ersten Blick fehlen mir nur 2 Module

TP Link HS110 Wifi Stecker
-https://github.com/kettenbach-it/FHEM-TPLink-HS110
EDIT: ERledigt mit cpan modul nach installation.

Und HomeBridge läuft nicht


Bei HomeBridge für Homekit Siri, weiß ich nicht welche Version ich nehmen soll in der Wiki steht

NodeJS V11 aber die Raspberry möchte das ich eher auf 14 bzw. 16 oder höher gehe.

Wisst Ihr welches Version gerade also bzgl. npm / node und nodeJS für Homebridge laufen. ??

Anbei die installierte Version
root@raspberrypi:~# node -v
v11.15.0
root@raspberrypi:~# nodejs -v
v11.15.0
root@raspberrypi:~# npm -v
6.7.0
root@raspberrypi:~#


pi@raspberrypi:/root $ homebridge
[8/27/2023, 8:05:57 PM] config.json (/home/pi/.homebridge/config.json) not found.
[8/27/2023, 8:05:57 PM] Loaded 0 cached accessories from cachedAccessories.
[8/27/2023, 8:05:57 PM] ---
Error: EACCES: permission denied, scandir '/root'
(node:1547) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'loaded' of undefined
    at exit (/usr/lib/node_modules/npm/lib/utils/error-handler.js:98:27)
    at errorHandler (/usr/lib/node_modules/npm/lib/utils/error-handler.js:216:3)
    at /usr/lib/node_modules/npm/bin/npm-cli.js:78:20
    at cb (/usr/lib/node_modules/npm/lib/npm.js:225:22)
    at /usr/lib/node_modules/npm/lib/npm.js:263:24
    at /usr/lib/node_modules/npm/lib/config/core.js:83:7
    at Array.forEach (<anonymous>)
    at /usr/lib/node_modules/npm/lib/config/core.js:82:13
    at f (/usr/lib/node_modules/npm/node_modules/once/once.js:25:25)
    at /usr/lib/node_modules/npm/lib/config/core.js:112:20
(node:1547) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:1547) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
TypeError: Cannot read property 'loaded' of undefined
    at process.<anonymous> (/usr/lib/node_modules/npm/lib/utils/error-handler.js:40:18)
    at process.emit (events.js:193:13)
/usr/lib/node_modules/npm/lib/utils/error-handler.js:98
  var doExit = npm.config.loaded ? npm.config.get('_exit') : true
                          ^

TypeError: Cannot read property 'loaded' of undefined
    at exit (/usr/lib/node_modules/npm/lib/utils/error-handler.js:98:27)
    at process.errorHandler (/usr/lib/node_modules/npm/lib/utils/error-handler.js:216:3)
    at process.emit (events.js:193:13)
    at process._fatalException (internal/process/execution.js:123:25)
[8/27/2023, 8:05:58 PM] Warning: skipping plugin found at '/lib/node_modules/homebridge-fhem' since we already loaded the same plugin from '/usr/lib/node_modules/homebridge-fhem'.
[8/27/2023, 8:05:58 PM] Loaded plugin: homebridge-fhem@0.5.38
homebridge API version: 2.7
this is homebridge-fhem 0.5.38
[8/27/2023, 8:05:59 PM] ====================
[8/27/2023, 8:05:59 PM] ERROR INITIALIZING PLUGIN homebridge-fhem:
[8/27/2023, 8:05:59 PM] /usr/lib/node_modules/homebridge-fhem/node_modules/https-proxy-agent/dist/index.js:54
        this.proxyHeaders = opts?.headers ?? {};
                                ^

SyntaxError: Unexpected token .
    at Module._compile (internal/modules/cjs/loader.js:760:23)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:827:10)
    at Module.load (internal/modules/cjs/loader.js:685:32)
    at Function.Module._load (internal/modules/cjs/loader.js:620:12)
    at Module.require (internal/modules/cjs/loader.js:723:19)
    at require (internal/modules/cjs/helpers.js:14:16)
    at Object.<anonymous> (/usr/lib/node_modules/homebridge-fhem/node_modules/gaxios/src/gaxios.ts:33:1)
    at Module._compile (internal/modules/cjs/loader.js:816:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:827:10)
    at Module.load (internal/modules/cjs/loader.js:685:32)
[8/27/2023, 8:05:59 PM] ====================
[8/27/2023, 8:05:59 PM] ---
Setup Payload:
X-HM://0023ISYWY7GWR
Scan this code with your HomeKit app on your iOS device to pair with Homebridge:

Abgesehen von den Fehlermeldungen, ist der Code auch nicht der richtige wenn es mit PI aufrufe, nur wenn ich es mit Fhem aufrufe....passt es wieder....

Oder sollte man mittlerweile auf Homebridge Config UI von Github gehen?


Evtl. habt Ihr eine Idee


Micky

Hi Zusammen,

Info an alle die es interessiert es läuft nun wieder. Denke homebridge-fhem ist doppelt in der RPI aber es läuft akuell.

Ich habe nämlich erst die Komplette Installation aus der FHEM WIKI Homebdirge und anschließend noch Homebridge UI und dort das Plugin Homebridge Fhem installiert.

Also in der Theorie war glaub ich die Installation von homebridge-fhem nach wiki unnötig, da man das Plugin über die UI installiert.

Also meine hier:
Durch Wiki Installation : npm install -g homebridge-fhem
Durch UI Installation : homebridge-fhem

Hab jetzt das Verzeichnis homebdirge welches doppelt war samt Inhalt gelöscht config.json etc. war alles doppelt in UI Verzeichnis ist das aktuelle.

Musste Namen und die MAC geändert andernfalls wollte er die Homebridge auf den Apfel nicht hinzufügen, das zurückspielen der Geräte über Persist und Accessories hat leider nicht geklappt.
Ich musste also Apple Home neu Einrichten.

Ich denke für die Zukunft wird es ggf. mit der HomeBridge UI einfacher da man von dort aus die Backups über das UI direkt erstellen und zurückspielen kann (noch nicht getestet), weiß nicht ob es aber Analog auf die HomeApp Synchronisiert wird (sieht aber nicht so aus).

Viele Grüße
Micky