7 bool usingInterprocessCommunication,
9 : controllerType(ctrlType)
11 , usingComs(usingInterprocessCommunication)
12 , usingOdometry(useOdometry)
36 std::cout <<
"Using QuadProg++ "<<std::endl;
37 internalSolver = std::make_shared<ocra::OneLevelSolverWithQuadProg>();
42 std::cout <<
"Using qpOASES"<<std::endl;
43 internalSolver = std::make_shared<ocra::OneLevelSolverWithQPOASES>();
48 std::cout <<
"Using qpOASES [Default]"<<std::endl;
49 internalSolver = std::make_shared<ocra::OneLevelSolverWithQPOASES>();
58 std::cout <<
"Constructing a WOCRA Controller "<<std::endl;
59 bool useReducedProblem =
false;
65 std::cout <<
"Constructing a HOCRA Controller "<<std::endl;
66 bool useReducedProblem =
false;
72 std::cout <<
"Constructing a WOCRA Controller [Default]"<<std::endl;
73 bool useReducedProblem =
false;
83 res &=
statesPort.open(
"/ControllerServer/states:o");
93 if (!
model->hasFixedRoot()) {
116 if (
model->hasFixedRoot()){
122 OCRA_ERROR(
"Couldn't write robot state for client. Not really doing anything about it, except reporting.");
Eigen::Displacementd H_root
ControllerServer(CONTROLLER_TYPE ctrlType, SOLVER_TYPE solver, bool usingInterprocessCommunication=true, bool useOdometry=false)
ocra::Controller::Ptr controller
ocra::Solver::Ptr internalSolver
ServerCommunications::Ptr serverComs
void setRegularizationTermWeights(double wDdq, double wTau, double wFc)
virtual ~ControllerServer()
const Eigen::VectorXd & computeTorques()
bool addTasks(std::vector< ocra::TaskBuilderOptions > &tmOpts)
virtual std::shared_ptr< Model > loadRobotModel()=0
CONTROLLER_TYPE controllerType
virtual void getRobotState(Eigen::VectorXd &q, Eigen::VectorXd &qd, Eigen::Displacementd &H_root, Eigen::Twistd &T_root)=0
yarp::os::Port statesPort
A generic abstract class the solvers that can be used in the wOcra Controller.
Wocra Controller based on LQP solver for the ocra framework.
bool addTasksFromXmlFile(const std::string &filePath)
A portable class for sending robot state information over yarp.