Flair
Framework Libre Air
SimuBldc.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 SIMUBLDC_H
14 #define SIMUBLDC_H
15 
16 #include <Bldc.h>
17 
18 namespace flair {
19 namespace core {
20 class SharedMem;
21 class IODevice;
22 class cvmatrix;
23 }
24 namespace gui {
25 class DoubleSpinBox;
26 class Layout;
27 }
28 }
29 
30 namespace flair {
31 namespace actuator {
37 class SimuBldc : public Bldc {
38 public:
50  SimuBldc(const core::IODevice *parent, gui::Layout *layout, std::string name,
51  uint8_t motors_count, uint32_t dev_id);
52 
63  SimuBldc(const core::Object *parent, std::string name, uint8_t motors_count,
64  uint32_t dev_id);
65 
70  ~SimuBldc();
71 
79  void GetSpeeds(float *value) const;
80 
88  bool HasSpeedMeasurement(void) const { return false; };
89 
97  bool HasCurrentMeasurement(void) const { return false; };
98 
99 private:
108  void SetMotors(float *value);
109 
110  core::SharedMem *shmem;
112 };
113 } // end namespace actuator
114 } // end namespace flair
115 #endif // SIMUBLDC_H
void GetSpeeds(float *value) const
Get motors speeds.
Base class for all Framework's classes.
Definition: Object.h:77
Abstract class for input/ouput system.
Definition: IODevice.h:45
namespace of the flair Framework
Definition: Ahrs.h:19
SimuBldc(const core::IODevice *parent, gui::Layout *layout, std::string name, uint8_t motors_count, uint32_t dev_id)
Constructor.
Class for a simulation bldc.
Definition: SimuBldc.h:37
Abstract class to display a layout on the ground station.
Definition: Layout.h:33
Class defining a shared memory.
Definition: SharedMem.h:32
Class displaying a QDoubleSpinBox on the ground station.
Definition: DoubleSpinBox.h:28
Base class for brushless motors drivers.
Definition: Bldc.h:38
bool HasSpeedMeasurement(void) const
Has speed measurement.
Definition: SimuBldc.h:88
bool HasCurrentMeasurement(void) const
Has current measurement.
Definition: SimuBldc.h:97
Base class for brushless motors drivers.