Arduino to Roomba – but how?

Posted On December 24, 2008

Filed under tech

Comments Dropped leave a response

I’m a huge fan of my new Arduino and I love my Roomba. So when I decided to strip my Roomba for parts, I got excited to find out I could just connect my Arduino right into the Roomba “serial” port and gain full control over the device. So I put my Roomba back together and began on a new journey…

First steps in Roomba serial

Starting at the website for Hacking Roomba got me just to the point of confusion. Seems I needed a little background help before I dove in (and I’m not about to buy the book, for I have the internet at my disposal). First step is building the cable to connect to the Roomba. It is a 7-pin or 8-pin mini din. But what pin connects to what on the Arduino? Good question, and it took some experimenting to solve. Here is a map of the pins as seen on the connector (male side)
Schematic with mini-din pin out Larger image

So after some testing, pins 1 and 2 are voltage and plug into the Vin on the Arduino. Either one, doesn’t seem to matter which (maybe both?) but I got one working. The other half is that pins 7 and 8 (on the 8-pin plug which I used) are ground. Again, only one seems to be necessary and that plugs into one of the GND plugs on the Arduino.

Now the fun stuff? A little in Serial: TX and RX stand for Transfer and Receive. The TX on the Arduino is SENDING information so that needs to be the RX on the Roomba or pin 3. RX on the Arduino is receiving and goes to pin 5. And the DD (I don’t know what that means) goes to pin 6.

I did manage to get my Roomba rolling with this new found knowledge. Beware, it will not stop unless picked up. However, I could not get any sensor data from the Roomba into the Arduino. I see this problem has happened to others. Something to do with the refresh on the sensor update function. More experimenting will be required but may be out of my league.

Next steps

My next step will be to attempt to add my own sensor and control the Roomba with that. I think I’ll add a light sensor and maybe hack into some of the Roomba sensors directly if possible.

After the fact

I recently found this link a manual for the roomba serial spec. Looks very promising. Also, setting the delay to 64 seems to give better results on the Roomba sensor. Still not 100% though.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s