Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Any way to plot Oscillation frequency vs Time in Cadence?

Status
Not open for further replies.

curious_engineer

Junior Member level 2
Joined
Nov 12, 2009
Messages
20
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,455
I have an oscillator, whose behavior with respect to time I want to observe. For example, I want to be able to see how long it takes before the oscillator starts oscillating at a desired frequency, if there is any overshoot, if the frequency somehow changes over time, etc.

I cannot figure out a way to do this on Cadence. I can add "frequency(VT("/oscillator_output"))" as an output, but that only plots frequency on the y-axis if I parametrically sweep a design variable. Otherwise, in a transient analysis, it simply displays a frequency value on the ADE window.

Thank you.
 

I have made veriloga widgets that take edge-to-edge
times, and turn them into an inverse voltage that represents
frequency. Not perfect, but close enough if you have a "well
behaved" (i.e. crosses zero, and no worse than square
wave harmonic content).
 
  • Like
Reactions: abe_00

    abe_00

    Points: 2
    Helpful Answer Positive Rating
Re: Any way to plot Oscillation frequency vs Time in Cadence

One month later, reviving this topic because I have come back to this project.

The "freq" command works, but it does not seem very precise for some reason. I can't really observe overshooting, and it does not start at 0. I would like to try a method that would perhaps be more accurate.

Can you please explain the veriloga algorithm, or some other more systematic method for accurately capturing Frequency vs Time for an oscillator?
 

maybe change the threshold from auto to user and give the corresponding dc level of your oscillator output
 

See below example of simple verilog-a module,
which shall be instantiated in circuit with frequency
that you would like to measure

------------
module freq_hdl(FO, IN);
output FO;
input IN;
electrical FO, IN;

parameter real VDD = 1.8;
parameter real scale = 1.0;

integer cross_in;
real per_in;
real prev_in;
real lat_in;
real freq;

analog begin

@ ( initial_step ) begin
cross_in = 0;
per_in = 0;
lat_in = 0;
freq = 0;
end

@ (cross( V(IN)-VDD*0.5, +1, 1e-3, IN.potential.abstol)) begin
cross_in = cross_in + 1;
prev_in = lat_in;
lat_in = $abstime;
end

if (cross_in < 2) begin
per_in = 0;
freq = 0;
end else begin
per_in = (lat_in - prev_in);
freq = (1/(per_in*scale));
end

V(FO) <+ transition(freq, 100p, 100p);

end

endmodule
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top