Dynamic Grasp Planner

Dynamic grasp planner simulates grasping of dynamic targets in OpenRAVE. This page contains the current implementation plan and completion status of different features of the implementation. There is also section for some other - possibly useful - implementation related things.

Implementation Plan

Current implementation plan for the dynamic grasp planner. Static grasp planner generates the initial hand preshapes and positions. In start state Octave scripts set the environment according to the initial state given by the static grasp planner. In grasp state the controller tries to grasp the target object. In analysis state Octave scripts calculate how good the grasp is. Here is the planner's implementation plan diagram for Dia. There is a PNG image of it below.

Static Grasp Planner

  1. Generate grasps with hand positions
    • MakeGraspTable needs to be modified
    • Call orBodyGetTransform after RunGrasp to get the hand's position

Implementation plan diagram

Start State

  1. Set plane
    • orEnvCreateKinBody
    • orBodySetTransform
  2. Set target position
    • Sets target object on the plane.
    • orEnvCreateKinBody
    • orBodySetTransform
  3. Set hand position
    • orEnvCreateRobot
    • orBodySetTransform
    • Gets the position from the static grasp planner.
    • The hand probably should not be colliding with the target at this point to avoid any unintentional movements when physics simulation starts. It might be a good idea to bull the hand back a bit.
    • Floats, connected to the environment with a lock joint.
    • Controlled through an actuator.
  4. Set preshape
    • orRobotSetDOFValues
  5. Check that the hand isn't colliding with the plane
    • orEnvCheckCollision checks that the hand isn't colliding with anything. Should be enough, because the plane is the only thing the hand could be colliding with.
  6. Set controller type
    • orRobotControllerSet
  7. Start physics simulation
    • orEnvSetOptions
  8. Set controller state machine
    • orRobotControllerSend
    • Also starts the controller

Grasp State

  1. Controller reads simulated sensors
    • Simulated sensors use physics engine.
  2. Controller commands simulated hand through actuator plugins
    • Controller implements IHand and IArms interfaces that command the simulation instead of the real robot.
    • Actuators control the hand through physics engine.
    • Actuators are controlled the same way as the real hardware.
  3. Controller waits simulated time sensor
    • Simulated time sensor gets simulation time from the environment.
    • Simulates the real time sensor.

Analysis State

  1. Controller in end state
    • Controller state sensor returns current state of the controller.
    • Poll orRobotSensorGetData until the controller is in end state?
  2. Read target position
    • orBodyGetTransform
  3. Read contact forces from simulated sensors
    • orRobotSensorGetData
    • Includes parts of the hand that are not covered by actual sensors.
  4. Grasp Analysis
    • Calculate force closure
    • How much the target object moved during the grasp?
    • It might be possible to reuse code from static scripts.

Implementation Status

This section contains completion status of different features of the planner and who is implementing them.

status explanation
Done This feature is implemented
Possible Possible to do from Octave, but nothing in dynamic grasp planner actually does it yet
Needs work Still needs some work
Not started Work for this feature has not been started yet

Static Grasp Planner

feature status who notes
Generate grasps Possible
Generated grasps include hand position Not started - Should be quit easy to implement

Start State

feature status who notes
Set plane Possible
Set target position Possible
Set hand position Needs work - Static grasp planner doesn't give hand positions. The hand should also float.
Set preshape Possible
Check that the hand isn't colliding with the plane Possible
Set controller type Needs work Janne
Set controller state machine Possible
Start physics simulation Possible
Scripts to tie everything together Not started -

Grasp State

feature status who notes
Actuator plugins Needs work Sami
Simulated sensors Needs work Sami
Simulated time sensor Not started Janne? Should be relatively easy to implement
Simulated hand Needs work Sami
Controller's simulation interface Not started Janne? Needs actuators

Analysis State

feature status who notes
Controller state sensor Not started Janne
Read contact forces from sensor plugins Needs work Sami
Read target position Possible
Grasp analysis Not started -

Here are some other things that could be useful when implementing the dynamic grasp planner.

Selecting the Physics Engine

With Palrave it should be possible to select from several physics engines with different characteristics. Some experimentation might be needed to find out which engine best suits dynamic grasp planner's needs. There is a paper from 2007 in which several physics engines are compared. It might be a bit outdated, but gives some hints how to evaluate physics engines. For example accurate collision detection and friction model are important properties for the dynamic grasp planner. All in all accuracy of the physics simulation is more important than speed.