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

rosrun rosserial_python serial_node.py _port:=/dev/ttyACM0 on RasPi giving "could not open port /dev/ttyUSB0" error

asked 2014-09-21 05:54:45 -0500

Nightstalker gravatar image

updated 2014-09-22 03:57:30 -0500

I have installed rosserial_arduino on my RasPi and my Arduino code for Push Button has been uploaded successfully. To run the code, I am following the following steps as mentioned in the tutorial:
1. Startup roscore using roscore
2. Run the run the rosserial_python serial_node.py using rosrun rosserial_python serial_node.py _port:=/dev/ttyUSB0
3. Watch button status on rostopic echo pushed

Now, the issue here is that when I try step 2 using rosrun rosserial_python serial_node.py _port:=/dev/ttyACM0 (my Arduino is on ACM0), the error message I receive is

[ERROR] [WallTime: 1411295710.119812] Error opening serial: could not open port /dev/ttyUSB0: [Errno 2] No such file or directory: '/dev/ttyUSB0'

For some reason, it keeps taking USB0 as the input even if I specify ACM0 as the port. This error does not occur on my Ubuntu 14.04 distro running _Indigo_. My RasPi is running _Groovy_. I have also added the necessary group permissions (adding user to dialout, etc.) but to no avail. Please suggest methods to solve this issue.


Thanks to ahendrix for having found out the problem. But there is a follow up issue here. Please check.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
2

answered 2014-09-22 01:13:02 -0500

ahendrix gravatar image

I think in the Groovy version, the serial port was passed directly as an argument, rather than as a ROS parameter. Try:

rosrun rosserial_python serial_node.py /dev/ttyACM0
edit flag offensive delete link more

Comments

You deserve a cookie. That worked. But it gives an error of Failed Packet Flags. Any thoughts?

Nightstalker gravatar image Nightstalker  ( 2014-09-22 02:14:48 -0500 )edit

I think the rosserial message format changed at some point. You should check that you're running a groovy version of the rosserial arduino library and the arduino sketch.

ahendrix gravatar image ahendrix  ( 2014-09-22 03:08:43 -0500 )edit

Yeah, I checked that. It's all groovy.

Nightstalker gravatar image Nightstalker  ( 2014-09-22 03:11:30 -0500 )edit

@ahendrix, please check this

Nightstalker gravatar image Nightstalker  ( 2014-09-22 03:56:07 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2014-09-21 05:54:45 -0500

Seen: 8,250 times

Last updated: Sep 22 '14