The Designer's Guide Community
Forum
Welcome, Guest. Please Login or Register. Please follow the Forum guidelines.
Jul 17th, 2024, 12:32am
Pages: 1
Send Topic Print
Printing magnitude in "AC" analysis (Read 2839 times)
Venkateshr
Junior Member
**
Offline



Posts: 10
Bangalore
Printing magnitude in "AC" analysis
May 31st, 2007, 3:52am
 
hello ,

            I want my verilogA block to recognize the input vsin source magnitude but it is not doing so.what is the reason ? I am just  using $display("%r",V(Vin));  but it is saying 0.0000.

However if I give some dc voltage to the vsin it is printing that.

Is there any way to get the magnitude ?

Please help me guys.
Back to top
 
 
View Profile   IP Logged
Geoffrey_Coram
Senior Fellow
******
Offline



Posts: 1999
Massachusetts, USA
Re: Printing magnitude in "AC" analysis
Reply #1 - Jun 1st, 2007, 9:13am
 
You can't get the ac magnitude from within the verilog-a module.  Only the simulator knows the ac small-signal quantities.  The modules have to evaluate their operating points at the dc voltages, but then the simulator takes the dc currents and conductances and builds the small-signal equivalent circuit.  The simulator doesn't evaluate the modules when solving the small-signal circuit.
Back to top
 
 

If at first you do succeed, STOP, raise your standards, and stop wasting your time.
View Profile WWW   IP Logged
Venkateshr
Junior Member
**
Offline



Posts: 10
Bangalore
Re: Printing magnitude in "AC" analysis
Reply #2 - Jun 1st, 2007, 11:11pm
 
Thanks. I thought the same.But desperately I want to build a frequenncy meter which works in ac that is why trying this sorts of things.

whether the ac_stim function will work inside veriloga in  correspondence to external ac frequency sweep ? I mean whether the freq. of ac_stim will be same as external frequency  :-/ ?

is there any way to build a frequency meter which works in ac & is it possible to measure the ac magnitude  so that amnt of peaking & 3db mmt, drop at specified frequency etc etc can be automated instead of manual mmt?
Back to top
 
 
View Profile   IP Logged
Ken Kundert
Global Moderator
*****
Offline



Posts: 2386
Silicon Valley
Re: Printing magnitude in "AC" analysis
Reply #3 - Jun 2nd, 2007, 10:48am
 
You would need to use a results processing language to automate the measurement of peaking and bandwidth. Something like MDL if you are using Spectre.

-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.