ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

URDF Roll,Pitch,Yaw giving weird results

asked 2020-10-13 14:52:28 -0500

grantgib gravatar image

I am trying to replicate the following robot. The base link is grey and the second link is turquoise

desired configuration

desired configuration with world frame (X-red, Y-Green, Z-Blue)

There are two links (base link in gray) and I am creating a joint between the two links located at the origin and rotated '0 -90deg -60deg' according to the intrinsic xyz tait-bryan angle description

I cannot seem to replicate the image. I have tried assigning the joint origin at

<origin xyz="0 0 0" rpy="0 -1.5708 -1.04719755"/>

or at

<origin xyz="0 0 0" rpy="-1.04719755 -1.5708 0"/>

and both give the same result.

This is my complete URDF.

<robot name="angle-check">
        <link name="base">
            <inertial>
                <origin xyz="0 0 0"/>
                <mass value="15"/>
                <inertia ixx="0.3" iyy="0.3" izz="0.1" ixy="0" ixz="0" iyz="0"/>
            </inertial>
            <visual>
                <material>
                    <color rgba="0.8 0.8 0.8 1"/>
                </material>
                <geometry>
                    <box size='0.5 0.05 0.05'/>  
                </geometry>
            </visual>
        </link>

    <link name="link1">
        <inertial>
            <origin xyz="0 0 0"/>
            <mass value="15"/>
            <inertia ixx="0.3" iyy="0.3" izz="0.1" ixy="0" ixz="0" iyz="0"/>
        </inertial>
        <visual>
            <material>
                <color rgba="0 0.8 0.8 1"/>
            </material>
            <geometry>
                <box size="0.4 0.1 0.05"/>
            </geometry>
        </visual>
    </link>

    <joint name="link1" type="revolute">
        <origin xyz="0 0 0" rpy="0 -1.5708 -1.04719755"/>
        <!-- <origin xyz="0 0 0" rpy="-1.04719755 -1.5708 0"/> -->
        <axis   xyz="0 0 1"/>
        <parent link="base"/>
        <child  link="link1"/>
        <limit  lower="-1.0472" upper="1.0472"/>
    </joint>
</robot>

Any Help would be greatly appreciated! Thank you

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2020-10-15 06:58:28 -0500

The following origin of joint configuration solves your problem.

<origin xyz="0 0 0" rpy="1.5707 0 1.5707/>

image description

And the movement of the joint will be on the X-axis [Base reference]

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2020-10-13 14:52:28 -0500

Seen: 402 times

Last updated: Oct 15 '20