Applies To
GC5050, GX5050, GX5055, GX5150, GX5280, GX5290, GX5290e, GX5295
Purpose
Returns the Slave board handle of the specified Master board.
Syntax
DioGetSlaveHandle (nMasterHandle, nBrdNum, pnHandle, pnStatus)
Parameters
Name |
Type |
Comments |
nMasterHandle |
SHORT |
Master board handle. |
nBrdNum |
SHORT |
Slave board number (1-7). |
pnHandle |
PSHORT |
Returned Slave board handle. |
pnStatus |
PSHORT |
Returned status: 0 on success, negative number on failure. |
Comments
The function can be called only after DioInitialize is called to retrieve the handle of Slave board. If an error occurs, pnHandle is 0.
Example
The following example returns the handle for Slave board number 1:
SHORT nHandle, nStatus;
DioGetSlaveHandle (nMasterHandle, 1, &nHandle, &nStatus);
See Also
DioSetupInitialization, DioInitialize