comparison src/customview.asm @ 53:2825f1d2262f

NEW: Dynamic Gaslist in OC mode (Divemode, Customview 7)
author heinrichsweikamp
date Sun, 29 Sep 2013 18:53:22 +0200
parents 7c7d7644ca37
children 37275e0fa7f5
comparison
equal deleted inserted replaced
52:0fae975af741 53:2825f1d2262f
38 bra customview_1sec_view3 38 bra customview_1sec_view3
39 dcfsnz WREG,F 39 dcfsnz WREG,F
40 bra customview_1sec_view4 40 bra customview_1sec_view4
41 dcfsnz WREG,F 41 dcfsnz WREG,F
42 bra customview_1sec_view5 42 bra customview_1sec_view5
43 dcfsnz WREG,F
44 bra customview_1sec_view6
45 dcfsnz WREG,F
46 bra customview_1sec_view7
43 ; Menupos3=0, do nothing 47 ; Menupos3=0, do nothing
44 return 48 return
45 49
46 customview_1sec_view3: 50 customview_1sec_view3:
47 call TFT_decoplan ; Show decoplan 51 call TFT_decoplan ; Show decoplan
55 customview_1sec_view4: 59 customview_1sec_view4:
56 call TFT_ead_end_tissues_clock ; Update EAD/END, Tissues and clock 60 call TFT_ead_end_tissues_clock ; Update EAD/END, Tissues and clock
57 return 61 return
58 customview_1sec_view5: 62 customview_1sec_view5:
59 call TFT_gf_info ; Update GF informations 63 call TFT_gf_info ; Update GF informations
64 return
65 customview_1sec_view6:
66 ; Compass updated seperately (Faster) in divemode
67 return
68 customview_1sec_view7: ; Dynamic gaslist
69 call TFT_dyn_gaslist ; Update the gaslist
60 return 70 return
61 71
62 ;============================================================================= 72 ;=============================================================================
63 ; Do every-minute tasks for the custom view area 73 ; Do every-minute tasks for the custom view area
64 74
279 ; Show next customview (and delete this flag) 289 ; Show next customview (and delete this flag)
280 global customview_toggle 290 global customview_toggle
281 customview_toggle: 291 customview_toggle:
282 bcf switch_right 292 bcf switch_right
283 incf menupos3,F ; Number of customview to show 293 incf menupos3,F ; Number of customview to show
284 movlw d'6' ; Max number of customsviews in divemode 294 movlw d'7' ; Max number of customsviews in divemode
285 cpfsgt menupos3 ; Max reached? 295 cpfsgt menupos3 ; Max reached?
286 bra customview_mask ; No, show 296 bra customview_mask ; No, show
287 customview_toggle_reset: ; Timeout occured 297 customview_toggle_reset: ; Timeout occured
288 clrf menupos3 ; Reset to zero (Zero=no custom view) 298 clrf menupos3 ; Reset to zero (Zero=no custom view)
289 global customview_mask 299 global customview_mask
302 bra customview_init_view4 312 bra customview_init_view4
303 dcfsnz WREG,F 313 dcfsnz WREG,F
304 bra customview_init_view5 ; GF informations 314 bra customview_init_view5 ; GF informations
305 dcfsnz WREG,F 315 dcfsnz WREG,F
306 bra customview_init_view6 ; Compass 316 bra customview_init_view6 ; Compass
317 dcfsnz WREG,F
318 bra customview_init_view7 ; Dynamic gaslist
307 customview_init_nocustomview: 319 customview_init_nocustomview:
308 call I2C_sleep_accelerometer ; Stop accelerometer 320 call I2C_sleep_accelerometer ; Stop accelerometer
309 call I2C_sleep_compass ; Stop compass 321 call I2C_sleep_compass ; Stop compass
310 bra customview_toggle_exit 322 bra customview_toggle_exit
311 323
357 369
358 customview_init_view6: ; Compass (View 6) 370 customview_init_view6: ; Compass (View 6)
359 call I2C_init_accelerometer ; Start accelerometer 371 call I2C_init_accelerometer ; Start accelerometer
360 call I2C_init_compass ; Start compass 372 call I2C_init_compass ; Start compass
361 call TFT_dive_compass_mask ; Show compass 373 call TFT_dive_compass_mask ; Show compass
374 bra customview_toggle_exit
375
376 customview_init_view7: ; Dynamic gaslist (View 7)
377 btfsc FLAG_apnoe_mode ; In Apnoe mode?
378 bra customview_toggle ; Yes, Call next view...
379 btfsc FLAG_ccr_mode ; In CC mode?
380 bra customview_toggle ; Yes, Call next view...
381 call TFT_dyn_gaslist ; Show the dyn gaslist
362 bra customview_toggle_exit 382 bra customview_toggle_exit
363 383
364 customview_toggle_exit: 384 customview_toggle_exit:
365 call TFT_standard_color 385 call TFT_standard_color
366 bcf toggle_customview ; Clear flag 386 bcf toggle_customview ; Clear flag