A few months ago, I saw this blog and video. The gentlemen had hacked a Lampan light from IKEA with LEDs, I was immediately enamored with the idea of building it and giving a few of them to my young nieces for Christmas. I figured they’d be far more excited about a one-of-a-kind light than a few more dolls in the ‘ole toy box.

I also wanted to further my design knowledge of PCBs as well as better understand using PWM in AVRs, until this point I’d really only played with my Arduino and a few ATTiny13s. I quickly came up with the following design to suite my requirements.

My Requirements:
1. AVR with at least 3 PWM channels. (I used the ATTiny2313)
2. Super bright RGB LEDs.
3. Warm white light for normal use, not the normal blue hued white LEDs.
4. In-circuit programmable design.
5. Fit in the base of an IKEA Lampan.
6. UL approved power source.

First Version of my Lampan RGB LED PCB

Lampan RGB LED PCB

I used quite a few surface mounted components to get the size down.

The lamp uses a single momentary button to switch (you need special drill bits to drill the hole in this thin plastic, trust me, check Harbor Freight for them!) between the colors and the two color mixing modes (one, I jokingly refer to as “light switch rave” and the other a slow color changing mode). My wife absolutely hates the blue hue of normal LEDs, so I knew my design would have to incorporate a few warm white LEDs in addition to the RGB LEDs, thus the 3 warm white LEDs in the middle of the board.

I got the 5mm RGB LEDs from here, highly recommended! And yes, I did use a single resistor for each color, typically a no-no in design, but the trade-off was worth it for me. I wasn’t overly concerned with exact color intensity from each LED.

Anyhow, this was a fun build and Christmas was a hit, the family loved them. I’ve attached the Eagle schematic and AVR Studio files to the post if anyone is more interested in the design.

Lampan RGB Firmware
Title: LampanRGBDriver (4213 clicks)
Caption: Lampan RGB Firmware
Filename: lampanrgbdriver.zip
Size: 3 KB
Lampan Eagle Schematic and Board Files
Title: LampanRGBLedSchematic (1371 clicks)
Caption: Lampan Eagle Schematic and Board Files
Filename: lampanrgbledschematic.zip
Size: 34 KB

Lampan Eagle Schematic and Board Files
Title: LampanRGBLedSchematic (1371 clicks)
Caption: Lampan Eagle Schematic and Board Files
Filename: lampanrgbledschematic.zip
Size: 34 KB
Lampan RGB Firmware
Title: LampanRGBDriver (4213 clicks)
Caption: Lampan RGB Firmware
Filename: lampanrgbdriver.zip
Size: 3 KB