Hooking up transistors in LTSpice

Is there a 'pretty' way to make custom transistors in LTSpice? To date I've just made a custom circuit card and hand connected things, leaving a hole in my schematic with the text "here be a transistor".

But that's a little bit crude to be showing off to a customer...

--
Tim Wescott
Wescott Design Services
 Click to see the full signature
Reply to
Tim Wescott
Loading thread data ...

None of the ones that came with LTSpice fits? You may find some more in the LTSpice Yahoo forum file area.

If you really must design a fancier symbol for the transistor or it's a special one go to -> Help -> Schematic Capture -> Creating New Symbols

--
Regards, Joerg

http://www.analogconsultants.com/
 Click to see the full signature
Reply to
Joerg

In partial answer to my own question, I've found where LTSpice keeps its transistor models -- so, can I do a custom one without just appending it to their file?

--
Tim Wescott
Wescott Design Services
 Click to see the full signature
Reply to
Tim Wescott

You can place a ".model ... " Spice directive in your schematic.

Or you can create .asy and .mod files in the same directory as your .asc file.

Or you can place a Spice directive in your schematic to .include a lib file.

Reply to
Andrew Holme

And if it's a whole subcircuit that you want behind a transistor you'll have to assign that transistor the designator X instead of M or Q.

--
Regards, Joerg

http://www.analogconsultants.com/
 Click to see the full signature
Reply to
Joerg

.INC(LUDE) slows down netlist reading... the whole file is pulled into the netlist.

.LIB(rary) only pulls in the models used

Not in PSpice.

A transistor (with a subcircuit "behind" it) would have as a "template" (for example):

X_Q1 %c %b %e 2N3904

but on the schematic all you would see would be:

[transistor] Q1 [symbol] 2N3904 ...Jim Thompson
--
| James E.Thompson, CTO                            |    mens     |
| Analog Innovations, Inc.                         |     et      |
 Click to see the full signature
Reply to
Jim Thompson

I tried that, and LTSpice wouldn't let me assign the transistor number to a package.

I may need to.

--
Tim Wescott
Wescott Design Services
 Click to see the full signature
Reply to
Tim Wescott

That's another difference I experienced between LTSpice and PSpice. LTSpice ... click the marathon runner symbol... slurrrrrp ... sim runs. PSpice ... click the green arrow ... One Mississippi ... Two Mississippi ... get coffee from kitchen ...

Real men use LTSpice :-)

[...]
--
Regards, Joerg

http://www.analogconsultants.com/
 Click to see the full signature
Reply to
Joerg

Not when you need professional looking presentations.

LTspice is faster for things like crystal oscillators, but not noticeably faster otherwise.

But you have been using Crapture, which keeps you in constant danger of losing everything.

(I often draw schematics in PSpice, then simply load the netlist into LTspice.) ...Jim Thompson

--
| James E.Thompson, CTO                            |    mens     |
| Analog Innovations, Inc.                         |     et      |
 Click to see the full signature
Reply to
Jim Thompson

file.

You keep saying that but I did create professional looking presentations with it. Often I just verbatim-copy the plot pane out of it. During a design review in a somewhat darkened room (to accommodate the projector) it actually looks rather cool. At an aerospace client the guys even remarked that they wished they could easily generate such output with their CAD.

Had to. The client wanted it that way and the client is king :-)

PSpice Schematics is incompatible with Capture 16.3, so no choice for me.

I still have to figure out how to do that in Eagle. Since that CAD is highly programmable I should be able to do that. But I am not a code writing specialist and I don't have a son who can do that for me :-)

--
Regards, Joerg

http://www.analogconsultants.com/
 Click to see the full signature
Reply to
Joerg

Click Help>Help Topics Search Tab Type in Third Party Model Follow Directions

The trick to editing the transistor is CTRL-RIGHT-CLICK

Reply to
Wanderer

AKA: Doing the same thing over and over, but expecting different results? There's a word for that.

--
It's easy to think outside the box, when you have a cutting torch.
Reply to
Michael A. Terrell

