|
Fang-Robotics-MCB
Fang Robotics Team Codebase
|
#include <fuzzy_pd.hpp>


Public Member Functions | |
| FuzzyPD (const FuzzyPDConfig &pdConfig, const SmoothPidConfig &smoothPidConfig) | |
| float | runController (float error, float errorDerivative, float dt) override |
Public Member Functions inherited from tap::algorithms::SmoothPid | |
| SmoothPid (const SmoothPidConfig &pidConfig) | |
| 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) |
Fuzzy PD controller. A controller that is built on top of the SmoothPid object.
Fuzzy logic is used to adaptively change the proportional and derivative gains at runtime, whereas they are hard-coded in the SmoothPid object. This allows the controller to adapt to more complex situations (such as overcoming sticktion, varying loads, etc.). Aside from adaptively changing the gains, this controller behaves the same was as the SmoothPid object.
For more general information about fuzzy PID, refer to this paper: https://ieeexplore.ieee.org/document/937407. You can also find others online. For a more generic look at fuzzy logic, you can refer to this paper: https://ieeexplore.ieee.org/stamp/stamp.jsp?arnumber=488475.
| tap::algorithms::FuzzyPD::FuzzyPD | ( | const FuzzyPDConfig & | pdConfig, |
| const SmoothPidConfig & | smoothPidConfig | ||
| ) |
| [in] | pdConfig | Fuzzy-specific configuration. |
| [in] | smoothPidConfig | PID-specific configuration. |
|
overridevirtual |
Reimplemented from tap::algorithms::SmoothPid.