Maker Pro
Maker Pro

IL300 Analog Optoisolator model problem

J

Johnson

Jan 1, 1970
0
Cut n' Paste -- but I I am having problems getting my simulator to accept
the TABLE for controlling the VCVS -- from a spice library


****************************************************************************
***
* A - Anode of LED
* C - Cathode of LED
* A1 - Anode of photodetector 1
* C1 - Cathode of photodetector 1
* A2 - Anode of photodetector 2
* C2 - Cathode of photodetector 2
* K1 - Servo gain
* K2 - Forward gain
* K3 - Transfer gain
..Subckt IL300 A C A1 C1 A2 C2 PARAMS: K1=0.007 K2=0.007 K3=1
* IL300 from Siemens * RAP 5/97
DLED A E Demit
VE E C 0
E2 D1 0 TABLE ; {Ip2 vs IF}
+ {(0.955414823*0.999409809^(1/(abs(I(VE))+0.1p))*I(VE)^0.963133681)}
+ (0,0) (1,1)
Rdly1 D1 D2 1K
Cdly1 D2 0 0.17N
Rdly2 D2 D3 1K
Cdly2 D3 0 0.17N
Gdly1 C1 A1 VALUE {K1*V(D3)}
D1 A1 C1 Dtect
RD1 A1 C1 15G
Gdly2 C2 A2 VALUE {K3*K2*V(D3)}
D2 A2 C2 Dtect
RD2 A2 C2 15G
..model Demit D IS=1.51E-16 N=1.495822 RS=2.624361 BV=5 IBV=1U
+ CJO=15P VJ=1 M=0.5 EG=1.424 TT=500N
..model Dtect D IS=0.5p N=1 RS=0.001 BV=50 IBV=1U
+ CJO=14P VJ=0.159621 M=0.344264 EG=1.11 TT=10N
..ends
*$
****************************************************************************
***
 
M

Mike Engelhardt

Jan 1, 1970
0
Johnson,
Cut n' Paste -- but I I am having problems getting my simulator to
accept the TABLE for controlling the VCVS -- from a spice library
...

It's a native PSpice model. LTspice can run it, but you need to
change the "^" to "**" because LTspice understands "^" to be
Boolean XOR instead of exponentiation. Below is the model
running in a simple netlist in LTspice.

--Mike

*
X1 A C A1 C1 A2 C2 IL300
V1 1 0 PULSE(-5 5 0 10n 10n 5u 10u)
R1 1 A 1K
R2 1 A1 1K
R3 1 A2 1K
V2 2 0 5
R4 2 C 1K
R5 2 C1 1K
R6 2 C2 1K

..Subckt IL300 A C A1 C1 A2 C2 PARAMS: K1=0.007 K2=0.007 K3=1
DLED A E Demit
VE E C 0
E2 D1 0 TABLE ; {Ip2 vs IF}
+ {(0.955414823*0.999409809**(1/(abs(I(VE))+0.1p))*I(VE)**0.963133681)}
+ (0,0) (1,1)
Rdly1 D1 D2 1K
Cdly1 D2 0 0.17N
Rdly2 D2 D3 1K
Cdly2 D3 0 0.17N
Gdly1 C1 A1 VALUE {K1*V(D3)}
D1 A1 C1 Dtect
RD1 A1 C1 15G
Gdly2 C2 A2 VALUE {K3*K2*V(D3)}
D2 A2 C2 Dtect
RD2 A2 C2 15G
..model Demit D IS=1.51E-16 N=1.495822 RS=2.624361 BV=5 IBV=1U
+ CJO=15P VJ=1 M=0.5 EG=1.424 TT=500N
..model Dtect D IS=0.5p N=1 RS=0.001 BV=50 IBV=1U
+ CJO=14P VJ=0.159621 M=0.344264 EG=1.11 TT=10N
..ends

..tran 50u 50u
..probe
..end
 
J

Jim Thompson

Jan 1, 1970
0
Johnson,


It's a native PSpice model. LTspice can run it, but you need to
change the "^" to "**" because LTspice understands "^" to be
Boolean XOR instead of exponentiation. Below is the model
running in a simple netlist in LTspice.
[snip]

PSpice considers "^" to be Boolean XOR as well. The model probably
originated with SmartSpice, or of that ilk.

...Jim Thompson
 
M

Mike Engelhardt

Jan 1, 1970
0
Jim,
It's a native PSpice model. LTspice can run it, but you need to
change the "^" to "**" because LTspice understands "^" to be
Boolean XOR instead of exponentiation. Below is the model
running in a simple netlist in LTspice.
[snip]

PSpice considers "^" to be Boolean XOR as well.

I wish it true because it's one of the few incompatibilities
between LTspice and PSpice that I can't change without breaking
models already using "^" as XOR. But in this ABM context,
PSpice uses "^" as exponentiation instead of XOR. Here's an
example to illustrate:

*
V1 1 0 PULSE(0 2 0 .5m .5m 1u 1.002m )
E1 2 0 value { 2 ^ V(1) } ; LTspice: XOR, PSpice: exponentiation
E2 3 0 value { 2 ** V(1) } ; LTspice & PSpice: exponentiation
..tran 3m 3m
..probe
..end

Regards,

--Mike
 
J

Jim Thompson

Jan 1, 1970
0
Jim,
Cut n' Paste -- but I I am having problems getting my
simulator to accept the TABLE for controlling the VCVS
-- from a spice library ...

It's a native PSpice model. LTspice can run it, but you need to
change the "^" to "**" because LTspice understands "^" to be
Boolean XOR instead of exponentiation. Below is the model
running in a simple netlist in LTspice.
[snip]

PSpice considers "^" to be Boolean XOR as well.

I wish it true because it's one of the few incompatibilities
between LTspice and PSpice that I can't change without breaking
models already using "^" as XOR. But in this ABM context,
PSpice uses "^" as exponentiation instead of XOR. Here's an
example to illustrate:

*
V1 1 0 PULSE(0 2 0 .5m .5m 1u 1.002m )
E1 2 0 value { 2 ^ V(1) } ; LTspice: XOR, PSpice: exponentiation
E2 3 0 value { 2 ** V(1) } ; LTspice & PSpice: exponentiation
.tran 3m 3m
.probe
.end

Regards,

--Mike

Mike, The old-style Microsim Schematics, which I use, rejects "^", but
I can manually get PSpice itself to run a netlist with "^" in it as
exponentiation.

The manual lists "^" as XOR, but I've not tried it... I only use the
canned digital parts ;-)

Also, the manual only lists "**" for exponentiation. Maybe "^" is a
legacy holdover that PSpice can handle simply because it's pretty easy
to recognize logical operations as opposed to Algebraic.

...Jim Thompson
 
Top