comparison src/tft_outputs.asm @ 104:223579e905c3

Show a Safety Stop if enabled (Menu "Deco Parameters")
author heinrichsweikamp
date Tue, 03 Jun 2014 12:25:47 +0200
parents 37275e0fa7f5
children 0aaa4877ba25
comparison
equal deleted inserted replaced
103:047629595215 104:223579e905c3
487 TFT_display_velocity_clear: 487 TFT_display_velocity_clear:
488 ; Clear Text 488 ; Clear Text
489 WIN_BOX_BLACK velocity_text_row, velocity_text_row+.22, velocity_text_column, (velocity_text_column+.7*.8)-1 ; top, bottom, left, right 489 WIN_BOX_BLACK velocity_text_row, velocity_text_row+.22, velocity_text_column, (velocity_text_column+.7*.8)-1 ; top, bottom, left, right
490 return 490 return
491 491
492 global TFT_clear_decoarea
492 TFT_clear_decoarea: 493 TFT_clear_decoarea:
493 WIN_BOX_BLACK decostop_1st_stop_row, .239, decostop_1st_stop_column ,.159 ; top, bottom, left, right 494 WIN_BOX_BLACK decostop_1st_stop_row, .239, decostop_1st_stop_column ,.159 ; top, bottom, left, right
494 return 495 return
495 496
496 global TFT_clear_divemode_menu 497 global TFT_clear_divemode_menu
570 rcall TFT_clear_decoarea 571 rcall TFT_clear_decoarea
571 WIN_STD tts_text_column,tts_text_row 572 WIN_STD tts_text_column,tts_text_row
572 call TFT_divemask_color 573 call TFT_divemask_color
573 STRCPY_TEXT_PRINT tTTS ; TTS 574 STRCPY_TEXT_PRINT tTTS ; TTS
574 call TFT_standard_color 575 call TFT_standard_color
576 bcf show_safety_stop ; Clear safety stop flag
575 return 577 return
576 578
577 TFT_display_deko_output_depth: ; Outputs depth (stored in lo) to POSTINC2 with "m" or w/o (For ft) 579 TFT_display_deko_output_depth: ; Outputs depth (stored in lo) to POSTINC2 with "m" or w/o (For ft)
578 TSTOSS opt_units ; 0=m, 1=ft 580 TSTOSS opt_units ; 0=m, 1=ft
579 bra TFT_display_deko_output_metric 581 bra TFT_display_deko_output_metric
746 ; cpfslt lo ; show value? 748 ; cpfslt lo ; show value?
747 ; bra TFT_display_deko2 ; Yes 749 ; bra TFT_display_deko2 ; Yes
748 ; ; No 750 ; ; No
749 ; bra TFT_display_ndl_mask2 ; Clear gradient factor 751 ; bra TFT_display_ndl_mask2 ; Clear gradient factor
750 ; 752 ;
753
754 global TFT_show_safety_stop
755 TFT_show_safety_stop:
756 tstfsz safety_stop_countdown ; Countdown at zero?
757 bra TFT_show_safety_stop2 ; No, show stop
758
759 bcf show_safety_stop ; Clear flag
760
761 btfsc safety_stop_active ; Displayed?
762 rcall TFT_clear_decoarea ; Yes, Clear stop
763 bcf safety_stop_active ; Clear flag
764 rcall TFT_display_ndl_mask ; Show NDL again
765 bra TFT_display_ndl ; (And return)
766
767 TFT_show_safety_stop2:
768 bsf safety_stop_active ; Set flag
769 rcall TFT_attention_color ; show in yellow
770 WIN_MEDIUM safetystop_column,safetystop_row
771 lfsr FSR2,buffer
772 decf safety_stop_countdown,F ; Reduce countdown
773 movff safety_stop_countdown,lo
774 clrf hi
775 call convert_time ; converts hi:lo in seconds to mins (hi) and seconds (lo)
776 movf hi,W
777 movff lo,hi
778 movwf lo ; exchange lo and hi
779 output_99
780 PUTC ':'
781 movff hi,lo
782 output_99x
783 STRCAT_PRINT ""
784 WIN_FONT FT_SMALL
785 rcall TFT_standard_color
786 return
751 787
752 global TFT_mask_avr_stopwatch ; Show mask for average depth and stopwatch 788 global TFT_mask_avr_stopwatch ; Show mask for average depth and stopwatch
753 TFT_mask_avr_stopwatch: 789 TFT_mask_avr_stopwatch:
754 ; The mask 790 ; The mask
755 call TFT_divemask_color 791 call TFT_divemask_color