116
Relay Methods (WACI NX+ Only)
Relay_On ( Port )
Relay_On ( Port )
Relay_On ( Port )
Relay_On ( Port )
Switches on the relay at the specified port.
Syntax
HRESULT Relay_On(
[in] long Port,
[out, retval] VARIANT_BOOL* Success
);
Parameters
Port
[in] Port number for the relay. Valid values are 1, 2, 3, and 4.
Success
[out, retval] TRUE if the relay was switched on, FALSE if the relay failed to switch on.
Remarks
This function energizes the specified relay. The switch “sense” depends on whether a device has been wired to
the port’s “Normally Open” or “Normally Closed” connector on the connector block.
Relay_Off ( Port )
Relay_Off ( Port )
Relay_Off ( Port )
Relay_Off ( Port )
Switches off the relay at the specified port.
Syntax
HRESULT Relay_Off(
[in] long Port,
[out, retval] VARIANT_BOOL* Success
);
Parameters
Port
[in] Port number for the relay. Valid values are 1, 2, 3, and 4.
Success
[out, retval] TRUE if the relay was switched off, FALSE if the relay failed to switch off.
Remarks
This function de-energizes the specified relay. The switch “sense” depends on whether a device has been wired
to the port’s “Normally Open” or “Normally Closed” connector on the connector block.
Relay_GetState ( Port )
Relay_GetState ( Port )
Relay_GetState ( Port )
Relay_GetState ( Port )
Reports state of relay (on or off) at the specified port.
Syntax
HRESULT Relay_GetState(
[in] long Port,
[out, retval] long* State
);
Parameters
Port
[in] Port number for the relay. Valid values are 1, 2, 3, and 4.