
Reserved Identifiers
157
NetLinx Programming Language Reference Guide
Keywords & Run-Time Library Functions (Cont.)
TO
This keyword activates a channel or variable for as long as the corresponding
channel of its
PUSH
statement is activated. When the channel referenced by
the
PUSH
statement changes from off to on, the
TO
command starts activating
the associated channel or variable. When the channel is released, the
TO
com-
mand stops activating of the channel or variable. Therefore, a
TO
statement
must be found underneath a
PUSH
statement only. The syntax is shown below:
TO [DEVICE,CHANNEL]TO [(DEVCHAN[ ])]TO [Variable]
Several conditions apply to the use of the
TO
command:
• It must be used only below a
PUSH
statement.
• It cannot be used as part of a set of
WAIT
statements.
• It cannot be placed in the
DEFINE_START
section.
The channel or variable will act under the rules set by
DEFINE_LATCHING
,
DEFINE_MUTUALLY_EXCLUSIVE
, and
DEFINE_TOGGLING
.
TOTAL_OFF
This keyword turns a channel or variable off. Unlike OFF, TOTAL_OFF turns off
the status of a channel or variable that is in a mutually exclusive set.
TRUE
This keyword is a CHAR constant contains the value 1.
While NetLinx does not support a BOOLEAN data type, an non-zero value is
consider true for conditional expressions.
TYPE_CAST
This routine eliminates compiler type cast warnings by casting the passed
intrinsic variable type to the type assigned by the return value.
IntrinsicVariableNewType TYPE_CAST
(IntrinsicVariableType)
It is possible to eliminate the compiler warnings related to type casting. The
TYPE_CAST
library function converts any non-array intrinsic type to any other
non-array intrinsic type. The type conversion still happens and follows the stan-
dard Type Conversion Rules, but any warnings related to the type cast are
eliminated. Type casting causes potential loss of data when a variable or con-
stant is assigned to a variable of smaller type.
UNCOMBINE_CHANNELS
This keyword reverses the effect of
COMBINE_CHANNELS
. All combines related
to the specified virtual device-channel are disabled.
SLONG UNCOMBINE_CHANNELS VDC
Parameters:
•
VDC
: The virtual device-channel passed to
COMBINE_CHANNELS
.
UNCOMBINE_DEVICES
This keyword reverses the effect of
COMBINE_DEVICES
. All combines related
to the specified virtual device are disabled.
SLONG UNCOMBINE_DEVICES VD
Parameters:
•
VD
: The virtual device passed to
COMBINE_DEVICES
.
Result:
• 0: Operation was successful.
• -1: Invalid virtual device.
Result = COMBINE_DEVICES VD, DEVSetResult =
UNCOMBINE_DEVICES VD
Summary of Contents for NETLINX PROGRAMMING LANGUAGE
Page 15: ...Table of Contents xiii NetLinx Programming Language Reference Guide...
Page 16: ...xiv NetLinx Programming Language Reference Guide Table of Contents...
Page 18: ...Introduction 2 NetLinx Programming Language Reference Guide...
Page 76: ...Language Elements 60 NetLinx Programming Language Reference Guide...
Page 106: ...Combining Devices Levels and Channels 90 NetLinx Programming Language Reference Guide...
Page 112: ...Master To Master M2M 96 NetLinx Programming Language Reference Guide...
Page 182: ...Reserved Identifiers 166 NetLinx Programming Language Reference Guide...
Page 204: ...NetLinx UniCode Functions 188 NetLinx Programming Language Reference Guide...
Page 244: ...Appendix B Glossary 228 NetLinx Programming Language Reference Guide...
Page 245: ...Appendix B Glossary 229 NetLinx Programming Language Reference Guide...