< >
Home » ROS1轻松学第2季_视频版 » ROS1轻松学2-工具篇11-catkin_create_pkg演示讲义(含视频)

ROS1轻松学2-工具篇11-catkin_create_pkg演示讲义(含视频)

ROS1轻松学2-工具篇11-catkin_create_pkg演示讲义

说明:

  • 介绍catkin_create_pkg如何生成ros包

参考:

示例:

  • catkin_create_pkg帮助
catkin_create_pkg -h 
  • 效果如下:
usage: catkin_create_pkg [-h] [--meta]
                         [-s [SYS_DEPS [SYS_DEPS ...]]]
                         [-b [BOOST_COMPS [BOOST_COMPS ...]]]
                         [-V PKG_VERSION] [-D DESCRIPTION]
                         [-l LICENSE] [-a AUTHOR]
                         [-m MAINTAINER]
                         [--rosdistro ROSDISTRO]
                         name [dependencies [dependencies ...]]
  • 简单用法:
catkin_create_pkg <package_name> [depend1] [depend2] [depend3]
  • 创建工作空间
mkdir -p ~/catkin_ws/src
cd ~/catkin_ws/src
  • 创建只支持C++的ROS包
catkin_create_pkg beginner_tutorials_cpp std_msgs roscpp
  • 创建只支持Python的ROS包
catkin_create_pkg beginner_tutorials_py std_msgs rospy
  • 创建同时支持Python和C++的ROS包
catkin_create_pkg beginner_tutorials std_msgs rospy roscpp
  • 查看包依赖
rospack depends beginner_tutorials
  • 在线版本:

纠错,疑问,交流: 请进入讨论区点击加入Q群

获取最新文章: 扫一扫右上角的二维码加入“创客智造”公众号


标签: ros1轻松学