FixTheRobot Explore Robotics / Systems Engineering / Engineering Guides / Module 16

Engineering Guides · Module 16

Grasp validation and failure recovery

Do not assume a grasp worked. Check width and force after closing and again after lifting, and react to each failure type.

  • Intermediate
  • Module 16: Manipulation & Robotic Arm Integration
  • Written for ROS 2 Jazzy where ROS 2 is used
  • Sources checked 2026-11-06

Assumptions: Numbers in the examples are illustrative and the code is executed by the site’s tests. Facts taken from a cited source are marked; other statements are general engineering knowledge and must be confirmed on the datasheet of the part you use.

1. Engineering problem

Picking fails in several distinct ways: nothing was grasped, the wrong thing was grasped, the grip is weak, or the object slips while being moved. Each needs a different response, and each can be detected from the gripper’s own measurements.

2. When is this needed?

  • Building a reliable pick-and-place cycle.
  • When failures are silent.
  • Adding retries.

3. Selection and design decisions

Signals: finger width after closing (a fully closed gripper means nothing was grasped; a width that differs from the expected object width suggests the wrong object or pose), gripper force or motor current (below a minimum means a weak grasp), and width again after lifting (an opening width means slip). Vacuum grippers use the vacuum level in the same way.

Overview
FailureSignalRecovery
MissedWidth at the closed limitRe-detect the object and retry
Wrong object or poseWidth not near the expected valueRelease, re-detect, regrasp
Weak graspForce below the minimumRegrasp with more force or another pose
Slip during liftWidth opens after the liftSlower motion or a better grasp
Dropped in transitWidth or vacuum change during transitStop, report, recover the object
CollisionUnexpected force on the armStop and replan

4. Advantages and disadvantages

  • More checks catch more failures and add time to each cycle.
  • Retry limits avoid infinite loops and need an escalation (ask for help).
  • Sensors in the gripper cost more and pay back in reliability.

5. Requirements and constraints

  • Expected width and minimum force for each object type.
  • A retry limit and an escalation path.
  • All failures are logged with the object and pose.

6. Architecture

close ─▶ check width and force ─▶ lift ─▶ check width again ─▶ move ─▶ place
          failure at any check ─▶ classified ─▶ retry or escalate

7. Implementation

  1. Define expected width and minimum force per object.
  2. Add checks after closing and after lifting.
  3. Classify failures (below) and map each to a recovery.
  4. Limit retries and add an escalation.
  5. Log every failure and review the statistics.
def classify(width_closed, width_expected, tol, force, force_min, width_after_lift):
    if width_closed <= 0.002:
        return "missed: fingers closed on nothing -> re-detect and retry"
    if abs(width_closed - width_expected) > tol:
        return f"wrong object or pose: width {width_closed * 1000:.0f} mm, expected {width_expected * 1000:.0f} mm -> release and re-grasp"
    if force < force_min:
        return "weak grasp: force below the minimum -> regrasp with more force or another pose"
    if width_after_lift is not None and width_after_lift - width_closed > 0.003:
        return "slipped during lift: width opened -> lower speed or regrasp"
    return "grasp ok"
cases = [(0.001, 0.05, 0.005, 0.0, 10.0, None), (0.032, 0.05, 0.005, 12.0, 10.0, None), (0.050, 0.05, 0.005, 4.0, 10.0, None), (0.050, 0.05, 0.005, 14.0, 10.0, 0.056), (0.051, 0.05, 0.005, 14.0, 10.0, 0.051)]
for c in cases:
    print(classify(*c))

Printed (checked by the site’s tests):

missed: fingers closed on nothing -> re-detect and retry
wrong object or pose: width 32 mm, expected 50 mm -> release and re-grasp
weak grasp: force below the minimum -> regrasp with more force or another pose
slipped during lift: width opened -> lower speed or regrasp
grasp ok

Reading it: width 1 mm means a missed grasp; 32 mm where 50 mm is expected means the wrong object or pose; correct width with 4 N below a 10 N minimum is a weak grasp; the width opening by 6 mm after lifting is a slip; and 51 mm with 14 N and no change is a good grasp. The thresholds and values are illustrative.

8. Real examples

  • Kitting cell: two retries with a re-detection, then the cell calls for help.

9. Failure scenarios

  • No check after lifting, so slip is invisible.
  • Unlimited retries on a mis-calibrated camera.
  • Not logging the failure type.

10. Troubleshooting

  1. Group failures by type and object.
  2. Check the width and force thresholds on good grasps first.
  3. Check calibration if misses are systematic.

11. Validation

  • The classifier prints the lines shown (executed by the site tests).
  • Failure statistics from a long run show a known rate per type.

12. Engineering checklist

13. Further references

  • MoveIt pick and place tutorial: moveit.picknik.ai, read 2026-11-06 (moveit_msgs/Grasp: grasp_pose, pre_grasp_approach, post_grasp_retreat).

Related on FixTheRobot