I want to automate the bot but I don’t want to strap a raspberry pi to it. Is there a nodejs library for interacting with this thing over bluetooth. All the ones I can find are deprecated or otherwise kind of garbage.
Hi @crazytechkid, welcome to our forums.
Which robot are you using?
we have both a bolt and a rvr. I’d rather use the bolt for this project, but I feel that ill only be able to use the rvr
For Bolt and RVR, we have the Sphero EDU app available on Windows and Mac. Although that’s not what you asked for, I wanted to mention it.
3rd party Android BLE support, could be used as a reference
We don’t have an officially supported library for controlling either of these over BLE. Forum user @btelman96 created an Android app that drives RVR via BLE, among other things, so you could take a look at that for connection details.
Raspberry Pi Python SDK - probably the best option
For RVR automation, the Raspberry Pi Python SDK is our most full-featured SDK, and the one that will likely see the most continuing support going forward as it’s been popular with the community. Someone posted a thread about using some kind of wireless UART bridge (maybe Bluetooth or XBee) to run the RVR from a stationary Pi. The Raspberry Pi SDK also doesn’t have a hard requirement to run on a Pi - that’s just the most common platform. By default, it assumes the RVR UART port is connected to /dev/ttys0, but you can specify your serial port for other platforms when you call the constructor for
SerialAsyncDal. It looks like the Observer side of the SDK can also be targeted to a different serial port, but it takes a little manual editing of the SDK source. In principle, you could run the SDK on any Windows/Mac/Linux computer, as long as you provide a connection to the RVR that looks like a serial port to the SDK. I just haven’t tried it to know if there any pitfalls.
RVR command documentation
RVR command documentation doesn’t cover the entire feature set of the firmware, but updates are currently in progress (I’m working on Python SDK improvements and updates to the SDK site). In the meantime, you can work out the full command set from the Raspberry Pi Python SDK source if you’re creating your own library.
Existing Nodejs libraries (not recommended)
There are some Nodejs libraries that were written by Sphero, but they may take some work to get running. Unfortunately, the developers who created them are no longer with Sphero, but if you really want to take that approach you can give it a shot. They require the use of a Raspberry Pi: server and client. A few users on here have taken an interest in Node, and you can search around the forum for debugging tips.
Hopefully this is enough to get you going. Check out sdk.sphero.com for all of our current documentation.