remap用于topic的映射:
下面是两个launch启动两个节点的例子: 一个节点叫talker,它发布一个topic名为/talker 一个节点叫test1,它订阅一个topic名为/talker_mid
<launch>
<node pkg="test" type="talker" name="talker" output="screen">
<remap from="/talker" to="/re_talker" />
</node>
</launch>
12345678
12345678
<launch>
<node pkg="test" type="test1" name="test1" output="screen">
<remap from="/talker_mid" to="/re_talker" />
</node>
</launch>
转载请注明原文地址: https://www.6miu.com/read-65334.html