-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update REP-I0001 with implementation-related changes/clarifications #13
base: master
Are you sure you want to change the base?
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -42,7 +42,7 @@ The following definitions are used throughout: | |
Motivation | ||
========== | ||
|
||
The first version of the motion/status interface (loosely documented in code and wikis) worked well for single arm manipulators. Multi-arm (asynchronous or synchronous) was not supported in a generic manor that could be used across all platforms [#discuss]_. Some attempts were made to support multiple arms using the existing interface, but these often required multi-arm joint states which could exceed the max number of joints and did not allow for mixed multi-arm/single-arm motion. The intent of this REP is to define a new set of simple messages[#simp_msg]_ for multi-arm control. These messages will replace existing motion control message (they will be deprecated). The approach taken in the REP is one that creates a new set of clients for robot motion. The underlying simple message libraries will remain unchanged (except for the addition of new messages). | ||
The first version of the motion/status interface (loosely documented in code and wikis) worked well for single arm manipulators. Multi-arm (asynchronous or synchronous) was not supported in a generic manner that could be used across all platforms [#discuss]_. Some attempts were made to support multiple arms using the existing interface, but these often required multi-arm joint states which could exceed the max number of joints and did not allow for mixed multi-arm/single-arm motion. The intent of this REP is to define a new set of simple messages[#simp_msg]_ for multi-arm control. These messages will replace existing motion control message (they will be deprecated). The approach taken in the REP is one that creates a new set of clients for robot motion. The underlying simple message libraries will remain unchanged (except for the addition of new messages). | ||
|
||
|
||
Requirements | ||
|
@@ -62,8 +62,7 @@ The industrial robot controller motion interface shall meet the following requir | |
|
||
Design Assumptions | ||
========= | ||
The following assumptions are inherent in the client/server design: | ||
* All joints (regardless of group) shall be uniquely named. | ||
None at this time. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Could you clarify why you removed that assumption? I can see why it would make sense to remove the regardless of group bit, but now it allows for multiple joints in the same group being identically named. Is that intentional? |
||
|
||
|
||
Simple Message Structures | ||
|
@@ -109,9 +108,11 @@ The dynamic joint state is meant to mimic both the ROS JointState and FollowJoin | |
accelerations[] | ||
effort[] | ||
position_desired[] | ||
position_errors[] | ||
position_error[] | ||
velocity_desired[] | ||
velocity_errors[] | ||
velocity_error[] | ||
accel_desired[] | ||
accel_error[] | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why revert to singular only here? To get this more in-line with the JointState msg, I'd make all field names singular (ie: There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This message maps to both the JointState and FollowJointTrajectoryFeedback, which eventually encapsulates data using a JointTrajectoryPoint. These messages use different conventions, so there is no "best choice". In the end, I updated For what it's worth, the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Hm, I think I'd vote for consistency. Let's see whether there are any more opinions. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Additional note for the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. For brevity in typing. {shrug}. In reality, these field names don't officially appear anywhere. There are some related constants, comments, and methods in the ROS/Karel code, but they don't adhere strictly to these names either. |
||
effort_desired[] | ||
effort_error[] | ||
|
||
|
@@ -125,12 +126,13 @@ The dynamic group status is meant to mimic both the ROS-I RobotStatus message. | |
num_groups: # of motion groups included in this message | ||
group[]: # length of this array must match num_groups | ||
id: control-group ID for use on-controller | ||
mode: | ||
e_stopped: | ||
drives_powered: | ||
motion_possible: | ||
in_motion: | ||
e_stopped: | ||
error_code: | ||
in_error: | ||
in_motion: | ||
mode: | ||
motion_possible: | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Just asking: do we want to order this like Obviously we don't have to keep this in the same order, as we are not bound by backward compatibility issues. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Hm. The linked header and the actual order used in the RobotStatus::load(..) and RobotStatus::unload(..) implementations would seem not to match with each other. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It looks to me as though everything is consistent, after this update to the REP. Your comments link to rev 12a74a1, but it looks like commit 4405b0d updated the header comments to match the field ordering in load/unload. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Hm, yes, you're right. I even fixed that order myself (ros-industrial/industrial_core@4405b0dc). Sorry for the noise. |
||
|
||
|
||
Communications Method | ||
|
@@ -156,27 +158,40 @@ The motion interface can be expressed as four variations: | |
|
||
Node Configuration | ||
--------- | ||
In order to support the various methods of control, the motion node must be somewhat dynamic/statically reconfigurable[see current parameters]. The node must be able to support subscriptions to multiple topics (all of the same type) as well as conversion from ROS group organizations to controller organization. This mapping would look similar to the MoveIt controller manager[#ctrl_mgr]_. | ||
The yaml file will contain a list of structures that defines the joint trajectory topics as well as the mapping to the controller.:: | ||
In order to support the various methods of control, the motion node must be somewhat dynamic/statically reconfigurable[see current parameters]. The node must be able to support subscriptions to multiple topics (all of the same type) as well as conversion from ROS group organizations to controller organization. This mapping would look similar to the MoveIt controller manager [#ctrl_mgr]_. | ||
|
||
As in previous interfaces, the node will be configured using a ROS parameter specifying ROS-to-controller mapping. This parameter will contain a list of structures that define both the topic namespaces as well as the mapping to the controller.:: | ||
|
||
topic_list: | ||
- name: <topic name> | ||
controller_joint_map: | ||
- group: <controller group#> | ||
ns: <topic namespace> | ||
group: <controller group#> | ||
joints: | ||
- <joint_1> | ||
- <joint_2> | ||
- <joint_N> | ||
- name: <topic name> | ||
- group: <controller group #> | ||
ns: ... | ||
|
||
This structure allows users to configure the robot interface to receive motion commands in several different ways: | ||
|
||
#. Single Topic | ||
all groups use same namespace (e.g. `ns: ""`) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. In reStructuredText you need double back-ticks for verbatim text. |
||
#. Separate Topics | ||
use group-specific namespaces | ||
#. Mixed Mode | ||
joint map may contain multiple entries for the same group, in different namespaces. This enables separate multi-arm topics for: left, right, both. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'd like to avoid referring to left and right as groups, as that is only relevant when dealing with dual-arm manipulators, while multi-group motion is used in many more setups. Perhaps just adding a "for example" to the sentence. |
||
|
||
The interface node will always listen for motion commands on the same topic as the current interface (`joint_path_command`), inside the specified namespace for each group. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. see earlier comment about verbatim text. And all other occurrences later. |
||
|
||
State Interface | ||
========= | ||
The robot state interface encapsulates all the data coming FROM the robot controller, including joint position, velocity (if available), effort(if available), position error and general robot status information [#rbt_stat]_. The implementation of the state interface is simpler than the motion interface because it can be generalized to the multi-arm case, where a single arm is just a specific example. | ||
The robot state interface encapsulates all the data coming FROM the robot controller, including joint position, velocity (if available), effort(if available), position error and general robot status information [#rbt_stat]_. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. missing space between effort and (if available). There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Suggestion: don't use capitalisation for emphasis, use |
||
|
||
The state interface is split into a joint state and robot status interface (although they will utilize the same socket connection, see `Communications Method`_). The split allows joint state feedback to be sent at a higher rate than status information (which should change slowly). | ||
* Joint State - A single controller message is split into N JointState messages. | ||
* Robot Status - A single controller message that contains status information for each arm. | ||
|
||
As in the motion interface, users can specify which namespace to use for each robot group. Unlike the motion interface, multiple groups that share a namespace are *always* combined into a single message (regardless of sync vs. async motion). Separate namespaces can be used to receive separate messages for each motion group. | ||
|
||
For `JointState` and `JointTrajectoryFeedback` messages, aggregation of multiple robot groups is easily supported through the explicit joint-name list in the message. For `RobotStatus` messages, the status of multiple groups is aggregated into a single message using simple logic and the `TriState` message type: If all groups share the same status value, use that value, otherwise use `TriState::Unknown`. Some fields (such as `in_motion`) may use modified logic (if "any" group in motion...). | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Perhaps reword paragraph a bit: to which group does "the status of multiple groups is aggregated" refer here? Motion groups on the controller, those defined in the configuration yaml or a mix-and-match of those two? Ie: what is the 'status of a group' defined in the config yaml that spans joints from two motion groups on the controller (if that is possible)? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Also: not too sure about the "Some fields may use modified logic". Can 'a group' be said to be in motion if one or more are not? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm struggling a bit with the rewording. Perhaps I can explain my intent, and you can suggest more specific areas that could be clarified? The intent is that "group" always refers to a Robot Motion Group, as defined on the robot controller, and always is directly/uniquely associated with a fixed set of physical motors. The ROS client can use the "mapping rules" defined in the configuration parameter/YAML to publish the joint states on one or more topics ("namespaces"). If each Robot Motion Group is mapped to a separate namespace, the ROS interface looks much like the current single-group case: each topic has messages that contain only joint-state data for a single robot motion group. For a dual-arm case, you might get a However, if multiple Robot Motion Groups are mapped to the same namespace, the multi-group core is more visible. Rather than publish separate messages for each motion-group on the same topic, the intent is to combine joints from all groups into a single topic. For a dual-arm robot, you might see: I was trying to highlight that the Here's an example, for a dual-arm robot, with both Robot Motion Groups mapped to a single namespace:
|
||
|
||
.. image:: rep-I0001/state_interface.png | ||
|
||
|
@@ -185,26 +200,11 @@ Node Configuration | |
--------- | ||
Similar to the motion interface, the state interface will require configuration. The state interface will have to parse messages coming from the robot and convert the date into the desired ROS topics. The level of configuration available on the robot controller will vary, so the messages coming from the controller may be more or less dynamic. The state node, based on configuration, will identify the pertinent information from the robot controller and convert to ROS topics. Additional information will be ignored. | ||
|
||
The yaml file will contain a list of structures that defines the joint trajectory/status topics as well as the mapping to the controller. Note, this configuration is very similar to the motion node, with the exception that the state node performs a one-to-one mapping from controller groups to topics. The motion node, in addition to this, can perform a one(topic) to many (groups) mapping.:: | ||
|
||
topic_list: | ||
- state | ||
group: <controller group#> | ||
- joint | ||
- name: <topic name> | ||
ns: <topic namespace> | ||
joints: | ||
- <joint_1> | ||
- <joint_2> | ||
- <joint_N> | ||
- status | ||
- name: <topic name> | ||
- ns: <topic namespace> | ||
... | ||
The state interface uses the same ROS configuration parameter as the motion node. Robot groups may be mapped to the same namespace (aggregate status messages) or different namespaces (per-group messages), or both. As in the motion interface, the same topics are used within each namespace as are used in the current state interface. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Perhaps add some example configurations for each of the cases? The "may be mapped to X, Y or both" can be confusing. |
||
|
||
Backwards Compatibility | ||
========= | ||
This REP creates a new industrial robot client package that will not be backwards compaptible with the previous version. This means that all servers will have to be rewritten to support this new client. Because this REP does not change the ROS API (except for multi-arm considerations), the previous client/server versions can continue to be used as is. Transition to the client/servers described by this REP can be a gradual process as the capabilities enabled by this new design are required. | ||
This REP creates a new industrial robot client package that may not be backwards compaptible with the previous version. The new Dynamic simple_message types will be used for all data communications with the robot, even in single-arm configurations. This means that all robot servers will have to be rewritten to support the new dynamic message types. This REP attempts to minimize the impact to ROS-side API, so most ROS clients will be unaffected. The new industrial robot client package should continue to support the existing `controller_joint_names` definition, for backwards compatibility. Transition to the client/servers described by this REP can be a gradual process as the capabilities enabled by this new design are required. | ||
|
||
If incompatible client/server combinations are ever used, there is little risk of undesirable behavior. Because the simple message base protocol is not changed by this REP, the client/server should recognize the new message types as undefined and return an error reply code. | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing space between messages and
[#simp_msg]_
(in "new set of simple messages[#simp_msg]_ for multi-arm control").