Reserved Identifiers
110
NetLinx Programming Language Reference Guide
Keywords & Run-Time Library Functions (Cont.)
CREATE_LEVEL
This keyword creates an association between a specified level of a device and
a variable that will contain the value of the level. This can only appear in the
DEFINE_START
section of the program.
CREATE_LEVEL DEV, Level, Value
Parameters:
•
DEV
: The device from which to read the level.
•
Level
: The level of the device to read.
•
Value
: Variable in which to store the level value.
•
DevLev
: A
DEVLEV
structure.
•
Value
: Variable in which to store the level value
CREATE_LEVEL DevLev,
Value
.
During execution of the program, NetLinx continuously updates the variable to
match the level it represents.
CREATE_MULTI_BUFFER
This keyword is the same as
CREATE_BUFFER
except that it accepts strings
from a range of devices. Two forms of this command are supported:
The first form of the command is provided for backward-compatibility; it accepts
two device numbers as the range of devices.
CREATE_MULTI_BUFFER FirstDevice, LastDevice, Buffer
Parameters:
•
FirstDevice
: First number in the range of devices.
•
LastDevice
: Last number in the range of devices.
•
Buffer
: Text buffer to receive the strings.
Each command string placed in the multi-buffer has a three-byte header associ-
ated with it:
• The first header byte,
$FF
, marks the start of a new command string.
• The second header byte is either the number of the device or the index of the
DEV[ ]
member that received the command string.
• The third header byte is the length of the string.
$FF, device number or DEV[ ] index, length, <string>
The second form of the command takes a device array rather than the device
number pair.
CREATE_MULTI_BUFFER DeviceSet, Buffer
Parameters:
•
DeviceSet
: Set of devices for which the buffer will accept strings.
•
Buffer
: Text buffer to receive the strings.
Each command string placed in the multi-buffer has a three-byte header associ-
ated with it.
• The first header byte,
$FF
, marks the start of a new command string
• The second header byte is the index into the
DeviceSet
of the device that
received the string.
The third header byte is the length of the string.
$FF, device number or DEV[ ] index, length, <string>
This command is not recommended for use in NetLinx due to its limitations.
The main limitations to note are:
• For the first form of the command, using
FirstDevice
and
LastDevice
,
only devices using the same port and system will be allowed. The device in
between the First Device and Last Device will be the sequential device
numbers using the same port and system (i.e. 1:1:0, 2:1:0, 3:1:0, etc…)
• For the second form of the command, using
DeviceSet
, only 255 devices
will be allowed in the array. This is required since only one byte is used to
represent the
DeviceSet
index in the return string so it has an upper limit of
255.
Содержание NETLINX PROGRAMMING LANGUAGE
Страница 15: ...Table of Contents xiii NetLinx Programming Language Reference Guide...
Страница 16: ...xiv NetLinx Programming Language Reference Guide Table of Contents...
Страница 18: ...Introduction 2 NetLinx Programming Language Reference Guide...
Страница 76: ...Language Elements 60 NetLinx Programming Language Reference Guide...
Страница 106: ...Combining Devices Levels and Channels 90 NetLinx Programming Language Reference Guide...
Страница 112: ...Master To Master M2M 96 NetLinx Programming Language Reference Guide...
Страница 114: ...Mainline 98 NetLinx Programming Language Reference Guide FIG 1 Message and Mainline Processing in the NetLinx System...
Страница 182: ...Reserved Identifiers 166 NetLinx Programming Language Reference Guide...
Страница 204: ...NetLinx UniCode Functions 188 NetLinx Programming Language Reference Guide...
Страница 244: ...Appendix B Glossary 228 NetLinx Programming Language Reference Guide...
Страница 245: ...Appendix B Glossary 229 NetLinx Programming Language Reference Guide...