Robotics StackExchange | Archived questions

Simulating a ping pong ball

Hello, I am trying to get an accurate gazebo simulation of a ping pong ball. However, even though the restitution coefficient is set to 1.0, the ball bouncing is weird or it doesn't even bounce.

Here is the ball model .sdf file:

<?xml version="1.0"?>

<sdf version="1.5">
<model name="pong_ball">
    <link name="link">
      <velocity_decay>
        <linear>0</linear>
        <angular>0.001</angular>
      </velocity_decay>
      <inertial>
        <mass>0.0027</mass>
        <inertia>
          <ixx>0.00000072</ixx>
          <ixy>0.0</ixy>
          <ixz>0.0</ixz>
          <iyy>0.00000072</iyy>
          <iyz>0.0</iyz>
          <izz>0.00000072</izz>
        </inertia>
      </inertial>
      <collision name="collision">
        <geometry>
          <sphere>
            <radius>0.020</radius>
          </sphere>
        </geometry>
        <surface>
          <friction>
            <ode>
              <mu>0.25</mu>
              <mu2>0.25</mu2>
            </ode>
          </friction>
          <bounce>
            <restitution_coefficient>1.0</restitution_coefficient>
            <threshold>0.01</threshold>
          </bounce>
          <contact>
            <ode>
              <max_vel>500</max_vel>
              <min_depth>0.001</min_depth>
            </ode>
          </contact>
        </surface>
      </collision>
      <visual name="visual">
        <geometry>
          <sphere>
            <radius>0.020</radius>
          </sphere>
        </geometry>
        <material>
            <script>
                <uri>file://media/materials/scripts/gazebo.material</uri>
                <name>Gazebo/Orange</name>
            </script>
        </material>
      </visual>
    </link>
  </model>

Can somebody help me?

Asked by pmfd123 on 2021-03-14 06:12:43 UTC

Comments

Answers