"Error, cannot bind to specified serial port /dev/ttyUSB0" with RPLidar A1 and Raspberry PI 3B

asked 2021-04-08 13:54:15 -0500

david_ttu gravatar image

updated 2021-04-26 09:10:23 -0500

miura gravatar image

Hello, a quick heads up, I started using ubuntu only a month ago, so I am still very new to this. I am currently having an issue with having my lidar scans show on my laptop with the RPLidar A1 running through the raspberry pi 3B. I am running Ubuntu 16.04 with ROS kinetic on a VM as the observer and Ubuntu mate on the pi as the master. I have all the appropriate packages for the rplidar installed on both machines. When running the lidar directly through the pi, everything works, but the issue is using the lidar while exporting causes the error.

I believe I have formatted the the export script correctly because whenever I run roslaunch rplidar_ros view_rplidar.launch on the VM, the lidar will pause momentarily then continue spinning, but then get the error.

I have had a similar issue before when connecting the lidar directly to my laptop running the VM, but was able to fix this when using sudo chmod 666 /dev/ttyUSB0. The issue now is that when trying to run it on the pi and have the scans show on rviz on my VM, I get the following error (sorry for no proper formatting).

"[Error] [1617847366.274329863]: Error, cannot bind to the specified serial port /dev/ttyUSB0. [rplidarNode-1] process has died [pid 2696, exit code 255, cmd /home/david/catkin_ws/devel/lib/rplidar_ros/rplidarNode __name:=rplidarNode __log:=/home/david/.ros/log/a3fffb6e-980d-11eb-8f4c-7752c26cb8ce/rplidarNode-1.log]. log file: /home/david/.ros/log/a3fffb6e-980d-11eb-8f4c-7752c26cb8ce/rplidarNode-1.log"

Trying to use the same fix I did before with sudo chmod 666 /dev/ttyUSB0 does not work and have not been able to figure out a solution, so any help would be greatly appreciated.

edit retag flag offensive close merge delete