Raj @ embedded-lab.com build a mini LED Christmas tree for his son. He writes:
My two and a half year old son loves toys with flashing lights. For this Christmas I thought of making a mini LED Christmas tree for him. This project uses 22 multi-color LEDs which are driven by a PIC12F683 microcontroller using the Charlieplexing technique. The details of the build procedure is described in the following sections.
Making a mini LED Christmas tree - [Link]
Try making a double led dice with 14 leds driven only by 4 available pins of an Atmel Attiny13a. I did it, and it worked:
14 leds can be driven by a technique called charlieplexing when not many microcontroller pins are available. This technique works from the fact that leds are diodes and that those diodes have a little voltage drop. In the network of leds, you can make one led turn on by applying a voltage smaller than twice the voltage drop of a led. In this way, only one led lights up. The other leds do not turn on because the voltage is not high enough.
To make all the leds light up you must cycle through all the leds very fast. Only one led can be turned on at a time. If you cycle through all leds very fast they all seem to be on at the same time to the human eye.
Charlieplexed double led dice - [Link]
This instructable describes how to charlieplex a bunch of 7-segment led displays.
Charlieplexing of discrete leds has been the topic of a few other instructables. The Charlieplexing LEDs- The theory and the How to drive a lot of LEDs from a few microcontroller pins comes to mind. They are both excellent and should be read by anyone that wants to gain a deeper knowledge of how charlieplexing really works.
Charlieplexing 7-segment displays is more or less the same as doing it with discrete leds, but with some changes to handle the fact that all the led segments have a common pin instead of being separate, and the need for buffering of the common output so the poor microcontroller can cope with the load.
Charlieplexing 7 segment displays - [Link]