Methodology for introducing a new robot model in graspPlugin

This section describes how to prepare for the grasp planning stage when a new robot is introduced. HRP2JRL is used as an example of a robot model.

(1) Edit the yaml file

Edit the file “graspPlugin/RobotModels/HRP2JRL/HRP2.yaml” in a similar manner to that shown below. The meaning of each entry is explained on the right, after the “%” sign.

    name: HRP2 %Name of the Robot
    base: CHEST_JOINT1 %Base link used when IK is solved
    palm: RARM_JOINT5 %Wrist link used when IK is solved
    fingerEnds:    [ RHAND_JOINT1, RHAND_JOINT4 ] %Finger-tip links
    prehensionList: [ prehension ] %File with reference postures for grasping (prehension.pos, prehension.prm), Multiple reference postures can be specified.
    armStandardPose: [0, 0, 0, -1.57, 0, 0] %Reference posture of the arm when IK is solved by iterative calculations(The Joint angle from the base to palm)
    fingerOpenPose: [0.78, -0.78, 0.78, -0.78, 0.78, -0.78] %Pose with the fingers opened to the maximum possible extent.
    interlink:    [ [ RARM_JOINT6, 1.0 , RHAND_JOINT0, -1.0, RHAND_JOINT1, 1.0 ],[RHAND_JOINT2, -1.0, RHAND_JOINT3, 1.0, RHAND_JOINT4, -1.0]]%Interlocking link
    GrasplotPluginDir: Plugin % Name of the directory that contains the program which solves a specific ID.

The interlink definition is very important here. The HRPJ2RL Robot possesses two hands and six links and moves by interlocking links. This entry defines the aforementioned interlocking.

(2) Edit the PRM file

Next, the “prehension.prm” and “prehension.pos files” are specified. These files are stored in the “graspPlugin/RobotModels/HRP2JRL/data” path.

The “prehension.prm” file contains descriptors that hold parameters related to the grasp types (3-fingered fingertip grasp, 4-fingered fingertip grasp, enveloping grasp, etc.) and the “prehension.pos” file contains the standard postures while grasping in any of the above grasp types.

(2-1) prehension.prm

The entries between the [START] and [END] of this file, for example, are filled as shown below.
    Reference_Motion prehension
    Finger0Contact    0 1 0
    Finger0Comp        0 0 0
    Finger0Close    0.01 -0.01 0.01 
    Finger1Contact    0 1 0
    Finger1Comp        0 0 0
    Finger1Close    -0.01 0.01 -0.01  
    GRCdes_Position    0.0 0.0 -0.19
    GRCmax_Position    0.0 0.0 -0.30
    GRCmin_Position 0.0 0.0 -0.19
    GRCdes_Rpy    -1.57 0 0 
    GRCmax_Rpy    -1.57 0 0 
    GRCmin_Rpy    -1.57 0 0 
    GRCdes_Edges     0.05 0.05 0.05
    GRCmax_Edges     0.30 0.30 0.10
    GRCmin_Edges     0.01 0.01 0.01 
    Max_Load     1.0
    Min_Load     0

Each entry is explained below.
Defines which i-th link of the finger contacts the object. In the case of the H2P2JRL model, only the second link of both the 0th and 1st fingers would make contact with the object.
Defines which joint should be used to compensate for the link position while bringing the j-th link (of the i-th finger) into contact with the object. In the case of the H2P2JRL model, the 0th joint is generally used.
GRC[max,des,min]_Position, GRC[max,des,min]_Rpy, GRC[max,dex,min]_Edges
The rectangular cuboid that specifies the grasp type. This defines the position, posture, and side length of the GRC (Grasping Rectangular Convex). The figures below show examples of GRCmax and GRCdes. It should be noted that GRCmax specifies the range for “random sampling” of the object positions. GRCdes specifies the desired grasp type. Furthermore, the hand approaches the object in the GRC coordinate system along the y axis, and so the posture should be decided accordingly.
[Max, Min]_Load
Specifies the maximum and minimum weight of the grasp object in kg.


For example, the entries in this file are as shown below.
0 0.78 -0.78 0.78 -0.78 0.78 -0.78
The first 0 can be any arbitrary number, but the numbers after that specify the finger joint angles in the same order as specified in the VRML.

With this, the setup for using the Grasp Plug-in is complete.

GRCmax2.jpg GRCmax
GRCdes2.jpg GRCdes