Gx6338Close

Purpose

Closes the specified relay.

Syntax

Gx6338Close (nHandle, nChannel, pnStatus)

Parameters

Name
Type
Comments
nHandle
SHORT
Handle to a GX6338 board.
nChannel
SHORT
Specifies the relay number. Can be 1 to 114.
pnStatus
LPSHORT
Returned status: 0 on success, negative number on failure.

 

Comments

The Gx6338GetChannel function can be used to retrieve the current channel state.

 

Warning

Caution - When closing a relay, verify that all other relays on the same circuit that may cause a short are disconnected (a delay may be required between switching commands). Low Impedance sources such as power supplies may cause irreversible damage to this product when shorted to other signals.

 

Example

The following example closes relay 1 and relay 22:

 

Gx6338Close (nHandle, 1, &nStatus);

Gx6338Close (nHandle, 22, &nStatus);

 

See Also

Gx6338Initialize, Gx6338Open, Gx6338SetGroupChannels, Gx6338GetChannel