Gx6062GetGroupRelays

Purpose

Returns the state of all relays in the specified group.

Syntax

Gx6062GetGroupRelays (nHandle, nGroup, pucRelaysState, pnStatus)

Parameters

Name
Type
Comments
nHandle
SHORT
Handle to a GX6062 board.
nGroup
SHORT
Specified group number, group number can be 0 (GX6062_GROUP_FIRST) to 11 (GX6062_GROUP_LAST).
pucRelaysState
PBYTE
Group relay state, each bit represents state of a relay:
  • 0: Open
  • 1: Closed
See comments for details on each bit.
pnStatus
PSHORT
Returned status: 0 on success, negative number on failure.

Comments

The ucGroupState parameter sets the state of all channels of the specified group. The following table describes the ucGroupStat bit description:

Bit #
Description
0-4
Relays 0-4 in the group. A high (‘1’) represent closed relay, a low (‘0’) represent open relay.
5

Relay connecting the specified group to the adjacent group. A high (‘1’) represent closed relay, a low (‘0’) represent open relay.

Note: Not applicable to the last group (Group L).

6

Relay connecting the specified group to the External Coax connector. Group A to P61 and Group L to P62.

Note: Apply to Group A (first group) and Group L (last group) only

 

Example

The following example returns group B relays state:

 

SHORT nMode, nStatus;

Gx6062GetDaisyChainMode (nHandle, &nMode, &nStatus);

 

See Also

Gx6062SetGroupRelays, Gx6062Open, Gx6062Close, Gx6062GetChannel, GxSWGetErrorString