Node red to use onboard pi 3+ bluetooth

Hello everybody,

It's been a day now, that i'm reading on github on other forum, including this one to find a way to do a simple thing.

I want to use node-red and the inboard bluetooth of the raspberry pi 3+ to send data to a android phone. For exemple, i want my user to press a button connected to Gpio pin, and i want the raspberry pi to broadcast it to all android phone with bluetooth.

My question is how can i access the onboard bluetooth using node red flow to send the input of the button ? Because i search and tried a lot of node-red library but none of them let me use the onboard bluetooth to send data. How can i possibly do this ?

Thank you for all your help.


What makes you think this is simple? Anything related to Bluetooth is rarely simple.

The first thing to note is that Bluetooth makes no assumptions about nor provides you with a protocol to exchange information. So you need something to create a PAN (personal area network) between the devices. Then you can use higher level protocols like HTTP/WSS/etc over that.

As I said, not simple because BT doesn't itself provide that support.

"Find a way to do a simple thing" as i was thinking that some possibility to communicate from and to some bluetooth deveice was already implemented in a node-red library.

GPIO is accessible from node-red interface and is easely added to a flow. My guest was that bluetooth would also be avaliable as a node-red component that could be added to a flow with some minor configuration, with the ability to send special data or at least some boolean.

Maybe some people around here have already implemented this kind of thing and could help me finding my way in this bluetooth jungle.

Thanks by the way for your answer

You could try node-red-contrib-generic-ble

Thanks already tried it and faced the same error as this guy:

So i was a bit stuck. Plus i don't know if it ok as it's the raspberry pi that is scanning for other devices and what i want is to access the bluetooth component of my pi to make him send data, exactly like with the GPIO pin.

Did you ever get this working as I have the same issue.