GX5055, GX5295
Sets the I/O pins channels direction when in static mode.
DioSetupIOPinsStaticDirection (nHandle, dwDirection, pnStatus)
Name |
Type |
Comments |
nHandle |
SHORT |
DIO Master handle, Slave handle or File board handle. |
dwDirection |
DWORD |
The 32 I/O channels directions are represented by the 32-bits. Each bit represents a channel starting from 0, e.g. channel zero is represented by bit 0.A bit high means the channel is set to output while a bit low means channel is set to input. |
pnStatus |
PSHORT |
Returned status: 0 on success, negative number on failure. |
The following example sets the I/O pins channels direction when in static mode:
SHORT nStatus;
DioSetupIOConfiguration (nHandle, 0, 1, pnStatus):
DioGetIOPinsStaticDirection, DioReadIoPinsValidity, DioReadIOPinsValue, DioWriteIOPinsValue, DioGetErrorString