Gx5733SetPortByte (nHandle, nPort, nByte, ucValue, pnStatus)
Name |
Type |
Description |
nHandle |
SHORT |
Handle to a GX5733 board. |
nPort |
SHORT |
Module port 0 (GX5733_PORT0) only. |
nByte |
SHORT |
Port byte number: 0-3, 0 for the port low order byte and 3 for the high order byte. |
ucValue |
BYTE |
Value to set 0-255. Each bit represents the specific channel state bit 0 for lowest channel number. |
pnStatus |
PSHORT |
Returned status: 0 on success, negative number on failure. |
Only byte set to output direction will be written.
The following example writes 0x5 (bit 16 and 19 hi and bit 17, 18, 20-23 to low state) to port 1, byte 2 value:
Gx5733GetPortByte (nHandle, 1, 2, 0x5, &nStatus);
Gx5733GetPortByte, Gx5733SetPortBit, Gx5733SetPortWord, Gx5733SetPort