Skip to content

Declare control systems with stable joint indices in presets - #116

Draft
stevenaya wants to merge 2 commits into
enactic:mainfrom
stevenaya:refactor/shared-ros2-control
Draft

stevenaya wants to merge 2 commits into
enactic:mainfrom
stevenaya:refactor/shared-ros2-control

Conversation

@stevenaya

@stevenaya stevenaya commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

Depends on #125.

Group component joints into explicitly named control systems and assign stable system-local joint indices in the preset.

Changes

  • Replace per-component control blocks with systems.<name>.joints, mapping each component's stable joint keys to {idx: ...} entries.
  • Resolve final names through the component descriptions' name maps and use the same mimic selection as model generation. Require non-negative, unique indices within each active system, allow gaps, and emit joints in index order with an idx parameter.
  • Support multiple components in one system and disjoint subsets of one component in separate systems. Skip disabled components and reject unknown references or duplicate joint assignments.
  • Supply standard OpenArm plugin and CAN defaults from the model entry. Preserve the CAN launch arguments, control-emission switch and automatic mock selection.
  • Allow system-level command/state interface lists, defaulting to position, velocity and effort. Validate the current OpenArmHW seven-arm-joint and optional single-gripper-joint requirement in real-hardware mode.

The preset can declare a complete left-arm system as follows.

systems:
  openarm_left_hardware_interface:
    joints:
      primary_arm:
        joint1: {idx: 1}
        joint2: {idx: 2}
        joint3: {idx: 3}
        joint4: {idx: 4}
        joint5: {idx: 5}
        joint6: {idx: 6}
        joint7: {idx: 7}
      primary_arm_end_effector:
        joint1: {idx: 8}

The idx parameter identifies a joint within its system for runtime configuration binding. Motor CAN addresses remain driver configuration.

Validation

  • 30 existing tests pass on ROS 2 Jazzy, covering grouping, joint subsets, names/mimic, stable index ordering, invalid assignments and interface selection.
  • The five shipped V2 presets retain their model/control output across export, mock and real-hardware declaration modes, apart from the added index metadata.
  • Current openarm_ros2 main bringup and MoveIt URDF generation accept the CAN arguments.

Review the control changes after #125.

@stevenaya
stevenaya force-pushed the refactor/shared-ros2-control branch from 1c7994d to 1b003bb Compare November 4, 2026 08:01
@stevenaya
stevenaya marked this pull request as ready for review November 4, 2026 08:02
Copilot AI balanced review requested due to automatic review settings November 4, 2026 08:02

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 insufficient remaining quota. Try requesting a review at a lower effort level.

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 force-pushed the refactor/shared-ros2-control branch from 1b003bb to 291c0d0 Compare November 4, 2026 09:15
Copilot AI balanced review requested due to automatic review settings November 4, 2026 09:15

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 insufficient remaining quota. Try requesting a review at a lower effort level.

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.

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 insufficient remaining quota. Try requesting a review at a lower effort level.

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.

Copilot AI balanced review requested due to automatic review settings November 6, 2026 00:43

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 insufficient remaining quota. Try requesting a review at a lower effort level.

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 force-pushed the refactor/shared-ros2-control branch from 7ba0186 to fdd624a Compare November 6, 2026 00:47
Copilot AI balanced review requested due to automatic review settings November 6, 2026 00:47

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 insufficient remaining quota. Try requesting a review at a lower effort level.

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 force-pushed the refactor/shared-ros2-control branch from fdd624a to d064d3c Compare November 6, 2026 01:25
Copilot AI balanced review requested due to automatic review settings November 6, 2026 02:29

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 insufficient remaining quota. Try requesting a review at a lower effort level.

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 force-pushed the refactor/shared-ros2-control branch from 854c002 to 471bd5b Compare November 6, 2026 02:51
Copilot AI balanced review requested due to automatic review settings November 6, 2026 02:51

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 insufficient remaining quota. Try requesting a review at a lower effort level.

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 Generate control interfaces from enabled preset components Declare control systems with stable joint indices in presets Nov 6, 2026
Copilot AI balanced review requested due to automatic review settings November 6, 2026 09:22

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 insufficient remaining quota. Try requesting a review at a lower effort level.

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 force-pushed the refactor/shared-ros2-control branch from f5c415a to 7fcbff2 Compare November 6, 2026 09:24
Copilot AI balanced review requested due to automatic review settings November 6, 2026 09:24

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 insufficient remaining quota. Try requesting a review at a lower effort level.

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 force-pushed the refactor/shared-ros2-control branch from 7fcbff2 to 2f9d210 Compare November 6, 2026 10:27
Copilot AI balanced review requested due to automatic review settings November 6, 2026 10:27

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 insufficient remaining quota. Try requesting a review at a lower effort level.

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 marked this pull request as draft November 6, 2026 11:05

This branch was successfully deployed

1 active deployment
release — 2f9d2101 Deployed Nov 6, 2026 by stevenaya via Publish #374
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.

2 participants