sot-torque-control  1.6.5
Collection of dynamic-graph entities aimed at implementing torque control on different robots.
AbstractTrajectoryGenerator Class Referenceabstract

#include <sot/torque_control/utils/trajectory-generators.hh>

Inheritance diagram for AbstractTrajectoryGenerator:

Public Member Functions

 AbstractTrajectoryGenerator (double dt, double traj_time, const Eigen::VectorXd &x_init, const Eigen::VectorXd &x_final)
 
 AbstractTrajectoryGenerator (double dt, double traj_time, Eigen::VectorXd::Index size)
 
virtual const Eigen::VectorXd & compute_next_point ()=0
 
virtual const Eigen::VectorXd & get_final_point ()
 
virtual const Eigen::VectorXd & get_initial_point ()
 
virtual const Eigen::VectorXd & getAcc ()
 
virtual const Eigen::VectorXd & getPos ()
 
virtual const Eigen::VectorXd & getVel ()
 
virtual bool isTrajectoryEnded ()
 
virtual bool set_final_point (const double &x_final)
 
virtual bool set_final_point (const Eigen::VectorXd &x_final)
 
virtual bool set_initial_point (const double &x_init)
 
virtual bool set_initial_point (const Eigen::VectorXd &x_init)
 
virtual bool set_trajectory_time (double traj_time)
 

Protected Member Functions

virtual void resizeAllData (Eigen::VectorXd::Index size)
 
void sendMsg (const std::string &msg, MsgType t=MSG_TYPE_INFO, const char *file="", int line=0)
 

Protected Attributes

Eigen::VectorXd m_ddx
 current velocity More...
 
double m_dt
 time to go from x_init to x_final (sec) More...
 
Eigen::VectorXd m_dx
 current position More...
 
Eigen::VectorXd::Index m_size
 current time More...
 
double m_t
 control dt (sampling period of the trajectory) More...
 
double m_traj_time
 final position More...
 
Eigen::VectorXd m_x
 
Eigen::VectorXd m_x_final
 initial position More...
 
Eigen::VectorXd m_x_init
 current acceleration More...
 

Detailed Description

Definition at line 89 of file trajectory-generators.hh.

Constructor & Destructor Documentation

◆ AbstractTrajectoryGenerator() [1/2]

AbstractTrajectoryGenerator ( double  dt,
double  traj_time,
Eigen::VectorXd::Index  size 
)
inline

Definition at line 117 of file trajectory-generators.hh.

◆ AbstractTrajectoryGenerator() [2/2]

AbstractTrajectoryGenerator ( double  dt,
double  traj_time,
const Eigen::VectorXd &  x_init,
const Eigen::VectorXd &  x_final 
)
inline

Definition at line 125 of file trajectory-generators.hh.

Member Function Documentation

◆ compute_next_point()

◆ get_final_point()

virtual const Eigen::VectorXd& get_final_point ( )
inlinevirtual

Definition at line 179 of file trajectory-generators.hh.

◆ get_initial_point()

virtual const Eigen::VectorXd& get_initial_point ( )
inlinevirtual

Definition at line 178 of file trajectory-generators.hh.

◆ getAcc()

virtual const Eigen::VectorXd& getAcc ( )
inlinevirtual

Definition at line 177 of file trajectory-generators.hh.

◆ getPos()

virtual const Eigen::VectorXd& getPos ( )
inlinevirtual

Definition at line 175 of file trajectory-generators.hh.

◆ getVel()

virtual const Eigen::VectorXd& getVel ( )
inlinevirtual

Definition at line 176 of file trajectory-generators.hh.

◆ isTrajectoryEnded()

virtual bool isTrajectoryEnded ( )
inlinevirtual

◆ resizeAllData()

virtual void resizeAllData ( Eigen::VectorXd::Index  size)
inlineprotectedvirtual

Definition at line 102 of file trajectory-generators.hh.

◆ sendMsg()

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

Definition at line 111 of file trajectory-generators.hh.

◆ set_final_point() [1/2]

virtual bool set_final_point ( const double &  x_final)
inlinevirtual

Definition at line 161 of file trajectory-generators.hh.

◆ set_final_point() [2/2]

virtual bool set_final_point ( const Eigen::VectorXd &  x_final)
inlinevirtual

Definition at line 155 of file trajectory-generators.hh.

◆ set_initial_point() [1/2]

virtual bool set_initial_point ( const double &  x_init)
inlinevirtual

Definition at line 146 of file trajectory-generators.hh.

◆ set_initial_point() [2/2]

virtual bool set_initial_point ( const Eigen::VectorXd &  x_init)
inlinevirtual

Definition at line 137 of file trajectory-generators.hh.

◆ set_trajectory_time()

virtual bool set_trajectory_time ( double  traj_time)
inlinevirtual

Reimplemented in ConstantAccelerationTrajectoryGenerator.

Definition at line 167 of file trajectory-generators.hh.

Member Data Documentation

◆ m_ddx

Eigen::VectorXd m_ddx
protected

current velocity

Definition at line 93 of file trajectory-generators.hh.

◆ m_dt

double m_dt
protected

time to go from x_init to x_final (sec)

Definition at line 98 of file trajectory-generators.hh.

◆ m_dx

Eigen::VectorXd m_dx
protected

current position

Definition at line 92 of file trajectory-generators.hh.

◆ m_size

Eigen::VectorXd::Index m_size
protected

current time

Definition at line 100 of file trajectory-generators.hh.

◆ m_t

double m_t
protected

control dt (sampling period of the trajectory)

Definition at line 99 of file trajectory-generators.hh.

◆ m_traj_time

double m_traj_time
protected

final position

Definition at line 97 of file trajectory-generators.hh.

◆ m_x

Eigen::VectorXd m_x
protected

Definition at line 91 of file trajectory-generators.hh.

◆ m_x_final

Eigen::VectorXd m_x_final
protected

initial position

Definition at line 95 of file trajectory-generators.hh.

◆ m_x_init

Eigen::VectorXd m_x_init
protected

current acceleration

Definition at line 94 of file trajectory-generators.hh.


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