11 #ifndef __SOT_com_impedance_Control_HH__ 12 #define __SOT_com_impedance_Control_HH__ 19 #include <dynamic-graph/linear-algebra.h> 25 #include <eigen-quadprog/QuadProg.h> 27 #include <dynamic-graph/signal-time-dependent.h> 28 #include <dynamic-graph/signal-ptr.h> 29 #include <dynamic-graph/entity.h> 46 void init(
const double& step){};
50 static const double TIME_STEP_DEFAULT;
54 static const std::string CLASS_NAME;
55 virtual const std::string& getClassName(
void )
const {
return CLASS_NAME;}
59 SignalPtr<dg::Vector, int> KpSIN;
60 SignalPtr<dg::Vector, int> KpAngSIN;
61 SignalPtr<dg::Vector, int> KdAngSIN;
62 SignalPtr<dg::Vector, int> KdSIN;
63 SignalPtr<dg::Vector, int> positionSIN;
64 SignalPtr<dg::Vector, int> desiredpositionSIN;
65 SignalPtr<dg::Vector, int> biasedpositionSIN;
66 SignalPtr<dg::Vector, int> velocitySIN;
67 SignalPtr<dg::Vector, int> desiredvelocitySIN;
68 SignalPtr<dg::Vector, int> biasedvelocitySIN;
69 SignalPtr<dg::Vector, int> inertiaSIN;
70 SignalPtr<dg::Vector, int> massSIN;
71 SignalPtr<dg::Vector, int> oriSIN;
72 SignalPtr<dg::Vector, int> desoriSIN;
73 SignalPtr<dg::Vector, int> angvelSIN;
74 SignalPtr<dg::Vector, int> desiredangvelSIN;
75 SignalPtr<dg::Vector, int> feedforwardforceSIN;
76 SignalPtr<dg::Vector, int> feedforwardtorquesSIN;
77 SignalPtr<dg::Vector, int> cntsensorSIN;
78 SignalPtr<dg::Vector, int> thrcntvalueSIN;
79 SignalPtr<dg::Vector, int> lqrerrorSIN;
80 SignalPtr<dg::Vector, int> lqrgainSIN;
81 SignalPtr<dg::Vector, int> lctrlSIN;
82 SignalPtr<dg::Vector, int> actrlSIN;
83 SignalPtr<dg::Matrix, int> hessSIN;
84 SignalPtr<dg::Vector, int> g0SIN;
85 SignalPtr<dg::Matrix, int> ceSIN;
87 SignalPtr<dg::Matrix, int> ciSIN;
88 SignalPtr<dg::Vector, int> ci0SIN;
89 SignalPtr<dg::Matrix, int> regSIN;
91 SignalPtr<dg::Vector, int> absendeffposSIN;
92 SignalPtr<dg::Vector, int> absendeffvelSIN;
97 SignalPtr<dg::Vector, int> leglengthhlSIN;
99 SignalTimeDependent<dg::Vector, int> controlSOUT;
100 SignalTimeDependent<dg::Vector, int> angcontrolSOUT;
101 SignalTimeDependent<dg::Vector, int> SetPosBiasSOUT;
102 SignalTimeDependent<dg::Vector, int> SetVelBiasSOUT;
103 SignalTimeDependent<dg::Vector, int> ThrCntSensorSOUT;
104 SignalTimeDependent<dg::Vector, int> lqrcontrolSOUT;
105 SignalTimeDependent<dg::Vector, int> endefflqrcontrolSOUT;
106 SignalTimeDependent<dg::Vector, int> wbcontrolSOUT;
108 SignalTimeDependent<dg::Vector, int> descomposSOUT;
114 double& setsize(
int dimension);
115 dg::Vector& return_control_torques( dg::Vector& tau,
int t);
116 dg::Vector& return_angcontrol_torques( dg::Vector& angtau,
int t);
117 dg::Vector& set_pos_bias(dg::Vector& pos_bias,
int t);
118 dg::Vector& set_vel_bias(dg::Vector& vel_bias,
int t);
119 dg::Vector& threshold_cnt_sensor(dg::Vector& thr_cnt_sensor,
int t);
122 dg::Vector& compute_end_eff_forces( dg::Vector & end_forces,
int t);
123 dg::Vector& compute_des_com_pos( dg::Vector & des_com_pos,
int t);
126 dg::Vector pos_error;
127 dg::Vector vel_error;
129 dg::Vector ori_error;
131 dg::Vector position_bias;
132 dg::Vector velocity_bias;
138 dg::Vector end_forces;
146 Eigen::QuadProgDense qp;
148 Eigen::Quaternion<double> ori_quat;
149 Eigen::Quaternion<double> des_ori_quat;
150 Eigen::Quaternion<double> ori_error_quat;
153 Eigen::Matrix<double, 3, 3> ori_se3;
154 Eigen::Matrix<double, 3, 3> des_ori_se3;
155 Eigen::Matrix<double, 3, 3> ori_error_se3;
162 Eigen::VectorXd delta_x;
163 Eigen::Vector3d lqr_pos_error;
164 Eigen::Vector3d lqr_vel_error;
165 Eigen::Vector4d lqr_ori_error;
166 Eigen::Vector3d lqr_ang_vel_error;
167 Eigen::VectorXd f_des;
dg::Vector & return_end_eff_lqr_tau(dg::Vector &end_eff_lqr_tau, int t)
Definition: com_impedance_controller.cpp:274
dg::Vector & return_lqr_tau(dg::Vector &lqrtau, int t)
Definition: com_impedance_controller.cpp:110
SignalPtr< dg::Vector, int > leglengthflSIN
for balancing taks on a planck
Definition: ComImpedanceController.hpp:96
Definition: ComImpedanceController.hpp:37
Definition: ComImpedanceController.hpp:31