Reference: OpenRAVE::ControllerBase
In order for openrave to control certain robot hardware, a OpenRAVE::ControllerBase controller has to be created that will interface with the hardware-specific libraries. This controller interface then has to be created through the environment and set onto an existing robot. All commands given to the robot are first filtered through the controller, then translated to joint commands. Different controllers can have different path inputs (ie: a robot walking on a floor might just have x,y,angle), but the default is the DOF joint values.
Assuming that there exists a plugin with a controller interface named MyController, here are some ways to set an openrave robot to use it:
<robot file="robots/schunk-lwa3.robot.xml"> <controller type="MyController controller arguments here"></controller> </robot>
<environment> <robot name="schunk-lwa3" file="robots/schunk-lwa3.robot.xml"> </robot> <controller type="MyController" robot="schunk-lwa3 controller arguments here"></controller> </environment>
robotid = orEnvGetBody('schunk-lwa3'); orRobotControllerSet(robotid,'MyController','controller arguments here')