Skip to content
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

Loading configuration file #193

Closed
delihus opened this issue Dec 6, 2023 · 1 comment
Closed

Loading configuration file #193

delihus opened this issue Dec 6, 2023 · 1 comment

Comments

@delihus
Copy link
Contributor

delihus commented Dec 6, 2023

Is it possible to create ros2_control_node in launch or parse configuration via launch not URDF?

The case is to create a multiple robot system with the same robots thus it is needed only one file. Nav2 created great feature to override the namespace with <rosbot_namespace> in yaml files. Here:
https://github.com/ros-planning/navigation2/blob/15c9be0aa5d09dd3be40bb46a66a5175464dd1a4/nav2_bringup/launch/rviz_launch.py#L69
and here:
https://github.com/ros-planning/navigation2/blob/15c9be0aa5d09dd3be40bb46a66a5175464dd1a4/nav2_bringup/params/nav2_multirobot_params_all.yaml#L215

I would like to create the config file which has:

imu_sensor_broadcaster:
  sensor_name: <robot_namespace>imu

use the ReplaceString feature and send the changed configuration file to the ros2_control_node.

@christophfroehlich
Copy link
Contributor

christophfroehlich commented Jun 9, 2024

Is it possible to create ros2_control_node in launch or parse configuration via launch not URDF?

No that is not possible with gz_ros2_control, because the plugin creates the controller_manager itself.

Neither it is possible to pass the content of a parameter yaml to the controller_manager, because it passes the parameter file path as node option argument --params-file to the controller's node.

But this is an interesting feature, maybe you can submit a PR to ros2_control with a new argument of the load_controller service, which doesn't pass the file path but a string with the content, which then will be unwrapped to node arguments when creating the controller nodes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants