Flair
Framework Libre Air
Pid.h
Go to the documentation of this file.
1 // %flair:license{
2 // This file is part of the Flair framework distributed under the
3 // CECILL-C License, Version 1.0.
4 // %flair:license}
13 #ifndef PID_H
14 #define PID_H
15 
16 #include <ControlLaw.h>
17 
18 namespace flair {
19 namespace gui {
20 class LayoutPosition;
21 }
22 }
23 
24 class Pid_impl;
25 
26 namespace flair {
27 namespace filter {
32 class Pid : public ControlLaw {
33  friend class ::Pid_impl;
34 
35 public:
47  Pid(const gui::LayoutPosition *position, std::string name);
48 
53  ~Pid();
54 
59  void Reset(void);
60 
66  float GetIntegral(void) const;
67 
68 
75  void SetValues(float p, float d);
76 
89  void UseDefaultPlot(const gui::LayoutPosition *position);
90 
91 private:
99  void UpdateFrom(const core::io_data *data);
100 
101  Pid_impl *pimpl_;
102 };
103 } // end namespace filter
104 } // end namespace flair
105 #endif // PID_H
Abstract class for data types.
Definition: io_data.h:94
Base class for control law input must be created by reimplemented class. output is created by this cl...
Definition: ControlLaw.h:36
Pid(const gui::LayoutPosition *position, std::string name)
Constructor.
namespace of the flair Framework
Definition: Ahrs.h:19
void Reset(void)
Reset integral.
~Pid()
Destructor.
void UseDefaultPlot(const gui::LayoutPosition *position)
Use default plot.
Base class for control law.
Class defining a PID.
Definition: Pid.h:32
Class to define a position in a layout on the ground station.
Definition: LayoutPosition.h:28
void SetValues(float p, float d)
Set input values.
float GetIntegral(void) const
Get intergral part.