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

F

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 wrote, on 07/25/09 14:09:
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
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,

This code is very useful, is there a way to access inherited properties in similar way ?
Specifically we pass parameters down through hierarchy using pPar() and cdf.
For example, we have inverter nfet with width=pPar("nw").
When we instantiate that invert, we set parameter nw=3u.

I would like to descend hierarchy using geSwitch (I know how to do that) and
access width parameter inside instance of the inverter and have it resolve nw to 3u (I don't know how to do that).

Thanks.
 

Welcome to EDABoard.com

Sponsor

Back
Top