ad1

Sunday, December 27, 2015

OCEAN Script Template

;; 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()


No comments:

Post a Comment