next up previous contents index
Next: Physical Subcircuits Up: Extraction Functions Previous: Physical Conductor Groups   Contents   Index

Physical Devices

(device_handle) ListPhysDevs(name, pref, indices, area_array)
This function returns a handle to a list of devices extracted from the physical part of the current cell. The first two arguments are strings which match the Name and Prefix fields from the technology file Device block of the device to list. Either or both of these arguments can be null or empty, in which case no devices are excluded by the comparison, i.e., such values act as wildcards.

The third argument is a string providing a list of device indices, or ranges of indices, to allow. These are integers that are unique to each instance of a device type in a cell. If this argument is null or empty, all indices will be returned. Each token in the string is an integer (e.g., ``2''), or range of integers (e.g., ``1-4''), using the hyphen (minus sign) to separate the minimum and maximum index to include. The tokens are separated by white space and/or commas. For example, ``1,3-5,7,9-12''.

The final argument, if not 0, is an array of size four or larger containing rectangle coordinates, in microns, in order L,B,R,T. If 0 is passed for this argument, the entire cell is searched for devices. Otherwise, only the area provided will be searched.

On success, a handle is returned, otherwise 0 is returned. The handle can be used in the functions that take a device handle as an argument. This is not an object handle. The returned device handle can be manipulated with the generic handle functions, and like other handles should be iterated through or explicitly closed when no longer needed.

(string) GetPdevName(device_handle)
This function returns a string containing the name of the device referenced by the handle. The name string is composed of the Name field for the device (from the Device Block), followed by an underscore, followed by the device index number. If the handle is defunct or some other error occurs, a null string is returned.

(int) GetPdevIndex(device_handle)
This function returns the index of the device referenced by the handle passed as an argument. The index is an integer which is unique among the devices of a given type. If the handle is defunct or an error occurs, -1 is returned.

(object_handle) GetPdevDual(device_handle)
This function returns an object handle which references the dual device in the electrical database to the physical device referenced by the argument. If association failed for the device, 0 is returned. The dual device is a subcell obtained from the device library.

(int) GetPdevBB(device_handle, array)
This function obtains the bounding box of the device referenced by the first argument. The coordinates, in microns using the origin of the current physical cell, are returned in the array, which must have size 4 or larger. If the function succeeds, 1 is returned, otherwise the returned value is 0. The saved order is L, B, R, T.

(real) GetPdevMeasure(device_handle, mname)
This function returns a device parameter corresponding to a Measure line given in the Device block for the device referenced by the first argument. The second argument is a string giving the name from a Measure line. The returned value is the measured parameter, or 0 if there was an error.

(stringlist_handle) ListPdevMeasures(device_handle)
This function returns a string list handle corresponding to a list of the names associated with Measure lines in the Device block for the device referenced by the handle. These are the names that can be passed to GetPdevMeasure to perform the measurement. If an error occurs, 0 is returned.

(dev_contact_handle) ListPdevContacts(device_handle)
This function returns a handle to a list of contact descriptors for the device referenced by the argument. The returned handle can be passed to the functions below to obtain information about the device contacts. If there is an error, 0 is returned. The returned handle can be manipulated with the generic handle functions, and like other handles should be iterated through or closed explicitly when no longer needed.

(string) GetPdevContactName(dev_contact_handle)
This function returns the name string of the contact referenced by the argument. Contact names are assigned in the Device block for the device containing the contact. If an error occurs, a null string is returned.

(int) GetPdevContactBB(dev_contact_handle, array)
This function returns the bounding box of the contact referenced by the first argument. The coordinates, in microns relative to the origin of the physical current cell, are returned in the array, which must have size 4 or larger. If the operation is successful, 1 is returned, otherwise 0 is returned.

(int) GetPdevContactGroup(dev_contact_handle)
This function returns the conductor group index to which the contact referenced by the argument is assigned. If there is an error, -1 is returned.

(string) GetPdevContactLayer(dev_contact_handle)
This function returns the name string of the layer to which the contact referenced by the argument is assigned. All contacts are assigned to layers which have the Conductor attribute. If there is an error, a null string is returned.

(device_handle) GetPdevContactDev(dev_contact_handle)
This function returns a handle to the device containing the contact referenced by the argument. If an error occurs, 0 is returned. The returned handle should be closed (for example, with the Close function) when no longer needed.

(string) GetPdevContactDevName(dev_contact_handle)
This function returns the name of the device containing the contact referenced by the argument. A null string is returned on error.

(int) GetPdevContactDevIndex(dev_contact_handle)
This returns the index number of the device to which the contact, referenced by the passed handle, is associated. Each device of a given type has an index number assigned, which is unique in the containing cell. On error, -1 is returned. A valid index is 0 or larger.


next up previous contents index
Next: Physical Subcircuits Up: Extraction Functions Previous: Physical Conductor Groups   Contents   Index
Stephen R. Whiteley 2017-11-08