6 #ifndef __sot_torque_control_se3_trajectory_generator_H__
7 #define __sot_torque_control_se3_trajectory_generator_H__
14 #if defined(se3_position_controller_EXPORTS)
15 #define SOTSE3TRAJECTORYGENERATOR_EXPORT __declspec(dllexport)
17 #define SOTSE3TRAJECTORYGENERATOR_EXPORT __declspec(dllimport)
20 #define SOTSE3TRAJECTORYGENERATOR_EXPORT
28 #include <parametric-curves/spline.hpp>
30 #include "boost/assign.hpp"
33 #include <dynamic-graph/signal-helper.h>
35 #include <sot/core/matrix-geometry.hh>
48 :
public ::dynamicgraph::Entity {
50 DYNAMIC_GRAPH_ENTITY_DECL();
56 void init(
const double& dt);
71 void playTrajectoryFile(
const std::string& fileName);
73 void setSpline(
const std::string& filename,
const double& timeToInitConf,
74 const Eigen::MatrixXd& init_rotation);
77 void getValue(
const int&
id);
84 void move(
const int&
id,
const double& xFinal,
const double& time);
92 void startSinusoid(
const int&
id,
const double& xFinal,
const double& time);
100 void startTriangle(
const int&
id,
const double& xFinal,
const double& time,
110 void startConstAcc(
const int&
id,
const double& xFinal,
const double& time);
121 void startLinearChirp(
const int&
id,
const double& xFinal,
const double& f0,
122 const double& f1,
const double& time);
128 void stop(
const int&
id);
131 virtual void display(std::ostream& os)
const;
133 void sendMsg(
const std::string& msg, MsgType t = MSG_TYPE_INFO,
134 const char* =
"",
int = 0) {
135 logger_.stream(t) << (
"[SE3TrajectoryGenerator-" + name +
"] " + msg)
void sendMsg(const std::string &msg, MsgType t=MSG_TYPE_INFO, const char *="", int=0)
Eigen::Matrix3d m_splineRotation
DECLARE_SIGNAL_IN(initial_value, dynamicgraph::Vector)
std::vector< SinusoidTrajectoryGenerator * > m_sinTrajGen
DECLARE_SIGNAL_IN(trigger, bool)
double m_t
last iter index
unsigned int m_nv
size of position vector
TextFileTrajectoryGenerator * m_textFileTrajGen
std::vector< LinearChirpTrajectoryGenerator * > m_linChirpTrajGen
unsigned int m_iterLast
size of velocity vector
double m_dt
true if it is the first iteration, false otherwise
std::vector< ConstantAccelerationTrajectoryGenerator * > m_constAccTrajGen
DECLARE_SIGNAL_OUT_FUNCTION(x, dynamicgraph::Vector)
parametriccurves::Spline< double, Eigen::Dynamic > * m_splineTrajGen
DECLARE_SIGNAL_OUT(dx, dynamicgraph::Vector)
std::vector< TG_Status > m_status
bool m_firstIter
true if the entity has been successfully initialized
DECLARE_SIGNAL_OUT(ddx, dynamicgraph::Vector)
std::vector< TriangleTrajectoryGenerator * > m_triangleTrajGen
DECLARE_SIGNAL(x, OUT, dynamicgraph::Vector)
std::vector< NoTrajectoryGenerator * > m_noTrajGen
std::vector< AbstractTrajectoryGenerator * > m_currentTrajGen
status of the component
std::vector< MinimumJerkTrajectoryGenerator * > m_minJerkTrajGen
unsigned int m_np
control loop time period
AdmittanceController EntityClassName
#define SOTSE3TRAJECTORYGENERATOR_EXPORT