org 00h ;-------register define------ s74clr equ p1.6 s74clk equ P1.7 s74dta equ P1.0 ;---------------------------- temp_164 equ 0x7f ;display data count_164 equ 0x7e ; numset: mov temp_164,#0xb0 ;if number 6:83h,3:boh mov count_164,#8 clr s74clr nop setb s74clr ; next164: mov a,temp_164 rlc a mov temp_164,a ; jc out_h clr s74dta call s164clk jmp loop_164 out_h: setb s74dta call s164clk ; loop_164: djnz count_164,next164 end164: jmp end164 ;jmp=>ret ; s164clk: clr s74clk nop setb s74clk ret ; numcode: db 0c0h,0f9h,0a4h,0b0h,99h ;number:0-4 db 92h,82h,0f8h,80h,90h ;number:5-9 end