File.
Returns the specified group’s channels names string, and the length of the string.
DioFileGroupGet (hFile, pszGroupName, pszGroupChannelsNames, pnGroupChannelsNamesLen, pnStatus)
Name |
Type |
Comments |
hFile |
SHORT |
Session identifier: File handle is used when communicating with a file. The File handle session identifier is returned by calling DioFileOpen. |
pszGroupName |
PCSTR |
String specifying group name. |
pszGroupChannelsNames |
PSTR |
Buffer to contain the returned group’s channels names (null terminated) string. |
pnGroupChannelsNamesLen |
PSHORT |
Returns the actual size of the buffer to of group’s channels names string. |
pnStatus |
PSHORT |
Returned status: 0 on success, negative number on failure. |
The function returns the specified group’s channels names string, and the length of the string associated with the specified group’s name. The user pass the buffers length of the pszGroupChannelsNames using the pnGroupChannelsNamesLen paramters, when the function returns, the pnGroupChannelsNamesLen paramters rreturns the actual size of the buffer to of group’s channels names string.
The pszGroupChannelsNames uses semicolons between channles name in the string, e.g. the following group’s channels names string "RESET;CLK_IN;CLK_OUT;SOURCE;GND;" has 5 channels names.
See DioFileGroupGetChannelList() for complete example code:
The following example return the group “Group1” channels names string from the file
SHORT hFile, nStatus;
SHORT nGroupChannelsNamesLen;
CHAR szGroupChannelsNames [512];
nGroupChannelsNamesLen = sizeof (szGroupChannelsNames);
DioFileGroupGet (hFile, “Group1”, szGroupChannelsNames, &nGroupChannelsNamesLen, &nStatus);
DioFileOpen, DioFileClose, DioFileGroupDelete, DioFileGroupGetChannelList, DioFileGroupGetName, DioFileGroupSet, DioGetErrorString