comparison Discovery/Src/t7.c @ 110:cc8e24374b83 FlipDisplay

Added option to handled mirrored display to existing functions
author Ideenmodellierer
date Tue, 01 Jan 2019 21:02:17 +0100
parents 8f8ea3a32e82
children 3834b6272ee5
comparison
equal deleted inserted replaced
109:65a6e352ce08 110:cc8e24374b83
185 * right of box are 249 px (551 .. 799) 185 * right of box are 249 px (551 .. 799)
186 */ 186 */
187 187
188 #define CUSTOMBOX_LINE_LEFT (250) 188 #define CUSTOMBOX_LINE_LEFT (250)
189 #define CUSTOMBOX_LINE_RIGHT (549) 189 #define CUSTOMBOX_LINE_RIGHT (549)
190 #define CUSTOMBOX_LINE_TOP (0)
191 #define CUSTOMBOX_LINE_MIDDLE (142)
192 #define CUSTOMBOX_LINE_BOTTOM (318)
190 #define CUSTOMBOX_INSIDE_OFFSET (2) 193 #define CUSTOMBOX_INSIDE_OFFSET (2)
191 #define CUSTOMBOX_OUTSIDE_OFFSET (2) 194 #define CUSTOMBOX_OUTSIDE_OFFSET (2)
192 #define CUSTOMBOX_SPACE_INSIDE (CUSTOMBOX_LINE_RIGHT + 1 - (CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET + CUSTOMBOX_INSIDE_OFFSET)) 195 #define CUSTOMBOX_SPACE_INSIDE (CUSTOMBOX_LINE_RIGHT + 1 - (CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET + CUSTOMBOX_INSIDE_OFFSET))
193 196 #define TOP_LINE_HIGHT (25)
194 197
195 /* Exported functions --------------------------------------------------------*/ 198 /* Exported functions --------------------------------------------------------*/
196 199
197 void t7_init(void) 200 void t7_init(void)
198 { 201 {
202
203 SSettings* pSettings;
204 pSettings = settingsGetPointer();
205
206
199 if(getLicence() == LICENCEBONEX) 207 if(getLicence() == LICENCEBONEX)
200 { 208 {
201 customviewsDive = customviewsDiveScooter; 209 customviewsDive = customviewsDiveScooter;
202 customviewsSurface = customviewsSurfaceScooter; 210 customviewsSurface = customviewsSurfaceScooter;
203 } 211 }
213 t7screenCompass.FBStartAdress = 0; 221 t7screenCompass.FBStartAdress = 0;
214 t7screenCompass.ImageHeight = 240; 222 t7screenCompass.ImageHeight = 240;
215 t7screenCompass.ImageWidth = 1600; 223 t7screenCompass.ImageWidth = 1600;
216 t7screenCompass.LayerIndex = 0; 224 t7screenCompass.LayerIndex = 0;
217 225
226 if(!pSettings->FlipDisplay)
227 {
228 t7l1.Image = &t7screen;
229 t7l1.WindowNumberOfTextLines = 2;
230 t7l1.WindowLineSpacing = 19; // Abstand von Y0
231 t7l1.WindowTab = 100; // vermtl. ohne Verwendung in diesem Fenster
232 t7l1.WindowX0 = 0;
233 t7l1.WindowX1 = CUSTOMBOX_LINE_LEFT - CUSTOMBOX_OUTSIDE_OFFSET;
234 t7l1.WindowY0 = 318;
235 t7l1.WindowY1 = 479;
236
237 t7l2.Image = &t7screen;
238 t7l2.WindowNumberOfTextLines = 2;
239 t7l2.WindowLineSpacing = 22; // Abstand von Y0
240 t7l2.WindowTab = 100; // vermtl. ohne Verwendung in diesem Fenster
241 t7l2.WindowX0 = 0;
242 t7l2.WindowX1 = t7l1.WindowX1;
243 t7l2.WindowY0 = 142;
244 t7l2.WindowY1 = t7l1.WindowY0 - 5;
245
246 t7l3.Image = &t7screen;
247 t7l3.WindowNumberOfTextLines = 2;
248 t7l3.WindowLineSpacing = 58; // Abstand von Y0
249 t7l3.WindowTab = 100; // vermtl. ohne Verwendung in diesem Fenster
250 t7l3.WindowX0 = 0;
251 t7l3.WindowX1 = t7l1.WindowX1;
252 t7l3.WindowY0 = 0;
253 t7l3.WindowY1 = t7l2.WindowY0 - 5;
254
255 t7r1.Image = &t7screen;
256 t7r1.WindowNumberOfTextLines = 2;
257 t7r1.WindowLineSpacing = t7l1.WindowLineSpacing;
258 t7r1.WindowTab = 100;
259 t7r1.WindowX0 = 550;
260 t7r1.WindowX1 = 799;
261 t7r1.WindowY0 = t7l1.WindowY0;
262 t7r1.WindowY1 = 479;
263
264 t7r2.Image = &t7screen;
265 t7r2.WindowNumberOfTextLines = 2;
266 t7r2.WindowLineSpacing = t7l2.WindowLineSpacing;
267 t7r2.WindowTab = 100;
268 t7r2.WindowX0 = 550;
269 t7r2.WindowX1 = 799;
270 t7r2.WindowY0 = t7l2.WindowY0;
271 t7r2.WindowY1 = t7l2.WindowY1;
272
273 t7r3.Image = &t7screen;
274 t7r3.WindowNumberOfTextLines = 2;
275 t7r3.WindowLineSpacing = 0;//t7l3.WindowLineSpacing;
276 t7r3.WindowTab = 100;
277 t7r3.WindowX0 = CUSTOMBOX_LINE_RIGHT + CUSTOMBOX_OUTSIDE_OFFSET;
278 t7r3.WindowX1 = 799;
279 t7r3.WindowY0 = t7l3.WindowY0;
280 t7r3.WindowY1 = t7l3.WindowY1;
281
282 t7cC.Image = &t7screen;
283 t7cC.WindowNumberOfTextLines = 3;
284 t7cC.WindowLineSpacing = 95; // Abstand von Y0
285 t7cC.WindowTab = 100;
286 t7cC.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
287 t7cC.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET;
288 t7cC.WindowY0 = 90;
289 t7cC.WindowY1 = 434 - 95;
290
291 t7cH.Image = &t7screen;
292 t7cH.WindowNumberOfTextLines = 1;
293 t7cH.WindowLineSpacing = 95; // Abstand von Y0
294 t7cH.WindowTab = 100;
295 t7cH.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
296 t7cH.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET;
297 t7cH.WindowY0 = 434 - 94;
298 t7cH.WindowY1 = 434;
299
300 t7cW.Image = &t7screen;
301 t7cW.WindowNumberOfTextLines = 3;
302 t7cW.WindowLineSpacing = 95; // Abstand von Y0
303 t7cW.WindowTab = 100;
304 t7cW.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
305 t7cW.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET;
306 t7cW.WindowY0 = 90;
307 t7cW.WindowY1 = 434 - 95;
308
309
310 t7surfaceL.Image = &t7screen;
311 t7surfaceL.WindowNumberOfTextLines = 9;
312 t7surfaceL.WindowLineSpacing = 53;
313 t7surfaceL.WindowTab = 100;
314 t7surfaceL.WindowX0 = 0;
315 t7surfaceL.WindowX1 = CUSTOMBOX_LINE_LEFT - CUSTOMBOX_OUTSIDE_OFFSET;
316 t7surfaceL.WindowY0 = 0;
317 t7surfaceL.WindowY1 = 480;
318
319 t7surfaceR.Image = &t7screen;
320 t7surfaceR.WindowNumberOfTextLines = 9;
321 t7surfaceR.WindowLineSpacing = 53;
322 t7surfaceR.WindowTab = 100;
323 t7surfaceR.WindowX0 = CUSTOMBOX_LINE_RIGHT + CUSTOMBOX_OUTSIDE_OFFSET;
324 t7surfaceR.WindowX1 = 800;
325 t7surfaceR.WindowY0 = 0;
326 t7surfaceR.WindowY1 = 480;
327
328 t7cY0free.Image = &t7screen;
329 t7cY0free.WindowNumberOfTextLines = 1;
330 t7cY0free.WindowLineSpacing = 95;
331 t7cY0free.WindowTab = 100;
332 t7cY0free.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
333 t7cY0free.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET;
334 t7cY0free.WindowY0 = 90;
335 t7cY0free.WindowY1 = 434 - 95;
336
337 t7batt.Image = &t7screen;
338 t7batt.WindowNumberOfTextLines = 1;
339 t7batt.WindowLineSpacing = 10;
340 t7batt.WindowTab = 100;
341 t7batt.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET;
342 t7batt.WindowX0 = t7batt.WindowX1 - (52+52);
343 t7batt.WindowY1 = 479;
344 t7batt.WindowY0 = t7batt.WindowY1 - 25;
345
346 t7charge.Image = &t7screen;
347 t7charge.WindowNumberOfTextLines = 1;
348 t7charge.WindowLineSpacing = 10;
349 t7charge.WindowTab = 100;
350 t7charge.WindowX1 = t7batt.WindowX1 - 18;
351 t7charge.WindowX0 = t7charge.WindowX1 - 14;
352 t7charge.WindowY1 = 479;
353 t7charge.WindowY0 = t7batt.WindowY1 - 25;
354
355 t7voltage.Image = &t7screen;
356 t7voltage.WindowNumberOfTextLines = 1;
357 t7voltage.WindowLineSpacing = 10;
358 t7voltage.WindowTab = 100;
359 t7voltage.WindowX0 = t7charge.WindowX0 - 30; //10
360 t7voltage.WindowX1 = t7voltage.WindowX0 + (18*3)+ 9;
361 t7voltage.WindowY1 = 479;
362 t7voltage.WindowY0 = t7batt.WindowY1 - 25;
363
364 t7c1.Image = &t7screen;
365 t7c1.WindowNumberOfTextLines = 1;
366 t7c1.WindowLineSpacing = 10;
367 t7c1.WindowTab = 100;
368 t7c1.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
369 t7c1.WindowX1 = t7batt.WindowX0 - 18;
370 t7c1.WindowY0 = 435;
371 t7c1.WindowY1 = 479;
372
373 t7c2.Image = &t7screen;
374 t7c2.WindowNumberOfTextLines = 1;
375 t7c2.WindowLineSpacing = 0; // Abstand von Y0
376 t7c2.WindowTab = 100;
377 t7c2.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
378 t7c2.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET;
379 t7c2.WindowY0 = 0;
380 t7c2.WindowY1 = 69;
381
382 t7pCompass.Image = &t7screenCompass;
383 t7pCompass.WindowNumberOfTextLines = 1;
384 t7pCompass.WindowLineSpacing = 100; // Abstand von Y0
385 t7pCompass.WindowTab = 100;
386 t7pCompass.WindowX0 = 0;
387 t7pCompass.WindowX1 = 1600-1;
388 t7pCompass.WindowY0 = 0;
389 t7pCompass.WindowY1 = 100-1;
390 }
391 else
392 {
393 /* 6 segments (left / right) used to show data during dive */
394
218 t7l1.Image = &t7screen; 395 t7l1.Image = &t7screen;
219 t7l1.WindowNumberOfTextLines = 2; 396 t7l1.WindowNumberOfTextLines = 2;
220 t7l1.WindowLineSpacing = 19; // Abstand von Y0 397 t7l1.WindowLineSpacing = 19; // Abstand von Y0
221 t7l1.WindowTab = 100; // vermtl. ohne Verwendung in diesem Fenster 398 t7l1.WindowTab = 100; // vermtl. ohne Verwendung in diesem Fenster
222 t7l1.WindowX0 = 0; 399 t7l1.WindowX0 = CUSTOMBOX_LINE_RIGHT + CUSTOMBOX_OUTSIDE_OFFSET;
223 t7l1.WindowX1 = CUSTOMBOX_LINE_LEFT - CUSTOMBOX_OUTSIDE_OFFSET; 400 t7l1.WindowX1 = 799;
224 t7l1.WindowY0 = 318; 401 t7l1.WindowY0 = CUSTOMBOX_LINE_TOP;
225 t7l1.WindowY1 = 479; 402 t7l1.WindowY1 = 150 + TOP_LINE_HIGHT;
226 403
227 t7l2.Image = &t7screen; 404 t7l2.Image = &t7screen;
228 t7l2.WindowNumberOfTextLines = 2; 405 t7l2.WindowNumberOfTextLines = 2;
229 t7l2.WindowLineSpacing = 22; // Abstand von Y0 406 t7l2.WindowLineSpacing = 22; // Abstand von Y0
230 t7l2.WindowTab = 100; // vermtl. ohne Verwendung in diesem Fenster 407 t7l2.WindowTab = 100; // vermtl. ohne Verwendung in diesem Fenster
231 t7l2.WindowX0 = 0; 408 t7l2.WindowX0 = t7l1.WindowX0;
232 t7l2.WindowX1 = t7l1.WindowX1; 409 t7l2.WindowX1 = t7l1.WindowX1;
233 t7l2.WindowY0 = 142; 410 t7l2.WindowY0 = t7l1.WindowY1 + 5;
234 t7l2.WindowY1 = t7l1.WindowY0 - 5; 411 t7l2.WindowY1 = t7l2.WindowY0 + 146;
235 412
236 t7l3.Image = &t7screen; 413 t7l3.Image = &t7screen;
237 t7l3.WindowNumberOfTextLines = 2; 414 t7l3.WindowNumberOfTextLines = 2;
238 t7l3.WindowLineSpacing = 58; // Abstand von Y0 415 t7l3.WindowLineSpacing = 58; // Abstand von Y0
239 t7l3.WindowTab = 100; // vermtl. ohne Verwendung in diesem Fenster 416 t7l3.WindowTab = 100; // vermtl. ohne Verwendung in diesem Fenster
240 t7l3.WindowX0 = 0; 417 t7l3.WindowX0 = t7l1.WindowX0;
241 t7l3.WindowX1 = t7l1.WindowX1; 418 t7l3.WindowX1 = t7l1.WindowX1;;
242 t7l3.WindowY0 = 0; 419 t7l3.WindowY0 = 479 - 150;
243 t7l3.WindowY1 = t7l2.WindowY0 - 5; 420 t7l3.WindowY1 = 479;
244 421
245 t7r1.Image = &t7screen; 422 t7r1.Image = &t7screen;
246 t7r1.WindowNumberOfTextLines = 2; 423 t7r1.WindowNumberOfTextLines = 2;
247 t7r1.WindowLineSpacing = t7l1.WindowLineSpacing; 424 t7r1.WindowLineSpacing = t7l1.WindowLineSpacing;
248 t7r1.WindowTab = 100; 425 t7r1.WindowTab = 100;
249 t7r1.WindowX0 = 550; 426 t7r1.WindowX0 = 0;
250 t7r1.WindowX1 = 799; 427 t7r1.WindowX1 = CUSTOMBOX_LINE_LEFT - CUSTOMBOX_OUTSIDE_OFFSET;
251 t7r1.WindowY0 = t7l1.WindowY0; 428 t7r1.WindowY0 = t7l1.WindowY0;
252 t7r1.WindowY1 = 479; 429 t7r1.WindowY1 = t7l1.WindowY1;
253 430
254 t7r2.Image = &t7screen; 431 t7r2.Image = &t7screen;
255 t7r2.WindowNumberOfTextLines = 2; 432 t7r2.WindowNumberOfTextLines = 2;
256 t7r2.WindowLineSpacing = t7l2.WindowLineSpacing; 433 t7r2.WindowLineSpacing = t7l2.WindowLineSpacing;
257 t7r2.WindowTab = 100; 434 t7r2.WindowTab = 100;
258 t7r2.WindowX0 = 550; 435 t7r2.WindowX0 = t7r1.WindowX0;
259 t7r2.WindowX1 = 799; 436 t7r2.WindowX1 = t7r1.WindowX1;
260 t7r2.WindowY0 = t7l2.WindowY0; 437 t7r2.WindowY0 = t7l2.WindowY0;
261 t7r2.WindowY1 = t7l2.WindowY1; 438 t7r2.WindowY1 = t7l2.WindowY1;
262 439
263 t7r3.Image = &t7screen; 440 t7r3.Image = &t7screen;
264 t7r3.WindowNumberOfTextLines = 2; 441 t7r3.WindowNumberOfTextLines = 2;
265 t7r3.WindowLineSpacing = 0;//t7l3.WindowLineSpacing; 442 t7r3.WindowLineSpacing = 0;//t7l3.WindowLineSpacing;
266 t7r3.WindowTab = 100; 443 t7r3.WindowTab = 100;
267 t7r3.WindowX0 = CUSTOMBOX_LINE_RIGHT + CUSTOMBOX_OUTSIDE_OFFSET; 444 t7r3.WindowX0 = t7r1.WindowX0;
268 t7r3.WindowX1 = 799; 445 t7r3.WindowX1 = t7r1.WindowX1;
269 t7r3.WindowY0 = t7l3.WindowY0; 446 t7r3.WindowY0 = t7l3.WindowY0;
270 t7r3.WindowY1 = t7l3.WindowY1; 447 t7r3.WindowY1 = t7l3.WindowY1;
271 448
449 /* screen for CustomText / serial number */
272 t7cC.Image = &t7screen; 450 t7cC.Image = &t7screen;
273 t7cC.WindowNumberOfTextLines = 3; 451 t7cC.WindowNumberOfTextLines = 3;
274 t7cC.WindowLineSpacing = 95; // Abstand von Y0 452 t7cC.WindowLineSpacing = 95; // Abstand von Y0
275 t7cC.WindowTab = 100; 453 t7cC.WindowTab = 100;
276 t7cC.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET; 454 t7cC.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
277 t7cC.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET; 455 t7cC.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET;
278 t7cC.WindowY0 = 90; 456 t7cC.WindowY0 = 165; //90;
279 t7cC.WindowY1 = 434 - 95; 457 t7cC.WindowY1 = 415;
280 458
459 /* used by warning message box */
281 t7cH.Image = &t7screen; 460 t7cH.Image = &t7screen;
282 t7cH.WindowNumberOfTextLines = 1; 461 t7cH.WindowNumberOfTextLines = 1;
283 t7cH.WindowLineSpacing = 95; // Abstand von Y0 462 t7cH.WindowLineSpacing = 95; // Abstand von Y0
284 t7cH.WindowTab = 100; 463 t7cH.WindowTab = 100;
285 t7cH.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET; 464 t7cH.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
286 t7cH.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET; 465 t7cH.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET;
287 t7cH.WindowY0 = 434 - 94; 466 t7cH.WindowY0 = 46; //480 - 434;
288 t7cH.WindowY1 = 434; 467 t7cH.WindowY1 = 390 - 46;// - 90; //46 + 390; //480 - (434 - 94); //434;
289 468
469 /* used by warning custom box */
290 t7cW.Image = &t7screen; 470 t7cW.Image = &t7screen;
291 t7cW.WindowNumberOfTextLines = 3; 471 t7cW.WindowNumberOfTextLines = 3;
292 t7cW.WindowLineSpacing = 95; // Abstand von Y0 472 t7cW.WindowLineSpacing = 95; // Abstand von Y0
293 t7cW.WindowTab = 100; 473 t7cW.WindowTab = 100;
294 t7cW.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET; 474 t7cW.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
295 t7cW.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET; 475 t7cW.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET;
296 t7cW.WindowY0 = 90; 476 t7cW.WindowY0 = 480 - (434 - 90);
297 t7cW.WindowY1 = 434 - 95; 477 t7cW.WindowY1 = 480 - 90; //434 - 95;
298 478
479 /* time and environment */
299 t7surfaceL.Image = &t7screen; 480 t7surfaceL.Image = &t7screen;
300 t7surfaceL.WindowNumberOfTextLines = 9; 481 t7surfaceL.WindowNumberOfTextLines = 9;
301 t7surfaceL.WindowLineSpacing = 53; 482 t7surfaceL.WindowLineSpacing = 53;
302 t7surfaceL.WindowTab = 100; 483 t7surfaceL.WindowTab = 100;
303 t7surfaceL.WindowX0 = 0; 484 t7surfaceL.WindowX0 = CUSTOMBOX_LINE_RIGHT + CUSTOMBOX_OUTSIDE_OFFSET;
304 t7surfaceL.WindowX1 = CUSTOMBOX_LINE_LEFT - CUSTOMBOX_OUTSIDE_OFFSET; 485 t7surfaceL.WindowX1 = 799;
305 t7surfaceL.WindowY0 = 0; 486 t7surfaceL.WindowY0 = 0;
306 t7surfaceL.WindowY1 = 480; 487 t7surfaceL.WindowY1 = 479;
307 488
308 t7surfaceR.Image = &t7screen; 489 t7surfaceR.Image = &t7screen;
309 t7surfaceR.WindowNumberOfTextLines = 9; 490 t7surfaceR.WindowNumberOfTextLines = 9;
310 t7surfaceR.WindowLineSpacing = 53; 491 t7surfaceR.WindowLineSpacing = 53;
311 t7surfaceR.WindowTab = 100; 492 t7surfaceR.WindowTab = 100;
312 t7surfaceR.WindowX0 = CUSTOMBOX_LINE_RIGHT + CUSTOMBOX_OUTSIDE_OFFSET; 493 t7surfaceR.WindowX0 = 0;
313 t7surfaceR.WindowX1 = 800; 494 t7surfaceR.WindowX1 = CUSTOMBOX_LINE_LEFT - CUSTOMBOX_OUTSIDE_OFFSET;
314 t7surfaceR.WindowY0 = 0; 495 t7surfaceR.WindowY0 = 0;
315 t7surfaceR.WindowY1 = 480; 496 t7surfaceR.WindowY1 = 479;
316 497
498 /* info screen in the middle */
317 t7cY0free.Image = &t7screen; 499 t7cY0free.Image = &t7screen;
318 t7cY0free.WindowNumberOfTextLines = 1; 500 t7cY0free.WindowNumberOfTextLines = 1;
319 t7cY0free.WindowLineSpacing = 95; 501 t7cY0free.WindowLineSpacing = 95;
320 t7cY0free.WindowTab = 100; 502 t7cY0free.WindowTab = 100;
321 t7cY0free.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET; 503 t7cY0free.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
322 t7cY0free.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET; 504 t7cY0free.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET;
323 t7cY0free.WindowY0 = 90; 505 t7cY0free.WindowY0 = 115;
324 t7cY0free.WindowY1 = 434 - 95; 506 t7cY0free.WindowY1 = 365;
325 507
508 /* voltage value (V or %) */
509 t7voltage.Image = &t7screen;
510 t7voltage.WindowNumberOfTextLines = 1;
511 t7voltage.WindowLineSpacing = 10;
512 t7voltage.WindowTab = 100;
513 t7voltage.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
514 t7voltage.WindowX1 = t7voltage.WindowX0 + (18*3) +9;
515 t7voltage.WindowY1 = TOP_LINE_HIGHT;
516 t7voltage.WindowY0 = 0;
517
518 /* battery symbol */
326 t7batt.Image = &t7screen; 519 t7batt.Image = &t7screen;
327 t7batt.WindowNumberOfTextLines = 1; 520 t7batt.WindowNumberOfTextLines = 1;
328 t7batt.WindowLineSpacing = 10; 521 t7batt.WindowLineSpacing = 10;
329 t7batt.WindowTab = 100; 522 t7batt.WindowTab = 100;
330 t7batt.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET; 523 t7batt.WindowX0 = t7voltage.WindowX1;
331 t7batt.WindowX0 = t7batt.WindowX1 - (52+52); 524 t7batt.WindowX1 = t7batt.WindowX0 + (52);
332 t7batt.WindowY1 = 479; 525 t7batt.WindowY1 = TOP_LINE_HIGHT;
333 t7batt.WindowY0 = t7batt.WindowY1 - 25; 526 t7batt.WindowY0 = 0;
334 527
528 /* charger symbol */
335 t7charge.Image = &t7screen; 529 t7charge.Image = &t7screen;
336 t7charge.WindowNumberOfTextLines = 1; 530 t7charge.WindowNumberOfTextLines = 1;
337 t7charge.WindowLineSpacing = 10; 531 t7charge.WindowLineSpacing = 10;
338 t7charge.WindowTab = 100; 532 t7charge.WindowTab = 100;
339 t7charge.WindowX1 = t7batt.WindowX1 - 18; 533 t7charge.WindowX1 = t7batt.WindowX0 - 18;
340 t7charge.WindowX0 = t7charge.WindowX1 - 14; 534 t7charge.WindowX0 = t7charge.WindowX1 - 14;
341 t7charge.WindowY1 = 479; 535
342 t7charge.WindowY0 = t7batt.WindowY1 - 25; 536 t7charge.WindowY1 = TOP_LINE_HIGHT;
343 537 t7charge.WindowY0 = 0;
344 t7voltage.Image = &t7screen; 538
345 t7voltage.WindowNumberOfTextLines = 1; 539 /* show dive mode OC / CC */
346 t7voltage.WindowLineSpacing = 10;
347 t7voltage.WindowTab = 100;
348 t7voltage.WindowX0 = t7charge.WindowX0 - 10;
349 t7voltage.WindowX1 = t7voltage.WindowX0 + (18*3)+ 9;
350 t7voltage.WindowY1 = 479;
351 t7voltage.WindowY0 = t7batt.WindowY1 - 25;
352
353 t7c1.Image = &t7screen; 540 t7c1.Image = &t7screen;
354 t7c1.WindowNumberOfTextLines = 1; 541 t7c1.WindowNumberOfTextLines = 1;
355 t7c1.WindowLineSpacing = 10; 542 t7c1.WindowLineSpacing = 10;
356 t7c1.WindowTab = 100; 543 t7c1.WindowTab = 100;
357 t7c1.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET; 544 t7c1.WindowX0 = t7batt.WindowX1 + 18; //CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
358 t7c1.WindowX1 = t7batt.WindowX0 - 18; 545 t7c1.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET; //t7batt.WindowX1 + 18;
359 t7c1.WindowY0 = 435; 546 t7c1.WindowY0 = 0;
360 t7c1.WindowY1 = 479; 547 t7c1.WindowY1 = 479 - 435;
361 548
549 /* Gas warnings and exit Sim*/
362 t7c2.Image = &t7screen; 550 t7c2.Image = &t7screen;
363 t7c2.WindowNumberOfTextLines = 1; 551 t7c2.WindowNumberOfTextLines = 1;
364 t7c2.WindowLineSpacing = 0; // Abstand von Y0 552 t7c2.WindowLineSpacing = 0; // Abstand von Y0
365 t7c2.WindowTab = 100; 553 t7c2.WindowTab = 100;
366 t7c2.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET; 554 t7c2.WindowX0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
367 t7c2.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET; 555 t7c2.WindowX1 = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_INSIDE_OFFSET;
368 t7c2.WindowY0 = 0; 556 t7c2.WindowY0 = 480 - 69;
369 t7c2.WindowY1 = 69; 557 t7c2.WindowY1 = 479;
370 558
559 /* Rotating compass */
371 t7pCompass.Image = &t7screenCompass; 560 t7pCompass.Image = &t7screenCompass;
372 t7pCompass.WindowNumberOfTextLines = 1; 561 t7pCompass.WindowNumberOfTextLines = 1;
373 t7pCompass.WindowLineSpacing = 100; // Abstand von Y0 562 t7pCompass.WindowLineSpacing = 100; // Abstand von Y0
374 t7pCompass.WindowTab = 100; 563 t7pCompass.WindowTab = 100;
375 t7pCompass.WindowX0 = 0; 564 t7pCompass.WindowX0 = 0;
376 t7pCompass.WindowX1 = 1600-1; 565 t7pCompass.WindowX1 = 1600-1;
377 t7pCompass.WindowY0 = 0; 566 t7pCompass.WindowY0 = 479 - 75;
378 t7pCompass.WindowY1 = 100-1; 567 t7pCompass.WindowY1 = 479;
568
569 }
379 570
380 init_t7_compass(); 571 init_t7_compass();
381 } 572 }
382 573
383 574
536 727
537 uint8_t oxygen_percentage, gasOffset, actualGasID; 728 uint8_t oxygen_percentage, gasOffset, actualGasID;
538 // uint16_t bottleFirstGas_bar; 729 // uint16_t bottleFirstGas_bar;
539 point_t start, stop;//, other; 730 point_t start, stop;//, other;
540 731
732 SSettings* pSettings;
733 pSettings = settingsGetPointer();
734
735
541 // update in all customview modes 736 // update in all customview modes
542 if(DataEX_check_RTE_version__needs_update() || font_update_required()) 737 if(DataEX_check_RTE_version__needs_update() || font_update_required())
543 updateNecessary = 1; 738 updateNecessary = 1;
544 else 739 else
545 updateNecessary = 0; 740 updateNecessary = 0;
546 741
547 /* buttons */ 742 /* buttons */
548 text[0] = TXT_2BYTE; 743 text[0] = TXT_2BYTE;
549 text[1] = TXT2BYTE_ButtonLogbook; 744 text[1] = TXT2BYTE_ButtonLogbook;
550 text[2] = 0; 745 text[2] = 0;
551 write_content_simple(&t7screen, 0, 800, 480-24, &FontT24,text,CLUT_ButtonSurfaceScreen); 746 write_content_simple(&t7screen, 0, 799, 479-TOP_LINE_HIGHT, &FontT24,text,CLUT_ButtonSurfaceScreen);
552 747
553 text[0] = '\001'; 748 text[0] = '\001';
554 text[1] = TXT_2BYTE; 749 text[1] = TXT_2BYTE;
555 text[2] = TXT2BYTE_ButtonView; 750 text[2] = TXT2BYTE_ButtonView;
556 text[3] = 0; 751 text[3] = 0;
557 write_content_simple(&t7screen, 0, 800, 480-24, &FontT24,text,CLUT_ButtonSurfaceScreen); 752 write_content_simple(&t7screen, 0, 799, 479-TOP_LINE_HIGHT, &FontT24,text,CLUT_ButtonSurfaceScreen);
558 753
559 text[0] = '\002'; 754 text[0] = '\002';
560 text[1] = TXT_2BYTE; 755 text[1] = TXT_2BYTE;
561 text[2] = TXT2BYTE_ButtonMenu; 756 text[2] = TXT2BYTE_ButtonMenu;
562 text[3] = 0; 757 text[3] = 0;
563 write_content_simple(&t7screen, 0, 800, 480-24, &FontT24,text,CLUT_ButtonSurfaceScreen); 758 write_content_simple(&t7screen, 0, 799, 479-TOP_LINE_HIGHT, &FontT24,text,CLUT_ButtonSurfaceScreen);
564 759
565 /* 760 /*
566 // scooter connected? 761 // scooter connected?
567 if(bC_getData(0,0,0,0) == BC_CONNECTED) 762 if(bC_getData(0,0,0,0) == BC_CONNECTED)
568 { 763 {
863 } 1058 }
864 */ 1059 */
865 // after gas name :-) 1060 // after gas name :-)
866 if(actualGasID > gasOffset) // security 1061 if(actualGasID > gasOffset) // security
867 { 1062 {
868 start.y = t7surfaceL.WindowY0 + (3 * t7surfaceL.WindowLineSpacing); 1063 if(!pSettings->FlipDisplay)
869 start.x = t7surfaceL.WindowX0 + ((stateUsed->lifeData.actualGas.GasIdInSettings - gasOffset - 1) * 35); 1064 {
1065 start.y = t7surfaceL.WindowY0 + (3 * t7surfaceL.WindowLineSpacing);
1066 start.x = t7surfaceL.WindowX0 + ((stateUsed->lifeData.actualGas.GasIdInSettings - gasOffset - 1) * 35);
1067 }
1068 else
1069 {
1070 start.y = t7surfaceR.WindowY0 + (3 * t7surfaceR.WindowLineSpacing);
1071 start.x = t7surfaceR.WindowX0 + ((stateUsed->lifeData.actualGas.GasIdInSettings - gasOffset - 1) * 35);
1072 }
1073
870 stop.x = start.x + 25; 1074 stop.x = start.x + 25;
871 stop.y = start.y + 52; 1075 stop.y = start.y + 52;
872 GFX_draw_box2(&t7screen, start, stop, CLUT_Font020, 1); 1076 GFX_draw_box2(&t7screen, start, stop, CLUT_Font020, 1);
873 } 1077 }
874 } 1078 }
919 if((stateUsed->lifeData.battery_charge > 0) && (stateUsed->lifeData.battery_charge < 140)) 1123 if((stateUsed->lifeData.battery_charge > 0) && (stateUsed->lifeData.battery_charge < 140))
920 { 1124 {
921 snprintf(text,16,"\004\025\f\002%u%%",(uint8_t)stateUsed->lifeData.battery_charge); 1125 snprintf(text,16,"\004\025\f\002%u%%",(uint8_t)stateUsed->lifeData.battery_charge);
922 if(warning_count_high_time) 1126 if(warning_count_high_time)
923 text[0] = '\a'; 1127 text[0] = '\a';
924 GFX_write_string(&FontT24,&t7batt,text,0); 1128 GFX_write_string(&FontT24,&t7voltage,text,0);
925 } 1129 }
926 else 1130 else
927 { 1131 {
928 snprintf(text,6,"\f%.1fV",stateUsed->lifeData.battery_voltage); 1132 snprintf(text,6,"\f%.1fV",stateUsed->lifeData.battery_voltage);
929 GFX_write_string(&FontT24,&t7voltage,text,0); 1133 GFX_write_string(&FontT24,&t7voltage,text,0);
934 GFX_write_string_color(&Batt24,&t7batt,text,0,CLUT_BatteryStandard); 1138 GFX_write_string_color(&Batt24,&t7batt,text,0,CLUT_BatteryStandard);
935 1139
936 if((stateUsed->lifeData.battery_charge > 0) && (stateUsed->lifeData.battery_charge < 140)) 1140 if((stateUsed->lifeData.battery_charge > 0) && (stateUsed->lifeData.battery_charge < 140))
937 { 1141 {
938 snprintf(text,16,"\f\002%u%%",(uint8_t)stateUsed->lifeData.battery_charge); 1142 snprintf(text,16,"\f\002%u%%",(uint8_t)stateUsed->lifeData.battery_charge);
939 GFX_write_string(&FontT24,&t7batt,text,0); 1143 // GFX_write_string(&FontT24,&t7batt,text,0);
1144 GFX_write_string(&FontT24,&t7voltage,text,0);
940 } 1145 }
941 else 1146 else
942 { 1147 {
943 snprintf(text,6,"\f%.1fV",stateUsed->lifeData.battery_voltage); 1148 snprintf(text,6,"\f%.1fV",stateUsed->lifeData.battery_voltage);
944 GFX_write_string(&FontT24,&t7voltage,text,0); 1149 GFX_write_string(&FontT24,&t7voltage,text,0);
1401 } 1606 }
1402 1607
1403 1608
1404 void t7_refresh_customview(void) 1609 void t7_refresh_customview(void)
1405 { 1610 {
1406 if((selection_customview == CVIEW_Scooter) && (getLicence() != LICENCEBONEX))
1407 t7_change_customview();
1408 if((selection_customview == CVIEW_Scooter) && (!DataEX_scooterFoundAndValidLicence() && (stateRealGetPointer()->mode == MODE_DIVE)))
1409 t7_change_customview();
1410 if((selection_customview == CVIEW_sensors) &&(stateUsed->diveSettings.ccrOption == 0))
1411 t7_change_customview();
1412 if((selection_customview == CVIEW_sensors_mV) &&(stateUsed->diveSettings.ccrOption == 0))
1413 t7_change_customview();
1414 if((selection_customview == CVIEW_sensors) &&(stateUsed->diveSettings.ccrOption == 0))
1415 t7_change_customview();
1416 1611
1417 char text[256]; 1612 char text[256];
1418 uint16_t textpointer = 0; 1613 uint16_t textpointer = 0;
1419 int16_t start; 1614 int16_t start;
1420 uint8_t lineCountCustomtext = 0; 1615 uint8_t lineCountCustomtext = 0;
1423 RTC_TimeTypeDef Stime; 1618 RTC_TimeTypeDef Stime;
1424 float fPpO2limitHigh, fPpO2limitLow, fPpO2ofGasAtThisDepth; // CVIEW_Gaslist 1619 float fPpO2limitHigh, fPpO2limitLow, fPpO2ofGasAtThisDepth; // CVIEW_Gaslist
1425 const SGasLine * pGasLine; // CVIEW_Gaslist 1620 const SGasLine * pGasLine; // CVIEW_Gaslist
1426 uint8_t oxygen, helium; // CVIEW_Gaslist 1621 uint8_t oxygen, helium; // CVIEW_Gaslist
1427 float depth, surface, fraction_nitrogen, fraction_helium, ead, end; // CVIEW_EADTime 1622 float depth, surface, fraction_nitrogen, fraction_helium, ead, end; // CVIEW_EADTime
1623
1624 SSettings* pSettings;
1625 pSettings = settingsGetPointer();
1626
1627
1628 if((selection_customview == CVIEW_Scooter) && (getLicence() != LICENCEBONEX))
1629 t7_change_customview();
1630 if((selection_customview == CVIEW_Scooter) && (!DataEX_scooterFoundAndValidLicence() && (stateRealGetPointer()->mode == MODE_DIVE)))
1631 t7_change_customview();
1632 if((selection_customview == CVIEW_sensors) &&(stateUsed->diveSettings.ccrOption == 0))
1633 t7_change_customview();
1634 if((selection_customview == CVIEW_sensors_mV) &&(stateUsed->diveSettings.ccrOption == 0))
1635 t7_change_customview();
1636 if((selection_customview == CVIEW_sensors) &&(stateUsed->diveSettings.ccrOption == 0))
1637 t7_change_customview();
1428 1638
1429 switch(selection_customview) 1639 switch(selection_customview)
1430 { 1640 {
1431 case CVIEW_noneOrDebug: 1641 case CVIEW_noneOrDebug:
1432 if(settingsGetPointer()->showDebugInfo) 1642 if(settingsGetPointer()->showDebugInfo)
1545 // header 1755 // header
1546 snprintf(text,100,"\032\f\001%c%c",TXT_2BYTE,TXT2BYTE_Gaslist); 1756 snprintf(text,100,"\032\f\001%c%c",TXT_2BYTE,TXT2BYTE_Gaslist);
1547 GFX_write_string(&FontT42,&t7cH,text,0); 1757 GFX_write_string(&FontT42,&t7cH,text,0);
1548 // content 1758 // content
1549 textpointer = 0; 1759 textpointer = 0;
1550 t7cY0free.WindowY0 = t7cC.WindowY0 - 10; 1760
1761 if(!pSettings->FlipDisplay)
1762 {
1763 t7cY0free.WindowY0 = t7cC.WindowY0 - 10;
1764 }
1765 else
1766 {
1767 t7cY0free.WindowY1 = 400;
1768 }
1551 t7cY0free.WindowLineSpacing = 48+9; 1769 t7cY0free.WindowLineSpacing = 48+9;
1552 t7cY0free.WindowNumberOfTextLines = 5; // NUM_GASES == 5 1770 t7cY0free.WindowNumberOfTextLines = 5; // NUM_GASES == 5
1553 t7cY0free.WindowTab = 420; 1771 t7cY0free.WindowTab = 420;
1554 1772
1555 pGasLine = settingsGetPointer()->gas; 1773 pGasLine = settingsGetPointer()->gas;
1586 snprintf(text,100,"\032\f\001%c%c",TXT_2BYTE,TXT2BYTE_Info ); 1804 snprintf(text,100,"\032\f\001%c%c",TXT_2BYTE,TXT2BYTE_Info );
1587 GFX_write_string(&FontT42,&t7cH,text,0); 1805 GFX_write_string(&FontT42,&t7cH,text,0);
1588 textpointer = 0; 1806 textpointer = 0;
1589 1807
1590 t7cY0free.WindowY0 = t7cC.WindowY0 - 10; 1808 t7cY0free.WindowY0 = t7cC.WindowY0 - 10;
1809 if(pSettings->FlipDisplay)
1810 {
1811 t7cY0free.WindowY1 = 400;
1812 }
1591 t7cY0free.WindowLineSpacing = 48; 1813 t7cY0free.WindowLineSpacing = 48;
1592 t7cY0free.WindowNumberOfTextLines = 6; 1814 t7cY0free.WindowNumberOfTextLines = 6;
1593 1815
1594 // time 1816 // time
1595 snprintf(text,100,"\032\001%c%c",TXT_2BYTE,TXT2BYTE_Clock ); 1817 snprintf(text,100,"\032\001%c%c",TXT_2BYTE,TXT2BYTE_Clock );
1714 case CVIEW_Compass: 1936 case CVIEW_Compass:
1715 default: 1937 default:
1716 snprintf(text,100,"\032\f\001%c%c",TXT_2BYTE, TXT2BYTE_Compass); 1938 snprintf(text,100,"\032\f\001%c%c",TXT_2BYTE, TXT2BYTE_Compass);
1717 GFX_write_string(&FontT42,&t7cH,text,0); 1939 GFX_write_string(&FontT42,&t7cH,text,0);
1718 t7_compass((uint16_t)stateUsed->lifeData.compass_heading, stateUsed->diveSettings.compassHeading); 1940 t7_compass((uint16_t)stateUsed->lifeData.compass_heading, stateUsed->diveSettings.compassHeading);
1719 t7cY0free.WindowY0 = 230; 1941
1720 t7cY0free.WindowX0 += 15; 1942 if(!pSettings->FlipDisplay)
1943 {
1944 t7cY0free.WindowX0 += 15;
1945 t7cY0free.WindowY0 = 230;
1946 }
1947 else
1948 {
1949 t7cY0free.WindowX0 -= 15;
1950 t7cY0free.WindowY0 = 0;
1951 t7cY0free.WindowY1 = 250;
1952 }
1721 snprintf(text,100,"\030\001%03i`",(uint16_t)stateUsed->lifeData.compass_heading); 1953 snprintf(text,100,"\030\001%03i`",(uint16_t)stateUsed->lifeData.compass_heading);
1722 GFX_write_string(&FontT54,&t7cY0free,text,0); 1954 GFX_write_string(&FontT54,&t7cY0free,text,0);
1723 t7cY0free.WindowX0 -= 15; 1955 if(!pSettings->FlipDisplay)
1956 {
1957 t7cY0free.WindowX0 -= 15;
1958 }
1959 else
1960 {
1961 t7cY0free.WindowX0 += 15;
1962 }
1724 break; 1963 break;
1725 1964
1726 case CVIEW_Decolist: 1965 case CVIEW_Decolist:
1727 snprintf(text,100,"\032\f\001 %c%c", TXT_2BYTE, TXT2BYTE_Decolist); 1966 snprintf(text,100,"\032\f\001 %c%c", TXT_2BYTE, TXT2BYTE_Decolist);
1728 GFX_write_string(&FontT42,&t7cH,text,0); 1967 GFX_write_string(&FontT42,&t7cH,text,0);
1763 textpointer += snprintf(&text[textpointer],20,"\030\034 %2u\016\016%c%c\017%3i'\n\r",depthNext, unit_depth_char1(), unit_depth_char2(), (pDecoinfo->output_stop_length_seconds[i]+59)/60); 2002 textpointer += snprintf(&text[textpointer],20,"\030\034 %2u\016\016%c%c\017%3i'\n\r",depthNext, unit_depth_char1(), unit_depth_char2(), (pDecoinfo->output_stop_length_seconds[i]+59)/60);
1764 else 2003 else
1765 textpointer += snprintf(&text[textpointer],20,"\031\034 %2u\016\016%c%c\017\n\r",depthNext, unit_depth_char1(), unit_depth_char2()); 2004 textpointer += snprintf(&text[textpointer],20,"\031\034 %2u\016\016%c%c\017\n\r",depthNext, unit_depth_char1(), unit_depth_char2());
1766 if(textpointer > 200) break; 2005 if(textpointer > 200) break;
1767 } 2006 }
1768 t7cY0free.WindowY0 = t7cC.WindowY0 - 10; 2007 if(!pSettings->FlipDisplay)
2008 {
2009 t7cY0free.WindowY0 = t7cC.WindowY0 - 10;
2010 }
2011 else
2012 {
2013 t7cY0free.WindowY0 = t7cC.WindowY0 - 10;
2014 t7cY0free.WindowY1 = 400;
2015 }
2016
1769 t7cY0free.WindowLineSpacing = 48; 2017 t7cY0free.WindowLineSpacing = 48;
1770 t7cY0free.WindowNumberOfTextLines = 6; 2018 t7cY0free.WindowNumberOfTextLines = 6;
1771 GFX_write_string(&FontT42, &t7cY0free, text, 1); 2019 GFX_write_string(&FontT42, &t7cY0free, text, 1);
1772 break; 2020 break;
1773 } 2021 }
1801 SDivetime SafetyStopTime = {0,0,0,0}; 2049 SDivetime SafetyStopTime = {0,0,0,0};
1802 SDivetime TimeoutTime = {0,0,0,0}; 2050 SDivetime TimeoutTime = {0,0,0,0};
1803 uint8_t customview_warnings = 0; 2051 uint8_t customview_warnings = 0;
1804 const SDecoinfo * pDecoinfo; 2052 const SDecoinfo * pDecoinfo;
1805 2053
2054 SSettings* pSettings;
2055 pSettings = settingsGetPointer();
2056
1806 Divetime.Total = stateUsed->lifeData.dive_time_seconds_without_surface_time; 2057 Divetime.Total = stateUsed->lifeData.dive_time_seconds_without_surface_time;
1807 Divetime.Minutes = Divetime.Total / 60; 2058 Divetime.Minutes = Divetime.Total / 60;
1808 Divetime.Seconds = Divetime.Total - ( Divetime.Minutes * 60 ); 2059 Divetime.Seconds = Divetime.Total - ( Divetime.Minutes * 60 );
1809 2060
1810 SafetyStopTime.Total = timer_Safetystop_GetCountDown(); 2061 SafetyStopTime.Total = timer_Safetystop_GetCountDown();
1896 GFX_write_string(&FontT105,&t7l2,TextL2,1); 2147 GFX_write_string(&FontT105,&t7l2,TextL2,1);
1897 2148
1898 /* ascentrate graph */ 2149 /* ascentrate graph */
1899 if(stateUsed->lifeData.ascent_rate_meter_per_min > 0) 2150 if(stateUsed->lifeData.ascent_rate_meter_per_min > 0)
1900 { 2151 {
1901 start.y = t7l1.WindowY0 - 1; 2152 if(!pSettings->FlipDisplay)
2153 {
2154 start.y = t7l1.WindowY0 - 1;
2155 }
2156 else
2157 {
2158 start.y = t7l3.WindowY0 - 25;
2159 }
2160
1902 for(int i = 0; i<4;i++) 2161 for(int i = 0; i<4;i++)
1903 { 2162 {
1904 start.y += 5*6; 2163 start.y += 5*6;
1905 stop.y = start.y; 2164 stop.y = start.y;
1906 start.x = CUSTOMBOX_LINE_LEFT - 1; 2165 start.x = CUSTOMBOX_LINE_LEFT - 1;
1911 // GFX_draw_line(&t7screen, start, stop, 0); 2170 // GFX_draw_line(&t7screen, start, stop, 0);
1912 } 2171 }
1913 // new thick bar design Sept. 2015 2172 // new thick bar design Sept. 2015
1914 start.x = CUSTOMBOX_LINE_LEFT - CUSTOMBOX_OUTSIDE_OFFSET - 3 - 5; 2173 start.x = CUSTOMBOX_LINE_LEFT - CUSTOMBOX_OUTSIDE_OFFSET - 3 - 5;
1915 stop.x = start.x; 2174 stop.x = start.x;
1916 start.y = t7l1.WindowY0 - 1; 2175 if(!pSettings->FlipDisplay)
2176 {
2177 start.y = t7l1.WindowY0 - 1;
2178 }
2179 else
2180 {
2181 start.y = t7l3.WindowY0 - 25;
2182 }
1917 stop.y = start.y + (uint16_t)(stateUsed->lifeData.ascent_rate_meter_per_min * 6); 2183 stop.y = start.y + (uint16_t)(stateUsed->lifeData.ascent_rate_meter_per_min * 6);
1918 stop.y -= 3; // wegen der Liniendicke von 12 anstelle von 9 2184 stop.y -= 3; // wegen der Liniendicke von 12 anstelle von 9
1919 if(stop.y >= 470) 2185 if(stop.y >= 470)
1920 stop.y = 470; 2186 stop.y = 470;
1921 start.y += 7; // starte etwas weiter oben 2187 start.y += 7; // starte etwas weiter oben
2225 if((stateUsed->lifeData.battery_charge > 0) && (stateUsed->lifeData.battery_charge < 140)) 2491 if((stateUsed->lifeData.battery_charge > 0) && (stateUsed->lifeData.battery_charge < 140))
2226 { 2492 {
2227 snprintf(TextC1,16,"\004\025\f\002%u%%",(uint8_t)stateUsed->lifeData.battery_charge); 2493 snprintf(TextC1,16,"\004\025\f\002%u%%",(uint8_t)stateUsed->lifeData.battery_charge);
2228 if(warning_count_high_time) 2494 if(warning_count_high_time)
2229 TextC1[0] = '\a'; 2495 TextC1[0] = '\a';
2230 GFX_write_string(&FontT24,&t7batt,TextC1,0); 2496 GFX_write_string(&FontT24,&t7voltage,TextC1,0);
2231 } 2497 }
2232 } 2498 }
2233 else 2499 else
2234 { 2500 {
2235 t7_colorscheme_mod(TextC1); 2501 t7_colorscheme_mod(TextC1);
2237 2503
2238 if((stateUsed->lifeData.battery_charge > 0) && (stateUsed->lifeData.battery_charge < 140)) 2504 if((stateUsed->lifeData.battery_charge > 0) && (stateUsed->lifeData.battery_charge < 140))
2239 { 2505 {
2240 snprintf(TextC1,16,"\020\f\002%u%%",(uint8_t)stateUsed->lifeData.battery_charge); 2506 snprintf(TextC1,16,"\020\f\002%u%%",(uint8_t)stateUsed->lifeData.battery_charge);
2241 t7_colorscheme_mod(TextC1); 2507 t7_colorscheme_mod(TextC1);
2242 GFX_write_string(&FontT24,&t7batt,TextC1,0); 2508 GFX_write_string(&FontT24,&t7voltage,TextC1,0); // t7batt
2243 } 2509 }
2244 } 2510 }
2245 2511
2246 /* customizable left lower corner */ 2512 /* customizable left lower corner */
2247 t7_refresh_divemode_userselected_left_lower_corner(); 2513 t7_refresh_divemode_userselected_left_lower_corner();
2482 void draw_frame(_Bool PluginBoxHeader, _Bool LinesOnTheSides, uint8_t colorBox, uint8_t colorLinesOnTheSide) 2748 void draw_frame(_Bool PluginBoxHeader, _Bool LinesOnTheSides, uint8_t colorBox, uint8_t colorLinesOnTheSide)
2483 { 2749 {
2484 point_t LeftLow, WidthHeight; 2750 point_t LeftLow, WidthHeight;
2485 point_t start, stop; 2751 point_t start, stop;
2486 2752
2753 SSettings* pSettings;
2754 pSettings = settingsGetPointer();
2755
2487 // plugin box 2756 // plugin box
2488 LeftLow.x = CUSTOMBOX_LINE_LEFT; 2757 LeftLow.x = CUSTOMBOX_LINE_LEFT;
2489 WidthHeight.x = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_LINE_LEFT; 2758 WidthHeight.x = CUSTOMBOX_LINE_RIGHT - CUSTOMBOX_LINE_LEFT;
2490 LeftLow.y = 60; 2759 LeftLow.y = 60;
2491 WidthHeight.y = 440 - LeftLow.y; 2760 WidthHeight.y = 440 - LeftLow.y;
2503 if(LinesOnTheSides) 2772 if(LinesOnTheSides)
2504 { 2773 {
2505 // aufteilung links 2774 // aufteilung links
2506 start.x = 0; 2775 start.x = 0;
2507 stop.x = CUSTOMBOX_LINE_LEFT; 2776 stop.x = CUSTOMBOX_LINE_LEFT;
2508 stop.y = start.y = t7l1.WindowY0 - 1; 2777 if(!pSettings->FlipDisplay)
2778 {
2779 stop.y = start.y = t7l1.WindowY0 - 1;
2780 }
2781 else
2782 {
2783 stop.y = start.y = 480 - t7l1.WindowY1 - 1;
2784 }
2785
2509 GFX_draw_line(&t7screen, start, stop, colorLinesOnTheSide); 2786 GFX_draw_line(&t7screen, start, stop, colorLinesOnTheSide);
2510 stop.y = start.y = t7l2.WindowY0 -1; 2787 if(!pSettings->FlipDisplay)
2788 {
2789 stop.y = start.y = t7l2.WindowY0 -1;
2790 }
2791 else
2792 {
2793 stop.y = start.y = 480 - t7l2.WindowY1 -1;
2794 }
2511 GFX_draw_line(&t7screen, start, stop, colorLinesOnTheSide); 2795 GFX_draw_line(&t7screen, start, stop, colorLinesOnTheSide);
2512 2796
2513 // aufteilung rechts 2797 // aufteilung rechts
2514 start.x = CUSTOMBOX_LINE_RIGHT; 2798 start.x = CUSTOMBOX_LINE_RIGHT;
2515 stop.x = 799; 2799 stop.x = 799;
2516 stop.y = start.y = t7l1.WindowY0 - 1; 2800 if(!pSettings->FlipDisplay)
2801 {
2802 stop.y = start.y = t7l1.WindowY0 - 1;
2803 }
2804 else
2805 {
2806 stop.y = start.y = 480 - t7l1.WindowY1 - 1;
2807 }
2808
2517 GFX_draw_line(&t7screen, start, stop, colorLinesOnTheSide); 2809 GFX_draw_line(&t7screen, start, stop, colorLinesOnTheSide);
2518 stop.y = start.y = t7l2.WindowY0 - 1; 2810 if(!pSettings->FlipDisplay)
2811 {
2812 stop.y = start.y = t7l2.WindowY0 - 1;
2813 }
2814 else
2815 {
2816 stop.y = start.y = 480 - t7l2.WindowY1 - 1;
2817 }
2519 GFX_draw_line(&t7screen, start, stop, colorLinesOnTheSide); 2818 GFX_draw_line(&t7screen, start, stop, colorLinesOnTheSide);
2520 } 2819 }
2521 } 2820 }
2522 2821
2523 2822
2539 const int radius[4] = {95,105,115,100}; 2838 const int radius[4] = {95,105,115,100};
2540 const point_t offset = {.x = 400, .y = 250}; 2839 const point_t offset = {.x = 400, .y = 250};
2541 2840
2542 static point_t r[4][360] = { 0 }; 2841 static point_t r[4][360] = { 0 };
2543 2842
2544 if(r[0][0].y == 0) 2843 if(r[0][0].y == 0) /* calc table at first call only */
2545 { 2844 {
2546 for(int i=0;i<360;i++) 2845 for(int i=0;i<360;i++)
2547 { 2846 {
2548 fCos = cos(i * piMult); 2847 fCos = cos(i * piMult);
2549 fSin = sin(i * piMult); 2848 fSin = sin(i * piMult);
2574 float percent_N2; 2873 float percent_N2;
2575 float percent_He; 2874 float percent_He;
2576 float partial_pressure_N2; 2875 float partial_pressure_N2;
2577 float partial_pressure_He; 2876 float partial_pressure_He;
2578 2877
2878 SSettings* pSettings;
2879 pSettings = settingsGetPointer();
2880
2579 2881
2580 /* N2 */ 2882 /* N2 */
2581 t7cY0free.WindowLineSpacing = 28 + 48 + 14; 2883 t7cY0free.WindowLineSpacing = 28 + 48 + 14;
2582 t7cY0free.WindowY0 = t7cH.WindowY0 - 5 - 2 * t7cY0free.WindowLineSpacing; 2884 if(!pSettings->FlipDisplay)
2885 {
2886 t7cY0free.WindowY0 = t7cH.WindowY0 - 5 - 2 * t7cY0free.WindowLineSpacing;
2887 }
2888 else
2889 {
2890 t7cY0free.WindowY0 = t7cH.WindowY0 + 15;
2891 t7cY0free.WindowY1 = t7cY0free.WindowY0 + 250;
2892 }
2583 t7cY0free.WindowNumberOfTextLines = 3; 2893 t7cY0free.WindowNumberOfTextLines = 3;
2584 2894
2585 text[textpointer++] = '\030'; 2895 text[textpointer++] = '\030';
2586 text[textpointer++] = TXT_2BYTE; 2896 text[textpointer++] = TXT_2BYTE;
2587 text[textpointer++] = TXT2BYTE_Nitrogen; 2897 text[textpointer++] = TXT2BYTE_Nitrogen;
2595 text[textpointer++] = TXT2BYTE_CNS; 2905 text[textpointer++] = TXT2BYTE_CNS;
2596 text[textpointer++] = 0; 2906 text[textpointer++] = 0;
2597 2907
2598 GFX_write_string(&FontT24, &t7cY0free, text, 1); 2908 GFX_write_string(&FontT24, &t7cY0free, text, 1);
2599 2909
2600 start.y = t7cH.WindowY0 - 5; 2910 if(!pSettings->FlipDisplay)
2911 {
2912 start.y = t7cH.WindowY0 - 5;
2913 }
2914 else
2915 {
2916 start.y = t7cH.WindowY1 - 5;
2917 }
2601 start.x = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET; 2918 start.x = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
2602 stop.x = start.x + CUSTOMBOX_SPACE_INSIDE; 2919 stop.x = start.x + CUSTOMBOX_SPACE_INSIDE;
2603 2920
2604 for(int i=0;i<16;i++) 2921 for(int i=0;i<16;i++)
2605 { 2922 {
2692 decom_get_inert_gases(pState->lifeData.pressure_ambient_bar, &pState->lifeData.actualGas, &percent_N2, &percent_He); 3009 decom_get_inert_gases(pState->lifeData.pressure_ambient_bar, &pState->lifeData.actualGas, &percent_N2, &percent_He);
2693 partial_pressure_N2 = (pState->lifeData.pressure_ambient_bar - WATER_VAPOUR_PRESSURE) * percent_N2; 3010 partial_pressure_N2 = (pState->lifeData.pressure_ambient_bar - WATER_VAPOUR_PRESSURE) * percent_N2;
2694 partial_pressure_He = (pState->lifeData.pressure_ambient_bar - WATER_VAPOUR_PRESSURE) * percent_He; 3011 partial_pressure_He = (pState->lifeData.pressure_ambient_bar - WATER_VAPOUR_PRESSURE) * percent_He;
2695 3012
2696 // Nitrogen vertical bar 3013 // Nitrogen vertical bar
2697 start.y = t7cH.WindowY0 + 1 - 5; 3014 if(!pSettings->FlipDisplay)
3015 {
3016 start.y = t7cH.WindowY0 + 1 - 5;
3017 }
3018 else
3019 {
3020 start.y = t7cH.WindowY1 - 5;
3021 }
3022
2698 stop.y = start.y - (3 * 15) - 1; 3023 stop.y = start.y - (3 * 15) - 1;
2699 if((percent_N2 > 0) && (partial_pressure_N2 > 0.8f))//(0.8f + 0.5f))) 3024 if((percent_N2 > 0) && (partial_pressure_N2 > 0.8f))//(0.8f + 0.5f)))
2700 { 3025 {
2701 value = partial_pressure_N2; 3026 value = partial_pressure_N2;
2702 value *= 80;//20 3027 value *= 80;//20
2716 stop.x = start.x; 3041 stop.x = start.x;
2717 GFX_draw_thick_line(2,&t7screen, start, stop, CLUT_EverythingOkayGreen); 3042 GFX_draw_thick_line(2,&t7screen, start, stop, CLUT_EverythingOkayGreen);
2718 3043
2719 3044
2720 // Helium vertical bar 3045 // Helium vertical bar
2721 start.y = t7cH.WindowY0 + 1 - 5 - 3*16 - 28 - 14; 3046 if(!pSettings->FlipDisplay)
3047 {
3048 start.y = t7cH.WindowY0 + 1 - 5 - 3*16 - 28 - 14;
3049 }
3050 else
3051 {
3052 start.y = t7cH.WindowY1 - 5 - 3*16 - 28 - 14;
3053 }
3054
2722 stop.y = start.y - (3 * 15) - 1; 3055 stop.y = start.y - (3 * 15) - 1;
2723 if((percent_He > 0) && (partial_pressure_He > 0.01f)) // 0.5f 3056 if((percent_He > 0) && (partial_pressure_He > 0.01f)) // 0.5f
2724 { 3057 {
2725 3058
2726 value = partial_pressure_He; 3059 value = partial_pressure_He;
2741 start.x = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET + front; 3074 start.x = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET + front;
2742 stop.x = start.x; 3075 stop.x = start.x;
2743 GFX_draw_thick_line(2,&t7screen, start, stop, CLUT_EverythingOkayGreen); 3076 GFX_draw_thick_line(2,&t7screen, start, stop, CLUT_EverythingOkayGreen);
2744 3077
2745 // Oxygen vertical bar 3078 // Oxygen vertical bar
2746 start.y = t7cH.WindowY0 + 1 - 5 - 6*16 - 2*28 - 2*14; 3079 if(!pSettings->FlipDisplay)
3080 {
3081 start.y = t7cH.WindowY0 + 1 - 5 - 6*16 - 2*28 - 2*14;
3082 }
3083 else
3084 {
3085 start.y = t7cH.WindowY1 - 5 - 6*16 - 2*28 - 2*14;
3086 }
3087
2747 stop.y = start.y - (3 * 15) - 1; 3088 stop.y = start.y - (3 * 15) - 1;
2748 3089
2749 start.x = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET + cns100pixel; 3090 start.x = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET + cns100pixel;
2750 stop.x = start.x; 3091 stop.x = start.x;
2751 GFX_draw_thick_line(2, &t7screen, start, stop, CLUT_WarningRed); 3092 GFX_draw_thick_line(2, &t7screen, start, stop, CLUT_WarningRed);
3093
2752 } 3094 }
2753 3095
2754 3096
2755 void t7_debug(void) 3097 void t7_debug(void)
2756 { 3098 {
3365 else 3707 else
3366 ActualHeading = lastHeading - resultKalman; 3708 ActualHeading = lastHeading - resultKalman;
3367 3709
3368 lastHeading = ActualHeading; 3710 lastHeading = ActualHeading;
3369 */ 3711 */
3712 uint16_t ActualHeadingRose;
3370 uint16_t LeftBorderHeading, LineHeading; 3713 uint16_t LeftBorderHeading, LineHeading;
3371 uint32_t offsetPicture; 3714 uint32_t offsetPicture;
3372 point_t start, stop, center; 3715 point_t start, stop, center;
3373 static int32_t LastHeading = 0; 3716 static int32_t LastHeading = 0;
3374 int32_t newHeading = 0; 3717 int32_t newHeading = 0;
3718 int32_t FlipHeading = 0;
3375 int32_t diff = 0; 3719 int32_t diff = 0;
3376 int32_t diff2 = 0; 3720 int32_t diff2 = 0;
3377 3721
3378 int32_t diffAbs = 0; 3722 int32_t diffAbs = 0;
3379 int32_t diffAbs2 = 0; 3723 int32_t diffAbs2 = 0;
3724
3725 SSettings* pSettings;
3726 pSettings = settingsGetPointer();
3380 3727
3381 newHeading = ActualHeading; 3728 newHeading = ActualHeading;
3382 3729
3383 diff = newHeading - LastHeading; 3730 diff = newHeading - LastHeading;
3384 3731
3407 if(newHeading >= 360) 3754 if(newHeading >= 360)
3408 newHeading -= 360; 3755 newHeading -= 360;
3409 3756
3410 LastHeading = newHeading; 3757 LastHeading = newHeading;
3411 ActualHeading = newHeading; 3758 ActualHeading = newHeading;
3759 ActualHeadingRose = ActualHeading;
3412 /* 3760 /*
3413 if (ActualHeading < 90) 3761 if (ActualHeading < 90)
3414 ActualHeading += 360; 3762 ActualHeading += 360;
3415 3763
3416 if(ActualHeading > LastHeading) 3764 if(ActualHeading > LastHeading)
3423 { 3771 {
3424 if((LastHeading - ActualHeading) < 25) 3772 if((LastHeading - ActualHeading) < 25)
3425 ActualHeading = LastHeading - 1; 3773 ActualHeading = LastHeading - 1;
3426 } 3774 }
3427 */ 3775 */
3428 if (ActualHeading < 90) 3776 if(pSettings->FlipDisplay)
3429 ActualHeading += 360; 3777 {
3778 ActualHeadingRose = 360 - ActualHeadingRose;
3779 if (ActualHeadingRose < 170) ActualHeadingRose += 360;
3780 }
3781 else
3782 {
3783 if (ActualHeadingRose < 90) ActualHeadingRose += 360;
3784 ActualHeading = ActualHeadingRose;
3785 }
3430 3786
3431 // new hw 160822 3787 // new hw 160822
3432 // if (ActualHeading >= 360 + 90) 3788 // if (ActualHeading >= 360 + 90)
3433 // ActualHeading = 360; 3789 // ActualHeading = 360;
3434 3790
3435 LeftBorderHeading = 2 * (ActualHeading - (CUSTOMBOX_SPACE_INSIDE/4)); 3791 LeftBorderHeading = 2 * (ActualHeadingRose - (CUSTOMBOX_SPACE_INSIDE/4));
3792
3793 if(pSettings->FlipDisplay) /* add offset caused by mirrowed drawing */
3794 {
3795 LeftBorderHeading += 2 * 80;
3796 }
3436 3797
3437 offsetPicture = LeftBorderHeading * t7screenCompass.ImageHeight * 2; 3798 offsetPicture = LeftBorderHeading * t7screenCompass.ImageHeight * 2;
3438 3799
3800 /* the background is used to draw the rotating compass rose */
3439 background.pointer = t7screenCompass.FBStartAdress+offsetPicture; 3801 background.pointer = t7screenCompass.FBStartAdress+offsetPicture;
3440 background.x0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET; 3802 background.x0 = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
3441 background.y0 = 65; 3803 if(!pSettings->FlipDisplay)
3804 {
3805 background.y0 = 65;
3806 }
3807 else
3808 {
3809 background.y0 = 480 - t7screenCompass.ImageHeight - 65;
3810 }
3811
3442 background.width = CUSTOMBOX_SPACE_INSIDE; 3812 background.width = CUSTOMBOX_SPACE_INSIDE;
3443 background.height = t7screenCompass.ImageHeight; 3813 background.height = t7screenCompass.ImageHeight;
3444 3814
3445 3815
3446 start.x = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET + (CUSTOMBOX_SPACE_INSIDE/2); 3816 start.x = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET + (CUSTOMBOX_SPACE_INSIDE/2);
3642 4012
3643 4013
3644 void t7_miniLiveLogProfile(void) 4014 void t7_miniLiveLogProfile(void)
3645 { 4015 {
3646 SWindowGimpStyle wintemp; 4016 SWindowGimpStyle wintemp;
4017 SSettings* pSettings;
4018 pSettings = settingsGetPointer();
4019
3647 wintemp.left = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET; 4020 wintemp.left = CUSTOMBOX_LINE_LEFT + CUSTOMBOX_INSIDE_OFFSET;
3648 wintemp.right = wintemp.left + CUSTOMBOX_SPACE_INSIDE; 4021 wintemp.right = wintemp.left + CUSTOMBOX_SPACE_INSIDE;
3649 wintemp.top = 480 - t7l1.WindowY0; 4022 if(!pSettings->FlipDisplay)
3650 wintemp.bottom = wintemp. top + 200; 4023 {
4024 wintemp.top = 480 - t7l1.WindowY0;
4025 wintemp.bottom = wintemp. top + 200;
4026 }
4027 else
4028 {
4029 wintemp.top = t7l1.WindowY1;
4030 wintemp.bottom = wintemp. top + 200;
4031 }
3651 4032
3652 uint16_t max_depth = (uint16_t)(stateUsed->lifeData.max_depth_meter * 10); 4033 uint16_t max_depth = (uint16_t)(stateUsed->lifeData.max_depth_meter * 10);
3653 4034
3654 GFX_graph_print(&t7screen, &wintemp, 0,1,0, max_depth, getMiniLiveLogbookPointerToData(), getMiniLiveLogbookActualDataLength(), CLUT_Font030, NULL); 4035 GFX_graph_print(&t7screen, &wintemp, 0,1,0, max_depth, getMiniLiveLogbookPointerToData(), getMiniLiveLogbookActualDataLength(), CLUT_Font030, NULL);
3655 } 4036 }
3656 4037
3657 void t7_logo_OSTC(void) 4038 void t7_logo_OSTC(void)
3658 { 4039 {
3659 SWindowGimpStyle windowGimp; 4040 SWindowGimpStyle windowGimp;
4041 SSettings* pSettings;
4042 pSettings = settingsGetPointer();
4043
3660 /* OSTC logo */ 4044 /* OSTC logo */
3661 windowGimp.left = t7l1.WindowX1 + 32; 4045 if(!pSettings->FlipDisplay)
4046 {
4047 windowGimp.left = t7l1.WindowX1 + 32;
4048 }
4049 else
4050 {
4051 windowGimp.left = t7r1.WindowX1 + 32;
4052 }
4053
3662 windowGimp.top = 40 + 32; 4054 windowGimp.top = 40 + 32;
3663 GFX_draw_image_monochrome(&t7screen, windowGimp, &ImgOSTC, 0); 4055 GFX_draw_image_monochrome(&t7screen, windowGimp, &ImgOSTC, 0);
3664 } 4056 }