Ctrl-right-click the transistor and set Value to the model name.

e.g.

Version 4 SHEET 1 880 680 WIRE -176 16 -272 16 WIRE -272 48 -272 16 WIRE -176 48 -176 16 WIRE -336 96 -416 96 WIRE -416 128 -416 96 WIRE -272 192 -272 144 WIRE -272 320 -272 272 FLAG -176 48 0 FLAG -416 128 0 FLAG -272 320 0 SYMBOL npn -336 48 R0 SYMATTR InstName Q1 SYMATTR Value foo SYMBOL current -272 192 R0 WINDOW 123 0 0 Left 0 WINDOW 39 0 0 Left 0 SYMATTR InstName I1 SYMATTR Value 1m TEXT -104 24 Left 0 !.MODEL foo NPN IS=3E-14 NF=1 BF=110 IKF=0.4\n+VAF=1900 ISE=1E-12 NE=1.6 NR=1 BR=7 IKR=0.2 VAR=75\n+ISC=1E-10 NC=1.9 RB=0.4 RE=0.1 RC=0.1 CJC=10.9E-12\n+MJC=0.347 VJC=0.476 CJE=82.6E-12 TF=1.3E-9 TR=2.3E-7 TEXT 4 208 Left 0 !.tran 1u

Reply to
Andrew Holme

file.

If we can get a few folks together and put in a few hundred bucks bounty each, we could probably find a FOSS programmer who'd do it. It'd pay for itself pretty fast.

Cheers

Phil Hobbs

--
Dr Philip C D Hobbs
Principal
 Click to see the full signature
Reply to
Phil Hobbs

file.

I don't know Eagle, but from PSpice, you simply merge the netlist into the .CIR file (text editor), then run the .CIR file with LTspice. ...Jim Thompson

--
| James E.Thompson, CTO                            |    mens     |
| Analog Innovations, Inc.                         |     et      |
 Click to see the full signature
Reply to
Jim Thompson

leaving

its

it

file.

Good idea. But let me check first, haven't done it in a while. If I can't find anything I'll post in one of the Eagle NGs.

Not sure what you mean with *.cir, LTSpice calls its files *.asc. But yeah, there should be a fairly easy way to do it. Eagle has tons of scripts, including for software that almost dates back to the Romans. I'll check again if someone has done it in the meantime. The Eagle community is very open in that respect and Cadsoft has provided a special area for sharing scripts and user language programs.

--
Regards, Joerg

http://www.analogconsultants.com/
 Click to see the full signature
Reply to
Joerg

SCHEMATIC files are *.asc

In LTspice just do File/Open on the .CIR file of interest, then "Run".

Anyone conversant in Spice knows what a .CIR file is ;-)

I doubt you even need a script. ...Jim Thompson

--
| James E.Thompson, CTO                            |    mens     |
| Analog Innovations, Inc.                         |     et      |
 Click to see the full signature
Reply to
Jim Thompson

Well, it's been decades since I last type up a SPICE netlist by hand. Back when DOS 3.2 was king.

Just took a look at th LTSpice sim I did yesterday. No *.cir files. Where do they live?

Depends one what's in there. SPICE expects pin numbers to be in a certain order and to adhere to naming conventions.

--
Regards, Joerg

http://www.analogconsultants.com/
 Click to see the full signature
Reply to
Joerg

I have no idea where Mike hides them, if he uses them at all. I do know that LTspice runs them just fine. And a search finds a bunch of them in the Yahoo zip files... and calls them as type "LTspice netlist file", so installation of LTspice must take that designation (I keep LTspice on a separate machine from PSpice just to avoid such "Open with" conflicts).

You mean Eagle doesn't follow Berkeley traditions ?:-) ...Jim Thompson

--
| James E.Thompson, CTO                            |    mens     |
| Analog Innovations, Inc.                         |     et      |
 Click to see the full signature
Reply to
Jim Thompson

When hooking up transistors in LTSpice, be sure to *not* solder them in.

Reply to
John S

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.