01-ROS入门-05 ROS功能包

1. 创建ros功能包

cd ~/workplace/src/
catkin_create_pkg package_name std_msgs rospy roscpp

#其中std...rospy...roscpp等都是功能包的各类依赖
#格式为 catkin_create_pkg [depend1] [depend2] [depend3] #

2. 编译ros功能包

cd ~/workspace/
catkin_make

3. 增加工作区至系统环境

. ~/catkin_ws/devel/setup.bash

4.定位当前工作区为活动工作区

source ~/workspace/devel/setup.bash

你可能感兴趣的:(01-ROS入门-05 ROS功能包)