# analog-design

Jorge Marin

02/18/2022, 3:08 PM
Hello All, I use the following flow for analog LVS: • I open the schematic cell in xschem and press netlist, and file1.spice is generated • I open the .mag cell in magic, and do: ◦ extract all ◦ ext2spice lvs ◦ ext2spice --> this latter generates file2.spice • Then I do: netgen -batch lvs file1.spice file2.spice /usr/local/share/pdk/sky130A/ For the LVS to succeed, I need to comment the subcircuit wrapper in the magic-generated file... is there a more straightforward way to do this? I tried using the "Simulation --> LVS netlist" option in xschem but it's not working. Any help would be really appreciated!

Harald Pretl

02/18/2022, 4:40 PM
You could use my script which automates the LVS process nicely.

Jorge Marin

02/18/2022, 8:13 PM
thanks @User, I will try them out

Tim Edwards

02/18/2022, 9:21 PM
@User: The better way to do it is to select
->`LVS netlist: Top level is a subckt` in xschem before hitting the
button, so that xschem produces a netlist with a subcircuit wrapper. This is better than removing the subcircuit wrapper from magic (which, if needed, can be controlled by the
ext2spice subcircuit
command option in magic).

Jorge Marin

08/09/2022, 10:15 PM
@Alfonso Cortés