天天看點

運作loam_velodyne時的步驟和存在的問題

ROS jizhang的工程 git laboshinl的工程 

環境是ubuntu 14.04 

ROS 版本 indigo

工程位址:

https://github.com/laboshinl/loam_velodyne.git

terminal 1:

$ cd ~/catkin_ws/src/

$ git clone https://github.com/laboshinl/loam_velodyne.git

$ cd ~/catkin_ws

$ catkin_make -DCMAKE_BUILD_TYPE=Release

$ source ~/catkin_ws/devel/setup.bash

roslaunch loam_velodyne loam_velodyne.launch           

terminal 2:

$ cd ~/catkin_ws/src/

$ source ~/catkin_ws/devel/setup.bash

$ roslaunch velodyne_pointcloud VLP16_points.launch pcap:="/home/laboshinl/Downloads/velodyne.pcap"

 bag 沒有嘗試 ,貌似虛拟機不能連接配接到雷達上儲存資料.

 等我更新我的ubuntu系統後再嘗試一下吧

遇到的問題有兩個:

1.ROS中執行前需運作$source ~/catkin_ws/devel/setup.bash.

[xxx] is neither a launch file in package [xxx] nor is [xxx] a launch file name           

2.工程執行前需要對velodyne_driver單獨進行編譯,以確定 velodyne_point 下的VLP16_points.launch方法找到執行位置

編譯velodyne的方法參照:http://wiki.ros.org/velodyne_driver

成功時,在

  roslaunch velodyne_pointcloud 時Tab會出現需要的方法,否則也會出現1中的錯誤

然後執行讀取pcap檔案.

編譯不成功時,會出現 :

運作雷達的錯誤檔案也會出現相同的問題.

論壇上了解說 改變const int N_SCANS = 32;可以解決

但嘗試後沒有效果

當VLP16時,N_SCANS是16 和32 都可以正常跑.