The Designer's Guide Community
Forum
Welcome, Guest. Please Login or Register. Please follow the Forum guidelines.
Jul 17th, 2024, 3:19pm
Pages: 1
Send Topic Print
Getting cadence convergence error for VerilogA code (Read 1987 times)
yash59
New Member
*
Offline



Posts: 2

Getting cadence convergence error for VerilogA code
Nov 11th, 2011, 11:37pm
 
Hi,

I want to write verilogA code for the symbol having three pins(cop,vdd,vss) all are inout pins.

Function: when vdd is greaterthan 3v and vss is 0, take input from cop and i have to send output from the same pin(cop).

I have written follwing code.

`include "constants.vams"
`include "disciplines.vams"

inout cop,vdd,vss;
voltage cop,vdd,vss;

real copin;

analog begin

copin=V(cop);
if(V(vdd>=3 && V(vss)==0)
begin
        V(cop)<+ copin;
end
else
       V(cop)<+0;
end
endmodule


with this code i am getting cadence convergence error.. plz help inthis regard.

thanks,
Back to top
 
 
View Profile   IP Logged
Forum Administrator
YaBB Administrator
*****
Offline



Posts: 145

Re: Getting cadence convergence error for VerilogA code
Reply #1 - Nov 12th, 2011, 2:25am
 
Normally when you don't give the actual model, or the testbench, or the error message, you make it quite difficult to help you (it is like you think we are psychic). However in this case, you yourself point out the problem. You are measuring the voltage of a pin, and then setting the voltage of the same pin to that value. In otherwords, your model states that:
Code:
copin=V(cop);
V(cop)<+ copin; 


This can be simplified to:
Code:
V(cop)<+ V(cop); 


The problem is that any voltage will satisfy that equation. Thus you have created a system where the solution is not unique, and simulators will not solve such systems. That is not really a problem in this case because this model makes no sense. Perhaps you can describe what you are trying to model and we can make suggestions.

-Ken
Back to top
 
 
View Profile WWW   IP Logged
Pages: 1
Send Topic Print
Copyright 2002-2024 Designer’s Guide Consulting, Inc. Designer’s Guide® is a registered trademark of Designer’s Guide Consulting, Inc. All rights reserved. Send comments or questions to editor@designers-guide.org. Consider submitting a paper or model.