sot-torque-control  1.6.2
Collection of dynamic-graph entities aimed at implementing torque control on different robots.
PositionController Class Reference

#include <sot/torque_control/position-controller.hh>

Inheritance diagram for PositionController:
Collaboration diagram for PositionController:

Public Member Functions

EIGEN_MAKE_ALIGNED_OPERATOR_NEW PositionController (const std::string &name)
 
 DECLARE_SIGNAL_IN (base6d_encoders, dynamicgraph::Vector)
 
 DECLARE_SIGNAL_IN (jointsVelocities, dynamicgraph::Vector)
 
 DECLARE_SIGNAL_IN (qRef, dynamicgraph::Vector)
 
 DECLARE_SIGNAL_IN (dqRef, dynamicgraph::Vector)
 
 DECLARE_SIGNAL_IN (Kp, dynamicgraph::Vector)
 
 DECLARE_SIGNAL_IN (Kd, dynamicgraph::Vector)
 joint proportional gains More...
 
 DECLARE_SIGNAL_IN (Ki, dynamicgraph::Vector)
 joint derivative gains More...
 
 DECLARE_SIGNAL_OUT (pwmDes, dynamicgraph::Vector)
 joint integral gains More...
 
 DECLARE_SIGNAL_OUT (qError, dynamicgraph::Vector)
 Kp*e_q + Kd*de_q + Ki*int(e_q) More...
 
virtual void display (std::ostream &os) const
 qRef-q More...
 
void init (const double &dt, const std::string &robotRef)
 
void resetIntegral ()
 
void sendMsg (const std::string &msg, MsgType t=MSG_TYPE_INFO, const char *="", int=0)
 

Protected Attributes

Eigen::VectorXd m_dq
 
double m_dt
 true if the entity has been successfully initialized More...
 
Eigen::VectorXd m_e_integral
 control loop time period More...
 
bool m_initSucceeded
 
Eigen::VectorXd m_pwmDes
 Robot Util. More...
 
Eigen::VectorXd m_q
 
RobotUtilShrPtr m_robot_util
 

Detailed Description

Definition at line 47 of file position-controller.hh.

Constructor & Destructor Documentation

◆ PositionController()

PositionController ( const std::string &  name)

Definition at line 42 of file position-controller.cpp.

Member Function Documentation

◆ DECLARE_SIGNAL_IN() [1/7]

DECLARE_SIGNAL_IN ( base6d_encoders  ,
dynamicgraph::Vector   
)

◆ DECLARE_SIGNAL_IN() [2/7]

DECLARE_SIGNAL_IN ( jointsVelocities  ,
dynamicgraph::Vector   
)

◆ DECLARE_SIGNAL_IN() [3/7]

DECLARE_SIGNAL_IN ( qRef  ,
dynamicgraph::Vector   
)

◆ DECLARE_SIGNAL_IN() [4/7]

DECLARE_SIGNAL_IN ( dqRef  ,
dynamicgraph::Vector   
)

◆ DECLARE_SIGNAL_IN() [5/7]

DECLARE_SIGNAL_IN ( Kp  ,
dynamicgraph::Vector   
)

◆ DECLARE_SIGNAL_IN() [6/7]

DECLARE_SIGNAL_IN ( Kd  ,
dynamicgraph::Vector   
)

joint proportional gains

◆ DECLARE_SIGNAL_IN() [7/7]

DECLARE_SIGNAL_IN ( Ki  ,
dynamicgraph::Vector   
)

joint derivative gains

◆ DECLARE_SIGNAL_OUT() [1/2]

DECLARE_SIGNAL_OUT ( pwmDes  ,
dynamicgraph::Vector   
)

joint integral gains

◆ DECLARE_SIGNAL_OUT() [2/2]

DECLARE_SIGNAL_OUT ( qError  ,
dynamicgraph::Vector   
)

Kp*e_q + Kd*de_q + Ki*int(e_q)

◆ display()

void display ( std::ostream &  os) const
virtual

qRef-q

Definition at line 166 of file position-controller.cpp.

◆ init()

void init ( const double &  dt,
const std::string &  robotRef 
)

Definition at line 65 of file position-controller.cpp.

◆ resetIntegral()

void resetIntegral ( )

Definition at line 97 of file position-controller.cpp.

◆ sendMsg()

void sendMsg ( const std::string &  msg,
MsgType  t = MSG_TYPE_INFO,
const char *  = "",
int  = 0 
)
inline

Definition at line 78 of file position-controller.hh.

Member Data Documentation

◆ m_dq

Eigen::VectorXd m_dq
protected

Definition at line 91 of file position-controller.hh.

◆ m_dt

double m_dt
protected

true if the entity has been successfully initialized

Definition at line 86 of file position-controller.hh.

◆ m_e_integral

Eigen::VectorXd m_e_integral
protected

control loop time period

Integral of the joint tracking errors

Definition at line 89 of file position-controller.hh.

◆ m_initSucceeded

bool m_initSucceeded
protected

Definition at line 85 of file position-controller.hh.

◆ m_pwmDes

Eigen::VectorXd m_pwmDes
protected

Robot Util.

Definition at line 84 of file position-controller.hh.

◆ m_q

Eigen::VectorXd m_q
protected

Definition at line 91 of file position-controller.hh.

◆ m_robot_util

RobotUtilShrPtr m_robot_util
protected

Definition at line 83 of file position-controller.hh.


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