comparison code_part1/OSTC_code_asm_part1/pled_outputs.asm @ 24:571a79f1d06a

1.61 beta rc1
author heinrichsweikamp
date Wed, 05 May 2010 18:55:50 +0200
parents 70215309143d
children
comparison
equal deleted inserted replaced
23:70215309143d 24:571a79f1d06a
807 return 807 return
808 808
809 btfsc multi_gf_display ; Is the Multi-GF Table displayed? 809 btfsc multi_gf_display ; Is the Multi-GF Table displayed?
810 return ; Yes, No update and return! 810 return ; Yes, No update and return!
811 811
812 WIN_INVERT .0 ; Init new Wordprocessor
813 call PLED_active_gas_divemode_show ; Show gas (Non-Inverted in all cases)
814
815 btfss better_gas_available ;=1: A better gas is available and a gas change is advised in divemode
816 return ; Done.
817
818 ; Check if Gas Output should blink when a better gas is available...
819 GETCUSTOM8 d'42' ; =1 if gas should blink
820 movwf lo
821 movlw d'1'
822 cpfseq lo ; =1?
823 return ; No, Done.
824
825 btg blinking_better_gas ; Toggle blink bit...
826 btfss blinking_better_gas ; blink now?
827 return ; No, Done.
828 WIN_INVERT .1 ; Init new Wordprocessor
829 call PLED_active_gas_divemode_show ; Show gas (Non-Inverted in all cases)
830 WIN_INVERT .0 ; Init new Wordprocessor
831 return ; Done.
832
833 PLED_active_gas_divemode_show:
812 ostc_debug 's' ; Sends debug-information to screen if debugmode active 834 ostc_debug 's' ; Sends debug-information to screen if debugmode active
813 ; gas 835 ; gas
814 WIN_TOP .192 836 WIN_TOP .192
815 WIN_LEFT .65 837 WIN_LEFT .65
816 WIN_FONT FT_SMALL 838 WIN_FONT FT_SMALL
817 WIN_INVERT .0 ; Init new Wordprocessor 839 call PLED_standard_color
818 call PLED_standard_color
819
820 840
821 movlw d'100' ; 100% in the tank 841 movlw d'100' ; 100% in the tank
822 movff char_I_N2_ratio,lo ; minus N2 842 movff char_I_N2_ratio,lo ; minus N2
823 bsf STATUS,C ; set borrow bit 843 bsf STATUS,C ; set borrow bit
824 subfwb lo,W 844 subfwb lo,W
852 movlw ' ' 872 movlw ' '
853 btfsc better_gas_available ;=1: A better gas is available and a gas change is advised in divemode 873 btfsc better_gas_available ;=1: A better gas is available and a gas change is advised in divemode
854 movlw '*' 874 movlw '*'
855 movwf POSTINC2 875 movwf POSTINC2
856 call word_processor 876 call word_processor
857 bra PLED_active_gas_divemode_exit 877 return
858 878
859 PLED_active_gas_divemode4: 879 PLED_active_gas_divemode4:
860 lfsr FSR2,letter 880 lfsr FSR2,letter
861 bsf leftbind ; left orientated output 881 bsf leftbind ; left orientated output
862 output_8 ; O2 ratio is still in "lo" 882 output_8 ; O2 ratio is still in "lo"
868 btfsc better_gas_available ;=1: A better gas is available and a gas change is advised in divemode 888 btfsc better_gas_available ;=1: A better gas is available and a gas change is advised in divemode
869 movlw '*' 889 movlw '*'
870 movwf POSTINC2 890 movwf POSTINC2
871 bcf leftbind 891 bcf leftbind
872 call word_processor 892 call word_processor
873 893 return
874 PLED_active_gas_divemode_exit: 894
875 btfss better_gas_available ;=1: A better gas is available and a gas change is advised in divemode
876 return ; Done.
877
878 ; Check if Gas Output should blink when a better gas is available...
879 GETCUSTOM8 d'42' ; =1 if gas should blink
880 movwf lo
881 movlw d'1'
882 cpfseq lo ; =1?
883 return ; No, Done.
884
885 btg blinking_better_gas ; Toggle blink bit...
886 btfss blinking_better_gas ; blink now?
887 return ; No, Done.
888 call PLED_active_gas_clear ; Blink once.
889 return ; Done.
890 895
891 896
892 PLED_display_decotype_surface: 897 PLED_display_decotype_surface:
893 WIN_LEFT .85 898 WIN_LEFT .85
894 WIN_FONT FT_SMALL 899 WIN_FONT FT_SMALL
3192 ; return 3197 ; return
3193 ; 3198 ;
3194 3199
3195 PLED_gaschange_DEBUG: 3200 PLED_gaschange_DEBUG:
3196 WIN_LEFT .0 3201 WIN_LEFT .0
3197 WIN_TOP .164 3202 WIN_TOP .160
3198 lfsr FSR2,letter 3203 lfsr FSR2,letter
3199 movff char_I_deco_He_ratio,lo 3204 movff char_I_deco_He_ratio,lo
3200 output_8 3205 output_8
3201 call word_processor 3206 call word_processor
3202 3207
3203 WIN_LEFT .60 3208 WIN_LEFT .25
3204 WIN_TOP .164 3209 WIN_TOP .160
3205 call PLED_SetRow 3210 call PLED_SetRow
3206 lfsr FSR2,letter 3211 lfsr FSR2,letter
3207 movff char_I_deco_N2_ratio,lo 3212 movff char_I_deco_N2_ratio,lo
3208 output_8 3213 output_8
3209 call word_processor 3214 call word_processor
3210 3215
3211 WIN_LEFT .120 3216 WIN_LEFT .50
3212 WIN_TOP .164 3217 WIN_TOP .160
3213 lfsr FSR2,letter 3218 lfsr FSR2,letter
3214 movff char_I_deco_gas_change,lo 3219 movff char_I_deco_gas_change,lo
3215 output_8 3220 output_8
3216 call word_processor 3221 call word_processor
3217 3222
3218 WIN_LEFT .140 3223 WIN_LEFT .75
3219 WIN_TOP .164 3224 WIN_TOP .160
3220 lfsr FSR2,letter 3225 lfsr FSR2,letter
3221 movff hi,lo 3226 movff hi,lo
3222 output_8 3227 output_8
3223 call word_processor 3228 call word_processor
3224 return 3229 return