Open rhaschke opened 1 year ago
I am planning to do this recently, will try this code. Thanks.
A small question: is it possible to write python code controlling rqt to switch controllers?
Is it possible to write python code controlling rqt to switch controllers
I don't think so. However, if you switch controllers, rqt's controller_manager plugin should reflect the new state of the controllers.
When switching controllers from the cmdline via
rosservice call /controller_manager/switch_controller ...
it works out of the box. However doing the same from python code always failed silently (response wasok=True
, but controller wasn't started as confirmed via rqt controller_manager plugin). Experimenting a little bit, I noticed that I need to load the controller in advance when switching programmatically. However calling the service from cmdline and from python should be the same, shouldn't it?This works: