# Revision history [back]

### Help troubleshooting this SDF model

Hello, it has taken me a while to sift through the API docs and the other SDF samples, but I'm still not able to quite get this ball-on-plate sdf functioning as expected. It's unstable and the joint dynamics don't quite make sense. Setting the target angle to zero does not appear to do so (even after a very very long time).

<?xml version="1.0" ?>
<sdf version="1.5">
<model name="ballonbeam">
<inertial>
<mass>30</mass>
</inertial>

<visual name="vis_plate_on_ground">
<pose>0 0 0.01 0 0 0</pose>
<geometry>
<cylinder>
<length>0.02</length>
</cylinder>
</geometry>
<material>
<script>
<uri>file://media/materials/scripts/gazebo.material</uri>
<name>Gazebo/Orange</name>
</script>
</material>
</visual>
<collision name="col_plate_on_ground">
<pose>0 0 0.01 0 0 0</pose>
<geometry>
<cylinder>
<length>0.02</length>
</cylinder>
</geometry>
</collision>
<visual name="vis_pole">
<pose>-0.275 0 1.1 0 0 0</pose>
<geometry>
<box>
<size>0.2 0.2 2.2</size>
</box>
</geometry>
<material>
<script>
<uri>file://media/materials/scripts/gazebo.material</uri>
<name>Gazebo/Orange</name>
</script>
</material>
</visual>
<collision name="col_pole">
<pose>-0.275 0 1.1 0 0 0</pose>
<geometry>
<box>
<size>0.2 0.2 2.2</size>
</box>
</geometry>
</collision>
<pose>0.1 0 2.1 0 0 0</pose>
<self_collide>0</self_collide>
<inertial>
<pose>0 0 0.5 0 0 0</pose>
</inertial>
<collision name='collision_plate'>
<geometry>
<box>
<size>.5 2.5 .05</size>
</box>
</geometry>
</collision>
<visual name='visual_plate'>
<geometry>
<box>
<size>.5 2.5 .05</size>
</box>
</geometry>
</visual>
<joint name="upper_joint" type="revolute">
<parent>base</parent>
<child>plate</child>
<axis>
<xyz>1.0 0 0</xyz>
<use_parent_model_frame>true</use_parent_model_frame>
</axis>
</joint>
<self_collide>1</self_collide>
<pose>0.1 -0.3 2.3 0 0 0</pose>
<collision name='collision_ball'>
<geometry>
<sphere>
</sphere>
</geometry>
</collision>
<visual name='visual_ball'>
<geometry>
<sphere>
</sphere>
</geometry>
<material>
<script>
<uri>file://media/materials/scripts/gazebo.material</uri>
<name>Gazebo/Purple</name>
</script>
</material>
</visual>
</model>
</sdf>


For reference, here's one clip of the model in the wild.. https://www.youtube.com/watch?v=y5Hmr-rR-yk

### Help troubleshooting this SDF model

Hello, it has taken me a while to sift through the API docs and the other SDF samples, but I'm still not able to quite get this ball-on-plate ball-on-beam sdf functioning as expected. It's The previous version was highly unstable and the joint dynamics don't quite make sense. Setting the target angle to zero does not appear to do so (even after a very very long time).prev version.

https://drive.google.com/file/d/0B9Gk5iW1PiEocWRTQ3lMQnhkUFk/previewThe current version doesn't isn't controllable. Maybe a gearbox is needed? Maybe I shouldn't actually try to use a real object that can leave the surface of the beam?

<?xml version="1.0" ?>
<sdf version="1.5">
<model name="ballonbeam">
<inertial>
<mass>30</mass>
</inertial>
https://github.com/slremy/ballonbeam       <visual name="vis_plate_on_ground">
<pose>0 0 0.01 0 0 0</pose>
<geometry>
<cylinder>
<length>0.02</length>
</cylinder>
</geometry>
<material>
<script>
<uri>file://media/materials/scripts/gazebo.material</uri>
<name>Gazebo/Orange</name>
</script>
</material>
</visual>
<collision name="col_plate_on_ground">
<pose>0 0 0.01 0 0 0</pose>
<geometry>
<cylinder>
<length>0.02</length>
</cylinder>
</geometry>
</collision>
<visual name="vis_pole">
<pose>-0.275 0 1.1 0 0 0</pose>
<geometry>
<box>
<size>0.2 0.2 2.2</size>
</box>
</geometry>
<material>
<script>
<uri>file://media/materials/scripts/gazebo.material</uri>
<name>Gazebo/Orange</name>
</script>
</material>
</visual>
<collision name="col_pole">
<pose>-0.275 0 1.1 0 0 0</pose>
<geometry>
<box>
<size>0.2 0.2 2.2</size>
</box>
</geometry>
</collision>
<pose>0.1 0 2.1 0 0 0</pose>
<self_collide>0</self_collide>
<inertial>
<pose>0 0 0.5 0 0 0</pose>
</inertial>
<collision name='collision_plate'>
<geometry>
<box>
<size>.5 2.5 .05</size>
</box>
</geometry>
</collision>
<visual name='visual_plate'>
<geometry>
<box>
<size>.5 2.5 .05</size>
</box>
</geometry>
</visual>
<joint name="upper_joint" type="revolute">
<parent>base</parent>
<child>plate</child>
<axis>
<xyz>1.0 0 0</xyz>
<use_parent_model_frame>true</use_parent_model_frame>
</axis>
</joint>
<self_collide>1</self_collide>
<pose>0.1 -0.3 2.3 0 0 0</pose>
<collision name='collision_ball'>
<geometry>
<sphere>
</sphere>
</geometry>
</collision>
<visual name='visual_ball'>
<geometry>
<sphere>
</sphere>
</geometry>
<material>
<script>
<uri>file://media/materials/scripts/gazebo.material</uri>
<name>Gazebo/Purple</name>
</script>
</material>
</visual>