Web bluetooth multiple devices #1966
Replies: 10 comments
-
Posted at 2017-01-14 by Ollie Solved both issues by starting again from this page which is very helpful boilerplate. https://beaufortfrancois.github.io/sandbox/web-bluetooth/generator/ |
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-16 by François Hey @ollie, I'm glad this page helped. Thanks in advance ;) |
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-16 by @gfwilliams It might be some problem with the |
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-16 by Ollie Hi @gfwilliams. No it wasn't the puck.js library -I've had no problems with that, but I haven't tried to run multiple connected devices TBH or two way comms. I was using the Web bluetooth API directly since I know nothing about it, and wanted to familiarise myself. @françois - i've just twigged that is your page - thanks! I'm afraid I don't have much of my code left to share, I was experimenting on a saturday afternoon so nothing under version control. The fact the boilerplate worked suggests it was me - promises are a bit new to me TBH. Should I be able to replicate it I will post code. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-19 by Ollie What is the limit to the number of connections over web bluetooth - is it hardware dependent? And could the connection dialog that pops up allow selection of multiple devices. Say I am connecting 3 pucks, it would be good to select them all and leave the browser to iterrate through the connections, rather than have to go back to the dialog three times. Just a thought after using the interface for a while now :) |
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-19 by @gfwilliams
Yes, it depends on hardware. @françois will know better than me but I think it's around 6 - not lots anyway. Multiple selection would be good, but I imagine it's a way down their priority list. Personally I'd like to see a 'remember this choice' checkbox - I think that could be really powerful, and might ease your multi-selection pain as well! |
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-19 by Ollie Thanks - I have had 5 pucks connected. That's all I have so can't test 6 or 7. Anyway, this is what I have so far if interested - basically a gateway using Web Bluetooth. I started from @françois's boiler plate. https://olliephillips.github.io/webbleMQ/ I plan to attempt to add the HTTP proxy and MQTT gateway but I think that's likely to need a server backend to be reliable. But I am out of time for now - unfortunately work beckons - but I will come back to this. Lots of potential! Edit: README with some info on what it does https://github.com/olliephillips/webbleMQ |
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-24 by François Here's what we know from Emil:
|
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-24 by Ollie Thanks for this. So Android Bluetooth capped at 7 connections, by design or otherwise. I'm also interested in other hardware/stack constraints too. While it would be relatively simple to detect device and act on limits in a web app - we'd need to know what they are. How can I find/monitor this? |
Beta Was this translation helpful? Give feedback.
-
Posted at 2017-01-25 by François @ollie I would follow WebBluetoothCG/web-bluetooth#342 for now ;) |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2017-01-14 by Ollie
I see a bit of weirdness when connecting multiple devices via web bluetooth.
Connect first device, read RX to console. Connect second read RX to console, first devices stops being read - nothing in from it in console. Connect first device again. Both devices now show their RX in console.
I can repeat this. Anyone else?
Edit:
Can also ask about how people are differentiating the device responsible for the UART RX in their web bluetooth applications. I'm setting up two objects, but seeing RX from two devices associated with last connected device.
I'd like to be able to identify which device is sending what.
Beta Was this translation helpful? Give feedback.
All reactions