PDA

View Full Version : [Question(s)] Roomba 5xx sensor reading problems



Resilient
02-11-2009, 11:30 PM
Does anyone here have any experience reading sensor data from the 500 series Roombas? I can send it commands just fine, and I am reasonably sure I am sending the correct commands for it to return sensor data, but I am getting nothing back.

If I connect the TX and RX pins I can talk to myself just dandy, so I am pretty sure the hardware is working.

I would expect if I were to send '142' then '100' it should return all the sensor packets, but I get nothing when I try to read.

Thanks!

Quantum
02-12-2009, 12:30 AM
Got some more info on the sensor?

Resilient
02-12-2009, 12:33 AM
Here is a link to the open interface specifications:

http://www.robotikasklubs.lv/read_write/file/Piemers/iRobot_Roomba_500_Open_Interface_Spec.pdf

Its less a sensor issue, and more an issue that I don't understand how to work this command.

The command in question is 142 on page 17.

Quantum
02-12-2009, 12:54 AM
Are your you giving it the 15ms it requires to update

Resilient
02-12-2009, 01:15 AM
Yeah,
it takes muti-byte commands like direct drive just fine, I built in the 15ms delay to the write function. And I can send it, for example, 134 in Realterm and it will begin the spot clean sequence. So it would seem, if I send 142 then send 100, I should get a whole bunch of stuff spit back into the terminal, but I get nothing.

Yet, if I connect the tx and rx pins on the serial adaptor that plugs into the roomba and give it power i get my commands sent back to the terminal, so my cable seems to be working. I am beginning to wonder if the roombas tx pin is just F'ed...

If anyone has any code that they know works for reading sensor data from a 500 seriese roomba, that would be awesome... but that seems pretty hard to come by. :o

Connor
02-12-2009, 09:23 PM
Yeah,
it takes muti-byte commands like direct drive just fine, I built in the 15ms delay to the write function. And I can send it, for example, 134 in Realterm and it will begin the spot clean sequence. So it would seem, if I send 142 then send 100, I should get a whole bunch of stuff spit back into the terminal, but I get nothing.

Yet, if I connect the tx and rx pins on the serial adaptor that plugs into the roomba and give it power i get my commands sent back to the terminal, so my cable seems to be working. I am beginning to wonder if the roombas tx pin is just F'ed...

If anyone has any code that they know works for reading sensor data from a 500 seriese roomba, that would be awesome... but that seems pretty hard to come by. :o

Are you using a RooStick or MAX232 or some sort of TTL Shifter on it? Roomba's don't talk straight serial.

Thanks, Connor

Adrenalynn
02-12-2009, 10:10 PM
I wouldn't expect he'd get good RX data if the levels weren't matched. But it's worth noting - that 10v into a TTL would be an ugly draw.

Resilient
02-13-2009, 12:16 PM
I have been posting this on a Roomba specific board as well and I got it solved.

I am using a MAX232 chip. The issue was that my the 5 pin on my serial cable was not hooked up to the common ground.

So now I have a fully functional Roomba :P

Thanks for the help!

metaform3d
02-13-2009, 08:39 PM
If there's one thing I've learned doing this crazy hobby it's: when in doubt, check your grounding! Even the professionals apparently get tripped up by faulty grounding.

Connor
02-13-2009, 09:56 PM
I have been posting this on a Roomba specific board as well and I got it solved.

I am using a MAX232 chip. The issue was that my the 5 pin on my serial cable was not hooked up to the common ground.

So now I have a fully functional Roomba :P

Thanks for the help!

That was the next thing I was going to suggest, had the same thing happen on my MAX232 and the RooStick (Had to make the Cable, didn't tie in a ground)

Thanks, Connor