The Designer's Guide Community Forum
https://designers-guide.org/forum/YaBB.pl Design Languages >> Verilog-AMS >> switch model in DC-sweep analysis https://designers-guide.org/forum/YaBB.pl?num=1374240681 Message started by spinfab on Jul 19th, 2013, 6:31am |
Title: switch model in DC-sweep analysis Post by spinfab on Jul 19th, 2013, 6:31am Hello, I wrote a .va model for a switch with a "if then else" approach using $discontinuity(0) and transition(..) commands to improve management of the sharp transition. For a transient analysis it is functional, but for a DC-sweep analysis ( to plot an I vs V curve), it fails. Any idea to help me fab nb: code skeleton if (state==0) G=Gmax; else if (state==1) G=Gmin; G = transition(G_digital,0,1p); I(b1) <+ G*V(b1); |
Title: Re: switch model in DC-sweep analysis Post by Ken Kundert on Jul 19th, 2013, 8:18am Your code is nonsensical. If you cannot give the original code, at least provide a complete model that actually exhibits the problem. -Ken |
Title: Re: switch model in DC-sweep analysis Post by spinfab on Jul 22nd, 2013, 2:04am Hello, Finally I succeed by defining a dedicated bloc for DC analysis "analysis('dc')", with the sharp transition transformed in a linear approach. fab |
The Designer's Guide Community Forum » Powered by YaBB 2.2.2! YaBB © 2000-2008. All Rights Reserved. |