Trouble with getting ngSpice to work

Hello, I downloaded digi7474.7z and tried to run digi_div_7474 from here:

It opens up fine, but when I do Inspect->Simulator it says:

Error: there is no circuit loaded.
Compatibility modes selected: ps lt a
Warning: Nesting of subcircuits with parameters is only marginally supported!
warning, can't find model '1prebar' from line
u1 dff(1) dpwr dgnd 1prebar 1clrbar 1clk 1d 1q 1qbar dly_hc74 io_hc mntymxdly={mntymxdly} io_level={io_level}
Circuit: KiCad schematic
Too few parameters for subcircuit type "74hc74" (instance: xxua)
Too few parameters for subcircuit type "74hc74" (instance: xxub)

I get similar errors when I try to manually follow the instructions from here:

------------------------- Version Info --------------------------------
Application: KiCad Schematic Editor x86_64 on x86_64

Version: 8.0.2-8.0.2-0~ubuntu22.04.1, release build

Libraries:
wxWidgets 3.2.1
FreeType 2.11.1
HarfBuzz 2.7.4
FontConfig 2.13.1
libcurl/7.81.0 OpenSSL/3.0.2 zlib/1.2.11 brotli/1.0.9 zstd/1.4.8 libidn2/2.3.2 libpsl/0.21.0 (+libidn2/2.3.2) libssh/0.9.6/openssl/zlib nghttp2/1.43.0 librtmp/2.3 OpenLDAP/2.5.17

Platform: Ubuntu 22.04.4 LTS, 64 bit, Little endian, wxGTK, X11, KDE, x11

Build Info:
Date: Apr 28 2024 21:38:46
wxWidgets: 3.2.1 (wchar_t,wx containers) GTK+ 3.24
Boost: 1.74.0
OCC: 7.6.3
Curl: 7.81.0
ngspice: 42
Compiler: GCC 11.4.0 with C++ ABI 1016

Build settings:

Welcome to this forum.

I split your post into a separate thread, to keep the thread with examples “clean”.
You can edit the title to make it a bit more descriptive, by clicking on the pencil on the right side of it (or at least, I think you have that ability). I do not have much experience with ngSpice, so I’ll leave the content of your post for others to answer.

This is an installation problem.

Please have a look at KiCad 8.01 Digital Simulation 74xx doesn't work.

Yup that was it, thank you! All I did was ‘apt remove libngspice0’ and apt automatically installed libngspice-kicad.

# apt remove libngspice0
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following additional packages will be installed:
  libngspice-kicad
The following packages will be REMOVED:
  libngspice0 libngspice0-dev
The following NEW packages will be installed:
  libngspice-kicad
0 upgraded, 1 newly installed, 2 to remove and 20 not upgraded.
Need to get 2,462 kB of archives.
After this operation, 990 kB of additional disk space will be used.
Do you want to continue? [Y/n] y

Seems like there should be a better way to announce that? Before ever letting the user start the simulator could kicad check the version of libngspice? I guess the problem is that kicad is just the glue between the text model and the sim… still I’m sure it would make for a lot of happy 1st time users if standard components just worked out-of-the-box. The difference between “wow, kicad is the best thing ever” and “I gave up, and went to xyz for simulation”

Thanks again! Have a great weekend everyone!

-Paul

There is a issue about

And some discussion

1 Like