every pic tutorial has a lesson about using pwm to vary the intensity of a= =20 led, but i couldn't find something that explained how it works in theory.= =20 Recently someone has posted a message suggesting to use pwm to get an analo= g=20 voltage. How does that work? Let's say i send a square wave to resistor-led= ,=20 does the intensity of light depend on the duty cycle of the wave? And if=20 yes, is it just for an optical effect, or there is some electrical law=20 behind it? in the latter case, what would be a general method to obtain an= =20 analog voltage through it? i know they are very stupid questions, sorry for= =20 that and thank you in advance for any enlightening answer :) -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist