Tag Archives: Bluetooth

Working with Bluetooth using NodeJS and node-red from Intel Edison

via Working with Bluetooth using Node.js and node-red from Intel Edison – CodeProject.

If you are working with Intel Edison then you must have already discovered that getting bluetooth to work in any sensible way in Edison is just a dead end. More so, if you are looking for a workaround with Node.js or node-red.

After hours of trail and errors, I could get it to work. So I am crating this page. Hope it saves someone’s precisous time!

I would tell you the logic first. Intel Edison Bluetooth does not have a Serial port service which is important for phone-Edison communication. Intel has a Python script that provides Serial port service. A mod of this python script was written to write the data to a named pipe which could then be read from programs like Arduino.

Bad news is that javascript does not and will probably never support named pipes. So we write a bash script to read data from named pipe. Now using a command line websocket we publish the data being received by this shell script.

Now we install websocket and ws ( a client) with npm to enable Node.js to work with websockets. Using websocket client we listen to our deamon server.

Android Mobile–> Serial Port–> Python Background Script–> Named Pipe—> Bash Script–> Websocket–>Javascript.

Don’t get afraid. Steps aren’t too complicated. It works like a charm.

Android Ultimate Plugin tutorial part 4 – Bluetooth

via Android Ultimate Plugin tutorial part 4 – Bluetooth | Gigadrill Games.

How to use Bluetooth communication on our plugin and here’s the answer.