em đang làm bảng quang báo loại lớn (16x160) dùng chip at89s52 và 2.0 clock 2.1 data dịch cột P3 dùng tran kéo hàng
các pác giúp em với
đây là code 8x160 của em:
cái này em chưa làm mạch thực chỉ mới mô phỏng trên proteus
cái em cần giúp là làm sao để kéo dài đoạn văn và có thể chạy dc chữ lớn (2 dòng) mong các pác giúp em
xin trân thành cảm ơn
các pác giúp em với
đây là code 8x160 của em:
Code:
#define SCL P2.1 #define SDA P2.0 #define SDA1 P2.2 #define RUN_DATA 40H #define MOC 41H #define BIEN_32 42H #define TIME_BACK 43H TIME_MOVE EQU 44H ORG 0000H MAIN: DONG1: LCALL SCAN DJNZ R0, DONG1 MOV DPTR,#VINHPHAT M1: MOV R0,#2 M2: LCALL SCAN ;NAP DU LIEU DJNZ R0,M2 INC DPTR MOV A,DPL CJNE A,#LOW(VINHPHAT+50),M1 ;============================================= ;============================================= BACK1: ; MAIN MOV RUN_DATA,MOC MOV A,RUN_DATA MOV TIME_BACK,TIME_MOVE ;===================== BACK3: MOV A,RUN_DATA MOVC A,@A+DPTR MOV P3,A LCALL DELAY MOV P3,#0FFH ;============ CLR SCL NOP SETB SCL ;============ INC RUN_DATA MOV A,RUN_DATA CJNE A,#0FFH,DEM_32_LAN MOV RUN_DATA,#0 DEM_32_LAN: INC BIEN_32 MOV A,BIEN_32 CJNE A,#99,BACK3 MOV RUN_DATA,MOC MOV BIEN_32,#190 ;============================ SETB SDA CLR SCL NOP SETB SCL CLR SDA ;============= DJNZ TIME_BACK,BACK3 INC MOC MOV A,MOC CJNE A,#0ffh,THOAT MOV MOC,#0 THOAT: SJMP BACK1 ;============================================= SCAN: MOV TIME_MOVE,#1 SETB SDA ; START CLR SCL SETB SCL CLR SDA MOV RUN_DATA,#200 ; DEFAUL MOV MOC,#200 MOV BIEN_32,#0 ret SCAN2: MOV TIME_MOVE,#1 SETB SDA1 ; START CLR SCL SETB SCL CLR SDA1 MOV RUN_DATA,#2 ; DEFAUL MOV MOC,#2 MOV BIEN_32,#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,7DH,7DH,1H,83H,0FFH,0FFH,0FFH,0FFH,0FFH DB 0FFH,0FFH,80H,80H,0BEH,0BEH,80H,0C1H,0FFH,80H,80H,0FFH,0CDH,84H,0B6H,0B6H,90H,0D9H,0FFH,80H,80H,0B7H,0B7H,87H DB 0CFH,0FFH,80H,80H,0FEH,0FEH,0FEH,0FFH,0F0H,0E0H,0DBH,0BBH,0DBH,0E0H,0F0H,0FFH,0FFH,8FH,87H,0F0H,0F0H,87H,8FH,0FFH DB 0FFH,0FFH,0DBH,0E7H,81H,0E7H,0DBH,0FFH,0FFH,0FFH,0FFH,0DBH,0E7H,81H,0E7H,0DBH,0FFH,0FFH ;HOA DB 0FFH,0FFH,0DBH,0E7H,81H,0E7H,0DBH,0FFH,0FFH,0FFH,0FFH,0DBH,0E7H,81H,0E7H,0DBH,0FFH,0FFH ;HOA DB 0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH DB 0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH DB 0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH DB 0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH DB 0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH DB 0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH DB 0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH DB 0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH,0FFH END
cái em cần giúp là làm sao để kéo dài đoạn văn và có thể chạy dc chữ lớn (2 dòng) mong các pác giúp em
xin trân thành cảm ơn
Comment