Urdf, two joints for one link possible?
Hey guys, I am trying to simulate an ackermann steering robot in ROS. For this I created from CAD data an URDF model. My problem is to connect 1 part with 2 other parts in the urdf. I am not really sure of this is even possible. I want that the spurstange joint is rotating the achsschenkel joints. See the GIF for maybe better understanding. One Achsschenkel joint is mimiced to the other and my goal is to move the spurstange and the achsschenkel are moving in depenency to this.
Is this possible or do you have another idea to achieve this?
Hope it is clear enough. I am sorry for the bad naming of the parts, it is just my first attempt i will clear it up later ;)
Here is my urdf:
<?xml version="1.0"?>
<robot
xmlns:xacro="http://www.ros.org/wiki/xacro" name="piaggio">
<property name="M_PI" value="3.1415926535897931" />
<link name="base">
<inertial>
<mass value="1.0" />
<origin xyz="0 0 0.27" />
<inertia ixx="1.0" ixy="0.0" ixz="0.0" iyy="1.0" iyz="0.0" izz="1.0" />
</inertial>
<visual>
<origin xyz="0 0 0" rpy="0 0 0" />
<geometry>
<mesh filename="file:///home/aschultz/piaggio_ws/src/piaggio_description/cad/dae_collada/fahrzeug_versetzt.dae" scale="1 1 1" />
</geometry>
<material name="white">
<color rgba="1 0 0 1"/>
</material>
</visual>
<collision>
<origin xyz="0 0 0" rpy="0 0 0" />
<geometry>
<mesh filename="file:///home/aschultz/piaggio_ws/src/piaggio_description/cad/dae_collada/fahrzeug_versetzt.dae" scale="1 1 1" />
</geometry>
</collision>
</link>
<gazebo reference="base">
<material>Gazebo/Blue</material>
<turnGravityOff>false</turnGravityOff>
</gazebo>
<link name="spurstange">
<inertial>
<mass value="1.0" />
<origin xyz="0 0 0" />
<inertia ixx="1.0" ixy="0.0" ixz="0.0" iyy="1.0" iyz="0.0" izz="1.0" />
</inertial>
<visual>
<origin xyz="0 0 0" rpy="0 0 0" />
<geometry>
<mesh filename="file:///home/aschultz/piaggio_ws/src/piaggio_description/cad/dae_collada/spurstange_koodmitte.dae" scale="1 1 1" />
</geometry>
</visual>
<collision>
<origin xyz="0 0 0" rpy="0 0 0" />
<geometry>
<mesh filename="file:///home/aschultz/piaggio_ws/src/piaggio_description/cad/dae_collada/spurstange_koodmitte.dae" scale="1 1 1" />
</geometry>
</collision>
</link>
<gazebo reference="spurstange">
<material>Gazebo/Green</material>
<turnGravityOff>false</turnGravityOff>
</gazebo>
<joint name="spurstange_joint" type="prismatic" >
<limit lower="-0.5" upper="0.5" effort="100" velocity="10" />
<axis xyz="0 1 0" />
<parent link="base" />
<child link="spurstange" />
<origin xyz="-0.0838375 0 0.29" rpy="0 0 0" />
</joint>
<link name="achsschenkel_driver">
<inertial>
<mass value="1.0" />
<origin xyz="0 0 0" />
<inertia ixx="1.0" ixy="0.0" ixz="0.0" iyy="1.0" iyz="0.0" izz="1.0" />
</inertial>
<visual>
<origin xyz="0 0 0" rpy="0 0 0" />
<geometry>
<mesh filename="file:///home/aschultz/piaggio_ws/src/piaggio_description/cad/dae_collada/achsegelenk.dae" scale="1 1 1" />
</geometry>
</visual>
<collision>
<origin xyz="0 0 0" rpy="0 0 0" />
<geometry>
<mesh filename="file:///home/aschultz/piaggio_ws/src/piaggio_description/cad/dae_collada/achsegelenk.dae" scale ...
The gif is showing how it ought to work, or is showing it working incorrectly (how?)
It is showing the incorrect behaviour. I want to achieve that with moving the spurstange joint also the achsschenkel joint are rotating about z axis. The rotation caused by the slider movement of the achsschenkel joint should be achieved vai the movement of the spurstange joint
I am sorry, its so hard to make clear :D