Skip to content

Allow setting payload inertia matrix via set_payload service backwards-compatible (backport #1811)#1878

Merged
urfeex merged 1 commit into
kiltedfrom
mergify/bp/kilted/pr-1811
Jul 17, 2026
Merged

Allow setting payload inertia matrix via set_payload service backwards-compatible (backport #1811)#1878
urfeex merged 1 commit into
kiltedfrom
mergify/bp/kilted/pr-1811

Conversation

@mergify

@mergify mergify Bot commented Jul 13, 2026

Copy link
Copy Markdown

Summary

Implements the driver-side changes to support the extended SetPayload service in a backwards-compatible manner.

Note: This PR replaces the breaking-change approach discussed in PR #1808. It depends on the updated ur_msgs/SetPayload.srv (ros-industrial/ur_msgs#43) and on the setTargetPayload() addition to ur_client_library (UniversalRobots/Universal_Robots_Client_Library#515).

Backwards Compatibility (No Breaking Changes)

Unlike the previous proposal, this implementation does not break existing code or API contracts. The service request has been extended by appending the new fields. Existing callers who only provide mass and center_of_gravity (with inertia components defaulting to 0.0) will continue to work seamlessly.

The updated SetPayload.srv structure is:

float32 mass  
geometry_msgs/Vector3 center_of_gravity  
float64 ixx  
float64 iyy  
float64 izz  
float64 ixy  
float64 ixz  
float64 iyz  
float64 transition_time  
---  
bool success

Note

Medium Risk
Payload commands now require all inertia and transition_time interfaces to be set before the driver acts, which can change behavior for callers or mocks that only set mass/COG; depends on matching ur_msgs and ur_client_library versions.

Overview
Extends set_payload end-to-end so callers can set payload inertia (six components) and a transition time, in line with the updated ur_msgs/SetPayload service and ur_client_library setTargetPayload().

GPIO controller forwards the new request fields through ros2_control command interfaces and, when verify_payload_on_set is enabled, compares RTDE feedback against mass, COG, and inertia (with an initial sleep when transition_time > 0).

Hardware interface adds matching payload command/state GPIOs, reads payload_inertia from RTDE, and replaces setPayload with setTargetPayload once mass, COG, inertia, and transition time are all present. URDF/xacro and the RTDE output recipe are updated accordingly.

Integration tests cover inertia, timed transitions, and sequential updates; launch parametrization on tf_prefix was removed from the IO controller test.

Reviewed by Cursor Bugbot for commit 65bc5ff. Bugbot is set up for automated code reviews on this repo. Configure here.


This is an automatic backport of pull request #1811 done by [Mergify](https://mergify.com).

Note

Medium Risk
Payload handling now requires all inertia and transition_time command interfaces before the driver acts and depends on matching ur_msgs and ur_client_library versions; incorrect mocks or partial writers could fail where mass/COG alone used to suffice.

Overview
Extends set_payload so callers can set payload inertia (six components) and a transition time, aligned with the updated ur_msgs/SetPayload service and setTargetPayload() in ur_client_library.

The GPIO controller writes the new request fields to ros2_control command interfaces and, when verify_payload_on_set is on, waits for transition_time then checks RTDE feedback against mass, COG, and inertia (not only mass/COG).

The hardware interface adds matching payload command/state GPIOs, subscribes to payload_inertia in the RTDE output recipe, and only issues a payload update once mass, COG, inertia, and transition time are all present—calling setTargetPayload instead of setPayload. URDF/xacro declares the new interfaces.

Integration tests cover inertia, timed transitions, and sequential updates; IO controller launch tests no longer parametrize tf_prefix.

Reviewed by Cursor Bugbot for commit 50b6efa. Bugbot is set up for automated code reviews on this repo. Configure here.

…s-compatible (#1811)

Extend set_payload service with inertia matrix and transition_time

(cherry picked from commit 3d18755)
@urfeex
urfeex merged commit 7fb09e2 into kilted Jul 17, 2026
7 of 12 checks passed
@urfeex
urfeex deleted the mergify/bp/kilted/pr-1811 branch July 17, 2026 12:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request kilted

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants