LTspice-How to use the Voltage Controlled Switch with Hysteresis Characteristics

This article details the use of "the voltage controlled switche with hysteresis characteristics" in LTspice.

TOC

What is the hysteresis characteristics of a voltage controlled switch?

LTspice XVII Voltage controlled switch

In the following article, we introduced the use of the voltage controlled switches.

It is possible to add hysteresis characteristics to this voltage controlled switch, and the syntax is as follows.

.Model ModelName SW(Ron=On-Resistance Roff=Off-Resistance Vt=VoltageThreshold Vh=VoltageHysteresis)

When the voltage input to the voltage controlled switch is below the "voltage threshold - hysteresis" (LOW LEVEL), the switch becomes off-resistance value, and when it is above the "voltage threshold + hysteresis" (HIGH LEVEL), it becomes on-resistance value.

"Vh = voltage hysteresis value" can be omitted, in which case "the voltage hysteresis value = 0V", resulting in a voltage controlled switch without hysteresis characteristics.

As an example, the model name: SW_1, on-resistance value: 1mΩ, off-resistance value: 100MΩ, voltage threshold: 5V, and voltage hysteresis value: 2V, the syntax is as follows.

.Model SW_1 SW(Ron=1m Roff=100Meg Vt=5 Vh=2)

When the voltage input to the voltage controlled switch is below the "3V(5V-2V)" (LOW LEVEL), the switch becomes off-resistance value, and when it is above the "7V(5V+2V)" (HIGH LEVEL), it becomes on-resistance value.

Current Controlled Switch with Hysteresis Characteristics Setting
LTspice XVII Voltage controlled switch Hysteresis Characteristics

Of course, the current controlled switche can also have hysteresis characteristics. The syntax is as follows.

.Model ModelName SW(Ron=On-Resistance Roff=Off-Resistance It=CurrentThreshold Ih=CurrentHysteresis)

As an example, the model name: SW_1, on-resistance value: 1mΩ, off-resistance value: 100MΩ, current threshold: 5A, and current hysteresis value: 2A, the syntax is as follows.

.Model SW_1 SW(Ron=1m Roff=100Meg It=5 Ih=2)

Compared to the syntax of a voltage controlled switch, it is not so difficult, since the 'V' is just changed to 'I'.

Simulations of Voltage Controlled Switche with Hysteresis Characteristics

LTspice XVII Voltage controlled switch Circuit

Having created the above "schematic for a voltage controlled switch without hysteresis characteristics" in the following article, let's modify this schematic to simulate a voltage controlled switch with hysteresis characteristics.

The schematic of a voltage controlled switch without hysteresis characteristics can be downloaded from the link below.

Pulse Wave

First, let's simulate adding a "pulse wave" to a voltage controlled switch with hysteresis characteristics.

1
LTspice XVII Voltage controlled switch Modification

Open "01_Voltage-controlled-switch.asc" and right-click with the mouse on ".MODEL syntax".

2

Modify the ".MODEL syntax" by adding "Vh=2" as follows.

.Model SW_1 SW(Ron=1m Roff=100Meg Vt=5 Vh=2)
LTspice XVII Voltage controlled switch Hysteresis addition
3
LTspice XVII Voltage controlled switch Hysteresis Characteristics Simulation Running

Click "Run" to run the simulation.

4
LTspice XVII Voltage controlled switch Hysteresis Characteristics Voltage Waveform

When V(in) is 0V, the resistance value of the voltage controlled switch is 100MΩ and V(output) is 0V because it is below the threshold value of 5V.

Also, when V(in) is 10V, the resistance value of the voltage controlled switch is 1mΩ and V(output) is 10V because it is above the threshold value of 5V.

The reason for this result is that the LOW/HIGH level changes immediately, so the hysteresis characteristic does not show up in V(output).

The schematic used in this simulation of a voltage controlled switch with hysteresis characteristics (pulse wave) can be downloaded from the link below.

Triangle Wave

Next, let's simulate adding a "triangle wave" to a voltage controlled switch with hysteresis characteristics.

1
LTspice XVII Voltage controlled switch Hysteresis Characteristics Modification

Modify from the schematic used in the previous section "Pulse Wave". Right-click on "V2" with the mouse.

2
LTspice XVII Voltage controlled switch Hysteresis Characteristics PWL Setting

Select "PWL" and enter "time1[s]: 0, value1[V]: 0, time2[s]: 5m, value2[V]: 10, time3[s]: 10m, value3[V]: 0".

This allows setting a triangle wave that rises to 10V in 0 to 5msec and falls to 0V in 5 to 10msec.

3
LTspice XVII Voltage controlled switch Hysteresis Characteristics Simulation Running

Click "Run" to run the simulation.

4
LTspice XVII Voltage controlled switch Hysteresis Characteristics Triangle Wave

You can clearly see that when V(in) goes from 0V to 7V, V(output) rises, and when V(in) goes from 10V to 7V, V(output) falls.

Therefore, the voltage hysteresis value is set to "Vh=2" in the .MODEL syntax, so V(output) is 7V(Vt+Vh) and Ron=1mΩ and the voltage is rising.

Also, V(output) is 3V(Vt-Vh) and Ron=100MΩ, which means that the voltage is falling.

The schematic used in this simulation of a voltage controlled switch with hysteresis characteristics (triangle wave) can be downloaded from the link below.

Let's share this post !
TOC