22 #ifndef __MINJERKCTRL_H__
23 #define __MINJERKCTRL_H__
28 #include <yarp/os/Property.h>
29 #include <yarp/sig/Vector.h>
30 #include <yarp/sig/Matrix.h>
59 virtual yarp::sig::Vector
computeCmd(
const double _T,
const yarp::sig::Vector &
e) = 0;
65 virtual void reset(
const yarp::sig::Vector &u0) = 0;
111 virtual yarp::sig::Vector
computeCmd(
const double _T,
const yarp::sig::Vector &
e);
117 virtual void reset(
const yarp::sig::Vector &u0);
142 yarp::sig::Vector
Kp;
143 yarp::sig::Vector
Tz;
144 yarp::sig::Vector
Tw;
146 std::deque<ctrl::Filter*>
F;
169 virtual yarp::sig::Vector
computeCmd(
const double _T,
const yarp::sig::Vector &
e);
175 virtual void reset(
const yarp::sig::Vector &u0);
195 const std::string &entryTag=
"dimension",
196 const yarp::os::Bottle &ordering=yarp::os::Bottle());
213 const std::string &entryTag=
"dimension");
253 minJerkBaseGen(
const unsigned int _dim,
const double _Ts,
const double _T);
287 virtual void init(
const yarp::sig::Vector &y0);
328 bool setT(
const double _T);
335 bool setTs(
const double _Ts);
364 minJerkTrajGen(
const unsigned int _dim,
const double _Ts,
const double _T);
419 minJerkRefGen(
const unsigned int _dim,
const double _Ts,
const double _T);
428 minJerkRefGen(
const yarp::sig::Vector &y0,
const double _Ts,
const double _T);
456 const yarp::sig::Vector &yd);
Base class for minimum jerk generators.
minJerkBaseGen(const yarp::sig::Vector &y0, const double _Ts, const double _T)
Constructor with initial value.
virtual void computeCoeffs()=0
minJerkBaseGen(const unsigned int _dim, const double _Ts, const double _T)
Constructor.
double getT() const
Get the trajectory reference time in seconds (90% of steady-state value in t=_T, transient extinguish...
virtual ~minJerkBaseGen()
Destructor.
minJerkBaseGen & operator=(const minJerkBaseGen &z)
Assignment operator.
bool setT(const double _T)
Set the trajectory reference time (90% of steady-state value in t=_T, transient extinguished for t>=1...
const yarp::sig::Vector & getVel() const
Get the current velocity.
const yarp::sig::Vector & getAcc() const
Get the current acceleration.
const yarp::sig::Vector & getPos() const
Get the current position.
double getTs() const
Get the sample time in seconds.
yarp::sig::Vector lastRef
bool setTs(const double _Ts)
Set the sample time.
virtual void init(const yarp::sig::Vector &y0)
Initialize the trajectory.
virtual void computeNextValues(const yarp::sig::Vector &yd)=0
Compute the next position, velocity and acceleration.
Generator of position, velocity and acceleration references that are approximately minimum jerk.
void computeNextValues(const yarp::sig::Vector &y)
Computes the position, velocity and acceleration references.
minJerkRefGen(const unsigned int _dim, const double _Ts, const double _T)
Constructor.
minJerkRefGen(const yarp::sig::Vector &y0, const double _Ts, const double _T)
Constructor with initial value.
minJerkRefGen & operator=(const minJerkRefGen &z)
Assignment operator.
Generator of approximately minimum jerk trajectories.
minJerkTrajGen & operator=(const minJerkTrajGen &z)
Assignment operator.
virtual void computeCoeffs()
minJerkTrajGen(const yarp::sig::Vector &y0, const double _Ts, const double _T)
Constructor with initial value.
void computeNextValues(const yarp::sig::Vector &yd)
Compute the next position, velocity and acceleration.
minJerkTrajGen(const unsigned int _dim, const double _Ts, const double _T)
Constructor.
Implements a minimum-jerk controller with velocity commands in the assumption that the plant can be m...
virtual void reset(const yarp::sig::Vector &u0)
Resets the controller to a given value.
virtual ~minJerkVelCtrlForIdealPlant()
Destructor.
virtual void computeCoeffs()
virtual yarp::sig::Vector computeCmd(const double _T, const yarp::sig::Vector &e)
Computes the velocity command.
Implements a minimum-jerk controller with velocity commands assuming a non ideal plant represented wi...
virtual void computeCoeffs()
virtual yarp::sig::Vector computeCmd(const double _T, const yarp::sig::Vector &e)
Computes the velocity command.
virtual ~minJerkVelCtrlForNonIdealPlant()
Destructor.
virtual void reset(const yarp::sig::Vector &u0)
Resets the controller to a given value.
std::deque< ctrl::Filter * > F
virtual void setPlantParameters(const yarp::os::Property ¶meters, const std::string &entryTag="dimension", const yarp::os::Bottle &ordering=yarp::os::Bottle())
Allows user to assign values to plant parameters.
virtual void getPlantParameters(yarp::os::Property ¶meters, const std::string &entryTag="dimension")
Allows user to retrieve plant parameters.
Abstract class for minimum-jerk controllers with velocity commands.
virtual void reset(const yarp::sig::Vector &u0)=0
Resets the controller to a given value.
virtual yarp::sig::Vector computeCmd(const double _T, const yarp::sig::Vector &e)=0
Computes the velocity command.
virtual ~minJerkVelCtrl()
Destructor.
virtual void computeCoeffs()=0
This file contains the definition of unique IDs for the body parts and the skin parts of the robot.