Ask Your Question
0

Problem with attaching a robotiq 2f gripper to my kuka lwr

asked 2019-03-18 15:57:17 -0500

steradiant gravatar image

updated 2019-03-21 14:46:51 -0500

Hello, I want to attach a gripper to my kuka lwr. I found the robotiq 2f gripper to fit quite good for my requirements ( https://github.com/Danfoa/robotiq_2fi... ). But I have some problems with attaching the gripper to my robot. I have a urdf.xarco file where I include all my separate parts

<?xml version="1.0"?>
  <robot xmlns:xacro="http://www.ros.org/wiki/xacro" name="single_lwr_robot">

  <!-- Include all models -->
  <xacro:include filename="$(find lwr_description)/model/kuka_lwr.urdf.xacro"/>
  <xacro:include filename="$(find robotiq_2f_140_gripper_visualization)/urdf/robotiq_arg2f_140_model_macro.xacro" />

  <xacro:kuka_lwr name="lwr">
  <origin xyz="0 0 0" rpy="0 0 0"/>
  </xacro:kuka_lwr> 

  <xacro:robotiq_arg2f_140 />
</robot>

The kuka robot alone works fine, I was also able to add a box at the top of the robot. Therefore I made a new joint on the last link of the robot and attached the box to this link. When I do the same with the robotiq gripper, it doesn't work. Here are is my changed robotiq_arg2f.xarco file:

<?xml version="1.0"?>
<robot xmlns:xacro="http://ros.org/wiki/xacro">
  <xacro:macro name="robotiq_arg2f_base_link" params="prefix">

  <joint name="tap_joint" type="fixed">
    <origin xyz="0 0 0.01" rpy="0 0 0"/>
    <parent link="lwr_7_link"/>
    <child link="${prefix}robotiq_arg2f_base_link"/>
  </joint>

    <link name="${prefix}robotiq_arg2f_base_link">
      <inertial>
        <origin xyz="8.625E-08 -4.6583E-06 0.03145" rpy="0 0 0" />
        <mass value="0.22652" />
        <inertia ixx="0.00020005" ixy="-4.2442E-10" ixz="-2.9069E-10" iyy="0.00017832" iyz="-3.4402E-08" izz="0.00013478" />
      </inertial>
      <visual>
        <origin xyz="0 0 0" rpy="0 0 0" />
        <geometry>
          <mesh filename="package://robotiq_2f_140_gripper_visualization/meshes/robotiq_arg2f_base_link_fine.stl" />
        </geometry>
        <material name="">
          <color rgba="0.1 0.1 0.1 1" />
        </material>
      </visual>
      <collision>
        <origin xyz="0 0 0" rpy="0 0 ${pi / 2}" />
        <geometry>
          <mesh filename="package://robotiq_2f_140_gripper_visualization/meshes/robotiq_arg2f_base_link_coarse.stl" />
        </geometry>
      </collision>
    </link>
  </xacro:macro>

  <xacro:macro name="finger_joints" params="prefix fingerprefix reflect">
    <xacro:outer_finger_joint prefix="${prefix}" fingerprefix="${fingerprefix}"/>
    <xacro:inner_knuckle_joint prefix="${prefix}" fingerprefix="${fingerprefix}" reflect="${reflect}"/>
    <xacro:inner_finger_joint prefix="${prefix}" fingerprefix="${fingerprefix}"/>
  </xacro:macro>

  <xacro:macro name="finger_links" params="prefix fingerprefix stroke">
    <xacro:outer_knuckle prefix="${prefix}" fingerprefix="${fingerprefix}" stroke="${stroke}"/>
    <xacro:outer_finger prefix="${prefix}" fingerprefix="${fingerprefix}" stroke="${stroke}"/>
    <xacro:inner_finger prefix="${prefix}" fingerprefix="${fingerprefix}" stroke="${stroke}"/>
    <xacro:inner_knuckle prefix="${prefix}" fingerprefix="${fingerprefix}" stroke="${stroke}"/>
  </xacro:macro>
</robot>

The tap_joint is the part I've added. But now comes the problem. Gazebo and RViz are starting up but showing strange shapes of the gripper (RViz only shows the ground part without the fingers and in Gazebo the gripper is kinda falling apart). RVIz shows the following errors regarding the fingers: No transform from [left_inner_finger] to [world]. What am I doing wrong?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2019-03-19 05:14:39 -0500

fvd gravatar image

updated 2019-03-19 05:15:29 -0500

I don't see a mistake in your URDF files. The gripper's joint_states may not be published. Do you need to start up the action server mentioned in the package?

If that doesn't help, check if the problem is on your machine by trying this package.

edit flag offensive delete link more

Comments

Yes, in my opinion I did that. I went back a step and I'm trying to get the gripper running in Gazebo alone (without the robot). But I'm also failing there. The gripper spawns correctly in RViz but not in Gazebo, there it looks kinda broken. I followed the tutorial ( http://gazebosim.org/tutorials?tut=ro... ) but it doesn't work. I also don't get error messages or anything that I could work with.

steradiant gravatar imagesteradiant ( 2019-03-22 03:00:31 -0500 )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: 2019-03-18 15:57:17 -0500

Seen: 110 times

Last updated: Mar 21