I have been trying to plot eye diagrams in cadence. The command eyediagram(signal,start,stop,period) is the format. But i am not able to control the no of eyes in my diagram. Say i run my simulation from 0 to 10u and my input clk is 5Ghz, typically to get a SINGLE EYE, i should give 200p as period rite ? I have added a 25p, 25p rise time fall time for it. But the thing seems going crazy.
Any ideas whats bugging ?
Yes, 200p should give a single period of the waveform - ie. one rise and one fall. Maybe some pictures would help explain your problem (also please state which version of the tools you're using - Help->About will tell you this). I don't really understand what the rise and fall time you're talking about is related to either.
In reply to Andrew Beckett:
Attaching the figures below
I am attaching the figures of my PRBS specifications. I am using cadence 6.1. I needed a centred eye diagram which i am not able to get. Either i get an incomplete eye as shown in the attached file, or i get multiple cycles, But not ONE EYE ALONE.
When i enter the period in the eyediagram function, does it include the rise time and fall time of the wave under consideration. THe plots i have attached ignores the same ? Does it affect my eye diagram as a whole ?
I hope i am clear.
In reply to nevinalex1234:
The first picture does show a single eye - maybe you just want it shifted though? To do that, you could specify 50p as the start time. You could do the same thing with 100p chunks and shift it by half a rise time - maybe that's what you want?
I don't see why the eye diagram needs to know about the rise time and fall time - it simple cuts the waveform up into 200p (or whatever period) chunks and overlays them.
You can also use the eye diagram assistant in ViVA (Measurements->Eye Diagram) which has a form to allow you to set it up - it also supports an edge-triggered eye diagram (unless you're using early IC615 versions - you didn't say which subversion you're using - I know it must be IC615 something because that's the new graph I see).
I adjusted my start time and i got something like this.
This is what i wanted. When i try to confirm the same design in matlab (extracting the data to matlab and using commscope.eyediagram), i am not getting the same eye, there are a set of parameters,
eyeobj= commscope.eyediagram('SamplingFrequency', 10e9, ... 'SymbolsPerTrace', 2,... 'SamplesPerSymbol', 10, ... 'MinimumAmplitude', -1, ... 'MaximumAmplitude', 1, ... 'AmplitudeResolution', .001, ... 'MeasurementDelay', 0, ... 'PlotType', '2D Line', ... 'PlotTimeOffset', 0, ... 'RefreshPLot','on',... 'ColorScale', 'linear');eyeobj.update(data);
Basically i am trying to convince that the eye diagram plot from matlab and cadence are one and the same. But what are the parameters that i have to additionally give to see the same eye diagram. I have given samples per symbol as 10, but in my earlier post, i have asked reg sampling frequency in cadence, you had told that there is no such thing (http://www.cadence.com/community/forums/T/23319.aspx). In that case what will be my Samples per Symbol ? I hope i am clear
Currently with the given parameters, i am getting a matlab plot like this which is not the same as the cadence one, atleast in first look.
The matlab plot doesn't look like a proper eye diagram to me - so I assume you're asking about how to set things up in Matlab?
Also, I didn't say in the other post that there is no such thing as a regular sampling frequency - I said that there isn't a sampling frequency unless you told it to sample. In order to compare with Matlab, I used this example netlist - which comes from my app note on Cadence Online Support (with a small modification to strobe the output):
// prbs.scsvclk (clk 0) vsource type=pulse period=80n val0=0 val1=1 rise=0.3n fall=0.3n delay=3nv1 (high 0) vsource type=prbs period=40n val0=0 val1=1 rise=0.3n fall=0.3n delay=3n //seed=1942del (withdelay high) randdelay sd=1n rise=0.3nrl (withdelay jitter) resistor r=100cl (jitter 0) capacitor c=50pr1 (high 0) resistor r=1kahdl_include "randdelay.va"tran tran stop=400u strobeperiod=0.5n
Notice I've added strobeperiod=0.5n to force there to be fixed rate outputs every half a nanosecond.
This uses this VerilogA model to add random jitter (of sorts):
// VerilogA for randdelay`include "constants.h"`include "discipline.h"module randdelay (op,ip);output op;input ip;electrical op,ip;parameter real sd=2.0n;parameter real gainsd=0.1;parameter real del=5.0n;parameter real rise=0.1n;parameter real thresh=0.5;parameter integer seed = 23133;integer vseed;real randnum,gain,delayed;analog begin @(cross(V(ip)-thresh)) begin randnum=$rdist_normal(vseed,0,1); randnum=randnum*sd+del; gain=$rdist_normal(vseed,0,1)*gainsd+1; if(randnum<0) randnum=0.0; end delayed= transition(V(ip),randnum,rise,rise); V(op) <+ gain*(delayed-thresh)+thresh;endendmodule
I run the simulation using spectre prbs.scs and then in Matlab I do:
There are 160 samples per symbol, because the period of my signal is 80ns, and I have a sample every 0.5n - so there are 160 samples per symbol. I want to show one Period in the trace, and the SamplingFrequency is the inverse of my strobeperiod. I've told it the Max and Min amplitude to scale it OK.
In ViVA I use the Eye Diagram assistant and tell it to use a period of 80n and I start from 160n (just to avoid a startup glitch, but that's not critical). The corresponding function is:
eyeDiagram(v("jitter" ?result "tran") 160n 400.0u 80n ?intensityPlot t)
(the intensityPlot bit is just to make it look prettier)
I've captured the two results side by side. As you can see, they look rather similar (The colours in the Matlab graph don't show up as brightly for the rarer points, but other than that you can see they match well).
hi andrew.. thankx a lot for elaborating in excellent detail.
I am getting the following error for the above prbs.scs . I am stuck @ this point.
Notice from spectre during hierarchy flattening.
v1: Invalid enumeration `prbs' used as value of parameter `type'. Ignored.
Error found by spectre during hierarchy flattening.
v1: Waveform type must be specified if any waveform parameters are given.
You must be using an old version of spectre. The prbs source type has been available since MMSIM71 (and since then we've had MMSIM72, MMSIM101, MMSIM111).
Of course, I'm only using the prbs source type for convenience - I'm sure you could generate a bit stream another way if you preferred (even a pulse source would do to illustrate the eye diagram).
DOne... exhaustive thread !
Just to add on.
Can i run simulate the prbs.scs file in ADE environment? I created the verilog a model and and tried to run prbs.scs in spectre ADE (added it to Setup---> SImulation Files--> Stimulus Files). But i get the following error.
End netlisting Sep 11 11:29:32 2012
ERROR (OSSHNL-514): Netlisting failed due to errors reported before. Netlist may be corrupt or may not be produced at all. Fix reported errors and netlist again.
But i have sucessfuly compted the simulation while running from terminal "spectre prbs.scs"
Basically i wanted to plot the jitter waveform in ADE Waveform window.