ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

built in control on a urdf model in gazebo

asked 2012-09-05 00:04:03 -0600

Nachum gravatar image

Hi. i built a urdf model of an inverted pendlum and spawned it in gazebo. it looks as if there is buil in control on it like if it falls it will stand right up. how can i stop that control?

<?xml version="1.0" ?>
<robot name="pendelum"> 

  <link name="rod">
   <inertial>
     <mass value="0.001"/>
     <origin xyz="0 0 0" rpy="0 0 0"/>

     <inertia ixx="0.00"  ixy="0"  ixz="0" iyy="0.00" iyz="0"    izz="0.00" />
     </inertial>

   <physics type="ode" update_rate="100">
     <gravity xyz="0 0 -9.8"/>
         <ode>
           <solver type="quick" dt="0.01" iters="100" sor="1.3"/>
          </ode>
    </physics>

   <visual>
     <origin xyz="0 0 0.5" rpy="0 0 0" />
     <geometry>
      <cylinder radius="0.02" length="1"/>
     </geometry>
   </visual>

 <collision>
     <origin xyz="0 0 0.5" rpy="0 0 0"/>
     <geometry>
       <cylinder radius="0.02" length="1"/>
     </geometry>
   </collision>

 </link>

  <link name="cmass"> 
    <inertial>
      <mass value="10.0" />
      <origin xyz="0 0 0" /> 
      <inertia  ixx="0.1" ixy="0.0"  ixz="0.0"  iyy="10"  iyz="0.0"  izz="0.1" />
    </inertial>

    <visual>
      <origin xyz="0 0 1" rpy="0 0 0" />
      <geometry>
        <sphere radius="0.05"/>
      </geometry>
    </visual>

    <collision>
      <origin xyz="0 0 1" rpy="0 0 0" />
      <geometry>
        <sphere radius="0.05"/>
      </geometry>
    </collision>


  </link>

   <joint name="weld" type="fixed">
    <parent link="rod" />
    <child link="cmass" />

  </joint>

   <link name="wor"> 
    <inertial>
      <mass value="100000" />
      <!-- center of mass (com) is defined w.r.t. link local   coordinate system -->
      <origin xyz="0 0 0" /> 
      <inertia  ixx="1000.0" ixy="0.0"  ixz="0.0"  iyy="1000.0"  iyz="0.0"  izz="1000.0" />
    </inertial>

    <visual>
      <origin xyz="0 0 0.0005" rpy="0 0 0" />
      <geometry>
        <box size="0.4 0.4 0.001"/>
      </geometry>
    </visual>


<collision>
      <origin xyz="0 0 0.0005" rpy="0 0 0" />
      <geometry>
        <box size="0.4 0.4 0.001"/>
      </geometry>
    </collision>
  </link>

<joint name="floor" type="revolute">
   <parent link="wor" />
    <child link="rod" />
    <origin xyz="0 0 0" rpy="0 0 0" />
    <axis xyz="0 1 0"/>
<limit upper="3.15" lower="-3.15" effort="1000.00" velocity="1000.00"/>
<joint_properties damping="0.1" friction="1.0" />
</joint>

 <gazebo>
    <controller:gazebo_ros_controller_manager name="gazebo_ros_controller_manager" plugin="libgazebo_ros_controller_manager.so">
      <alwaysOn>true</alwaysOn>
      <updateRate>1000.0</updateRate>
      <interface:audio name="gazebo_ros_controller_manager_dummy_iface" />
    </controller:gazebo_ros_controller_manager>
  </gazebo>

<gazebo reference="cmass">
    <turnGravityOff>false</turnGravityOff>
    <material>Gazebo/Blue</material>
  </gazebo>

  <gazebo reference="rod">
    <turnGravityOff>false</turnGravityOff>
    <material>Gazebo/Red</material>
  </gazebo>

  <gazebo reference="wor">
    <turnGravityOff>true</turnGravityOff>
    <material>Gazebo/Red</material>
  </gazebo>

   </robot>

any ideas? Thanks Nachum

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2012-09-05 01:04:32 -0600

Lorenz gravatar image

I guess what you see is caused by the physics engine. Rod is connected by a joint to the world but it's pose seems to be right in the floor. Try placing it above the floor, i.e. it should not collide with the wor link.

edit flag offensive delete link more

Comments

thanks i think it is working better

Nachum gravatar image Nachum  ( 2012-09-05 01:32:12 -0600 )edit

Question Tools

Stats

Asked: 2012-09-05 00:04:03 -0600

Seen: 718 times

Last updated: Sep 05 '12