You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm currently facing an issue with the ros2 parameters. I'm not sure how to approach this, from Iron on ros2_controller creates a node without the node options allow_undeclared_parameters and automatically_declare_parameters_from_overrides. I would like to define a block of parameters for my controller, however, their namespace is only known at the runtime. This is making it hard for me to load the parameters using the spawner.
To parse such a block, we need to know the joints parameter already at the time of declaration, and this is currently not possible. So, at the time of declaration, as this is not known, I'm not able to declare the parameter block and hence unable to set any of the respective parameters.
Moreover, in the existing parameter callbacks(add_pre_set_parameters_callback , add_on_set_parameters_callback , and add_post_set_parameters_callback), we cannot declare or set any parameters, so I would like to know if there is a way to declare some parameters at runtime. If not, I propose to have a new callback method that helps to declare the parameters at runtime or a way to specify to allow undeclared parameters to a specific namespace.
Is there a better way to approach this problem?
The text was updated successfully, but these errors were encountered:
saikishor
changed the title
Ability to declare parameter that are only known at runtime
Unable to declare parameter that are only known at runtime
Nov 14, 2023
Hello!
I'm currently facing an issue with the ros2 parameters. I'm not sure how to approach this, from Iron on ros2_controller creates a node without the node options
allow_undeclared_parameters
andautomatically_declare_parameters_from_overrides
. I would like to define a block of parameters for my controller, however, their namespace is only known at the runtime. This is making it hard for me to load the parameters using the spawner.A simple case would be something like below:
To parse such a block, we need to know the
joints
parameter already at the time of declaration, and this is currently not possible. So, at the time of declaration, as this is not known, I'm not able to declare the parameter block and hence unable to set any of the respective parameters.Moreover, in the existing parameter callbacks(
add_pre_set_parameters_callback
,add_on_set_parameters_callback
, andadd_post_set_parameters_callback
), we cannot declare or set any parameters, so I would like to know if there is a way to declare some parameters at runtime. If not, I propose to have a new callback method that helps to declare the parameters at runtime or a way to specify to allow undeclared parameters to a specific namespace.Is there a better way to approach this problem?
The text was updated successfully, but these errors were encountered: