next up previous contents index
Next: Terminals Up: Extraction Functions Previous: Extraction Functions   Contents   Index

Menu Commands

(int) DumpPhysNetlist(filename, depth, modestring, names)
This function dumps a netlist file extracted from the physical part of the database, much like the Dump Phys Netlist command in the Extract Menu. The filename argument is a file name which will receive the output. If null or empty, the file will be the base name of the current cell with ``.physnet'' appended. The depth argument specifies the depth of the hierarchy to process. If an integer, 0 represents the current cell only, 1 includes the first level subcells, etc. A negative integer specifies to process the entire hierarchy. This argument can also be a string beginning with the letter `a', which will process all levels of the hierarchy.

The third argument is a string, consisting of characters from the table below, which set the mode of the command. These are analogous to the check boxes that appear with the Dump Phys Netlist command. If a character does not appear in the string, that option is turned off. If it appears in lower case, the option is turned on, and if it appears in upper case, the option will be set by the present value of the corresponding !set variable. The characters can appear in any order.

character option corresponding variable
n net NoPnet
d devs NoPnetDevs
s spice NoPnetSpice
b list bottom-up PnetBottomUp
g show geometry PnetShowGeometry
c include wire cap PnetIncludeWireCap
a list all cells PnetListAll

The final argument, if not null or empty, contains a space-separated list of physical format names, each of which must match a PnetFormat name in the format library file, or option names from the table above. The names that contain white space should be double-quoted.

For each cell, a field in the output is generated for each format choice implicit in the modestring or given in the names. In most cases, only one format is probably wanted. The option text in the table above can also be included in the names, which is equivalent to giving the corresponding lower-case letter in the modestring. The modestring setting will have precedence if there is a conflict. If both the modestring and the names string are empty or null, an effective mode string consisting of all of the upper-case option letters is used.

Example: print a SPICE file

DumpPhysNetlist("myfile.cir", "a", "s", 0)
or
DumpPhysNetlist("myfile.cir", "a", 0, "spice")

If the function succeeds, 1 is returned, otherwise 0 is returned.

(int) DumpElecNetlist(filename, depth, modestring, names)
This function dumps a netlist file extracted from the electrical part of the database, much like the Dump Elec Netlist command in the Extract Menu. The filename argument is a file name which will receive the output. If null or empty, the file will be the base name of the current cell with ``.elecnet'' appended. The depth argument specifies the depth of the hierarchy to process. If an integer, 0 represents the current cell only, 1 includes the first level subcells, etc. A negative integer specifies to process the entire hierarchy. This argument can also be a string beginning with the letter `a', which will process all levels of the hierarchy.

The third argument is a string, consisting of characters from the table below, which set the mode of the command. These are analogous to the check boxes that appear with the Dump Elec Netlist command. If a character does not appear in the string, that option is turned off. If it appears in lower case, the option is turned on, and if it appears in upper case, the option will be set by the present value of the corresponding !set variable. The characters can appear in any order.

character option corresponding variable
n net NoEnet
s spice EnetSpice
b list bottom-up EnetBottomUp

The final argument, if not null or empty, contains a space-separated list of electrical format names, each of which must match an EnetFormat name in the format library file, or option names from the table above. The names that contain white space should be double quoted.

For each cell, a field in the output is generated for each format choice implicit in the modestring or given in the names. In most cases, only one format is probably wanted. The option text in the table above can also be included in the names, which is equivalent to giving the corresponding lower-case letter in the modestring. The modestring setting will have precedence if there is a conflict. If both the modestring and the names string are empty or null, an effective mode string consisting of all of the upper-case option letters is used.

If the function succeeds, 1 is returned, otherwise 0 is returned.

(int) SourceSpice(filename, modestring)
This function will parse a SPICE file, adding to or updating the electrical part of the database with the devices and subcircuits found. This is equivalent to the Source SPICE command in the Extract Menu. The first argument is a path to the SPICE file to process.

The final argument is a string, consisting of characters from the table below, which set the mode of the command. These are analogous to the check boxes that appear with the Source SPICE command. If a character does not appear in the string, that option is turned off. If it appears in lower case, the option is turned on, and if it appears in upper case, the option will be set by the present value of the corresponding !set variable. The characters can appear in any order. If the string is empty or null, all options will be set by the corresponding variables.

character option corresponding variable
a all devs SourceAllDevs
r create SourceCreate
l clear SourceClear

If the operation succeeds, 1 is returned, otherwise 0 is returned.

