The theory in my head was quite simple, I connected 16 LEDs in a matrix like so:

but physically they are positioned in a single row from LED1 to LED16
I am testing with 16 LEDs but ideally I would do this with 64.
I can turn them on one at a time using this:
Code:
portb = %00011110:pause 25
portb = %00101110:pause 25
portb = %01001110:pause 25
portb = %10001110:pause 25
portb = %00011101:pause 25
portb = %00101101:pause 25
portb = %01001101:pause 25
portb = %10001101:pause 25
portb = %00011011:pause 25
portb = %00101011:pause 25
portb = %01001011:pause 25
portb = %10001011:pause 25
portb = %00010111:pause 25
portb = %00100111:pause 25
portb = %01000111:pause 25
portb = %10000111:pause 25
But I actually want to turn them on much like a flying star where LED1 stays on until LED9 goes on.
I was able to get one row lit but I can't figure out how to turn on the LEDs on the second row while keeping the LEDs on in the first row.
Is there a simple trick for this?
Mike
Bookmarks