loading
Picture of Web-controlled Twittering Roomba
I wanted to see if I could operate my Roomba remotely and get it to report its status via Twitter while I was away from home. I also wanted to make the device independent of a computer. This is the solution I came up with and it works very well.

Follow @TheRoomba on Twitter to see what mine is doing!

Step 1: Needed Parts and Tools

Picture of Needed Parts and Tools
DSC_7118.JPG
Parts:
  • 1x - Small signal, low power PNP transistor (I used a 2N2907A (may also be known as NTE159))
  • 1x - 8-Pin mini DIN male connector
  • 1x - 7805 5V voltage regulator
  • 1x - Solderless breadboard
  • 1x - Arduino board
  • 1x - Sparkfun WiFly Arduino shield
  • Row of five or more male pin headers
  • A short piece of Cat5 cable or similar wire (Cat5 is 24 AWG)
  • And last but certainly not least, a Roomba*

Tools:
  • Soldering iron
  • Small scissors
  • Third hand
  • Hot glue gun
  • Multimeter

Assumptions:
  • For the purpose of this Instructable, I am going to be assuming that you have a basic knowledge of basic electronics,  the Arduino and the Arduino's programming language.

*I have only tested this with the 500 Series. However, it should work with newer models, but I am not sure about older models.

 
pi-nerd11 days ago

If you don't have a 8-pin mini DIN connector laying around, you can also use a ps2 connector of the old computer-mouses,

only remove the black pin in the middle

atlantica4 years ago
Why not strap a camera to it and remotely check out whats goin on at home?
No burglar would suspect that. A dog\s eye view... haha
matchlighter (author)  atlantica4 years ago
I thought about it, but the Arduino does not have the necessary processing power to use the camera with the WiFly.
actually it does.u just need to add a pin cammera to it.
There is an Arduino Shield Compatible board with a Parallax Propeller chip that would have the processing power, while still being able to use the Arduino shields. Not quite as easy to program, though.

http://mghdesigns.com/index.php?main_page=product_info&products_id=1
matchlighter (author)  Alderin4 years ago
Hmmm... I will have to look into that. I have also heard that the FEZ Panda has the processing power?
elabz4 years ago
Trying to eliminate some confusion: the connector diagram above is for a Mini-DIN7, not Mini-DIN8 as noted on the previous page. They don't count the circular ground shroud as a pin, although it does indeed provide a useful additional connection, normally to the ground. That said, however, you can fit a Mini-DIN8 plug into a Mini-DIN7 socket (which is what Roomba has). In other words, if you're looking for a connector, you can expand your search and get yourself either Mini-DIN7 or Mini-DIN8 plugs, both would work, just be careful with the pinout.

Or, and a word of caution, perhaps: there is a whole bunch of non-standard 7, 8 and 9 pin plugs out there, usually from power supplies of all sorts, that look like Mini-DINs but aren't. 

matchlighter (author)  elabz4 years ago
It appears that you are right. I got confused because some of the mini DIN 7's have a different pin out. I was also going off of the fact that the cable for the Roomba from Sparkfun is an 8 pin. thanks for pointing that out.
You are a very patient, helpful person.

Very inspiring build as well. Love the iterative process you've worked through this instructable.
Gfer2 years ago
The device still does not work consistently:
1) It is not always a connection is established with the Roomba.
2) WEB interface displays the information is not correct.
3) Control in WEB interface does not work.

The scheme is valid because the data is still being received. Transfer rate the same is true.

Please help me!

Propose to introduce a management DDpin. It would be great to transfer data exchange interface for softserial, and USB Arduino output debug information.
matchlighter (author)  Gfer2 years ago
It sounds like the underlying problem has to do with the communication between the Arduino and the Roomba, that would certainly be causing all of the symptoms you have listed.

I doubt you would get much from serial debugging; it isn't a software problem as you consistently have access to the web interface. But you can try it. The SoftwareSerial is pretty compatible with the Serial library, if it is fast enough.

I know I have said this before, but please check your link cable thoroughly. You could also try making few jumpers out of lengths of Cat5 and make the links individually. This will eliminate a large portion of possible problems.
Cable and transistor I changed 3 times already.
Gfer2 years ago
The device works! The problem was most Arduino.
However, sometimes the fee freezes and green LED stops flashing and constant light.
Is it possible to learn the meaning of the flashing LEDs?
Are there any plans expansion WEB interface?
Gfer2 years ago
All my efforts are useless. Does not work.
I know that the data rate my Roomba 115200.
I know exactly what data is coming.
Web interface works but no data. I tried everythin
Gfer2 years ago
Good afternoon.
I still problemmy.
The program compiles without errors. Appears WEB interface where all the zeros, and nothing works.
It is also very much like the version for 400 series.
matchlighter (author)  Gfer2 years ago
It sounds like your interface cable is wired wrong. Double check it. Most likely, you have the TX and RX mixed up. Another possibility is that the PNP transistor on the Roomba-to-Arduino line may be wired incorrectly.
bratan2 years ago
Great instructable! I was actually looking for a way to control Roomba over internet, did you forget to add this part? :)
"To control the Roomba over the network, simply enter the IP address you assigned to the WiFly into you browser's address bar and voila!" There will be directional controls on the resulting webpage?
matchlighter (author)  bratan2 years ago
Thanks!
I never added manual control, just start, stop, and dock. I have recently considered returning to this project and adding a few features (like manual driving), but haven't yet.
Gfer2 years ago
Help!!!

