SCL
1.0
Standard Control Library : Control, dynamics, physics, and simulation
|
#include <CTaskBase.hpp>
Public Member Functions | |
virtual bool | computeServo (const SRobotSensors *arg_sensors)=0 |
virtual bool | computeModel (const SRobotSensors *arg_sensors)=0 |
virtual STaskBase * | getTaskData ()=0 |
virtual bool | setGoalPos (const Eigen::VectorXd &arg_goal) |
virtual bool | setGoalVel (const Eigen::VectorXd &arg_goal) |
virtual bool | setGoalAcc (const Eigen::VectorXd &arg_goal) |
virtual bool | getGoalPos (Eigen::VectorXd &arg_goal) const |
virtual bool | getGoalVel (Eigen::VectorXd &arg_goal) const |
virtual bool | getGoalAcc (Eigen::VectorXd &arg_goal) const |
virtual bool | getPos (Eigen::VectorXd &arg_pos) const |
virtual bool | getVel (Eigen::VectorXd &arg_vel) const |
virtual bool | getAcc (Eigen::VectorXd &arg_acc) const |
CTaskBase () | |
virtual | ~CTaskBase () |
virtual bool | init (STaskBase *arg_task_data, CDynamicsBase *arg_dynamics)=0 |
virtual void | reset ()=0 |
virtual sBool | hasBeenInit () |
virtual sBool | setActivated (sBool arg_activate) |
virtual sBool | hasBeenActivated () |
Protected Attributes | |
sBool | has_been_init_ |
CDynamicsBase * | dynamics_ |
Container class to encapsulate a task model and a task servo.
NOTE : Virtual class. Subclass and implement functions that compute the task forces.
|
inline |
Constructor does nothing
|
inlinevirtual |
Destructor does nothing
|
pure virtual |
Computes the dynamics (task model)
Implemented in scl::CTaskOpPosNoGravity, scl::CTaskOpPosContactForce, scl::CTaskOpPosPIDA1OrderInfTime, scl::CTaskNULL, scl::CTaskOpPos, scl::CTaskGcSet, scl::CTaskComPos, scl::CTaskGcLimitCentering, scl::CTaskNullSpaceDamping, and scl::CTaskGc.
|
pure virtual |
Computes the task torques
Implemented in scl::CTaskOpPosNoGravity, scl::CTaskOpPosContactForce, scl::CTaskOpPosPIDA1OrderInfTime, scl::CTaskNULL, scl::CTaskOpPos, scl::CTaskGcSet, scl::CTaskComPos, scl::CTaskGcLimitCentering, scl::CTaskNullSpaceDamping, and scl::CTaskGc.
|
inlinevirtual |
Gets the current acceleration. Returns false if not supported by task.
Reimplemented in scl::CTaskOpPosPIDA1OrderInfTime, scl::CTaskOpPos, and scl::CTaskComPos.
|
inlinevirtual |
Gets the current goal acceleration. Returns false if not supported by task.
Reimplemented in scl::CTaskOpPosPIDA1OrderInfTime, scl::CTaskOpPos, scl::CTaskGcSet, scl::CTaskComPos, and scl::CTaskGc.
|
inlinevirtual |
Gets the current goal position. Returns false if not supported by task.
Reimplemented in scl::CTaskOpPosPIDA1OrderInfTime, scl::CTaskOpPos, scl::CTaskGcSet, scl::CTaskComPos, scl::CTaskGcLimitCentering, and scl::CTaskGc.
|
inlinevirtual |
Gets the current goal velocity. Returns false if not supported by task.
Reimplemented in scl::CTaskOpPosPIDA1OrderInfTime, scl::CTaskOpPos, scl::CTaskGcSet, scl::CTaskComPos, and scl::CTaskGc.
|
inlinevirtual |
Gets the current position. Returns false if not supported by task.
Reimplemented in scl::CTaskOpPosPIDA1OrderInfTime, scl::CTaskOpPos, scl::CTaskComPos, and scl::CTaskGcLimitCentering.
|
pure virtual |
Return this task controller's task data structure. Use it responsibly! NOTE : Use dynamic casts whenever you downcast the data. And try not to downcast very often. Perf hit.
Implemented in scl::CTaskOpPosPIDA1OrderInfTime, scl::CTaskOpPos, scl::CTaskGcSet, scl::CTaskOpPosNoGravity, scl::CTaskComPos, scl::CTaskOpPosContactForce, scl::CTaskNULL, scl::CTaskNullSpaceDamping, scl::CTaskGc, and scl::CTaskGcLimitCentering.
|
inlinevirtual |
Gets the current velocity. Returns false if not supported by task.
Reimplemented in scl::CTaskOpPosPIDA1OrderInfTime, scl::CTaskOpPos, and scl::CTaskComPos.
|
inlinevirtual |
Activated = All dynamic parameters and data structures are up to date and task is actively contributing to a controller.
|
inlinevirtual |
Initialized = All static parameters are set and data structures are up to date. Ready to contribute to a controller.
|
pure virtual |
Initializes the task object. Create a subclass of STaskBase if your task requires more data than the defaults in STaskBase provide. This function should set has_been_init_ to true
Implemented in scl::CTaskOpPosPIDA1OrderInfTime, scl::CTaskOpPos, scl::CTaskComPos, scl::CTaskGcSet, scl::CTaskGc, scl::CTaskNullSpaceDamping, scl::CTaskOpPosContactForce, scl::CTaskOpPosNoGravity, scl::CTaskNULL, and scl::CTaskGcLimitCentering.
|
pure virtual |
Resets the task by removing its data.
Implemented in scl::CTaskOpPosPIDA1OrderInfTime, scl::CTaskOpPos, scl::CTaskComPos, scl::CTaskGcSet, scl::CTaskGc, scl::CTaskOpPosNoGravity, scl::CTaskNullSpaceDamping, scl::CTaskOpPosContactForce, scl::CTaskNULL, and scl::CTaskGcLimitCentering.
Activated = All dynamic parameters and data structures are up to date and task is actively contributing to a controller.
Set to true/false during runtime to activate/deactivate task.
Returns : success/failure
|
inlinevirtual |
Sets the current goal acceleration. Returns false if not supported by task.
Reimplemented in scl::CTaskOpPosContactForce, scl::CTaskOpPosPIDA1OrderInfTime, scl::CTaskOpPos, scl::CTaskGcSet, scl::CTaskComPos, and scl::CTaskGc.
|
inlinevirtual |
Sets the current goal position. Returns false if not supported by task.
Reimplemented in scl::CTaskOpPosPIDA1OrderInfTime, scl::CTaskOpPos, scl::CTaskGcSet, scl::CTaskComPos, scl::CTaskGcLimitCentering, and scl::CTaskGc.
|
inlinevirtual |
Sets the current goal velocity. Returns false if not supported by task.
Reimplemented in scl::CTaskOpPosContactForce, scl::CTaskOpPosPIDA1OrderInfTime, scl::CTaskOpPos, scl::CTaskGcSet, scl::CTaskComPos, and scl::CTaskGc.
|
protected |
A Dynamics model required to compute the task's dynamics
|
protected |
Initialized = All static parameters are set and data structures are up to date.
Set to true in init()