
CIP API Functions ControlLogix Platform ♦ "C" Programmable
Developer's Manual Linux Application Development Module
Page 126 of 264 ProSoft Technology, Inc.
March 12, 2014
OCXcip_GetStructInfo
Syntax
int OCXcip_GetStructInfo(OCXHANDLE apihandle,
OCXTAGDBHANDLE tdbHandle,
WORD hStruct,
OCXCIPTAGDBSTRUCT *pStructInfo);
Parameters
handle returned by previous call to OCXcip_Open
handle created by previous call to
OCXcip_CreateTagDbHandle
Nonzero structure handle from previous
OCXcip_GetSymbolInfo or OCXcip_GetStructMbrInfo
call
Pointer to symbol info variable - all members set if success:
name = NULL terminated symbol name
daType = structure data type
daSize = Size of the structure data in bytes. Zero indicates that
the structure is not accessible as a whole
ioType = OCX_CIP_STRUCT_IOTYPE_NA: Structure is not
accessible as a whole.
OCX_CIP_STRUCT_IOTYPE_OUT: Structure is an output type
and is read only when accessed as a whole.
OCX_CIP_STRUCT_IOTYPE_RMEM: Structure is memory type
and is read only when accessed as a whole.
OCX_CIP_STRUCT_IOTYPE_MEM: Structure is memory and is
read/write compatible.
OCX_CIP_STRUCT_IOTYPE_STRING: Structure is a memory
string and is read/write compatible.
numMbr = number of structure members
Description
This function gets structure information from the tag database. A tag database
must have been previously built with OCXcip_BuildTagDb. This functions does not
access the device or verify the device program version.
Return Value
Struct info was retrieved successfully
apihandle or tdbHandle is invalid
Example
OCXHANDLE hApi;
OCXTAGDBHANDLE hTagDb;
OCXCIPTAGDBSYM symInfo;
Comentarios a estos manuales