How to IC Modelling (LM2596)

Hello QSpice community, I need help making SPICE models for two ICs (UCC38C55 and FA1A50).
I have their datasheets and block diagrams. I’m not sure how to turn the block diagrams and datasheet graphs into an accurate SPICE subcircuit. Can someone give me a concrete, step-by-step method or checklist to follow and ideally an example/template I can adapt?

ucc38c55.pdf (3.2 MB)
FA1A50N_PFC.pdf (710.9 KB)

I did quite a number of them as you can find in my GitHub page.

Anyway, I unfortunately don’t find the interest in making the detailed tutorial for it.

In general, you should just focus on the behavior, not the exact detail implementation silicon model as it will be very time consuming.

i also currently modeling LM2596, it have some errors in qspice maybe because of the command, it works in ltspice with the same command, can anyone figure it out?


Untitled.qsch (37.3 KB)

Great stuff there’s a lot in there

Seems to me the error log is quite straight forward.

For limit, I don’t remember if such function exist or not, but you can consider replacing it with if

And 2nd, I(Br), seems like you need to write it as I=I(Br)

You defined I=<equation> in an I-source instead of a B-source. I believe you placed I-source but rename symbol name as B. But this action cannot change a device type, they are still I-source. The correct way is to type shortcut “B” two time to bring an Arbitrary Behavioral Current Source to use. [You have multiples current device defined in this way and return all these warning]

I-source cannot accept an equation with node voltage or device current, only B-source does.

By the way, your RS flip-flop doesn’t have supply voltage.

@KSKelvin okey now the simulation have the stepping failed error, not sure how to tackle that, also previously get the pwm matrix error but it resolved by v=0, is that solutions make sense?


LM2596_model-DCDCmodule 2a.qsch (38.6 KB)

Based on the file you upload.
Timestep to small - QSPICE - Qorvo Tech Forum

Here is how to convert its netlist to run in Qspice. I believe there might be a mistake when you were copying your schematic from another spice platform.
55_LM2596_model-DCDCmodule 2ac.cir (2.4 KB)

1 Like

dude thank you so much it is finally work, it might be time for migrate lol. btw how to create the netlist from other spice platform like you did? it is very useful

For Qspice and LTspice, they are in View > Netlist
For Tina-TI, it is in File > Export
For Pspice, it is in Pspice > View Netlist

All SPICE runs from netlist, GUI is just to convert your schematic into netlist.

thank you so much for a good tip