Copyright 2015-2020 YDLIDAR
8/11
ROS Driver Installation
Before doing the following, make sure that the Kinetic version ROS environment is installed
correctly.
1. Use the command to create the ydlidar_ws workspace and copy the ROS driver package
ydlidar_ros_driver in the YDLIDAR package to the ydlidar_ws/src directory. Switch to the
ydlidar_ws workspace and compile again.
2. After the compilation is complete, add the ydlidar_ws environment variable to the ~/.bashrc
file and make it effective.
3. Add a device alias /dev/ydlidar to the YDLIDAR serial port.
RVIZ installation
1. Online installation
2. If something went wrong, update the source cache and re-install it.
$ mkdir -p ~/ydlidar_ws/src
$ cd ~/ydlidar_ws
$ catkin_make
$ echo "source ~/ydlidar_ws/devel/setup.bash" >> ~/.bashrc
$ source ~/.bashrc
$ cd ~/ydlidar_ws/src/ydlidar_ros_driver/startup
$ sudo chmod +x initenv.sh
$ sudo sh initenv.sh
$
sudo
apt-get
install
python-serial
ros-kinetic-serial
g++
vim
\
ros-kinetic-turtlebot-rviz-launchers
$ sudo apt-get update