PSpice Netlisting/Template Trick

Apr 23, 2013 7 Replies

Just discovered (or re-remembered :-), in PSpice...



To just have the color of an LED showing in the schematic (I hate over-klutzy drawings), I just enter color and the template collects the model name...



Template= X^@refdes %1 %2 My\@COLOR\@LED COLOR=RED LED=LED ...Jim Thompson



-- | James E.Thompson | mens | | Analog Innovations | et | | Analog/Mixed-Signal ASIC's and Discrete Systems | manus | | Phoenix, Arizona 85048 Skype: Contacts Only | | | Voice:(480)460-2350 Fax: Available upon request | Brass Rat | | E-mail Icon at

formatting link
| 1962 | I love to cook with wine. Sometimes I even put it in the food.


Sounds like you're simulating my "LED differential pair" circuit.

It works, doesn't it.

John Larkin Highland Technology, Inc jlarkin at highlandtechnology dot com http://www.highlandtechnology.com Precision electronic instrumentation Picosecond-resolution Digital Delay and Pulse generators Custom laser drivers and controllers Photonics and fiberoptic TTL data links VME thermocouple, LVDT, synchro acquisition and simulation

That simulation takes a loooong time to run. Mikek :-)

"Sounds like"??? The netlist I provided is that of the PSpice schematic I published earlier...

Message-ID:

Where I PATCHED Larkin's not-so-well-thought-out circuit, then ran it both on PSpice and LTspice.

The reason is takes a "loooong time to run" in LTspice has nothing to do with run time, but is all about the poor library handling in LTspice. Watch the message tray in LTspice to see what is happening. I posted a separate message addressing this library (mis)behavior. ...Jim Thompson

| James E.Thompson | mens | | Analog Innovations | et | | Analog/Mixed-Signal ASIC's and Discrete Systems | manus | | Phoenix, Arizona 85048 Skype: Contacts Only | | | Voice:(480)460-2350 Fax: Available upon request | Brass Rat | | E-mail Icon at http://www.analog-innovations.com | 1962 | I love to cook with wine. Sometimes I even put it in the food.

Hi Jim, I don't have a clue if it really takes a long time to run. I was just picking on you, Larkin tried to drag you into an argument and it had been 4 days with no response. Guess you were just being the bigger man. Good job! Mikek

Actually it seems to... but all the excess time is taken up by loading my library, which is extensive. PSpice scans an index, loads only the location of the components used, then runs. LTspice checked _every_ component in my library, then barfed because a component not even being used by the schematic, had a syntax LTspice didn't understand... like my digital behavioral stuff. So I had to pare down MyLib.lib to MyLibLTC.lib, containing only LTC-syntax-compatible components. It's still "slow" because of LTspice checking _every_ component.

Maybe I can figure out a trick to get around that... like create a schematic-specific library on the fly

Thanks! ...Jim Thompson

| James E.Thompson | mens | | Analog Innovations | et | | Analog/Mixed-Signal ASIC's and Discrete Systems | manus | | Phoenix, Arizona 85048 Skype: Contacts Only | | | Voice:(480)460-2350 Fax: Available upon request | Brass Rat | | E-mail Icon at http://www.analog-innovations.com | 1962 | I love to cook with wine. Sometimes I even put it in the food.

[snip]

Aha! Solution right under my nose... PSpice has a compression utility that "packages" _only_ the needed components and models. (Conceived originally to allow passing a schematic to another PSpice user, who has his own symbols and models.)

So, a little klutzy, but it'll work... compress, uncompress, and the .CIR file will now library only the required components.

Thus I can address quickly circuit questions that come up here, by doing my solutions in PSpice, but conveying the content easily to the LTspice user. ...Jim Thompson

| James E.Thompson | mens | | Analog Innovations | et | | Analog/Mixed-Signal ASIC's and Discrete Systems | manus | | Phoenix, Arizona 85048 Skype: Contacts Only | | | Voice:(480)460-2350 Fax: Available upon request | Brass Rat | | E-mail Icon at http://www.analog-innovations.com | 1962 | I love to cook with wine. Sometimes I even put it in the food.

Jim Thompson Inscribed thus:

Neat !

Best Regards: Baron.

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required