(int) ExtractAndSet(depth, modestring)
This function performs extraction on the physical part of the database, updating the electrical part. This is equivalent to the Source Physical command in the Extract Menu. The first argument indicates the depth of the hierarchy to process. This can be an integer: 0 means process the current cell only, 1 means process the current cell plus the subcells, etc., and a negative integer sets the depth to process the entire hierarchy. This argument can also be a string starting with `a' such as ``a'' or ``all'' which indicates to process the entire hierarchy.

The final argument is a string, consisting of characters from the table below, which set the mode of the command. These are analogous to the check boxes that appear with the Source Physical command. If a character does not appear in the string, that option is turned off. If it appears in lower case, the option is turned on, and if it appears in upper case, the option will be set by the present value of the corresponding !set variable. The characters can appear in any order. If the string is empty or null, all options will be set by the corresponding variables.

character option corresponding variable
a all devs NoExsetAllDevs
r create NoExsetCreate
l clear ExsetClear
c include wire cap ExsetIncludeWireCap

If the operation succeeds, 1 is returned, otherwise 0 is returned. This function does not redraw the windows.

(object_handle) FindPath(x, y, depth, use_extract)
This function returns a handle to a list of copies of physical conducting objects in a wire net. The x,y point (microns, in the physical part of the current cell) should intersect a conducting object, and the list will consist of this object plus connected objects. The depth argument is an integer or a string beginning with ``a'' (for "all") which gives the hierarchy search depth. Only objects in cells to this depth will be considered for addition to the list (0 means objects in the current cell only). If the boolean value use_extract is nonzero, the main extraction functions will be used to determine the connectivity. If the value is zero, the connectivity is established through geometry. This is similar the the Show Paths and Quick Paths commands.

The return value is a handle to a list of object copies, or 0 if no objects are found.

(int) ExtractRL(conductor_zoidlist, layername, r_or_l, array, term, ...)
This will use the square-counting system to estimate the resistance or inductance of a conducting object with respect to two or more terminals. The first argument is a trapezoid list representing a single conducting area, on the layer given in the second argument. The layer keywords set electrical parameters used in the estimation.

For Resistance:
The Resistance layer keyword gives the ohms-per-square of the material. If not set, a value of 1.0 is assumed.
For Inductance:
The Tranline keyword supplies the appropriate parameters. In this case, the material is assumed to be over a ground plane covered by dielectric.

The third argument is a boolean which if nonzero indicates inductance estimation, and zero indicates resistance estimation.

The fourth argument is an array which will hold the return values, which will be resized if necessary. The zeroth component of the array gives the number of returned values, which are returned in the rest of the array. If there are two terminals, the number of returned values is 1. For more than two terminals, the number of returned values is n*(n-1)/2, where n is the number of terminals. The values are the effective two-terminal decomposition for terminals i,j (i != j) in the order, e.g., for n = 4; 01, 02, 03, 12, 13, 23.

The following arguments are trapezoid lists representing the terminals. Arguments that are not trapezoid lists will be ignored. There must be at least two terminals passed. Terminal areas should be spatially disjoint, and in the computation, the terminal areas are clipped by the conductor area. Terminals are assigned numbers in left-to-right order.

The algorithm is most efficient if all coordinates are on some grid. This provide for efficient tiling of the structure.

Structures that require a very large number of tiles may require excessive time and memory to compute, and/or suffer from a loss of accuracy. The approximate threshold is 105 tiling squares. Non-Manhattan shapes have strict internal limiting of tile count. Manhattan structures can require an arbitrarily large number of tiles, thus the potential for resource overuse.

The return value is always 1. The function will fail (terminating the script) if an error is encountered.

(int) ExtractNetResistance(x, y, spicefile, array, term, ...)
This function will extract resistance of a conductor net, taking into account multiple conducting layers connected by vias. The resistance decomposition of each conducting object and its vias and/or terminals is computed using the algorthm used by the ExtractRL function. The resistance of the connected network is then computed, with respect to the terminals specified.

The first two arguments are a coordinate point that is expected to fall on a wire net (similar to the FindPath function). The net is recognized using the Quick Paths algorithm. Invisible layers are not included.

The third argument is a string giving a file name, which will contain a generated SPICE listing representing the extracted resistor network. In the SPICE file, each terminal and each via are assigned node numbers. A comment indicates the range of numbers used for terminals. If this argument is 0 (NULL) or an empty string, no SPICE file is written.

The fourth argument is an array which will hold the return values, which will be resized if necessary. The zeroth component of the array gives the number of returned values, which are returned in the rest of the array. If there are two terminals, the number of returned values is 1. For more than two terminals, the number of returned values is n*(n-1)/2, where n is the number of terminals. The values are the effective two-terminal decomposition for terminals i,j (i != j) in the order, e.g., for n = 4; 01, 02, 03, 12, 13, 23.

The following arguments are trapezoid lists representing the terminals. Arguments that are not trapezoid lists will be ignored. There must be at least two terminals passed. Terminal areas should be spatially disjoint, and in the computation, the terminal areas are clipped by the conductor area. Terminals are assigned numbers in left-to-right order.

The return value is always 1. The function will fail (terminating the script) if an error is encountered.


next up previous contents index
Next: Terminals Up: Extraction Functions Previous: Extraction Functions   Contents   Index
Stephen R. Whiteley 2006-10-23