Rev 361 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 361 | Rev 391 | ||
---|---|---|---|
Line 23... | Line 23... | ||
23 | #include <QSize> |
23 | #include <QSize> |
24 | #include <QPoint> |
24 | #include <QPoint> |
25 | #include <QColor> |
25 | #include <QColor> |
26 | #include <QBitArray> |
26 | #include <QBitArray> |
Line -... | Line 27... | ||
- | 27 | ||
- | 28 | //copter settings from kopter module |
|
- | 29 | #include "com/Kopter.h" |
|
27 | 30 | ||
Line 28... | Line 31... | ||
28 | #include "Parameter_Positions.h" |
31 | #include "Parameter_Positions.h" |
29 | 32 | ||
30 | #ifdef _WIN32_ |
33 | #ifdef _WIN32_ |
Line 39... | Line 42... | ||
39 | static const int MeterSize = 125; |
42 | static const int MeterSize = 125; |
40 | #else |
43 | #else |
41 | static const int MeterSize = 160; |
44 | static const int MeterSize = 160; |
42 | #endif |
45 | #endif |
Line 43... | Line -... | ||
43 | - | ||
44 | // Version des Seriellen Protokoll |
46 | |
45 | static const int VERSION_SERIAL_MAJOR = 10; |
47 | static const QString QA_NAME = "QMK-Groundstation"; |
46 | static const int VERSION_SERIAL_MINOR = 0; |
- | |
47 | - | ||
48 | // Basis-Addressen der verschiedenen Hardware |
- | |
49 | static const int ADDRESS_ALL = 0; |
- | |
50 | static const int ADDRESS_FC = 1; |
- | |
51 | static const int ADDRESS_NC = 2; |
- | |
52 | static const int ADDRESS_MK3MAG = 3; |
- | |
53 | - | ||
Line -... | Line 48... | ||
- | 48 | static const QString QA_VERSION_NR = "0.8.5 - own flight lib"; |
|
- | 49 | ||
54 | static const int SETTINGS_ID = 2; |
50 | // sleep time - time to wait until next command is received |
Line 55... | Line -... | ||
55 | - | ||
56 | static const int SLEEP = 500000; |
- | |
57 | - | ||
58 | static const QString QA_NAME = "QMK-Groundstation"; |
51 | // FIXME: delete this / rewrite to use interrupts, mutex or something elsebetter than timeouts |
59 | static const QString QA_VERSION_NR = "0.8.5"; |
52 | static const int SLEEP = 500000; |
60 | 53 | ||
61 | #ifdef _BETA_ |
54 | #ifdef _BETA_ |
62 | static const QString QA_VERSION = QA_VERSION_NR + " (BETA)"; |
55 | static const QString QA_VERSION = QA_VERSION_NR + " (BETA)"; |
Line 104... | Line 97... | ||
104 | static const QRgb Def_Colors[] = {0x00FF0000, 0x0000FF00, 0x00FFFF00, 0x000000FF, 0x00FF00FF, 0x0000FFFF, 0x00FFFFFF, 0x00660000, 0x00006600, 0x00666600, 0x00000066, 0x00660066, 0x000066, 0x00666666, 0x00990000, 0x00009900, 0x00999900, 0x00000099, 0x00990099, 0x00009999, 0x00999999, 0x00CC0000, 0x0000CC00, 0x00CCCC00, 0x000000CC, 0x00CC00CC, 0x0000CCCC, 0x00CCCCCC, 0x0066FF99, 0x009966FF, 0x00FF9966, 0x0099FF66}; |
97 | static const QRgb Def_Colors[] = {0x00FF0000, 0x0000FF00, 0x00FFFF00, 0x000000FF, 0x00FF00FF, 0x0000FFFF, 0x00FFFFFF, 0x00660000, 0x00006600, 0x00666600, 0x00000066, 0x00660066, 0x000066, 0x00666666, 0x00990000, 0x00009900, 0x00999900, 0x00000099, 0x00990099, 0x00009999, 0x00999999, 0x00CC0000, 0x0000CC00, 0x00CCCC00, 0x000000CC, 0x00CC00CC, 0x0000CCCC, 0x00CCCCCC, 0x0066FF99, 0x009966FF, 0x00FF9966, 0x0099FF66}; |
Line 105... | Line 98... | ||
105 | 98 | ||
106 | static const bool Def_Plot_Show[] = {1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0}; |
99 | static const bool Def_Plot_Show[] = {1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0}; |
Line 107... | Line -... | ||
107 | static const bool Def_Log[] = {1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0}; |
- | |
108 | - | ||
109 | static const QString HardwareType[] = {"Default", "FlightCtrl", "NaviCtrl", "MK3Mag"}; |
- | |
110 | - | ||
111 | static const int MaxTickerEvents = 5; |
- | |
112 | - | ||
113 | static const int MaxAnalog = 32; |
- | |
114 | static const int MaxPlot = 50000; |
- | |
115 | - | ||
116 | static const int MaxNaviPos = 2000; |
- | |
117 | - | ||
118 | struct sMotor |
- | |
119 | { |
- | |
120 | int Speed[12]; |
- | |
121 | }; |
- | |
122 | - | ||
123 | struct sMode |
- | |
124 | { |
- | |
125 | int ID; |
- | |
126 | int VERSION_MAJOR; |
- | |
127 | int VERSION_MINOR; |
- | |
128 | int VERSION_PATCH; |
- | |
129 | int VERSION_SERIAL_MAJOR; |
- | |
130 | int VERSION_SERIAL_MINOR; |
- | |
131 | QString Hardware; |
- | |
132 | QString Version; |
- | |
133 | }; |
- | |
134 | - | ||
135 | struct sRxData |
- | |
136 | { |
- | |
137 | char *Input; |
- | |
138 | QString String; |
- | |
139 | int Decode[150]; |
- | |
140 | int DecLen; |
- | |
141 | }; |
- | |
142 | - | ||
143 | struct sGPS_Pos |
- | |
144 | { |
- | |
145 | long Longitude; |
- | |
146 | long Latitude; |
- | |
147 | long Altitude; |
- | |
148 | }; |
- | |
149 | - | ||
150 | struct sNaviData |
- | |
151 | { |
- | |
152 | sGPS_Pos Current; |
- | |
153 | sGPS_Pos Target; |
- | |
154 | sGPS_Pos Home; |
- | |
155 | - | ||
156 | - | ||
157 | long Longitude; |
- | |
158 | long Latitude; |
- | |
159 | long Altitude; |
- | |
160 | }; |
- | |
161 | - | ||
162 | struct sNaviString |
- | |
163 | { |
- | |
164 | QString Longitude; |
- | |
165 | QString Latitude; |
- | |
166 | QString Altitude; |
- | |
167 | }; |
- | |
168 | - | ||
169 | struct sWayPoint |
- | |
170 | { |
- | |
171 | double Longitude; |
- | |
172 | double Latitude; |
- | |
173 | double Altitude; |
- | |
174 | int Time; |
- | |
175 | }; |
100 | static const bool Def_Log[] = {1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0}; |