The Designer's Guide Community Forum
https://designers-guide.org/forum/YaBB.pl
Modeling >> Behavioral Models >> Switch model
https://designers-guide.org/forum/YaBB.pl?num=1121433622

Message started by noreng on Jul 15th, 2005, 6:20am

Title: Switch model
Post by noreng on Jul 15th, 2005, 6:20am

I need to model a switch consisting of two transistors in parallel which are conducting a current either in the left or the right branch.
The model should be in Verilog-A(MS).

Title: Re: Switch model
Post by sheldon on Jul 16th, 2005, 7:43am

Noreng,

   Do you need a switch model or a multiplexer model?
Have you tried the sw_no model in bmslib? What are
you looking for in the model?

                                              Best Regards,

                                                  Sheldon

Title: Re: Switch model
Post by noreng on Jul 18th, 2005, 2:04am

I'm making a high level model of a current switched DAC with complementary current outputs. I need a switch which behaves like a voltage controlled resistor in a range of the control voltage and which becomes a high resistance when the control voltage is below a low threshold and vice versa.
I've made a model which does this, and it seems to work in dc analysis. However, in transient analysis something strange happens. Then, the outputs start switching before getting stuck for about 400ps. Then, the switching continues until each output reaches its deistination.

Title: Re: Switch model
Post by sheldon on Jul 18th, 2005, 9:17am

Noreng,

  Again, the sw_no is probably a good place to start. In
the past, I have added threshold voltage and body effect
to it to simulate distortion due to a sampling switch. The
one change you will need to make is to re-formulate the
switch. The control voltage will be the difference in the
two levels and the outputs will be complementary.

                                                     Best Regards,

                                                         Sheldon

Title: Re: Switch model
Post by noreng on Jul 18th, 2005, 11:38pm

Thanks for your reply.

Where do I find the sw_no model?

Title: Re: Switch model
Post by Andrew Beckett on Jul 19th, 2005, 10:48am

Put this in your cds.lib file:


Code:
DEFINE bmslib $CDSHOME/tools/dfII/samples/artist/bmslib


where $CDSHOME is the path to your IC installation.

Sheldon mentioned that sw_no was from bmslib earlier. Note, bmslib first appeared in the installation in IC5033 - so you'll need IC5033 or IC5141 to see this.

Regards,

Andrew.

Title: Re: Switch model
Post by noreng on Jul 19th, 2005, 11:26pm

Thanks for your help.

I'm using eldo meaning that I don't have access to the sw_no switch model. Is it possible to make it available on this web site?

Title: Re: Switch model
Post by Andrew Beckett on Jul 20th, 2005, 3:23am

I don't think I would be allowed to post it here. Copyright and all that...

Not that it is that complex. Fundamentally what happens is that it takes the digital switch control line, and then uses transition() to have some finite rise/fall time between 0 and 1. Then it uses pow() to logarithmically alter the resistance of the branch across the switch terminals.

i.e. along these lines:


Code:
rout = roff*pow(ron/roff,transition(state, tconv, trise, tfall));


Hopefully that explains enough of the principles without posting the actual code here.

Andrew.

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