ad1

Wednesday, November 4, 2015

MDL Control File for Finding Hold Time of DFF

The following mdl control file will find the hold time of a DFF:
alias   measurement holdTime{
 run tran
 export real outcross, Thold, maxq
 outcross=cross(V(Q),thresh=DVDD18/2)
 maxq=max(Q)
 Thold=deltax(sig1=V(CLK),sig2=V(D),dir1='rise, \
     n1=1,thresh1=DVDD18/2,dir2='fall,n2=1,thresh2=DVDD18/2) }
// print results in user-defined format
print fmt("*****Intermediate results of search*****\n\n") \
        to="../../../../../mdl_result/search_holdTime.print"
// define a binary search function, varying the value of
// vdata:width (width for Pulse Width) from 8n to 2n with tolerance=0.1p
search VD:width  from binary(start=8n, stop=2n, tol=0.1p) {
run holdTime
print fmt( "%-15g%-15g%-15g%-15g\n", \
VD:width, \
holdTime->outcross, \
holdTime->maxq, \
holdTime->Thold) \
addto="../../../../../mdl_result/search_holdTime.print"
} while (holdTime->maxq > DVDD18/2)
The transient waveform is shown below:

the data of mdl simulation is:
*****Intermediate results of search*****
8e-09          1.01736e-08    1.8            3.01e-09    
2e-09          nan            0.0050413      -2.99e-09    
5e-09          1.01823e-08    0.954557       1e-11        
3.5e-09        nan            0.0050413      -1.49e-09    
4.25e-09       nan            0.0050413      -7.4e-10    
4.625e-09      nan            0.0050413      -3.65e-10    
4.8125e-09     nan            0.0050413      -1.775e-10  
4.90625e-09    nan            0.0050413      -8.375e-11  
4.95312e-09    nan            0.0050413      -3.6875e-11  
4.97656e-09    1.02428e-08    0.905755       -1.34375e-11
4.96484e-09    nan            0.0050413      -2.51563e-11
4.9707e-09     nan            0.0050413      -1.92969e-11
4.97363e-09    1.03392e-08    0.937831       -1.63672e-11
4.97217e-09    nan            0.0050413      -1.7832e-11  
4.9729e-09     nan            0.0050413      -1.70996e-11
4.97327e-09    nan            0.0050413      -1.67334e-11
4.97345e-09    nan            0.0050413      -1.65503e-11
4.97354e-09    1.03675e-08    0.943537       -1.64587e-11
4.97354e-09    1.03675e-08    0.943537       -1.64587e-11
  
so the hold time for the simulated dff is negative

No comments:

Post a Comment