Tools for handling and analyzing Spice netlists
- Provides an easy interface for netlist manipulation.
- Uses Python standard library only.
- Easy to extend.
pip intall spatk* mynetlist.spice
vdd vdd vss 1
vss vss 0 0
r1 vdd n1 1k
r2 n1 vss 2k
x1 vdd vss sr
.subckt subres n1 n2
r1 n1 n2 3k
.ends
import spatk
cir = spatk.Circuit("mynetlist.spice")
for res in cir.resistors:
print(res.instance, res.resistance, res.location)r1 1k /
r2 2k /
r1 3k /subres