Gazebo | Ignition | Community
Ask Your Question

Virtual Joint/World Joint not working with Gazebo

asked 2020-05-19 03:56:35 -0500

this post is marked as community wiki

This post is a wiki. Anyone with karma >75 is welcome to improve it.

Hello friends,

I am unsure of where this post belongs as I posted something similar in the ROS Answers and did not get much attention that side.

I am attempting to correctly fix my gazebo model to the empty world as I have seen in so many tutorials (like this one), but am struggling...a lot.

My GitHub for the project can be found here...where I am attempting to launch demo_gazebo.launch but get a similar behavior as this previously asked question: 22078.

I have attempted both the solutions there with no luck.

The URDF being utilized is here.

I have tried several iterations with and without the "world" link (truncated URDF):

    <?xml version="1.0" ?>
<!-- =================================================================================== -->
<!-- |    This document was autogenerated by xacro from arm.xacro                      | -->
<!-- |    EDITING THIS FILE BY HAND IS NOT RECOMMENDED                                 | -->
<!-- =================================================================================== -->
<robot name="arm" xmlns:xacro="">
  <!-- base_link -->
  <gazebo reference="base_link">
  <!-- plat_link -->
  <gazebo reference="plat_link">
  <!-- lock_link -->
  <gazebo reference="lock_link">
  <!-- shoulder_link -->
  <gazebo reference="shoulder_link">
  <!-- forearm_link -->
  <gazebo reference="forearm_link">
  <!-- wrist_link -->
  <gazebo reference="wrist_link">
    <plugin filename="" name="gazebo_ros_control">

  <!--World Link-->
  <link name="world"/>
  <!-- World Joint -->
  <joint name="world_joint" type="fixed">
    <parent link="world"/>
    <child link="base_link"/>

  <!--Base Link-->
  <link name="base_link">
      <mass value="1.0"/>
      <origin rpy="0 0 0" xyz="0 0 0"/>
      <inertia ixx="0.00153508333333" ixy="0" ixz="0" iyy="0.00153508333333" iyz="0" izz="0.00245"/>

I realize this is probably a one line quick fix but I am so stumped and I really want my custom 4 DOF shakin' before June!

Any time you fine people can give is greatly appreciated.


edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2020-05-19 09:48:43 -0500

ahcorde gravatar image

updated 2020-05-19 09:48:53 -0500


Adding these lines at the end of the URDF should be enough

  <link name="world"/>
  <joint name="world_joint" type="fixed">
     <parent link="world"/>
     <child link="dummy_link"/>
edit flag offensive delete link more


Hey @ahcorde, thank you for checking out my question, I appreciate your time.

In my quest to solve this, I have tried your suggestion as well. I have updated the URDF and the SRDF in my project in a form that I feel should be the solution.

When this is run, the arm acts erratically in both Gazebo and Rviz/Moveit.

matthewmarkey gravatar imagematthewmarkey ( 2020-05-20 06:32:44 -0500 )edit

Whenever I use the lines of code you have suggested, my model moves very quickly in many different directions.

matthewmarkey gravatar imagematthewmarkey ( 2020-05-20 06:35:24 -0500 )edit

Question Tools

1 follower


Asked: 2020-05-19 03:56:35 -0500

Seen: 772 times

Last updated: May 19 '20