# LTspice potentiometer simulation

#### StArnold

Joined Feb 19, 2023
2
Hello,

I am new here and did search the forums about simulating a potentiometer already. But I did not find an answer....

My problem: I have a very simple circuit: A 12V voltage, a 120ohm resistor and in row a 120ohm poti down to mass. Very simple is'nt it...

The poti is to measue the liquid level in a tank amd I whant to simulate the circuit (and additions I whant to make later) if the value of the poti is changing rapidly. The only simlution I found was simulationg the poti with the step command. But that does not give me an dynamic behavior of the circuit but only two or more static values.

So, does anyone has an idea?

Greatins, Stephan

#### ericgibbs

Joined Jan 29, 2010
17,416
hi StA,
Welcome to AAC.
Do you have an LTSpice asc file to post?
E

#### Papabravo

Joined Feb 24, 2006
20,122
Sure. What you need is a voltage controlled potentiometer. The wiper position is controlled by a voltage. That way it can change as fast as you want. Can such a thing be implemented? It is possible but I have not had any occasion to work out the details.

#### StArnold

Joined Feb 19, 2023
2
Hm, who can help me to get a voltage controlled viper. I am a beginner.....

#### Alec_t

Joined Sep 17, 2013
13,425
Here's a simple voltage-controlled potentiometer consisting of R1 and R2.
Rpot is the total resistance. The wiper position goes from minimum to maximum as the control voltage (wiper) goes from 0 to 1V.

The '1m' in the R value is to ensure the resistance is never zero, which LTspice would complain about.

Last edited:

#### Alec_t

Joined Sep 17, 2013
13,425
That linked method is unnecessarily involved. Any resistor in LTspice is inherently programmable by simply right-clicking its symbol and setting its value with R= ......

#### crutschow

Joined Mar 14, 2008
32,031
You can also use "time" as a variable to control the resistor voltage.