Write Characteristic to Web Bluetooth. #3026
Replies: 1 comment
-
|
Posted at 2019-07-29 by @gfwilliams I think I answered this at JSOxford, but if anyone else is interested: Web Bluetooth doesn't let you create services on the device with the Web Browser. However to 'push' data from Espruino to a device with a Web Bluetooth browser, you just need to use notifications: http://www.espruino.com/About+Bluetooth+LE#services-and-characteristics So on Espruino you do: And then on Web Bluetooth you get the characteristic as normal and then call I don't think there's any info on the Espruino site about that yet, but there is a workshop I did which has the relevant code: https://github.com/gfwilliams/workshop-thingy52/blob/master/step5.md |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2019-07-24 by sammachin
I have a pixl that currently advertises a custom service and characteristic which a puck can then discover connect to and write to.
I would like to replicate this with webbluetooth so that the puck can control a browser app instead of the pixl, is that possible? obviously doing something on the page instead of turning on the LED
Below is the code on my pixl.
Beta Was this translation helpful? Give feedback.
All reactions