I am currently designing a circuit in Autodesk Eagle which requires a 555 timer IC. The timer may be any 555 chip, such as an ne555, tlc555, or lm555, or even one of their 556 variants, but the lm555 would be best. I am able to add the device to the circuit just fine, but, as it does not automatically have a model, I am unable to simulate it. After hours of scouring the internet, including but not limited to EE Stack Exchange, I have been unable to find a SPICE, NGSPICE, or LTSPICE model for any of these chips. If anyone could help me to find such a model compatible with Eagle, it would be much appreciated. Also, as this is my first time working with SPICE simulation in Eagle, installation instructions would be further appreciated, but are less important than the model itself.
Electrical – 555 Timer IC Simulation in Eagle
555eagleltspicengspicespice
Related Solutions
After having experimented a lot, and read some more, I found an answer to my question.
Simple switch model approach
After seing a demo on the switch models I finally understood the parameters and workings of the SPICE switch model, which I will explain below.
Switch model syntax
.model MODEL SW VT VH RON ROFF
SX N+ N- NC+ NC- MODEL <ON><OFF>
(where a RegEx for X is [a-z0-9]{0,7}
.)
What the manual doesn't explain
Although easily guessed:
- The
N
nodes are the controlled nodes, which will be "short-circuited" or "opened" (continue reading for quoting reason.) - The
NC
nodes are the controller nodes, from which the "switching" voltage will be read.
The switch is essentially on when the voltage accross the controlled nodes is positive, and off otherwise, this is also easily guessed.
Now, the hysteresis voltage makes it possible for the user to define a "dark voltage interval", in which the switch will not be able to change its state. This interval is defined by [VT-VH, VT+VH]
, and is what provides hysteresis to the model. This is interpreted as follows:
- A voltage over
VT+VH
will turn the switch on. - A voltage below
VT-VH
will turn the switch off.
Because these are the only conditions ruling the model, the model needs an initial on or off state if the initial voltage across the controller nodes is within the dark voltage interval. This initial state is optional otherwise, for it would be overridden.
The current controlled switch model is analogous to this one, but take note about that between the controlled nodes there is a short circuit.
Sample circuit
Voltage controlled switch
V0 1 0 SIN(0 12 2 0 0)
S1 1 2 1 0 simpleswitch OFF
R2 2 0 10
.model simpleswitch sw vt=0 vh=6 ron=0.1 roff=1Meg
.control
tran 1e-3 1 uic
plot v(2)/10.1 v(1)/10.1 $ voltage/(resistor resistance + switch on resistance)
.endc
Above you can see the plot resulting from the simulation of the circuit source code. The blue curve corresponds to the source voltage, the red curve to the voltage across the resistor.
As it can be observed from the code, the so called dark voltage interval is [-6,6]
, at which the switch does nothing (remembers its last state). As soon as the voltage across the controller nodes is over 6 V, there is a current flowing through the resistor (and thus non-null voltage across it); as soon as the voltage is below -6 V, the current flow is cut.
I am wondering if this question is not better suited for biology.SE but anyways...
"Commercially" available electrical bug squatters run usually at around 600-700V and use this to charge up something like a 22 nF capacitor.
This is then "shorted" through the bug, which depending on the position you hit the bug with is signaled by a satisfying bang and a distinct smell. Often though there is no bang, but the fly falls down nevertheless. This makes me assume that depending on the position you hit it, its resistance is in the range of a couple of hundred to some kOhms. It also seems they can withstand much higher amps than humans, since even after some burning they can fly away.
But in my experience, anything but the real smaller ones usually just get unconscious by this (I had a slapstick episode of a big fat fly falling maybe half a dozen times behind a cupboard and reemerging).
So this thing unloads ~5mJ onto the fly, and it doesn't really die reliably.
So to get some decent amps running through these beasts, you need sufficiently high voltages and a good amount of energy storage.
You say you want to run it from some 9V, which means for, say, 180V output (probably too low, but still) you have factor of 20. This is going to be a big voltage multiplier.
Better is, you go into a dollar store, buy ten of those mosquito swatters, and have 10 nice tiny transformers to play with.
Best Answer
In LTSpice, press F2 to add a component, go into the (MISC)ellaneous directory and choose NE555, "An idealized 555 timer".
I'll see if I can look up how you can import LTS models to eagle, but it may be just as quick for you to research it yourself now that you know where to find a model.