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
Controller Manager has an additional parameter that describes how controllers are chained.
70
-
In the first version, the parameter-structure would have some semantic meaning embedded into it, as follows:
71
-
72
-
73
-
.. code-block:: yaml
74
-
75
-
controller_manager:
76
-
ros__parameters:
77
-
chained_controllers:
78
-
79
-
- parallel_group_1:
80
-
- controller1_1
81
-
- controller1_2
82
-
83
-
- parallel_group_2:
84
-
- controller2_1
85
-
86
-
- parallel_group_3:
87
-
- controller3_1
88
-
- controller3_2
89
-
- controller3_3
90
-
91
-
...
92
-
93
-
- parallel_group_N:
94
-
- controllerN_1
95
-
- ...
96
-
- controllerN_M
97
-
98
-
99
-
100
-
This structure is motivated by ``filter_chain`` structure from `ros/filters repository <https://github.com/ros/filters/tree/ros2>`__, see `this file for implementation <https://github.com/ros/filters/blob/ros2/include/filters/filter_chain.hpp>`__.
101
-
102
-
This structure is stored internally by controller manager into an ordered map (``std::map<std::string, std::vector<std::string>>``) with group name as key.
103
-
When a controller should be deactivated, the controller manager deactivates all the controllers in the preceding groups first.
104
-
All other controllers from the group stay active, as well as all controllers in the following groups.
105
-
NOTE: In the future this could be done more intelligently, i.e., deactivate only controllers in the preceding groups that actually precede the controller that should be deactivated.
106
-
107
-
On the other hand, the controller should be manually activated in the reverse order, i.e., from the those closer to the hardware toward those preceding them.
70
+
Chained controllers must be activated and deactivated together or in the proper order.
71
+
This means you must first activate all following controllers to have the preceding one activated.
72
+
For the deactivation there is the inverse rule - all preceding controllers have to be deactivated before the following controller is deactivated.
73
+
One can also think of it as an actual chain, you can not add a chain link or break the chain in the middle.
0 commit comments