Thursday, July 07, 2005

Binary Reflects LED blinks

'Set 8 LEDs into RB0 through RB7 and see this motion.

x var byte
trisb = %00000000
pause 500
' start program with a half-second delay

main:
for x = 0 to 255
portb = x
pause 500
next
pause 1500
goto main

0 Comments:

Post a Comment

<< Home