-
Notifications
You must be signed in to change notification settings - Fork 373
Update realtime containers #1721
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
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #1721 +/- ##
=======================================
Coverage 85.69% 85.70%
=======================================
Files 123 123
Lines 11897 11912 +15
Branches 1015 1015
=======================================
+ Hits 10195 10209 +14
- Misses 1379 1380 +1
Partials 323 323
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
// If this fails, then another command will be received soon anyways. | ||
ControllerReferenceMsg emtpy_msg; | ||
reset_controller_reference_msg(emtpy_msg, get_node()); | ||
input_ref_.try_set(emtpy_msg); |
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.
input_ref_.try_set(emtpy_msg); | |
input_ref_.set(emtpy_msg); |
Shouldn't it be a set in this case? As we are in the activate callback
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.
on_activate is in the rt thread, isn't it?
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.
Yes, you are right. In this particular case, it is wiser to use a set, as you want the controller to start with a zero state. Moreover, it is hard to have it blocking, unless you keep spamming the topic even before the controller started
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.
but if the lock fails here, wouldn't it be very likely that the recently received command can be read with the try_get at the beginning of the update method?
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.
then this blocking set here has no use
Apply changes from the guidelines added with ros-controls/realtime_tools#347