40 #include <sawControllers/sawControllersRevision.h>
174 void ResetController(
void);
184 void SetupInterfaces(
void);
186 void Enable(
const bool & enable);
188 void EnableTorqueMode(
const vctBoolVec & enable);
190 void SetTrackingErrorTolerances(
const vctDoubleVec & tolerances);
192 void ErrorEventHandler(
const std::string & message);
202 mtsPID(
const std::string & taskname,
203 const double period);
212 void Configure(
const std::string& filename);
245 void SetJointLowerLimit(
const vctDoubleVec & lowerLimit);
252 void SetJointUpperLimit(
const vctDoubleVec & upperLimit);
275 void SetForgetIError(
const double & forget);
Definition: prmPositionJointGet.h:35
vctBoolVec mTrackingErrorFlag
Definition: mtsPID.h:152
vctDoubleVec maxIErrorLimit
Max iError.
Definition: mtsPID.h:133
#define CISST_EXPORT
Definition: cmnExportMacros.h:50
vctBoolVec TorqueMode
Enable mtsPID controller.
Definition: mtsPID.h:148
Definition: prmVelocityJointGet.h:39
prmStateJoint mStateJointDesired
Definition: mtsPID.h:114
bool mEnableTrackingError
Definition: mtsPID.h:150
Definition: mtsFunctionRead.h:37
mtsFunctionRead GetFeedbackPosition
Read joint position from robot.
Definition: mtsPID.h:55
vctDoubleVec DesiredPosition
Desired joint positions.
Definition: mtsPID.h:88
prmVelocityJointGet FeedbackVelocityParam
prm type feedback velocity
Definition: mtsPID.h:110
Definition: mtsTaskPeriodic.h:38
mtsFunctionWrite Warning
Definition: mtsPID.h:166
mtsFunctionWrite Status
Definition: mtsPID.h:165
mtsFunctionWrite Enabled
Enable event.
Definition: mtsPID.h:159
Definition: prmForceTorqueJointSet.h:37
const int CMN_DYNAMIC_CREATION_ONEARG
Definition: cmnClassRegisterMacros.h:333
virtual void Startup(void)
Definition: mtsComponent.h:262
Always include last.
Definition: mtsPID.h:45
bool Enabled
Enable mtsPID controller.
Definition: mtsPID.h:145
Definition: prmStateJoint.h:35
vctDoubleVec dError
Error derivative.
Definition: mtsPID.h:121
vctDoubleVec DesiredVelocity
Desired joint velocities.
Definition: mtsPID.h:96
vctDoubleVec DesiredTorque
Desired joint positions.
Definition: mtsPID.h:92
vctDoubleVec ErrorAbsolute
Definition: mtsPID.h:118
vctDoubleVec JointLowerLimit
Joint lower limit.
Definition: mtsPID.h:76
vctDoubleVec iError
Error integral.
Definition: mtsPID.h:123
mtsFunctionRead GetFeedbackVelocity
Read joint velocity from robot.
Definition: mtsPID.h:57
vctDoubleVec JointUpperLimit
Joint upper limit.
Definition: mtsPID.h:78
vctDoubleVec nonlinear
If 0, use regular PID, else use as nonlinear factor.
Definition: mtsPID.h:139
vctDoubleVec Error
Error.
Definition: mtsPID.h:117
vctDoubleVec Ki
Integral gains.
Definition: mtsPID.h:72
vctDoubleVec FeedbackPosition
Feedback joint positions.
Definition: mtsPID.h:86
vctDoubleVec mTrackingErrorTolerances
Definition: mtsPID.h:151
mtsFunctionWrite Error
Definition: mtsPID.h:167
vctDoubleVec DeadBand
Deadband (errors less than this are set to 0)
Definition: mtsPID.h:142
virtual void Configure(const std::string &CMN_UNUSED(filename)="")
Definition: mtsTask.h:218
vctDoubleVec forgetIError
iError forgetting factor
Definition: mtsPID.h:136
vctBoolVec mPreviousJointLimitFlag
Definition: mtsPID.h:81
Definition: mtsStateTable.h:67
mtsFunctionWrite SetTorque
Write the joint torques.
Definition: mtsPID.h:61
mtsFunctionWrite JointLimit
Definition: mtsPID.h:161
Joint position move parameters.
#define CMN_DECLARE_SERVICES(hasDynamicCreation, lod)
Definition: cmnClassRegisterMacros.h:116
mtsFunctionRead GetFeedbackTorque
Read joint torque from robot.
Definition: mtsPID.h:59
Joint velocity query parameters.
prmPositionJointGet FeedbackPositionParam
prm type feedback positoin
Definition: mtsPID.h:103
prmForceTorqueJointSet prmDesiredTrq
prm type desired torque
Definition: mtsPID.h:108
vctDoubleVec Offset
Offset.
Definition: mtsPID.h:74
vctDoubleVec oldError
Previous error.
Definition: mtsPID.h:126
vctDoubleVec Kp
Proportional gains.
Definition: mtsPID.h:68
mtsFunctionRead GetJointType
Read joint type form robot.
Definition: mtsPID.h:53
prmPositionJointSet DesiredPositionParam
prm type desired position
Definition: mtsPID.h:106
vctDoubleVec FeedbackVelocity
Feedback joint velocities.
Definition: mtsPID.h:94
prmPositionJointGet FeedbackPositionPreviousParam
Definition: mtsPID.h:104
~mtsPID()
Definition: mtsPID.h:205
Joint position move parameters.
bool CheckJointLimit
Flag whether check joint limit.
Definition: mtsPID.h:80
vctDoubleVec oldDesiredPos
Previous desiredPos.
Definition: mtsPID.h:128
Definition: mtsFunctionWrite.h:37
Definition: mtsTaskPeriodic.h:80
vctDoubleVec Torque
Torque set to robot.
Definition: mtsPID.h:98
prmForceTorqueJointSet TorqueParam
prm type set torque
Definition: mtsPID.h:112
vctDoubleVec FeedbackTorque
Feedback joint positions.
Definition: mtsPID.h:90
CMN_DECLARE_SERVICES_INSTANTIATION(mtsPID)
virtual void Cleanup(void)
Definition: mtsComponent.h:267
int Counter
Counter for internal use.
Definition: mtsPID.h:65
vctDoubleVec Kd
Derivative gains.
Definition: mtsPID.h:70
mtsStateTable ConfigurationStateTable
Configuration state table.
Definition: mtsPID.h:155
#define CMN_LOG_ALLOW_DEFAULT
Definition: cmnLogLoD.h:76
vctDoubleVec minIErrorLimit
Min iError.
Definition: mtsPID.h:131
Definition: prmPositionJointSet.h:37
prmJointTypeVec JointType
prm type joint type
Definition: mtsPID.h:101