-
Notifications
You must be signed in to change notification settings - Fork 431
TF prefix helper for diff drive controller #1997
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
base: master
Are you sure you want to change the base?
Conversation
saikishor
left a comment
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.
I'm not sure if it makes sense to have it in the control_toolbox package. What about controllers_interfaces/helpers.hpp existing file?
What do you think @christophfroehlich ?
OK, maybe you are right and we should put it here. |
I will start working on it |
christophfroehlich
left a comment
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.
There is a behavior-breaking change now, right?
Can we do that gracefully? e.g.,
- Deprecate the
tf_frame_prefix_enableparameter in the yaml, and log a warning message if it is set to a value different than default. And we should maintain the behavior and still use the value. - Please update the description of the
tf_frame_prefixparameter
https://github.com/ros-controls/ros2_controllers/blob/master/diff_drive_controller/src/diff_drive_controller_parameter.yaml#L49-L53 - Please add release and migration notes.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #1997 +/- ##
==========================================
- Coverage 84.91% 84.89% -0.03%
==========================================
Files 148 148
Lines 14367 14351 -16
Branches 1230 1227 -3
==========================================
- Hits 12200 12183 -17
- Misses 1740 1741 +1
Partials 427 427
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
53851e8 to
0e25332
Compare
christophfroehlich
left a comment
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.
tf_frame_prefix_enable was not unused before? Instead, during the deprecation phase, we still should use this parameter before we remove it.
I'm not sure how we can gracefully transition the usage of node namespace? Currently, if tf_frame_prefix is not set, then automatically the node namespace is used.
- control toolbox pkg already linked
- this commit is to be deleted later
- enable flag removed from args - tilde substitution with ns added - tests updated - verbose comments
- log message added if tf_frame_prefix_enable is not set default - relevant info added to yaml description, migration and release notes
05a578b to
aae1a3e
Compare
christophfroehlich
left a comment
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.
(failing tests are fine, I've released ros2_control but rosdistro is on hold for the upcoming sync).
| const auto tf_prefix = | ||
| controller_interface::resolve_tf_prefix(params_.tf_frame_prefix, get_node()->get_namespace()); |
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.
| const auto tf_prefix = | |
| controller_interface::resolve_tf_prefix(params_.tf_frame_prefix, get_node()->get_namespace()); | |
| std::string tf_prefix = ""; | |
| if (params_.tf_frame_prefix_enable) | |
| { | |
| if (params_.tf_frame_prefix != "") | |
| { | |
| tf_prefix = | |
| controller_interface::resolve_tf_prefix(params_.tf_frame_prefix, get_node()->get_namespace()); | |
| } | |
| else | |
| { | |
| tf_prefix = std::string(get_node()->get_namespace()); | |
| } | |
| } |
In this way, we get backward compatibility? currently we have the deprecation notice, but it has no effect any more.
Used new tf frame prefix helper in differential drive controller to test out & showcase the helper. This is the first part of the changes, the other controllers will come next:
Related issue