vlsi design course 2000 cad tools magic/irsim/spice 簡介 presenter :黃世緯 助教 rm 322...
TRANSCRIPT
VLSI Design Course 2000
CAD ToolsCAD ToolsMagic/IRSIM/SPICEMagic/IRSIM/SPICE 簡介簡介
Presenter :黃世緯 助教Rm 322
10/18/2000
VLSI Design Course 2000
OutlineOutline
• Introduction
• Magic – Layout Editor
• IRSIM – Logic-level simulator for MOS circuits
• SPICE – Transistor-level simulator for MOS circuits
VLSI Design Course 2000
IntroductionIntroduction
Design Circuits Circuit-levelSimulator
SPICE
Layout ToolsMagic
Logic-levelSimulator
IRSIM
extract
verification
A
B
C
C=A?B=A?
VLSI Design Course 2000
What is Magic?What is Magic?
• A color painting tool?– Quite a bit about the nature of VLSI circuit
layout
• Additional operations– Built-in Design-Rule-Check (DRC)– Built-in Hierarchical circuit extractor– Some useful functions such as routing
tools
VLSI Design Course 2000
How to Get Help?How to Get Help?
• Manual– Hard copies– Electronic files
• postscript files available on http://video.ee.ntu.edu.tw/~vlsi_design/homework/cad_tools/magic.htm
• On WS: – ~d8921030/magic_tutorial (tutorial files)– ~d8921030/magic_tutcells (example files for tutorial)
• On-line help– >> :help subject
VLSI Design Course 2000
Running MagicRunning Magic
• 在 Linux 中的 magic 及 irsim, 均需要將 CAD_HOME 環境變數設到 /home/cad 目錄下 , 也就是 , 如果用的是 C Shell (csh, tcsh), 要加入下列兩行到 $HOME/.cshrc 中
setenv CAD_HOME /home/cad
set path=($path $CAD_HOME/bin) • 在 Linux 中執行
>> magic –dX11 –T tsmc0p8_spdm filename
VLSI Design Course 2000
The Box & the CursorThe Box & the Cursor
• Used to select things on the color display
Mouse left button
Mouse right button
VLSI Design Course 2000
Invoking CommandsInvoking Commands
• Invoking Commands– Type “:”(colon) or “;”(semi-colon) to invoke
command– Use macro
• E.g. ‘u’ means “:undo”
VLSI Design Course 2000
Magic Commands (1)Magic Commands (1)
• Basic Painting– :paint layers (color)– :erase layers
• “ ^D ” (erase all layers underneath the cursor)
– Use Mouse• Select or box what U would like to paint• Move to the color (layer) U would like to paint• Press middle button (or press left & right
together if U use 2-button mouse)
VLSI Design Course 2000
Magic Commands (2)Magic Commands (2)
• If I mistake to take action…– :undo
• Same as ‘u’
– :redo• Same as ‘U’
VLSI Design Course 2000
Magic Commands (3)Magic Commands (3)
• Selection– Move over the portion and type ‘s’– Select more
• Type ‘S’
– Select area ‘a’ / select more area ‘A’– Clear out the selection
• ‘C’ or “:select clear”
VLSI Design Course 2000
Magic Commands (4)Magic Commands (4)
• Operations on the Selection– :delete d– :move q(l), w(d), e(u), r(r)– :stretch Q, W, E, R– :copy c– :upsidedown (vertically flip)– :sideway (horizontally flip)– :clockwise
VLSI Design Course 2000
Magic Commands (5)Magic Commands (5)
• Label– :label– Erase a label
• Select it and delete it
– Erase all labels• :erase labels
– Labeling conventions• Vdd! GND! (important!!)
VLSI Design Course 2000
Magic Commands (6)Magic Commands (6)
• Save to files– :writeall– :save name
• Magic file format : *.mag
• Leaving Magic– :quit
VLSI Design Course 2000
Magic Commands (7)Magic Commands (7)• Utility Commands
– :grid [spacing]– :zoom z / Z (zoom in/out)
• Advanced Wiring– :array xsize ysize
• Cell Hierarchy– Expanding
• x (expand)• X (overview)
• Design Rule Checking– :drc why– :drc find
VLSI Design Course 2000
IRSIM – Logic-level simulator for IRSIM – Logic-level simulator for MOS circuitsMOS circuits
VLSI Design Course 2000
Function of IRSIMFunction of IRSIM
• Logic-level simulation (based on RC model)• Display simulation waveform• Differences from SPICE
– IRSIM is an event-driven logic-level simulator for MOS transistor circuits.
– SPICE is a circuit analysis tool for simulation of electrical circuits in steady-state, transient, and frequency domains.
VLSI Design Course 2000
IRSIM EXAMPLEIRSIM EXAMPLE
#1 Download magic file (ex or4.mag) and extract as .ext file.:load or4:extract#2 Convert .ext file to .sim file.ccsun> ext2sim or4.sim or4.ext#3 Construct command file for IRSIM.ccsun> vim or4.cmd
VLSI Design Course 2000
COMMAND FILE EXAMPLECOMMAND FILE EXAMPLE
h Vdd!l GND!vector INPUT a b c dclock Vdd! 1 1 1 1 1 1 1 1V INPUT 0000 0001 0010 0011 0100 0101 0110 0111R 1clock Vdd! 1 1 1 1 1 1 1 1V INPUT 1000 1001 1010 1011 1100 1101 1110 1111R 1ana a b c d z
此行去掉,改加在 run irsim 之後,見下頁
VLSI Design Course 2000
TRY IRSIMTRY IRSIM
#4 Try this .cmd file with IRSIMccsun> irsim tsmc08.prm or4.sim -or4.cmd#5 run analyze windowirsim> ana a b c d z#6 Analyzer window with simulation results will pop up.
VLSI Design Course 2000
SPICE – Transistor-level simulator SPICE – Transistor-level simulator for MOS circuitsfor MOS circuits
VLSI Design Course 2000
Magic to SpiceMagic to Spice
• Convert magic extracted files to spice net files ext2spice name.sp name.ext
VLSI Design Course 2000
SPICESPICE
*~~~~ .lib 'tsmc08.model' TT.op.option post captab.global vdd vss
VLSI Design Course 2000
SPICESPICE
** Circuit Description **Vin 1 0 DC +1.5VVDD vdd 0 DC +1.5VVSS vss 0 DC 0VM1 2 1 5 5 PCH L=1um W=1umM2 2 1 0 0 NCH L=1um W=1um* drain gate source substrate