All the information you need to Simulate Ron J's Toggle Switch No.1.


Practical Guides Choosing Parts Testing Your Circuit More Alarm Circuits Firefox Optimised

Toggle Switch No.1 - Simulation


You can use the free SiMetrix Circuit Simulator to run My Simulations. Or you can use my observations, tips and techniques - to help you create a suitable file for a different simulator programme. If you do decide to create your own simulation - it's still worthwhile downloading SiMetrix - just to compare my results.

The circuit uses a small single pole relay. The coils of low voltage DC relays behave just like resistors. I've used a 270 ohm resistor (Ry) to simulate my relay coil. And the relay contacts are represented by S1 and S2.

SiMetrix Schematic

Stripboard Layout Breadboard Layout Photo Of The Prototype

The top line of the graph shows that the button is pushed for two-seconds - at twenty-second intervals. These are translated into very short trigger pulses - by R1, R2 & C1. The trigger pulses energize and de-energize the relay coil. When the coil energizes - the red LED switches off - and the blue LED switches on. And when the coil de-energizes - the blue LED switches off - and the red LED switches on.


Circuit Description Stripboard Layout Breadboard Layout

The bottom line of the graph is an analogue representation of the current flowing through the transistor. It's measured by the in-line current probe connected to the collector of Q1. The state of the red and blue LEDs is also indicated by in-line anologue current probes - but they are displayed as digital (on/off) traces.

The Sw1 Control Pulse (V2)

Sw1 is controlled by a waveform generator (V2). After an initial delay of five-seconds - the generator produces a series of 5v output pulse. The pulses are two-seconds long - and they are delivered at twenty-second intervals. The pulses close Sw1 - simulating the button pushes.

SiMetrix Switches Are Analogue Devices

SiMetrix switches don't simply open and close - like regular switches. Instead - they have both an ON resistance and an OFF resistance. The default OFF (open) resistance is 1 Meg. In order to make them behave more like regular switches - I've increased the OFF resistance to something that more closely resembles an open circuit.

Note that the relay contacts (S1 & S2) form a two-way switch. There are both normally-open and normally-closed contacts. SiMetrix switches are - by default - normally-open. That is - the "On Voltage" is higher than the "Off Voltage". To create a normally-closed switch - make the "On Voltage" lower than the "Off Voltage".

Analysis Settings

For the analysis - the "Mode" should be set to "Transient". And the "Stop Time" should be long enough to allow the simulation to complete a few cycles. I set it to 155 seconds. That's long enough for eight "pushes".

SiMetrix uses your choice of "Stop time" to calculate some of its default settings. Here the stop time figure is relatively high. And one of the resulting default values - the minimum time step - is too high to allow the simulation to run successfully.

You'll find the minimum time step setting - under the "Advanced Options" button. For present purposes - provided it's short enough - the actual choice of minimum step length is not important. So I set a really short one pico-second - effectively removing it as a parameter.

Why Is The Simulation 5-Volts?

The Cmos Models that come with SiMetrix are designed for a 5-volt supply. So I've had to set up a 5-volt simulation. However - the circuit itself will work at anything from 5v to 15v. All you have to do is make sure that the coil of your relay - is designed to work at the voltage you want to use.
Download Simulation Files

Free Web Hosting