-
Notifications
You must be signed in to change notification settings - Fork 44
Open
Labels
Description
I'm trying to build a Eddystone beacon that hosts it's own Web Bluetooth based control interface.
The Web Bluetooth API lets me filter BLE devices either by name prefix or advertised services. At the moment I'm having to use the name prefix as the services I've attached are not getting advertised along with the URL. I'd like to be able to let users set arbitrary names for beacons so I would like to move away from using the name prefix.
My code currently looks like this
var toggle = new ToggleCharacteristic(toggleCallback);
var dim = new RangeCharacteristic(dimCallback);
var characteristics = [toggle, dim];
bleno.once('advertisingStart', function(err) {
if (err) {
throw err;
}
bleno.setServices([
new BlenoPrimarySerivce({
uuid: 'ba42561bb1d2440a8d040cefb43faece',
characteristics: characteristics
})
]);
});
eddystone.advertiseUrl(config.shortURL, {name: config.name});
Reactions are currently unavailable