I bought a Pi-Stop just for fun and to introduce my nieces to coding. Pi-Stop is an educational pistop traffic light add-on for Raspberry Pi and was designed in partnership between 4Tronix.co.uk and PiHardware.com.
I first started trying some simple Python scripts to use the GPIO lines, then used the RPIO library to dim the LEDs with PWM, etc. Then it come to my mind that this simple and funny device could be used for something more serius: a CPU load indicator. Just some minutes later I had it done. It’s my first real Python program so it may be not perfect but it’s been a good start on the language. The code can be downloaded from github. Contributions are really appreciated
https://github.com/enekochan/piStopCpuLoad
The are 2 different versions of it:
piStopCpuLoad.py
: Uses RPi.GPIO to interface with the GPIO port.piStopCpuLoadPwm.py
: Uses RPIO library and a PWM approach to dim the LEDs. You’ll have to install RPIO to use this script.
You can see it in action here: