1

I'm trying to get a voltage in a range from a potentiometer.

The potentiometer theorically varies between 22k and 40k (R1 in the shematic) but I'm unsure as I currently don't have it in my hands.

I want to "convert" the potentiometer value to a voltage in [0v-5v].

schematic

simulate this circuit – Schematic created using CircuitLab

Here, I first convert the impedance to a voltage trough a voltage divider (R2/R1+R2), and then I input this in a differential LIAO.

It should substract Vc from Va and multiply it with R4/43 and I should have : Vout = (R4/R3)(Va-Vc) which would give me a value in the right range.

But the problem is that It actually won't work because the second voltage divider won't just behave as if Va was a regulated voltage source, and with Thevenin theorem, you can find this equivalent circuit (here just for Va - Vb part) :

schematic

simulate this circuit

And then I have Vc = 1.91011 Volts while what I'd want there is Vc = 5*(22k/44k)(68k/78k) = 2.17949

How can i do ?

servabat
  • 158
  • 4

2 Answers2

1

Your circuit has 7 resistors and produces a nonlinear response of voltage with respect to resistance.

Here is a circuit with only 5 resistors that can operate from a single 5.0V supply (using a rail-to-rail input* and rail-to-rail output op-amp) and which produces a linear voltage proportional to resistance.

schematic

simulate this circuit – Schematic created using CircuitLab

The variable resistance sees a constant current of 39.78uA.

To synthesize this circuit for other ranges, pick R1, R2 to something reasonable considering the op-amp input bias current, accuracy required, and current capability of the variable resistor, and overall consumption.

Pick R4 to maintain a constant current.

Pick R5 and R6 to make the output voltage correct at minimum and maximum resistance.

As simple as that! (some algebra omitted, but it's straightforward)

* actually the input range is only 0.87 to 1.59V so many R-R output op-amps will work.

Spehro Pefhany
  • 376,485
  • 21
  • 320
  • 842
  • Well thank you, it what I wanted. Sorry I can't upvote not enough "reputation". – servabat Feb 01 '14 at 13:00
  • Just a question, how would you do for a rheostat between 11 and 19k ohms ? What have to be changed ? I tried to calculate the transfer function but I get a big silly thing. – servabat Feb 01 '14 at 16:56
  • Change R4, R5 and R6 to get the correct voltage and constant current, as I said above. – Spehro Pefhany Feb 01 '14 at 16:58
0

If your rheostat is at 40k ohms, then if one end is tied to +5V and a 40kohm fixed resistor connects the other end to -5V, the junction of the fixed resistor and rheostat (40k) has to be 0V. That could be your starting point.

If your rheostat changed value to 22k the voltage seen at the junction will be: -

\$ 10volts\times\dfrac{40}{22+40} - 5 volts\$ = 1.45 volts

So far you have a circuit that converts 40kohm to 0V and 22k to 1.4516 volts.

Given that the 1.45 volts needs to be 5V, you have two options; amplify that voltage with an op-amp or increse the +/- 5V applied to the rheostat and fixed resistor to 17.2222 volts.

Now, when the rheostat is 40k you'll still get 0V but when the rheostat is 22k you'll get: -

\$ 2\times 17.2222volts\times\dfrac{40}{22+40} - 17.2222 volts\$ = 4.9999 volts.

Alternatively you can use an op-amp with a more complicated offset circuit but i can't remember the formula and can't be bothered to look-up but you could probably search for it using "op-amp for offsetting a signal". There are calculators I've seen that can help.

Andy aka
  • 434,556
  • 28
  • 351
  • 777