Ask Your Question

U-Blox: Could not open serial port :/dev/ttyACM0

asked 2018-07-03 11:45:54 -0600

hecontreraso gravatar image

hello guys, I'm getting this error. Then the process dies. I'm not sure about what could be wrong. Any idea will be very appreciated

02.07.18 21:24:26 (+0000)  main  [ublox_gps-2] restarting process
02.07.18 21:24:26 (+0000)  main  process[ublox_gps-2]: started with pid [29965]
02.07.18 21:24:26 (+0000)  main  [ WARN] [1530566666.814132192]: Warning: PPP is enabled - this is an expert setting.
02.07.18 21:24:26 (+0000)  main  terminate called after throwing an instance of 'std::runtime_error'
02.07.18 21:24:26 (+0000)  main    what():  U-Blox: Could not open serial port :/dev/ttyACM0 open: No such file or directory
02.07.18 21:24:26 (+0000)  main  [ublox_gps-2] process has died [pid 29965, exit code -6, cmd /catkin_ws/devel/lib/ublox_gps/ublox_gps __name:=ublox_gps __log:=/root/.ros/log/a10fc4ca-7e39-11e8-817b-00044ba83bf2/ublox_gps-2.log].
edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2018-07-03 22:27:26 -0600

DrBot gravatar image

In linux first see if your port is being detected:

'lsusb' with the USB plugged in and out the list should be longer if it is plugged in. If you can't see it, then try another cable to see if that fixes the problem.

Next, try 'ls /dev/tty*' with the same plugged in and out technique. The port should show up as noted in the previous answer.

Once you have identified the port, you need to see if it is set correctly in ROS, this is usually in a param directory, but could be specified in a launch or 'node' directory.

Sometimes you need to set permissions to write to a USB port; you need to add your username to the dialout group.

One final issue is a failed USB device - minicom - D /dev/ttyACM0 would test if Linux can talk to that device. If minicom doesn't work, but sudo minicom does, you have the dialout problem.

There, that's my answer, now I am exhausted and need to go to bed! (just kidding)

edit flag offensive delete link more

answered 2018-07-03 20:48:36 -0600

billy gravatar image

You need to identify the name of the serial port the U-Blox is connected to and make sure the node is connecting to it. I suspect it is a parameter in the launch file but could be listed somewhere else. Of course this assumes it's plugged in an turned on : )

There are many ways to get a list of serial ports on your machine. Google ubuntu list serial ports

They won't all be called ttyACMx, could be called ttyUSBx or ttySx.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2018-07-03 11:45:54 -0600

Seen: 3,775 times

Last updated: Jul 03 '18