noble warning: unknown peripheral
See original GitHub issueI am using this add on : https://github.com/futomi/node-thunderboard-react
I used this code in js:
var noble = require('noble');
var ThunderboardReact = require('node-thunderboard-react');
var thunder = new ThunderboardReact({'noble': noble});
thunder.init((error) => {
thunder.startDiscovery((device) => {
console.log('- Found ' + device.localName);
thunder.stopDiscovery();
device.connect((error) => {
console.log('- Connected ' + device.localName);
startMonitorOrientation(device);
});
});
});
// Monitor the sensored data
function startMonitorOrientation(device) {
// Start to monitor the orientation of the device
device.startMonitorOrientation((error) => {
if(error) {
console.log(error.toString());
process.exit();
}
});
// Set a listener for orientation events fired on the ThunderboardReactDevice object
device.on('orientation', (res) => {
// Show the event data
console.log('- Orientation:');
console.log(' - alpha :' + res.alpha + '°');
console.log(' - beta :' + res.beta + '°');
console.log(' - gamma :' + res.gamma + '°');
});
// Stop to monitor and disconnect the device in 5 seconds
setTimeout(() => {
device.stopMonitorOrientation((error) => {
// Disconnect the device
device.disconnect(() => {
console.log('- Disconnected ' + device.localName);
process.exit();
});
});
}, 5000);
}
I got this output:
pi@raspberrypi:~/code/ThunderBoard $ sudo node ExampleB.js
Found Thunder React #15646
Connected Thunder React #15646
Orientation:
alpha :0°
beta :-0.34°
gamma :0.03°
Orientation:
alpha :-0.03°
beta :-0.74°
gamma :0.05°
Orientation:
alpha :-0.06°
beta :-1.14°
gamma :0.08°
Orientation:
alpha :-0.1°
beta :-1.54°
gamma :0.11°
Orientation:
alpha :-0.13°
beta :-1.93°
gamma :0.14°
Orientation:
alpha :-0.16°
beta :-2.33°
gamma :0.17°
Orientation:
alpha :-0.2°
beta :-2.72°
gamma :0.19°
Orientation:
alpha :-0.23°
beta :-3.13°
gamma :0.21°
Orientation:
alpha :-0.26°
beta :-3.52°
gamma :0.24°
Orientation:
alpha :-0.3°
beta :-3.92°
gamma :0.27°
Orientation:
alpha :-0.33°
beta :-4.32°
gamma :0.3°
noble warning: unknown peripheral 000b570c3d1e
The address is the address of the board witch the data is coming from.
I tried getting at hcidump for you as you suggested to the guy on a simular issue but it wouldn’t even connect to the device while this was running (it only has a maybe 75% success rate normally!) but here is that result. Output for that is just :
pi@raspberrypi:~/code/ThunderBoard $ sudo node ExampleB.js
Found Thunder React #15646
^Cpi@raspberrypi:~/code/ThunderBoard $ sudo node ExampleB.js
Found Thunder React #15646
^Cpi@raspberrypi:~/code/ThunderBoard $ sudo node ExampleB.js
Found Thunder React #15646
^Cpi@raspberrypi:~/code/ThunderBoard $ sudo node ExampleB.js
Found Thunder React #15646
any help on these two issues?, I have had no response from the developer of the add-on mentioned above.
Issue Analytics
- State:
- Created 7 years ago
- Comments:8
Top Results From Across the Web
sandeepmistry/noble - Gitter
just got a "noble warning: unknown handle 64 disconnected!" while messing around on Windows using noble. _. Sandeep Mistry. @sandeepmistry.
Read more >Connection problems with javascript API - MBIENTLAB
noble : unknown peripheral d048de5db6c0 disconnected! I am trying to connect a few sensors. It was 4 sensors in range and I was...
Read more >@abandonware/noble NPM | npm.io
A Node.js BLE (Bluetooth Low Energy) central module. Want to implement a peripheral? Check out bleno. Note: macOS / Mac OS X, Linux,...
Read more >Bluetooth on RP 3B - Raspberry Pi Forums
Programming is probably best done with node.js and the noble module. ... noble warning: unknown peripheral 000b570c3d1e ...
Read more >Noble | A Node.js BLE (Bluetooth Low Energy) central module
on('discover', callback(peripheral));. Note: on OS X the address will be set to 'unknown' if the device has not been connected previously. Warnings.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@agonz519 I do not understand what you mean. I eventually found out, that devices behave differently. I had one device that, once connected, stayed connected ‘forever’ and another device, that disconnected after 10 seconds. To be able to handle both cases, I checked in my source code if the device in question is still connected and, if not, reconnect.
@kevinresol On Linux or Windows: If you search for createLeConn in lib/hci-socket/hci.js and edit the value for min-interval and max-interval manually you can change the values globally (the values are in units of 1.25ms). On Macs it’s not possible at all as Apple did not put this value into the API. Alternatively, the BLE device can ask for a suitable connection interval. E.g. the TI Sensor Tag offers a GATT service to change the connection interval (probably as a reaction to Apple’s API). I went the first route and set the intervals to 50-100ms globally which solved my connection issues and increased battery life. And for all devices I had access to the firmware I put in reasonable numbers to start with.