0
$\begingroup$

I am using ROS Noetic Ninjemys with Ubuntu 20.04. I made a URDF of an end effector. I tried to configure it with MoveIt setup assistant. However, I am unable to adjust the prismatic joint "flange_vertical" while I try to define the robot poses.

Screenshot of MoveIt

My URDF is given below.

<?xml version="1.0" encoding="utf-8"?>
<!-- This URDF was automatically created by SolidWorks to URDF Exporter! Originally created by Stephen Brawner ([email protected]) 
     Commit Version: 1.6.0-4-g7f85cfe  Build Version: 1.6.7995.38578
     For more information, please see http://wiki.ros.org/sw_urdf_exporter -->
<robot
  name="endeffector4">
  <link name="world"/>
  
  <link
    name="base_link">
    <inertial>
      <origin
        xyz="0.050387 0.039686 0.048716"
        rpy="0 0 0" />
      <mass
        value="0.1149" />
      <inertia
        ixx="4.1367E-05"
        ixy="-6.866E-14"
        ixz="2.7746E-21"
        iyy="4.3009E-05"
        iyz="1.4022E-22"
        izz="5.6702E-05" />
    </inertial>
    <visual>
      <origin
        xyz="0 0 0"
        rpy="0 0 0" />
      <geometry>
        <mesh
          filename="package://endeffector4/meshes/base_link.STL" />
      </geometry>
      <material
        name="">
        <color
          rgba="0.79216 0.81961 0.93333 1" />
      </material>
    </visual>
    <collision>
      <origin
        xyz="0 0 0"
        rpy="0 0 0" />
      <geometry>
        <mesh
          filename="package://endeffector4/meshes/base_link.STL" />
      </geometry>
    </collision>
  </link>
  <joint name="world_base_link" type="fixed">
    <parent link="world"/>
    <child link="base_link"/>
    <origin xyz="0.0 0.0 0.0" rpy="0.0 0.0 0.0"/>
  </joint>
  
  <link
    name="vertical">
    <inertial>
      <origin
        xyz="0 0.0502311372932116 0.00491665820356758"
        rpy="0 0 0" />
      <mass
        value="0.00953772572267691" />
      <inertia
        ixx="7.5511917482841E-06"
        ixy="7.3731952992275E-22"
        ixz="2.38714677766247E-23"
        iyy="1.58301414257507E-07"
        iyz="-2.70631615917454E-08"
        izz="7.55042505209247E-06" />
    </inertial>
    <visual>
      <origin
        xyz="0 0 0"
        rpy="0 0 0" />
      <geometry>
        <mesh
          filename="package://endeffector4/meshes/vertical.STL" />
      </geometry>
      <material
        name="">
        <color
          rgba="0.792156862745098 0.819607843137255 0.933333333333333 1" />
      </material>
    </visual>
    <collision>
      <origin
        xyz="0 0 0"
        rpy="0 0 0" />
      <geometry>
        <mesh
          filename="package://endeffector4/meshes/vertical.STL" />
      </geometry>
    </collision>
  </link>
  <joint
    name="flange_vertical"
    type="prismatic">
    <origin
      xyz="0.050387 -0.060076 0.0086904"
      rpy="1.5708 0 0" />
    <parent
      link="base_link" />
    <child
      link="vertical" />
    <axis
      xyz="0 1 0" />
    <limit
      lower="0.04"
      upper="0"
      effort="1"
      velocity="0.01" />
    <calibration
      rising="100"
      falling="0" />
      <safety_controller 
        k_position="20" 
        k_velocity="20" 
        soft_lower_limit="0.03" 
        soft_upper_limit="0.0" />
  </joint>
  <link
    name="horizontal">
    <inertial>
      <origin
        xyz="-0.014525 -1.569E-08 0.028652"
        rpy="0 0 0" />
      <mass
        value="0.0063234" />
      <inertia
        ixx="3.8486E-06"
        ixy="1.1544E-12"
        ixz="8.5999E-08"
        iyy="3.8887E-06"
        iyz="-2.2122E-12"
        izz="1.1115E-07" />
    </inertial>
    <visual>
      <origin
        xyz="0 0 0"
        rpy="0 0 0" />
      <geometry>
        <mesh
          filename="package://endeffector4/meshes/horizontal.STL" />
      </geometry>
      <material
        name="">
        <color
          rgba="0.79216 0.81961 0.93333 1" />
      </material>
    </visual>
    <collision>
      <origin
        xyz="0 0 0"
        rpy="0 0 0" />
      <geometry>
        <mesh
          filename="package://endeffector4/meshes/horizontal.STL" />
      </geometry>
    </collision>
  </link>
  <joint
    name="vertical_horizontal"
    type="revolute">
    <origin
      xyz="0 0.09 0.005"
      rpy="-0.0056389 0 3.1416" />
    <parent
      link="vertical" />
    <child
      link="horizontal" />
    <axis
      xyz="1 0 0" />
    <limit
      lower="-3.14"
      upper="1.5708"
      effort="30"
      velocity="3.14" />
  </joint>
</robot>

There is no error. When I try to visualise the URDF with rviz, the joint moves as expected. I tried changing the limits of the prismatic joint, but that didn't work for me.

$\endgroup$

1 Answer 1

1
$\begingroup$

When I adjusted the upper/lower limits, I was able to control the Prismatic joint:

enter image description here

  <joint
    name="flange_vertical"
    type="prismatic">

    <origin
      xyz="0.050387 -0.060076 0.0086904"
      rpy="1.5708 0 0" />
    <parent
      link="base_link" />
    <child
      link="vertical" />
    <axis
      xyz="0 1 0" />
    <limit
      lower="0.04"
      upper="100.0"
      effort="1"
      velocity="0.01" />
    <calibration
      rising="100"
      falling="0" />
      <safety_controller 
        k_position="20" 
        k_velocity="20" 
        soft_lower_limit="0.05" 
        soft_upper_limit="90.0" />
  </joint>
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.