org 0h
ayam:
mov p1,#01h;ijo
call e;
mov p1,#02h;kuning
call e;
mov p1,#04h;merah
call f;
sjmp ayam;
e: MOV R0,#4FH;
E1: MOV R1,#0FAH;
E2: MOV R2,#0FAH;
DJNZ R2,$;
DJNZ R1,E2;
DJNZ R0,E1;
RET
F: MOV R0,#9FH;
F1: MOV R1,#0FAH;
F2: MOV R2,#0FAH;
DJNZ R2,$;
DJNZ R1,F2;
DJNZ R0,F1;
RET
END
Tidak ada komentar:
Posting Komentar