;; initialization
(setq designName "./spectre/schematic/netlist/netlist")
(setq resultPath "./spectre/result")
(setq modelName "model.lib")
(setq saveFile "save.scs")
(setq corners list("ss" "ff" "tt"))
;; run script
ocnWaveformTool('wavescan )
simulator('spectre )
design(designName)
analysis(
'tran
?stop "8.814u"
?errpreset "conservative"
)
desVar( "VRP" 1.2 )
desVar( "VRN" 0 )
desVar( "AVDD12" 1.2 )
envOption(
'userCmdLineOption "+aps +parasitics +mt=20"
)
option(
'nthreads "30"
'multithread "on"
'temp "85"
)
saveOption('nestlvl "1")
saveOption('save "selected")
foreach(corner corners
resultsDir(sprintf(nil "%s/%s" resultPath corner))
modelFile(
list(modelName sprintf(nil "%s" corner))
list(modelName sprintf(nil "res_%s" corner))
list(modelName sprintf(nil "mom_%s" corner))
list(saveFile)
)
paramAnalysis(
"temp"
?values '(-40 -20 0 55 85 125)
)
paramRun()
)
winID=newWindow()
clearAll()
graphicsOff()
foreach(
corner corners
openResults(sprintf(nil "%s/%s" resultPath corner))
selectResults('tran)
(setq V VT("OUT"))
plot(V)
)
graphicsOn()
ad1
Sunday, December 27, 2015
Saturday, December 26, 2015
Waveform & Waveform Family
Use drIsWaveform & famIsFamily
(defun fcnName (wave_x @rest wl)
(let (a b c)
(cond
((drIsWaveform wave_x)
blah blah
blah blah
) ; is waveform
((famIsFamily wave_x)
(apply 'famMap (constar 'fcnName wave_x wl))
) ; is family
(t
(error "can't handle %L\n" wave_x)
) ; not a waveform and not a family of waveform
) ; cond
) ; let
) ; defun
(defun fcnName (wave_x @rest wl)
(let (a b c)
(cond
((drIsWaveform wave_x)
blah blah
blah blah
) ; is waveform
((famIsFamily wave_x)
(apply 'famMap (constar 'fcnName wave_x wl))
) ; is family
(t
(error "can't handle %L\n" wave_x)
) ; not a waveform and not a family of waveform
) ; cond
) ; let
) ; defun
SKILL Internal system variable
autoReload
debugMode
errsetTrace
fullPrecision
integermode
mergemode
printinfix
writeProtect
stacktraceDump
stacktrace
sourceTracing
traceArgs
debugMode
errsetTrace
fullPrecision
integermode
mergemode
printinfix
writeProtect
stacktraceDump
stacktrace
sourceTracing
traceArgs
status & sstatus
Friday, December 25, 2015
.oceanrc file
$ oceanThis command loads and reads your .cdsinit file first and then loads and reads the .oceanrc file. You can place OCEAN commands in your .oceanrc file, which is similar to the .cdsinit file.
Draw Waveform From Corner Simulation Result
winID=newWindow()
corners = list("ss" "ff" "tt")
resultPath="./opamp_stb_tb/spectre/PVT"
clearAll()
; Note:
; graphicsOff()/graphicsOn() helps eliminates the redraw for each plot.
; When graphicsOn() is called, the completed plot appears.
graphicsOff()
foreach(
var
corners
openResults(sprintf(nil "%s/%s" resultPath var))
selectResults('stb_margin)
plot(getData("phaseMargin"))
)
graphicsOn()
corners = list("ss" "ff" "tt")
resultPath="./opamp_stb_tb/spectre/PVT"
clearAll()
; Note:
; graphicsOff()/graphicsOn() helps eliminates the redraw for each plot.
; When graphicsOn() is called, the completed plot appears.
graphicsOff()
foreach(
var
corners
openResults(sprintf(nil "%s/%s" resultPath var))
selectResults('stb_margin)
plot(getData("phaseMargin"))
)
graphicsOn()
Subscribe to:
Posts (Atom)

