Fang-Robotics-MCB
Fang Robotics Team Codebase
Loading...
Searching...
No Matches
tap::algorithms::SmoothPid Class Reference

#include <smooth_pid.hpp>

Inheritance diagram for tap::algorithms::SmoothPid:

Public Member Functions

 SmoothPid (const SmoothPidConfig &pidConfig)
 
virtual float runController (float error, float errorDerivative, float dt)
 
float runControllerDerivateError (float error, float dt)
 
float getOutput ()
 
void reset ()
 
void setP (float p)
 
void setI (float i)
 
void setD (float d)
 
void setMaxICumulative (float maxICumulative)
 
void setMaxOutput (float maxOutput)
 
void setErrDeadzone (float errDeadzone)
 

Constructor & Destructor Documentation

◆ SmoothPid()

tap::algorithms::SmoothPid::SmoothPid ( const SmoothPidConfig pidConfig)

Member Function Documentation

◆ getOutput()

float tap::algorithms::SmoothPid::getOutput ( )

◆ reset()

void tap::algorithms::SmoothPid::reset ( )

◆ runController()

float tap::algorithms::SmoothPid::runController ( float  error,
float  errorDerivative,
float  dt 
)
virtual

Runs the PID controller. Should be called frequently for best results.

Parameters
[in]errorThe error (in user-defined units) between some target and measured value.
[in]errorDerivativeThe derivative of the error passed in above (in user-defined units / time).
[in]dtThe difference in time between the time this function is being called and the last time this function was called.

Reimplemented in tap::algorithms::FuzzyPD.

◆ runControllerDerivateError()

float tap::algorithms::SmoothPid::runControllerDerivateError ( float  error,
float  dt 
)

◆ setD()

void tap::algorithms::SmoothPid::setD ( float  d)
inline

◆ setErrDeadzone()

void tap::algorithms::SmoothPid::setErrDeadzone ( float  errDeadzone)
inline

◆ setI()

void tap::algorithms::SmoothPid::setI ( float  i)
inline

◆ setMaxICumulative()

void tap::algorithms::SmoothPid::setMaxICumulative ( float  maxICumulative)
inline

◆ setMaxOutput()

void tap::algorithms::SmoothPid::setMaxOutput ( float  maxOutput)
inline

◆ setP()

void tap::algorithms::SmoothPid::setP ( float  p)
inline

The documentation for this class was generated from the following files: