Subscribe

Tiny RGB

Posted by Circuit Labs on Thursday, November 13, 2008

Author: Tobias Flöry

050027uk

This circuit is a good example of a microcontroller design using the absolute minimum of external components. The ATTiny15L microcontroller from Atmel has three of its outputs connected to an RGB LED (or three individual red green and blue LEDs) and produces changing colour patterns. There are of course multicolour LEDs with a controller already built-in on the market but where would be the fun in the ready-built version? You will certainly learn much more by building and programming the design yourself.

The brightness of each LED is controlled using Pulse Width Modulation (PWM). This is accomplished in software and the source code is available to download from www.elektor-electronics.co.uk free of charge as file no. 050027-11.zip. A pre-programmed controller (part no. 050027-41) can also be ordered from the online shop at the same address.

050027uk[3]

The Kingbright RGB LED used in this circuit actually contains one red, one green and two blue LEDs. This helps compensate for the poorer output from the blue LEDs and for the relative insensitivity of our eye to the blue end of the spectrum. The light output thus can produce a better white colour balance. The forward voltage drop of the blue LEDs (4.5 V) is also quite a bit higher than green (2.2 V) or red (2.0 V) so the value of the series resistor (R4) needs to be almost ten times smaller than the series resistors R2 and R3 used for the other LEDs to maintain a similar drive current.

Maximum current consumption of the circuit is approximately 35 mA but the average will be around 25 mA. More information on this design together with some other interesting designs can be found on the author’s website at www.floery.net and look for ‘tobi’s corner’.

 (Elektor Electronics Magazine – 07/2006)


Download this article (#050027.pdf)
 050027-11.zip >> or direct link

0 comments:

Subscribe to: Post Comments (Atom)