Week 13 - Output Devices

RGB Charlieplexed Matrix

The output device I decided to make this week is a 2x2 RGB matrix. It consisted of 12 Led's (4 RGB's) and I controlled them with 5 pins on the ATtiny44. I accomplished this using a method known as "Charlieplexing".

Charlieplexing is a technique proposed in early 1995 by Charlie Allen at Maxim Integrated Products for driving a multiplexed display in which relatively few I/O pins on a microcontroller are used to drive an array of LEDs. The method utilizes the tri-state logic capabilities of microcontrollers in order to gain efficiency over traditional multiplexing.

Eagle Board File

Eagle Schematic File

Arduino Test File (requires >1.0)


If you examine the schematic you can see just whats going on to enable the use of so many led's with so few pins. The IO toggles between the flow of current, taking advantage of the fact that current cannot flow through led's in reverse bias. So for example connecting the circuit...

(GPIO->Resistor->Led(anode-cathode)->Led(cathode-anode)->Resistor->GPIO pin)

...allows the formula n(pins) can drive n2-n led's

Now looking through the code you can see that the pin assignments are quite similar and 2 of the RGB's are just reflected GPIO pins.