Do_setbits, Syntax, Remarks – Rockwell Automation 6182 SDK User Manual
Page 44: Return value, Portability, See also

4–4
RAC6182-Specific Extensions to the CE API
Publication 6182-UM002B-EN-P
do_SetBits
This function sets digital outputs. It is prototyped in
DiagnosticOutputAPI.h.
Syntax
#include
#include
BOOL do_SetBits(UCHAR ucMask)
Remarks
This function sets any output whose bit is 1 in ucMask to logic TRUE.
For the relay output, logic TRUE is equivalent to closed; for TTL
outputs, it is equivalent to TTL high level. All pins whose bit is 0 in
ucMask are left unchanged.
Note that the relay contacts are normally closed (i.e., closed when the
relay is not energized). Thus, when the relay output is set to 1 or TRUE,
the contacts will be open and vice versa.
The following macros may be used (separately or bitwise ORed together)
to evaluate ucMask:
Macro
Digital Output
MASK_DIAG_PIN_A
J10, pin A (no external access)
MASK_DIAG_PIN_B
J10, pin B (no external access)
MASK_DIAG_PIN_C
J10, pin C (no external access)
MASK_DIAG_PIN_D
J10, pin D (no external access)
MASK_RELAY_PIN
J16 (Relay – contacts NC)
Return Value
TRUE if read operation was successful, else FALSE.
Portability
This function is specific to the RAC6182 hardware.
See Also
do_ClearBits, do_ToggleBits, do_WritePort