Ask Your Question
0

URDF joint not Rotate about its origin

asked 2018-03-14 03:31:33 -0600

updated 2018-03-15 05:24:33 -0600

Hi all ,

I create a one URDF file from Solidworks and i tried to rotate its joint . then i get Wrong origin of joint . i mean when i rotate joint of Robotic arm its rotate about its base joint not about its axis . i need to define cooridante frame in specific direction or need to create every joint cooridante system in specific directions

here is my URDF code :-

<?xml version ="1.0"?>
<robot name="ros_as">

<link name="world"/>
  <link name="base_link">

<inertial>
 <mass value="0.11529" />
<inertia ixx="9.8E-05" ixy="-1.15E-05"  ixz="8.6465E-05" iyy="4.444E-05" iyz="-3.4586E-05" izz="4.73321E-05" />
    </inertial>
    <visual>
      <origin xyz="0 0 0" rpy="0 -1.7 0" />
      <geometry>
        <mesh filename="package://ros_as/meshes/base_link.STL" />
      </geometry>
      <material name="">
        <color rgba="0.77647 0.75686 0.73725 1" />
      </material>
    </visual>
  </link>

  <link name="link1">

<inertial>
<mass value="0.11529" />
<inertia ixx="1.2008E-05" ixy="-4.262E-05"  ixz="-2.59095E-05" iyy="2.743395E-05" iyz="4.1807E-05" izz="2.794303E-05" />
    </inertial>
    <visual>
      <origin xyz="0.001 -0.038 0.02" rpy="-1.7 0 0" />
      <geometry>
        <mesh filename="package://ros_as/meshes/link1.STL" />
      </geometry>
      <material name="">
        <color rgba="0.77647 0.75686 0.73725 1" />
      </material>
    </visual>
  </link>



  <link name="link2">

<inertial>
<mass value="0.11529" />
<inertia ixx="3.46069E-05" ixy="-7.86556E-05" ixz="-1.295125E-05" iyy="7.548495E-05" iyz="1.42141E-05" izz="7.410357E-05" />
    </inertial>
    <visual>
      <origin xyz="0.001 -0.066 0.05" rpy="-1.7 0 0" />
      <geometry>
        <mesh filename="package://ros_as/meshes/link2.STL" />
      </geometry>
      <material name="">
        <color rgba="0.77647 0.75686 0.73725 1" />
      </material>
    </visual>

  </link>

<joint name="j0" type="fixed">
    <parent link="world" />
    <child link="base_link" />
  <origin xyz="0 0 0" rpy="0 0 0" />
</joint>

  <joint name="j1" type="revolute">
    <parent link="base_link" />
    <child link="link1" />
    <origin xyz="0.03593 0 0" rpy="-1.5708 0 1.657" />
    <axis xyz="0 0 1" />
    <limit lower="-3.14" upper="3.14" effort="20" velocity="5" />
  </joint>

  <joint name="j2" type="revolute">
    <parent link="link1" />
    <child link="link2" />
    <origin  xyz="0 -0.01 -0.03593" rpy="0 0.034067 0" />
    <axis xyz="0 0 1" />
    <limit lower="-3.14" upper="3.14" effort="20" velocity="5" />
  </joint>

<transmission name="tran0">
<type>transmission_interface/SimpleTransmission</type>
<joint name="j1">
<hardwareInterface>PositionJointInterface</hardwareInterface>
</joint>
<actuator name="motor0">
<hardwareInterface>PositionJointInterface</hardwareInterface>
<mechanicalReduction>1</mechanicalReduction>
</actuator>
</transmission>

<transmission name="tran1">
<type>transmission_interface/SimpleTransmission</type>
<joint name="j2">
<hardwareInterface>PositionJointInterface</hardwareInterface>
</joint>
<actuator name="motor1">
<hardwareInterface>PositionJointInterface</hardwareInterface>
<mechanicalReduction>1</mechanicalReduction>
</actuator>
</transmission>

<gazebo>
<plugin name="control" filename="libgazebo_ros_control.so"/>
</gazebo>

</robot>

Home position joints potion

edit retag flag offensive close merge delete

Comments

1

Can you edit your question to put your urdf code wiht the preformatted text (101010 button or CTRL+K) ?

Delb gravatar imageDelb ( 2018-03-14 03:42:27 -0600 )edit

@Delb Done Sir

lagankapoor gravatar imagelagankapoor ( 2018-03-14 04:09:32 -0600 )edit

2 Answers

Sort by ยป oldest newest most voted
0

answered 2018-03-15 01:34:04 -0600

I have solved this issue with URDF base coordinates and with its reference joint coordinates
i attached screenshot hereWorking well

edit flag offensive delete link more
1

answered 2018-03-14 03:44:08 -0600

gvdhoorn gravatar image

If you used the SolidWorks urdf exporter plugin this is most likely caused by the fact that your mates were not in the correct location.

Or if they were, then either the plugin failed in correctly identifying them, or you misconfigured them in the export wizard.

edit flag offensive delete link more

Comments

@gvdhoorn Sir i chose them Right in solidworks wizard and then after geting URDF file i manually translate links from horizontal to vertical position . is there any way to correct them ?

lagankapoor gravatar imagelagankapoor ( 2018-03-14 04:11:58 -0600 )edit

@gvdhoorn Sir help me to be more specific about URDF wizard information , so that i learn . in SW tutorials not explain much about that

lagankapoor gravatar imagelagankapoor ( 2018-03-15 00:27:35 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2018-03-14 03:31:33 -0600

Seen: 480 times

Last updated: Mar 15 '18