20 #include <boost/any.hpp>
40 DAMPING_ACTIVE = 0x00000001,
42 JOINT_LIMIT = 0x00000002
53 public:
virtual void Load(sdf::ElementPtr _sdf);
56 public:
virtual void Reset();
59 public:
virtual LinkPtr GetJointLink(
unsigned int _index)
const;
62 public:
virtual bool AreConnected(
LinkPtr _one,
LinkPtr _two)
const;
70 public:
virtual double GetParam(
unsigned int _parameter)
const;
78 public:
virtual void SetParam(
unsigned int _parameter,
double _value);
81 public:
virtual void SetDamping(
unsigned int _index,
double _damping);
84 public:
virtual bool SetPosition(
unsigned int _index,
double _position);
87 public:
virtual void SetStiffness(
unsigned int _index,
88 const double _stiffness);
91 public:
virtual void SetStiffnessDamping(
unsigned int _index,
92 double _stiffness,
double _damping,
double _reference = 0);
98 public:
virtual void Detach();
102 public:
void SetERP(
double _erp);
106 public:
double GetERP();
110 public:
void SetCFM(
double _cfm);
114 public:
double GetCFM();
118 public: dJointFeedback *GetFeedback();
122 public:
bool UsesImplicitSpringDamper();
126 public:
void ApplyImplicitStiffnessDamping();
129 public:
void ApplyExplicitStiffnessDamping();
135 return this->stopCFM;
142 return this->stopERP;
154 private:
double ApplyAdaptiveDamping(
unsigned int _index,
155 const double _damping);
163 private:
void KpKdToCFMERP(
const double _dt,
164 const double _kp,
const double _kd,
165 double &_cfm,
double &_erp);
173 private:
void CFMERPToKpKd(
const double _dt,
174 const double _cfm,
const double _erp,
175 double &_kp,
double &_kd);
188 private:
bool stiffnessDampingInitialized;
191 private:
bool useImplicitSpringDamper;
194 public:
virtual bool SetHighStop(
unsigned int _index,
198 public:
virtual bool SetLowStop(
unsigned int _index,
202 public:
virtual math::Angle GetHighStop(
unsigned int _index);
205 public:
virtual math::Angle GetLowStop(
unsigned int _index);
208 public:
virtual math::Vector3 GetLinkForce(
unsigned int _index)
const;
211 public:
virtual math::Vector3 GetLinkTorque(
unsigned int _index)
const;
214 public:
virtual void SetAxis(
unsigned int _index,
218 public:
virtual bool SetParam(
const std::string &_key,
220 const boost::any &_value);
223 public:
virtual double GetParam(
const std::string &_key,
224 unsigned int _index);
227 public:
virtual void SetProvideFeedback(
bool _enable);
230 public:
virtual JointWrench GetForceTorque(
unsigned int _index);
233 public:
virtual void SetForce(
unsigned int _index,
double _force);
236 public:
virtual double GetForce(
unsigned int _index);
239 public:
virtual void ApplyStiffnessDamping();
250 protected:
virtual void SetForceImpl(
251 unsigned int _index,
double _force) = 0;
256 private:
void SaveForce(
unsigned int _index,
double _force);
262 private: dJointFeedback *feedback;
265 private:
double stopCFM;
268 private:
double stopERP;
boost::shared_ptr< Base > BasePtr
Definition: PhysicsTypes.hh:66
double GetStopCFM()
Get access to stopCFM.
Definition: ODEJoint.hh:133
The Vector3 class represents the generic vector containing 3 elements.
Definition: Vector3.hh:43
dJointID jointId
This is our ODE ID.
Definition: ODEJoint.hh:259
CFMMode
internal variables used for implicit damping
Definition: ODEJoint.hh:35
#define MAX_JOINT_AXIS
maximum number of axis per joint anticipated.
Definition: Joint.hh:39
double GetStopERP()
Get access to stopERP.
Definition: ODEJoint.hh:140
Base class for all joints.
Definition: Joint.hh:50
Wrench information from a joint.
Definition: JointWrench.hh:39
ODE joint interface.
Definition: ODEJoint.hh:32
An angle and related functions.
Definition: Angle.hh:52
#define GAZEBO_VISIBLE
Use to represent "symbol visible" if supported.
Definition: system.hh:48
boost::shared_ptr< Link > LinkPtr
Definition: PhysicsTypes.hh:90
A Time class, can be used to hold wall- or sim-time.
Definition: Time.hh:43