User guide
18-78
DirectC Interface
int
vc_arraySize(vc_handle)
Returns the number of elements in a memory.
scalar
vc_getScalar(vc_handle)
Returns the value of a scalar reg or bit.
void
vc_putScalar(vc_handle,
scalar)
Passes the value of a scalar reg or bit to a vc_handle by
reference.
char
vc_toChar(vc_handle)
Returns the 0, 1, x, or z character.
int
vc_toInteger(vc_handle)
Returns an int value for a vc_handle to a scalar bit or a
vector bit of 32 bits or less.
char
*vc_toString(vc_handle)
Returns a string that contains the 1, 0, x, and z characters.
char
*vc_toStringF(vc_handle,
char)
Returns a string that contains the 1, 0, x, and z characters
and allows you to specify the format or radix for the display.
The char parameter can be ’b’, ’o’, ’d’, or ’x’.
void
vc_putReal(vc_handle,
double)
Passes by reference a real (double) value to a vc_handle.
double
vc_getReal(vc_handle)
Returns a real (double) value from a vc_handle.
void
vc_putValue(vc_handle,
char *)
This function passes, by reference through the vc_handle,
a value represented as a string containing the 0, 1, x, and
z characters.
void
vc_putValueF(vc_handle,
char, char *)
This function passes by reference through the vc_handle
a value for which you specify a radix with the third
parameter. The valid radixes are ’b’, ’o’, ’d’, and ’x’.
void
vc_putPointer(vc_handle,
void*)
void
*vc_getPointer(vc_handle)
These functions pass, by reference to a vc_handle, a
generic type of pointer or string. Do not use these functions
for passing Verilog data (the values of Verilog signals).
Use it for passing C/C++ data. vc_putPointer passes this
data by reference to Verilog and vc_getPointer receives
this data in a pass by reference from Verilog. You can also
use these functions for passing Verilog strings.
Access Routine Description