Remove hardcoded joint prefix #79
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hello, this PR removes the hardcoded
IRB1200prefix assigned to standardized joint names obtained through RWS.Bugfix
When multiple mechanical unit groups are defined in RobotStudio, their names are used to construct a prefix when deriving standardized joint names in abb_egm_rws_managers/SystemDataParser.
When stripping the hardcoded
IRB1200, the hardware interface stripped also the mechanical unit group prefix, likely causing #77.This was tested in RobotStudio, using the IRB1200_5_90.rspag project and RobotWare 6.16.
Joint names
When initializing the hardware interface, standardized EGM joint names are matched with URDF joint names.
With the RWS manager, the standardized joint names are constructed like this:
<robot_controller_id>_+<mech_unit_group>_+joint_+<index>The
mech_unit_groupis obtained from the controller and is applied if there is more than one.The
robot_controller_idcan be specified in the establishRWSConnection method, which passes it to the RWS manager / SystemDataParser, which pre-pends it to the standardized joint names (if defined).Before
For a single arm, the standardized joint names were:
IRB1200_joint_1,IRB1200_joint_2, ...Stripping everything before
joint_gave usjoint_1,joint_2, ... which was fine as long as URDF joints followed the same convention.For two arms, the standardized joint names were:
IRB1200_rob1_joint_1,IRB1200_rob1_joint_2, ...IRB1200_rob2_joint_1,IRB1200_rob2_joint_2, ...In this case, stripping everything before
joint_also discarded therob1_androb2_prefixes.After
After dropping the
IRB1200prefix, we no longer need to do stripping when matching joint names.For a single arm, we get
joint_1,joint_2, .. directly from the RWS manager.For two arms, we get standardized joint names:
rob1_joint_1,rob1_joint_2, ...rob2_joint_1,rob2_joint_2, ...Which is also fine, as long as the URDF follows the same convention.
Remaining issue
With this solution and RWS (RobotWare < 7.0 and
configure_via_rwsflag is set), URDF joint names must match the names generated by the RWS manager. For example, it is not possible to define a custom prefix for single-arm joint names.