ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
2

Can't access turtlebot through ttyUSB0

asked 2011-09-12 07:33:31 -0500

lucascoelho gravatar image

updated 2014-01-28 17:10:22 -0500

ngrennan gravatar image

Hi,

I think that ROS can't access my Create... Is not possible see informations about the robot in turtlebot_dashboard, like battery and sensors status, but is possible to see netbook battery status, then I can conclude that the connection Workstation-netbook is ok, the problem could be between the netbook and Create. The status of all sensors in turtlebot_dashboard is Stale, except the netbook battery.

I'm using a serial-usb converter, because my Create uses a serial-serial cable. Could it be the problem?

Using "dmesg" and "lsusb" commands, I can see that my converter is properly connected at ttyUSB0. And I've tried to change the default_port in turtlebot_node.py to another USB and serial ports, but the error continues.

Thanks in advance, Lucas

edit retag flag offensive close merge delete

4 Answers

Sort by ยป oldest newest most voted
7

answered 2011-09-12 08:53:12 -0500

dvbot gravatar image

I think I had the same problem with the ATHEN USB serial cable. Here is how I solved it:

Add the following line in the /etc/udev/rules.d/52-turtlebot.rules:

ATTRS{idProduct}=="2008",ATTRS{idVendor}=="0557",MODE="666",GROUP="turtlebot"

2008 and 0557 is either the vendor or product id. You can find that out from lsusb. The problem is that the ttyUSB0 does not have the approprite permission.

edit flag offensive delete link more

Comments

Thanks a lot!!!! Now everything is ok on my turtlebot!
lucascoelho gravatar image lucascoelho  ( 2011-09-13 08:20:05 -0500 )edit
I am having the same darn problem that I had on the other one. I can pull up the file and make changes, but I cannot save the new file.
MovieMaker gravatar image MovieMaker  ( 2011-11-23 14:45:19 -0500 )edit
Have you tried to edit the file as a superuser (root)?
lucascoelho gravatar image lucascoelho  ( 2011-11-25 00:59:03 -0500 )edit

I had a similar problem. I followed the instructions here, and got my turtlebot working for a day. I shutdown everything at the weekend. On monday, I was back to zero. I am getting "Failed to open port /dev/ttyUSB0" What can cause this?

Ozkan gravatar image Ozkan  ( 2012-05-02 04:27:06 -0500 )edit

Hi is GROUP="xxx" referring to the login account?

Sentinal_Bias gravatar image Sentinal_Bias  ( 2013-06-04 22:28:19 -0500 )edit

Bus 003 Device 005: ID 0403:6001 Future Technology Devices International, Ltd FT232 USB-Serial (UART) IC What shall be my required code ? and could u tell me the parameters for GROUP and MODE ?

vikiboy gravatar image vikiboy  ( 2014-06-30 07:08:57 -0500 )edit
2

answered 2012-03-06 15:35:40 -0500

trroy gravatar image

I had a similar problem, and I'd like to add something to dvbot's extremely helpful response. I couldn't communicate to the my turtlebot netbook, and my Turtlebot Dashboard was all gray. Under Diagnostic, I had the error: TurtleBot Node: Failed to open port /dev/ttyUSB0. Please make sure the Create cable is plugged into the computer.

When trying to implement dvbot's recommendation, I realized my turtlebot netbook didn't have the file /etc/udev/rules.d/52-turtlebot.rules, and I did not have permission to create it. I went here, and found good instructions from tredegar (halfway down the page) in how to overcome the problem. For your convenience, I am recopying some of tredegar's recommendation. To become root issue the command:

sudo -i

Then to create the file you can use the command

gedit /etc/udev/rules.d/52-turtlebot.rules

or use your favorite editor. Once you populate the content with dvbot's code, restart udev:

/etc/init.d/udev  restart

I'm still very new to this, but I do know this worked for me: once I restarted udev, my Turtlebot Dashboard went from gray to greens and reds. Both my workstation and turtlebot netbook are running Ubuntu 11.10 and ros electric. Hope this is useful.

edit flag offensive delete link more
0

answered 2012-02-14 13:02:49 -0500

technothug gravatar image

updated 2012-02-14 13:30:59 -0500

If you are still having this problem, I resolved it by changing adding the turtlebot user to the 'dialout' group. That group owns /dev/ttyUSB0 so by being a member of that group you are added to the ownership. It doesn't affect any other permission at least so that U can detect at this point. I'll keep you posted, unless you already fixed it using another method. Just sharing the info as I find it.

edit flag offensive delete link more

Comments

1

how to do it?

SHPOWER gravatar image SHPOWER  ( 2012-09-18 06:34:29 -0500 )edit

how to add the turtlebot user to the 'dialout' group

howyda gravatar image howyda  ( 2013-03-10 03:45:07 -0500 )edit
0

answered 2013-07-10 08:53:32 -0500

newe1344 gravatar image

You could check the permissions of ttyUSB0

ls -la /dev/

If the perms are not 666 or a+rw then you need to boot with usb that has permission to access. Basically you need to create a new rule in /etc/udev/rules.d:

Create a new file with your specific permissions (higher numbers override existing rules):

cd /etc/udev/rules.d/
touch 80-turtlebot.rules
sudo pico 80-turtlebot.rules

Add the following lines for every usb device:

#serial usb
SUBSYSTEM=="usb", ATTRS{idProduct}=="6001", ATTRS{idVendor}=="0403", MODE="0666", GROUP="turtlebot"

To find the product id and vendor id, do lsusb -v, I think if you just do regular lsusb its vendor:product. Shift + PgUp to view previous parts of the cli.

finally reboot

sudo reboot

edit flag offensive delete link more

Comments

I have a similar issue with a Create2. I found /etc/udev/rules.d/99-com.rule What GROUP should be added to #serial usb line?

lotharchris gravatar image lotharchris  ( 2019-12-29 09:18:50 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2011-09-12 07:33:31 -0500

Seen: 6,221 times

Last updated: Jul 10 '13