start learning LTspice, and facing error - diyAudio
Go Back   Home > Forums > Design & Build > Software Tools

Software Tools SPICE, PCB CAD, speaker design and measurement software, calculators

Please consider donating to help us continue to serve you.

Ads on/off / Custom Title / More PMs / More album space / Advanced printing & mass image saving
Reply
 
Thread Tools Search this Thread
Old 25th February 2015, 02:11 PM   #1
diyAudio Member
 
Join Date: Mar 2009
Default start learning LTspice, and facing error

Hello,

I am now start learning LTSPICE
and I got a .SUBCKT data of 2sc3601 from another thread.

there is no problem for usual .model
but using this .subckt I face the problem as in the captured screen.

What is the exact problem?
or the .subckt has problem?

Thanks a lot.

Click the image to open in full size.
Attached Images
File Type: jpg sim.JPG (102.5 KB, 114 views)
  Reply With Quote
Old 25th February 2015, 04:14 PM   #2
diyAudio Member
 
cogsncogs's Avatar
 
Join Date: Jul 2003
Location: Wayne, West Virginia
You can't use the symbol "npn" with a subckt. You can add a npn symbol to the same directory/folder where you schematic (.asc) file(s) are located. When you go to choose a symbol, click on the "Top Directory" drop down box and choose the symbol that you've added.

Attached is a .asy file you can use. Remove the ".txt" extension at the end of the file name.
Attached Files
File Type: txt xnpn2.asy.txt (554 Bytes, 4 views)
  Reply With Quote
Old 26th February 2015, 03:48 PM   #3
diyAudio Member
 
Join Date: Mar 2009
Thanks for your reply.

so the procedures will be replacing Q1 with xnpn symbol
then .include the 2sc3601.sub
then change the value to Q2sc3601?

Error still

Or I should create new symbol by the 2sc3601.sub
  Reply With Quote
Old 26th February 2015, 03:53 PM   #4
diyAudio Member
 
Join Date: Mar 2009
i post the .subckt here, maybe there is error

.subckt Q2SC3601 C B E
+ params:
+ IC_VBE=1.10250E-36
+ IC_VCE=1.10250E-36
+ STATE=1
+ TEMP=0
+ AREA=1.0
+ STATE_FACTOR=0
+ IS=20.9E-15
+ BF=95
+ NF=1
+ VAF=80
+ IKF=0.2
+ ISE=0.0
+ NE=1.5
+ BR=0.2138
+ NR=1
+ VAR=20
+ IKR=0.5
+ ISC=0
+ NC=1.0
+ RB=4.0
+ RBM=4.0
+ RE=0.4
+ RC=3
+ CJE=5.84E-12
+ VJE=0.5
+ MJE=0.3083
+ TF=340E-12
+ XTF=1
+ VTF=10.0
+ ITF=0.2
+ PTF=0
+ CJC=5.32E-12
+ VJC=0.5
+ MJC=0.3271
+ XCJC=0.5
+ TR=10E-9
+ CJS=0
+ VJS=1.3
+ MJS=0.5
+ XTB=2.3
+ EG=1.11
+ XTI=3.0
+ KF=0
+ AF=1.0
+ FC=0.5

.END
  Reply With Quote
Old 27th February 2015, 04:27 PM   #5
diyAudio Member
 
cogsncogs's Avatar
 
Join Date: Jul 2003
Location: Wayne, West Virginia
The .MODEL statement is missing and .END should be .ENDS
I've commented out the 'unknown parameters', that which LTspice does not use and dropped the 'Q' so the subckt name and the file name will be the same. You can add the 'Q' back if you like.
Code:
.SUBCKT 2SC3601 1 2 3
Q1 1 2 3 2SC3601
.MODEL 2SC3601 NPN (
*+ IC_VBE=1.10250E-36
*+ IC_VCE=1.10250E-36
*+ STATE=1
*+ TEMP=0
*+ AREA=1.0
*+ STATE_FACTOR=0
+ IS=20.9E-15
+ BF=95
+ NF=1
+ VAF=80
+ IKF=0.2
+ ISE=0.0
+ NE=1.5
+ BR=0.2138
+ NR=1
+ VAR=20
+ IKR=0.5
+ ISC=0
+ NC=1.0
+ RB=4.0
+ RBM=4.0
+ RE=0.4
+ RC=3
+ CJE=5.84E-12
+ VJE=0.5
+ MJE=0.3083
+ TF=340E-12
+ XTF=1
+ VTF=10.0
+ ITF=0.2
+ PTF=0
+ CJC=5.32E-12
+ VJC=0.5
+ MJC=0.3271
+ XCJC=0.5
+ TR=10E-9
+ CJS=0
+ VJS=1.3
+ MJS=0.5
+ XTB=2.3
+ EG=1.11
+ XTI=3.0
+ KF=0
+ AF=1.0
+ FC=0.5)

.ENDS
With this model below you can use the default npn symbol as I see no need to use a subckt with it. That is unless you would want to use a drop-down menu. That would be a diiferent topic for a different time.
Code:
.MODEL 2SC3601 NPN (
+ IS=20.9E-15
+ BF=95
+ NF=1
+ VAF=80
+ IKF=0.2
+ ISE=0.0
+ NE=1.5
+ BR=0.2138
+ NR=1
+ VAR=20
+ IKR=0.5
+ ISC=0
+ NC=1.0
+ RB=4.0
+ RBM=4.0
+ RE=0.4
+ RC=3
+ CJE=5.84E-12
+ VJE=0.5
+ MJE=0.3083
+ TF=340E-12
+ XTF=1
+ VTF=10.0
+ ITF=0.2
+ PTF=0
+ CJC=5.32E-12
+ VJC=0.5
+ MJC=0.3271
+ XCJC=0.5
+ TR=10E-9
+ CJS=0
+ VJS=1.3
+ MJS=0.5
+ XTB=2.3
+ EG=1.11
+ XTI=3.0
+ KF=0
+ AF=1.0
+ FC=0.5)

Last edited by cogsncogs; 27th February 2015 at 04:29 PM.
  Reply With Quote

Reply


Hide this!Advertise here!
Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
LTSpice Error Log THD values macplauder Software Tools 3 12th February 2015 07:21 PM
Garmin Express software causing windows busy and error above windows start button. M Gregg The Lounge 2 17th October 2013 10:12 PM
which is best, sub driver up facing or down at floor Bill poster Subwoofers 8 24th March 2013 06:42 AM
Down facing drivers evad Subwoofers 4 22nd October 2007 05:25 PM
Rear facing ports MWP Multi-Way 2 4th December 2003 07:08 AM


New To Site? Need Help?

All times are GMT. The time now is 02:02 PM.


vBulletin Optimisation provided by vB Optimise (Pro) - vBulletin Mods & Addons Copyright © 2015 DragonByte Technologies Ltd.
Copyright 1999-2015 diyAudio

Content Relevant URLs by vBSEO 3.3.2