At 15:16 22/12/95 -0600, you wrote: >>I am looking for a way to use the pic to control a resistor in a circuit >>(to use as a microcontroller controlled variable power supply). Would >>anyone have any ideas how? Thanks in advance. >> >You could pulse-width modulate an RC integrator to develop the reference >voltage for a regulator, use a CMOS analog switch pulse modulated with an >integrateing capacitor to form a variable voltage divider, an R-2R network >to source current to a current-mirror controlled regulator or pulse modulate >a MOSFet and filter its output. ...and then we'll just reverse the polarity of the neutron flow and connect the input of the high-frequency tachyon generator to the subatomic particle spin mirror and..blam! Antimatter! On a more serious note, you can, provided the voltages around the rest of the circuit can be made to fit, use a resistor and a CMOS switch in series. Turn the switch on/off with a variable duty cycle at a sufficiently high frequency, and the resistor value will appear to change from R (with the switch on all the time) to infinity, with it off all the time. I've used this technique for digitally controlled pots in a guitar amplifier, where it worked a treat with the switches going at 40kHz or so. A 'sufficiently high frequency' is one where the rest of the circuitry doesn't notice what you're doing too much. Dave ----------------- David Knell M.A. Tel: 01843 846558 Fax: 01843 846608 E-mail: dave@dave-ltd.co.uk