Easily modifying BJT parameters in LTSpice?

In summary, the conversation discusses how to modify the hfe values for transistors in a multistage amplifier in LTSpice IV. The speaker has had success modifying component parameters in B2Spice but is now having trouble with LTSpice. The solution is to modify a file called standard.BJT and give each transistor a modified name with the desired hfe value. Another question is also raised about using LTSpice's default values for other BJT parameters. Some helpful tips and resources are provided for better results.
  • #1
crono1009
15
0
I've created a multistage amplifier in LTSpice IV and want to use actual measured hfe (Beta) values for each of the transistors, though I can't find an easy way to modify them. I could modify their library values in notepad, but I am using the same transistor model for a few of the stages and that would make both of their hfe values the same (when I've measured them to be substantially different).

In the past I've used B2Spice and modifying each of my components parameters was as easy as double clicking on the component itself and plugging in values. Is this possible in LTSpice?

Any help would be greatly appreciated, Thanks!
 
Engineering news on Phys.org
  • #2
You can do this, although it is a little messy.

Look for a file called standard.BJT in the following directory:
c:\Program Files\LTC\LTspiceIV\lib\cmp\

If your transistor is in there, you can copy it to another position in the list (probably at the top) and then modify the "BF=" figure to your measured value.
You can do this with each of your measured values and then give each transistor a modified name.
For example, you could give a 2N2222 the name 2N2222-100 if you had given it a Hfe of 100.
Then save the file.

To use it, select the generic NPN transistor. Put it on the schematic page. Right click and choose "pick another transistor". Then look for your modified version.
 
  • #3
Thanks! That worked perfectly.
 
  • #4
Actually vk6kro I have another question about LTspice if you don't mind. Let's say I created put a generic npn transistor in my circuit. Then I created a .model for that transistor for example, .model 2N3904-95 NPN(Bf=95). Will LTspice insert its own default values in for all of the other BJT parameters (junction capacitances and such)?

Also as a rule of thumb while creating .model BJTs are there any values (Bf, VAF, RX etc.) I should always input while leaving the rest of the values as LTspice defaults? I'm designing pretty simple multistage amplifiers at the moment and don't need super accurate results.

Thanks again!
 
  • #5
I haven't really tried just leaving parameters out, but LTSpice does have default parameters so I expect it might fill in the gaps if you left something out.

You could probably get a better result by picking a similar transistor and just changing the parameters you wanted to change. That way, the other things like internal capacitances might be closer than the default values.

You can see an interesting article on this. Go to HELP on LTSpice. Search for "parameters" then select "Q", bipolar transistor.
 
  • #6
Nice info

woww, this thread is very helpful
 
  • #7

1. How do I modify the parameters of a BJT in LTSpice?

To modify the parameters of a BJT in LTSpice, you can either double-click on the BJT symbol in your circuit, or right-click and select "Edit." This will open the BJT properties window where you can change the parameters such as beta, VAF, etc.

2. Can I modify the parameters of a BJT while my circuit is running in LTSpice?

Yes, you can modify the parameters of a BJT while the simulation is running in LTSpice. However, keep in mind that the changes will not take effect until the simulation is restarted.

3. How do I change the temperature at which the BJT is operating in LTSpice?

To change the operating temperature of a BJT in LTSpice, you can go to the "Edit Simulation Cmd" window and add the ".temp" command followed by the desired temperature. For example, ".temp 25" will set the temperature to 25 degrees Celsius.

4. Is there a way to easily modify multiple BJT parameters at once in LTSpice?

Yes, you can use the ".step" command in LTSpice to modify multiple BJT parameters at once. This allows you to run multiple simulations with different sets of parameters and analyze the results easily.

5. Can I save the modified BJT parameters in LTSpice for future use?

Yes, you can save the modified BJT parameters in LTSpice by right-clicking on the BJT symbol and selecting "Save." This will save the modified parameters as a new model which can be used in future simulations.

Similar threads

Replies
1
Views
831
  • Electrical Engineering
Replies
14
Views
4K
Replies
4
Views
1K
Replies
22
Views
2K
  • Programming and Computer Science
Replies
11
Views
959
  • Electrical Engineering
Replies
2
Views
3K
  • Engineering and Comp Sci Homework Help
Replies
4
Views
17K
  • Set Theory, Logic, Probability, Statistics
Replies
12
Views
1K
  • Electrical Engineering
Replies
13
Views
6K
  • Engineering and Comp Sci Homework Help
Replies
3
Views
1K
Back
Top