UNI Project: Control led brightness,with microphone input.

Trying to build a device that picks up noise level and turns it into light.
so i got an Electret Microphone, o Amp, arduino board and a few leds.
I only want to light up one led and control the brightness through input from the microphone.
any help would be great.

p.s
i was wondering if i would need a Digital Potentiometer - 10K... to get this to work.

We have an application (sample sketch) that does nearly exactly this thing for our Gadget Shield. It uses the microphone level to light some number of LED's, the stronger the signal the more LED's that light:

http://ruggedcircuits.com/html/gadget_shield.html#SampleSketches

(scroll down to Microphone Volume Meter)

Perhaps you can extract some relevant concepts from this sample code.

--
The Rugged Motor Driver: two H-bridges, more power than an L298, fully protected

Thanks, but i was wondering if anybody has had experience with dimming LEDs? Im guessing by controlling the voltage that the LED gets.. or would it be easier to by a tri colour LED and set a certain level of noise to each color? Im just not sure which way to go.

Take a look at the fade tutorial:

http://arduino.cc/en/Tutorial/Fade

thanks

I got the fade working on my arduino board using this image:

but how would i go about adding my Electret Microphone to the circuit above without damaging it?
then im good to go.