Technical data
VSIM function descriptions
ModelSim EE/PLUS Reference Manual VHDL Foreign Language Interface and Verilog PLI
-
475
relative name is relative to the region set by the VSIM
environment
(p312) command (the
top level region is the default). NULL is returned if the variable is not found.
The caller can read or modify the value of the variable provided that the type of
the variable is known. Given the variable's data type, the caller can interpret the
storage pointed to by the returned pointer.
char *mti_GetVarImage(char *nm)
Returns a pointer to a static buffer containing the string image of the variable named nm.
The variable name may be either a full hierarchical name or a relative name. The variable
name must include the process label. A relative name is relative to the region set by the
VSIM
environment
(p312) command (the top level region is the default). NULL is
returned if the variable is not found.
The image is the same as would be returned by the VHDL 1076-1993 attribute
IMAGE.
typeID mti_GetVarType(varID var)
Returns the typeID for the variable.
long mti_GetVarValue (varID var)
Gets the value of a scalar variable except TIME and DOUBLE which require
GetVarValueIndirect.
void * mti_GetVarValueIndirect(varID var, void * buf)
Gets the value of a variable of any type. GetVarValueIndirect must be used for variables of
type TIME and REAL. If buf is NULL, then VSIM returns a pointer to the value, which
should be treated as read-only data. If buf is not NULL, then VSIM copies the value into
buf and returns buf.
regionID mti_HigherRegion(regionID reg)
Returns the parent region of the region identified by "reg". The operation is the same for
Verilog instances.
char *mti_Image(void *ptr, typeID type)
Returns a pointer to a static buffer containing the string image of the value pointed to by
ptr. The format is determined by the specified typeID. The image is the same as would be
returned by the VHDL 1076-1993 attribute IMAGE.
void *mti_Interp ()
Returns the Tcl_Interp* used in the simulator. This pointer is needed in most Tcl calls and
can also be used in conjunction with mti_Cmd to obtain the command return value (results).
For example,