How to aggregate command hardware interfaces in ros_control?
I would like to know what workarounds can be used to allow a controller to command more than one hardware interface in ros_control. The hardware interfaces could be homogeneous or heterogeneous (e.g. VelocityJointInterface
+ PositionJointInterface
+ MyCustomInterface
). I am looking for a solution that does not involve creating a new hardware interface with gigantic handles. There is a workaround here for the case where only one hardware interface sends commands, but it might not work for our particular case.
One of our applications for this is a mobile manipulator where the arm has velocity and position hardware interfaces, and the base has a velocity hardware interface. We would like to control both the arm and the base within the same controller.
To get familiar with ros_control, we developed the control architecture for the arm first. The RobotHW
specialization has a VelocityJointInterface
and a PosVelJointInterface
for visual servoing/joystick and trajectory tracking control modes, respectively. The design of the architecture is such that several components (e.g. arm + base) can be aggregated in a single RobotHW
specialization. Now we are facing the difficulty of aggregating hardware interfaces at the controller level. So I would like to know what other people have done on similar scenarios.