Moodlamp library The Moodlamp library was created to facilitate the control of an RGB LED or individual red, green, and blue LEDs connected to pins 9, 10, and 11 respectivly. Circuit The library assumes that you have a red LED on pin 9. A green LED on pin 10, and a blue LED on pin 11. Each with an appropriate resistor. A diffuser can help improve colour blending. Functions getColour(int red, int green, int blue) This retrieves and displays the desired colour. Colours are coded in the standard RGB color code format. fade(int red, int green ,int blue, int red2, int green2, int blue2, int vit) This will fade from the first defined colour to the second defined colour (where each set of red,green,blue represent a colour code), at the speed defined by vit. Vit is a delay to hold each step of the colour fade. pulse(int red, int green, int blue, int vit, int times, int pause) Pulses a colour defined by red, green, and blue at a speed defined by vit for x times with a pause between pulses of pause length. flicker(int red, int green, int blue,int pause, int times) Will flick from one random colour to the next for int times, holding each random colour for delay defined by pause. The flickering will end on the colour defined by the colour code red,green,blue. candle(int red, int green, int blue, int duration, int intensity) Creates a flickering candle light effect of the general colour defined by red, green, blue for duration in microseconds with the intesity of the flicker defined by intesity. spin(int times, int vit, int anim) spin through red then green then blue for times, at a speed of vit, with an animation speed of anim. Feel free to use this library however you like. If you make a cool lamp using it, be kind enough to send me a link or picture or something, just so that I can see the ripple in the water...however slight.