Robotics StackExchange | Archived questions

add velodyne_pointcloud as a dependancy to a package

Hello,

I'm new at ROS, Im working on a LiDAR project, I downloaded a project of a segmentation algorithme for 3D point clouds. The first question is I don't know in which repository I should paste the folder project. Second question: I see on the CMAKELISTS file that the node has velodyne_pointcloud as dependency. How can I add it ?

Thanks everyone

Asked by hachbani on 2019-05-17 09:39:00 UTC

Comments

Answers

I am kind of newbie, but

I suggest you download two main packages into your $ROSworkspace/src (i.e. ~/catkin_ws/src)

1. (velodyne_pointcloud) velodyne package from (https://github.com/ros-drivers/velodyne)

2. your project

then cakin_make will automatically detect two packages by chaining CMakeLists.txt.

Asked by Y.Frank on 2019-05-21 00:39:16 UTC

Comments

Create a catkin workspace and in the src directory under it clone the project and the velodyne_pointcloud package. Since the project and driver packages depend on pcl and velodyne packages you will need to install them. You can see exactly on which packages the project depend in their package.xml files. These packages you can install using the sudo apt install command:

sudo apt install ros-kinetic-pcl-ros
sudo apt install ros-kinetic-pcl-conversions
sudo apt install ros-kinetic-velodyne-driver
sudo apt install ros-kinetic-velodyne-driver
sudo apt install ros-kinetic-velodyne-msgs

ass well as other packages listed in the package.xml.

Asked by pavel92 on 2019-05-21 01:41:46 UTC

Comments

This is an OK answer, but please don't use apt to install dependencies manually. There are tools for this and they should be used.

Refer to the part about rosdep update and rosdep install in #q252478.

Being able to automate dependency resolution and management is one of the major rationales behind having a package.xml.

Asked by gvdhoorn on 2019-05-21 02:53:28 UTC

Yeah I agree. I just wanted to point out the major dependencies when dealing with point-clouds. As you suggested, the proper way would be to utilize rosdep to automatically install the dependencies:

rosdep install --from-paths path_to_ws/src --rosdistro=kinetic -i -y -r

Asked by pavel92 on 2019-05-21 03:11:36 UTC