Conversation
system_metrics_collector/launch/system_cpu_and_memory.launch.py
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.
Launch files should not contain any logic, let's chat about this pr
Finished chatting. Please re-review, @dabonnie and @thomas-moulard. |
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.
this looks fine
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.
This LGTM - could you check quickly if there isn't any kind of builtin way to rename nodes to make sure we're not reimplementing something that already exists? It was the case in ROS2, I'm surprised this hasn't been ported.
default_measurement_period = '1000' | ||
default_publish_period = '60000' |
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.
variables containing a scientific value should include the unit default_measurement_period
-> default_measurement_period_in_ms
@thomas-moulard if i understand correctly, you are asking about this https://index.ros.org/doc/ros2/Tutorials/Node-arguments/#name-remapping |
@emersonknapp wrong username :p Yes exactly, but does it work with |
I think you mean something like overriding a builtin |
Hm, yes, I'm not sure. I'm pretty sure if you know the name, you can remap any ROS2 name from the launch command line, but I'm not sure how |
^ what I'm talking about - if we could educate ourselves on this now, that would solve us a lot of work in the future. |
After doing some testing, this is my understanding.
However, if you try to override I'm not sure what's the right way to override parameters at the
But it works. I actually think for |
In short, I believe what we're doing in this pull request is the right approach. |
Codecov Report
@@ Coverage Diff @@
## master #80 +/- ##
========================================
Coverage ? 39.3%
========================================
Files ? 33
Lines ? 1346
Branches ? 809
========================================
Hits ? 529
Misses ? 62
Partials ? 755
Continue to review full report at Codecov.
|
The launch parameters may now be specified in the launch file, and consequently on the command line as well. Node names, measurement period, publish period, and publish topic are things that are configurable.
Example usage and output: