Hacking Roomba

Build A Roomba Bluetooth Adapter

[originally published 15 Feb 2006 in Makezine blog and edited by Phil Torrone

roomba-bluetooth-1-400.jpg

If you liked the serial port cable/board Roomba how to, you’ll really like this one - controlling a Roomba via Bluetooth! Roomba’s have a serial port that let you entirely control them. Adding a Bluetooth serial adapter to wirelessly control the Roomba isn’t that hard to do. It looks just like a serial port to the OS, so the software from the previous how to works with it too.

roomba-bluetooth-2-400.jpg

This was the first version I built, trying to make it as small as possible. While the x & y dimensions are a little smaller, the z dimension is about twice as tall. Since this is a nicer prototyping board with plated holes, it feels a lot sturdier than the second version using the cheap Radio Shack board.

Parts needed

roomba-bluetooth-3-400.jpg
See Flickr photo with notes.

Circuit diagram

roomba-bluetooth-4-400.jpg
Larger version here.

roomba-bluetooth-5-400.jpg

If the BlueSMiRF could take the +16VDC the Roomba puts out, the voltage regulator circuit below wouldn’t be needed and we’d save a lot of space.

roomba-bluetooth-6-400.jpg
roomba-bluetooth-7-400.jpg

These Radio Shack prototyping boards are cheap ($1.79) which is nice, but since the holes aren’t plated thru with metal, getting solder to stick well is sometimes problematic. However, this does mean that if you mess up, it’s easy to remove parts.

roomba-bluetooth-8-400.jpg

After testing continuity and voltage tests on all the pins going to the Roomba and the BlueSMiRF, I plugged in the BlueSMiRF and tried talking to it with the computer. When that succeeded, I plugged it into the Roomba and tried talking to the Roomba. Success!

roomba-bluetooth-9-400.jpg

Every gadget deserves a little enclosure. Since this was Bluetooth, I figured a blue floss container was appropriate.

25 Comments so far

  1. Zack November 28th, 2006 10:22 pm

    So, when does the application for my bluetooth phone come out?

    Nice hack.

  2. todbot November 28th, 2006 11:38 pm

    Hi Zack,

    If you’re phone is a recent J2ME phone, then there already is an application for you.

  3. Cody December 17th, 2006 11:02 pm

    I’m curious. I understand you went with the BlueSmirf for its open-ended connection pins, but at $60 per card, why did you not try bodging a $10 usb bluetooth into the usb dongle circuit and make a very cheap bluetooth adapter with a professionally milled case?

  4. todbot December 17th, 2006 11:39 pm

    Hi Cody,
    If I could’ve used a $10 part instead of a $60 one I would’ve. Unfortunately, the economies of scale haven’t yet reached Bluetooth-to-serial adapters like they have Bluetooth-to-USB adapters, so they’re more expensive.

    Also, I’m pretty sure that the $10 adapters rely on the computer to implement part of the Bluetooth protocol. The Roomba can’t do that so we need a part that fully implements Bluetooth. Even if it didn’t, USB is a very complex protocol compared to RS-232 (what the Roomba protocol essentially is). To act like a USB “host” to drive the $10 part requires a fairly powerful embedded computer system that runs a real OS like Linux.

  5. Cody December 18th, 2006 9:17 am

    Ah, that makes sense. The usb bluetooth adapaters aren’t much more than antennae and rely on the PC to do the translation (via drivers). I wasn’t familiar with how the Roomba’s serial port worked, but I should’ve realized a personal vacuum cleaner won’t have the processing power or the OS platform to handle the bluetooth protocol on its own. I just wish those BlueSmirfs weren’t $60 so I could convince my wife that our Roomba needed bluetooth. ;)

  6. Paul February 16th, 2007 8:42 am

    I bought one of these Bluetooth adapters (see link below) for use with my Roomba and it works great. Load the software, plug it in and and your connected. The best part is it only cost $9.95 with free shipping. I’m sure you can get that price by your wife. It’s a great little adapter. Good luck!

    http://www.emtcompany.com/products/btusb.htm

  7. Steve February 27th, 2007 3:11 pm

    What about using an IOGear bluetooth to serial like this one? Does RS-232 have power?

    http://www.provantage.com/iogear-gbs301~7IOGB009.htm

    I’m not affiliated with that site, I don’t know if it would work. I froogled it.

  8. todbot February 27th, 2007 3:19 pm

    Hi Steve,
    Yup, that would work. I have one of those. You have to take it apart to intercept the signals between the Bluetooth chip and the RS-232 transceiver. RS-232 voltage levels are approx +/- 10V while the Roomba expects 0-5V TTL signals.

  9. Ben March 20th, 2007 7:52 pm

    Hey,

    what is the software you are using to connect the pc to the roomba … the pc’s bluetooth to the roomba’s bluetooth.

    Thanks, Ben!

  10. todbot March 20th, 2007 8:55 pm

    Hi Ben,
    The Roomba Bluetooth adapter appears as a normal serial port to the PC. So any software that can speak to a serial port can speak to the Roomba over Bluetooth. For the book, I wrote several different programs in Java, C, and Perl. You can see them in the code section.

  11. Ben March 23rd, 2007 11:09 am

    Thanks!

    I just got your book (enjoying it very much so far) and have setup a little roomba hacking center in my apartment.

    I’ll be sure to post some images of my hacks once they are done.

    Thanks again!

    - Ben

  12. Pyrofer March 26th, 2007 8:40 am

    From around 16v to 5v is quite a drop for the vreg, doesnt it get hot? How much power does the bluetooth adaptor use when transmitting at max power?

  13. todbot March 26th, 2007 9:39 am

    Hi Pyrofer,
    Nope, it doesn’t get hot. The Bluetooth module draws very little current, under 100mA, which is why a tiny 78L05 can be used instead of bulky normal 7805.

  14. Pyrofer March 26th, 2007 11:39 am

    Thanks, I hooked up my BT module (same one!) with a 7805 (old large plastic case not 78L05) and after about a minute its quite hot.
    There is about 15v on the input. For now im going to stick a heatsink on it, but im worried about it going pop, and maybe pushing >5v out the output pin cooking the BT module.

  15. todbot March 26th, 2007 11:46 am

    Pyrofer, if you’re drawing enough current to make a 7805 hot, something is seriously wrong! Disconnect the BT module from your circuit, power your circuit from a power supply (not the Roomba), and see if the 7805 still gets hot. I bet you have a short circuit in there somewhere.

  16. Chinedu May 31st, 2007 8:20 am

    ur contraption is quite cool, but could u please help me with a project titled “micro-controller based home appliance control system using bluetooth.thnx

  17. Carlos June 5th, 2007 8:03 pm

    Hi Paul:

    You mean you bought the adapter for the PC? What do you connect to the Roomba in your setup? I seems to me that Tod is right, you can’t just connect a USB BT dongle to a a rooStick or even Tod’s original serial adapter, not on the Roomba side.

  18. Doug January 1st, 2008 8:43 pm

    We just successfully built this interface, and noticed some differences from what is documented in the book.
    I believe there may be 2 different versions of the BlueSMiRF product. Ours came up with a Bluetooth device name beginning with “FireFly” (instead of “BlueRadio” or “BlueSMirf”). It had a different passkey (”1234″ instead of “default”). The commands to configure the baud rate were not the AT commands either, see http://www.sparkfun.com/datasheets/RF/RN_BlueportII-ref-guide.pdf
    The BlueSMiRF product we used was http://www.sparkfun.com/commerce/product_info.php?products_id=582

  19. John Graves February 11th, 2008 3:32 pm

    I’ve built the interface and have paired to FireFly using pin 1234.
    Now I need to find an comm interface program for Vista Ultimate 64 bit, any ideas?

  20. Scott February 21st, 2008 9:31 am

    Tod,

    This is a left field question, but do you have any idea if the RooTooth from RoboDynamics follows the same schematic as your project?

    It just dawned on me that I might be able to use the RooTooth on an Arduino board if I created a female ROI adapter and used your schematic to identify each pin.

  21. todbot February 21st, 2008 11:24 am

    Hi Scott,
    The original RooTooth had an extremely similar schematic. I think about the only change was that it had in-line resistors on the TX/RX lines as a short-circuit protection measure.

    The newly redisgned RooTooth by Sparkfun uses a new Blutooth module and has a different schematic, but I bet it works just as good or better.

  22. taousser March 11th, 2008 7:43 am

    Mr hi
    I am a student in electronics, I prepare my graduation project study design and implementation of an electrocardiogram through the soundcard why I think a transmetre ECG signal by a bluetooth end of the bluetooth also receive and ‘injected by the end of a sound card to be treated at micro computer
    For this I need help in the emission and reception of bluetooth.
    While awaiting a response from you accept Mr saltutations my respectful.

  23. TSH May 29th, 2008 2:01 am

    Hi todbot,

    Now I have some problems with my RooTooth. I’ve changed the baud rate of its Firefly bluetooth devices to 57600(my Roomba is a Roomba Scheduler), and I’ve set roobacomm.waitForDSR to true in RoombaView’s code, but it still doesn’t work. If I press the power button of my Roomba during RoombaView is running, it seems like it have received some data but just not the format, and the on-screen virtual roomba may walk around everywhere. I wonder is there still anything I have to changed?

    Thank you.

  24. Cheng June 1st, 2008 9:21 pm

    if you are connecting a 500 serie roomba using Firefly, this is what you need to do to set the baut rate:

    1) download this terminal first (made by the firefly company):
    http://www.rovingnetworks.com/support/teraterm.zip

    2)set up your bluetooth then use the aforementioned terminal program to connect to COM 4 (or whatever your SPP port is)

    3)enter $$$, then you will see CMD

    4)enter “U,115k,N” (without quotation mark)

    5)disconnect the terminal program and now connect to roomba using your program

    Note: you have to complete the sequence above before you connect to roomba every time.

    According to the 500 series ROI:
    http://www.irobot.com/filelibrary/iRobot_Roomba_500_Open_Interface_Spec.pdf

    If you are connecting to a 500 serie roomba, you need to set the baud rate to 115200, not 57600.

    I found this solution here:
    http://www.roombareview.com/chat/viewtopic.php?t=8472&postdays=0&postorder=asc&start=20

  25. TSH June 2nd, 2008 12:15 am

    Thx, Cheng. But my Roomba Scheduler is older than 500 series and the baud rate should be 57600.

Leave a reply