In file included from Twittering_Roomba.cpp:1:
C:\arduino-0022\libraries\Twitter/Twitter.h:21:22: error: Ethernet.h: No such file or directory
C:\arduino-0022\libraries\Twitter/Twitter.h:23:25: error: EthernetDNS.h: No such file or directory
In file included from Twittering_Roomba.cpp:1:
C:\arduino-0022\libraries\Twitter/Twitter.h:33: error: 'Client' does not name a type
matchlighter (author)  Gfer2 years ago
Ok. I have updated the code and packaged a modified version of the Twitter library. Thanks for your patience and your interest in my project :)
matchlighter (author)  Gfer2 years ago
It looks like the Twitter library has been updated for 1.0 (It appears you have the 1.0 version of the library). You can try finding an older version, or I'll be releasing an update of my code in a couple of days, now that I actually have an opportunity. Sorry I haven't been able to offer a lot of support on this over the last little while.
Gfer2 years ago
after replacing the library:
In file included from Twittering_Roomba.pde:1:
C:\arduino-1.0.4\libraries\Twitter/Twitter.h:35: error: 'EthernetClient' does not name a type
Gfer2 years ago
There are problems when compiling:
IDE 1.0.4

In file included from Twittering_Roomba.pde:1:
C:\arduino-1.0.4\libraries\Twitter/Twitter.h:35: error: 'EthernetClient' does not name a type
In file included from C:\arduino-1.0.4\libraries\WiFly/WiFly.h:4,
from Twittering_Roomba.pde:4:
C:\arduino-1.0.4\libraries\WiFly/SpiUart.h:62: error: conflicting return type specified for 'virtual void SpiUartDevice::write(byte)'
C:\arduino-1.0.4\hardware\arduino\cores\arduino/Print.h:48: error: overriding 'virtual size_t Print::write(uint8_t)'
In file included from C:\arduino-1.0.4\libraries\WiFly/WiFly.h:8,
from Twittering_Roomba.pde:4:
C:\arduino-1.0.4\libraries\WiFly/Client.h:21: error: conflicting return type specified for 'virtual void Client::write(byte)'
C:\arduino-1.0.4\hardware\arduino\cores\arduino/Print.h:48: error: overriding 'virtual size_t Print::write(uint8_t)'
C:\arduino-1.0.4\libraries\WiFly/Client.h:23: error: conflicting return type specified for 'virtual void Client::write(const uint8_t*, size_t)'
C:\arduino-1.0.4\hardware\arduino\cores\arduino/Print.h:53: error: overriding 'virtual size_t Print::write(const uint8_t*, size_t)'
In file included from Twittering_Roomba.pde:1:
C:\arduino-1.0.4\libraries\Twitter/Twitter.h:35: error: 'EthernetClient' does not name a type
In file included from C:\arduino-1.0.4\libraries\WiFly/WiFly.h:4,
from Twittering_Roomba.pde:4:
C:\arduino-1.0.4\libraries\WiFly/SpiUart.h:62: error: conflicting return type specified for 'virtual void SpiUartDevice::write(byte)'
C:\arduino-1.0.4\hardware\arduino\cores\arduino/Print.h:48: error: overriding 'virtual size_t Print::write(uint8_t)'
In file included from C:\arduino-1.0.4\libraries\WiFly/WiFly.h:8,
from Twittering_Roomba.pde:4:
C:\arduino-1.0.4\libraries\WiFly/Client.h:21: error: conflicting return type specified for 'virtual void Client::write(byte)'
C:\arduino-1.0.4\hardware\arduino\cores\arduino/Print.h:48: error: overriding 'virtual size_t Print::write(uint8_t)'
C:\arduino-1.0.4\libraries\WiFly/Client.h:23: error: conflicting return type specified for 'virtual void Client::write(const uint8_t*, size_t)'
C:\arduino-1.0.4\hardware\arduino\cores\arduino/Print.h:53: error: overriding 'virtual size_t Print::write(const uint8_t*, size_t)'
matchlighter (author)  Gfer2 years ago
Ah yes. Arduino 1.0 changed a few things. I can't remember if my code needed changing itself, so do you have the 1.0 version of the WiFly library? https://github.com/jmr13031/WiFly-Shield
When I ran in to this problem, I think the only needed fix was updating the library, but if you still have problems, I'll take a look at my code.
huitlacoche2 years ago
Just curious.
I made this cable but haven't tested it yet. Is the pin out supposed to be for the male end (cable) or the female end (roomba serial port)?
matchlighter (author)  huitlacoche2 years ago
The illustration in the bottom right of Img.6 is the female port on the Roomba. The main picture is of the back-side (with the solder cups) of the male connector (so from the viewpoint, it is the same as the bottom-right drawing, but rotated 180 degrees).

I hope this was helpful.
matchlighter (author)  matchlighter2 years ago
I just added a couple of notes to the image to add (hopefully) a little more clarification.
Robotman_23 years ago
A twittering robot is awesome! haha. A great introduction to interfacing with the roomba can be seen here:

http://www.robotappstore.com/Knowledge-Base/3-Serial-Port-Baud-Rate-Configuration/17.html

what's nice with the roomba - is that you can program via any type of language you want - as long as your program ultimately sends the proper serial commands down to the roomba.

Cool project - :)
That's a great work!

Why not doing that with code? (like .Net, or Java...)
It seems much easier when you are connected to a computer.

(check out this Roomba Programming guide for .Net for more details)
robotmaker3 years ago
very nice job
ballin1473 years ago
this is a good invention very good invention actually and you should get it to say im bout to explode when its filled up
The fact that it tweets is hilarious. "I'm all done with the living room!" lol
Kasm2794 years ago
It sure is being picked up a lot :P
matchlighter (author)  Kasm2794 years ago
I like making it mad ;)