Prerequisites:
You authored your circuit as both:
- an Electric schematic & icon (symbol): ~/design/YourProject/elec/yourLib.delib/yourCell.{sch,ic}
- a magic layout: ~/design/YourProject/mag/yourCell.mag
Such that:
- the Electric schematic cell-name matches the magic layout cell-name
- the Electric schematic Exports (pins) match the magic layout PORTS
and you:
- have an Electric test-bench schematic that ultimately places yourLib.delib/yourCell.ic
- used Electric’s toolbar buttons to Sim the test-bench and view waveform results
Goal:
- generate a post-layout RCX netlist (with parasitics) from the layout yourCell.mag
- Sim the test-bench using the post-layout RCX netlist in place of the schematic-based subckt.
Steps:
1. ensure you define PORTS (not just text labels) in your magic layout, that match the schematic.
2. save all if you have a running magic.
3. change dir to your project’s mag dir.
% cd ~/design/YourProject/mag
4. run batch RCX extract for spice on the layout:
% magic2spi -S yourCell >m2spi.yourCell.log
Visually inspect outputs in mag/ dir (the .log and the .SPI netlist):
yourCell.mag.SPI
m2spi.yourCell.log
WARNING: Especially VERIFY the log DOES NOT end with (if so return to step#1):
info: magic2spi: no top-cell .subckt found (normal if it had no top-level ports)
5. import the RCX netlist to the dir-structure standard supported by the rcx-switcher. You must specify three args: path to the raw RCX-netlist just generated, libName, cellName.
% rcximport yourCell.mag.SPI yourLib yourCell
6. to support comparison, save copies of your test-bench raw files (pre-layout results).
7. enable the Electric Sim button (simcorners) rcx-switch behavior:
% touch ~/design/YourProject/.ef-config/view-switch.cfg
This will one-day be a real config file. Today it’s just a blunt instrument to globally (per project) turn on or off all RCX switching. Delete the file to turn it off.
8. Hit Sim button in your electric test-bench. Near top of Sim log window you should see one or more “rcxswitch: …” including a status summary. View the new post-layout waveforms; compare to pre-layout waveforms.
Challenge example:
Say your layout is named: XBG_1V23LC_V01 and intent is to switch its RCX-netlist in place of the electric schematic: XBG_1V23LC_V01.delib/XBG_1V23LC_V01.sch,
then in step-4:
% magic2spi -S XBG_1V23LC_V01 >m2spi.XBG_1V23LC_V01.log
and in step-5:
% rcximport XBG_1V23LC_V01.mag.SPI XBG_1V23LC_V01 XBG_1V23LC_V01