Rev 440 | Rev 449 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
307 | KeyOz | 1 | /*************************************************************************** |
2 | * Copyright (C) 2009 by Manuel Schrape * |
||
3 | * manuel.schrape@gmx.de * |
||
4 | * * |
||
5 | * This program is free software; you can redistribute it and/or modify * |
||
6 | * it under the terms of the GNU General Public License as published by * |
||
7 | * the Free Software Foundation; either version 2 of the License. * |
||
8 | * * |
||
9 | * This program is distributed in the hope that it will be useful, * |
||
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of * |
||
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * |
||
12 | * GNU General Public License for more details. * |
||
13 | * * |
||
14 | * You should have received a copy of the GNU General Public License * |
||
15 | * along with this program; if not, write to the * |
||
16 | * Free Software Foundation, Inc., * |
||
17 | * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * |
||
18 | ***************************************************************************/ |
||
19 | #include "dlg_MotorMixer.h" |
||
20 | |||
21 | dlg_MotorMixer::dlg_MotorMixer(QWidget *parent) : QDialog(parent) |
||
22 | { |
||
23 | setupUi(this); |
||
24 | connect(pb_READ, SIGNAL(clicked()), this, SLOT(slot_pb_READ())); |
||
25 | connect(pb_LOAD, SIGNAL(clicked()), this, SLOT(slot_pb_LOAD())); |
||
26 | connect(pb_SAVE, SIGNAL(clicked()), this, SLOT(slot_pb_SAVE())); |
||
27 | connect(pb_WRITE, SIGNAL(clicked()), this, SLOT(slot_pb_WRITE())); |
||
28 | |||
29 | connect(sb_NICK_1, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
30 | connect(sb_NICK_2, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
31 | connect(sb_NICK_3, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
32 | connect(sb_NICK_4, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
33 | connect(sb_NICK_5, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
34 | connect(sb_NICK_6, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
35 | connect(sb_NICK_7, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
36 | connect(sb_NICK_8, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
37 | connect(sb_NICK_9, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
38 | connect(sb_NICK_10, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
39 | connect(sb_NICK_11, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
40 | connect(sb_NICK_12, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
41 | |||
42 | connect(sb_ROLL_1, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
43 | connect(sb_ROLL_2, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
44 | connect(sb_ROLL_3, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
45 | connect(sb_ROLL_4, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
46 | connect(sb_ROLL_5, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
47 | connect(sb_ROLL_6, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
48 | connect(sb_ROLL_7, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
49 | connect(sb_ROLL_8, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
50 | connect(sb_ROLL_9, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
51 | connect(sb_ROLL_10, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
52 | connect(sb_ROLL_11, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
53 | connect(sb_ROLL_12, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
54 | |||
55 | connect(sb_GIER_1, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
56 | connect(sb_GIER_2, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
57 | connect(sb_GIER_3, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
58 | connect(sb_GIER_4, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
59 | connect(sb_GIER_5, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
60 | connect(sb_GIER_6, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
61 | connect(sb_GIER_7, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
62 | connect(sb_GIER_8, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
63 | connect(sb_GIER_9, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
64 | connect(sb_GIER_10, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
65 | connect(sb_GIER_11, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
66 | connect(sb_GIER_12, SIGNAL(valueChanged(int)), this, SLOT(slot_CheckValue(int))); |
||
67 | |||
68 | } |
||
69 | |||
70 | // Connection-Object übergeben. |
||
396 | Brean | 71 | void dlg_MotorMixer::set_Objects(Handler *handler, cSettings *t_Settings) |
307 | KeyOz | 72 | { |
396 | Brean | 73 | this->handler = handler; |
442 | Brean | 74 | this->data = handler->data; |
307 | KeyOz | 75 | o_Settings = t_Settings; |
76 | } |
||
77 | |||
78 | // Motordaten übernehmen. |
||
79 | void dlg_MotorMixer::set_MotorConfig(sRxData RX) |
||
80 | { |
||
440 | Brean | 81 | //FIXME: put this in libMK/Handler.cpp and fill motor values in KopterData |
82 | /* |
||
307 | KeyOz | 83 | int Pos = 0; |
84 | |||
396 | Brean | 85 | MixerName = ToolBox::dataToQString(RX.decode, 1, 12); |
307 | KeyOz | 86 | |
87 | Pos = 13; |
||
88 | |||
89 | for (int z = 0; z < 16; z++) |
||
90 | { |
||
91 | for (int y = 0; y < 4; y++) |
||
92 | { |
||
396 | Brean | 93 | Motor[z][y] = Parser::dataToChar(RX.decode,Pos); |
307 | KeyOz | 94 | Pos++; |
95 | } |
||
96 | } |
||
97 | |||
98 | set_MotorData(); |
||
440 | Brean | 99 | */ |
307 | KeyOz | 100 | } |
101 | |||
102 | // Motordaten aus GUI übernehmen |
||
103 | void dlg_MotorMixer::get_MotorData() |
||
104 | { |
||
442 | Brean | 105 | sMotorData motorData; |
106 | |||
440 | Brean | 107 | char * mixerName = le_NAME->text().toAscii().data(); |
442 | Brean | 108 | motorData.mixer_name = string(mixerName); |
307 | KeyOz | 109 | |
442 | Brean | 110 | int gas[MAX_MOTORS] = { |
111 | sb_GAS_1->value(), sb_GAS_2->value(), sb_GAS_3->value(), sb_GAS_4->value(), |
||
112 | sb_GAS_5->value(), sb_GAS_6->value(), sb_GAS_7->value(), sb_GAS_8->value(), |
||
113 | sb_GAS_9->value(), sb_GAS_10->value(), sb_GAS_11->value(), sb_GAS_12->value() |
||
440 | Brean | 114 | }; |
442 | Brean | 115 | int nick[MAX_MOTORS] = { |
116 | sb_NICK_1->value(), sb_NICK_2->value(), sb_NICK_3->value(), sb_NICK_4->value(), |
||
117 | sb_NICK_5->value(), sb_NICK_6->value(), sb_NICK_7->value(), sb_NICK_8->value(), |
||
118 | sb_NICK_9->value(), sb_NICK_10->value(), sb_NICK_11->value(), sb_NICK_12->value() |
||
119 | }; |
||
120 | int roll[MAX_MOTORS] = { |
||
121 | sb_ROLL_1->value(), sb_ROLL_2->value(), sb_ROLL_3->value(), sb_ROLL_4->value(), |
||
122 | sb_ROLL_5->value(), sb_ROLL_6->value(), sb_ROLL_7->value(), sb_ROLL_8->value(), |
||
123 | sb_ROLL_9->value(), sb_ROLL_10->value(), sb_ROLL_11->value(), sb_ROLL_12->value() |
||
124 | }; |
||
125 | int yaw[MAX_MOTORS] = { |
||
126 | sb_GIER_1->value(), sb_GIER_2->value(), sb_GIER_3->value(), sb_GIER_4->value(), |
||
127 | sb_GIER_5->value(), sb_GIER_6->value(), sb_GIER_7->value(), sb_GIER_8->value(), |
||
128 | sb_GIER_9->value(), sb_GIER_10->value(), sb_GIER_11->value(), sb_GIER_12->value() |
||
129 | }; |
||
130 | for (int i = 0; i < MAX_MOTORS; i++) { |
||
131 | motorData.mixer_gas[i] = gas[i]; |
||
132 | motorData.mixer_nick[i] = nick[i]; |
||
133 | motorData.mixer_roll[i] = roll[i]; |
||
134 | motorData.mixer_yaw[i] = yaw[i]; |
||
135 | } |
||
136 | //FIXME: add Function in handler to send data |
||
307 | KeyOz | 137 | } |
138 | |||
139 | // Motordaten anzeigen |
||
140 | void dlg_MotorMixer::set_MotorData() |
||
141 | { |
||
442 | Brean | 142 | sMotorData motorData = handler->data->motor; |
143 | le_NAME->setText(motorData.mixer_name.c_str()); |
||
307 | KeyOz | 144 | |
442 | Brean | 145 | sb_GAS_1->setValue(motorData.mixer_gas[0]); |
146 | sb_GAS_2->setValue(motorData.mixer_gas[1]); |
||
147 | sb_GAS_3->setValue(motorData.mixer_gas[2]); |
||
148 | sb_GAS_4->setValue(motorData.mixer_gas[3]); |
||
149 | sb_GAS_5->setValue(motorData.mixer_gas[4]); |
||
150 | sb_GAS_6->setValue(motorData.mixer_gas[5]); |
||
151 | sb_GAS_7->setValue(motorData.mixer_gas[6]); |
||
152 | sb_GAS_8->setValue(motorData.mixer_gas[7]); |
||
153 | sb_GAS_9->setValue(motorData.mixer_gas[8]); |
||
154 | sb_GAS_10->setValue(motorData.mixer_gas[9]); |
||
155 | sb_GAS_11->setValue(motorData.mixer_gas[10]); |
||
156 | sb_GAS_12->setValue(motorData.mixer_gas[11]); |
||
307 | KeyOz | 157 | |
442 | Brean | 158 | sb_NICK_1->setValue(motorData.mixer_nick[0]); |
159 | sb_NICK_2->setValue(motorData.mixer_nick[1]); |
||
160 | sb_NICK_3->setValue(motorData.mixer_nick[2]); |
||
161 | sb_NICK_4->setValue(motorData.mixer_nick[3]); |
||
162 | sb_NICK_5->setValue(motorData.mixer_nick[4]); |
||
163 | sb_NICK_6->setValue(motorData.mixer_nick[5]); |
||
164 | sb_NICK_7->setValue(motorData.mixer_nick[6]); |
||
165 | sb_NICK_8->setValue(motorData.mixer_nick[7]); |
||
166 | sb_NICK_9->setValue(motorData.mixer_nick[8]); |
||
167 | sb_NICK_10->setValue(motorData.mixer_nick[9]); |
||
168 | sb_NICK_11->setValue(motorData.mixer_nick[10]); |
||
169 | sb_NICK_12->setValue(motorData.mixer_nick[11]); |
||
307 | KeyOz | 170 | |
442 | Brean | 171 | sb_ROLL_1->setValue(motorData.mixer_roll[0]); |
172 | sb_ROLL_2->setValue(motorData.mixer_roll[1]); |
||
173 | sb_ROLL_3->setValue(motorData.mixer_roll[2]); |
||
174 | sb_ROLL_4->setValue(motorData.mixer_roll[3]); |
||
175 | sb_ROLL_5->setValue(motorData.mixer_roll[4]); |
||
176 | sb_ROLL_6->setValue(motorData.mixer_roll[5]); |
||
177 | sb_ROLL_7->setValue(motorData.mixer_roll[6]); |
||
178 | sb_ROLL_8->setValue(motorData.mixer_roll[7]); |
||
179 | sb_ROLL_9->setValue(motorData.mixer_roll[8]); |
||
180 | sb_ROLL_10->setValue(motorData.mixer_roll[9]); |
||
181 | sb_ROLL_11->setValue(motorData.mixer_roll[10]); |
||
182 | sb_ROLL_12->setValue(motorData.mixer_roll[11]); |
||
307 | KeyOz | 183 | |
442 | Brean | 184 | sb_GIER_1->setValue(motorData.mixer_yaw[0]); |
185 | sb_GIER_2->setValue(motorData.mixer_yaw[1]); |
||
186 | sb_GIER_3->setValue(motorData.mixer_yaw[2]); |
||
187 | sb_GIER_4->setValue(motorData.mixer_yaw[3]); |
||
188 | sb_GIER_5->setValue(motorData.mixer_yaw[4]); |
||
189 | sb_GIER_6->setValue(motorData.mixer_yaw[5]); |
||
190 | sb_GIER_7->setValue(motorData.mixer_yaw[6]); |
||
191 | sb_GIER_8->setValue(motorData.mixer_yaw[7]); |
||
192 | sb_GIER_9->setValue(motorData.mixer_yaw[8]); |
||
193 | sb_GIER_10->setValue(motorData.mixer_yaw[9]); |
||
194 | sb_GIER_11->setValue(motorData.mixer_yaw[10]); |
||
195 | sb_GIER_12->setValue(motorData.mixer_yaw[11]); |
||
307 | KeyOz | 196 | } |
197 | |||
198 | // Prüfen auf vollstaändigkeit |
||
199 | void dlg_MotorMixer::slot_CheckValue(int Wert) |
||
200 | { |
||
201 | Wert = Wert; |
||
202 | |||
442 | Brean | 203 | int NICK = sb_NICK_1->value() + sb_NICK_2->value() + sb_NICK_3->value() + |
204 | sb_NICK_4->value() + sb_NICK_5->value() + sb_NICK_6->value() + |
||
205 | sb_NICK_7->value() + sb_NICK_8->value() + sb_NICK_9->value() + |
||
206 | sb_NICK_10->value() + sb_NICK_11->value() + sb_NICK_12->value(); |
||
307 | KeyOz | 207 | |
442 | Brean | 208 | int ROLL = sb_ROLL_1->value() + sb_ROLL_2->value() + sb_ROLL_3->value() + |
209 | sb_ROLL_4->value() + sb_ROLL_5->value() + sb_ROLL_6->value() + |
||
210 | sb_ROLL_7->value() + sb_ROLL_8->value() + sb_ROLL_9->value() + |
||
211 | sb_ROLL_10->value() + sb_ROLL_11->value() + sb_ROLL_12->value(); |
||
307 | KeyOz | 212 | |
442 | Brean | 213 | int GIER = sb_GIER_1->value() + sb_GIER_2->value() + sb_GIER_3->value() + |
214 | sb_GIER_4->value() + sb_GIER_5->value() + sb_GIER_6->value() + |
||
215 | sb_GIER_7->value() + sb_GIER_8->value() + sb_GIER_9->value() + |
||
216 | sb_GIER_10->value() + sb_GIER_11->value() + sb_GIER_12->value(); |
||
307 | KeyOz | 217 | |
218 | if (NICK == 0) |
||
219 | { |
||
220 | lb_NICK->setEnabled(true); |
||
221 | } |
||
222 | else |
||
223 | { |
||
224 | lb_NICK->setEnabled(false); |
||
225 | } |
||
226 | |||
227 | if (ROLL == 0) |
||
228 | { |
||
229 | lb_ROLL->setEnabled(true); |
||
230 | } |
||
231 | else |
||
232 | { |
||
233 | lb_ROLL->setEnabled(false); |
||
234 | } |
||
235 | |||
236 | if (GIER == 0) |
||
237 | { |
||
238 | lb_GIER->setEnabled(true); |
||
239 | } |
||
240 | else |
||
241 | { |
||
242 | lb_GIER->setEnabled(false); |
||
243 | } |
||
244 | } |
||
245 | |||
440 | Brean | 246 | //FIXME: put this in libMK/Handler.cpp |
396 | Brean | 247 | /* |
307 | KeyOz | 248 | int dlg_MotorMixer::get_MotorConfig() |
249 | { |
||
250 | get_MotorData(); |
||
251 | |||
252 | TX_Data[0] = VERSION_MIXER; |
||
253 | |||
254 | char *Name = MixerName.toLatin1().data(); |
||
255 | |||
256 | int a; |
||
257 | |||
258 | for (a = 0; a < MixerName.length(); a++) |
||
259 | { |
||
260 | TX_Data[1+a] = Name[a]; |
||
261 | } |
||
262 | |||
263 | while(a < 12) |
||
264 | { |
||
265 | TX_Data[1+a] = 0; |
||
266 | a++; |
||
267 | } |
||
268 | |||
269 | int Pos = 13; |
||
270 | |||
271 | for (int z = 0; z < 16; z++) |
||
272 | { |
||
273 | for (int y = 0; y < 4; y++) |
||
274 | { |
||
396 | Brean | 275 | TX_Data[Pos] = Parser::charToData(Motor[z][y]); |
307 | KeyOz | 276 | Pos++; |
277 | } |
||
278 | } |
||
279 | |||
280 | return Pos - 1; |
||
281 | } |
||
440 | Brean | 282 | */ |
307 | KeyOz | 283 | |
396 | Brean | 284 | // read motor values |
307 | KeyOz | 285 | void dlg_MotorMixer::slot_pb_READ() |
286 | { |
||
396 | Brean | 287 | //send command to get mixer values |
440 | Brean | 288 | handler->read_motor_mixer(); |
307 | KeyOz | 289 | } |
290 | |||
396 | Brean | 291 | //write motor values |
440 | Brean | 292 | //FIXME: put this in libMK/Handler.cpp |
307 | KeyOz | 293 | void dlg_MotorMixer::slot_pb_WRITE() |
294 | { |
||
440 | Brean | 295 | char tx_data[150]; |
296 | int length = handler->get_motor_config(tx_data); |
||
297 | handler->write_motor_mixer(tx_data, length); |
||
307 | KeyOz | 298 | } |
299 | |||
300 | void dlg_MotorMixer::slot_pb_LOAD() |
||
301 | { |
||
358 | KeyOz | 302 | QString Filename = QFileDialog::getOpenFileName(this, tr("Mikrokopter MotorMixer laden"), o_Settings->DIR.Parameter + "", tr("MK MotorMixer(*.mkm);;Alle Dateien (*)")); |
307 | KeyOz | 303 | |
304 | if (!Filename.isEmpty()) |
||
305 | { |
||
306 | QSettings Setting(Filename, QSettings::IniFormat); |
||
307 | |||
308 | Setting.beginGroup("Info"); |
||
442 | Brean | 309 | data->motor.mixer_name = Setting.value("Name", QString("--noname--")).toString().toAscii().data(); |
310 | data->motor.mixer_version = Setting.value("Version", 0).toInt(); |
||
307 | KeyOz | 311 | Setting.endGroup(); |
312 | |||
313 | Setting.beginGroup("Gas"); |
||
314 | for (int z = 0; z < MAXMOTOR; z++) |
||
315 | { |
||
442 | Brean | 316 | data->motor.mixer_gas[z] = Setting.value(QString("Motor%1").arg(z+1), 0).toInt(); |
307 | KeyOz | 317 | } |
318 | Setting.endGroup(); |
||
319 | |||
320 | Setting.beginGroup("Nick"); |
||
321 | for (int z = 0; z < MAXMOTOR; z++) |
||
322 | { |
||
442 | Brean | 323 | data->motor.mixer_nick[z] = Setting.value(QString("Motor%1").arg(z+1), 0).toInt(); |
307 | KeyOz | 324 | } |
325 | Setting.endGroup(); |
||
326 | |||
327 | Setting.beginGroup("Roll"); |
||
328 | for (int z = 0; z < MAXMOTOR; z++) |
||
329 | { |
||
442 | Brean | 330 | data->motor.mixer_roll[z] = Setting.value(QString("Motor%1").arg(z+1), 0).toInt(); |
307 | KeyOz | 331 | } |
332 | Setting.endGroup(); |
||
333 | |||
334 | Setting.beginGroup("Yaw"); |
||
335 | for (int z = 0; z < MAXMOTOR; z++) |
||
336 | { |
||
442 | Brean | 337 | data->motor.mixer_yaw[z] = Setting.value(QString("Motor%1").arg(z+1), 0).toInt(); |
307 | KeyOz | 338 | } |
339 | Setting.endGroup(); |
||
442 | Brean | 340 | |
341 | if (data->motor.mixer_version == VERSION_MIXER) |
||
307 | KeyOz | 342 | { |
343 | set_MotorData(); |
||
344 | } |
||
345 | } |
||
346 | } |
||
347 | |||
348 | void dlg_MotorMixer::slot_pb_SAVE() |
||
349 | { |
||
358 | KeyOz | 350 | QString Filename = QFileDialog::getSaveFileName(this, tr("Mikrokopter MotorMixer speichern"), o_Settings->DIR.Parameter + "/" + le_NAME->text(), tr("MK MotorMixer(*.mkm);;Alle Dateien (*)")); |
307 | KeyOz | 351 | |
352 | if (!Filename.isEmpty()) |
||
353 | { |
||
354 | if (!(Filename.endsWith(".mkm", Qt::CaseInsensitive))) |
||
355 | { |
||
356 | Filename = Filename + QString(".mkm"); |
||
357 | } |
||
358 | |||
359 | get_MotorData(); |
||
360 | |||
361 | QSettings Setting(Filename, QSettings::IniFormat); |
||
362 | |||
363 | Setting.beginGroup("Info"); |
||
442 | Brean | 364 | Setting.setValue("Name", data->motor.mixer_name.c_str()); |
365 | Setting.setValue("Version", data->motor.mixer_version); |
||
307 | KeyOz | 366 | Setting.endGroup(); |
367 | |||
368 | Setting.beginGroup("Gas"); |
||
369 | for (int z = 0; z < MAXMOTOR; z++) |
||
370 | { |
||
442 | Brean | 371 | Setting.setValue(QString("Motor%1").arg(z+1), data->motor.mixer_gas[z]); |
307 | KeyOz | 372 | } |
373 | Setting.endGroup(); |
||
374 | |||
375 | Setting.beginGroup("Nick"); |
||
376 | for (int z = 0; z < MAXMOTOR; z++) |
||
377 | { |
||
442 | Brean | 378 | Setting.setValue(QString("Motor%1").arg(z+1), data->motor.mixer_nick[z]); |
307 | KeyOz | 379 | } |
380 | Setting.endGroup(); |
||
381 | |||
382 | Setting.beginGroup("Roll"); |
||
383 | for (int z = 0; z < MAXMOTOR; z++) |
||
384 | { |
||
442 | Brean | 385 | Setting.setValue(QString("Motor%1").arg(z+1), data->motor.mixer_roll[z]); |
307 | KeyOz | 386 | } |
387 | Setting.endGroup(); |
||
388 | |||
389 | Setting.beginGroup("Yaw"); |
||
390 | for (int z = 0; z < MAXMOTOR; z++) |
||
391 | { |
||
442 | Brean | 392 | Setting.setValue(QString("Motor%1").arg(z+1), data->motor.mixer_yaw[z]); |
307 | KeyOz | 393 | } |
394 | Setting.endGroup(); |
||
395 | } |
||
396 | } |