Flashing Leds!

closeflash

Just before Christmas I invested in a PiRingo board which was a KickStarter Project. This is a small board which plugs directly into the Pi GPIO pins and it contains a ring of 12 Leds and two push buttons. There are a variety of led colours and configurations available. I chose the Christmas Wreath/Traffic Lights board which has 4 each of red green and yellow Leds. I bought this as an easy way to explore the I/O functions of the Raspberry Pi, and also as I wanted to use it with my eldest Grandson (aged 5) to get him interested in using the Pi.

The board is easy to put together with the aid of a soldering iron and some side cutters, and there are good construction details available on the PiRingo website. (The board is produced by 4tronix)

Sample Python programs are available, but I chose to use the gpio extensions to Scratch, which also support the board, as the software is more appropriate to a 5 year old.

I developed a scratch program to show two different patterns of flashing Leds, which also used the two push buttons to select which pattern is displayed.

If you have a Pi and have not yet delved into the control side of things, then I can recommend this as a very convenient and cheap way to try things out.

prog

 

A view of the program

flash

 

The LEDS flashing

The program can be downloaded here

Advertisements