This is an attempt to fix and improve the driver provided by LDRobots in their website
cd <your_ws>
git clone -b ros2 https://github.com/linoroot/ldlidar src/ldlidar
rosdep update && rosdep install --from-path src --ignore-src -y
colcon build
source install/setup.bash
ros2 launch ldlidar ldlidar.launch.py
Optional Parameters:
serial_port
used to override the autodetect and select a specific port.lidar_frame
used to override the defaultlaser
frame_id.topic_name
used to override the defaultscan
topic name.
For example:
ros2 launch ldlidar ldlidar.launch.py serial_port:=/dev/ttyUSB0
---- Original readme ----
使用catkin编译,执行如下操作
catkin_make
source devel/setup.bash
roslaunch ldlidar LD06.launch
or
rosrun ldlidar ldlidar
rviz的配置在rviz文件夹下面。
代码在ubuntun16.04 kinetic版本下测试,使用rviz可视化。