So in the second starter circuit multiple LEDs are linked up and patterns created.  The first one turns each LED on before turning each LED off.  It uses an array and a couple of for loops.  You can read the full explanation on ardx.org.

and this is the result

Binary Counter

So for an alternative pattern you could write a binary counter which counts from 0 to any number less than 255 (we only have 8 bits so are limited to 255).  Maybe an extension could be to add a red ‘overflow’ LED.

This is the code window.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.