SCL  1.0
Standard Control Library : Control, dynamics, physics, and simulation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Friends Macros Groups Pages
Public Member Functions | Protected Attributes | List of all members
scl::CControllerGc Class Reference

#include <CControllerGc.hpp>

Inheritance diagram for scl::CControllerGc:
Inheritance graph
[legend]
Collaboration diagram for scl::CControllerGc:
Collaboration graph
[legend]

Public Member Functions

 CControllerGc ()
 
virtual ~CControllerGc ()
 
virtual sBool computeControlForces ()
 
virtual sBool computeKinematics ()
 
virtual sBool computeDynamics ()
 
virtual sBool computeNonControlOperations ()
 
virtual const Eigen::VectorXd * getControlForces ()
 
virtual sBool init (SControllerBase *arg_data, scl::CDynamicsBase *arg_dynamics)
 
virtual sBool reset ()
 
virtual sBool hasBeenInit ()
 
sBool computeControlForcesPD ()
 
sBool computeControlForcesPIDA (const sFloat arg_time)
 
sBool computeFloatForces ()
 

Protected Attributes

SControllerGcdata_
 
sBool has_been_init_
 
CDynamicsBasedynamics_
 

Detailed Description

A generic generalized coordinate space force controller.

Requires set points for position and velocity. Optionally, can also use acceleration set points and can introduce integral gain.

This controller's advantage is its simplicity. It's disadvantage is that it is usually hard trajectories in the generalized coordinates. Moreover, for redundant robots, such trajectories are energy sub-optimal and require controlling motor task null spaces, which may be superfluous.

Constructor & Destructor Documentation

scl::CControllerGc::CControllerGc ( )

The constructor does nothing

scl::CControllerGc::~CControllerGc ( )
virtual

The destructor does nothing

Member Function Documentation

sBool scl::CControllerGc::computeControlForces ( )
virtual

[PDA] : Computes generalized coordinate forces. Uses position, velocity and acceleration set points and gains.

Does not use integral gain by default. To get an integral gain controller look at computeControlForcesPIDA()

Implements scl::CControllerBase.

sBool scl::CControllerGc::computeControlForcesPD ( )

[PD] : Dynamic decoupling + PD controller on decoupled closed loop system in the generalized coordinates.

Does not include acceleration set points or integral gain.

sBool scl::CControllerGc::computeControlForcesPIDA ( const sFloat  arg_time)

[PIDA] : Dynamic decoupling + PIDA controller on decoupled closed loop system in the generalized coordinates.

Includes acceleration set points and integral gain.

Implements the following 1st order, infinite time horizon integrator: Force = Force + ki * pos_err * (t_curr - t_pre);

arg_time : The current time. Required to compute integral gain term.

sBool scl::CControllerGc::computeDynamics ( )
virtual

Computes the dynamic model : Mass, MassInv, centrifugal/coriolis, gravity

Following Khatib's convention : A and Ainv matrices + b and g vectors

Implements scl::CControllerBase.

sBool scl::CControllerGc::computeFloatForces ( )

Controller that only compensates for gravity: Gravity compensation + damping

virtual sBool scl::CControllerGc::computeKinematics ( )
inlinevirtual

Computes the kinematic model : Jacobian

This function does nothing in GcControllers. For the curious : The jacobian for a generalized coordinate force controllers is the identity matrix

virtual sBool scl::CControllerGc::computeNonControlOperations ( )
inlinevirtual

Support for non control computations in the controller. This is really basic controller and does nothing here. Subclasses might consider adding stuff to this function..

Implements scl::CControllerBase.

const Eigen::VectorXd * scl::CControllerGc::getControlForces ( )
virtual

Returns the current control forces

virtual sBool scl::CControllerGc::hasBeenInit ( )
inlinevirtual

Whether the controller has been attached to a robot or not

Reimplemented from scl::CControllerBase.

sBool scl::CControllerGc::init ( SControllerBase arg_data,
scl::CDynamicsBase arg_dynamics 
)
virtual

Whether the controller has been initialized to a particular robot

Implements scl::CControllerBase.

sBool scl::CControllerGc::reset ( )
virtual

Reset the controller (set it to execute a different behavior perhaps)

Implements scl::CControllerBase.


The documentation for this class was generated from the following files: