User Manual

www.ydlidar.com Copyright 2015-2018 YDLIDAR Team
10 / 12
$ sudo apt-get install python-serial ros-kinetic-serial g++ vim \
ros-kinetic-turtlebot-rviz-launchers
2 If there is a problem with the installation, update the source cache and reinstall it.
$ sudo apt-get update
RVIZ Check the scan results
Run the launch file and open rviz to see the G4 scan results, as shown in the following figure:
$ roslaunch ydlidar g4_view.launch
FIG 12 YDLIDAR G4 RVIZ
Modify the scan angle problem
The scanning data seen by running the launch file is displayed by default with 360-degree data. If
you want to modify the display range, modify the configuration parameters in launch. The specific
operation is as follows:
1 Switch to the directory where g4.launch is located and use vim to edit g4.launch. The
contents are as follows:
$ roscd ydlidar/launch
$ vim g4.launch