Unexpected Simulation Results When Using a SPST Switch in Multisim

Updated Dec 30, 2022

Reported In


  • Multisim Base

Issue Details

I built a digital circuit in NI Multisim and it has two single-pole-single-throw (SPST) switches as shown below. When I run the simulation, it does not matter if the switch is opened or closed; the LED is always on. How do I make this circuit work in NI Multisim?



  • Using a SPST switch, one method to connect this circuit is to add a resistor and connect the circuit as shown below. When the switch is closed, the AND gate input is connected to ground giving you a low. When the switch is opened, the input is connected to Vcc through the resistor giving you a high input.


Note : The model of a SPST switch is made up of two resistors; double-click the switch to open the component properties dialog to view its properties. When the switch is opened, the resistor is represented by Roff which is 100 MΩ, and when the switch is closed the resistor is represented by Ron which is 100 µΩ. In your circuit, regardless of the switch position, the AND gate input is 5V and this is why the output is always high. In the real world, when the switch is opened, there is no real voltage applied to the gate input and it said to be floating. Usually, the input floats towards a high but any noise can cause the input to go low; therefore, this circuit is unpredictable.



Additional Information

If you want to quickly understand the circuit logic in NI Multisim, you can use the Interactive Digital Constant component; this part is located in the Sources group under the Digital Sources family. This part is a virtual switch that sends a high or low to digital component input.