Basic op amp simulation file

I need a basic .lib simulation file for a “jellybean” op-amp such as an LM358. All I was able to find is an unusable, as-is, .mod file originally from Nat’l Semi via the Github repository at: KiCad-Spice-Library/README.md at master · kicad-spice-library/KiCad-Spice-Library · GitHub I’m sure it must be very detailed and accurate for a wide variety of uses…
Instead, is there a generic op-amp sim model file with basic functionality I can get?

Always go to the manufacturers first!
You’ll find models for LM324 and LM358 at www.ti.com

There are several threads on this forum dedicated to working ngSpice simulations in KiCad. Some examples:

Those are two of the top links found after a quick search with:
https://forum.kicad.info/search?q=simulation%20examples

(reply has been retracted)

How did you add the model to your symbol?
The normal way is to open the symbol properties in your schematic, go to simulation model and add the model as file.
But there’s a nasty catch: the window for adding the simulation model has an extra field where you need to select the model name.
This is graphically so badly made that you tend to miss it. Even after years, it still happens to me.

Have a look at the KiCad symbol library Simulation_SPICE. The OPAMP symbol has a generic ngspice model attached.

MIL9104: I haven’t found any “bubble gum” `op amp sim models at the TI web site directly usable for NGspice. Where are they? They seem to have only models for their own simulator.

Holger: I successfully substituted this in my test circuit making a comparator from an op amp since I could not find a working comparator sim file.

GENERIC OP AMP USED AS COMPARITOR - SCHEMATIC

The zener reference voltage throughout the voltage works as expected as well as the op amp’s comparator function.

I should have run a transient analysis instead of a ramping DC as an input signal. That will be changed shortly.

The red trace is the applied voltage. Why doesn’t the graph scale reach up to 13 volts? Is this a limitation to the model?

(Reply has been retracted)

Just go to the product page, eg, LM358 data sheet, product information and support | TI.com
A bit down you’ll find “Design & development” and there “Design tools & simulation”.
Not too hard, no?

Thanks! To choose any TI part go to: https://www.ti.com/