-
Notifications
You must be signed in to change notification settings - Fork 304
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
Introduce Creation of Handles with InterfaceDescription (variant support) #1679
Introduce Creation of Handles with InterfaceDescription (variant support) #1679
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #1679 +/- ##
==========================================
+ Coverage 86.64% 86.66% +0.02%
==========================================
Files 115 116 +1
Lines 10527 10537 +10
Branches 967 971 +4
==========================================
+ Hits 9121 9132 +11
+ Misses 1058 1057 -1
Partials 348 348
Flags with carried forward coverage won't be shown. Click here to find out more.
|
7fe9238
to
7b9ab79
Compare
This pull request is in conflict. Could you fix it @mamueluth? |
7b9ab79
to
f0a37d5
Compare
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 would love to see some examples of parsing data_type
and size
. Or is this not required here yet, and it is tested in another test?
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.
it is not supported here yet, i add this later with the full variant support. There i test the initialization of handles with all supported types and the parsing of the datatype for initialization of the handle is tested which includes tests for the data_type
and size
.
@destogl should i add tests here nevertheless, or is it enough if the tests are added when the functionality is actually used.
hardware_interface/include/hardware_interface/hardware_info.hpp
Outdated
Show resolved
Hide resolved
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.
The changes look good to me.
If we need to use get_name
at some point in the real-time loop, then maybe you might be interested in my suggestions. If not, they might/might not be interesting.
Thanks for the nice work .
hardware_interface/include/hardware_interface/hardware_info.hpp
Outdated
Show resolved
Hide resolved
hardware_interface/include/hardware_interface/hardware_info.hpp
Outdated
Show resolved
Hide resolved
Co-authored-by: Sai Kishor Kothakota <saisastra3@gmail.com>
c9df88d
to
e8fa131
Compare
hardware_interface/include/hardware_interface/component_parser.hpp
Outdated
Show resolved
Hide resolved
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.
thank you!
This PR is the second part of multiple breaking down #1240 in smaller changes. For an overview explanation and a lot of comments/discussion, please refer to #1240.
This prepares the handle to be constructed with a description of an Interface (InterfaceDescription). The old ways of creating a Command-/StateInterface is kept as is but deprecated. If the Command-/StateInterface is constructed with the InterfaceDescription no pointer is given anymore but the pointer points to the internal storage of the handle. Variant is still only double and get/set is only available for double as well. One important thing here is that the internal value can not be practically used at this point, since the hardware has not access to the handle after exporting, so creating one with an InterfaceDescription is pointless at this time but will be useful in the next step.
NOTE: Everything is fully backward compatible at this point. There is no change visible to Controllers. For Hardware there are changes visible (additional way of construction of the Handles) but not usable since they have no access to Handles after exporting. Tests are included. Demos can not be adapted since hw has no access to Handles at this point.