3
\$\begingroup\$

I want to simulate a 555 circuit in KiCad, but quite failing to do so. I found a SPICE model here and included it in my model like this:

enter image description here

My circuit looks like this:

enter image description here

The transient simulation works. It should oscillate at around 14ms, but it doesn't do so:

enter image description here

How can I simulate the 555 in KiCad?

Update I made the simulation a little longer, and I do get some results, but not quite what I expect:

This is from 3s - 4s: enter image description here

And from 4s - 5s: enter image description here

\$\endgroup\$
3
  • \$\begingroup\$ I think that in Kicad 8, that it's at the moment in 'release candidate 2', there are important improvements in simulation. \$\endgroup\$
    – Gos
    Commented Feb 13 at 11:36
  • \$\begingroup\$ Hmmm...looks like the ngspice engine is having trouble with the transistor-based model. Try adding a SPICE directive to the schematic and see if it helps: .options cshunt=1p \$\endgroup\$
    – Ste Kulov
    Commented Feb 13 at 19:12
  • \$\begingroup\$ Can also try Gear integration method by doing this: .options method=gear \$\endgroup\$
    – Ste Kulov
    Commented Feb 13 at 19:31

2 Answers 2

4
\$\begingroup\$

Did you give it enough time to start? My model does start after ~2.38sec.

I tested with KiCAD 7.0.8

Simulator, Sim Command, Transient tab, 1m in Time step and Final time set to 3 seconds.

enter image description here

Please see attached picture:

enter image description here

Zoomed in and more signals - the plot looks like this:

NE555 simulation

NE555.lib file downloaded from here: KiCAD forum

---EDIT--- To check if skipping is present.

This is my result when setup is: transient: 100us step, 3 to 4 second simulation. Voltage seems to be a bit unstable, otherwise fine (no skips).

100micro-3secto4sec

Other setup: 10us step, other parameters the same.

10microsec-3secto4sec

And the last one: 1us step.

1microsec-3secto4sec

\$\endgroup\$
4
  • \$\begingroup\$ Thanks, I got it almost... Ran it in KiCAD 7.0.10, see my updated question. Your results are significantly better. \$\endgroup\$ Commented Feb 13 at 10:53
  • \$\begingroup\$ @BartFriederichs Perhaps skip the initial operating point analysis for the transient simulation, by including the "UIC" argument. For example ".tran 1m 1 uic" \$\endgroup\$ Commented Feb 13 at 11:14
  • \$\begingroup\$ @SimonFitch skipping is OK, problem I still have is the results vary even after that initial startup time. \$\endgroup\$ Commented Feb 13 at 11:30
  • \$\begingroup\$ @Bart Friederichs I see your skipping. Also, your voltage levels are somehow uneven. Let me check this on my simulation. I see the .lib files are identical. \$\endgroup\$
    – smajli
    Commented Feb 13 at 22:36
0
\$\begingroup\$

it should oscillate at around 14ms, but it doesn't do so:

It should be 35 ms ... Simulated with microcap v12.

enter image description here

\$\endgroup\$
3
  • \$\begingroup\$ The problem is not with the circuit, but with KiCad. I have successfully simulated it with other tools. I want to use KiCad because my other designs are in there as well. \$\endgroup\$ Commented Feb 12 at 12:09
  • 1
    \$\begingroup\$ Don't know KiCad. Ok, but the period should be 35 ms, not 14 ms ... \$\endgroup\$
    – Antonio51
    Commented Feb 12 at 12:10
  • 1
    \$\begingroup\$ @BartFriederichs The problem is with NgSpice that KiCad uses as the SPICE engine. The KiCad project has not developed their own simulator yet :) \$\endgroup\$ Commented Feb 12 at 17:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.