The pot I'm using is a Guitar Volume pedal for a variable resistor within the voltage divider. Unfortunately this does not produce a linear result (Ohms law and all) and I'm trying to figure out what the math would be to produce that.Maybe your question is over my head, but if you use a linear taper potentiometer with a maximum resistance equal to the fixed resistor, won't the output of the voltage divider be linear?
I have measured the pot which goes from 0-40K ohms. Assuming the model of a standard voltage divider (R2/R2+R1)*V here's a partial list of voltages produced.How do you know the pot is linear? Measure the pot resistance from end to end. Set the pot to halfway and measure the resistance from center tap to each of the two ends. Compare.
This sounds promising, and at the risk of appearing stupider than I already do, would it be possible to get some pointers to this? Can it be done with discrete components or is an IC?If R1 were replaced by a 0.1mA constant current source, the voltage across R2 would vary linearly from 0v to 4v.
E=IR, so if I = 0.1mA, varying R will vary E proportionally.
You don't sound stupid at all. I'll see what I can do about some pointers.This sounds promising, and at the risk of appearing stupider than I already do, would it be possible to get some pointers to this?
Well, it might be done with either. However, it would help a great deal to know what kind of power you have available;Can it be done with discrete components or is an IC?
1) The device is USB powered so it's source is constant and produces 3.3V at the VDD pin.Well, it might be done with either. However, it would help a great deal to know what kind of power you have available;
1) Is the circuit battery powered, or a mains powered DC supply? Please describe.
2) I need to verify if you want a voltage level out between 0v and 4v, or did you have another range in mind?
3) How closely controlled do you need the voltage?
If tolerances need to be pretty close over temperature, it would be a lot easier to use an opamp IC along with a few discrete components. If you don't mind it shifting over temperature, it could be done with a transistor, LED, and a couple of resistors - if there is enough "headroom" from the supply.
by Jake Hertz
by Jake Hertz