Michael Algernon wrote: > My customer wants to program a variable current load on his > batteries. I don't know why ...... > Is this a one-off? If so, he/you might want to seriously consider one of the electronic loads I mentioned in a previous posting to the list. I also found a couple of circuits which were similar to the one I was talking about... The one which is best described is: http://electronicdesign.com/Articles/ArticleID/4056/4056.html The schematic is at http://electronicdesign.com/Files/29/4056/Figure_01.gif What I was suggesting is to hook your ADC up to the + terminal instead of using the pots as the voltage divider. The general idea can be used for constant voltage as well..... As long as you can produce a voltage on the - terminal of the opamp which corresponds to the actual current or voltage on the output, and put the desired matching voltage on the + terminal, the load will "seek" to the current or voltage, since the opamp wants it's inputs to match.... If you increase the voltage on the + terminal, it will increase the output voltage until the voltage coming off of the current sense resistors matches. -forrest -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist