flag var bit
flag = 0
start:
If portb.0 = 1 and flag=0 then
portb.1 = 1
flag = 1
pause 1000
endif
if portb.0 = 1 and flag=1 then
portb.1=0
flag = 0
pause 1000
endif
goto start
The endif should not have had a space in it. I also didn't meand the LED would flash. The pause is so it won't flash.




Bookmarks