[help]cadence skill:how to get the whole net names of a instance

Discussion in 'Cadence' started by freetree, Jul 25, 2009.

  1. freetree

    freetree Guest

    [help]cadence skill :
    how to get the whole net names that connected to a instance.
    I want to get the actual net names of /I1/I0/M0,which should be "inp"
    or "ind"...
    I need to get them in command line,and can not use Mouse to select
    them.
    Thanks a lot

    netlist example:
    -----------------------------------------
    //the netlist created
    subckt por1 vss vdd por
    M0 (por vdd vss net01) nch l=1u w=5u
    R0 (por vdd) resistor r=10
    ends por1

    subckt por2 vss vdd vset
    M0 (vdd vset vss net01) nch l=1u w=10u
    I0 (vdd vss vset) por1
    ends por2

    I1 (inx inp ind ) por2
    M0 (inx inp ind net01) nch l=1u w=10u
    R1 (net01 1) resistor r=100m
     
    freetree, Jul 25, 2009
    #1
  2. freetree wrote, on 07/25/09 14:09:
    The function you want is geGetAdjustedPath. See the code below to see it in use:

    /* abGetHierNetName.il

    Author A.D.Beckett
    Group Custom IC (UK), Cadence Design Systems Ltd.
    Language SKILL
    Date Dec 13, 2004
    Modified
    By

    Simple functions to retrieve the hierarchical net name
    of a net in a design.

    The GUI interface is abShowHierNetName()

    ***************************************************

    SCCS Info: @(#) abGetHierNetName.il 12/13/04.15:16:23 1.1

    */

    /*****************************************************************
    * *
    * (abGetHierNetName net @optional (window (hiGetCurrentWindow))) *
    * *
    * Given a net object, return the adjusted hierarchical net name. *
    * By adjusted, we mean that the path is adjusted to the net name *
    * at the highest level. *
    * *
    *****************************************************************/

    (procedure (abGetHierNetName net @optional (window (hiGetCurrentWindow)))
    (let (netName)
    (setq netName
    (strcat
    "/"
    (buildString
    (foreach mapcar i (geGetHierMemInst window)
    (dbGetMemName (dbGetq (car i) name) (cadr i)))
    "/"
    )
    ))
    (setq netName
    (if (netName=="/")
    (strcat netName (dbGetq net name))
    (strcat netName "/" (dbGetq net name))
    ))
    (geGetAdjustedPath window netName)
    ))

    /*******************************************************************
    * *
    * (abShowHierNetName) *
    * *
    * Very simple GUI which expects you to have a single wire segment *
    * selected - and pops up a dialog box showing the hierarchical net *
    * name. *
    * *
    *******************************************************************/

    (procedure (abShowHierNetName)
    (let ((selSet (geGetSelSet)))
    (cond
    ((or (null selSet)
    (cdr selSet)
    (null (dbGetq (car selSet) net)))
    (hiDisplayAppDBox
    ?name 'abShowHierNetNameDBox
    ?dboxBanner "Show Hier Net Name Error"
    ?dboxText "You must have a single wire selected"
    ?dialogType hicErrorDialog
    ?dialogStyle 'modal
    ?buttonLayout 'Close
    )
    )
    (t
    (hiDisplayAppDBox
    ?name 'abShowHierNetNameDBox
    ?dboxBanner "Show Hier Net Name"
    ?dboxText (abGetHierNetName (dbGetq (car selSet) net))
    ?dialogType hicInformationDialog
    ?dialogStyle 'modal
    ?buttonLayout 'Close
    )
    )
    ) ; cond
    ) ; let
    ) ; procedure
     
    Andrew Beckett, Jul 27, 2009
    #2
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.