Skip to content

ROS 2 Migration: Joint Pose Trajectory

Leander Stephen D'Souza edited this page Jun 26, 2022 · 3 revisions

Overview

This pages describes the changes in the joint pose trajectory plugin in gazebo_plugins for ROS 2, including a migration guide.

Summary

  • Service set_joint_trajectory has been deprecated as it was already non-functional for the past distros.
  • Disabling physics is no longer supported as it used to disable the physics for the whole world which is not ideal.
  • tf_prefix is no longer supported.
  • set_joint_trajectory topic can now be changed using remapping arguments.

SDF parameters

ROS 1 ROS 2
updateRate update_rate
topicName <ros><remapping>set_joint_trajectory:=custom_joint_trajectory</remapping></ros>
robotNamespace
serviceName

Example Migration

ROS1

    <plugin name="plugin_name" filename="libgazebo_ros_joint_pose_trajectory.so">
      <!-- Add a namespace -->
      <robotNamespace>demo</robotNamespace>
      <topicName>set_trajectory_demo</topicName>
      <updateRate>100</updateRate>
    </plugin>

ROS2

    <plugin name="gazebo_ros_joint_pose_trajectory" filename="libgazebo_ros_joint_pose_trajectory.so">
      <ros>
        <namespace>/demo</namespace>
        <remapping>set_joint_trajectory:=set_trajectory_demo</remapping>
      </ros>
      <update_rate>100</update_rate>
    </plugin>