Add pex video and reorganize PEX example
This commit is contained in:
parent
a8ccdd87e0
commit
4ec1a1c1d7
|
|
@ -189,8 +189,6 @@ value="
|
|||
"}
|
||||
C {devices/code_shown.sym} -865 -1040 0 0 {name=NGSPICE only_toplevel=false
|
||||
value="
|
||||
.include comparator_tb.save
|
||||
|
||||
.param temp=27
|
||||
.param clock = 100e6 ; 100 MHz clock
|
||||
.param period = \{1/clock\}
|
||||
|
|
@ -255,7 +253,6 @@ device="ceramic capacitor"}
|
|||
C {gnd.sym} 460 -140 0 0 {name=l6 lab=GND}
|
||||
C {gnd.sym} 460 -300 2 0 {name=l7 lab=GND}
|
||||
C {dynamic_comparator.sym} 270 -220 0 0 {name=x1}
|
||||
C {sg13g2_pr/annotate_fet_params.sym} -240 -1070 0 0 {name=annot1 ref=M3}
|
||||
C {devices/launcher.sym} -210 -810 0 0 {name=h1
|
||||
descr="OP annotate"
|
||||
tclcommand="xschem annotate_op"
|
||||
|
|
|
|||
Binary file not shown.
|
Before Width: | Height: | Size: 53 KiB |
Binary file not shown.
Binary file not shown.
|
|
@ -1,9 +0,0 @@
|
|||
* Extracted by KLayout with SG13G2 LVS runset on : 14/07/2025 15:44
|
||||
|
||||
.SUBCKT input_pair_cm vdd Drain2 Drain1 top
|
||||
M$1 top \$9 Drain1 \$2 sg13_lv_pmos L=0.2u W=32u AS=8.48p AD=8.48p PS=52.24u
|
||||
+ PD=52.24u
|
||||
M$3 top \$8 Drain2 \$2 sg13_lv_pmos L=0.2u W=32u AS=8.48p AD=8.48p PS=52.24u
|
||||
+ PD=52.24u
|
||||
R$17 \$2 vdd ntap1 A=15.376p P=99.2u
|
||||
.ENDS input_pair_cm
|
||||
|
|
@ -1,58 +0,0 @@
|
|||
v {xschem version=3.4.6 file_version=1.2}
|
||||
G {}
|
||||
K {}
|
||||
V {}
|
||||
S {}
|
||||
E {}
|
||||
N 490 -650 490 -600 {
|
||||
lab=top}
|
||||
N 810 -650 810 -600 {
|
||||
lab=top}
|
||||
N 810 -540 810 -470 {
|
||||
lab=Drain2}
|
||||
N 650 -650 810 -650 {
|
||||
lab=top}
|
||||
N 650 -710 650 -650 {
|
||||
lab=top}
|
||||
N 490 -650 650 -650 {
|
||||
lab=top}
|
||||
N 650 -570 810 -570 {
|
||||
lab=#net1}
|
||||
N 490 -540 490 -470 {
|
||||
lab=Drain1}
|
||||
N 440 -570 450 -570 {
|
||||
lab=v+}
|
||||
N 850 -570 860 -570 {
|
||||
lab=v-}
|
||||
N 650 -570 650 -550 {lab=#net1}
|
||||
N 490 -570 650 -570 {
|
||||
lab=#net1}
|
||||
N 650 -490 650 -470 {lab=vdd}
|
||||
C {ipin.sym} 440 -570 0 0 {name=p3 lab=v+}
|
||||
C {ipin.sym} 860 -570 0 1 {name=p4 lab=v-}
|
||||
C {sg13g2_pr/sg13_lv_pmos.sym} 470 -570 0 0 {name=M2
|
||||
l=200n
|
||||
w=8u
|
||||
ng=2
|
||||
m=4
|
||||
model=sg13_lv_pmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/sg13_lv_pmos.sym} 830 -570 0 1 {name=M1
|
||||
l=200n
|
||||
w=8u
|
||||
ng=2
|
||||
m=4
|
||||
model=sg13_lv_pmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/ntap1.sym} 650 -520 0 0 {name=R1
|
||||
model=ntap1
|
||||
spiceprefix=X
|
||||
w=0.78e-6
|
||||
l=0.78e-6
|
||||
}
|
||||
C {iopin.sym} 810 -470 0 0 {name=p7 lab=Drain2}
|
||||
C {iopin.sym} 490 -470 0 0 {name=p1 lab=Drain1}
|
||||
C {iopin.sym} 650 -470 0 0 {name=p2 lab=vdd}
|
||||
C {iopin.sym} 650 -710 0 0 {name=p5 lab=top}
|
||||
Binary file not shown.
|
|
@ -1,126 +0,0 @@
|
|||
v {xschem version=3.4.6 file_version=1.2}
|
||||
G {}
|
||||
K {}
|
||||
V {}
|
||||
S {}
|
||||
E {}
|
||||
N 720 -270 720 -230 {
|
||||
lab=Drain2}
|
||||
N 810 -270 900 -270 {
|
||||
lab=Drain2}
|
||||
N 900 -270 900 -230 {
|
||||
lab=Drain2}
|
||||
N 810 -470 810 -270 {
|
||||
lab=Drain2}
|
||||
N 720 -270 810 -270 {
|
||||
lab=Drain2}
|
||||
N 900 -170 900 -130 {
|
||||
lab=gnd}
|
||||
N 720 -170 720 -130 {
|
||||
lab=gnd}
|
||||
N 400 -270 400 -230 {
|
||||
lab=Drain1}
|
||||
N 490 -270 580 -270 {
|
||||
lab=Drain1}
|
||||
N 580 -270 580 -230 {
|
||||
lab=Drain1}
|
||||
N 400 -270 490 -270 {
|
||||
lab=Drain1}
|
||||
N 580 -170 580 -130 {
|
||||
lab=gnd}
|
||||
N 400 -170 400 -130 {
|
||||
lab=gnd}
|
||||
N 490 -470 490 -270 {
|
||||
lab=Drain1}
|
||||
N 580 -130 720 -130 {
|
||||
lab=gnd}
|
||||
N 900 -130 1060 -130 {
|
||||
lab=gnd}
|
||||
N 490 -470 680 -200 {
|
||||
lab=Drain1}
|
||||
N 620 -200 810 -470 {
|
||||
lab=Drain2}
|
||||
N 330 -200 360 -200 {
|
||||
lab=clk}
|
||||
N 810 -200 900 -200 {
|
||||
lab=well}
|
||||
N 720 -130 900 -130 {
|
||||
lab=gnd}
|
||||
N 490 -200 580 -200 {
|
||||
lab=well}
|
||||
N 400 -130 580 -130 {
|
||||
lab=gnd}
|
||||
N 940 -200 960 -200 {
|
||||
lab=clk}
|
||||
N 490 -200 490 -110 {lab=well}
|
||||
N 650 -110 810 -110 {lab=well}
|
||||
N 810 -200 810 -110 {lab=well}
|
||||
N 720 -200 810 -200 {
|
||||
lab=well}
|
||||
N 650 -30 650 -10 {lab=gnd}
|
||||
N 650 -110 650 -90 {lab=well}
|
||||
N 490 -110 650 -110 {lab=well}
|
||||
N 390 -200 490 -200 {lab=well}
|
||||
N 1190 -400 1190 -370 {lab=gnd}
|
||||
N 1190 -400 1230 -400 {lab=gnd}
|
||||
N 1230 -400 1230 -280 {lab=gnd}
|
||||
N 1190 -280 1230 -280 {lab=gnd}
|
||||
N 1190 -310 1190 -280 {lab=gnd}
|
||||
N 1140 -340 1190 -340 {lab=well}
|
||||
C {iopin.sym} 1060 -130 0 0 {name=p2 lab=gnd}
|
||||
C {ipin.sym} 330 -200 0 0 {name=p6 lab=clk}
|
||||
C {sg13g2_pr/sg13_lv_nmos.sym} 600 -200 0 1 {name=M6
|
||||
l=0.200u
|
||||
w=4.0u
|
||||
ng=1
|
||||
m=1
|
||||
model=sg13_lv_nmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/sg13_lv_nmos.sym} 380 -200 0 0 {name=M10
|
||||
l=0.200u
|
||||
w=4.0u
|
||||
ng=1
|
||||
m=1
|
||||
model=sg13_lv_nmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/sg13_lv_nmos.sym} 920 -200 0 1 {name=M7
|
||||
l=0.200u
|
||||
w=4.0u
|
||||
ng=1
|
||||
m=1
|
||||
model=sg13_lv_nmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/sg13_lv_nmos.sym} 700 -200 0 0 {name=M8
|
||||
l=0.200u
|
||||
w=4.0u
|
||||
ng=1
|
||||
m=1
|
||||
model=sg13_lv_nmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {lab_pin.sym} 960 -200 2 0 {name=p11 sig_type=std_logic lab=clk}
|
||||
C {iopin.sym} 490 -470 2 0 {name=p1 lab=Drain1}
|
||||
C {iopin.sym} 810 -470 0 0 {name=p7 lab=Drain2}
|
||||
C {sg13g2_pr/ptap1.sym} 650 -60 2 0 {name=R2
|
||||
model=ptap1
|
||||
spiceprefix=X
|
||||
w=0.78e-6
|
||||
l=0.78e-6
|
||||
}
|
||||
C {lab_pin.sym} 650 -10 2 0 {name=p3 sig_type=std_logic lab=gnd}
|
||||
C {lab_pin.sym} 810 -110 2 0 {name=p4 sig_type=std_logic lab=well}
|
||||
C {sg13g2_pr/sg13_lv_nmos.sym} 1210 -340 0 1 {name=M2
|
||||
l=0.200u
|
||||
w=4.0u
|
||||
ng=1
|
||||
m=4
|
||||
model=sg13_lv_nmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {lab_pin.sym} 1140 -340 0 0 {name=p8 sig_type=std_logic lab=well
|
||||
m=4}
|
||||
C {lab_pin.sym} 1190 -400 0 0 {name=p10 sig_type=std_logic lab=gnd
|
||||
m=4}
|
||||
|
|
@ -1,328 +0,0 @@
|
|||
# Parasitic Extraction (PEX)
|
||||
|
||||
Parasitic extraction is an important step in the analog design flow, kind of like EM simulation. After you finish the physical layout, this step analyzes how unintended parasitic resistances and capacitances affect your circuit’s behavior.
|
||||
|
||||
For this workflow, we use the kpex tool developed by [Martin Jan Köhler](https://github.com/martinjankoehler), which is open-source and integrates well with KLayout. You can find it here: [klayout-pex](https://github.com/martinjankoehler/klayout-pex). Big thanks to Martin for sharing this tool!
|
||||
|
||||
You can check out installation instructions directly on the repo or the official website: [official website](https://martinjankoehler.github.io/klayout-pex-website/).
|
||||
|
||||
## Basic Commands
|
||||
|
||||
Once installed, run:
|
||||
|
||||
```bash
|
||||
kpex --help
|
||||
```
|
||||
From this we see that we have lots of infomration we can specify to `kpex`. As it can be seen there is a lot of different configuration options depending on your use case, lets dive into this simple example:
|
||||
|
||||
```
|
||||
kpex \
|
||||
--pdk ihp_sg13g2 \
|
||||
--gds design.gds \
|
||||
--schematic design.spice \
|
||||
--cell top \
|
||||
--magic \
|
||||
--magic_mode RC \
|
||||
--out_dir output/
|
||||
```
|
||||
🔧 Explanation of each option:
|
||||
--pdk ihp_sg13g2
|
||||
Specifies the process design kit to use. In this case, the IHP SG13G2 PDK.
|
||||
|
||||
--gds design.gds
|
||||
Path to the GDS layout file for the design.
|
||||
|
||||
--schematic design.spice
|
||||
Path to the SPICE netlist of the schematic used for LVS comparison.
|
||||
|
||||
--cell top
|
||||
Specifies the top-level cell name in the GDS file to extract parasitics from.
|
||||
|
||||
--magic
|
||||
Tells kpex to use Magic’s parasitic extraction engine (alternatives: `--fastercap`, `--2.5D`, `--fastcap`).
|
||||
|
||||
--magic_mode RC
|
||||
Specifies the extraction mode used by Magic. Can be:
|
||||
- `CC` – extract only capacitances
|
||||
- `RC` – extract resistances and capacitances (default)
|
||||
- `R` – extract only resistances
|
||||
|
||||
--mode RC
|
||||
If using `--2.5D` instead of `--magic`, use `--mode` to specify the extraction mode. Same options apply: `CC`, `RC`, or `R`.
|
||||
|
||||
--out_dir output/
|
||||
Output directory where results (LVS database, parasitic netlist, logs) will be saved.
|
||||
|
||||
|
||||
This can simply be tried out with a gds file to confirm everthing is working
|
||||
|
||||
## What will it create?
|
||||
Taking a very basic inverter example we will start by viewing the netlist from xschem seen here
|
||||
|
||||
```
|
||||
.SUBCKT inverter Vdd Vin Vout Gnd
|
||||
*.PININFO Vout:B Vdd:B Vin:B Gnd:B
|
||||
M1 Gnd Vin Vout net2 sg13_lv_nmos w=1.0u l=0.45u ng=1 m=1
|
||||
M2 Vout Vin Vdd net1 sg13_lv_pmos w=2.0u l=0.45u ng=1 m=1
|
||||
R1 Vdd net1 ntap1 A=6.084e-13 P=3.12e-06
|
||||
R2 Gnd net2 ptap1 A=6.084e-13 P=3.12e-06
|
||||
.ENDS
|
||||
|
||||
```
|
||||
|
||||
as it can be seen its a very simple netlist with two transistors and tap devices. We have the parameters describing the instace parameters and thats it. Using the flow explained above a simple GDS layout has been made and can be seen below:
|
||||
|
||||
<p align="center">
|
||||
<img src="../.media/inverter_layout.png" width="400" height="450" />
|
||||
</p>
|
||||
|
||||
|
||||
for this layout a simple shell script has been made in order to execute the kpex. This i seen below
|
||||
|
||||
```
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
# Hardcoded paths (except PDK stuff)
|
||||
PYTHON_ENV="/home/pedersen/misc/klayout_pex/bin/activate"
|
||||
KPEX_MAGIC_EXE="/home/pedersen/.local/bin/magic"
|
||||
LAYOUT_PATH="../layout/inverter.gds"
|
||||
SCHEMATIC="../simulations/inverter.spice"
|
||||
|
||||
|
||||
PDK_NAME="ihp_sg13g2"
|
||||
MAGICRC="$PDK_ROOT/$PDK_NAME/libs.tech/magic/ihp-sg13g2.magicrc"
|
||||
|
||||
# Activate Python environment
|
||||
source "$PYTHON_ENV"
|
||||
|
||||
# Run parasitic extraction with kpex
|
||||
kpex \
|
||||
--pdk "$PDK_NAME" \
|
||||
--magic \
|
||||
--schematic "$SCHEMATIC" \
|
||||
--gds "$LAYOUT_PATH" \
|
||||
--magicrc "$MAGICRC" \
|
||||
--magic_mode RC \
|
||||
--magic_cthresh 0.02 \
|
||||
--magic_rthresh 50 \
|
||||
--magic_short resistor \
|
||||
--magic_merge conservative \
|
||||
--out_dir /.pex_output
|
||||
```
|
||||
|
||||
### Script Explanation
|
||||
|
||||
This bash script automates parasitic extraction using **kpex** with the IHP SG13G2 PDK. Here's what each part does:
|
||||
|
||||
- `set -e`
|
||||
Ensures the script exits immediately if any command fails, preventing cascading errors.
|
||||
|
||||
- **paths:**
|
||||
- `PYTHON_ENV`: Path to the Python virtual environment of klayout-pex (optional depending on your setup).
|
||||
- `KPEX_MAGIC_EXE`: Path to the Magic engine executable.
|
||||
- `LAYOUT_PATH`: Relative path to the layout GDS file to extract parasitics from.
|
||||
- `SCHEMATIC`: Relative path to the SPICE netlist schematic used for LVS and parasitic extraction (Top level must be a subcircuit! to be compatible with costum python script later! Refer to LVS guide in klayout)
|
||||
|
||||
- `PDK_NAME` and `MAGICRC`:
|
||||
- `PDK_NAME` specifies the Process Design Kit to use (`ihp_sg13g2`).
|
||||
- `MAGICRC` points to the Magic configuration file for the PDK
|
||||
(this should be already setup if you followed installation of the IHP open PDK)
|
||||
|
||||
- `source "$PYTHON_ENV"`:
|
||||
Activates the Python environment so the `kpex` command and dependencies run properly.
|
||||
|
||||
- The `kpex` command runs parasitic extraction with these options:
|
||||
- `--pdk`: Selects the PDK.
|
||||
- `--magic`: Uses Magic’s extraction engine.
|
||||
- `--schematic`: Specifies the schematic netlist for LVS comparison and annotation.
|
||||
- `--gds`: Layout file to extract from.
|
||||
- `--magicrc`: PDK-specific Magic configuration file.
|
||||
- `--magic_mode RC`: Extraction mode producing both resistive and capacitive parasitics.
|
||||
- `--magic_cthresh 0.02`: Capacitance extraction threshold (farads).
|
||||
- `--magic_rthresh 50`: Resistance extraction threshold (ohms).
|
||||
- `--magic_short resistor`: Method to handle shorts using resistors.
|
||||
- `--magic_merge conservative`: Merging style to combine parasitics cautiously.
|
||||
- `--out_dir ./pex_output`: Directory where extraction results (parasitic netlists, logs) are saved.
|
||||
|
||||
---
|
||||
|
||||
Once the script has been run, a log is printed and a folder is generated containing the results:
|
||||
|
||||
```
|
||||
.
|
||||
└── inverter__inverter
|
||||
├── inverter_dummy_schematic.spice
|
||||
├── kpex.log
|
||||
├── kpex_plain.log
|
||||
└── magic_RC
|
||||
├── inverter.ext
|
||||
├── inverter_MAGIC_RC_Output.txt
|
||||
├── inverter_MAGIC_RC_Script.tcl
|
||||
├── inverter_MAGIC_report.rdb.gz
|
||||
├── inverter.pex.spice
|
||||
└── inverter.res.ext
|
||||
```
|
||||
|
||||
Among the outputs, the important file is `inverter.pex.spice`, shown below:
|
||||
|
||||
```
|
||||
* NGSPICE file created from inverter.ext - technology: ihp-sg13g2
|
||||
|
||||
.subckt inverter_pex Vdd Vin Vout Gnd
|
||||
X0 Vout Vin Vdd Vdd sg13_lv_pmos ad=0.68p pd=4.68u as=0.68p ps=4.68u w=2u l=0.45u
|
||||
X1 Vout Vin Gnd Gnd sg13_lv_nmos ad=0.34p pd=2.68u as=0.34p ps=2.68u w=1u l=0.45u
|
||||
C0 Vout Vin 0.10077f
|
||||
C1 Vin Vdd 0.14482f
|
||||
C2 Vout Vdd 0.13155f
|
||||
R0 Vin Vin.n0 7.52248
|
||||
C3 Vout Gnd 0.39245f
|
||||
C4 Vin Gnd 0.64666f
|
||||
C5 Vdd Gnd 0.15308f
|
||||
.ends
|
||||
```
|
||||
|
||||
As can be seen, it's the same netlist structure as shown earlier but now with parasitics inserted.
|
||||
|
||||
- The `X0` and `X1` instances are the original PMOS and NMOS devices with additional layout-calculated source/drain diffusion areas (`ad`, `as`) and perimeters (`pd`, `ps`).
|
||||
- The `C0–C5` elements are **extracted parasitic capacitances** between the nodes in the layout.
|
||||
- The `R0` entry is a **resistive parasitic**, representing resistance in the interconnect or diffusion.
|
||||
|
||||
These parasitics are important for accurate simulation of timing and analog performance, especially in high-speed or precision circuits.
|
||||
|
||||
## Integration in Xschem/Ngspice (post-layout simulation)
|
||||
|
||||
To simulate the extracted device, several approaches exist. In this example, we’ll keep the entire flow inside Xschem, using Ngspice as the simulator.
|
||||
|
||||
Before continuing, please watch the following video by Stefan Schippers (creator of Xschem):
|
||||
https://www.youtube.com/watch?v=zs6JPXk074c&t=495s
|
||||
|
||||
### Improved Shell Script
|
||||
|
||||
As seen in the video, it’s possible to insert a netlist directly into a schematic using a symbol. Imagine a case where you’ve already generated a symbol for a design to use in a testbench — now, you can use that *same* symbol to simulate the extracted version with parasitics included.
|
||||
|
||||
To enable this, a shell script has been created:
|
||||
`IHP-AnalogAcademy/modules/module_3_8_bit_SAR_ADC/part_5_layout/comparator/pex/run_kpex.sh`
|
||||
Relevant parts of this script are shown below.
|
||||
|
||||
**Snippet 1** – User configuration:
|
||||
```
|
||||
###############################################################################
|
||||
# ⬇⬇⬇ USER CONFIGURATION ⬇⬇⬇ #
|
||||
###############################################################################
|
||||
|
||||
# Activate Python environment (adjust this path to your Python venv activate script) Or if you python version is >3.12 ignore asuming klayout_pex is installed
|
||||
PYTHON_ENV="$HOME/misc/klayout_pex/bin/activate"
|
||||
# Example: /home/username/misc/klayout_pex/bin/activate
|
||||
|
||||
# Path to Magic executable used by kpex (adjust if installed elsewhere)
|
||||
KPEX_MAGIC_EXE="$HOME/.local/bin/magic"
|
||||
# Example: /usr/local/bin/magic or ~/.local/bin/magic
|
||||
|
||||
#Path to symbol
|
||||
SYM_DIR="../xschem_pre_layout/schematic/DIFF_COMPARATOR.sym" # Asuming you have a symbol for the DUT
|
||||
|
||||
LAYOUT_DIR="../layout/DIFF_COMPARATOR.gds" # Path to the GDS file
|
||||
|
||||
# Important: Path to your PDK root directory must be set externally in env variable PDK_ROOT, otherwise give absolute path
|
||||
PDK_NAME="ihp_sg13g2" # Your PDK name (must match PDK_ROOT contents)
|
||||
MAGICRC="$PDK_ROOT/$PDK/libs.tech/magic/ihp-sg13g2.magicrc" # The magicrc file for your PDK, used during extraction
|
||||
|
||||
SCHEMATIC="../layout/lvs_netlist/DIFF_COMPARATOR.spice" # Spicefile of the comparator from Schematic or LVS (Used for pex to perform LVS and script to organize IO)
|
||||
```
|
||||
|
||||
|
||||
As seen above, a new variable has been added for the symbol. In this case, it points to the symbol used earlier for the comparator (from part_1) now copied to this directory. After that, the script runs `kpex`, just like we did for the inverter.
|
||||
|
||||
The new logic comes in the next step.
|
||||
|
||||
**Snippet 2** – Matching pin order and generating the new symbol:
|
||||
|
||||
```
|
||||
# Find the generated spice file (assuming only one)
|
||||
spice_location=$(find ./pex_output -type f -name "*.spice" ! -name "*_dummy_schematic.spice" | head -n 1)
|
||||
|
||||
|
||||
if [[ -z "$spice_location" ]]; then
|
||||
echo "[ERROR] No .spice file found in pex_output directory"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "[INFO] Found extracted spice file: $spice_location"
|
||||
|
||||
# Run Python script to fix port ordering in the extracted netlist
|
||||
echo "[INFO] Reordering subcircuit pins to match original schematic..."
|
||||
echo "$spice_location"
|
||||
echo "$SCHEMATIC"
|
||||
|
||||
python3 python/match_subckt_order.py "$spice_location" "$SCHEMATIC"
|
||||
|
||||
|
||||
|
||||
echo "[INFO] Creating DUT symbol with pex netlist"
|
||||
python3 python/insert_netlist_to_sym.py "$spice_location" "$SYM_DIR" xschem_pex_symbol
|
||||
```
|
||||
After running `kpex`, the script looks for the generated PEX netlist and stores the path in the variable `spice_location`. It then calls a Python script `match_subckt_order.py` to fix the pin ordering.
|
||||
|
||||
This step is important: the `.subckt` line in the netlist determines the pin order used for simulation, and when its generated in xschem the pin order will be the same for the symbol (which we will use for simulation). If the pin order of the PEX netlist doesn’t match the original netlist from xschem (also used for the symbol), simulation will give false results!
|
||||
|
||||
Let’s look at an example:
|
||||
|
||||
Original schematic netlist (used in LVS):
|
||||
|
||||
for the inverter netlist, this is what it looks like when extracted (Top level is a subcircuit i.e LVS netlist in xschem)
|
||||
```
|
||||
.SUBCKT inverter Vdd Vin Vout Gnd
|
||||
*.PININFO Vout:B Vdd:B Vin:B Gnd:B
|
||||
M1 Gnd Vin Vout net2 sg13_lv_nmos w=1.0u l=0.45u ng=1 m=1
|
||||
M2 Vout Vin Vdd net1 sg13_lv_pmos w=2.0u l=0.45u ng=1 m=1
|
||||
R1 Vdd net1 ntap1 A=6.084e-13 P=3.12e-06
|
||||
R2 Gnd net2 ptap1 A=6.084e-13 P=3.12e-06
|
||||
.ENDS
|
||||
|
||||
```
|
||||
the direct output from PEX will give:
|
||||
|
||||
```
|
||||
* NGSPICE file created from inverter.ext - technology: ihp-sg13g2
|
||||
|
||||
.subckt inverter Vout Vin Gnd Vdd
|
||||
X0 Vout Vin Vdd Vdd sg13_lv_pmos ad=0.68p pd=4.68u as=0.68p ps=4.68u w=2u l=0.45u
|
||||
X1 Vout Vin Gnd Gnd sg13_lv_nmos ad=0.34p pd=2.68u as=0.34p ps=2.68u w=1u l=0.45u
|
||||
C0 Vout Vdd 0.13155f
|
||||
C1 Vout Vin 0.10077f
|
||||
C2 Vin Vdd 0.14482f
|
||||
R0 Vin Vin.n0 7.52248
|
||||
C3 Vout Gnd 0.39245f
|
||||
C4 Vin Gnd 0.64666f
|
||||
C5 Vdd Gnd 0.15308f
|
||||
.ends
|
||||
```
|
||||
Notice the difference in the `.subckt` pin order? That’s why we use the matching script.
|
||||
|
||||
The script is located at:
|
||||
`IHP-AnalogAcademy/modules/module_3_8_bit_SAR_ADC/part_5_layout/comparator/pex/python/match_subckt_order.py`
|
||||
|
||||
Finally, a second script is called to generate a new symbol containing the reordered PEX netlist:
|
||||
`IHP-AnalogAcademy/modules/module_3_8_bit_SAR_ADC/part_5_layout/comparator/pex/python/insert_netlist_to_sym.py`
|
||||
|
||||
This creates a symbol placed in:
|
||||
`xschem_pex_symbol/`
|
||||
You can now use this symbol directly in your testbench to simulate the impact of parasitics.
|
||||
|
||||
|
||||
## Usage in Part_5
|
||||
|
||||
In part_5, you’ll find a folder called `comparator`. Key folders inside are:
|
||||
|
||||
- `layout/`: contains the comparator layout
|
||||
- `pex/`: contains the `run_pex.sh` script, Python helpers, and extraction output
|
||||
- `pex_output/`: holds the PEX netlist after extraction
|
||||
- `xschem_pex_symbol/`: contains the generated symbol with the PEX netlist
|
||||
- `xschem_post_layout/`: a copy of the part_1 testbenches, but updated to use the PEX symbol
|
||||
|
||||
## Youtube Video
|
||||
|
||||
To see this flow in action, please refer to the accompanying video:
|
||||
|
||||
|
||||
|
|
@ -1,39 +0,0 @@
|
|||
v {xschem version=3.4.5 file_version=1.2
|
||||
}
|
||||
G {}
|
||||
K {type=subcircuit
|
||||
format="@name @pinlist @symname"
|
||||
template="name=x1"
|
||||
}
|
||||
V {}
|
||||
S {}
|
||||
E {}
|
||||
L 4 -130 -100 130 0 {}
|
||||
L 4 -130 100 130 0 {}
|
||||
L 4 -130 -100 -130 100 {}
|
||||
L 4 -150 0 -130 0 {}
|
||||
L 4 -150 -60 -130 -60 {}
|
||||
L 4 -150 60 -130 60 {}
|
||||
L 4 110 10 130 10 {}
|
||||
L 4 110 -10 130 -10 {}
|
||||
L 4 -20 60 -20 80 {}
|
||||
L 7 -70 -100 -70 -80 {}
|
||||
L 7 -70 80 -70 100 {}
|
||||
B 5 -72.5 -102.5 -67.5 -97.5 {name=vdd dir=inout}
|
||||
B 5 -152.5 -2.5 -147.5 2.5 {name=vbias dir=in}
|
||||
B 5 -152.5 -62.5 -147.5 -57.5 {name=v+ dir=in}
|
||||
B 5 -152.5 57.5 -147.5 62.5 {name=v- dir=in}
|
||||
B 5 127.5 7.5 132.5 12.5 {name=out- dir=out}
|
||||
B 5 127.5 -12.5 132.5 -7.5 {name=out+ dir=out}
|
||||
B 5 -22.5 77.5 -17.5 82.5 {name=clk dir=in}
|
||||
B 5 -72.5 97.5 -67.5 102.5 {name=gnd dir=inout}
|
||||
T {@symname} -89 -6 0 0 0.3 0.3 {}
|
||||
T {@name} 25 -52 0 0 0.2 0.2 {}
|
||||
T {vdd} -74 -75 3 1 0.2 0.2 {}
|
||||
T {vbias} -125 -4 0 0 0.2 0.2 {}
|
||||
T {v+} -125 -64 0 0 0.2 0.2 {}
|
||||
T {v-} -125 56 0 0 0.2 0.2 {}
|
||||
T {out-} 90 1 0 1 0.2 0.2 {}
|
||||
T {out+} 95 -14 0 1 0.2 0.2 {}
|
||||
T {clk} -24 55 3 0 0.2 0.2 {}
|
||||
T {gnd} -66 75 1 1 0.2 0.2 {}
|
||||
|
|
@ -1,124 +0,0 @@
|
|||
timestamp 0
|
||||
version 8.3
|
||||
tech ihp-sg13g2
|
||||
style ngspice()
|
||||
scale 1000 1 0.5
|
||||
resistclasses 3000000 67000 110 88 88 88 88 18 11
|
||||
parameters sg13_lv_nmos l=l w=w a1=as p1=ps a2=ad p2=pd
|
||||
parameters sg13_lv_pmos l=l w=w a1=as p1=ps a2=ad p2=pd
|
||||
port "vbias" 4 2148 -579 2236 -495 m3
|
||||
port "clk" 8 1620 -950 1654 -915 m2
|
||||
port "out+" 7 6037 2710 6063 2738 m2
|
||||
port "out-" 6 -1819 2721 -1793 2749 m2
|
||||
port "V+" 2 979 6959 1061 7055 m3
|
||||
port "V-" 3 3313 6717 3395 6813 m3
|
||||
port "vdd" 10 127 335 275 572 m6
|
||||
port "gnd" 9 -513 -440 -293 -73 m7
|
||||
node "vbias" 7 2834.31 2148 -579 m3 0 0 0 0 54512 3184 61712 2244 605098 3622 0 0 0 0 0 0 0 0
|
||||
node "a_1752_817#" 16 442.661 1752 817 pdif 0 0 0 0 315568 9996 275888 7644 509688 8744 0 0 0 0 0 0 0 0
|
||||
node "clk" 14 7896.06 1620 -950 m2 0 0 0 0 853640 15708 236152 8628 0 0 0 0 0 0 0 0 0 0
|
||||
node "out+" 5 2361.94 6037 2710 m2 0 0 0 0 291396 5776 930084 9364 0 0 0 0 0 0 0 0 0 0
|
||||
node "out-" 5 2358.75 -1819 2721 m2 0 0 0 0 291396 5776 930084 9364 0 0 0 0 0 0 0 0 0 0
|
||||
node "a_944_1911#" 25 4286.17 944 1911 p 0 0 0 0 213640 9556 229760 8018 848474 15962 269080 4124 0 0 0 0 0 0
|
||||
node "V+" 10 3912.6 979 6959 m3 0 0 0 0 335280 7822 56404 2350 515268 8328 0 0 0 0 0 0 0 0
|
||||
node "a_687_2445#" 24 4012.69 687 2445 p 0 0 0 0 213640 9556 490160 11738 848614 15964 0 0 0 0 0 0 0 0
|
||||
node "V-" 10 3931.19 3313 6717 m3 0 0 0 0 312654 7152 96568 3908 523040 8334 0 0 0 0 0 0 0 0
|
||||
node "a_1245_3300#" 64 1432.03 1245 3300 pdif 0 0 0 0 646952 33468 462832 13040 1797472 26104 193480 3044 0 0 0 0 0 0
|
||||
node "w_805_2869#" 1242572 5.18828 805 2869 pw 182658 17438 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
|
||||
node "vdd" 58 17973.9 127 335 m6 0 0 0 0 2395440 52908 883744 19072 642880 13104 642880 13104 1340864 17360 6062752 36968 0 0
|
||||
substrate "gnd" 0 0 -513 -440 m7 0 0 0 0 2036008 30746 224000 4320 224000 4320 224000 4320 654400 6472 1331200 8256 9608000 48040
|
||||
cap "a_1245_3300#" "vdd" 2550.93
|
||||
cap "V+" "a_1245_3300#" 765.727
|
||||
cap "clk" "out-" 17.6324
|
||||
cap "a_1752_817#" "vdd" 7111.46
|
||||
cap "a_944_1911#" "vbias" 3.01856
|
||||
cap "clk" "a_687_2445#" 238.332
|
||||
cap "w_805_2869#" "out+" 7.86123
|
||||
cap "out-" "vbias" 0.0904886
|
||||
cap "a_1245_3300#" "a_944_1911#" 8045.22
|
||||
cap "a_944_1911#" "a_1752_817#" 55.7997
|
||||
cap "a_687_2445#" "vbias" 4.05638
|
||||
cap "V-" "a_1245_3300#" 941.789
|
||||
cap "a_1245_3300#" "out-" 367.947
|
||||
cap "out+" "vdd" 1847.73
|
||||
cap "V+" "out+" 3.75851
|
||||
cap "w_805_2869#" "vdd" 153.703
|
||||
cap "w_805_2869#" "V+" 10.369
|
||||
cap "a_1245_3300#" "a_687_2445#" 11353.4
|
||||
cap "a_687_2445#" "a_1752_817#" 45.3073
|
||||
cap "a_944_1911#" "out+" 800.279
|
||||
cap "w_805_2869#" "a_944_1911#" 4.42903
|
||||
cap "V+" "vdd" 4082.05
|
||||
cap "clk" "vbias" 198.783
|
||||
cap "V-" "out+" 9.67399
|
||||
cap "w_805_2869#" "V-" 10.604
|
||||
cap "out+" "out-" 93.2996
|
||||
cap "w_805_2869#" "out-" 7.86123
|
||||
cap "a_1245_3300#" "clk" 447.822
|
||||
cap "clk" "a_1752_817#" 502.499
|
||||
cap "a_944_1911#" "vdd" 1108.62
|
||||
cap "a_687_2445#" "out+" 692.864
|
||||
cap "V+" "a_944_1911#" 1081.78
|
||||
cap "w_805_2869#" "a_687_2445#" 3.06666
|
||||
cap "V-" "vdd" 4061.21
|
||||
cap "V+" "V-" 1610.45
|
||||
cap "a_1245_3300#" "vbias" 2.78546
|
||||
cap "out-" "vdd" 1843.04
|
||||
cap "V+" "out-" 7.34235
|
||||
cap "a_1752_817#" "vbias" 2289.93
|
||||
cap "a_687_2445#" "vdd" 1311.56
|
||||
cap "V+" "a_687_2445#" 130.255
|
||||
cap "V-" "a_944_1911#" 469.011
|
||||
cap "a_1245_3300#" "a_1752_817#" 3765.33
|
||||
cap "clk" "out+" 16.9002
|
||||
cap "a_944_1911#" "out-" 611.611
|
||||
cap "a_687_2445#" "a_944_1911#" 2249.36
|
||||
cap "V-" "out-" 3.46102
|
||||
cap "out+" "vbias" 0.0904886
|
||||
cap "V-" "a_687_2445#" 785.268
|
||||
cap "clk" "vdd" 2988.42
|
||||
cap "a_687_2445#" "out-" 894.529
|
||||
cap "a_1245_3300#" "out+" 369.238
|
||||
cap "w_805_2869#" "a_1245_3300#" 12.1813
|
||||
cap "vdd" "vbias" 2839.64
|
||||
cap "clk" "a_944_1911#" 247.428
|
||||
device msubckt sg13_lv_nmos 3710 1075 3711 1076 l=40 w=800 "gnd" "gnd" 80 0 "gnd" 0 0 "gnd" 1600 30400,876
|
||||
device msubckt sg13_lv_nmos 3594 1075 3595 1076 l=40 w=800 "gnd" "clk" 80 0 "a_944_1911#" 800 57600,944 "gnd" 800 30400,876
|
||||
device msubckt sg13_lv_nmos 3410 1075 3411 1076 l=40 w=800 "gnd" "a_687_2445#" 80 0 "gnd" 800 30400,876 "a_944_1911#" 800 57600,944
|
||||
device msubckt sg13_lv_nmos 3294 1075 3295 1076 l=40 w=800 "gnd" "gnd" 80 0 "gnd" 0 0 "gnd" 1600 54400,1736
|
||||
device msubckt sg13_lv_pmos 1752 885 1753 886 l=60 w=900 "vdd" "vbias" 120 0 "a_1752_817#" 900 61200,1936 "vdd" 900 34200,976
|
||||
device msubckt sg13_lv_pmos 1752 1021 1753 1022 l=60 w=900 "vdd" "vbias" 120 0 "vdd" 900 34200,976 "a_1752_817#" 900 34200,976
|
||||
device msubckt sg13_lv_pmos 1752 1157 1753 1158 l=60 w=900 "vdd" "vbias" 120 0 "a_1752_817#" 900 34200,976 "vdd" 900 34200,976
|
||||
device msubckt sg13_lv_pmos 1752 1293 1753 1294 l=60 w=900 "vdd" "vbias" 120 0 "vdd" 900 34200,976 "a_1752_817#" 900 61200,1936
|
||||
device msubckt sg13_lv_pmos 1752 1623 1753 1624 l=60 w=900 "vdd" "clk" 120 0 "a_1245_3300#" 900 61200,1936 "a_1752_817#" 900 34200,976
|
||||
device msubckt sg13_lv_pmos 1752 1759 1753 1760 l=60 w=900 "vdd" "clk" 120 0 "a_1752_817#" 900 34200,976 "a_1245_3300#" 900 34200,976
|
||||
device msubckt sg13_lv_pmos 1752 1895 1753 1896 l=60 w=900 "vdd" "clk" 120 0 "a_1245_3300#" 900 34200,976 "a_1752_817#" 900 34200,976
|
||||
device msubckt sg13_lv_pmos 1752 2031 1753 2032 l=60 w=900 "vdd" "clk" 120 0 "a_1752_817#" 900 34200,976 "a_1245_3300#" 900 61200,1936
|
||||
device msubckt sg13_lv_nmos 1070 1075 1071 1076 l=40 w=800 "gnd" "gnd" 80 0 "gnd" 0 0 "gnd" 1600 30400,876
|
||||
device msubckt sg13_lv_nmos 954 1075 955 1076 l=40 w=800 "gnd" "a_944_1911#" 80 0 "a_687_2445#" 800 57600,944 "gnd" 800 30400,876
|
||||
device msubckt sg13_lv_nmos 770 1075 771 1076 l=40 w=800 "gnd" "clk" 80 0 "gnd" 800 30400,876 "a_687_2445#" 800 57600,944
|
||||
device msubckt sg13_lv_nmos 654 1075 655 1076 l=40 w=800 "gnd" "gnd" 80 0 "gnd" 0 0 "gnd" 1600 54400,1736
|
||||
device msubckt sg13_lv_nmos 3281 2445 3282 2446 l=40 w=400 "gnd" "a_944_1911#" 80 0 "out+" 400 27200,936 "gnd" 400 15200,476
|
||||
device msubckt sg13_lv_pmos 2309 2445 2310 2446 l=40 w=800 "vdd" "a_944_1911#" 80 0 "out+" 800 54400,1736 "vdd" 800 30400,876
|
||||
device msubckt sg13_lv_pmos 1295 2445 1296 2446 l=40 w=800 "vdd" "a_687_2445#" 80 0 "out-" 800 54400,1736 "vdd" 800 30400,876
|
||||
device msubckt sg13_lv_nmos 3281 2561 3282 2562 l=40 w=400 "gnd" "a_944_1911#" 80 0 "gnd" 400 15200,476 "out+" 400 27200,936
|
||||
device msubckt sg13_lv_nmos 723 2445 724 2446 l=40 w=400 "gnd" "a_687_2445#" 80 0 "out-" 400 27200,936 "gnd" 400 15200,476
|
||||
device msubckt sg13_lv_pmos 2309 2561 2310 2562 l=40 w=800 "vdd" "a_944_1911#" 80 0 "vdd" 800 30400,876 "out+" 800 54400,1736
|
||||
device msubckt sg13_lv_pmos 1295 2561 1296 2562 l=40 w=800 "vdd" "a_687_2445#" 80 0 "vdd" 800 30400,876 "out-" 800 54400,1736
|
||||
device msubckt sg13_lv_nmos 723 2561 724 2562 l=40 w=400 "gnd" "a_687_2445#" 80 0 "gnd" 400 15200,476 "out-" 400 27200,936
|
||||
device msubckt sg13_lv_pmos 2357 3367 2358 3368 l=40 w=800 "vdd" "V-" 80 0 "a_1245_3300#" 800 54400,1736 "a_687_2445#" 800 30400,876
|
||||
device msubckt sg13_lv_pmos 2357 3483 2358 3484 l=40 w=800 "vdd" "V-" 80 0 "a_687_2445#" 800 30400,876 "a_1245_3300#" 800 54400,1736
|
||||
device msubckt sg13_lv_pmos 1245 3368 1246 3369 l=40 w=800 "vdd" "V+" 80 0 "a_1245_3300#" 800 54400,1736 "a_944_1911#" 800 30400,876
|
||||
device msubckt sg13_lv_pmos 1245 3484 1246 3485 l=40 w=800 "vdd" "V+" 80 0 "a_944_1911#" 800 30400,876 "a_1245_3300#" 800 54400,1736
|
||||
device msubckt sg13_lv_pmos 2357 3838 2358 3839 l=40 w=800 "vdd" "V+" 80 0 "a_1245_3300#" 800 54400,1736 "a_944_1911#" 800 30400,876
|
||||
device msubckt sg13_lv_pmos 2357 3954 2358 3955 l=40 w=800 "vdd" "V+" 80 0 "a_944_1911#" 800 30400,876 "a_1245_3300#" 800 54400,1736
|
||||
device msubckt sg13_lv_pmos 1245 3839 1246 3840 l=40 w=800 "vdd" "V-" 80 0 "a_1245_3300#" 800 54400,1736 "a_687_2445#" 800 30400,876
|
||||
device msubckt sg13_lv_pmos 1245 3955 1246 3956 l=40 w=800 "vdd" "V-" 80 0 "a_687_2445#" 800 30400,876 "a_1245_3300#" 800 54400,1736
|
||||
device msubckt sg13_lv_pmos 2357 4309 2358 4310 l=40 w=800 "vdd" "V-" 80 0 "a_1245_3300#" 800 54400,1736 "a_687_2445#" 800 30400,876
|
||||
device msubckt sg13_lv_pmos 2357 4425 2358 4426 l=40 w=800 "vdd" "V-" 80 0 "a_687_2445#" 800 30400,876 "a_1245_3300#" 800 54400,1736
|
||||
device msubckt sg13_lv_pmos 1245 4310 1246 4311 l=40 w=800 "vdd" "V+" 80 0 "a_1245_3300#" 800 54400,1736 "a_944_1911#" 800 30400,876
|
||||
device msubckt sg13_lv_pmos 1245 4426 1246 4427 l=40 w=800 "vdd" "V+" 80 0 "a_944_1911#" 800 30400,876 "a_1245_3300#" 800 54400,1736
|
||||
device msubckt sg13_lv_pmos 2357 4780 2358 4781 l=40 w=800 "vdd" "V+" 80 0 "a_1245_3300#" 800 54400,1736 "a_944_1911#" 800 30400,876
|
||||
device msubckt sg13_lv_pmos 2357 4896 2358 4897 l=40 w=800 "vdd" "V+" 80 0 "a_944_1911#" 800 30400,876 "a_1245_3300#" 800 54400,1736
|
||||
device msubckt sg13_lv_pmos 1245 4781 1246 4782 l=40 w=800 "vdd" "V-" 80 0 "a_1245_3300#" 800 54400,1736 "a_687_2445#" 800 30400,876
|
||||
device msubckt sg13_lv_pmos 1245 4897 1246 4898 l=40 w=800 "vdd" "V-" 80 0 "a_687_2445#" 800 30400,876 "a_1245_3300#" 800 54400,1736
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,27 +0,0 @@
|
|||
# Generated by kpex 0.2.7
|
||||
crashbackups stop
|
||||
drc off
|
||||
gds read /home/pedersen/projects/IHP-AnalogAcademy/modules/module_3_8_bit_SAR_ADC/part_5_layout/comparator/layout/DIFF_COMPARATOR.gds
|
||||
load DIFF_COMPARATOR
|
||||
select top cell
|
||||
flatten DIFF_COMPARATOR_flat
|
||||
load DIFF_COMPARATOR_flat
|
||||
cellname delete DIFF_COMPARATOR -noprompt
|
||||
cellname rename DIFF_COMPARATOR_flat DIFF_COMPARATOR
|
||||
select top cell
|
||||
extract path /home/pedersen/projects/IHP-AnalogAcademy/modules/module_3_8_bit_SAR_ADC/part_5_layout/comparator/pex/pex_output/DIFF_COMPARATOR__DIFF_COMPARATOR/magic_RC
|
||||
extract do resistance
|
||||
extract all
|
||||
ext2sim labels on
|
||||
ext2sim
|
||||
extresist tolerance 1
|
||||
extresist all
|
||||
ext2spice short resistor
|
||||
ext2spice merge conservative
|
||||
ext2spice cthresh 0.02
|
||||
ext2spice rthresh 50
|
||||
ext2spice extresist on
|
||||
ext2spice subcircuits top on
|
||||
ext2spice format ngspice
|
||||
ext2spice -p /home/pedersen/projects/IHP-AnalogAcademy/modules/module_3_8_bit_SAR_ADC/part_5_layout/comparator/pex/pex_output/DIFF_COMPARATOR__DIFF_COMPARATOR/magic_RC -o /home/pedersen/projects/IHP-AnalogAcademy/modules/module_3_8_bit_SAR_ADC/part_5_layout/comparator/pex/pex_output/DIFF_COMPARATOR__DIFF_COMPARATOR/magic_RC/DIFF_COMPARATOR.pex.spice
|
||||
quit -noprompt
|
||||
Binary file not shown.
|
|
@ -1,74 +0,0 @@
|
|||
import sys
|
||||
import os
|
||||
|
||||
def extract_netlist_and_topcell(spice_path):
|
||||
with open(spice_path, 'r') as f:
|
||||
lines = f.readlines()
|
||||
|
||||
netlist = []
|
||||
topcell = None
|
||||
inside_subckt = False
|
||||
|
||||
for line in lines:
|
||||
if line.strip().startswith(".subckt"):
|
||||
parts = line.strip().split()
|
||||
if len(parts) > 1:
|
||||
topcell = parts[1]
|
||||
inside_subckt = True
|
||||
if inside_subckt:
|
||||
netlist.append(line.rstrip())
|
||||
if line.strip().startswith(".ends"):
|
||||
break
|
||||
|
||||
if not topcell:
|
||||
raise ValueError("Topcell name not found in SPICE file.")
|
||||
|
||||
return topcell, "\n".join(netlist)
|
||||
|
||||
def modify_sym_file(sym_path, output_dir, topcell, netlist):
|
||||
with open(sym_path, 'r') as f:
|
||||
sym_lines = f.readlines()
|
||||
|
||||
new_sym_lines = []
|
||||
inserted = False
|
||||
|
||||
for line in sym_lines:
|
||||
if line.strip().startswith("K {type=subcircuit"):
|
||||
new_sym_lines.append(line)
|
||||
continue
|
||||
elif line.strip().startswith("template=") and not inserted:
|
||||
new_template = (
|
||||
f'template="name=x1\n'
|
||||
f'schematic={topcell}\n'
|
||||
f'spice_sym_def=\n'
|
||||
f'\\\\"\n'
|
||||
f'{netlist}\n'
|
||||
f'\\\\"\n'
|
||||
f'"'
|
||||
)
|
||||
new_sym_lines.append(new_template + "\n")
|
||||
inserted = True
|
||||
else:
|
||||
new_sym_lines.append(line)
|
||||
|
||||
filename = os.path.basename(sym_path)
|
||||
out_path = os.path.join(output_dir, filename)
|
||||
|
||||
os.makedirs(output_dir, exist_ok=True)
|
||||
|
||||
with open(out_path, 'w') as f:
|
||||
f.writelines(new_sym_lines)
|
||||
|
||||
print(f"Saved modified .sym to: {out_path}")
|
||||
|
||||
if __name__ == "__main__":
|
||||
if len(sys.argv) != 4:
|
||||
print("Usage: python insert_netlist_to_sym.py <netlist.spice> <symbol.sym> <output_folder>")
|
||||
sys.exit(1)
|
||||
|
||||
spice_file = sys.argv[1]
|
||||
sym_file = sys.argv[2]
|
||||
output_folder = sys.argv[3]
|
||||
|
||||
topcell, netlist = extract_netlist_and_topcell(spice_file)
|
||||
modify_sym_file(sym_file, output_folder, topcell, netlist)
|
||||
|
|
@ -1,75 +0,0 @@
|
|||
import sys
|
||||
from pathlib import Path
|
||||
|
||||
def get_original_io_order(original_netlist_path):
|
||||
io_pins = []
|
||||
|
||||
with open(original_netlist_path, "r") as f:
|
||||
for line in f:
|
||||
stripped = line.strip()
|
||||
if not stripped or stripped.startswith("*"):
|
||||
continue
|
||||
if stripped.lower().startswith(".subckt"):
|
||||
tokens = stripped.split()
|
||||
if len(tokens) >= 3:
|
||||
print(f"[INFO] Found .subckt in original: {stripped}")
|
||||
io_pins = tokens[2:]
|
||||
break
|
||||
|
||||
if not io_pins:
|
||||
raise ValueError(f"Could not find IO pins in original schematic: {original_netlist_path}")
|
||||
|
||||
return io_pins
|
||||
|
||||
def reorder_pex_subckt(pex_path, correct_order):
|
||||
with open(pex_path, "r") as f:
|
||||
lines = f.readlines()
|
||||
|
||||
new_lines = []
|
||||
subckt_found = False
|
||||
|
||||
for line in lines:
|
||||
stripped = line.strip()
|
||||
if stripped.lower().startswith(".subckt") and not subckt_found:
|
||||
tokens = stripped.split()
|
||||
subckt_name = tokens[1]
|
||||
ports = tokens[2:]
|
||||
|
||||
# Case-insensitive set comparison
|
||||
ports_lower = [p.lower() for p in ports]
|
||||
correct_lower = [p.lower() for p in correct_order]
|
||||
|
||||
if set(ports_lower) != set(correct_lower):
|
||||
print("[ERROR] Port name mismatch!")
|
||||
print("[DEBUG] PEX ports :", ports)
|
||||
print("[DEBUG] Schematic IOs:", correct_order)
|
||||
raise ValueError("Port names in PEX netlist don't match original IO pins")
|
||||
|
||||
# Map from lower-case pin name to original-cased PEX name
|
||||
port_map = {p.lower(): p for p in ports}
|
||||
|
||||
reordered_ports = [port_map[p.lower()] for p in correct_order]
|
||||
reordered_line = f".subckt {subckt_name}_pex {' '.join(reordered_ports)}\n"
|
||||
new_lines.append(reordered_line)
|
||||
subckt_found = True
|
||||
else:
|
||||
new_lines.append(line)
|
||||
|
||||
with open(pex_path, "w") as f:
|
||||
f.writelines(new_lines)
|
||||
|
||||
print(f"[INFO] Rewrote subckt line in {pex_path}")
|
||||
|
||||
if __name__ == "__main__":
|
||||
if len(sys.argv) != 3:
|
||||
print("Usage: python match_subckt_order.py <pex_spice_path> <original_schematic_spice_path>")
|
||||
sys.exit(1)
|
||||
|
||||
pex_spice = Path(sys.argv[1])
|
||||
original_schematic = Path(sys.argv[2])
|
||||
|
||||
print(f"[INFO] Found extracted spice file: {pex_spice}")
|
||||
print(f"[INFO] Reordering subcircuit pins to match original schematic...")
|
||||
|
||||
io_order = get_original_io_order(original_schematic)
|
||||
reorder_pex_subckt(pex_spice, io_order)
|
||||
|
|
@ -1,99 +0,0 @@
|
|||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
###############################################################################
|
||||
# ⬇⬇⬇ USER CONFIGURATION ⬇⬇⬇ #
|
||||
###############################################################################
|
||||
|
||||
# Activate Python environment (adjust this path to your Python venv activate script) Or if you python version is >3.12 ignore asuming klayout_pex is installed
|
||||
PYTHON_ENV="$HOME/misc/klayout_pex/bin/activate"
|
||||
# Example: /home/username/misc/klayout_pex/bin/activate
|
||||
|
||||
# Path to Magic executable used by kpex (adjust if installed elsewhere)
|
||||
KPEX_MAGIC_EXE="$HOME/.local/bin/magic"
|
||||
# Example: /usr/local/bin/magic or ~/.local/bin/magic
|
||||
|
||||
#Path to symbol
|
||||
SYM_DIR="./DIFF_COMPARATOR.sym" # Asuming you have a symbol for the DUT
|
||||
|
||||
LAYOUT_DIR="../layout/DIFF_COMPARATOR.gds" # Path to the GDS file
|
||||
|
||||
# Important: Path to your PDK root directory must be set externally in env variable PDK_ROOT, otherwise give absolute path
|
||||
PDK_NAME="ihp_sg13g2" # Your PDK name (must match PDK_ROOT contents)
|
||||
MAGICRC="$PDK_ROOT/$PDK/libs.tech/magic/ihp-sg13g2.magicrc" # The magicrc file for your PDK, used during extraction
|
||||
|
||||
SCHEMATIC="../layout/lvs_netlist/DIFF_COMPARATOR.spice" # Spicefile of the comparator from Schematic or LVS (Used for pex to perform LVS and script to organize IO)
|
||||
|
||||
##############################################################################################################################################################
|
||||
# ⛔ DO NOT TOUCH BELOW THIS LINE ⛔ Unless you see clear issue with your setup :) #
|
||||
##############################################################################################################################################################
|
||||
|
||||
|
||||
# Check if required files exist before proceeding
|
||||
if [[ ! -f "$PYTHON_ENV" ]]; then
|
||||
echo "[ERROR] Python environment activate script not found: $PYTHON_ENV"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ ! -x "$KPEX_MAGIC_EXE" ]]; then
|
||||
echo "[ERROR] Magic executable not found or not executable: $KPEX_MAGIC_EXE"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ ! -f "$LAYOUT_DIR" ]]; then
|
||||
echo "[ERROR] Layout GDS file not found: $LAYOUT_DIR"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
||||
if [[ ! -f "$MAGICRC" ]]; then
|
||||
echo "[ERROR] Magicrc file for PDK not found: $MAGICRC"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Activate Python virtual environment
|
||||
echo "[INFO] Activating Python environment..."
|
||||
source "$PYTHON_ENV"
|
||||
|
||||
echo "[INFO] Using MAGIC executable: $KPEX_MAGIC_EXE"
|
||||
|
||||
# Run parasitic extraction with kpex
|
||||
echo "[INFO] Running parasitic extraction with KPEX..."
|
||||
kpex \
|
||||
--pdk "$PDK_NAME" \
|
||||
--magic \
|
||||
--schematic "$SCHEMATIC"\
|
||||
--gds "$LAYOUT_DIR" \
|
||||
--magicrc "$MAGICRC" \
|
||||
--magic_mode RC \
|
||||
--magic_cthresh 0.02 \
|
||||
--magic_rthresh 50 \
|
||||
--magic_short resistor \
|
||||
--magic_merge conservative \
|
||||
--out_dir ./pex_output
|
||||
|
||||
# Find the generated spice file (assuming only one)
|
||||
spice_location=$(find ./pex_output -type f -name "*.spice" ! -name "*_dummy_schematic.spice" | head -n 1)
|
||||
|
||||
|
||||
if [[ -z "$spice_location" ]]; then
|
||||
echo "[ERROR] No .spice file found in pex_output directory"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "[INFO] Found extracted spice file: $spice_location"
|
||||
|
||||
# Run Python script to fix port ordering in the extracted netlist
|
||||
echo "[INFO] Reordering subcircuit pins to match original schematic..."
|
||||
echo "$spice_location"
|
||||
echo "$SCHEMATIC"
|
||||
|
||||
python3 python/match_subckt_order.py "$spice_location" "$SCHEMATIC"
|
||||
|
||||
|
||||
|
||||
echo "[INFO] Creating DUT symbol with pex netlist"
|
||||
python3 python/insert_netlist_to_sym.py "$spice_location" "$SYM_DIR" xschem_pex_symbol
|
||||
|
||||
cd xschem_pex_symbol
|
||||
echo "[✅ DONE] Modified symbol, including pex netlist generated and saved in: $(pwd)/"
|
||||
|
|
@ -1,947 +0,0 @@
|
|||
v {xschem version=3.4.5 file_version=1.2
|
||||
}
|
||||
G {}
|
||||
K {type=subcircuit
|
||||
format="@name @pinlist @symname"
|
||||
template="name=x1
|
||||
schematic=DIFF_COMPARATOR_pex
|
||||
spice_sym_def=
|
||||
\\"
|
||||
.subckt DIFF_COMPARATOR_pex vdd gnd V+ V- clk out- out+ vbias
|
||||
X0 a_687_2445# V- a_1245_3300# vdd sg13_lv_pmos ad=0.76p pd=4.38u as=1.36p ps=8.68u w=4u l=0.2u M=8
|
||||
X1 a_944_1911# V+ a_1245_3300# vdd sg13_lv_pmos ad=0.76p pd=4.38u as=1.36p ps=8.68u w=4u l=0.2u M=8
|
||||
X2 a_1752_817# vbias vdd vdd sg13_lv_pmos ad=1.53p pd=9.68u as=0.855p ps=4.88u w=4.5u l=0.3u M=4
|
||||
X3 gnd gnd gnd gnd sg13_lv_nmos ad=1.36p pd=8.68u as=50.9002p ps=0.15373m w=4u l=0.2u M=4
|
||||
X4 vdd a_944_1911# out+ vdd sg13_lv_pmos ad=0.76p pd=4.38u as=1.36p ps=8.68u w=4u l=0.2u M=2
|
||||
X5 a_944_1911# a_687_2445# gnd gnd sg13_lv_nmos ad=1.44p pd=4.72u as=0.76p ps=4.38u w=4u l=0.2u
|
||||
X6 a_687_2445# clk gnd gnd sg13_lv_nmos ad=1.44p pd=4.72u as=0.76p ps=4.38u w=4u l=0.2u
|
||||
X7 gnd a_944_1911# a_687_2445# gnd sg13_lv_nmos ad=0.76p pd=4.38u as=1.44p ps=4.72u w=4u l=0.2u
|
||||
X8 out- a_687_2445# gnd gnd sg13_lv_nmos ad=0.68p pd=4.68u as=0.38p ps=2.38u w=2u l=0.2u M=2
|
||||
X9 gnd clk a_944_1911# gnd sg13_lv_nmos ad=0.76p pd=4.38u as=1.44p ps=4.72u w=4u l=0.2u
|
||||
X10 out- a_687_2445# vdd vdd sg13_lv_pmos ad=1.36p pd=8.68u as=0.76p ps=4.38u w=4u l=0.2u M=2
|
||||
X11 out+ a_944_1911# gnd gnd sg13_lv_nmos ad=0.68p pd=4.68u as=0.38p ps=2.38u w=2u l=0.2u M=2
|
||||
X12 a_1245_3300# clk a_1752_817# vdd sg13_lv_pmos ad=1.53p pd=9.68u as=0.855p ps=4.88u w=4.5u l=0.3u M=4
|
||||
C0 a_944_1911# V- 0.46901f
|
||||
C1 a_944_1911# vdd 1.10862f
|
||||
C2 a_687_2445# V- 0.78527f
|
||||
C3 a_687_2445# vdd 1.31156f
|
||||
C4 clk a_1245_3300# 0.44782f
|
||||
C5 out+ a_1245_3300# 0.36924f
|
||||
C6 out- a_1245_3300# 0.36795f
|
||||
C7 V+ a_1245_3300# 0.76573f
|
||||
C8 vdd a_1752_817# 7.11146f
|
||||
C9 clk a_944_1911# 0.24743f
|
||||
C10 clk a_687_2445# 0.23833f
|
||||
C11 out+ a_944_1911# 0.80028f
|
||||
C12 out+ a_687_2445# 0.69286f
|
||||
C13 a_944_1911# out- 0.61161f
|
||||
C14 a_944_1911# V+ 1.08178f
|
||||
C15 a_687_2445# out- 0.89453f
|
||||
C16 a_687_2445# V+ 0.13025f
|
||||
C17 clk a_1752_817# 0.5025f
|
||||
C18 vdd V- 4.06121f
|
||||
C19 clk vdd 2.98842f
|
||||
C20 out+ vdd 1.84773f
|
||||
C21 a_1752_817# vbias 2.28993f
|
||||
C22 V- V+ 1.61045f
|
||||
C23 vdd out- 1.84304f
|
||||
C24 vdd V+ 4.08205f
|
||||
C25 a_944_1911# a_1245_3300# 8.04522f
|
||||
C26 a_687_2445# a_1245_3300# 11.3534f
|
||||
C27 a_1752_817# a_1245_3300# 3.76533f
|
||||
C28 out+ out- 0.0933f
|
||||
C29 a_687_2445# a_944_1911# 2.24936f
|
||||
C30 vdd vbias 2.83964f
|
||||
C31 a_944_1911# a_1752_817# 0.0558f
|
||||
C32 a_687_2445# a_1752_817# 0.04531f
|
||||
C33 clk vbias 0.19878f
|
||||
C34 V- a_1245_3300# 0.94179f
|
||||
C35 vdd a_1245_3300# 2.55093f
|
||||
C36 vdd w_805_2869# 0.1537f
|
||||
R0 V+.n6 V+.n0 17.1875
|
||||
R1 V+.n6 V+.n5 16.5321
|
||||
R2 V+.n2 V+.n1 15.8046
|
||||
R3 V+.n4 V+.n3 9.60223
|
||||
R4 V+.n4 V+.n1 8.28871
|
||||
R5 V+.n3 V+.n0 8.28871
|
||||
R6 V+.n5 V+.n4 7.51146
|
||||
R7 V+.n3 V+.n2 7.51146
|
||||
R8 V+ V+.n6 1.77098
|
||||
R9 V-.n6 V-.n0 17.1792
|
||||
R10 V-.n3 V-.n0 17.1129
|
||||
R11 V-.n4 V-.n1 17.1083
|
||||
R12 V-.n6 V-.n5 16.5321
|
||||
R13 V-.n2 V-.n1 15.8156
|
||||
R14 V-.n5 V-.n4 7.51146
|
||||
R15 V-.n3 V-.n2 7.51146
|
||||
R16 V- V-.n6 1.57783
|
||||
R17 V-.n4 V-.n3 0.792909
|
||||
R18 vbias vbias.n0 6.1153
|
||||
R19 out-.n17 out-.n1 17.0005
|
||||
R20 out-.n22 out-.n1 17.0005
|
||||
R21 out-.n13 out-.n1 17.0005
|
||||
R22 out-.n35 out-.n7 17.0005
|
||||
R23 out-.n35 out-.n6 17.0005
|
||||
R24 out-.n35 out-.n8 17.0005
|
||||
R25 out-.n42 out-.n41 9.04081
|
||||
R26 out-.n12 out-.n10 9.03703
|
||||
R27 out-.n24 out-.n23 9.0005
|
||||
R28 out-.n21 out-.n20 9.0005
|
||||
R29 out-.n16 out-.n3 9.0005
|
||||
R30 out-.n40 out-.n39 9.0005
|
||||
R31 out-.n31 out-.n30 9.0005
|
||||
R32 out-.n28 out-.n27 9.0005
|
||||
R33 out-.n45 out-.n43 9.0005
|
||||
R34 out-.n46 out-.n43 9.0005
|
||||
R35 out-.n44 out-.n43 9.0005
|
||||
R36 out-.n51 out-.n43 9.0005
|
||||
R37 out-.n52 out-.n45 9.0005
|
||||
R38 out-.n52 out-.n46 9.0005
|
||||
R39 out-.n52 out-.n44 9.0005
|
||||
R40 out-.n52 out-.n51 9.0005
|
||||
R41 out-.n36 out-.n35 8.501
|
||||
R42 out-.n12 out-.n1 8.50006
|
||||
R43 out-.n35 out-.n5 8.49923
|
||||
R44 out-.n50 out-.n49 8.49864
|
||||
R45 out-.n49 out-.n47 8.49864
|
||||
R46 out-.n41 out-.n1 8.49628
|
||||
R47 out-.n49 out-.n48 8.49096
|
||||
R48 out-.n35 out-.n4 8.49007
|
||||
R49 out-.n35 out-.n34 8.49007
|
||||
R50 out-.n2 out-.n1 8.46606
|
||||
R51 out-.n29 out-.n1 8.46606
|
||||
R52 out-.n10 out-.n5 4.51473
|
||||
R53 out-.n36 out-.n0 4.51194
|
||||
R54 out-.n38 out-.n37 4.5005
|
||||
R55 out-.n19 out-.n18 4.5005
|
||||
R56 out-.n15 out-.n14 4.5005
|
||||
R57 out-.n26 out-.n25 4.5005
|
||||
R58 out-.n11 out-.n9 4.5005
|
||||
R59 out-.n33 out-.n32 4.5005
|
||||
R60 out- out-.n53 1.4685
|
||||
R61 out-.n30 out-.n12 0.146886
|
||||
R62 out-.n41 out-.n40 0.143078
|
||||
R63 out-.n17 out-.n16 0.137052
|
||||
R64 out-.n28 out-.n13 0.129466
|
||||
R65 out-.n53 out-.n42 0.126844
|
||||
R66 out-.n40 out-.n2 0.108815
|
||||
R67 out-.n30 out-.n29 0.101229
|
||||
R68 out-.n22 out-.n21 0.0953276
|
||||
R69 out-.n23 out-.n22 0.0877414
|
||||
R70 out-.n29 out-.n28 0.0822633
|
||||
R71 out-.n16 out-.n2 0.0746771
|
||||
R72 out-.n23 out-.n13 0.0536034
|
||||
R73 out-.n37 out-.n36 0.0468193
|
||||
R74 out-.n21 out-.n17 0.0460172
|
||||
R75 out-.n50 out-.n44 0.0453402
|
||||
R76 out-.n47 out-.n46 0.0453402
|
||||
R77 out-.n33 out-.n5 0.0450428
|
||||
R78 out-.n9 out-.n8 0.043672
|
||||
R79 out-.n18 out-.n7 0.0401237
|
||||
R80 out-.n34 out-.n33 0.0352729
|
||||
R81 out-.n37 out-.n4 0.0317246
|
||||
R82 out-.n25 out-.n6 0.0306613
|
||||
R83 out-.n48 out-.n44 0.0293633
|
||||
R84 out-.n48 out-.n46 0.0293633
|
||||
R85 out-.n14 out-.n6 0.0271129
|
||||
R86 out-.n18 out-.n4 0.0269934
|
||||
R87 out-.n34 out-.n9 0.023445
|
||||
R88 out-.n32 out-.n10 0.019037
|
||||
R89 out-.n31 out-.n11 0.019037
|
||||
R90 out-.n27 out-.n26 0.019037
|
||||
R91 out-.n24 out-.n15 0.019037
|
||||
R92 out-.n20 out-.n19 0.019037
|
||||
R93 out-.n38 out-.n3 0.019037
|
||||
R94 out-.n39 out-.n0 0.019037
|
||||
R95 out-.n14 out-.n7 0.0176505
|
||||
R96 out-.n25 out-.n8 0.0141022
|
||||
R97 out-.n51 out-.n50 0.0134159
|
||||
R98 out-.n47 out-.n45 0.0134159
|
||||
R99 out-.n53 out-.n43 0.0127081
|
||||
R100 out-.n53 out-.n52 0.0127081
|
||||
R101 out-.n32 out-.n31 0.00151852
|
||||
R102 out-.n27 out-.n11 0.00151852
|
||||
R103 out-.n26 out-.n24 0.00151852
|
||||
R104 out-.n20 out-.n15 0.00151852
|
||||
R105 out-.n19 out-.n3 0.00151852
|
||||
R106 out-.n39 out-.n38 0.00151852
|
||||
R107 out-.n42 out-.n0 0.00151852
|
||||
R108 out+.n40 out+.n5 17.0005
|
||||
R109 out+.n40 out+.n2 17.0005
|
||||
R110 out+.n40 out+.n6 17.0005
|
||||
R111 out+.n34 out+.n33 17.0005
|
||||
R112 out+.n33 out+.n14 17.0005
|
||||
R113 out+.n33 out+.n17 17.0005
|
||||
R114 out+.n29 out+.n4 9.04081
|
||||
R115 out+.n42 out+.n41 9.03703
|
||||
R116 out+.n10 out+.n9 9.0005
|
||||
R117 out+.n21 out+.n20 9.0005
|
||||
R118 out+.n25 out+.n24 9.0005
|
||||
R119 out+.n28 out+.n27 9.0005
|
||||
R120 out+.n7 out+.n1 9.0005
|
||||
R121 out+.n38 out+.n37 9.0005
|
||||
R122 out+.n45 out+.n43 9.0005
|
||||
R123 out+.n46 out+.n43 9.0005
|
||||
R124 out+.n44 out+.n43 9.0005
|
||||
R125 out+.n51 out+.n43 9.0005
|
||||
R126 out+.n52 out+.n45 9.0005
|
||||
R127 out+.n52 out+.n46 9.0005
|
||||
R128 out+.n52 out+.n44 9.0005
|
||||
R129 out+.n52 out+.n51 9.0005
|
||||
R130 out+.n33 out+.n16 8.501
|
||||
R131 out+.n41 out+.n40 8.50006
|
||||
R132 out+.n33 out+.n13 8.49923
|
||||
R133 out+.n49 out+.n47 8.49864
|
||||
R134 out+.n50 out+.n49 8.49864
|
||||
R135 out+.n40 out+.n4 8.49628
|
||||
R136 out+.n49 out+.n48 8.49096
|
||||
R137 out+.n33 out+.n11 8.49007
|
||||
R138 out+.n33 out+.n32 8.49007
|
||||
R139 out+.n40 out+.n3 8.46606
|
||||
R140 out+.n40 out+.n39 8.46606
|
||||
R141 out+.n29 out+.n13 4.51392
|
||||
R142 out+.n16 out+.n0 4.51194
|
||||
R143 out+.n31 out+.n30 4.5005
|
||||
R144 out+.n26 out+.n18 4.5005
|
||||
R145 out+.n23 out+.n22 4.5005
|
||||
R146 out+.n19 out+.n12 4.5005
|
||||
R147 out+.n36 out+.n35 4.5005
|
||||
R148 out+.n15 out+.n8 4.5005
|
||||
R149 out+ out+.n53 1.36221
|
||||
R150 out+.n41 out+.n1 0.146886
|
||||
R151 out+.n27 out+.n4 0.143078
|
||||
R152 out+.n24 out+.n5 0.137052
|
||||
R153 out+.n38 out+.n6 0.129466
|
||||
R154 out+.n53 out+.n42 0.127659
|
||||
R155 out+.n27 out+.n3 0.108815
|
||||
R156 out+.n39 out+.n1 0.101229
|
||||
R157 out+.n20 out+.n2 0.0953276
|
||||
R158 out+.n9 out+.n2 0.0877414
|
||||
R159 out+.n39 out+.n38 0.0822633
|
||||
R160 out+.n24 out+.n3 0.0746771
|
||||
R161 out+.n9 out+.n6 0.0536034
|
||||
R162 out+.n16 out+.n15 0.0468193
|
||||
R163 out+.n20 out+.n5 0.0460172
|
||||
R164 out+.n50 out+.n44 0.0453402
|
||||
R165 out+.n47 out+.n46 0.0453402
|
||||
R166 out+.n31 out+.n13 0.0450428
|
||||
R167 out+.n18 out+.n17 0.043672
|
||||
R168 out+.n35 out+.n34 0.0401237
|
||||
R169 out+.n32 out+.n31 0.0352729
|
||||
R170 out+.n15 out+.n11 0.0317246
|
||||
R171 out+.n22 out+.n14 0.0306613
|
||||
R172 out+.n48 out+.n44 0.0293633
|
||||
R173 out+.n48 out+.n46 0.0293633
|
||||
R174 out+.n14 out+.n12 0.0271129
|
||||
R175 out+.n35 out+.n11 0.0269934
|
||||
R176 out+.n32 out+.n18 0.023445
|
||||
R177 out+.n7 out+.n0 0.0198519
|
||||
R178 out+.n37 out+.n8 0.0198519
|
||||
R179 out+.n36 out+.n10 0.0198519
|
||||
R180 out+.n21 out+.n19 0.0198519
|
||||
R181 out+.n25 out+.n23 0.0198519
|
||||
R182 out+.n28 out+.n26 0.0198519
|
||||
R183 out+.n30 out+.n29 0.0198519
|
||||
R184 out+.n34 out+.n12 0.0176505
|
||||
R185 out+.n22 out+.n17 0.0141022
|
||||
R186 out+.n51 out+.n50 0.0134159
|
||||
R187 out+.n47 out+.n45 0.0134159
|
||||
R188 out+.n53 out+.n43 0.0127081
|
||||
R189 out+.n53 out+.n52 0.0127081
|
||||
R190 out+.n42 out+.n0 0.000703704
|
||||
R191 out+.n8 out+.n7 0.000703704
|
||||
R192 out+.n37 out+.n36 0.000703704
|
||||
R193 out+.n19 out+.n10 0.000703704
|
||||
R194 out+.n23 out+.n21 0.000703704
|
||||
R195 out+.n26 out+.n25 0.000703704
|
||||
R196 out+.n30 out+.n28 0.000703704
|
||||
R197 clk.n4 clk.n0 32.251
|
||||
R198 clk.n3 clk.n2 29.4509
|
||||
R199 clk.n3 clk.n1 12.2999
|
||||
R200 clk.n4 clk.n3 2.20443
|
||||
R201 clk clk.n4 0.574117
|
||||
R202 vdd.n208 vdd.n190 17.0005
|
||||
R203 vdd.n208 vdd.n188 17.0005
|
||||
R204 vdd.n208 vdd.n191 17.0005
|
||||
R205 vdd.n208 vdd.n186 17.0005
|
||||
R206 vdd.n208 vdd.n207 17.0005
|
||||
R207 vdd.n239 vdd.n178 17.0005
|
||||
R208 vdd.n179 vdd.n178 17.0005
|
||||
R209 vdd.n232 vdd.n178 17.0005
|
||||
R210 vdd.n227 vdd.n178 17.0005
|
||||
R211 vdd.n225 vdd.n178 17.0005
|
||||
R212 vdd.n210 vdd.n209 9.05964
|
||||
R213 vdd.n189 vdd.n176 9.05964
|
||||
R214 vdd.n222 vdd.n183 9.05964
|
||||
R215 vdd.n242 vdd.n241 9.05964
|
||||
R216 vdd.n226 vdd.n182 9.0005
|
||||
R217 vdd.n229 vdd.n228 9.0005
|
||||
R218 vdd.n231 vdd.n230 9.0005
|
||||
R219 vdd.n233 vdd.n180 9.0005
|
||||
R220 vdd.n236 vdd.n235 9.0005
|
||||
R221 vdd.n238 vdd.n237 9.0005
|
||||
R222 vdd.n240 vdd.n177 9.0005
|
||||
R223 vdd.n224 vdd.n223 9.0005
|
||||
R224 vdd.n206 vdd.n205 9.0005
|
||||
R225 vdd.n204 vdd.n203 9.0005
|
||||
R226 vdd.n202 vdd.n201 9.0005
|
||||
R227 vdd.n200 vdd.n199 9.0005
|
||||
R228 vdd.n198 vdd.n197 9.0005
|
||||
R229 vdd.n196 vdd.n195 9.0005
|
||||
R230 vdd.n194 vdd.n193 9.0005
|
||||
R231 vdd.n185 vdd.n184 9.0005
|
||||
R232 vdd.n128 vdd.n127 8.501
|
||||
R233 vdd.n115 vdd.n89 8.501
|
||||
R234 vdd.n98 vdd.n97 8.501
|
||||
R235 vdd.n81 vdd.n80 8.501
|
||||
R236 vdd.n134 vdd.n69 8.501
|
||||
R237 vdd.n208 vdd.n189 8.47918
|
||||
R238 vdd.n208 vdd.n187 8.47918
|
||||
R239 vdd.n208 vdd.n192 8.47918
|
||||
R240 vdd.n209 vdd.n208 8.47918
|
||||
R241 vdd.n241 vdd.n178 8.47918
|
||||
R242 vdd.n234 vdd.n178 8.47918
|
||||
R243 vdd.n181 vdd.n178 8.47918
|
||||
R244 vdd.n183 vdd.n178 8.47918
|
||||
R245 vdd.n87 vdd.n86 5.66778
|
||||
R246 vdd.n243 vdd.n176 5.20536
|
||||
R247 vdd.n221 vdd.n210 5.20536
|
||||
R248 vdd.n222 vdd.n221 4.6895
|
||||
R249 vdd.n243 vdd.n242 4.6895
|
||||
R250 vdd.n245 vdd.n173 4.56174
|
||||
R251 vdd.n249 vdd.n174 4.56174
|
||||
R252 vdd.n215 vdd.n211 4.56174
|
||||
R253 vdd.n219 vdd.n212 4.56174
|
||||
R254 vdd.n165 vdd.n2 4.56174
|
||||
R255 vdd.n169 vdd.n3 4.56174
|
||||
R256 vdd.n11 vdd.n7 4.56174
|
||||
R257 vdd.n15 vdd.n8 4.56174
|
||||
R258 vdd.n28 vdd.n25 4.56174
|
||||
R259 vdd.n32 vdd.n26 4.56174
|
||||
R260 vdd.n38 vdd.n35 4.56174
|
||||
R261 vdd.n42 vdd.n36 4.56174
|
||||
R262 vdd.n48 vdd.n45 4.56174
|
||||
R263 vdd.n52 vdd.n46 4.56174
|
||||
R264 vdd.n136 vdd.n66 4.56174
|
||||
R265 vdd.n140 vdd.n67 4.56174
|
||||
R266 vdd.n74 vdd.n70 4.56174
|
||||
R267 vdd.n78 vdd.n71 4.56174
|
||||
R268 vdd.n100 vdd.n93 4.56174
|
||||
R269 vdd.n104 vdd.n94 4.56174
|
||||
R270 vdd.n109 vdd.n90 4.56174
|
||||
R271 vdd.n113 vdd.n91 4.56174
|
||||
R272 vdd.n121 vdd.n117 4.56174
|
||||
R273 vdd.n125 vdd.n118 4.56174
|
||||
R274 vdd.n145 vdd.n22 4.56174
|
||||
R275 vdd.n149 vdd.n23 4.56174
|
||||
R276 vdd.n58 vdd.n55 4.56174
|
||||
R277 vdd.n62 vdd.n56 4.56174
|
||||
R278 vdd.n248 vdd.n247 4.5005
|
||||
R279 vdd.n246 vdd.n175 4.5005
|
||||
R280 vdd.n218 vdd.n217 4.5005
|
||||
R281 vdd.n216 vdd.n213 4.5005
|
||||
R282 vdd.n166 vdd.n4 4.5005
|
||||
R283 vdd.n168 vdd.n167 4.5005
|
||||
R284 vdd.n12 vdd.n9 4.5005
|
||||
R285 vdd.n14 vdd.n13 4.5005
|
||||
R286 vdd.n29 vdd.n27 4.5005
|
||||
R287 vdd.n31 vdd.n30 4.5005
|
||||
R288 vdd.n39 vdd.n37 4.5005
|
||||
R289 vdd.n41 vdd.n40 4.5005
|
||||
R290 vdd.n49 vdd.n47 4.5005
|
||||
R291 vdd.n51 vdd.n50 4.5005
|
||||
R292 vdd.n137 vdd.n68 4.5005
|
||||
R293 vdd.n139 vdd.n138 4.5005
|
||||
R294 vdd.n75 vdd.n72 4.5005
|
||||
R295 vdd.n77 vdd.n76 4.5005
|
||||
R296 vdd.n101 vdd.n95 4.5005
|
||||
R297 vdd.n103 vdd.n102 4.5005
|
||||
R298 vdd.n110 vdd.n92 4.5005
|
||||
R299 vdd.n112 vdd.n111 4.5005
|
||||
R300 vdd.n122 vdd.n119 4.5005
|
||||
R301 vdd.n124 vdd.n123 4.5005
|
||||
R302 vdd.n146 vdd.n24 4.5005
|
||||
R303 vdd.n148 vdd.n147 4.5005
|
||||
R304 vdd.n59 vdd.n57 4.5005
|
||||
R305 vdd.n61 vdd.n60 4.5005
|
||||
R306 vdd.n133 vdd.n132 4.16092
|
||||
R307 vdd.n116 vdd.n82 4.16066
|
||||
R308 vdd.n96 vdd.n84 4.16066
|
||||
R309 vdd.n88 vdd.n83 4.16054
|
||||
R310 vdd.n154 vdd.n6 4.16048
|
||||
R311 vdd.n158 vdd.n6 4.16048
|
||||
R312 vdd.n162 vdd.n6 4.16048
|
||||
R313 vdd.n131 vdd.n82 2.83383
|
||||
R314 vdd.n131 vdd.n83 2.83383
|
||||
R315 vdd.n131 vdd.n84 2.83383
|
||||
R316 vdd.n132 vdd.n131 2.83383
|
||||
R317 vdd.n21 vdd.n6 2.7354
|
||||
R318 vdd.n245 vdd.n244 2.28117
|
||||
R319 vdd.n244 vdd.n174 2.28117
|
||||
R320 vdd.n220 vdd.n211 2.28117
|
||||
R321 vdd.n220 vdd.n219 2.28117
|
||||
R322 vdd.n165 vdd.n164 2.28117
|
||||
R323 vdd.n164 vdd.n3 2.28117
|
||||
R324 vdd.n16 vdd.n7 2.28117
|
||||
R325 vdd.n16 vdd.n15 2.28117
|
||||
R326 vdd.n28 vdd.n17 2.28117
|
||||
R327 vdd.n26 vdd.n17 2.28117
|
||||
R328 vdd.n38 vdd.n18 2.28117
|
||||
R329 vdd.n36 vdd.n18 2.28117
|
||||
R330 vdd.n48 vdd.n19 2.28117
|
||||
R331 vdd.n46 vdd.n19 2.28117
|
||||
R332 vdd.n136 vdd.n135 2.28117
|
||||
R333 vdd.n135 vdd.n67 2.28117
|
||||
R334 vdd.n79 vdd.n70 2.28117
|
||||
R335 vdd.n79 vdd.n78 2.28117
|
||||
R336 vdd.n100 vdd.n99 2.28117
|
||||
R337 vdd.n99 vdd.n94 2.28117
|
||||
R338 vdd.n114 vdd.n90 2.28117
|
||||
R339 vdd.n114 vdd.n113 2.28117
|
||||
R340 vdd.n126 vdd.n117 2.28117
|
||||
R341 vdd.n126 vdd.n125 2.28117
|
||||
R342 vdd.n150 vdd.n22 2.28117
|
||||
R343 vdd.n150 vdd.n149 2.28117
|
||||
R344 vdd.n58 vdd.n20 2.28117
|
||||
R345 vdd.n56 vdd.n20 2.28117
|
||||
R346 vdd.n250 vdd.n173 2.25769
|
||||
R347 vdd.n250 vdd.n249 2.25769
|
||||
R348 vdd.n215 vdd.n214 2.25769
|
||||
R349 vdd.n214 vdd.n212 2.25769
|
||||
R350 vdd.n170 vdd.n2 2.25769
|
||||
R351 vdd.n170 vdd.n169 2.25769
|
||||
R352 vdd.n11 vdd.n10 2.25769
|
||||
R353 vdd.n10 vdd.n8 2.25769
|
||||
R354 vdd.n33 vdd.n25 2.25769
|
||||
R355 vdd.n33 vdd.n32 2.25769
|
||||
R356 vdd.n43 vdd.n35 2.25769
|
||||
R357 vdd.n43 vdd.n42 2.25769
|
||||
R358 vdd.n53 vdd.n45 2.25769
|
||||
R359 vdd.n53 vdd.n52 2.25769
|
||||
R360 vdd.n141 vdd.n66 2.25769
|
||||
R361 vdd.n141 vdd.n140 2.25769
|
||||
R362 vdd.n74 vdd.n73 2.25769
|
||||
R363 vdd.n73 vdd.n71 2.25769
|
||||
R364 vdd.n105 vdd.n93 2.25769
|
||||
R365 vdd.n105 vdd.n104 2.25769
|
||||
R366 vdd.n109 vdd.n108 2.25769
|
||||
R367 vdd.n108 vdd.n91 2.25769
|
||||
R368 vdd.n121 vdd.n120 2.25769
|
||||
R369 vdd.n120 vdd.n118 2.25769
|
||||
R370 vdd.n145 vdd.n144 2.25769
|
||||
R371 vdd.n144 vdd.n23 2.25769
|
||||
R372 vdd.n63 vdd.n55 2.25769
|
||||
R373 vdd.n63 vdd.n62 2.25769
|
||||
R374 vdd.n156 vdd.n6 1.99818
|
||||
R375 vdd.n160 vdd.n6 1.9981
|
||||
R376 vdd.n244 vdd.n243 1.89937
|
||||
R377 vdd.n221 vdd.n220 1.89937
|
||||
R378 vdd.n164 vdd.n163 1.66843
|
||||
R379 vdd.n161 vdd.n16 1.66843
|
||||
R380 vdd.n159 vdd.n17 1.66843
|
||||
R381 vdd.n157 vdd.n18 1.66843
|
||||
R382 vdd.n155 vdd.n19 1.66843
|
||||
R383 vdd.n135 vdd.n134 1.66843
|
||||
R384 vdd.n80 vdd.n79 1.66843
|
||||
R385 vdd.n99 vdd.n98 1.66843
|
||||
R386 vdd.n115 vdd.n114 1.66843
|
||||
R387 vdd.n127 vdd.n126 1.66843
|
||||
R388 vdd.n151 vdd.n150 1.66843
|
||||
R389 vdd.n153 vdd.n20 1.66843
|
||||
R390 vdd.n152 vdd.n151 1.52562
|
||||
R391 vdd.n153 vdd.n152 1.2834
|
||||
R392 vdd.n86 vdd.n5 1.27296
|
||||
R393 vdd.n86 vdd.n85 1.21158
|
||||
R394 vdd.n64 vdd.n63 1.1005
|
||||
R395 vdd.n54 vdd.n53 1.1005
|
||||
R396 vdd.n44 vdd.n43 1.1005
|
||||
R397 vdd.n34 vdd.n33 1.1005
|
||||
R398 vdd.n10 vdd.n1 1.1005
|
||||
R399 vdd.n171 vdd.n170 1.1005
|
||||
R400 vdd.n144 vdd.n143 1.1005
|
||||
R401 vdd.n120 vdd.n0 1.1005
|
||||
R402 vdd.n108 vdd.n107 1.1005
|
||||
R403 vdd.n106 vdd.n105 1.1005
|
||||
R404 vdd.n73 vdd.n65 1.1005
|
||||
R405 vdd.n142 vdd.n141 1.1005
|
||||
R406 vdd.n214 vdd.n172 1.1005
|
||||
R407 vdd.n251 vdd.n250 1.1005
|
||||
R408 vdd.n127 vdd.n85 1.0667
|
||||
R409 vdd.n163 vdd.n5 0.897218
|
||||
R410 vdd.n130 vdd.n129 0.740086
|
||||
R411 vdd.n129 vdd.n85 0.513736
|
||||
R412 vdd.n6 vdd.n5 0.434488
|
||||
R413 vdd.n134 vdd.n21 0.405564
|
||||
R414 vdd.n127 vdd.n116 0.338749
|
||||
R415 vdd.n163 vdd.n162 0.338361
|
||||
R416 vdd.n115 vdd.n88 0.332914
|
||||
R417 vdd.n98 vdd.n96 0.328172
|
||||
R418 vdd.n159 vdd.n158 0.327784
|
||||
R419 vdd.n133 vdd.n80 0.322902
|
||||
R420 vdd.n155 vdd.n154 0.317207
|
||||
R421 vdd.n161 vdd.n160 0.30387
|
||||
R422 vdd.n157 vdd.n156 0.29911
|
||||
R423 vdd.n156 vdd.n155 0.273116
|
||||
R424 vdd.n154 vdd.n153 0.272784
|
||||
R425 vdd.n160 vdd.n159 0.268235
|
||||
R426 vdd.n134 vdd.n133 0.267129
|
||||
R427 vdd.n158 vdd.n157 0.262207
|
||||
R428 vdd.n96 vdd.n80 0.261823
|
||||
R429 vdd.n98 vdd.n88 0.257063
|
||||
R430 vdd.n162 vdd.n161 0.25163
|
||||
R431 vdd.n116 vdd.n115 0.251246
|
||||
R432 vdd.n143 vdd.n64 0.245476
|
||||
R433 vdd.n172 vdd.n171 0.223305
|
||||
R434 vdd.n130 vdd.n6 0.187367
|
||||
R435 vdd.n151 vdd.n21 0.179715
|
||||
R436 vdd.n252 vdd.n0 0.142854
|
||||
R437 vdd.n223 vdd.n222 0.0965
|
||||
R438 vdd.n223 vdd.n182 0.0965
|
||||
R439 vdd.n229 vdd.n182 0.0965
|
||||
R440 vdd.n230 vdd.n229 0.0965
|
||||
R441 vdd.n230 vdd.n180 0.0965
|
||||
R442 vdd.n236 vdd.n180 0.0965
|
||||
R443 vdd.n237 vdd.n236 0.0965
|
||||
R444 vdd.n237 vdd.n177 0.0965
|
||||
R445 vdd.n242 vdd.n177 0.0965
|
||||
R446 vdd.n210 vdd.n184 0.0965
|
||||
R447 vdd.n205 vdd.n184 0.0965
|
||||
R448 vdd.n205 vdd.n204 0.0965
|
||||
R449 vdd.n204 vdd.n202 0.0965
|
||||
R450 vdd.n202 vdd.n200 0.0965
|
||||
R451 vdd.n200 vdd.n198 0.0965
|
||||
R452 vdd.n198 vdd.n196 0.0965
|
||||
R453 vdd.n196 vdd.n194 0.0965
|
||||
R454 vdd.n194 vdd.n176 0.0965
|
||||
R455 vdd.n152 vdd.n6 0.0898978
|
||||
R456 vdd.n203 vdd.n186 0.083
|
||||
R457 vdd.n197 vdd.n188 0.083
|
||||
R458 vdd.n228 vdd.n227 0.083
|
||||
R459 vdd.n235 vdd.n179 0.083
|
||||
R460 vdd.n252 vdd.n251 0.0809512
|
||||
R461 vdd.n201 vdd.n192 0.0721377
|
||||
R462 vdd.n199 vdd.n187 0.0721377
|
||||
R463 vdd.n231 vdd.n181 0.0721377
|
||||
R464 vdd.n234 vdd.n233 0.0721377
|
||||
R465 vdd.n207 vdd.n185 0.0705
|
||||
R466 vdd.n193 vdd.n190 0.0705
|
||||
R467 vdd.n225 vdd.n224 0.0705
|
||||
R468 vdd.n240 vdd.n239 0.0705
|
||||
R469 vdd.n209 vdd.n185 0.0621377
|
||||
R470 vdd.n193 vdd.n189 0.0621377
|
||||
R471 vdd.n224 vdd.n183 0.0621377
|
||||
R472 vdd.n241 vdd.n240 0.0621377
|
||||
R473 vdd.n248 vdd.n175 0.0608429
|
||||
R474 vdd.n247 vdd.n246 0.0608429
|
||||
R475 vdd.n218 vdd.n213 0.0608429
|
||||
R476 vdd.n217 vdd.n216 0.0608429
|
||||
R477 vdd.n168 vdd.n4 0.0608429
|
||||
R478 vdd.n167 vdd.n166 0.0608429
|
||||
R479 vdd.n13 vdd.n12 0.0608429
|
||||
R480 vdd.n14 vdd.n9 0.0608429
|
||||
R481 vdd.n31 vdd.n27 0.0608429
|
||||
R482 vdd.n30 vdd.n29 0.0608429
|
||||
R483 vdd.n41 vdd.n37 0.0608429
|
||||
R484 vdd.n40 vdd.n39 0.0608429
|
||||
R485 vdd.n51 vdd.n47 0.0608429
|
||||
R486 vdd.n50 vdd.n49 0.0608429
|
||||
R487 vdd.n139 vdd.n68 0.0608429
|
||||
R488 vdd.n138 vdd.n137 0.0608429
|
||||
R489 vdd.n76 vdd.n75 0.0608429
|
||||
R490 vdd.n77 vdd.n72 0.0608429
|
||||
R491 vdd.n103 vdd.n95 0.0608429
|
||||
R492 vdd.n102 vdd.n101 0.0608429
|
||||
R493 vdd.n111 vdd.n110 0.0608429
|
||||
R494 vdd.n112 vdd.n92 0.0608429
|
||||
R495 vdd.n123 vdd.n122 0.0608429
|
||||
R496 vdd.n124 vdd.n119 0.0608429
|
||||
R497 vdd.n147 vdd.n146 0.0608429
|
||||
R498 vdd.n148 vdd.n24 0.0608429
|
||||
R499 vdd.n60 vdd.n59 0.0608429
|
||||
R500 vdd.n61 vdd.n57 0.0608429
|
||||
R501 vdd.n201 vdd.n191 0.0605
|
||||
R502 vdd.n199 vdd.n191 0.0605
|
||||
R503 vdd.n232 vdd.n231 0.0605
|
||||
R504 vdd.n233 vdd.n232 0.0605
|
||||
R505 vdd.n251 vdd.n172 0.0577927
|
||||
R506 vdd.n207 vdd.n206 0.0505
|
||||
R507 vdd.n195 vdd.n190 0.0505
|
||||
R508 vdd.n226 vdd.n225 0.0505
|
||||
R509 vdd.n239 vdd.n238 0.0505
|
||||
R510 vdd.n203 vdd.n192 0.0496377
|
||||
R511 vdd.n197 vdd.n187 0.0496377
|
||||
R512 vdd.n228 vdd.n181 0.0496377
|
||||
R513 vdd.n235 vdd.n234 0.0496377
|
||||
R514 vdd.n206 vdd.n186 0.038
|
||||
R515 vdd.n195 vdd.n188 0.038
|
||||
R516 vdd.n227 vdd.n226 0.038
|
||||
R517 vdd.n238 vdd.n179 0.038
|
||||
R518 vdd.n249 vdd.n248 0.0308751
|
||||
R519 vdd.n175 vdd.n173 0.0308751
|
||||
R520 vdd.n217 vdd.n212 0.0308751
|
||||
R521 vdd.n216 vdd.n215 0.0308751
|
||||
R522 vdd.n4 vdd.n2 0.0308751
|
||||
R523 vdd.n169 vdd.n168 0.0308751
|
||||
R524 vdd.n12 vdd.n11 0.0308751
|
||||
R525 vdd.n13 vdd.n8 0.0308751
|
||||
R526 vdd.n27 vdd.n25 0.0308751
|
||||
R527 vdd.n32 vdd.n31 0.0308751
|
||||
R528 vdd.n37 vdd.n35 0.0308751
|
||||
R529 vdd.n42 vdd.n41 0.0308751
|
||||
R530 vdd.n47 vdd.n45 0.0308751
|
||||
R531 vdd.n52 vdd.n51 0.0308751
|
||||
R532 vdd.n68 vdd.n66 0.0308751
|
||||
R533 vdd.n140 vdd.n139 0.0308751
|
||||
R534 vdd.n75 vdd.n74 0.0308751
|
||||
R535 vdd.n76 vdd.n71 0.0308751
|
||||
R536 vdd.n95 vdd.n93 0.0308751
|
||||
R537 vdd.n104 vdd.n103 0.0308751
|
||||
R538 vdd.n110 vdd.n109 0.0308751
|
||||
R539 vdd.n111 vdd.n91 0.0308751
|
||||
R540 vdd.n122 vdd.n121 0.0308751
|
||||
R541 vdd.n123 vdd.n118 0.0308751
|
||||
R542 vdd.n146 vdd.n145 0.0308751
|
||||
R543 vdd.n147 vdd.n23 0.0308751
|
||||
R544 vdd.n57 vdd.n55 0.0308751
|
||||
R545 vdd.n62 vdd.n61 0.0308751
|
||||
R546 vdd.n247 vdd.n174 0.0307722
|
||||
R547 vdd.n246 vdd.n245 0.0307722
|
||||
R548 vdd.n219 vdd.n218 0.0307722
|
||||
R549 vdd.n213 vdd.n211 0.0307722
|
||||
R550 vdd.n166 vdd.n165 0.0307722
|
||||
R551 vdd.n167 vdd.n3 0.0307722
|
||||
R552 vdd.n9 vdd.n7 0.0307722
|
||||
R553 vdd.n15 vdd.n14 0.0307722
|
||||
R554 vdd.n29 vdd.n28 0.0307722
|
||||
R555 vdd.n30 vdd.n26 0.0307722
|
||||
R556 vdd.n39 vdd.n38 0.0307722
|
||||
R557 vdd.n40 vdd.n36 0.0307722
|
||||
R558 vdd.n49 vdd.n48 0.0307722
|
||||
R559 vdd.n50 vdd.n46 0.0307722
|
||||
R560 vdd.n137 vdd.n136 0.0307722
|
||||
R561 vdd.n138 vdd.n67 0.0307722
|
||||
R562 vdd.n72 vdd.n70 0.0307722
|
||||
R563 vdd.n78 vdd.n77 0.0307722
|
||||
R564 vdd.n101 vdd.n100 0.0307722
|
||||
R565 vdd.n102 vdd.n94 0.0307722
|
||||
R566 vdd.n92 vdd.n90 0.0307722
|
||||
R567 vdd.n113 vdd.n112 0.0307722
|
||||
R568 vdd.n119 vdd.n117 0.0307722
|
||||
R569 vdd.n125 vdd.n124 0.0307722
|
||||
R570 vdd.n24 vdd.n22 0.0307722
|
||||
R571 vdd.n149 vdd.n148 0.0307722
|
||||
R572 vdd.n59 vdd.n58 0.0307722
|
||||
R573 vdd.n60 vdd.n56 0.0307722
|
||||
R574 vdd.n64 vdd.n54 0.0235488
|
||||
R575 vdd.n54 vdd.n44 0.0235488
|
||||
R576 vdd.n44 vdd.n34 0.0235488
|
||||
R577 vdd.n34 vdd.n1 0.0235488
|
||||
R578 vdd.n171 vdd.n1 0.0235488
|
||||
R579 vdd.n143 vdd.n142 0.0235488
|
||||
R580 vdd.n142 vdd.n65 0.0235488
|
||||
R581 vdd.n106 vdd.n65 0.0235488
|
||||
R582 vdd.n107 vdd.n106 0.0235488
|
||||
R583 vdd.n107 vdd.n0 0.0235488
|
||||
R584 vdd.n131 vdd.n130 0.00773882
|
||||
R585 vdd vdd.n252 0.00527439
|
||||
R586 vdd.n87 vdd.n6 0.00166667
|
||||
R587 vdd.n129 vdd.n87 0.00133332
|
||||
R588 vdd.n69 vdd.n6 0.001
|
||||
R589 vdd.n132 vdd.n81 0.001
|
||||
R590 vdd.n97 vdd.n84 0.001
|
||||
R591 vdd.n89 vdd.n83 0.001
|
||||
R592 vdd.n128 vdd.n82 0.001
|
||||
R593 vdd.n129 vdd.n128 0.001
|
||||
R594 vdd.n89 vdd.n82 0.001
|
||||
R595 vdd.n97 vdd.n83 0.001
|
||||
R596 vdd.n84 vdd.n81 0.001
|
||||
R597 vdd.n132 vdd.n69 0.001
|
||||
R598 gnd.n82 gnd.n81 2794.14
|
||||
R599 gnd.n12 gnd.n11 17.0005
|
||||
R600 gnd.n74 gnd.n64 17.0005
|
||||
R601 gnd.n65 gnd.n64 17.0005
|
||||
R602 gnd.n73 gnd.n64 17.0005
|
||||
R603 gnd.n66 gnd.n64 17.0005
|
||||
R604 gnd.n72 gnd.n64 17.0005
|
||||
R605 gnd.n67 gnd.n64 17.0005
|
||||
R606 gnd.n71 gnd.n64 17.0005
|
||||
R607 gnd.n68 gnd.n64 17.0005
|
||||
R608 gnd.n70 gnd.n64 17.0005
|
||||
R609 gnd.n69 gnd.n64 17.0005
|
||||
R610 gnd.n76 gnd.n64 17.0005
|
||||
R611 gnd.n75 gnd.n74 17.0005
|
||||
R612 gnd.n75 gnd.n65 17.0005
|
||||
R613 gnd.n75 gnd.n73 17.0005
|
||||
R614 gnd.n75 gnd.n66 17.0005
|
||||
R615 gnd.n75 gnd.n72 17.0005
|
||||
R616 gnd.n75 gnd.n67 17.0005
|
||||
R617 gnd.n75 gnd.n71 17.0005
|
||||
R618 gnd.n75 gnd.n68 17.0005
|
||||
R619 gnd.n75 gnd.n70 17.0005
|
||||
R620 gnd.n75 gnd.n69 17.0005
|
||||
R621 gnd.n76 gnd.n75 17.0005
|
||||
R622 gnd.n35 gnd.n34 17.0005
|
||||
R623 gnd.n34 gnd.n33 17.0005
|
||||
R624 gnd.n81 gnd.n53 17.0005
|
||||
R625 gnd.n81 gnd.n54 17.0005
|
||||
R626 gnd.n81 gnd.n55 17.0005
|
||||
R627 gnd.n81 gnd.n56 17.0005
|
||||
R628 gnd.n81 gnd.n57 17.0005
|
||||
R629 gnd.n81 gnd.n58 17.0005
|
||||
R630 gnd.n81 gnd.n59 17.0005
|
||||
R631 gnd.n81 gnd.n60 17.0005
|
||||
R632 gnd.n81 gnd.n61 17.0005
|
||||
R633 gnd.n81 gnd.n62 17.0005
|
||||
R634 gnd.n124 gnd.n108 17.0005
|
||||
R635 gnd.n109 gnd.n108 17.0005
|
||||
R636 gnd.n122 gnd.n108 17.0005
|
||||
R637 gnd.n110 gnd.n108 17.0005
|
||||
R638 gnd.n121 gnd.n108 17.0005
|
||||
R639 gnd.n111 gnd.n108 17.0005
|
||||
R640 gnd.n120 gnd.n108 17.0005
|
||||
R641 gnd.n112 gnd.n108 17.0005
|
||||
R642 gnd.n119 gnd.n108 17.0005
|
||||
R643 gnd.n113 gnd.n108 17.0005
|
||||
R644 gnd.n118 gnd.n108 17.0005
|
||||
R645 gnd.n124 gnd.n123 17.0005
|
||||
R646 gnd.n123 gnd.n109 17.0005
|
||||
R647 gnd.n123 gnd.n122 17.0005
|
||||
R648 gnd.n123 gnd.n110 17.0005
|
||||
R649 gnd.n123 gnd.n121 17.0005
|
||||
R650 gnd.n123 gnd.n111 17.0005
|
||||
R651 gnd.n123 gnd.n120 17.0005
|
||||
R652 gnd.n123 gnd.n112 17.0005
|
||||
R653 gnd.n123 gnd.n119 17.0005
|
||||
R654 gnd.n123 gnd.n113 17.0005
|
||||
R655 gnd.n123 gnd.n118 17.0005
|
||||
R656 gnd.n126 gnd.n85 17.0005
|
||||
R657 gnd.n126 gnd.n86 17.0005
|
||||
R658 gnd.n126 gnd.n87 17.0005
|
||||
R659 gnd.n126 gnd.n88 17.0005
|
||||
R660 gnd.n126 gnd.n89 17.0005
|
||||
R661 gnd.n126 gnd.n90 17.0005
|
||||
R662 gnd.n126 gnd.n91 17.0005
|
||||
R663 gnd.n126 gnd.n92 17.0005
|
||||
R664 gnd.n126 gnd.n93 17.0005
|
||||
R665 gnd.n126 gnd.n94 17.0005
|
||||
R666 gnd.n10 gnd.n9 15.0005
|
||||
R667 gnd.n78 gnd.n77 15.0005
|
||||
R668 gnd.n32 gnd.n31 15.0005
|
||||
R669 gnd.n116 gnd.n115 15.0005
|
||||
R670 gnd.n101 gnd.n19 8.501
|
||||
R671 gnd.n101 gnd.n95 8.501
|
||||
R672 gnd.n101 gnd.n100 8.501
|
||||
R673 gnd.n101 gnd.n99 8.501
|
||||
R674 gnd.n102 gnd.n101 8.501
|
||||
R675 gnd.n28 gnd.n24 8.49127
|
||||
R676 gnd.n28 gnd.n27 8.49127
|
||||
R677 gnd.n29 gnd.n28 8.49127
|
||||
R678 gnd.n34 gnd.n25 8.49127
|
||||
R679 gnd.n34 gnd.n26 8.49127
|
||||
R680 gnd.n15 gnd.n14 8.49123
|
||||
R681 gnd.n14 gnd.n7 8.49123
|
||||
R682 gnd.n14 gnd.n13 8.49123
|
||||
R683 gnd.n11 gnd.n6 8.49123
|
||||
R684 gnd.n11 gnd.n8 8.49123
|
||||
R685 gnd.n104 gnd.n103 8.48464
|
||||
R686 gnd.n107 gnd.n96 8.46519
|
||||
R687 gnd.n106 gnd.n97 8.46519
|
||||
R688 gnd.n105 gnd.n98 8.46519
|
||||
R689 gnd.n126 gnd.n18 8.34456
|
||||
R690 gnd.n101 gnd.n82 6.02053
|
||||
R691 gnd.n45 gnd.n44 5.48318
|
||||
R692 gnd.n129 gnd.n128 5.48318
|
||||
R693 gnd.n41 gnd.n40 5.47768
|
||||
R694 gnd.n51 gnd.n50 5.47768
|
||||
R695 gnd.n14 gnd.n5 3.4169
|
||||
R696 gnd.n28 gnd.n23 3.4022
|
||||
R697 gnd.n34 gnd.n23 3.40192
|
||||
R698 gnd.n126 gnd.n125 3.3033
|
||||
R699 gnd.n126 gnd.n84 3.29867
|
||||
R700 gnd.n127 gnd.n126 3.29859
|
||||
R701 gnd.n81 gnd.n80 3.29855
|
||||
R702 gnd.n81 gnd.n21 3.29832
|
||||
R703 gnd.n126 gnd.n3 3.28305
|
||||
R704 gnd.n81 gnd.n22 3.28288
|
||||
R705 gnd.n11 gnd.n5 2.82281
|
||||
R706 gnd.n126 gnd.n83 2.69969
|
||||
R707 gnd.n81 gnd.n20 2.6991
|
||||
R708 gnd.n126 gnd.n17 1.94103
|
||||
R709 gnd.n81 gnd.n37 1.94046
|
||||
R710 gnd.n126 gnd.n82 1.53748
|
||||
R711 gnd.n52 gnd.n51 1.20601
|
||||
R712 gnd.n50 gnd.n43 1.10932
|
||||
R713 gnd.n45 gnd.n0 1.10932
|
||||
R714 gnd.n42 gnd.n41 1.10932
|
||||
R715 gnd.n130 gnd.n129 1.10932
|
||||
R716 gnd.n2 gnd.n1 1.1005
|
||||
R717 gnd.n39 gnd.n38 1.1005
|
||||
R718 gnd.n47 gnd.n46 1.1005
|
||||
R719 gnd.n49 gnd.n48 1.1005
|
||||
R720 gnd.n81 gnd.n52 0.846373
|
||||
R721 gnd.n74 gnd.n52 0.816125
|
||||
R722 gnd.n40 gnd.n17 0.552785
|
||||
R723 gnd.n51 gnd.n37 0.550694
|
||||
R724 gnd.n17 gnd.n16 0.539211
|
||||
R725 gnd.n37 gnd.n36 0.520006
|
||||
R726 gnd.n125 gnd.n107 0.470337
|
||||
R727 gnd.n30 gnd.n20 0.445273
|
||||
R728 gnd.n83 gnd.n4 0.444434
|
||||
R729 gnd.n36 gnd.n22 0.438499
|
||||
R730 gnd.n114 gnd.n83 0.420793
|
||||
R731 gnd.n63 gnd.n20 0.419889
|
||||
R732 gnd.n16 gnd.n3 0.418292
|
||||
R733 gnd.n44 gnd.n21 0.408383
|
||||
R734 gnd.n128 gnd.n127 0.407974
|
||||
R735 gnd.n40 gnd.n18 0.395917
|
||||
R736 gnd.n43 gnd.n42 0.37285
|
||||
R737 gnd.n104 gnd.n18 0.347109
|
||||
R738 gnd.n80 gnd.n63 0.343886
|
||||
R739 gnd.n114 gnd.n84 0.343268
|
||||
R740 gnd.n127 gnd.n4 0.318914
|
||||
R741 gnd.n30 gnd.n21 0.318498
|
||||
R742 gnd.n44 gnd.n22 0.306266
|
||||
R743 gnd.n128 gnd.n3 0.305337
|
||||
R744 gnd.n117 gnd.n84 0.294788
|
||||
R745 gnd.n80 gnd.n79 0.294146
|
||||
R746 gnd.n106 gnd.n105 0.288586
|
||||
R747 gnd.n107 gnd.n106 0.288586
|
||||
R748 gnd.n105 gnd.n104 0.249692
|
||||
R749 gnd.n33 gnd.n32 0.247403
|
||||
R750 gnd.n125 gnd.n124 0.244402
|
||||
R751 gnd.n12 gnd.n10 0.24324
|
||||
R752 gnd.n10 gnd.n4 0.227375
|
||||
R753 gnd.n79 gnd.n78 0.227375
|
||||
R754 gnd.n78 gnd.n63 0.227375
|
||||
R755 gnd.n32 gnd.n30 0.227375
|
||||
R756 gnd.n117 gnd.n116 0.227375
|
||||
R757 gnd.n116 gnd.n114 0.227375
|
||||
R758 gnd.n131 gnd.n130 0.17199
|
||||
R759 gnd.n36 gnd.n23 0.0828779
|
||||
R760 gnd.n16 gnd.n5 0.0744717
|
||||
R761 gnd.n7 gnd.n6 0.0405896
|
||||
R762 gnd.n13 gnd.n8 0.0405896
|
||||
R763 gnd.n15 gnd.n6 0.0405896
|
||||
R764 gnd.n8 gnd.n7 0.0405896
|
||||
R765 gnd.n27 gnd.n25 0.0404028
|
||||
R766 gnd.n29 gnd.n26 0.0404028
|
||||
R767 gnd.n25 gnd.n24 0.0404028
|
||||
R768 gnd.n27 gnd.n26 0.0404028
|
||||
R769 gnd.n74 gnd.n53 0.0275956
|
||||
R770 gnd.n124 gnd.n94 0.0275956
|
||||
R771 gnd.n65 gnd.n54 0.0267868
|
||||
R772 gnd.n109 gnd.n93 0.0267868
|
||||
R773 gnd.n73 gnd.n55 0.0259779
|
||||
R774 gnd.n122 gnd.n92 0.0259779
|
||||
R775 gnd.n66 gnd.n56 0.0247647
|
||||
R776 gnd.n110 gnd.n91 0.0247647
|
||||
R777 gnd.n131 gnd.n0 0.02459
|
||||
R778 gnd.n72 gnd.n57 0.0239559
|
||||
R779 gnd.n121 gnd.n90 0.0239559
|
||||
R780 gnd.n67 gnd.n58 0.0231471
|
||||
R781 gnd.n111 gnd.n89 0.0231471
|
||||
R782 gnd.n49 gnd.n46 0.023
|
||||
R783 gnd.n39 gnd.n2 0.023
|
||||
R784 gnd.n71 gnd.n59 0.0223382
|
||||
R785 gnd.n120 gnd.n88 0.0223382
|
||||
R786 gnd.n68 gnd.n60 0.021125
|
||||
R787 gnd.n112 gnd.n87 0.021125
|
||||
R788 gnd.n16 gnd.n15 0.0205448
|
||||
R789 gnd.n13 gnd.n12 0.0205448
|
||||
R790 gnd.n35 gnd.n24 0.0204514
|
||||
R791 gnd.n33 gnd.n29 0.0204514
|
||||
R792 gnd.n70 gnd.n61 0.0203162
|
||||
R793 gnd.n119 gnd.n86 0.0203162
|
||||
R794 gnd.n69 gnd.n62 0.0195074
|
||||
R795 gnd.n113 gnd.n85 0.0195074
|
||||
R796 gnd.n38 gnd.n1 0.01425
|
||||
R797 gnd.n48 gnd.n47 0.01425
|
||||
R798 gnd.n79 gnd.n76 0.0126324
|
||||
R799 gnd.n118 gnd.n117 0.0126324
|
||||
R800 gnd.n76 gnd.n62 0.0114191
|
||||
R801 gnd.n118 gnd.n85 0.0114191
|
||||
R802 gnd.n42 gnd.n38 0.01128
|
||||
R803 gnd.n130 gnd.n1 0.01128
|
||||
R804 gnd.n48 gnd.n43 0.01128
|
||||
R805 gnd.n47 gnd.n0 0.01128
|
||||
R806 gnd.n69 gnd.n61 0.0106103
|
||||
R807 gnd.n113 gnd.n86 0.0106103
|
||||
R808 gnd.n70 gnd.n60 0.00980147
|
||||
R809 gnd.n119 gnd.n87 0.00980147
|
||||
R810 gnd.n50 gnd.n49 0.00932
|
||||
R811 gnd.n46 gnd.n45 0.00932
|
||||
R812 gnd.n41 gnd.n39 0.00932
|
||||
R813 gnd.n129 gnd.n2 0.00932
|
||||
R814 gnd.n68 gnd.n59 0.00858823
|
||||
R815 gnd.n112 gnd.n88 0.00858823
|
||||
R816 gnd.n71 gnd.n58 0.00777941
|
||||
R817 gnd.n120 gnd.n89 0.00777941
|
||||
R818 gnd.n67 gnd.n57 0.00697059
|
||||
R819 gnd.n111 gnd.n90 0.00697059
|
||||
R820 gnd.n72 gnd.n56 0.00616176
|
||||
R821 gnd.n121 gnd.n91 0.00616176
|
||||
R822 gnd.n36 gnd.n35 0.00576316
|
||||
R823 gnd.n66 gnd.n55 0.00494853
|
||||
R824 gnd.n110 gnd.n92 0.00494853
|
||||
R825 gnd.n73 gnd.n54 0.00413971
|
||||
R826 gnd.n122 gnd.n93 0.00413971
|
||||
R827 gnd.n65 gnd.n53 0.00333088
|
||||
R828 gnd.n109 gnd.n94 0.00333088
|
||||
R829 gnd.n131 gnd 0.0014625
|
||||
R830 gnd.n126 gnd.n19 0.001
|
||||
R831 gnd.n103 gnd.n102 0.001
|
||||
R832 gnd.n99 gnd.n98 0.001
|
||||
R833 gnd.n100 gnd.n97 0.001
|
||||
R834 gnd.n96 gnd.n95 0.001
|
||||
R835 gnd.n103 gnd.n19 0.001
|
||||
R836 gnd.n126 gnd.n95 0.001
|
||||
R837 gnd.n100 gnd.n96 0.001
|
||||
R838 gnd.n99 gnd.n97 0.001
|
||||
R839 gnd.n102 gnd.n98 0.001
|
||||
C37 vbias gnd 2.83431f
|
||||
C38 clk gnd 7.89606f
|
||||
C39 out+ gnd 2.36194f
|
||||
C40 out- gnd 2.35875f
|
||||
C41 V+ gnd 3.9126f
|
||||
C42 V- gnd 3.93119f
|
||||
C43 vdd gnd 17.9739f
|
||||
C44 a_1752_817# gnd 0.44266f $ **FLOATING
|
||||
C45 a_944_1911# gnd 4.28617f $ **FLOATING
|
||||
C46 a_687_2445# gnd 4.01269f $ **FLOATING
|
||||
C47 a_1245_3300# gnd 1.43203f $ **FLOATING
|
||||
.ends
|
||||
\\"
|
||||
"
|
||||
}
|
||||
V {}
|
||||
S {}
|
||||
E {}
|
||||
L 4 -130 -100 130 0 {}
|
||||
L 4 -130 100 130 0 {}
|
||||
L 4 -130 -100 -130 100 {}
|
||||
L 4 -150 0 -130 0 {}
|
||||
L 4 -150 -60 -130 -60 {}
|
||||
L 4 -150 60 -130 60 {}
|
||||
L 4 110 10 130 10 {}
|
||||
L 4 110 -10 130 -10 {}
|
||||
L 4 -20 60 -20 80 {}
|
||||
L 7 -70 -100 -70 -80 {}
|
||||
L 7 -70 80 -70 100 {}
|
||||
B 5 -72.5 -102.5 -67.5 -97.5 {name=vdd dir=inout}
|
||||
B 5 -152.5 -2.5 -147.5 2.5 {name=vbias dir=in}
|
||||
B 5 -152.5 -62.5 -147.5 -57.5 {name=v+ dir=in}
|
||||
B 5 -152.5 57.5 -147.5 62.5 {name=v- dir=in}
|
||||
B 5 127.5 7.5 132.5 12.5 {name=out- dir=out}
|
||||
B 5 127.5 -12.5 132.5 -7.5 {name=out+ dir=out}
|
||||
B 5 -22.5 77.5 -17.5 82.5 {name=clk dir=in}
|
||||
B 5 -72.5 97.5 -67.5 102.5 {name=gnd dir=inout}
|
||||
T {@symname} -89 -6 0 0 0.3 0.3 {}
|
||||
T {@name} 25 -52 0 0 0.2 0.2 {}
|
||||
T {vdd} -74 -75 3 1 0.2 0.2 {}
|
||||
T {vbias} -125 -4 0 0 0.2 0.2 {}
|
||||
T {v+} -125 -64 0 0 0.2 0.2 {}
|
||||
T {v-} -125 56 0 0 0.2 0.2 {}
|
||||
T {out-} 90 1 0 1 0.2 0.2 {}
|
||||
T {out+} 95 -14 0 1 0.2 0.2 {}
|
||||
T {clk} -24 55 3 0 0.2 0.2 {}
|
||||
T {gnd} -66 75 1 1 0.2 0.2 {}
|
||||
|
|
@ -1,284 +0,0 @@
|
|||
v {xschem version=3.4.6 file_version=1.2}
|
||||
G {}
|
||||
K {}
|
||||
V {}
|
||||
S {}
|
||||
E {}
|
||||
N 490 -650 490 -600 {
|
||||
lab=#net1}
|
||||
N 810 -650 810 -600 {
|
||||
lab=#net1}
|
||||
N 1060 -470 1060 -450 {
|
||||
lab=out-}
|
||||
N 980 -530 1020 -530 {
|
||||
lab=#net2}
|
||||
N 980 -470 980 -420 {
|
||||
lab=#net2}
|
||||
N 980 -420 1020 -420 {
|
||||
lab=#net2}
|
||||
N 810 -540 810 -470 {
|
||||
lab=#net2}
|
||||
N 810 -470 980 -470 {
|
||||
lab=#net2}
|
||||
N 980 -530 980 -470 {
|
||||
lab=#net2}
|
||||
N 720 -270 720 -230 {
|
||||
lab=#net2}
|
||||
N 810 -270 900 -270 {
|
||||
lab=#net2}
|
||||
N 900 -270 900 -230 {
|
||||
lab=#net2}
|
||||
N 810 -470 810 -270 {
|
||||
lab=#net2}
|
||||
N 720 -270 810 -270 {
|
||||
lab=#net2}
|
||||
N 900 -170 900 -130 {
|
||||
lab=gnd}
|
||||
N 720 -170 720 -130 {
|
||||
lab=gnd}
|
||||
N 400 -270 400 -230 {
|
||||
lab=#net3}
|
||||
N 490 -270 580 -270 {
|
||||
lab=#net3}
|
||||
N 580 -270 580 -230 {
|
||||
lab=#net3}
|
||||
N 400 -270 490 -270 {
|
||||
lab=#net3}
|
||||
N 580 -170 580 -130 {
|
||||
lab=gnd}
|
||||
N 400 -170 400 -130 {
|
||||
lab=gnd}
|
||||
N 650 -650 810 -650 {
|
||||
lab=#net1}
|
||||
N 650 -710 650 -650 {
|
||||
lab=#net1}
|
||||
N 490 -650 650 -650 {
|
||||
lab=#net1}
|
||||
N 320 -470 490 -470 {
|
||||
lab=#net3}
|
||||
N 490 -470 490 -270 {
|
||||
lab=#net3}
|
||||
N 490 -540 490 -470 {
|
||||
lab=#net3}
|
||||
N 240 -470 240 -450 {
|
||||
lab=out+}
|
||||
N 280 -530 320 -530 {
|
||||
lab=#net3}
|
||||
N 320 -470 320 -420 {
|
||||
lab=#net3}
|
||||
N 280 -420 320 -420 {
|
||||
lab=#net3}
|
||||
N 320 -530 320 -470 {
|
||||
lab=#net3}
|
||||
N 650 -930 1060 -930 {
|
||||
lab=vdd}
|
||||
N 240 -130 400 -130 {
|
||||
lab=gnd}
|
||||
N 580 -130 720 -130 {
|
||||
lab=gnd}
|
||||
N 900 -130 1060 -130 {
|
||||
lab=gnd}
|
||||
N 490 -470 680 -200 {
|
||||
lab=#net3}
|
||||
N 620 -200 810 -470 {
|
||||
lab=#net2}
|
||||
N 140 -470 240 -470 {
|
||||
lab=out+}
|
||||
N 240 -500 240 -470 {
|
||||
lab=out+}
|
||||
N 1060 -470 1160 -470 {
|
||||
lab=out-}
|
||||
N 1060 -500 1060 -470 {
|
||||
lab=out-}
|
||||
N 340 -200 360 -200 {
|
||||
lab=clk}
|
||||
N 440 -570 450 -570 {
|
||||
lab=v+}
|
||||
N 850 -570 860 -570 {
|
||||
lab=v-}
|
||||
N 720 -130 900 -130 {
|
||||
lab=gnd}
|
||||
N 400 -130 580 -130 {
|
||||
lab=gnd}
|
||||
N 940 -200 960 -200 {
|
||||
lab=clk}
|
||||
N 1500 -340 1500 -320 {lab=well}
|
||||
N 1500 -260 1500 -240 {lab=vdd}
|
||||
N 490 -570 810 -570 {
|
||||
lab=well}
|
||||
N 1240 -360 1240 -330 {lab=gnd}
|
||||
N 1240 -360 1280 -360 {lab=gnd}
|
||||
N 1280 -360 1280 -240 {lab=gnd}
|
||||
N 1240 -240 1280 -240 {lab=gnd}
|
||||
N 1240 -270 1240 -240 {lab=gnd}
|
||||
N 1190 -300 1240 -300 {lab=sub}
|
||||
N 1370 -270 1370 -250 {lab=gnd}
|
||||
N 400 -200 580 -200 {
|
||||
lab=sub}
|
||||
N 720 -200 900 -200 {
|
||||
lab=sub}
|
||||
N 240 -390 240 -130 {lab=gnd}
|
||||
N 1370 -340 1370 -330 {lab=sub}
|
||||
N 1060 -420 1110 -420 {lab=sub}
|
||||
N 190 -420 240 -420 {lab=sub}
|
||||
N 1060 -390 1060 -130 {lab=gnd}
|
||||
N 1060 -930 1060 -560 {lab=vdd}
|
||||
N 240 -930 240 -560 {lab=vdd}
|
||||
N 1060 -530 1110 -530 {lab=well}
|
||||
N 190 -530 240 -530 {lab=well}
|
||||
N 650 -810 650 -770 {lab=#net4}
|
||||
N 650 -930 650 -870 {lab=vdd}
|
||||
N 240 -930 650 -930 {
|
||||
lab=vdd}
|
||||
N 340 -740 340 -200 {lab=clk}
|
||||
N 330 -200 340 -200 {
|
||||
lab=clk}
|
||||
N 340 -740 610 -740 {lab=clk}
|
||||
N 580 -840 610 -840 {lab=vbias}
|
||||
N 650 -740 710 -740 {lab=well}
|
||||
N 650 -840 710 -840 {lab=well}
|
||||
N 710 -840 710 -740 {lab=well}
|
||||
C {iopin.sym} 1060 -930 0 0 {name=p1 lab=vdd}
|
||||
C {iopin.sym} 1060 -130 0 0 {name=p2 lab=gnd}
|
||||
C {ipin.sym} 440 -570 0 0 {name=p3 lab=v+}
|
||||
C {ipin.sym} 860 -570 0 1 {name=p4 lab=v-}
|
||||
C {ipin.sym} 330 -200 0 0 {name=p6 lab=clk}
|
||||
C {opin.sym} 1160 -470 0 0 {name=p7 lab=out-}
|
||||
C {opin.sym} 140 -470 0 1 {name=p8 lab=out+}
|
||||
C {sg13g2_pr/sg13_lv_pmos.sym} 470 -570 0 0 {name=M2
|
||||
l=200n
|
||||
w=8u
|
||||
ng=2
|
||||
m=4
|
||||
model=sg13_lv_pmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/sg13_lv_pmos.sym} 830 -570 0 1 {name=M1
|
||||
l=200n
|
||||
w=8u
|
||||
ng=2
|
||||
m=4
|
||||
model=sg13_lv_pmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/sg13_lv_pmos.sym} 1040 -530 0 0 {name=M4
|
||||
l=0.200u
|
||||
w=8u
|
||||
ng=2
|
||||
m=1
|
||||
model=sg13_lv_pmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/sg13_lv_pmos.sym} 260 -530 0 1 {name=M5
|
||||
l=0.200u
|
||||
w=8u
|
||||
ng=2
|
||||
m=1
|
||||
model=sg13_lv_pmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/sg13_lv_nmos.sym} 260 -420 2 0 {name=M11
|
||||
l=0.200u
|
||||
w=4.0u
|
||||
ng=2
|
||||
m=1
|
||||
model=sg13_lv_nmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/sg13_lv_nmos.sym} 1040 -420 2 1 {name=M12
|
||||
l=0.200u
|
||||
w=4.0u
|
||||
ng=2
|
||||
m=1
|
||||
model=sg13_lv_nmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/sg13_lv_nmos.sym} 600 -200 2 0 {name=M6
|
||||
l=0.200u
|
||||
w=4.0u
|
||||
ng=1
|
||||
m=1
|
||||
model=sg13_lv_nmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/sg13_lv_nmos.sym} 380 -200 2 1 {name=M10
|
||||
l=0.200u
|
||||
w=4.0u
|
||||
ng=1
|
||||
m=1
|
||||
model=sg13_lv_nmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/sg13_lv_nmos.sym} 920 -200 2 0 {name=M7
|
||||
l=0.200u
|
||||
w=4.0u
|
||||
ng=1
|
||||
m=1
|
||||
model=sg13_lv_nmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/sg13_lv_nmos.sym} 700 -200 2 1 {name=M8
|
||||
l=0.200u
|
||||
w=4.0u
|
||||
ng=1
|
||||
m=1
|
||||
model=sg13_lv_nmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {lab_pin.sym} 960 -200 2 0 {name=p11 sig_type=std_logic lab=clk}
|
||||
C {sg13g2_pr/ntap1.sym} 1500 -290 2 0 {name=R1
|
||||
model=ntap1
|
||||
spiceprefix=X
|
||||
w=100e-6
|
||||
l=100e-6
|
||||
|
||||
}
|
||||
C {lab_pin.sym} 1500 -240 2 0 {name=p9 sig_type=std_logic lab=vdd}
|
||||
C {sg13g2_pr/sg13_lv_nmos.sym} 1260 -300 0 1 {name=M3
|
||||
l=0.200u
|
||||
w=4.0u
|
||||
ng=1
|
||||
m=4
|
||||
model=sg13_lv_nmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {lab_pin.sym} 1190 -300 0 0 {name=p10 sig_type=std_logic lab=sub
|
||||
m=4}
|
||||
C {lab_pin.sym} 1240 -360 0 0 {name=p12 sig_type=std_logic lab=gnd
|
||||
m=4}
|
||||
C {sg13g2_pr/ptap1.sym} 1370 -300 2 0 {name=R2
|
||||
model=ptap1
|
||||
spiceprefix=X
|
||||
w=100e-6
|
||||
l=100e-6
|
||||
}
|
||||
C {lab_pin.sym} 1370 -250 0 0 {name=p13 sig_type=std_logic lab=gnd
|
||||
m=4}
|
||||
C {lab_pin.sym} 820 -200 3 0 {name=p14 sig_type=std_logic lab=sub}
|
||||
C {lab_pin.sym} 490 -200 3 0 {name=p15 sig_type=std_logic lab=sub}
|
||||
C {lab_pin.sym} 1370 -340 0 1 {name=p16 sig_type=std_logic lab=sub}
|
||||
C {lab_pin.sym} 1500 -340 0 1 {name=p17 sig_type=std_logic lab=well}
|
||||
C {lab_pin.sym} 660 -570 1 1 {name=p18 sig_type=std_logic lab=well}
|
||||
C {lab_pin.sym} 1110 -530 0 1 {name=p19 sig_type=std_logic lab=well}
|
||||
C {lab_pin.sym} 190 -530 2 1 {name=p20 sig_type=std_logic lab=well}
|
||||
C {lab_pin.sym} 1110 -420 0 1 {name=p21 sig_type=std_logic lab=sub}
|
||||
C {lab_pin.sym} 190 -420 2 1 {name=p22 sig_type=std_logic lab=sub}
|
||||
C {sg13g2_pr/sg13_lv_pmos.sym} 630 -740 0 0 {name=M13
|
||||
l=0.3u
|
||||
w=18u
|
||||
ng=4
|
||||
m=1
|
||||
model=sg13_lv_pmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {sg13g2_pr/sg13_lv_pmos.sym} 630 -840 0 0 {name=M9
|
||||
l=0.3u
|
||||
w=18u
|
||||
ng=4
|
||||
m=1
|
||||
model=sg13_lv_pmos
|
||||
spiceprefix=X
|
||||
}
|
||||
C {ipin.sym} 580 -840 0 0 {name=p5 lab=vbias}
|
||||
C {lab_pin.sym} 710 -790 0 1 {name=p23 sig_type=std_logic lab=well}
|
||||
C {sg13g2_pr/annotate_fet_params.sym} 240 -400 0 0 {name=annot1 ref=M1}
|
||||
|
|
@ -1,39 +0,0 @@
|
|||
v {xschem version=3.4.5 file_version=1.2
|
||||
}
|
||||
G {}
|
||||
K {type=subcircuit
|
||||
format="@name @pinlist @symname"
|
||||
template="name=x1"
|
||||
}
|
||||
V {}
|
||||
S {}
|
||||
E {}
|
||||
L 4 -130 -100 130 0 {}
|
||||
L 4 -130 100 130 0 {}
|
||||
L 4 -130 -100 -130 100 {}
|
||||
L 4 -150 0 -130 0 {}
|
||||
L 4 -150 -60 -130 -60 {}
|
||||
L 4 -150 60 -130 60 {}
|
||||
L 4 110 10 130 10 {}
|
||||
L 4 110 -10 130 -10 {}
|
||||
L 4 -20 60 -20 80 {}
|
||||
L 7 -70 -100 -70 -80 {}
|
||||
L 7 -70 80 -70 100 {}
|
||||
B 5 -72.5 -102.5 -67.5 -97.5 {name=vdd dir=inout}
|
||||
B 5 -152.5 -2.5 -147.5 2.5 {name=vbias dir=in}
|
||||
B 5 -152.5 -62.5 -147.5 -57.5 {name=v+ dir=in}
|
||||
B 5 -152.5 57.5 -147.5 62.5 {name=v- dir=in}
|
||||
B 5 127.5 7.5 132.5 12.5 {name=out- dir=out}
|
||||
B 5 127.5 -12.5 132.5 -7.5 {name=out+ dir=out}
|
||||
B 5 -22.5 77.5 -17.5 82.5 {name=clk dir=in}
|
||||
B 5 -72.5 97.5 -67.5 102.5 {name=gnd dir=inout}
|
||||
T {@symname} -89 -6 0 0 0.3 0.3 {}
|
||||
T {@name} 25 -52 0 0 0.2 0.2 {}
|
||||
T {vdd} -74 -75 3 1 0.2 0.2 {}
|
||||
T {vbias} -125 -4 0 0 0.2 0.2 {}
|
||||
T {v+} -125 -64 0 0 0.2 0.2 {}
|
||||
T {v-} -125 56 0 0 0.2 0.2 {}
|
||||
T {out-} 90 1 0 1 0.2 0.2 {}
|
||||
T {out+} 95 -14 0 1 0.2 0.2 {}
|
||||
T {clk} -24 55 3 0 0.2 0.2 {}
|
||||
T {gnd} -66 75 1 1 0.2 0.2 {}
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
|
@ -1,2 +0,0 @@
|
|||
* Place this .save file with a .include line in your testbench
|
||||
|
||||
|
|
@ -1,120 +0,0 @@
|
|||
import numpy as np
|
||||
import sys
|
||||
import os
|
||||
import matplotlib.pyplot as plt
|
||||
|
||||
SI_PREFIXES = {
|
||||
-9: "n", # nano
|
||||
-6: "µ", # micro
|
||||
-3: "m", # milli
|
||||
0: "", # base unit
|
||||
3: "k", # kilo
|
||||
6: "M", # Mega
|
||||
9: "G" # Giga
|
||||
}
|
||||
|
||||
def get_best_unit(value):
|
||||
if value == 0:
|
||||
return 0, ""
|
||||
exponent = int(np.floor(np.log10(abs(value)) / 3) * 3)
|
||||
exponent = max(min(exponent, 9), -9)
|
||||
unit = SI_PREFIXES.get(exponent, "")
|
||||
return exponent, unit
|
||||
|
||||
def format_value(value):
|
||||
exponent, unit = get_best_unit(value)
|
||||
return f"{value / (10**exponent):.6g} {unit}"
|
||||
|
||||
def calculate_histogram_data(file_path):
|
||||
results = []
|
||||
errors_removed = 0
|
||||
total_samples = 0
|
||||
|
||||
try:
|
||||
with open(file_path, 'r') as file:
|
||||
for line in file:
|
||||
if line.startswith("Index") or not line.strip():
|
||||
continue
|
||||
|
||||
try:
|
||||
_, result = line.split()
|
||||
value = float(result)
|
||||
total_samples += 1 # Count total samples
|
||||
|
||||
# Check if value is exactly 1.0000e+00
|
||||
if value == 1.0:
|
||||
errors_removed += 1
|
||||
continue # Skip this value
|
||||
|
||||
results.append(value)
|
||||
except ValueError:
|
||||
continue
|
||||
except Exception as e:
|
||||
print(f"Error reading the file: {e}")
|
||||
return [], 0, 0, errors_removed, total_samples
|
||||
|
||||
if errors_removed > 0:
|
||||
print(f"ERROR: There are {errors_removed} values out of bounds (equal to 1.0), data has been removed.")
|
||||
print(f"Total samples: {total_samples}, Remaining samples: {total_samples - errors_removed}")
|
||||
else:
|
||||
print(f"Total samples: {total_samples}")
|
||||
|
||||
mean = np.mean(results)
|
||||
std_dev = np.std(results)
|
||||
|
||||
print(f"Mean: {format_value(mean)}")
|
||||
print(f"Standard Deviation: {format_value(std_dev)}")
|
||||
|
||||
return results, mean, std_dev, errors_removed, total_samples
|
||||
|
||||
def create_histogram(results, mean, std_dev):
|
||||
script_directory = os.path.dirname(os.path.abspath(__file__))
|
||||
histogram_dir = os.path.join(script_directory, "histogram_plots")
|
||||
|
||||
if not os.path.exists(histogram_dir):
|
||||
os.makedirs(histogram_dir)
|
||||
|
||||
plt.style.use('seaborn-whitegrid')
|
||||
fig, ax = plt.subplots(figsize=(8, 6))
|
||||
|
||||
# Plot histogram
|
||||
bins = 30
|
||||
counts, bin_edges, _ = ax.hist(results, bins=bins, edgecolor='black', color='skyblue', alpha=0.7)
|
||||
|
||||
# Overlay individual data points as scatter dots
|
||||
bin_centers = (bin_edges[:-1] + bin_edges[1:]) / 2
|
||||
jitter = np.random.uniform(-0.1, 0.1, size=len(results)) # Adds slight randomness to prevent overlap
|
||||
ax.scatter(results, np.random.uniform(0, counts.max() * 0.1, len(results)),
|
||||
color='red', s=15, alpha=0.7, label=f"Mean: {format_value(mean)}\nStd Dev: {format_value(std_dev)}")
|
||||
|
||||
# Title and labels
|
||||
ax.set_title('Histogram of Results', fontsize=16, fontweight='bold')
|
||||
ax.set_xlabel('Results', fontsize=14)
|
||||
ax.set_ylabel('Frequency', fontsize=14)
|
||||
|
||||
# Grid settings
|
||||
ax.grid(True, linestyle='--', alpha=0.5)
|
||||
|
||||
# Set ticks for better readability
|
||||
ax.tick_params(axis='both', which='major', labelsize=12)
|
||||
|
||||
# Save figure
|
||||
histogram_path = os.path.join(histogram_dir, "histogram.png")
|
||||
plt.legend()
|
||||
plt.tight_layout()
|
||||
plt.savefig(histogram_path, dpi=300)
|
||||
print(f"Histogram saved to {histogram_path}")
|
||||
plt.close()
|
||||
|
||||
if __name__ == "__main__":
|
||||
if len(sys.argv) != 2:
|
||||
print("Usage: python script.py <path_to_txt_file>")
|
||||
else:
|
||||
file_path = sys.argv[1]
|
||||
|
||||
results, mean, std_dev, errors_removed, total_samples = calculate_histogram_data(file_path)
|
||||
|
||||
if results:
|
||||
generate_histogram = input("Do you want to create a histogram plot? (y/n): ").strip().lower()
|
||||
if generate_histogram == 'y':
|
||||
create_histogram(results, mean, std_dev)
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 149 KiB |
|
|
@ -1,18 +0,0 @@
|
|||
# xschemrc - Custom configuration file for xschem
|
||||
# This file sources another xschemrc file from a known location
|
||||
|
||||
# Source the base configuration from a known location
|
||||
source $::env(PDK_ROOT)/$::env(PDK)/libs.tech/xschem/xschemrc
|
||||
|
||||
# (Optional) Add any custom overrides or extensions below
|
||||
# set xschem_library_path /home/user/my_libs
|
||||
# set xschem_gui_font "Monospace 10"
|
||||
|
||||
#### include skywater libraries. Here I use [pwd]. This works if I start xschem from here.
|
||||
###only if you dont have this setup already ###
|
||||
###append XSCHEM_LIBRARY_PATH :[file dirname [info script]]
|
||||
|
||||
|
||||
#### Add custom libraries (directories with .lib files)
|
||||
append XSCHEM_LIBRARY_PATH :../../pex/xschem_pex_symbol/
|
||||
|
||||
Loading…
Reference in New Issue