Skip to content

SpiceParser cannot parse parameters with multiple keywords #404

@Jamanaman

Description

@Jamanaman

I'm currently trying to parse in this set of 3 coupled transmission lines as part of a larger circuit and I can pass it directly as raw spice or I can code it directly as one normally would. The problem herein lies in that I am trying to build a pipeline where one can build a schematic in QUCS-S or KiCAD with the full set of models available in ngSPICE and can then automatically run a large number of parametrized simulations using PySPICE. To do this I would like to be able to get individual nodes and components and would like to be able to read in the netlist directly from a QUCS-S or KiCAD netlist output. Is this within the intended use of the Parser to be able to read any ngSPICE netlist and if so, should I try to put together a change for Line.get_kwargs to get this to work? Otherwise I'll just write my own parser on top.


*                                       TLINE_1 In
*                                          | TLINE_2 In
*                                          |   |  TLINE_3 In
*                                          |   |   | GND Ref Voltage at Inputs
*                                          |   |   |   | TLINE_1 Out
*                                          |   |   |   |    | TLINE_2 Out
*                                          |   |   |   |    |    | TLINE_3 Out
*                                          |   |   |   |    |    |    | GND Ref Voltage at Outputs
*                                          |   |   |   |    |    |    |    |   
.SUBCKT KSPICE_Tline_Tline_Coupled_x3 gnd in1 in2 in3 ref1 out1 out2 out3 ref2 len=10m L11=0 L12=0 L13=0 L22=0 L23=0 L33=0 C11=0 C12=0 C13=0 C22=0 C23=0 C33=0
P1 out1 out2 out3 ref1 in1 in2 in3 ref2 tline_coupled_x3 
.MODEL tline_coupled_x3 CPL (length={len} L={L11} {L12} {L13} {L22} {L23} {L33} C={C11} {C12} {C13} {C22} {C23} {C33} R=0 0 0 0 0 0 G=0 0 0 0 0 0)
XCPL_3_1 0  _net6 _net3 _net1 0 _net7 _net4 _net5 0 KSPICE_TLine_Tline_Coupled_x3 len=100M L11=3.373512324354E-07 L12=8.454286635295E-08 L13=3.049822592114E-08 L22=3.317674190711E-07 L23=8.454286635295E-08 L33=3.373512324354E-07 C11=9.298647207845E-11 C12=-1.330012165772E-11 C13=-8.829589065184E-13 C22=9.616753828914E-11 C23=-1.330012165772E-11 C33=9.298647207845E-11

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions