comparison src/tft.asm @ 431:9500b2d3e32b

hunting a bug in the logbook...
author heinrichsweikamp
date Tue, 21 Jun 2016 17:20:44 +0200
parents fec5eec4c8b7
children 929feb0da4f5
comparison
equal deleted inserted replaced
430:5604cd15c39f 431:9500b2d3e32b
755 movf PRODL,W 755 movf PRODL,W
756 rcall TFT_DataWrite ; Lower (and tick) 756 rcall TFT_DataWrite ; Lower (and tick)
757 757
758 Index_out 0x20 ; Frame Memory Horizontal Address 758 Index_out 0x20 ; Frame Memory Horizontal Address
759 movf PRODH,W 759 movf PRODH,W
760 rcall TFT_DataWrite ; Lower (and tick) 760 bra TFT_DataWrite ; Lower (and tick) and return
761 return 761 ; return
762 762
763 763
764 TFT_box_noflip_V: 764 TFT_box_noflip_V:
765 ;---- Normal vertical window ---------------------------------------- 765 ;---- Normal vertical window ----------------------------------------
766 movff win_top,PRODL 766 movff win_top,PRODL
781 movf PRODL,W 781 movf PRODL,W
782 rcall TFT_DataWrite ; Lower (and tick) 782 rcall TFT_DataWrite ; Lower (and tick)
783 783
784 Index_out 0x20 ; Frame Memory Horizontal Address 784 Index_out 0x20 ; Frame Memory Horizontal Address
785 movf PRODL,W 785 movf PRODL,W
786 rcall TFT_DataWrite ; Lower (and tick) 786 bra TFT_DataWrite ; Lower (and tick) and return
787 return 787 ;return
788 788
789 789
790 ;============================================================================= 790 ;=============================================================================
791 ; TFT_frame : draw a frame around current box with current color. 791 ; TFT_frame : draw a frame around current box with current color.
792 ; Inputs: win_top, win_leftx2, win_height, win_width, win_color1, win_color2 792 ; Inputs: win_top, win_leftx2, win_height, win_width, win_color1, win_color2
839 ; Trashed: WREG, PROD 839 ; Trashed: WREG, PROD
840 global TFT_box 840 global TFT_box
841 841
842 TFT_box: 842 TFT_box:
843 ;---- Define Window ------------------------------------------------------ 843 ;---- Define Window ------------------------------------------------------
844 movf win_width,W 844 ; movf win_width+0,W
845 ; bcf STATUS,C
846 ; rlcf WREG
847 ; movwf win_width+0
845 bcf STATUS,C 848 bcf STATUS,C
846 rlcf WREG 849 rlcf win_width+0,F
847 movwf win_width+0
848 movlw 0 850 movlw 0
849 rlcf WREG 851 rlcf WREG
850 movwf win_width+1 852 movwf win_width+1
851 rcall TFT_box_write ; Setup box 853 rcall TFT_box_write ; Setup box
852 854
853 global TFT_box_16bit_win_left 855 global TFT_box_16bit_win_left
854 TFT_box_16bit_win_left: 856 TFT_box_16bit_win_left:
855 rrcf win_width+1,W ; width /= 2 857 bcf STATUS,C
856 rrcf win_width+0,W 858 rrcf win_width+1,F ; width /= 2
857 movwf win_width 859 rrcf win_width+0,F
860 ; movwf win_width
858 861
859 ;---- Fill Window -------------------------------------------------------- 862 ;---- Fill Window --------------------------------------------------------
860 Index_out 0x22 ; Frame Memory Data Write start 863 Index_out 0x22 ; Frame Memory Data Write start
861 864
862 clrf PRODH ; Column counter. 865 clrf PRODH ; Column counter.