Mercurial > public > hwos_code
comparison src/tft_outputs.asm @ 53:2825f1d2262f
NEW: Dynamic Gaslist in OC mode (Divemode, Customview 7)
author | heinrichsweikamp |
---|---|
date | Sun, 29 Sep 2013 18:53:22 +0200 |
parents | 0fae975af741 |
children | 7d626c15b577 |
comparison
equal
deleted
inserted
replaced
52:0fae975af741 | 53:2825f1d2262f |
---|---|
732 STRCPY_TEXT_PRINT tDiveTotalAvr | 732 STRCPY_TEXT_PRINT tDiveTotalAvr |
733 WIN_TINY dive_custom_avr_stop_column2,dive_custom_avr_stop_row | 733 WIN_TINY dive_custom_avr_stop_column2,dive_custom_avr_stop_row |
734 STRCPY_TEXT_PRINT tDiveStopwatch | 734 STRCPY_TEXT_PRINT tDiveStopwatch |
735 WIN_TINY dive_custom_avr_stop_column3,dive_custom_avr_stop_row | 735 WIN_TINY dive_custom_avr_stop_column3,dive_custom_avr_stop_row |
736 STRCPY_TEXT_PRINT tDiveStopAvr | 736 STRCPY_TEXT_PRINT tDiveStopAvr |
737 call TFT_standard_color | |
738 return | |
739 | |
740 global TFT_dyn_gaslist | |
741 TFT_dyn_gaslist: ; Show the dynamic gaslist | |
742 ; The mask | |
743 call TFT_divemask_color | |
744 WIN_TINY dive_custom_dyn_mask_column,dive_custom_dyn_mask_row | |
745 STRCPY_TEXT_PRINT tGaslist | |
746 call TFT_standard_color | |
747 | |
748 WIN_SMALL dive_custom_dyn_mask_column1,dive_custom_dyn_mask_row1 | |
749 lfsr FSR2,buffer | |
750 movlw .1 | |
751 movwf mcp_temp+0 | |
752 cpfseq active_gas ;1-5 | |
753 bra $+4 | |
754 incf mcp_temp+0,F ; +1 | |
755 movff mcp_temp+0,lo | |
756 movff mcp_temp+0,PRODL | |
757 decf PRODL,F ;-1 to have 0-4 | |
758 bsf leftbind | |
759 output_8 ; Gas number | |
760 PUTC ":" | |
761 bsf short_gas_decriptions ; =1: Use short versions of gaslist_strcat_gas_mod and gaslist_strcat_setpoint | |
762 call gaslist_strcat_gas_mod ;Append gas description of gas #PRODL (0-4) to current string | |
763 PUTC " " ; Clearing space | |
764 movlw 0x00 | |
765 movff WREG,buffer+.11 ; limit to 11 chars | |
766 STRCAT_PRINT "" | |
767 | |
768 WIN_SMALL dive_custom_dyn_mask_column1,dive_custom_dyn_mask_row2 | |
769 lfsr FSR2,buffer | |
770 incf mcp_temp+0,F ; +1 | |
771 movf mcp_temp+0,W ; into W | |
772 cpfseq active_gas ;1-5 | |
773 bra $+4 | |
774 incf mcp_temp+0,F ; +1 | |
775 movff mcp_temp+0,lo | |
776 movff mcp_temp+0,PRODL | |
777 decf PRODL,F ;-1 to have 0-4 | |
778 bsf leftbind | |
779 output_8 ; Gas number | |
780 PUTC ":" | |
781 call gaslist_strcat_gas_mod ;Append gas description of gas #PRODL (0-4) to current string | |
782 PUTC " " ; Clearing space | |
783 movlw 0x00 | |
784 movff WREG,buffer+.11 ; limit to 11 chars | |
785 STRCAT_PRINT "" | |
786 | |
787 WIN_SMALL dive_custom_dyn_mask_column2,dive_custom_dyn_mask_row1 | |
788 lfsr FSR2,buffer | |
789 incf mcp_temp+0,F ; +1 | |
790 movf mcp_temp+0,W ; into W | |
791 cpfseq active_gas ;1-5 | |
792 bra $+4 | |
793 incf mcp_temp+0,F ; +1 | |
794 movff mcp_temp+0,lo | |
795 movff mcp_temp+0,PRODL | |
796 decf PRODL,F ;-1 to have 0-4 | |
797 bsf leftbind | |
798 output_8 ; Gas number | |
799 PUTC ":" | |
800 call gaslist_strcat_gas_mod ;Append gas description of gas #PRODL (0-4) to current string | |
801 PUTC " " ; Clearing space | |
802 movlw 0x00 | |
803 movff WREG,buffer+.11 ; limit to 11 chars | |
804 STRCAT_PRINT "" | |
805 | |
806 WIN_SMALL dive_custom_dyn_mask_column2,dive_custom_dyn_mask_row2 | |
807 lfsr FSR2,buffer | |
808 incf mcp_temp+0,F ; +1 | |
809 movf mcp_temp+0,W ; into W | |
810 cpfseq active_gas ;1-5 | |
811 bra $+4 | |
812 incf mcp_temp+0,F ; +1 | |
813 movff mcp_temp+0,lo | |
814 movff mcp_temp+0,PRODL | |
815 decf PRODL,F ;-1 to have 0-4 | |
816 bsf leftbind | |
817 output_8 ; Gas number | |
818 bcf leftbind | |
819 PUTC ":" | |
820 call gaslist_strcat_gas_mod ;Append gas description of gas #PRODL (0-4) to current string | |
821 PUTC " " ; Clearing space | |
822 movlw 0x00 | |
823 movff WREG,buffer+.11 ; limit to 11 chars | |
824 STRCAT_PRINT "" | |
825 bcf short_gas_decriptions ; =1: Use short versions of gaslist_strcat_gas_mod and gaslist_strcat_setpoint | |
737 call TFT_standard_color | 826 call TFT_standard_color |
738 return | 827 return |
739 | 828 |
740 global TFT_update_avr_stopwatch ; Update average depth and stopwatch | 829 global TFT_update_avr_stopwatch ; Update average depth and stopwatch |
741 TFT_update_avr_stopwatch: | 830 TFT_update_avr_stopwatch: |