0
$\begingroup$

Gazebo Answers logo

Hi. I am trying to create a simple cylindrical shape model for Gazebo. To do so, I just copy and edit the existing cylindrical.model in /simulator_gazebo/gazebo/gazebo/share/gazebo-1.0.2/models to the dimensions I want. However, the model dissappear the moment i inserted them in Gazebo.

This is my model file

    <gazebo version="1.0">
    <model name="cylinder">
      <link name="link">
        <origin pose="0 0 0.5 0 0 0"/>
        <inertial mass="1.0">
          <inertia ixx="1" ixy="0" ixz="0" iyy="1" iyz="0" izz="1"/>
        </inertial>

        <collision name="collision">
          <geometry>
            <cylinder radius="0.127" length="1.245"/>
          </geometry>
        </collision>

        <visual name="visual">
          <geometry>
            <cylinder radius="0.127" length="1.245"/>
          </geometry>
          <material script="Gazebo/Green"/>
       </visual>
      </link>
    </model>
    </gazebo>

After some reading up, it seems that my mistake is I did not create a mesh file for the new model I created. Is my guess correct?

If so, another question will be where should I place the mesh file at? The original cylinder.model did not seems to have a mesh file.

Thank you.


Originally posted by ChengXiang on Gazebo Answers with karma: 17 on 2012-12-22

Post score: 0


Original comments

Comment by hsu on 2013-01-11:
the cylinder as it is defined in your sdf intersects with the ground plane with 0.1225m of overlap. This translates to an impulse of erp * 0.1225m / dt to be applied to the model upwards. Given the position of link is 0.5m from the ground plane, changing cylinder length to 1.0m should help.

Comment by ChengXiang on 2013-01-19:
Thank you. i will try that.

$\endgroup$

1 Answer 1

0
$\begingroup$

Gazebo Answers logo

The version of Gazebo that you are referencing in deprecated. I'll post and answer for Gazebo 1.3.

  1. Start gazebo: gazebo
  2. Insert a Cylinder using the toolbar located about the render window
  3. Save the World using File->Save World As
  4. Open the saved world using your favorite editor.

Originally posted by nkoenig with karma: 7676 on 2013-01-11

This answer was ACCEPTED on the original site

Post score: 0


Original comments

Comment by ChengXiang on 2013-01-19:
Thanks nkoenig. I guess i should upgrade my version of gazebo.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.