ad1

Monday, November 2, 2015

SpectreMDL Control File For Searching Setup Time of DFF

The SpectreMDL control file is shown below:
alias measurement setup_time{
run tran
export real outcross, Tsetup, maxq
outcross=cross(V(Q),thresh=DVDD18/2)
maxq=max(Q)
Tsetup=deltax(sig1=V(CLK),sig2=V(D),dir1='rise, \
                               n1=1,thresh1=DVDD18/2,dir2='rise,n2=1,thresh2=DVDD18/2) } 
// print results in user-defined format
print fmt("*****Intermediate results of search*****\n\n") to="search.print" 
// define a binary search function, varying the value of
// vdata:delay from 2n to 10n with tolerance=1p
search VD:delay from binary(start=2n, stop=10n, tol=0.1p) {
run setup_time
print fmt("%-15g%-15g%-15g%-15g\n", \
VD:delay, \
setup_time->outcross, \
setup_time->maxq, \
setup_time->Tsetup) \
addto="search.print"
} while (setup_time->maxq > DVDD18/2)
The simulated result is:
*****Intermediate results of search*****
2e-09          1.02004e-08    0.954856       -8e-09      
1e-08          nan            0.0050413      0            
6e-09          1.02004e-08    0.954722       -4e-09      
8e-09          1.02004e-08    0.95465        -2e-09      
9e-09          1.02006e-08    0.954709       -1e-09      
9.5e-09        1.02014e-08    0.954846       -5e-10      
9.75e-09       1.02028e-08    0.932577       -2.5e-10    
9.875e-09      1.02052e-08    0.910011       -1.25e-10    
9.9375e-09     1.02193e-08    0.919918       -6.25e-11    
9.96875e-09    1.025e-08      0.954308       -3.125e-11  
9.98438e-09    nan            0.0050413      -1.5625e-11  
9.97656e-09    nan            0.0050413      -2.34375e-11
9.97266e-09    1.02682e-08    0.954683       -2.73437e-11
9.97461e-09    1.0297e-08     0.928062       -2.53906e-11
9.97559e-09    1.03718e-08    0.926719       -2.44141e-11
9.97607e-09    nan            0.0050413      -2.39258e-11
9.97583e-09    nan            0.0050413      -2.41699e-11
9.97571e-09    nan            0.0050413      -2.4292e-11  
9.97565e-09    1.0398e-08     0.945892       -2.4353e-11  
9.97565e-09    1.0398e-08     0.945892       -2.4353e-11    




No comments:

Post a Comment