Event Handlers
62
NetLinx Programming Language Reference Guide
CHANNEL
refers to:
LEVEL
refers to:
Button events
Button events include pushes, releases, and holds. These events are associated with a push or release on
a particular device-channel. A sample button event is shown below:
BUTTON_EVENT[DEVICE,CHANNEL] or BUTTON_EVENT[(DEVCHAN[ ])]
{
PUSH:
{
// PUSH event handler
}
RELEASE:
{
// RELEASE event handler
}
HOLD[TIME]: or HOLD[TIME, REPEAT]:
{
// HOLD event handler
}
}
A
HOLD
event handler specifies the actions that should be performed when a button is pressed and held
for a minimum length of time indicated by the
TIME
parameter (
TIME
is specified in .10 second
increments). The
REPEAT
keyword specifies that the event notification should be repeated in
TIME
increments as long as the button is held.
The
BUTTON
object is available to the button event handler as a local variable. The following table lists
the information contained in Button Objects.
CHANNEL
A single channel number constant
CHAN[ ]
An integer array of channel numbers
DEVCHAN[ ]
A device-channel array
LEVEL
A single level number constant
LEV[ ]
An integer array of level numbers
DEVLEV[ ]
A device-level array
The processing of an event associated with a given member of a device, channel,
device-channel, level, or device-array must be completed before processing can
begin on another event associated with the same array.
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...