source: flair-src/trunk/tools/Controller/Mavlink/src/GuiGcs.h@ 125

Last change on this file since 125 was 88, checked in by Sanahuja Guillaume, 8 years ago

m

File size: 1.4 KB
Line 
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}
5// created: 2016/09/02
6// filename: GuiGcs.h
7//
8// authors: Thomas Fuhrmann
9// Milan Erdelj
10// Copyright Heudiasyc UMR UTC/CNRS 7253
11//
12// version: $Id: $
13//
14// purpose: Implementation of GuiInterface, using sockets
15//
16//
17/*********************************************************************/
18
19#ifndef MAVPLANNER_GUI_GCS_H
20#define MAVPLANNER_GUI_GCS_H
21
22#include <string>
23#include <array>
24
25#include "GuiInterface.h"
26
27#include "MavlinkUDP.h"
28
29#define INTER_COMMAND_PAUSE 10000 // us
30#define PERIOD_SECOND 1000000 // us
31
32namespace flair {
33namespace core {
34 class FrameworkManager;
35 class Socket;
36}
37}
38
39class GuiGcs : public GuiInterface {
40public:
41
42 GuiGcs(const flair::core::FrameworkManager *parent, std::string name,
43 std::string &outputAddress, int outputPort);
44 ~GuiGcs();
45
46protected:
47
48 virtual void MissionStart();
49 virtual void MissionStop();
50 virtual void MissionPause();
51 virtual void MissionSend();
52
53 uint16_t MavCommandGet(const std::string& command) const;
54
55private:
56 std::string outputAddress;
57 int outputPort;
58
59 MavlinkUDP* mavCom;
60
61 bool missionPauseEnabled;
62
63 void Initialize();
64 void ParametersParse(const std::string& parametersString, std::array<float, 6>& parametersFloat);
65};
66
67#endif // MAVPLANNER_GUI_GCS_H
Note: See TracBrowser for help on using the repository browser.