TazMataz Und? Bist Du weiter gekommen?
Ich habe mich mal daran probiert:
https://github.com/grover/home…16#issuecomment-516641246
Zitat
Ended up changing dependency for noble to https://github.com/abandonware/node-bluetooth-hci-socket.
To achieve this I had to fork homebridge-ranger and modified a dependency as follows:
"ble-executor": "git+https://github.com/vectronic/ble-executor.git"
which in turn has a modified dependency:
"noble": "git+https://github.com/vectronic/noble.git"
which in turn has a modified dependency:
"bluetooth-hci-socket": "git+https://github.com/abandonware/node-bluetooth-hci-socket"
Alles anzeigen
Wobei "vectronic" seine Forks nicht mehr online hat.
Aus meiner Sicht müsste es reichen, "homebridge-ranger" zu forken und dort auf "git+https://github.com/abandonware/noble" zu verweisen, da das wiederum "abandonware/bluetooth-hci-socket" anzieht.
Ich hab das ganz dilletantisch in der "package.json" gemacht, da ich keine Ahnung habe und es baute unter Node 10 auch durch - lief nur leider nicht.
Unter Node 12 gab es wiederrum Fehler.
Interessanterweise läuft das unter Windows mit "npm install -g --unsafe-perm palasinio/homebridge-ranger"...
EDIT:
Der Ranger baut unter Node 10 auf dem RPI jetzt durch. 
Dazu habe ich "homebridge-ranger" und "ble-executor" geforked und jeweils die "package.json" so angepasst, dass der Ranger auf den geforkten BLE-Executor zeigt und der "BLE-Executor" wiederum auf:
"dependencies": {
"debug": "^4.1.1",
"noble": "git+https://github.com/abandonware/noble.git"
},
Den da nicht vergessen:
sudo setcap cap_net_raw+eip $(eval readlink -f `which node`)
Hi,
während Ranger unter Node 10 nun ganz gut läuft, klemmt es unter Node 12 nun an anderer Stelle:
curve.target.mk:107: die Regel für Ziel „Release/obj.target/curve/node_curve.o“ scheiterte
make: *** [Release/obj.target/curve/node_curve.o] Fehler 1
make: Verzeichnis „/usr/local/lib/node_modules/homebridge-ranger/node_modules/curve25519-n2/build“ wird verlassen
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack at ChildProcess.emit (events.js:223:5)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Linux 4.19.79-v7+
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/local/lib/node_modules/homebridge-ranger/node_modules/curve25519-n2
gyp ERR! node -v v12.14.1
gyp ERR! node-gyp -v v5.0.5
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
Alles anzeigen