“model name is missing” error in HSPICE

simulationspice

I get these errors in a simulation in HSPICE and I don't know why:

model name is missing            tokin number=   4
difficulty in reading input

Here is are some lines of my net list:

QQ1 15 14 1 TIP42C
D1 7 8 1N4148
QQ3 9 8 11 BD140

And some lines of the model descriptions:

*BC327
.MODEL BC327 PNP (IS=0.230P NF=1.000 BF=504.327 VAF=26.000 IKF=0.780 .....
*BD140
.MODEL Qbd140 pnp
+IS=1e-09 BF=650.842 NF=0.85 VAF=10....
*1N4148
.model D1N4148 D (IS=0.1PA, RS=16 CJO=2PF TT=12N BV=100 IBV=0.1PA)....

There is a weird thing in BD140 and 1n4148 model description. Why in the model description the correcponding prefix is put again? Or is it the case that BC327 model description should have had the prefix? What is the "token number" by the way?
Thanks

Best Answer

The Proton is right in his commentary. It holds also for D1 (D1N4148). The model name of a part in a corresponding netlist must agree with the model name in the .model statement. So, if you have named the model D1N4148, then your netlist must contain D1 7 8 D1N4148 line; and QQ3 9 8 11 QBD140 line, of course, as The Proton already indicated.

I don't think the prefix of the reference designation matters, the Q in your case. In my opinion netlister added it to provide the right reference according to the device type (Q for BJT, M for MOSFET, etc.), as required by simulator. In such a case you yourself can use an arbitrary reference designation and netlister provides the right first letter.

As to comment lines, it doesn't count, you can write whatever you want there.