abandonware / bleno

A Node.js module for implementing BLE (Bluetooth Low Energy) peripherals
https://mastodon.social/@rzr/106068437787315146#bleno
MIT License
149 stars 52 forks source link

a different Node.js version using #46

Closed edgexie closed 1 year ago

edgexie commented 1 year ago

my node v18.18.0 when run the node code , there is a error below in console:

Error: The module '/home/pi/raspi/bleno-starter/node_modules/@abandonware/bluetooth-hci-socket/build/Release/bluetooth_hci_socket.node'
was compiled against a different Node.js version using
edgexie commented 1 year ago

It's my wrong . I link error version from nvm to /usr/local/bin. Digression, bleno-hci-socket use root node, so I link nvm node to usr/local/bin. reference:

https://github.com/noble/node-bluetooth-hci-socket/issues/110#issuecomment-489064443