The Designer's Guide Community Forum
https://designers-guide.org/forum/YaBB.pl
Simulators >> Circuit Simulators >> Spice model
https://designers-guide.org/forum/YaBB.pl?num=1132562296

Message started by Michele Marino on Nov 21st, 2005, 12:38am

Title: Spice model
Post by Michele Marino on Nov 21st, 2005, 12:38am

Hello, I´m a problem with Spice library´s conversion. I must convert the THS3202 library and my problem is on this piece of netlist:

.SUBCKT cswil 1 2 3 4  
+ PARAMS:
+ IL = 800u ;
v1  1 2 0
Gout 3 4 value={limit(I(v1),IL,-IL)} ;
.ENDS cswil

Can you help me?

Thanks, Michele.

Title: Re: Spice model
Post by Geoffrey_Coram on Nov 22nd, 2005, 4:56am

What are you trying to convert it to?  Spectre's VCCS has min and max parameters that should deal with what you have.

I'm a little confused by the subckt, though: a G element is a VCCS (voltage-controlled current source), but it is sensing a current I(v1),
which makes it look like it should be a current-controlled source.
Is it a CCCS or a CCVS??

Title: Re: Spice model
Post by Michele Marino on Nov 22nd, 2005, 5:17am

This is the original model from Texas Inst. site:

.SUBCKT cswil 1 2 3 4  
+ PARAMS:
+ IL = 800u ;
v1  1 2 0
Gout 3 4 value={limit(I(v1),IL,-IL)} ;
.ENDS cswil
It seem that Gout is controlled by current and not by voltage. Please help me.

Michele.

Title: Re: Spice model
Post by mmelectronics on Nov 22nd, 2005, 5:26am

So this is the calling to the subckt:

X_U5         VCC A VCC HIZ CSWIL PARAMS:  IL=3000U

Title: Re: Spice model
Post by mmelectronics on Nov 22nd, 2005, 8:44am

How I can explain the current that flow in a component with spectre syntax?

Thanks, Michele.

Title: Re: Spice model
Post by Geoffrey_Coram on Nov 30th, 2005, 12:47pm

subckt CSWIL (1 2 3 4)
 parameters IL = 800u
CCS (3 4 1 2) cccs gain=1 min=-IL max=IL
ends CSWIL

This should do it. The subckt you had shorted terminals 1 and 2 (through v1), measured this current, clamped it between +/- IL, and output that current.

The Designer's Guide Community Forum » Powered by YaBB 2.2.2!
YaBB © 2000-2008. All Rights Reserved.