I have one big file with c.a. 800 zener diodes models from LTSpice.
When I import zener diode model:
.subckt 1N4728A 1 2
D1 1 2 DF
DZ 3 1 DR
VZ 2 3 0.972
.MODEL DF D ( IS=125p RS=0.620 N=1.10 CJO=364p VJ=0.750 M=0.330 TT=50.1n )
.MODEL DR D ( IS=25.0f RS=1.24 N=3.00 )
.ends
to create Qspice Zener symbol, symbol created works without any problerm.
I was trying to create symbols with independent library txt files.
Error messages:
Warning: library has a .ends without matching .subckt
Fatal error: .ends without matching .subckt
or
Fatal error: Unresolved subcircuit in: X1 0 OUT 1N4728A
Why it’s not working with that zener diode simulation?
The problem is only with that kind of model - and it’s may be a problem with CRLF character (Carriage Return Line Feed) in txt files of any kind.
Have you any idea, how to run a symbol model connected to the external txt library?
zener-TEST.cpp (6.3 KB)
cpp ext change on zip and unpack to test.
˙Ř˙Ű«symbol
«type: X»
«description: Zener Diode»
«library file: zener.txt»
«shorted pins: false»
«line (80,80) (-80,80) 7 0 0x1000000 -1 -1»
«line (0,200) (0,80) 7 0 0x1000000 -1 -1»
«line (0,-200) (0,-70) 7 0 0x1000000 -1 -1»
«line (80,80) (130,130) 7 0 0x1000000 -1 -1»
«line (-130,30) (-80,80) 7 0 0x1000000 -1 -1»
«triangle (0,80) (100,-70) (-100,-70) 7 0 0x1000000 0x2000000 -1 -1»
«text (100,200) 0.5 7 0 0x1000000 -1 -1 "X"»
«text (100,-200) 0.5 7 0 0x1000000 -1 -1 "1N4728A"»
«pin (0,-200) (0,0) 1 0 0 0x0 -1 "1"»
«pin (0,200) (0,0) 1 0 0 0x0 -1 "2"»
»
That symbol is not working with txt file zener.txt
.subckt 1N4728A 1 2
D1 1 2 DF
DZ 3 1 DR
VZ 2 3 0.972
.MODEL DF D ( IS=125p RS=0.620 N=1.10 CJO=364p VJ=0.750 M=0.330 TT=50.1n )
.MODEL DR D ( IS=25.0f RS=1.24 N=3.00 )
.ends




