Urdf, two joints for one link possible?

asked 2015-12-08 03:36:50 -0500

schultza gravatar image

updated 2015-12-08 05:57:03 -0500

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.

GIF of the problem

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 ...
(more)
edit retag flag offensive close merge delete

Comments

The gif is showing how it ought to work, or is showing it working incorrectly (how?)

lucasw gravatar image lucasw  ( 2015-12-08 09:28:13 -0500 )edit

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

schultza gravatar image schultza  ( 2015-12-08 10:20:12 -0500 )edit

I am sorry, its so hard to make clear :D

schultza gravatar image schultza  ( 2015-12-08 10:20:20 -0500 )edit