Hi everyone,
my project is to switch on/off led one by one from P1,P3,P2,P0 with 1 seconde delay.
When i try my code, it's working very well on P1,P2 and P3 but for P0, the leds are blinking one by one and it never stops.
The portion of the code for Port 0 never exits.
here is the code:
Thank you very much if someone could help me,
ps: i use the 8051
my project is to switch on/off led one by one from P1,P3,P2,P0 with 1 seconde delay.
When i try my code, it's working very well on P1,P2 and P3 but for P0, the leds are blinking one by one and it never stops.
The portion of the code for Port 0 never exits.
here is the code:
Rich (BB code):
org 0000h
Loop:
mov p1,#00h
mov a,#01h
mov p1,a
mov p3,#00h
mov p2,#00h
mov p0,#0FFh
cpl a
L7:
rl a
mov p0,a
call delay
jb p0.7,L7
clr p0.7
ps: i use the 8051