Flair
Framework Libre Air
ControlLaw.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 CONTROLLAW_H
14 #define CONTROLLAW_H
15 
16 #include <IODevice.h>
17 
18 namespace flair {
19 namespace gui {
20 class LayoutPosition;
21 }
22 namespace core {
23 class Matrix;
24 }
25 }
26 
27 namespace flair {
28 namespace filter {
36 class ControlLaw : public core::IODevice {
37 public:
47  ControlLaw(const core::Object *parent, std::string name, uint32_t nb_out = 1);
48 
53  ~ControlLaw();
54 
62  float Output(uint32_t index = 0) const;
63 
76  virtual void UseDefaultPlot(const gui::LayoutPosition *position);
77 
85  void Update(core::Time time);
86 
93  virtual void Reset(){};
94 
95 protected:
103 
112 
113 private:
121  virtual void UpdateFrom(const core::io_data *data) = 0;
122 };
123 } // end namespace filter
124 } // end namespace flair
125 #endif // CONTROLLAW_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
void Update(core::Time time)
Update using provided datas.
Base class for all Framework's classes.
Definition: Object.h:83
Abstract class for input/ouput system.
Definition: IODevice.h:45
namespace of the flair Framework
Definition: Ahrs.h:19
unsigned long long Time
Time definition, in ns.
Definition: Object.h:55
Abstract class for input/ouput system.
ControlLaw(const core::Object *parent, std::string name, uint32_t nb_out=1)
Constructor.
core::Matrix * input
input matrix
Definition: ControlLaw.h:93
core::Matrix * output
output matrix
Definition: ControlLaw.h:111
float Output(uint32_t index=0) const
Output value.
virtual void UseDefaultPlot(const gui::LayoutPosition *position)
Use default plot.
Class to define a position in a layout on the ground station.
Definition: LayoutPosition.h:28
Class defining a matrix.
Definition: Matrix.h:31
virtual void Reset()
Reset the internal state of the control law.
Definition: ControlLaw.h:93