Flair
Framework Libre Air
FrameworkManager.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 FRAMEWORKMANAGER_H
14 #define FRAMEWORKMANAGER_H
15 
16 #include <Object.h>
17 
18 class FrameworkManager_impl;
19 
20 namespace flair {
21  namespace gui {
22  class TabWidget;
23  class SendData;
24  }
25 }
26 namespace flair {
27 namespace core {
28 class IODevice;
29 
45 class FrameworkManager : public Object {
46 public:
56  FrameworkManager(std::string name);
57 
66 
79  void SetupConnection(std::string address, uint16_t port,Time watchdogTimeout=(Time)1500000000,
80  size_t rcv_buf_size = 10000);
81 
93  void SetupUserInterface(std::string xml_file);
94 
100  gui::TabWidget *GetTabWidget(void) const;
101 
111  void SetupLogger(std::string log_path,uint32_t stackSize=1024*32);
112 
120  std::string GetLogPath(void) const;
121 
132  void AddDeviceToLog(IODevice *device);
133 
142  bool IsDeviceLogged(const IODevice *device) const;
143 
151  void StartLog(void);
152 
158  void StopLog(void);
159 
165  bool IsLogging(void) const;
166 
176  void UpdateSendData(const gui::SendData *obj);
177 
188  void BlockCom(void);
189 
200  void UnBlockCom(void);
201 
211  bool ConnectionLost(void) const;
212 
221  void DisableErrorsDisplay(bool value);
222 
229  bool IsDisplayingErrors(void) const;
230 
231 private:
232  class FrameworkManager_impl *pimpl_;
233 };
234 
241 
247 bool IsBigEndian(void);
248 
249 } // end namespace core
250 } // end namespace flair
251 
252 #endif // FRAMEWORKMANAGER_H
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
std::string GetLogPath(void) const
Get log path.
bool IsDeviceLogged(const IODevice *device) const
Is device logged.
bool IsDisplayingErrors(void) const
Is displaying errors?
Main class of the Framework library.
Definition: FrameworkManager.h:45
bool ConnectionLost(void) const
Is connection lost?
bool IsBigEndian(void)
is big endian?
Class displaying a QTabWidget on the ground station.
Definition: TabWidget.h:29
void StartLog(void)
Start logging.
FrameworkManager(std::string name)
Constructor.
Base class for all Framework's classes.
void StopLog(void)
Stop logging.
void SetupConnection(std::string address, uint16_t port, Time watchdogTimeout=(Time) 1500000000, size_t rcv_buf_size=10000)
Setup the connection with ground station.
void AddDeviceToLog(IODevice *device)
Add log element.
FrameworkManager * getFrameworkManager(void)
get FrameworkManager
void SetupLogger(std::string log_path, uint32_t stackSize=1024 *32)
Logger setup.
void UnBlockCom(void)
Unblock communication.
gui::TabWidget * GetTabWidget(void) const
Get TabWidget.
void DisableErrorsDisplay(bool value)
Disable errors display.
void SetupUserInterface(std::string xml_file)
Setup the user interface.
Abstract class for sending datas to ground station.
Definition: SendData.h:29
void UpdateSendData(const gui::SendData *obj)
Notify that SendData's period has changed.
void BlockCom(void)
Block communication.
bool IsLogging(void) const
Is logging?