GxAoDioSetOutputEnable

Purpose

Sets the Digital IO output enables states.

Applies

GX1649, GX1649-1

Syntax

GxAoDioSetOutputEnable (nHandle, ucOutputEnable,  pnStatus)

Parameters

Name
Type
Description
nHandle
SHORT
Handle to a GX1649 board.
ucOutputEnable
BYTE
Sets the bit field corresponding to the DIO output enable states.
pnStatus
PSHORT
Returned status: 0 on success, negative number on failure.

Comments

Bit 0-7 of ucOutputEnable correspond to DIO channels 0-7.

A bit with a value of 1 represents an enabled state. A bit with a value of 0 represents a disabled state.

Example

The following example sets DIO Channel output enable states for DIO Channel 0 and 2 to Enabled:

 

SHORT nStatus;

 

GxAoDioSetOutputEnable(nHandle, 0x5, &nStatus);

 

See Also

GxAoDioGetOutputEnable, GxAoGetErrorString