Skip to content

Use shared V1 gripper limits across the full stroke - #86

Merged
kou merged 1 commit into
enactic:mainfrom
stevenaya:fix/v1-gripper-limits
Oct 16, 2026
Merged

kou merged 1 commit into
enactic:mainfrom
stevenaya:fix/v1-gripper-limits

Conversation

@stevenaya

@stevenaya stevenaya commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

The V1 gripper macro hardcodes 333 N and 10 m/s, ignoring the shared limits YAML. Read that configuration for both finger joints and set fixed limits of 150.75 N and 0.661 m/s, chosen to stay within the respective motor bounds at every opening. Update the example URDF.

Source: openarm_hardware 1.0.1, STEP/OpenArm01_follower.step. The swivel_rotor pin radius is r = 0.040 m, the swivel_link hole spacing is L = 0.035 m, and the slider-bearing axis offset is e = 0.0186 m.

q = r cosφ + sqrt(L² − (r sinφ − e)²) − 0.0185 m
q ∈ [0, 0.044] m; J = |dq/dφ|
Jmin = 0.031565963 m/rad at q = 0
Jmax = 0.046433725 m/rad at q = 0.0252285 m
Q_limit = min_q (7 / J) = 7 / Jmax = 150.752496 N
v_limit = min_q (ω × J) = (200 × 2π / 60) × Jmin = 0.661115976 m/s

These calculations separately use the DM4310's 7 N·m peak torque and 200 rpm no-load speed. The analytical Jacobian was checked at the endpoints and its interior extremum, with a finite-difference cross-check. The force and speed capability peaks over the stroke are 221.758 N and 0.972506 m/s respectively; those occur at different openings and are retained as performance references.

ROS2 control commands finger_joint1 only; joint2 follows through mimic. Effort is the budget for that one active coordinate, corresponding to 75.375 N per jaw under symmetric static loading. Velocity is per finger. A simulator with two independently driven fingers should split the force budget between its actuators.

Validation: 8 single/bimanual Xacro/URDF configurations covering prefixes and ROS2 control, plus the standalone gripper; generated limits and example URDF checked.

@kou

kou commented Oct 16, 2026

Copy link
Copy Markdown
Contributor

Can we make this PR ready for review?

BTW, here are comments from Claude Code:


Could you add how these two values were derived to the PR description (or as a comment next to the values in joint_limits.yaml)?

  1. Effort (150.75 N): The velocity derivation is clear, but the effort one isn't explained. I couldn't reproduce it from Jmin: 3 Nm / Jmin ≈ 95.0 N and 7 Nm / Jmin ≈ 221.8 N. My guess is it's the 7 Nm peak torque divided by the maximum linkage ratio over the stroke (Jmax ≈ 0.04643 m/rad), giving the force available at every finger position. Is that right? If so, please include Jmax and the torque value you used.

  2. Linkage ratio (Jmin = 0.031565962684 m/rad): Where in the CAD does this come from (which release/file of openarm_hardware, and which parts or dimensions)? How was it computed (e.g., sampled over the 0–44 mm stroke)? With that, others can check and update these values later.

@kou

kou commented Oct 16, 2026

Copy link
Copy Markdown
Contributor

I provided enactic/openarm_mujoco#91 to Claude Code and here is a new comment from Claude Code:


I found the derivation of the effort value in enactic/openarm_mujoco#91, and I could reproduce both values from that linkage model (Jmin = 0.031566 m/rad at q = 0 mm, Jmax = 0.046434 m/rad at q = 25.23 mm). Could you add the same derivation to this PR's description (or as a comment next to the values in joint_limits.yaml)? Please include the CAD source (openarm_hardware 1.0.1, STEP/OpenArm01_follower.step), r/L/e, and both Jmin and Jmax. This would let others check and update the values later.

One question: openarm_mujoco#91 says the 150.75 N limit acts on the shared opening coordinate and each jaw sees F/2. Here, both finger_joint1 and the mimic finger_joint2 get effort="150.75". In a simulator that applies each joint's effort limit independently, the total gripping force could then be 2 × 150.75 N. Is 150.75 N per joint intended here, or should it be F/2 ≈ 75.38 N per finger?

@stevenaya
stevenaya marked this pull request as ready for review October 16, 2026 03:30
Copilot AI balanced review requested due to automatic review settings October 16, 2026 03:30

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.

@stevenaya

Copy link
Copy Markdown
Contributor Author

This PR is now ready for review. Rechecking the derivation exposed a distinction in the intended limit convention: the current values use the lowest points of the force and speed capability envelopes over the stroke. For global maximum capabilities, both extrema need to change.

Source: openarm_hardware 1.0.1, STEP/OpenArm01_follower.step. The swivel_rotor pin radius is r = 40 mm, the swivel_link hole spacing is L = 35 mm, and the slider-bearing axis offset is e = 18.6 mm.

q = r cosφ + sqrt(L² − (r sinφ − e)²) − 0.0185 m
q ∈ [0, 0.044] m; J = |dq/dφ|
Jmin = 0.031565963 m/rad at q = 0
Jmax = 0.046433725 m/rad at q = 0.0252285 m
maximum effort = 7 / Jmin = 221.75785 N
maximum velocity = Jmax × (200 × 2π / 60) = 0.97250567 m/s

The analytical derivative was checked at the endpoints and its interior extremum, and cross-checked with finite differences. The motor specifications provide 7 N·m peak torque and 200 rpm no-load speed. These maxima occur at different openings and operating points; fixed global bounds do not capture the opening-dependent torque/speed envelope.

The current ROS2 control configuration commands joint1 only, with joint2 following through mimic. Effort is intended for this one active coordinate; velocity is single-finger travel speed. A 221.76 N generalized-force bound corresponds to 110.88 N per jaw under symmetric static loading. A simulator with two independently driven fingers should split that force budget between its actuators. The mimic joint's URDF effort field alone does not create another actuator.

The current code still uses 150.75 N / 0.661 m/s; the values above correct the proposed maxima and make the actuator convention explicit.

Copilot AI balanced review requested due to automatic review settings October 16, 2026 04:16
@stevenaya
stevenaya force-pushed the fix/v1-gripper-limits branch from b51425f to 41374ed Compare October 16, 2026 04:16

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.

@stevenaya stevenaya changed the title Use shared V1 gripper force and velocity limits Use shared V1 gripper peak force and speed limits Oct 16, 2026
Copilot AI balanced review requested due to automatic review settings October 16, 2026 05:07
@stevenaya
stevenaya force-pushed the fix/v1-gripper-limits branch from 41374ed to 72600a8 Compare October 16, 2026 05:07

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.

@stevenaya stevenaya changed the title Use shared V1 gripper peak force and speed limits Use shared V1 gripper limits across the full stroke Oct 16, 2026
@stevenaya

Copy link
Copy Markdown
Contributor Author

Updated the code and PR description to use fixed limits of 150.75 N / 0.661 m/s across the full stroke: Q_limit = 7 / Jmax and v_limit = ω × Jmin. The description includes the CAD source and derivation, with 221.758 N / 0.972506 m/s retained as performance peaks at individual openings. Effort is the budget for one active coordinate; velocity is per finger.

@kou
kou merged commit 44264e2 into enactic:main Oct 16, 2026
6 checks passed

This branch was successfully deployed

1 active deployment
release — 72600a88 Deployed Oct 16, 2026 by stevenaya via Publish #195
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants