6 #ifndef __sot_torque_control_admittance_controller_H__
7 #define __sot_torque_control_admittance_controller_H__
14 #if defined(sot_admittance_controller_EXPORTS)
15 #define SOTADMITTANCECONTROLLER_EXPORT __declspec(dllexport)
17 #define SOTADMITTANCECONTROLLER_EXPORT __declspec(dllimport)
20 #define SOTADMITTANCECONTROLLER_EXPORT
28 #include "boost/assign.hpp"
30 #include <tsid/robots/robot-wrapper.hpp>
31 #include <tsid/tasks/task-se3-equality.hpp>
34 #include <dynamic-graph/signal-helper.h>
35 #include <sot/core/matrix-geometry.hh>
36 #include <sot/core/robot-utils.hh>
48 DYNAMIC_GRAPH_ENTITY_DECL();
51 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
56 void init(
const double& dt,
const std::string& robotRef);
59 DECLARE_SIGNAL_IN(encoders, dynamicgraph::Vector);
60 DECLARE_SIGNAL_IN(jointsVelocities, dynamicgraph::Vector);
61 DECLARE_SIGNAL_IN(kp_force, dynamicgraph::Vector);
62 DECLARE_SIGNAL_IN(ki_force, dynamicgraph::Vector);
63 DECLARE_SIGNAL_IN(kp_vel, dynamicgraph::Vector);
64 DECLARE_SIGNAL_IN(ki_vel, dynamicgraph::Vector);
65 DECLARE_SIGNAL_IN(force_integral_saturation, dynamicgraph::Vector);
66 DECLARE_SIGNAL_IN(force_integral_deadzone, dynamicgraph::Vector);
67 DECLARE_SIGNAL_IN(fRightFootRef, dynamicgraph::Vector);
68 DECLARE_SIGNAL_IN(fLeftFootRef, dynamicgraph::Vector);
69 DECLARE_SIGNAL_IN(fRightFoot, dynamicgraph::Vector);
70 DECLARE_SIGNAL_IN(fLeftFoot, dynamicgraph::Vector);
71 DECLARE_SIGNAL_IN(fRightFootFiltered, dynamicgraph::Vector);
72 DECLARE_SIGNAL_IN(fLeftFootFiltered, dynamicgraph::Vector);
73 DECLARE_SIGNAL_IN(controlledJoints, dynamicgraph::Vector);
74 DECLARE_SIGNAL_IN(damping, dynamicgraph::Vector);
81 DECLARE_SIGNAL_OUT(u, dynamicgraph::Vector);
83 DECLARE_SIGNAL_OUT(dqDes, dynamicgraph::Vector);
84 DECLARE_SIGNAL_OUT(vDesRightFoot, dynamicgraph::Vector);
85 DECLARE_SIGNAL_OUT(vDesLeftFoot, dynamicgraph::Vector);
91 virtual void display(std::ostream& os)
const;
93 void sendMsg(
const std::string& msg, MsgType t = MSG_TYPE_INFO,
const char* =
"",
int = 0) {
94 logger_.stream(t) << (
"[" + name +
"] " + msg) <<
'\n';
148 #endif // #ifndef __sot_torque_control_admittance_controller_H__