1. roslaunch [package] [filename.launch]
$ roscd beginner_tutorials
$ mkdir launch $ cd launch
아래와 같은 turtlemimic.launch파일생성
1 <launch> 2 3 <group ns="turtlesim1"> 4 <node pkg="turtlesim" name="sim" type="turtlesim_node"/> 5 </group> 6 7 <group ns="turtlesim2"> 8 <node pkg="turtlesim" name="sim" type="turtlesim_node"/> 9 </group> 10 11 <node pkg="turtlesim" name="mimic" type="mimic"> 12 <remap from="input" to="turtlesim1/turtle1"/> 13 <remap from="output" to="turtlesim2/turtle1"/> 14 </node> 15 16 </launch>
$ roslaunch beginner_tutorials turtlemimic.launch
$ rostopic pub /turtlesim1/turtle1/command_velocity turtlesim/Velocity -r 1 -- 2.0 -1.8
'ROS electric' 카테고리의 다른 글
ROS msg와 srv생성 (0) | 2014.01.08 |
---|---|
ROS editor (rosed) (0) | 2014.01.08 |
ROS Service와 Parameter의 이해 (0) | 2014.01.08 |
ROS topic의 이해 (0) | 2014.01.08 |
ROS node의 이해 (0) | 2014.01.08 |