infinity controller programmer’s guide - free fire...
TRANSCRIPT
Andover Controls Corporation i
This man ual is inc lude d for informatio nal purpo ses only. It is supe rceded by the
SX 8000 Program mer’s Guide , Versi on 2.0.
Infinity ControllerProgrammer’s Guide
Electronic Version
Controlling Tomorrow’s World
www.PDF-Zoo.com
ii Infinity Controller Programmer’s Guide
Version 1.4
Reproduction or distribution forbidden.Copyright 1993–1996 by Andover Controls.
Subject to change without notice.
Order No. 30-3001-166
Copyright 1993Andover Controls Corporation300 Brickstone SquareAndover, Massachusetts 01810All Rights Reserved.
IMPORTANT NOTICE
The number of points, files, system objects, entries in a log or array, ex-changed points, and statements you can program are all subject to memory and system limitations. Controller scan speed is reduced as you increase the num-ber objects defined and amount of communication activity on the network. Various operations or activities on the system will affect system performance. You should check the amount of memory available frequently (see the Ando-ver Controls 9000 programmer’s guides for details). Consult with your An-dover Controls representative concerning the amount of memory your instal-lation requires.
Examples in this book are for illustrative purposes only and must never be used in an actual building.
This product is subject to change without notice. This document does not con-stitute any warranty, express or implied. Andover Controls Corporation re-serves the right to alter capabilities, performance, and presentation of this product at any time.
www.PDF-Zoo.com
Andover Controls Corporation iii
The following trademarks are used in this manual:
CROSSTALK is a registered trademark of Digital Communications Associates, Inc.
IBM is a registered trademark of International Business Machines, Inc.
VT is a trademark of Digital Equipment Corporation.
The following are registered trademarks of Andover Controls Corporation:
Andover Controls Plain EnglishEnergyNetInfinet
www.PDF-Zoo.com
iv Infinity Controller Programmer’s Guide
Preface
The Andover Controls Infinity CX Programmer’s Guide is a two vol-ume set.
The volumes present the following:
• Volume 1—Getting Started Programming
• Volume 2—Advanced Programming/Access Control
If you are using the control system for HVAC, you should proceed through this manual sequentially. If you are using the control system for access control, begin with Chapter 21 in Volume 2.
If you do not know anything about HVAC, this manual does not provide adequate information. The examples in it are extremely simplistic for purposes of illustrating programming techniques and concepts. For complete information on HVAC or programming HVAC, refer to other sources.
www.PDF-Zoo.com
Andover Controls Corporation v
Volum e 1—Getting Sta rtedProgramming
The Andover Controls Infinity Controller Programmer’s Guide Volume 1 presents step by step instructions for setting up the controller system and fundamental programming in Andover Controls Plain EnglishTM. Whether you use this system for HVAC or for access control, you should already have installed your hardware before you attempt to set up the Infinity CX system. If you do not know how to arrange yournetwork to set up your hardware, refer to the EnergyNet and Infinet Configuration Guide.
The chapters of this book present the following:
• Chapter 1—Understanding Controller Hardware
• Chapter 2—Setting Up EnergyNet and Infinet
• Chapter 3—Setting Up Logons, LBuses, Terminals, and Printers
• Chapter 4—Naming and Defining Points
• Chapter 5—An Overview of the Programming Process
• Chapter 6—Writing Fundamental Programs
• Chapter 7—More Fundamental Keywords
• Chapter 8—Working with Triggers, Logs, and Special Conversions
• Chapter 9—Altering and Further Developing Programs in Your Set
• Chapter 10—Creating and Using Numeric, String, and DateTime Points
For more advanced programming, refer to Volume 2.
www.PDF-Zoo.com
vi Infinity Controller Programmer’s Guide
Volum e 2—Advanced Programm ingand Acc ess Control
The Andover Controls Infinity Controller Programmer’s Guide Volume 2 presents instructions for programming with advanced keywords in Andover Controls Plain EnglishTM. This volume is a continuation of Volume 1 and assumes you have read Volume 1.
If you are using controllers for access control only, you should begin with Chapter 21 in this volume. This volume also covers creating your own functions, setting up and using data files, and programming DCX 250, modems on Infinity CX and CMX controllers, expansion modules, and more. It also has a special chapter on debugging techniques.
The chapters in this volume present the following:
• Chapter 11—Programming with Advanced Keywords
• Chapter 12—Defining Your Own Functions
• Chapter 13—Creating, Using, and Searching for Data in Files
• Chapter 14—Debugging Techniques
• Chapter 15—Programming the DCX Screen
• Chapter 16—Programming Modules, ReaderDoors, and Lighting Controllers
• Chapter 17—Dialing Modems
• Chapter 18—Advanced Functions for Experts
• Chapter 19—Loading and Saving Programs
• Chapter 20—Operating on Battery Backup
www.PDF-Zoo.com
Andover Controls Corporation vii
• Chapter 21—Introducing and Planning Access Control
• Chapter 22—Setting Up Areas and Doors for Access Control
• Chapter 23—Setting Up Persons for Access Control
• Appendix A—Keystrokes
• Appendix B—Error Messages
• Appendix C—DCX Graphic Controls and Frame Styles
• Appendix D—Storing Areas and Persons on Infinity CX 9000/220
www.PDF-Zoo.com
viii Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Chapter 1
UnderstandingCont roller Hardwa re
This chapter presents the following topics:
• About the Controller Network
• Knowing about Point Types
• Expansion Modules Inputs and Outputs
• Small Network Controllers
www.PDF-Zoo.com
Understanding Controller Hardware
1-2 Infinity Controller Programmer’s Guide
About th e Controller NetworkThe Andover Controls control system consists of:
• One or more Infinity CX controllers.
Or one Infinity CMX controller for a smaller network.
• One or more Infinity SX 8000 workstations (optional).
• Input/output units (IOUs) attached to each Infinity CX 9000. (For best performance we recommend you use only three.) The Infinity CX 9500 has its own inputs and outputs.
• An optional series of smaller controllers called Infinet controllers that may each have optional EMX modules. All Infinity CX controller may have at least one Infinet.
• At least one computer terminal (screen) for human access to the system. (Can also be a computer running a VT100 terminal emulator communications package, such as CROSSTALK.)
• An optional printer for printing messages.
You might find it useful to draw a sketch of the network, showing each item.
Figure 1-1 shows what a map of a typical network looks like.
You should have a tag that came from each controller, IOU, or Infinet controller. The tag has the serial number and loca-tion of the equipment. You may want to label your map so it reflects the actual layout of the controller system.
Each Infinity CX controller on that map can have one or more input output units (IOUs). Each IOU has a number the con-troller identifies it by. That number is marked on the map.
Elements o f theNetwork
Find Cont roller Tags
www.PDF-Zoo.com
Understanding Controller Hardware
Infinity Controller Programmer’s Guide 1-3
Figure 1-1. Sample Map o f a Network
Infinity SX 8000
CableEnergyNet
Infinity CX 9000
TCX SCX
VT100
850 900
Infinity CX 9500 (has built-in inputs and outputs)
TCX SCX 850 900
Infinity CX 9000
IOUIOUIOU
SCX SCX
LBUS Cable
Infinet Cable900 900
Infinity CX 9500
IOUIOUIOU
SCX LCX900 800
www.PDF-Zoo.com
Understanding Controller Hardware
1-4 Infinity Controller Programmer’s Guide
Knowing about Point TypesEach IOU on the controller has 32 universal input sensors and 16 outputs, which may be universal, tristate, or Form C (ON and OFF). The “universal” inputs and outputs accept input from and send output to several types of sensors or devices without any hardware alterations.
We refer to all these sensors and transmitters as input and out-put points.
Input and output points are Infinity’s way of interacting with the environment.
An input point is constantly receiving information about, for instance, the temperature in a room. While that temperature remains within a set range (say 68 to 72), the controller takes no action.
If the heat is off and not needed, the controller does not turn it on. When the temperature drops below 68 or rises above 72, the point triggers a response from the controller.
Usually, only when a point changes does the controller take action. Types of points other than inputs and outputs are de-scribed in Chapter 5.
Plain Eng lish Names
The controller cannot act on a point unless you tell it the name and location of the point. So you must assign a name to each point.
Points and other items on the controller can be named with up to 16 alphabetic and numeric characters, including periods and underscores. The first character must be alphabetic.
You can enter the name in upper and lowercase the first time so it is more readable than all caps, but the controller under-
Input and Output Points
Rules fo r Naming Points
www.PDF-Zoo.com
Understanding Controller Hardware
Infinity Controller Programmer’s Guide 1-5
stands it as the same name in either case. For example, the controller reads the following two names as the same:
SupplyAir
SUPPLYAIR
The first is obviously easier for you to read. If you enter it that way the first time, later, even when you enter SUPPLYAIR, the controller will reprint it on the screen as SupplyAir each time you open the program file.
Procedures to tell the controller the names of all the points are in Chapter 4.
Locati ng Control ler Poin ts
You might want to make copies of the drawings on the next few pages, one for each Infinity CX 9000 IOU and each Infinet controller on the network.
The drawings show the input and output points and the nu-meric labels supplied at by Andover Controls. In your drawing, you write a name next to each input and output that defines its purpose. Note which IOUs are tristate, universal, or Form C.
You can later follow these drawings when setting up points. If you have many IOUs connected to one Infinity CX 9000, or a great many Infinet controllers, these drawings may help avoid confusion.
Finding Poin ts on IOUs
www.PDF-Zoo.com
Understanding Controller Hardware
1-6 Infinity Controller Programmer’s Guide
Figure 1-2 is a drawing of an IOU, showing the input and output points (usually used with Infinity CX controllers).
Points o n IOUs
F
ig
ure 1-
2. S
am
ple Draw
in
g o
f IOU
P
o
in
ts
fo
r In
fin
ity CX
9
000
OU
TP
UT
SIN
PU
TS
OU
TP
UT
NU
MB
ER
S
of
IOU
Num
ber
Infin
ity C
X 9
000
Nam
e C
entr
alP
lant
1U
nive
rsal
Poi
nts
2
www.PDF-Zoo.com
Understanding Controller Hardware
Infinity Controller Programmer’s Guide 1-7
Figure 1-3 is a drawing of a Infinet controller, SCX 900 showing the input and output points.
Points on an SCX 900
Figure 1-3. Drawing Sho wing SCX 900 Points
- OnOff
Auto
Off+On
-OnOff
Auto
Off+On
- OnOff
Auto
Off+On
- OnOff
Auto
Off+On
-O nOff
Auto
Off+On
-OnOff
Auto
Off+On
Auto
Off+On
–+
1
12
34
56
78
2
3
4
5
6
7
8
X
xx
XXXXXXXXXXXXX
XXXXXXXXXXXX
XXXXXXXXXXXX
XXXXXXXXXXXX
x
x
x
x
x
x
x
x
x
x
x
x
x
x
x
1
2
3
4
5
6
7
8
x
x
x
x
x
x
x
x
Form CTristate
Form CTristate
x
x
x
x
x
OVERRIDE
CPU
TD
RD
+ 24 VEXTERNAL
STATUS
x
- OnOff
Auto
Off+On
ADJ
ADJ
ADJ
ADJ
ADJ
ADJ
ADJ
ADJ
EXPANSIONPORT
X
X
X
X
X X X X
X X
X X
X X
X X
X
X ----To
230V
E1
TP10
From24V
ToE1
TP10E7
To
TP10
From115V
USE COPPERCONDUCTORS ONLY
E3 E4E2 E5 E2 E2 E7
E6 E6 E4
From
AC INPUT VOLTAGE SELECTION
ACINPUT
LCD VIEW ANGLE
SCX
x xSLOW BLOWF19, 3A, 250V
-
+
3.6 V
X
X
F142 A
xxxxxxxx
XXXXXXXXXXXX
XXXXXXXXXXXX
XXX
910
1112
1314
1516
INFINET
xxxxx
xxxxx
xxxxx
xxxxx
XXXXXXXX
XXXXXXXX
1
3
5
7
2
4
6
8
XXXXXXXX
XXXXXXXX
911
13
15
10
12
14
16
INPUTREFERENCERESISTOR
OUT
OUT
INPUTREFERENCERESISTOR
X
INPUTS
X XX X
X
XF1
1/8 A
RESET
SERVICEPORT
EPROM
XX
X X
IN
GND
NEU
HOT
RET
RET
RET
RET
RET
RET
RET
RETIN
SHLD
1/8 A
1/8 A
1/8 A
NCC
NO
NCC
NO
IV
GNDGND
IV
NCC
NO
NCC
NO
IV
GNDGND
IV
NCC
NO
NCC
NO
IV
GNDGND
IV
NCC
NO
NCC
NO
IV
GNDIV
X
OUTPUT
INPUTS
www.PDF-Zoo.com
Understanding Controller Hardware
1-8 Infinity Controller Programmer’s Guide
Figure 1-4 is a drawing of a TCX 850, showing the input and output points. The TCX 851 is similar, but has only the first four inputs.
Figure 1-4. Drawing Showing TCX 850/851 Point s
Points on an TCX 850
C
C
C
OUT1
NO
OUT2
NO
OUT3
NOC
OUT4
ON
ON
IN1
RET
IN2
RET
IN3
RET
IN4
RET
GNDNEUHOT
+–
+
–
SHLD
INPUT 8
++
–
+
MIN MAX SPIN5 IN6 IN7
INPUTS OUTPUTS
INPUTS
www.PDF-Zoo.com
Understanding Controller Hardware
Infinity Controller Programmer’s Guide 1-9
Figure 1-5 shows the TCX 853 inputs and outputs. The universal inputs are 5 through 6, the airflow inputs 7 and 8.
Figure 1-5. Drawing Showing TCX 853 Poin ts
Points o n an TCX 853
C
C
C
OUT1
NO
OUT2
NO
OUT3
NOC
OUT4
ON
ON
IN1
RET
IN2
RET
IN3
RET
IN4
RET
GNDNEUHOT
+–
+
–
SHLD
INPUT 8
++
–
+
Inputs
OUTPUTS
INPUT 7
IN5
RET
IN6
RET
INPUTS
www.PDF-Zoo.com
Understanding Controller Hardware
1-10 Infinity Controller Programmer’s Guide
Figure 1-6 is a drawing of an LCX 800, showing the input and output points.
Figure 1-6. Drawing Showing LCX 800 Poin ts
Points on an LCX 800
GNDNEUHOT
RETIN1
IN2RETIN3IN4RETIN5IN6RETIN7IN8
+–
SHLD
NC
C
NO
NC
C
NO
NC
C
NO
NC
C
NO
OUT1
OUT2
OUT3
OUT4
NC
C
NO
NC
C
NO
NC
C
NO
NC
C
NO
OUT5
OUT6
OUT7
OUT8
OUTPUTS
OUTPUTS
INPUTS
www.PDF-Zoo.com
Understanding Controller Hardware
Infinity Controller Programmer’s Guide 1-11
Figure 1-7 is a drawing of an LCX 810, showing the input and output points.
Figure 1-7. Drawing Showing LCX 810 Poin ts
Points on an LCX 810
INFINETSHLD–
RD
TD
CPU
EXPANSIONPORT
SERVICEPORT
+
INP
UT
S
–
+
NEU
HOT
GND
ACINPUT
NCCNONCCNONCCNONCCNO
NCCNONCCNONCCNONCCNO
1
USE COPPERCONDUCTORS ONLY
3.6V
OVERRIDE
+24VEXTERNAL
STATUSLIGHTSINPUTS
RET12RET34RET56RET78
INPUTREFERENCERESISTOR
IN
OUT2
3
4
5
6
7
8
OU
TP
UT
S
xxxxxxxxxxx
xxxxxxxxxxx
www.PDF-Zoo.com
Understanding Controller Hardware
1-12 Infinity Controller Programmer’s Guide
Figure 1-8 shows the ACX 700 supervisory input points.
Figure 1-8. Drawing Showing ACX 700 Points
Points o n an ACX 700
AUTO/OFF/ON
AUTO/OFF/ON
DOOR 2OUTPUT
KEYPAD 2C3C2C1
DOOR 1OUTPUT
AUTO/OFF/ON
INFINET
OVERRIDE
C3C2C1
SHLD–
GNDO/CLKI/DATALED+5V
GNDO/CLKI/DATALED WIEGAND
ABA
RET8
RET4
IN8RET7IN7RET6IN6RET5IN5
IN4RET3IN3RET2IN2RET1
----
AC INPUT VOLTAGE SELECTION
TO230V
E6
P1
FROM24V
TOE6
P1
FROM
E2
TO
P1
FROM115V
ACX700
B13.6V
1.8AHr
LITHIUM
RD
TD
CPU
EXPANSIONPORT
SERVICEPORT
+
KEYPAD 1SUPERVISORYINPUTS
EXT
TAMPER
SWITCH
RESET
+5V
WIEGAND
ABA
IN1
-INPUT+12VDC PWR
ON
–
+
USE COPPERCONDUCTORS
ONLY
F13A,250V
SLOW BLOW
NEU
HOT
GND
ACINPUT
E7 E5E4 E3 E4 E4 E5
E1 E1 E2
READER 1
READER 2
TAMPER
SWITCH 9
R1R2R3R4RET
RETR4R3R2R1
OUTPUT 3
OVERRIDE
+24VDC CLASS 11160 m A
INPUTS
DOORS
www.PDF-Zoo.com
Understanding Controller Hardware
Infinity Controller Programmer’s Guide 1-13
For this special controller, you do not set up ordinary points. Instead, you set up Doors, as described in Chapters 21, 22, and 23 of Volume 2. Doors are similar to points. Each door has a channel number. Door1 is channel 1, Door2 channel 2. You can also connect a door to Output 3 (channel 3).
You do not set up the card readers or keypads as input points, but associate a card reader or keypad with a particular door by assigning the channel number (Reader1 is channel 1, Reader2 is channel 2) to the card reader for the particular door.
You can, in addition, set up the supervisory inputs as input points. For information about the types of sensors you can wire to supervisory inputs, and for more information about Doors and access control, see Chapters 21, 22, and 23. Refer
to Chapter 4 for how to set up supervisory point types.1
1. For an alternative method of setting up doors, see Chapter 16.
ACX 700 Has Doors
www.PDF-Zoo.com
Understanding Controller Hardware
1-14 Infinity Controller Programmer’s Guide
Figure 1-9 is a drawing of an LCX 890, showing the input and output points, and the location of the switches for momentary manual control.
Figure 1-9. Drawing Showing LCX 890 Poin ts
Poin ts on an LCX 890
LCX 890
INPUTS
EMX 170 or SP 100 Port
Universal Inputs
Digital Inputs
24 VACRectified
PowerTerminal forOccupancy
Sensor
OutputRelays(Max NumberPossibleShown—24)
MomentarySwitches
www.PDF-Zoo.com
Understanding Controller Hardware
Infinity Controller Programmer’s Guide 1-15
Expansion Mo dul e Inputs and OutputsYou may attach a limited number of expansion modules to each Infinet controller model. The number is based on the following:
Caution—Memory LimitationYou may run out of memory before the maximum number of expansion points, so keep the number to a minimum.
• Never use more than two of any particular model number.
• The total number of inputs or outputs that are on the modules must never be more than the number allowed on the Infinet controller—see the table below.
• You must set the first output module on the chain to Board 1, the second to Board 2, the third to Board 1, the fourth to Board 2, and so on—no matter which model number modules. When you start the input modules, start atBoard 1 again and continue to alternate from 1 to 2.
• A single EMX 190 must be the last output module on any chain. Two of them must be the last two output modules on any chain.
• A SmartSensor (EMX 170) must be the last module on any chain.
• If all modules attached to a single controller consume more than 110 mA, you must add an external power supply to the chain. To determine the milliamps each module con-sumes and whether or not you require an external power supply, see the ACC EMX Modules Configuration Guide.
Based on the table, you can have up to eight expansion outputs on a LCX 810. So you can, for example, have two EMX 150s (two outputs each) and two EMX 155s (two outputs each) on that controller, for a total of eight expansion outputs.
At tach Limited Number of Expansion Modules
www.PDF-Zoo.com
Understanding Controller Hardware
1-16 Infinity Controller Programmer’s Guide
You may never have more than two of any single module.
Table 1-1. Number of Base, Expansi on Modul e, and Total Inputs/ Outputs Allowed for Vari ous Control lers
An alternative would be to have two EMX 150s (with two outputs each), one EMX 151 (with two outputs), and one EMX 140 (with two outputs). Again, the total is eight expansion outputs.
You can mix inputs with outputs so that, in addition to the outputs, you could have two EMX 160s and one EMX 170. Be sure to put the EMX 170 at the end of the chain.
NoteNote that EMX 140 and 150 expansion module outputs do not give standard feedback indicating when you are controlling the point manually or what its manual control setting is.
Be sure you set the Board switch of the first module to Board 1, and the second to Board 2 (see illustrations that follow for location of Board switch) and you put one immediately after the other. (Never set the first one to Board 2.) The same applies for every EMX model that has a Board switch—except the EMX 190. No matter which Board you just set the last output module to, you must set the first EMX 190 to Board 1 and the second to Board 2. Since the EMX 190s must be the last output modules on the chain, you can then switch to input modules, and start again at Board 1. (Be sure to put together a
TCX 850/851
LCX 810
8
8
17
17
Model No. Base Exp Total Base Exp Total
SCX 900 16 17
25
25
33
4
8
8
2
8
8
6
16
16
Inputs OutputsController
ACX 700 8 21 29 3 4 7
Sett ing the BoardSwitc hes
www.PDF-Zoo.com
Understanding Controller Hardware
Infinity Controller Programmer’s Guide 1-17
map showing the chain of EMX modules for each Infinet controller using them.)
Figure 1-10 illustrates a sample map of EMX modules on an SCX 900 controller, using the maximum number of inputs and outputs allowed. (You assign input and output numbers later, in Chapter 4.)
Figure 1-10. Sample of EMX Modul es on an SCX 900
SCX900
EMX 150—Board 1
EMX 150—Board 2
EMX 190—Board 1
EMX 190—Board 2
EMX 160—Board 1
EMX 160—Board 2
EMX 170
EMX 140—Board 1
ExternalPowerSupply
2 Outputs
2 Outputs
2 Outputs
1 Output
1 Output
8 Digital Inputs
8 Digital Inputs
Output 9—VoltageOutput 10—Voltage
Output 11—CurrentOutput 12—Current
Output 13—Pneumatic
Output 15—ReaderDoor
Output 16—ReaderDoor
Inputs 17–24—Digital
Inputs 25–32—Digital
—1 InputInput 33—Temperature
You assign these outputnumbers very carefully,as covered in Chapter 4.
Output 14—Pneumatic1
1Even if you do not have a second pneumatic output (as on an EMX 141 or EMX 143), you mustcount outputs as if it were there.
www.PDF-Zoo.com
Understanding Controller Hardware
1-18 Infinity Controller Programmer’s Guide
Figure 1-11 is a drawing of an EMX 160 input module, showing the inputs, labeled 1 through 8. The inputs can be digital or counter.
You number the inputs on the module sequentially after the highest input number on the Infinet controller it is attached to. For instance, if you put the module on an SCX 900, the Board 1 module would have inputs 17 through 24, and the Board 2 module would have inputs 25 through 32.
Figure 1-11. Drawing Showing EMX 160 Points
Poin ts on an EMX 160
EMX 160 BOARD
EXTERNALPOWER
RET
IN1
IN2
RET
IN3
IN4
RET
IN5
IN6
RET
IN7
IN8
1
2
INPUTS
www.PDF-Zoo.com
Understanding Controller Hardware
Infinity Controller Programmer’s Guide 1-19
Figure 1-12 is a drawing of an EMX 150 output module, showing the outputs, labeled A and B. The outputs can be voltage or current.
You number the outputs sequentially after the highest output number on the Infinet controller. For instance, if you put the module on a TCX 850, the Board 1 module would have out-puts 5 and 6, and the Board 2 module would have outputs 7 and 8.
The two knobs adjust the two outputs between 0 and 20 V.
You can set the override switch to manual or automatic. You cannot, however, get feedback through the controller telling you that either of these outputs is set to manual control with the OVERRIDE switch or telling what the override setting is.
Figure 1-12. Drawing Showing EMX 150 Points
Points on an EMX 150
EMX150
BOARD1
2
RETIV
OUTPUTA
RETIV
OUTPUTB
OVERRIDE
A
AUTO MAN
B
A
B
OUTPUTS
www.PDF-Zoo.com
Understanding Controller Hardware
1-20 Infinity Controller Programmer’s Guide
Figure 1-13 is a drawing of an EMX 170 SmartSensor module. This module has a single temperature input.
Figure 1-13. Drawin g Showin gthe EMX 170 Point
The input on the EMX 170 is automatically the only temperature input point number assigned after the original inputs on the controller. Even if you have no other expansion module, you must always assign the EMX 170 sensor the highest possible input number in the entire chain of modules. (On SCX controllers, number 33. On LCX and TCX controllers, number 25.)
A SINGLE INPUT
EMX 170 Input IsTemperature Inpu t
www.PDF-Zoo.com
Understanding Controller Hardware
Infinity Controller Programmer’s Guide 1-21
Figure 1-14 is a drawing of an EMX 151 module. This module has two analog outputs that must be controlled by the controller because they have no manual override switches.
You can use one or two modules of this type in a single chain.
Figure 1-14. Drawin g Showin g EMX 151 Points
Points on an EMX 151
EMX151
BOARD
1
2
RET
I
V
OUTPUT
A
RET
I
V
OUTPUT
B
EXTERNAL
POWER
OUTPUTS
www.PDF-Zoo.com
Understanding Controller Hardware
1-22 Infinity Controller Programmer’s Guide
Figure 1-15 is a drawing of an EMX 155 module. This module has two Form C outputs. You can use one or two modules of this type in a single chain.
Figure 1-15. Drawing Showing EMX 155 Points
Poin ts on an EMX 155
EMX155
1 2
OUTPUT A
OUTPUT B
OVERRIDE
AUTO
B
ON
EXTERNAL
POWER
OFF
NC
C
NO
NC
C
NO
BOARD
A
www.PDF-Zoo.com
Understanding Controller Hardware
Infinity Controller Programmer’s Guide 1-23
Figure 1-16 is a drawing of an EMX 190 module. This module has a single output. Infinity identifies all the inputs wired to the module in terms of the output.
The EMX 190 must always be the last output module on the chain. If you have one, it must be Board 1. If you have two EMX 190s they must be the last two output modules and they must be Board 1, then Board 2, no matter which board number precedes them.
Figure 1-16. Drawing Showing EMX 190 Points
Points on an EMX 190
EMX190
OVERRIDE
DOOROUTPUT
NO CNC
ABA
CARD READER
AUTO
24VDC
CLASS
+5V
1/DATALED
0-CLKRTN
2
1BOARD
OVERRIDE
OFF
ON
DOOR SWITCHRTN
EXIT REQUESTRTN
CARDREADER
INPUT
WIEGAND
II
ReaderDoorOutput
www.PDF-Zoo.com
Understanding Controller Hardware
1-24 Infinity Controller Programmer’s Guide
Figure 1-17 is a drawing of an EMX 140 module. This module has two pneumatic outputs. You can manually override this output by removing the air flow tube. The controller does not give you feedback telling you the output is being manually controlled, but it does give you the value of the output when you have it in this “manual override” state.
Figure 1-17. Drawing Showing EMX 140 Points
Poin ts on an EMX 140
EMX140
CHANNEL CHANNELA B
SUPPLY AIR
PNEUMATICOUTPUTS
BOARD
1 2
RET INA RET INB
+
–EXTERNALPOWER
SUPPLY AIR
OUT
OUT
0-20MA
www.PDF-Zoo.com
Understanding Controller Hardware
Infinity Controller Programmer’s Guide 1-25
You can purchase variations on this module with only one pneumatic output, but you must treat those models as if they have two by skipping an output for the second one.
So, if you assign a single pneumatic output the number 13, then you cannot assign 14 to another module. Skip 14 and as-sign 15 to the next module output.
EMX 140 Modules Have One or Two Outputs
www.PDF-Zoo.com
Understanding Controller Hardware
1-26 Infinity Controller Programmer’s Guide
Small Network Con troll ersIn certain situations, you may require only a single Infinet and no EnergyNet. These situations would be sites with few con-trollers and/or few programs (since the memory available in any Infinet controller is limited). You may want to call such a site to monitor it.
For a single Infinet where you do not always require a termi-nal, you may want to employ the Infinity CMX controller.
The Infinity CMX is a scaled down Infinity CX. The Infinity CMX has the following features/limitations:
• A port for an Infinet that can have up to 32 Infinet controllers.
• An RS-232 port you can use for two purposes, but only one at time:
— Built-in modem automatically set to 2400 baud.
— A terminal.
When you set up the port as a UserPort, you set it up for a terminal. However, when another party (such as another site or an operator in another building) calls in over the modem, the modem always takes control of the port.
Once a modem call occurs, the controller automatically logs you (or any other operator) out of the terminal and closes any open files. If you have been altering a program and have not saved it when the modem call occurs, you lose the changes.
Small Networks CanEmploy CMX Controller
www.PDF-Zoo.com
Understanding Controller Hardware
Infinity Controller Programmer’s Guide 1-27
When to Use CMX Contr ollers
Andover recommends that you use an CMX controller with a terminal only in situations where you do not expect the termi-nal and the modem to conflict with one another. For instance, here are some possible situations:
• If you are calling in on the modem only after 5 p.m., when the operator is no longer using the terminal.
• If you intend to construct a dump file for the CMX on another controller and then load it, rather than developing programs on the controller at its terminal.
CMX Terminal and Modem Can Conflic t
www.PDF-Zoo.com
Understanding Controller Hardware
1-28 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Chapter 2
Logging On and Set ting Up
EnergyNet and InfinetWe recommend you read this chapter sequentially to get started on an Infinity CX or CMX controller. Go to the terminal and carry out all of these procedures to set up the controllers on each EnergyNet and Infinet:
• Logging on for the First Time
• Using the Command Window
• Printing in the Command Window
• Using the Menus
• Setting the Date and Time
• Making Changes Inside the Window
• Defining Infinity CX Controllers
• Setting Controller Attributes
• Defining the Infinet Controller Network
• Setting Infinet Attributes and Finding Controllers
• Opening Infinet Controllers
• Understanding Infinet Controller Attributes
• Accessing (Connecting to) Other Controllers
• An Alternative Method of Connecting to Other Controllers
NoteKeystrokes are unique for each terminal type. This manual uses standard key names. You can look up the specific keystrokes for your terminal in the Keystroke Reference card (enclosed) or in Appendix A. Keep the reference card by your terminal until you are well acquainted with the keystrokes. Note that you may use some keys differently in different situations.
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-2 Infinity Controller Programmer’s Guide
Logging On for the First TimeOnce you have installed the hardware, when you first approach any terminal or computer on an Infinity CX controller, the screen is blank. You activate Infinity CX windows as follows:
1. Type WINDOW. The word does not appear on the screen. Instead, a box appears that takes up most of the screen. The box is called a “window.” (If you do not have windows, go to Logging On without Windows on the next page.)
Figure 2-1 shows the Infinity window.
Figure 2-1. Infinity Window
In the center of the window are two smaller boxes (text boxes), one labeled User Name and the other Password .
Since you, the system administrator, are the first user, you
must enter the predefined user logon ACC and the password provided with your hardware.
The cursor (the blinking box) should be at the beginning of the User Name text box.
Terminal Displa ys t heInfini ty Window
User Name
Password
Infinity
View Edit Connect Logout
(C) 1990 Andover Controls Corporation
Version 1.2
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-3
2. Type ACC in the first text box and press the NEXT ATTRIBUTE key to move to the next text box. (Or arrow to it with the down arrow key.)
3. Type your password in the second text box.
To prevent others from seeing the password, the controller does not show the word as you type it.
4. Press the EXECUTE key to proceed.
A new window should appear on the screen. The EXECUTE key always moves on to the next window or completes an action.
You are now ready to proceed with the next section.
If the window does not appear, you may have made a mistake typing the password. Try logging on again. If you continue to fail, contact your Andover Controls representative.
Logging on w itho ut Win dow s
If you have an Infinity CX 9100 controller, you can log on to the controller from a blank screen so that you can work with dump files:
1. Type COMMAND. The word does not appear on the screen. Instead, Login: appears.
2. Type ACC and press the EXECUTE key. The ACC does not appear on the screen. Password: appears.
3. Type ACC again and press the EXECUTE key. If you make a mistake in the password, Login: appears again and you must enter the logon and password again.
When you have logged on successfully, the R> prompt appears.
If you cannot log on successfully, contact your Andover Controls representative.
Passwo rds Do Not Display
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-4 Infinity Controller Programmer’s Guide
Using the Command W indowAs soon as you have logged on to the controller, a window inside the main window appears. This is called the “Command window.”
Figure 2-2 shows that window. The cursor is on View the far left selection on the Main menu bar. The Main menu bar is the narrow strip across the top of the screen. To move the cursor from the Main menu bar to the Command window, press the CANCEL WINDOW key (see the Keystroke Quick Reference card). To bring it back to the menu bar, press CANCEL WINDOW again.
In the Command window you can enter single-line instructions called “command lines.” Command lines tell the controller to do something now.
Figur e 2-2. Command Windo w of the FLOOR1 Control ler
You can use most keywords on the command line. In the Andover Controls Plain English Language Reference, each keyword has a section labeled Modes Available In . If “command line” is listed, the keyword can be used on the command line.
The Command Window
R>Command Window – FLOOR1
View Edit Connect Logout
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-5
A PRINT Command Li ne
You can find out the date using a keyword called PRINT. To print, for instance, the date, type
PRINT DATE
after the R> prompt and press the EXECUTE key.
Figure 2-3 shows that the date prints immediately.
Figure 2-3. Printing the Date on Command Line
If the date is incorrect, you change it as described later in this chapter.
Proceed with the next section to print more information.
Summary
• Command lines tell the controller to act now.
• You can use keywords to form command lines.
• You type command lines after the R>.
Print the Date
R> PRINT DATEJune 23, 1992 2:25:51R>
Command Window – FLOOR1
View Edit Connect Logout
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-6 Infinity Controller Programmer’s Guide
Printing in the Command WindowYou can use the PRINT keyword to print the following predefined names in the Command window:
TOD HOUR MINUTE SECOND
Each of these is already defined by the controller. They are called “system variables,” because the controller system keeps track of their values.
To print the time of day (TOD) enter this command line:
PRINT TOD
To print the current hour, minute, or second, enter one of these command lines:
PRINT HOUR
PRINT MINUTE
PRINT SECOND
Figure 2-4 shows the commands in the window.
Remember not to type the R>. The R> indicates where you may type.
To print TOD again, press the up arrow key until the cursor lands on the command line that says PRINT TOD. Then press the EXECUTE key.
Print Syst em VariableValues
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-7
Figure 2-4. PRINT Command L ines
Notice that PRINT TOD reappears below all the other command lines along with the new time.
Now that you have seen how to get information from the controller, proceed to the next section to see how to put it into the controller.
Summary
• You can use the PRINT command to print predefined names in the Command window.
• Predefined names are called “system variables.”
• TOD, HOUR, MINUTE, and SECOND are system variables.
• Type command lines after the R> that appears.
• Repeat a command line by moving the cursor back up to the command line and pressing the EXECUTE key.
R> PRINT TOD 8:30 am R> PRINT HOUR8R> PRINT MINUTE30R> PRINT SECOND22 R>
Command Window – FLOOR1
View Edit Connect Logout
Use the PRINT Keywo rd
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-8 Infinity Controller Programmer’s Guide
Using th e MenusAcross the top of the screen is a 1/4-inch wide bar called the “Main menu bar.” Each word along that bar is the name of a menu.
Figure 2-5 shows the Main menu bar, a pulldown menu, and the status bar. (Your status bar may be different from the one shown here.)
Figure 2-5. Main Menu Bar, Pulld own Menu, and Status Bar
1. To move the cursor along the menu bar, you press the right and left arrow keys.
2. To select a menu, press the EXECUTE key while the name is highlighted.
OR
To both move the cursor to the menu and select the menu at once, press the first letter of the menu name on the keyboard. For example, as in the figure above, you press
The Main Menu Bar
UsersPointsFilesCommPortsControllerInfinet ControllerSystem Date & Time
View
PULLDOWN
MAIN MENU BAR
Messages 0 CX: BoilerRm October 24 1992 08:23:45
STATUS BAR
System Variables
MENU
PersonsAreasDoors
Edit Connect Logout
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-9
E and the Edit menu pulls down. This type of menu is called a “pulldown” menu.
3. To select an item from any pulldown menu, you arrow to it using the up and down arrow keys, until it is highlighted. Then press the EXECUTE key.
OR
4. Press the key for the first highlighted letter in that menu item. (The first highlighted letter is not always the first letter of the word.)
Throughout this book when you are directed to select from a menu, we say “select Edit Points ,” because you first select the Edit menu, then the Points menu item.
In the next section, you set the time and date by opening the System Date & Time window with through the menus.
Summary
• The bar across the top of the screen is the “menu bar” and contains the names of several menus.
• The menus that pull down from the bar are called “pulldown menus.”
• To select a menu from the menu bar you press either the arrow and EXECUTE keys or the first letter in the menu name.
• To select a pulldown menu item press either the arrow and EXECUTE keys or the key for the first highlighted letter in the item.
Select ing from the Pulldown Menu
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-10 Infinity Controller Programmer’s Guide
Sett ing the Date and TimeBefore you do anything else, you must set the date and time for your controller. (Later, when you set up other controllers, you can easily send them the same date and time. This way, you set the date and time only once.)
Select Edit System Date & Time from the menu bar.
Figure 2-6 shows selecting from the pulldown menu.
Figure 2-6. Select ing Edit Syst em Date & Time
Figure 2-7 shows the window that appears after you press the EXECUTE key. The cursor is in the Date and Time text box. You enter both the date and time on that line.
You can press the DELETE LINE/TEXT key (refer to the Infinity CX Keystroke Quick Reference) to erase the date and time from the text box. The cursor should then be at the beginning of the box. You now enter the new date and time all in the same box.
If, after erasing it, you want to bring the original date and time back, press the RESTORE TEXT key.
Set the System Time
UsersPointsFilesCommPortsControllerInfinet ControllerSystem Date & Time
View
Messages 0 CX: BoilerRm October 24 1992 08:23:45
System VariablesPersonsAreasDoors
Edit Connect Logout
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-11
Figure 2-7. System Time Window
If you want to delete only the time (the last few characters in the text box), arrow over to the first letter to remove and press the DELETE TO RIGHT key. Characters to the right of the cursor erase. You can then type the new time.
More ways to move the cursor in this window and others are explained in the section called Making Changes Inside the Window, later in this chapter.
Setting Da te
You may enter the date using all numbers or spelling the month as either the full word or the three-letter abbreviation.
You can separate the month, day, and year with spaces, slashes, dashes, periods, commas, or any combination of them.
Setting Da y and Month
If you enter 3-2-92, the controller automatically interprets it as March 2, 1992, rather than as February 3, 1992. You can, however, enter the day first if you:
• Spell the month as a word.
Date and Time August 20, 1990 13:30:26
OK CANCEL
System Time – FLOOR1 DATE
View Edit Connect Logout
Press Certain Keysto Erase/Restore Text
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-12 Infinity Controller Programmer’s Guide
• Use numbers for both month and day only if the day is greater than 12, since any number between 1 and 12 could be a month. (So, 15-12-90 becomes December 15, 1990.)
Setting Ye ar
You may enter the year as a two- or four-digit year. You may enter it before or after the day or month.
Sample Dates
Input Output
9 January 1992 January 9, 199292 8 Mar March 8, 199291, July 6 July 6, 199191-8-Apr April 8, 19919/22/91 September 22, 1991
Setting T ime
You must keep hours, minutes, and seconds together when you enter the time, but you do not have to enter seconds.
You can enter the time as 24-hour time or include AM or PM with the 12-hour time:
Input Output
14:24:09 14:24:099:25 PM 21:25:2010:30:22 AM 10:30:221:24:36 PM 13:24:36
You can enter AM or PM anywhere in the date-time.
The controller translates 12-hour time into the 24-hour clock. For instance, 3:00 PM becomes 15:00:00.
The Year May Be Two orFour Digits
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-13
Sample Date and Time Input
Input Output
July 92, 8 PM 9:25 July 8, 1992 21:25:0091, Aug 6 8:52:35 PM August 6, 1991 20:52:359/22/91 6:6 PM September 22, 1991 18:06:00AM 9 Jan 1990 6:00 January 9, 1990 6:00:00
Steps to Compl etingthe Date and Time
1. Enter the complete date and time in the Date and Time text box.
You must enter a complete and acceptable date and time before the controller lets you leave the Date and Time text box.
2. Press the NEXT ATTRIBUTE key to move to the OK button and press the EXECUTE key to execute the process. If you press the CANCEL button, the time reverts to what it was before.
The date and time are stored in the controller’s memory. The cursor returns to the menu bar.
You can also press EXECUTE from the Date and Time text box at any time to save and close the window, just as you did in the User window. Or you can press the SAVE key.
3. Select Edit System Date & Time from the menu bar.
Notice that the date and time have changed to the one you entered.
The next section covers how to move around and erase/add text in the windows. You learn the keystrokes in the quick reference card as you proceed.
Change and Check t he Date and Time
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-14 Infinity Controller Programmer’s Guide
Making Changes Inside t he WindowBelow is how to make changes inside all windows in the Infinity CX, including Open and Edit windows. (Refer to the quick reference card for exact keystrokes.)
Erasing Text
To erase all text while the cursor is in the text box, press the DELETE LINE/TEXT key. The cursor lands to the far left.
Moving to Left/Right Side of Text Box
To move the cursor to the far left of the text box without erasing the text, press the LEFT SIDE key.
To move the cursor to the far right of the text box without erasing the text, press the RIGHT SIDE key.
Restor ing Text
If, after erasing or changing it, you want to bring the text back, press the RESTORE TEXT key.
Deleting Text
To delete text in front of the cursor (to the right) one character at a time, press the DELETE TEXT key.
To delete text in back of the cursor (to the left) one character at a time, press the BACKSPACE key.
To delete only characters to the right of the cursor, arrow over to the first letter to remove and press the DELETE TO RIGHT key.
Cancelin g the Info rmation
To cancel the information in the window, press CANCEL WINDOW or MENU BAR. The window closes, and the cursor returns to the Main menu bar.
Alter User Attributes inthe Window
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-15
Inser ting Additio nal Text
To insert additional characters in the text box without overwriting current ones, press the INSERT TEXT key.
Saving Information and Clos ing Window
To save changes, you can press the SAVE key. Or you can press the EXECUTE button from any location in the window except on a button other than SAVE. Or press the SAVE button.
Table 2-1. Keys to Edit At tr ibutes in Windows
To set up controllers, proceed to the next section.
EXECUTE Can Also Save At tributes
Key or Keys Action
BACKSPACE Erases the single character that ap-pears before it. (Erases backward).
When you press it, then type, inserts text where cursor is in text box.
RIGHT SIDE Moves cursor to right side of text box.
INSERT TEXT
Arrow Keys Move the cursor left and right or up and down a list of selections.
CANCEL WINDOWor MENU BAR
Closes window and erases changes. Then returns cursor to menu bar.
DELETE TO RIGHT Deletes text to right of cursor.
DELETE LINE/TEXT Erases all text in the text box the cur-sor is in.
RESTORE TEXT Returns text in text box to what it was before you changed it.
Erases the single character that ap-pears after it. (Erases forward).
DELETE TEXT
Moves cursor to left side of text box.LEFT SIDE
NEXT ATTRIBUTE Moves cursor forward one attribute.
PREVIOUSATTRIBUTE
Moves cursor back one attribute.
EXECUTE or SAVE Saves all attributes. EXECUTE saves if not on a button that directs another action.
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-16 Infinity Controller Programmer’s Guide
Defining Infinity CX Controlle rs(If you are working on an Infinity CMX controller, you may skip this section and the next one—these steps are optional. Begin, instead with Defining the Infinet Controller Network.)
The Infinity CX 9000s and Infinity CX 9500s on your network of controllers are all connected by a cable called EnergyNet. In the menu, we call the controllers on this cable simply Controllers , while we call the other family of controllers Infinet controllers.
Before the Infinity CX controllers can interact, each has to know about the others. To tell all controllers about all other Infinity CX controllers on the EnergyNet, proceed as follows:
1. Refer to your network map. You need to know the name and DIP switch setting of each controller.
2. Select Edit Controllers from the Main menu bar.
Figure 2-8 shows the menu.
Figure 2-8. Select ing Edit Controlle rs
Give Each Controller aName
View Edit Connect Logout
UsersPointsFilesCommPortsControllersInfinet ControllersSystem Date & TimeSystem VariablesPersonsAreasDoors
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-17
Figure 2-9 shows the Open a Controller window.
Figure 2-9. Open a Controlle r Window
3. Find the name of your controller on the network map.
4. Enter the name from the network map into the Controller text box and press the EXECUTE key.
The Controller window appears. You fill in the information about the controller as explained in the next section.
Although they are not on the EnergyNet, the CMX 220 and 230 models are also “controllers” that function like Infinity CX controllers, so you can enter information about them as described here for other Infinity CX controllers; however, you do not have to. The information is optional for CMX controllers.
Open a Controller Window
Controller
Open a Controller
View Edit Connect Logout
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-18 Infinity Controller Programmer’s Guide
Sett ing Con troll er AttributesFigure 2-10 shows the Controller window.
Figure 2-10. Cont roller Windo w
Notice that each text box is labeled: NAME, DESCRIPTION, MODEL, and so on. These labels are called “attributes.”
The attribute name, as stored in the controller, may differ from the label shown on the screen; if it does, the controller view of the attribute is shown in capital letters in parentheses. You enter attributes of each controller as follows:
1. Name—Already contains the name of the controller as you typed it in the previous window. It may be up to 16 characters long and must start with a letter of the alphabet. You can include underscores, periods, and numbers in the name. If you change it here, the new name replaces the old name throughout the network.
Set EnergyNet ControllerAttri but es
Name
Description
Floor1
Serial Number
Model
SAVE
Controller – Floor1
CANCEL
Status
EnergyNet ID
DELETE
VIEW
RESET
TEACH
View Edit Connect Logout
EthernetId 0:40:11:0:0:2
Ethernet IDAppears Only
for 9200Controllers
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-19
2. Description —Type a description of the controller if you want to. It is optional.
3. Serial Number (SERIALNUM)—Later, displays the serial number of the controller. You do not enter it.
4. Model —Later, displays the model number of the controller. You do not enter it.
5. Status (COMMSTATUS)—Displays OffLine or OnLine , depending on whether the Infinity CX 9000 is on the network or not. You cannot change the status.
6. EnergyNet ID (NETWORKID)—Enter the number that the DIP switch on the controller is set to. That switch identifies each controller by a unique number between 1 and 254. The number should be on your network map, if you have one. (On a network of both controllers and workstations, you assign numbers 1 through 223 to Infinity CX controllers and 224 through 254 to Infinity SX 8000 workstations.) Once you have assigned an ID, you cannot change it.
This text box does not appear for the CMX controllers.
7. EthernetId (ETHERNETID)—This text box appears only if you are setting up an Infinity CX 9200, which runs on a network called Ethernet. The unique Ethernet ID assigned at the factory displays in this text box.
8. Press the SAVE button to save the controller settings. The window automatically closes.
Or you can press the CANCEL button to cancel the settings.
9. Repeat the steps in the section before this one and in this section to give a name to every controller on EnergyNet.
10. When you have assigned each controller a name and EnergyNet ID, connect to an EnergyNet controller
DIP Switch SettingIdentifies Controller
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-20 Infinity Controller Programmer’s Guide
through the Connect menu. (Do not carry out the next step while connected to an Infinet controller.) If you are on a CMX controller, skip the rest of this section.
11. Open the Controller window (for any controller) and press the TEACH button.
As shown in Figure 2-11, a message window appears.
Figure 2-11. Message Window during Teach
The controller now goes out and assigns the names to the controllers with the corresponding NETWORKIDs. It then fills in the model and serial number and finds the status (COMMSTATUS) of each controller. It teaches all on-line controllers about not only all other controllers on-line, but about all controllers off-line as well.
In addition, teach mode teaches all controllers on EnergyNet that the names you assigned belong to particular controllers.
Since you have already set the date and time, Infinity also teaches each controller that same date and time.
You cannot access the controller until teaching stops.
Teach Mode is Active.
Give the Teachi ngProcess a Few Secon ds
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-21
Lookin g at th e Contro ller Sum mary
Once Infinity has taught all the controllers about the network, the Controller Summary window appears on the screen.
Figure 2-12 shows the Controller Summary window.
Figure 2-12. Cont roller Summary Windo w
Note that all controllers should be OnLine because you connected them to the EnergyNet. If any are still OffLine , check them, properly connect them, and press TEACH again.
If you assigned more than one controller the same NETWORKID number, a new window appears.
EnergyNet Summary Gives Overview of All
Name Model ID Status
Controller Summary - Floor1
Floor1 9000 1 OnLineFloor2 9500 2 OnLine
View Edit Connect Logout
CentralStation 8000 223 OnLine
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-22 Infinity Controller Programmer’s Guide
Figure 2-13 shows the message that the window displays.
Figure 2-13. Message Window in Response to Duplic ate IDs
12. If you see a controller in the summary that you want more information about, arrow down until it is highlighted and press the EXECUTE key to open its Controller window.
13. Press the CANCEL WINDOW key to close the summary. If you close the summary by mistake, press VIEW to reopen it.
From the Controller Summary window, you can now take any of the following actions:
1. You can press DELETE to delete any controller other than the one you are directly physically connected to or the one you have connected to through the Connect menu.
2. Do not press RESET now. RESET erases the controller and all its points and programs. If you press RESET, Infinity tells you that RESET destroys all points and programs and asks if you want to cancel. Press YES to cancel the reset.
You are now ready to proceed with the next section, where you set up the Infinet controllers.
You Have Assigned More Than One Controller the Same ID Number
You Canno t DeleteConnected Controller
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-23
Summary
• You must identify all Infinity CX controllers as on the network using the Edit Controllers menu selection.
• The status of the controller is either OnLine or OffLine .
• Each controller has a DIP switch that identifies it by being set to a unique number from 1 to 254.
• In a network of both controllers and workstations, Infinity CX controllers must have IDs 1 to 223 and Infinity SX 8000 workstations 224 to 254.
• The EnergyNet ID text box (NETWORKID attribute) in
the Controller window contains the number the DIP switch is set to.
• While setting up any particular controller, you can press CANCEL to erase information you have not yet saved.
• You use TEACH to tell each controller its name and to retrieve its model number and serial number.
• You can press DELETE to delete a controller from the network, but cannot delete the one you are connected to or your terminal is physically connected to.
• You can press VIEW to open the Controller Summary window.
• If you press RESET, you erase all programs and other information in the controller.
Ident ify Infin ity CXControllers
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-24 Infinity Controller Programmer’s Guide
Defining the Inf inet Controller NetworkEach Infinity CX 9000 series controller on the EnergyNet network has communication ports (comm ports). Some of these comm ports can connect Infinet cabling to the controller Infinity CX or CMX controller. On this cabling, you install Infinet controllers.
Before you can define any Infinet controllers that are on the network, you must define the port the Infinet cabling is connected to as an Infinet port, as follows:
1. Select Edit Comm Ports from the Main menu bar.
Figure 2-14 shows the menu.
Figure 2-14. Selec ting Edit Comm Ports to Set Up Infin et
Figure 2-15 shows the Open a Comm Port window that appears.
Define the Comm Port asan Infin et Port
Points
Users
Controllers
Infinet Controllers
System Date & Time
View Edit Connect Logout
Comm Ports
Files
System Variables
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-25
Figure 2-15. Open a Comm Po rt Window
2. Verify the name of the Infinity CX controller from the network map.
3. If the correct name does not appear in the Controller text box, press the BACKSPACE key or DELETE TEXT key to erase it. Then type the correct name.
Or press the SHOW LIST key to see a list of controller names. To select a name, arrow to it. When the correct name is highlighted, press the EXECUTE key to put the name in the Controller text box.
4. Arrow to the Name text box (or press the NEXT ATTRIBUTE key to get there).
5. Press the SHOW LIST key for a list of the comm port names on the controller. For an Infinity CX 9000, three names appear, COMM1, COMM2, and COMM3. For other 9000 series controllers, you may also see COMM4. On still other models, you may see only UserPort and InfinetPort.
6. Refer to your network map to find out which port has an Infinet on it. For the Infinity CX 9000 or 9200, you can have one or two Infinets. For other models, you can have only one Infinet.
Controller
Open a Comm Port
View Edit Connect Logout
Name
Veri fy the Name of the EnergyNet Controller
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-26 Infinity Controller Programmer’s Guide
For an Infinity CX 9000, the port must be COMM1 or COMM2. For an Infinity CX 9500, it must be InfinetPort. For an Infinity CX 9200, the port must be COMM1 or COMM2. On a CMX 220 or 240, it must be InfinetPort.
Refer to the table below to be sure you are selecting the correct port.
Never select UserPort for Infinet.
If you have a DCX 250 mounted inside your 9000 controller, you must set up COMM2 as an Infinet, since this DCX 250 is always on the Infinet on COMM2.
A DCX 250 that stands alone in an enclosure can be on either COMM1 or COMM2.
If you plan to connect the LSX 280 laptop computer service tool to the service port inside the Infinity CX 9000, you should make COMM2 an Infinet.
7. Arrow to the name of the comm port for Infinet and press the EXECUTE key to put it in the Name text box.
Table 2-2. Comm Ports for Infinet on Infini tyCX and CMX Contro llers
ControllerModel
Comm Ports That Can Have Infinet Attached to Them
9000 COMM1 and COMM2
9200 COMM1 and COMM2
9500 InfinetPort
220/240 InfinetPort
Never Select UserPortfor Infin et
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-27
Summary
• Infinet cables on the Infinity CX 9000 are connected through one of the three communications ports.
• Up to two of the communications ports on an Infinity CX 9000 can be for Infinets, only one on an Infinity CX 9500 or Infinity CMX 220/230.
• The three comm ports on the Infinity CX 9000 are predefined as COMM1, COMM2, and COMM3. Only COMM1 or COMM2 can have an Infinet attached to it.
• The predefined Infinet port on an Infinity CMX controller is called InfinetPort.
Select the Infin et Type
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-28 Infinity Controller Programmer’s Guide
Sett ing Infinet Att ribut esand Finding Cont roller sFigure 2-16 shows the Comm Port window that appears. The Mode and the LEARN and VIEW buttons do not appear until you select Infinet in the DefaultMode box.
Figure 2-16. Comm Port Window
You enter the following attributes:
1. Name—Already contains the name of the port. You can change it here. It may be up to 16 characters long and must start with a letter of the alphabet. You can include underscores, periods, and numbers in the name. If you change it here, the new name replaces the old name throughout the network.
2. Description —Type a description of the comm port if you would like. It is optional. This information is strictly for you and does not affect the controller.
Give Infin et Attri but es
Baud( ) Baud300( ) Baud1200( ) Baud2400( ) Baud4800( ) Baud9600(X) Baud19200
Name Description
Comm Port – Floor1 Comm1
LocalNET
SAVE
Infinet Cable
CANCEL
LEARN
VIEW
Mode Infinet
View Edit Connect Logout
DefaultMode(X) Printer( ) Window( ) Command( ) Infinet( ) Lbus( ) AutoSet( ) TankNet
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-29
3. DefaultMode —Select Infinet for the Infinet cable. If you are setting up Infinet on an Infinity CMX controller, Infinet is automatically selected for you.
4. Baud —Automatically set to Baud19200 .
5. Mode —You cannot change this box. It displays the current way the comm port is operating, Infinet .
6. After you select the Infinet type, the LEARN button appears. Press the LEARN button.
As shown in Figure 2-17, a message window appears.
Figure 2-17. Message Window during Learn
The controller now goes out and explores the network.It finds the serial numbers and assigns IDs to all Infinet controllers on that comm port. It then finds the model and status.
You cannot access the controller until it stops learning, within 15 seconds.
Once learn mode is complete, the Infinet Summary appears.
Figure 2-18 shows the window. It contains the known attributes of each Infinet controller on the comm port. Infinity has assigned each a name based on its serial number.
Learn Mode is Active.
Give the Controller a Few Seconds to Learn
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-30 Infinity Controller Programmer’s Guide
Figure 2-18. Complete Infinet Summary
7. You can select a controller from the list to rename it or you can return to the comm port information.
To select a controller, arrow to it and, while it is highlighted, press the EXECUTE key. The Infinet Controller window opens. If you select this option, you may skip the next few steps and skip the next section. Continue with the section titled Understanding Infinet Controller Attributes.
OR
To return to the comm port information, press the CANCEL WINDOW key and the Comm Port window appears.
8. If you close the Infinet Summary window before you have had a chance to look at the list, you can press the VIEW button to reopen the window. (Do not press LEARN again to open the window, only to relearn the network.)
View Edit Connect Logout
Infinet Summary – FLOOR1
Port Name Model Serial Number ID Status
COMM1 lc_0989001_0 850 0989001 01 OffLine
COMM1 lc_0989002_0 850 0989002 02 OffLine
COMM1 lc_0989003_0 850 0989003 03 OffLine
COMM1 lc_0989004_0 850 0989004 04 OffLine
COMM1 lc_0989005_0 850 0989005 05 OffLine
COMM1 lc_0989006_0 900 0989006 06 OffLine
COMM1 lc_0989007_0 900 0989007 07 OffLine
COMM1 lc_0989008_0 900 0989008 08 OffLine
COMM1 lc_0989009_0 900 0989009 09 OffLine
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-31
9. Press the SAVE button, SAVE key, or EXECUTE key to save the comm port attributes and all the Infinet controller information on that comm port. The window automatically closes.
If you have network problems, refer to the EnergyNet and Infinet Troubleshooting Guide.
Summary
• Infinet cables on the Infinity CX 9000 are connected through one of the three communications ports.
• Up to two of the communications ports on an Infinity CX 9000 can be for Infinets, only one on an Infinity CX 9500 or Infinity CMX 220/230.
• The three comm ports on the Infinity CX 9000 are predefined as COMM1, COMM2, and COMM3. Only COMM1 or COMM2 can have an Infinet attached to it.
• The predefined Infinet port on an Infinity CMX controller is called InfinetPort.
• You must select Infinet for the DEFAULTMODE of the comm port.
• After you select Infinet , the MODE displays as Infinet .
• After you select Infinet , the BAUD is automatically Baud19200 .
• Press the LEARN button to have Infinity automatically assign names and ID numbers to each Infinet controller on the comm port.
• Press the VIEW button to open the Infinet Summary window.
Select the Infin et Type
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-32 Infinity Controller Programmer’s Guide
Opening Infinet ControllersOnce you have defined an Infinet connection port for the Infinet controllers on the Infinity CX controller, you may then open each Infinet controller to alter its name and look at its other attributes, as follows:
1. Select Edit Infinet Controllers from the Main menu bar.
Figure 2-19 shows the menu.
Figure 2-19. Selec ting Edit Infinet Controllers
Select Edit In fin etController
View Edit Connect Logout
UsersPointsFilesCommPortsControllerInfinet ControllerSystem Date & TimeSystem VariablesPersonsAreasDoors
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-33
Figure 2-20 shows the Open a Controller window.
Figure 2-20. Open an Infin et Controlle r Window
2. Verify the name of the Infinity CX 9000 controller from the network map. If the correct name does not appear in the Controller text box, press the LEFT SIDE key to move to the left side of the box. Then type over the name there with the correct one. Or use the SHOW LIST key to select another name.
You can also erase names in the text boxes with the BACKSPACE or DELETE TEXT keys.
3. Arrow to the Infinet Ctlr text box (or press the NEXT ATTRIBUTE key).
4. Refer to the tag for the controller you want to define. Enter a name for that controller. The name may be up to 16 characters long and must start with a letter of the alphabet. You can include underscores, periods, and numbers in the name.
5. Press the EXECUTE key.
The Infinet Controller window appears. You fill in the information about the Infinet controllers as explained in the next section.
Controller
Open an Infinet Controller
View Edit Connect Logout
Infinet Ctlr
Select the Infin ity CX Controller
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-34 Infinity Controller Programmer’s Guide
Under standing Infinet Controller At tri butesFigure 2-21 shows the Infinet Controller window.
Figure 2-21. Infinet Controller Window
You set the attributes as follows:
1. Name—Already contains the name you assigned the Infinet controller in the previous window. If it is incorrect, change the name. The new name replaces the old name throughout the network.
2. While the cursor is in the Name text box, press the SHOW LIST key. The Infinet Summary window appears.
3. Arrow down to the controller that has a serial number matching the one on the tag from the hardware. (Compare the numbers carefully.) When the correct controller is highlighted, press the EXECUTE key to select it. That controller’s attributes now fill the other text boxes.
Can Give EachController a Description
Name
Model
Room2
Infinet Controller – Floor1 Room2
Description
Infinet ID
Serial Number Status
Error
CommPort
Error Time
850
Error Count
COMM1
Air Flow Controller
01
0989001 OnLine
0
0
0 0
View Edit Connect Logout
Version
Reconfigs
1.4
DELETE
SAVE AS
CANCEL
SAVE
RESET
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-35
4. Model —Displays the model number of the controller. You cannot change it.
5. Version —Displays the version of the controller PROMs.
6. Description —Type a description of the Infinet controller if you want to. It is optional. You can enter up to 32 characters including blanks.
7. CommPort (PORT)—Displays the name of the particu-lar comm port this Infinet is on, either COMM1, COMM2, or InfinetPort.
8. Infinet ID (INFINETID)—Displays the Infinet ID. You cannot change the ID. (You can elect to press SHOW LIST with the cursor in this text box to see the summary.)
9. Serial Number (SERIALNUM)—Displays the serial number of the Infinet controller. You can verify it against the tag that was on the hardware. You cannot change the serial number. (You can elect to press SHOW LIST with the cursor in this text box to see the summary.)
10. Status (COMMSTATUS)—Displays OffLine or On-Line , depending on whether the Infinet controller is on the network or not. (Later may also display Reconfig or Pause to indicate activity on the network.) You cannot change the status.
11. Error (INFINETERROR)—Displays the last error that occurred on the controller.
12. Error Time (INFINETERRTIME)—Displays the date and time the last error occurred.
13. Error Count (INFINETERRCNT)—Displays the number of errors that have occurred. You later reset the error count to zero from an Andover Controls Plain English program.
Infin et Contr oller Models
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-36 Infinity Controller Programmer’s Guide
14. Reconfigs (RECONFIGS)—Displays the number of reconfigurations that have occurred on the Infinet that controller is on. You later reset to zero from a program.
15. Press the SAVE AS button to save the controller settings without closing the window.
16. Type the correct name for the controller in the Name text box that appears. When you press the EXECUTE key, the controller is saved with that name. The new name also appears in the Infinet Summary window.
The cursor lands in the Name text box.
17. Press the SHOW LIST key and the Infinet Summary window appears, showing all the information known about each controller on the same comm port.
18. Arrow down to the next controller you want to define and, while it is highlighted, press the EXECUTE key. Again, be sure you carefully compare the serial number to the one on the tag.
The information about that controller appears in the Infinet Controller window—all except the name.
19. Press SAVE AS and enter the correct name in the Name text box that appears. When you press the EXECUTE key, the new name appears in the Infinet Summary window.
20. Repeat the last three steps, selecting the next controller each time and renaming it. Remember you are assigning the name after you select the controller from the list.
21. When you have renamed the last Infinet controller on that comm port, press the SAVE button, SAVE key, or EXECUTE key to save the controller information. The window automatically closes.
Select an Infin etController
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-37
22. Repeat the entire process for the other comm port if you have more than one Infinet.
Do not press RESET now. RESET erases the controller and all information on the controller. If you press RESET, Infinity asks if you want to cancel. Press YES to cancel the reset.
You can work on any controller you have defined from one terminal. To see how, read the next section.
Summary
• You must define all Infinet controllers.
• The CommPort for the Infinet controller is the name of the port the Infinet is connected to.
• LEARN assigns the Infinet ID of each Infinet controller.
• The Serial Number of the controller should match the one on the tag for that controller.
• The status is usually either OnLine or OffLine .
• The Error text box displays the last error on the particular controller; Error Time displays the date and time it occurred.
• Error Count displays the number of errors since you last set it to zero.
• Reconfigs displays the number of times the Infinet comm port has reconfigured itself since you last set it to zero.
• To see the Infinet Summary from inside the Infinet Controller window, press the SHOW LIST key inside the Name, Infinet ID , or Serial Number text box.
• To select a controller from the Infinet Summary , arrow down to it and, when it is highlighted, press the EXECUTE key.
Infin et Is Located on a Comm Port
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-38 Infinity Controller Programmer’s Guide
Accessing ( Connect ing to) Other Cont rol lersAfter you have told the controller about all other controllers on the network, you can work on any controller on EnergyNet or Infinet from your terminal.
You can connect to any controller on EnergyNet or Infinet. If the controller is an Infinet controller, you must first indicate the EnergyNet controller it is on. You connect to a particular controller as follows:
1. Select Connect from the Main menu bar.
Figure 2-22 shows the Open a Connection window that appears.
Figure 2-22. Open a Conn ection Windo w
2. To change the Infinity CX 9000 name displayed in the
Controller text box, you can:
• Erase the name displayed and type another controller name
OR
Connect to AnotherInfin ity CX 9000
Controller
Open a Connection
Infinet Ctlr
Floor1
View Edit Connect Logout
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-39
• Press the SHOW LIST key to bring up a choice list of Infinity CX 9000 controllers.
The list of Infinity CX 9000 controllers is in alphabetical order.
Press the up and down arrow keys (UP and DOWN) or the PAGE UP and PAGE DOWN keys to move up and down the list of Infinet controllers to highlight the one you want.
3. Press the EXECUTE key to put the name of the Infinity CX controller in the Controller text box. If you are connecting only to an Infinity CX controller, skip to the last step on this page.
4. Press NEXT ATTRIBUTE to move to the Infinet Ctlr text box.
5. If you want to access an Infinet controller, repeat step 2, only this time type or select the name of an Infinet controller.
The list of Infinet controllers is in alphabetical order.
6. Press the EXECUTE key. Now you can take action on the Infinity CX 9000 or Infinet controller you selected here. The controller name or names appear in any Open window each time you select an item from the Edit menu.
In the next section, you find out how to carry out this same action from inside the Command window.
Change to Another Infin et Contr oller
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-40 Infinity Controller Programmer’s Guide
An Alter native Method of Accessing Other ControllersYou can work on a controller other than the one your terminal is physically connected to. Proceed as follows:
1. Press the CANCEL WINDOW key. The cursor moves to the Command window.
2. Type CD (change direct connection) followed by the name of an Infinity C (EnergyNet) controller:
CD FLOOR1
3. If the controller is on Infinet, you give first the Infinity CX controller that the Infinet is connected to, then the Infinet controller name:
CD FLOOR1 ROOM2
Figure 2-23 shows a CD command in the Command window. (Remember not to type the R>.)
Figure 2-23. CD Command Li ne
Connect to Controllerswit h the Connect Menu
R> CD FLOOR1 ROOM2 R>
Command Window – FLOOR1
View Edit Connect Logout
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
Infinity Controller Programmer’s Guide 2-41
4. Press the EXECUTE key. Now you can take action on the Infinity CX 9000 or Infinet controller you gave here. The controller name or names appear in the Open window each time you select an item from the Edit menu.
You can now proceed to the next chapter, where you set up the Lbuses, terminals, and printers. You then create your own logon and password, finally, create logons and password for all others who use the controller system.
Summary
• You can access another controller after you have given names to all the controllers on your network.
• You can connect to another controller either from the Main menu bar or from the Command window.
• On the Main menu bar, arrow to the Connect menu and press the EXECUTE key.
• In the Command window, type the CD command followed by the name of the Infinity CX controller, then the Infinet controller.
Two Ways to Connect to Another Controller
www.PDF-Zoo.com
Setting Up EnergyNet/Infinet
2-42 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Chapter 3
Setting Up LBuses,Terminal s, Printers, TankN ets,
and User Logons
We recommend you read this chapter sequentially. You carry out the procedures in this chapter (listed below) on an Infinity CX controller or Infinity CMX controller through the terminal. You begin with LBUSes. If you do not have any LBUSes, skip those sections and begin with terminals. If you have a TankNet, after you complete the printers section, you set up your TankNet. The sections are as follows:
• Defining the LBUS for Input/Output Units
• Setting LBUS Attributes
• Defining Terminals or Printers
• Setting Terminal Attributes
• Setting Up Modem Attached Directly to the Controller
• Setting Up Modem Attached to a Terminal
• Setting Printer Attributes
• Defining the TankNet for Tank Probes
• Setting TankNet Attributes
• Creating Your Own Logon
• Creating Other User Logons, Assigning Security Levels
• Copying All User Logons to Multiple Controllers
• Setting the Password for Keypads on Infinet Controllers
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-2 Infinity Controller Programmer’s Guide
Defining the LBUS for Input/Output UnitsThe LBUS cable connects all input-output units (IOUs) to the Infinity CX 9000 controller. You may or may not have an LBUS on your controller. If you have one, you must tell the controller about it.
Each Infinity CX 9000 controller on the EnergyNet network has three “communication ports” (comm ports). They are called communication ports because they allow information to travel into and out of the controller. One (and only one) of those ports can be used for an LBUS cable, and the port must be either COMM1 or COMM2.
You must define one of the comm ports for the LBUS of that Infinity CX 9000, as follows:
1. Select Edit Comm Ports from the Main menu bar.
Figure 3-1 shows the menu.
Figure 3-1. Select ing Edit Comm Ports
Figure 3-2 shows the Open a Comm Port window.
One Comm PortConnects the LBUS
View Edit Connect Logout
UsersPointsFilesCommPortsControllerInfinet ControllerSystem Date & TimeSystem VariablesPersonsAreasDoors
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-3
Figure 3-2. Open a Comm Port Window
2. Verify the name of the Infinity CX 9000 controller from the network map. If the correct name does not appear in the Controller text box, press the DELETE LINE/TEXT key to erase the name. Then type the correct name. Or use the SHOW LIST key to select another name.
3. Arrow to the Name text box (or press NEXT ATTRIBUTE) and press the SHOW LIST key for a list of the comm port names. The three predefined names appear in a choice list: COMM1, COMM2, and COMM3.
4. Select COMM1 or COMM2 and press the EXECUTE key. (You may change the name in the next window.) Then press the EXECUTE key to move to the next window.
Controller
Open a Comm Port
Name
View Edit Connect Logout
Select a Comm Port Name
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-4 Infinity Controller Programmer’s Guide
Sett ing LBU S At tri butesFigure 3-3 shows the Comm Port window that appears.
Figure 3-3. Comm Port Window fo r LBus
You enter the following attributes:
1. Name—Already contains the name of the port. It may be 16 characters long and must start with a letter of the alphabet. You can include underscores, periods, and numbers in the name. If you change it here, the new name replaces the old name throughout the network.
2. Description —Type a description of the comm port if you would like. It is optional. This information is strictly for you and does not affect the controller.
3. DefaultMode —Select LBUS for the LBUS cable.
4. Baud —Automatically set to Baud19200 .
Give LBUS Attr ibut es
Baud( ) Baud300
( ) Baud1200
( ) Baud2400
( ) Baud4800
( ) Baud9600
(X) Baud19200
Name Description
Comm Port – FLOOR1
COMM1
SAVE
LBUS for IOUs
CANCEL
DefaultMode( ) Printer( ) Window( ) Command( ) Infinet(X) Lbus( ) AutoSet
Mode Lbus
View Edit Connect Logout
( ) TankNet
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-5
5. Mode —You cannot change this box. It displays the current way the comm port is operating, Lbus .
6. Press the SAVE button, SAVE key, or EXECUTE key to save the comm port attributes. The window automatically closes.
Summary
• The LBUS on the Infinity CX 9000 network is connected through one of the three communications ports.
• Only one of the three comm ports can be for an LBUS.
• The LBUS is connected on COMM1 or COMM2.
• You must select Lbus for the DEFAULTMODE of the comm port.
• After you select Lbus , the MODE displays as Lbus .
• After you select Lbus , the baud is automatically set to Baud19200 .
Select the LBUS for the DefaultMode
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-6 Infinity Controller Programmer’s Guide
Defining Terminals or Pri ntersThe computer screens attached to your network are usually referred to as “terminals” because they are endpoints on the network.
(A terminal can also be a complete computer running an ANSI terminal emulation package.)
NoteIf you would like more than one terminal, check the amount of free memory by typing PR FREEMEM in the Command window. If you do not have at least 400,000 bytes of free memory, do not add a second terminal to your Infinity CX 9000 controller or the comm port you try to set it up on becomes unusable.
You connect terminals and printers to the comm ports to al-low humans to interact with and/or communicate with the controller.
Connecti ng to Infinity CX 9000
You can connect a terminal or printer to any of the open RS-232 ports on Infinity CX 9000. (COMM1 and COMM2 RS-232 ports are not “open” if you are using their corresponding RS-485 ports.) If you connect any of these through a modem, the preinstalled modem is on COMM3.
(COMM3 can connect only to terminals, printers, computers, or modems, but not to LBUS or Infinet.)
If you connect, for example, a terminal through a modem, when you define the comm port, you define it for a terminal.
Minimum Free Memoryfor Second Terminal
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-7
Connecti ng Termina l toan Infi nity CM X Control ler
You can connect a terminal to the UserPort on an Infinity CMX controller.
CautionRemember that on an Infinity CMX controller, the modem always preempts the terminal and takes over control of the UserPort, even when an operator is logged on and actively using the port. The operator could lose changes to an unsaved program or other item when the modem call occurs.
You should not connect a printer to the CMX UserPort.
Setting Up the Termina l
Define a terminal or printer on your Infinity CX 9000 or ter-minal on your Infinity CMX controller as follows:
1. Select Edit Comm Ports from the Main menu bar.
Figure 3-4 shows the menu.
Connect Terminals, Printers
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-8 Infinity Controller Programmer’s Guide
Figure 3-4. Select ing Edit Comm Ports
Figure 3-5 shows the Open a Comm Port window that appears.
Figure 3-5. Open a Comm Port Window
2. Verify the name of the controller from the network map. If the correct name does not appear in the Controller text box, press the DELETE LINE/TEXT key to erase the name. Then type the correct one. Or use the SHOW LIST key to select another name.
3. Check your network map for the name of your terminal, computer, or printer.
View Edit Connect Logout
UsersPointsFilesCommPortsControllerInfinet ControllerSystem Date & TimeSystem VariablesPersonsAreasDoors
Controller
Open a Comm Port
Name
View Edit Connect Logout
DELETE LINE/TEXTErases Entire Name
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-9
4. On an Infinity CX 9000, press the SHOW LIST key and select COMM3.
OR
On an Infinity CMX controller, press the SHOW LIST key and select UserPort.
5. When the comm port you want is in the Name text box, press the EXECUTE key to proceed.
The Comm Port window opens. To fill in the text boxes in that window, proceed to the next section.
Connect Terminals, Printers
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-10 Infinity Controller Programmer’s Guide
Sett ing Termi nal AttributesFigure 3-6 shows the Comm Port window. If you opened COMM3 on an Infinity CX controller, it is already predefined as a terminal, but you may want to change how it is set up.
Figure 3-6. Comm Port Window for Termi nal
You enter the following attributes for a terminal or computer with or without a modem (see next section for printer attributes):
1. Name—Change the comm port name to the name of your terminal in the Name text box. It may be 16 characters long and must start with a letter of the alphabet. You can include underscores, periods, and numbers in the name. If you change it here, the new name replaces the old name throughout the network.
2. Description —Type a description of the comm port if you would like. It is optional. This information is strictly for you and does not affect the controller.
Give Terminals andComputers Attr ibut es
SAVE
CANCEL
Name Description
Comm Port – FLOOR1
SCREEN1
Baud( ) Baud300
Terminal in Basement
( ) Baud1200
( ) Baud2400
( ) Baud4800
(X) Baud9600
( ) Baud19200
TerminalType(X) VT100( ) VT220( ) WYSE
DefaultMode
Mode Window DirectConnect X
CurrentUser len
View Edit Connect Logout
( ) Printer(X) Window( ) Command( ) Infinet( ) Lbus( ) AutoSet( ) TankNet
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-11
3. DefaultMode —Select one of the following three:
• Select Window to display the windows and menus. You would choose this option for most terminals.
If a terminal is on a modem and you set it up to run in Window mode, to get started on that terminal, you must type an ampersand (&) to receive the Infinity window.
• Select Command to display a screen with no windows or menus, only the Login prompt.
(This choice is available only on an ICS AC 9100 or on AC 220 controllers with model number 230 or higher. See your Andover Controls representative for details.)
Figure 3-7 shows the screen that later appears on that terminal if you select Command for DEFAULTMODE.
Figure 3-7. The Command Screen
If a terminal is on a modem and you set it up to run in Command mode, to get started on that terminal, you must type an ampersand (&) to receive the Login prompt.
Window, Command, or AutoSet Modes
Login:
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-12 Infinity Controller Programmer’s Guide
On the Command screen, you enter your logon name and wait for further prompts. On this screen, you cannot move the cursor up and down as you can in the Command window.
• Select AutoSet if you want to be able to switch between Window and Command , or if you want to connect to an Infinity SX workstation Version 1.3.
Later, when you turn on the terminal, it comes up totally blank. You type one of the following and press the EXECUTE key after it (the word does not appear on the screen):
COMMANDor
WINDOW
COMMAND brings up the Login prompt that appears on the Command mode screen. WINDOW brings up the logon window. To change the mode, you log out, and when the screen becomes blank again, type COMMAND or WINDOW.
4. Baud —Select the baud rate your terminal or computer is set to. See the terminal manufacturer’s manual for procedures to set the baud rate or find out the default baud rate setting.
5. TerminalType —Select the brand of terminal, VT100, VT220, or WYSE, for an actual terminal or VT100 for a computer emulating one.
6. CurrentUser —You cannot change this box. It displays the user name of the person currently logged on through that communications port.
7. Mode—You cannot change this box. It displays the cur-rent way the terminal is operating, either in Window or Command mode. If you selected AutoSet , the mode may change periodically.
Select t he Baud Rate ofthe Terminal
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-13
8. DirectConnect —If your terminal or computer is set up through a modem, press the space bar in this box to toggle it to FALSE (no X appears), otherwise (the X appears) it is TRUE.
The modem itself is not the type of equipment you define; instead, you define the equipment attached to the other end of the modem—the terminal or computer—and then set DirectConnect to FALSE.
9. Press the SAVE button, SAVE key, or EXECUTE key to save the terminal or printer attributes. The window automatically closes.
If your terminal is on a modem, complete the steps in one of the next two sections. Otherwise, skip those sections. If you are setting up a printer, skip the modem sections and go to the next.
Summary
• You select Window as the DEFAULTMODE of your terminal for most Infinity CX and CMX controllers.
• You can select Command for the DEFAULTMODE of the terminal or computer if it is an Infinity CX 9100 or CMX 230.
• You can select AutoSet for the DEFAULTMODE of the any terminal if you want to switch between Command and Window modes, or to connect to an Infinity SX 8000.
• The MODE displays either Window or Command , depending on the mode the terminal is currently operating in.
• You leave DIRECTCONNECT set to TRUE if your computer or terminal is not set up through a modem.
• You select the terminal type based on the brand.
• You may want to change the name of the port from COMM1, COMM2, or COMM3 to the name of your terminal.
Make DirectConnect TRUE If Not on Modem
Select Window asDefaultMode
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-14 Infinity Controller Programmer’s Guide
Sett ing Up M odem Att ached Directly to the Infinity CX ControllerIf your modem shipped already installed inside the Infinity CX 9000or in a retrofit kit, you can skip this section.
If your modem was shipped alone without a retrofit kit, you must set it up to work on an Infinity CX 9000 or a terminal.
To set up a modem to be attached to a comm port on a controller, proceed as follows:
1. If you have already installed it, disconnect the modem ribbon cable from the port inside the Infinity CX 9000 cabinet and attach it to a dumb terminal. (You can use a computer if you run a terminal emulation package, such as CROSSTALK.)
2. Set the terminal or emulation package to 9600 baud.
3. On the dumb terminal, enter each of the following commands and press the RETURN key (EXECUTE key) after each one (the modem sends OK to the terminal after each command):
AT&F
AT&C1
AT&D21
AT\N3
AT%C1
AT\J
1. Do not include this command if you are still operating Version 1.0.
Preinstalled Modems AreAlready Set Up
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-15
AT%B9600 (The last two characters are zeros.)
AT\Q1
ATS0=1 (The character before the equal sign is zero.)
ATE
ATQ1 (Characters do not show on the screen and no response appears.)
AT&W (Characters do not show on the screen and no response appears.)
4. Reconnect the modem ribbon cable to the controller.
Your modem is now ready.
Summary
• You do not have to set up a modem if it ships already installed or in a retrofit kit.
• You connect a dumb terminal to the modem to set it up.
• You enter a series of commands on the dumb terminal that set up the modem.
• Once you have entered the commands, you reconnect the modem ribbon cable to the controller and your modem is ready to operate.
Modem Is Ready
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-16 Infinity Controller Programmer’s Guide
Sett ing Up M odem Attached to a Termina l on Infini ty CX ControllerTo set up a modem you want attached to a terminal for calling an Infinity CX controller across town or across the country, proceed as follows:
1. If you have already connected your terminal to Infinity CX 9000 and the controller is powered up, disconnect the terminal from the controller.
If your terminal is a computer, you must run a terminal emulation package, such as CROSSTALK and be in dumb terminal mode.
2. Set the terminal or emulation package to 9600 baud.
3. Connect the modem to the terminal with a standard ribbon cable.
Do not use the same cable that connects the terminal to the Infinity CX 9000 to connect your modem to your terminal. Andover Controls does not supply the correct cable; the one provided is designed only to connect the terminal to the controller. The pinouts for each cable type are included in the Andover Controls Infinity CX 9000 Hardware Installation Guide.
4. On the dumb terminal, enter each of the following commands and press the RETURN key (EXECUTE key) after each one (the modem sends OK to the terminal after each command). Be sure you enter them in the order listed:
AT&F
AT&C1
AT&D21
You Set Up a Modem toAttach t o a Terminal
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-17
AT\N3
AT%C1
AT\J
AT%B9600 (The last two characters are zeros.)
AT\Q1
ATS0=1 (The character before the equal sign is zero.)
AT&W
5. Reconnect the ribbon cable of the terminal (or computer) to the comm port on Infinity CX 9000.
Your modem is now ready.
For how to log onto the Infinity CX, see Chapter 2. For a list of modem commands to dial and hang up the modem, see the modem documentation.
Summary
• If you want to attach a modem to a terminal, you must set it up.
• You connect a dumb terminal to the modem to set it up.
• You use a standard ribbon cable to connect a dumb terminal to the modem.
• You enter a series of commands on the dumb terminal that set up the modem.
• Once you have entered the commands, you reconnect the terminal to the controller and your modem is ready to operate.
1. Do not include this command if you are still operating Version 1.0.
Last Two Characters Are Zeros
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-18 Infinity Controller Programmer’s Guide
Sett ing P rinter At tribute sFigure 3-8 shows the Comm Port window.
Figure 3-8. Comm Port Window fo r Printer
You enter the following attributes for a printer:
1. Name—Change the comm port name to the name of your printer in the Name text box. It may be 16 characters long and must start with a letter of the alphabet. You can include underscores, periods, and numbers in the name. If you change it here, the new name replaces the old name throughout the network.
2. Description —Type a description of the comm port if you would like. It is optional. This information is strictly for you and does not affect the controller.
Give Printers Attr ibutes
SAVE
CANCEL
Name Description
Comm Port – FLOOR1 Comm3
SCREEN1 Printer in Lab
DefaultMode
Mode Printer
View Edit Connect Logout
Baud( ) Baud300
( ) Baud1200
( ) Baud2400
( ) Baud4800
(X) Baud9600
( ) Baud19200
(X) Printer( ) Window( ) Command( ) Infinet( ) Lbus( ) AutoSet( ) TankNet
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-19
3. DefaultMode —Select Printer for a printer.
4. Baud —Select the baud rate your printer is set to. See the manufacturer’s manual on the printer for procedures to set the baud rate or find out the default baud rate setting.
5. Mode—You cannot change this box. It displays the current way the comm port is being used, for a Printer .
6. Press the SAVE button, SAVE key, or EXECUTE key to save the terminal or printer attributes. The window automatically closes.
You have now set up every physical part of your controller system—except the points. Before you proceed to Chapter 4 to set up the points, you must define who can have access to the system, covered in last few sections of this chapter.
Summary
• You select Printer for the DEFAULTMODE of a printer.
• You may want to change the name of the port from COMM1, COMM2, or COMM3 to the name of your printer.
Select Printer forDEFAULTMODE
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-20 Infinity Controller Programmer’s Guide
Defining the TankNetfor Tank P robesThe TankNet cable connects to many Infinity CX controllers and to the CMX 240 controller. You may or may not have a TankNet on your controller. If you have one, you must tell the controller about it.
Each Infinity CX 9000/9200 or CMX 240 controller has “communication ports” (comm ports). They are called communication ports because they allow information to travel into and out of the controller. You can use one and only one of those ports on any controller for TankNet cable. Which port depends on the model number of the controller.
You define one of the comm ports for the TankNet of that controller, as follows:
1. Select Edit Comm Ports from the Main menu bar.
Figure 3-9 shows the menu.
Figure 3-9. Select ing Edit Comm Ports
Figure 3-10 shows the Open a Comm Port window.
TankNet Connects TankProbes to Controllers
View Edit Connect Logout
UsersPointsFilesCommPortsControllerInfinet ControllerSystem Date & TimeSystem VariablesPersonsAreasDoors
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-21
Figure 3-10. Open a Comm Po rt Window
2. Verify the name of the Infinity CX 9000 controller from the network map. If the correct name does not appear in the Controller text box, press the DELETE LINE/TEXT key to erase the name. Then type the correct name. Or use the SHOW LIST key to select another name.
3. Arrow to the Name text box (or press NEXT ATTRIBUTE) and press the SHOW LIST key for a list of the comm port names. The predefined names appear in a choice list. The comm port you can choose depends on the model of the controller. Below are the comm ports you can choose for TankNet:
• 9000 series—COMM1 or COMM2
• 9200—COMM1, COMM2, COMM3, or COMM4
• 240—CUSTOMPORT
4. Select the comm port your TankNet is wired to and press the EXECUTE key. (You may change the name in the next window.) Then press the EXECUTE key to move to the next window.
Controller
Open a Comm Port
Name
View Edit Connect Logout
Select a Comm Port Name
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-22 Infinity Controller Programmer’s Guide
Sett ing TankNet At tributesFigure 3-11 shows the Comm Port window that appears.
Figure 3-11. Comm Por t Window for TankNet
You enter the following attributes:
1. Name—Already contains the name of the port. It may be 16 characters long and must start with a letter of the alphabet. You can include underscores, periods, and numbers in the name. If you change it here, the new name replaces the old name throughout the network.
2. Description —Type a description of the comm port if you would like. It is optional. This information is strictly for you and does not affect the controller.
3. DefaultMode —Select TankNet for the TankNet cable.
4. Baud —Automatically set to Baud4800 .
Give TankNet Attri but es
Baud( ) Baud300
( ) Baud1200
( ) Baud2400
(X) Baud4800
( ) Baud9600
( ) Baud19200
Name Description
Comm Port – FLOOR1
COMM1
SAVE
LBUS for IOUs
CANCEL
DefaultMode( ) Printer( ) Window( ) Command( ) Infinet( ) Lbus( ) AutoSet
Mode TankNet
View Edit Connect Logout
(X) TankNet
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-23
5. Mode —You cannot change this box. It displays the current way the comm port is operating, TankNet .
6. Press the SAVE button, SAVE key, or EXECUTE key to save the comm port attributes. The window automatically closes.
Summary
• The TankNet on the Infinity CX 9000 network is connected through one of the communications ports.
• The TankNet is connected to COMM1 or COMM2 of the Infinity CX 9000.
• The TankNet is connected to COMM1, COMM2, COMM3, or COMM4 of the Infinity CX 9200.
• The TankNet is connected to the CUSTOMPORT of the CMX 240.
• You must select TankNet for the DEFAULTMODE of the comm port.
• After you select TankNet , the MODE displays as TankNet .
• After you select TankNet , the baud is automatically set to Baud4800 .
Select TankNet for the DefaultMode
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-24 Infinity Controller Programmer’s Guide
Creating Your Own LogonTo prevent unauthorized access to the system, you tell the controller about who can use the system. You do this by assigning each user a logon name. The logon is the name the person logs on with.
Before you assign any other user logons, be sure to define yourself as the ACC user and change the password to one unique for your controller system. Follow these steps:
1. Be sure you are connected to an Infinity CX controller.
2. Select Edit User from the menu bar.
3. The Open a User window appears.
Inside all Open and Edit windows, you press the NEXT ATTRIBUTE key to proceed from text box to text box (press the PREVIOUS ATTRIBUTE key to move backwards) and press the EXECUTE key to move on to the next window.
Figure 3-12 shows the Open a User window.
Figure 3-12. Open a User Window
Define Who Can UseController
Name
Open a User
Controller
View Edit Connect Logout
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-25
4. The name of the Infinity CX 9000 controller you are connect to appears in the Controller text box. If you expect to work on a different controller most of the time, erase the controller name, type the new one, and press NEXT ATTRIBUTE to proceed to the next text box. You cannot create logons on an Infinet controller. (To assign a password for the keypad on SCX 900 or LCX 810, see the end of the chapter.)
If you decide you want to change the controller name, you can erase it while the cursor is in the text box by pressing the DELETE LINE/TEXT key. The entire name erases and the cursor moves to the far left.
To move the cursor to the far left of the text box without erasing the controller name, press the LEFT SIDE key. Then type over the name.
If after erasing it, you want to bring the controller name back, press the RESTORE TEXT key.
If you want to delete only the last few characters in the controller name, arrow over to the first letter to remove and press the DELETE TO RIGHT key. Characters to the right of the cursor erase.
If you decide not to take any action, press CANCEL WINDOW to erase the information, close the window, and return the cursor to the Main menu bar.
More ways to move the cursor in this window and others are explained in the section called Making Changes Inside the Window, in Chapter 2.
5. Type the name you expect to log on with in the Name text box. Since you are the system administrator, you should type ACC.
6. Press the EXECUTE key to proceed to the User window.
A Logo n Gives A ccess t o All Co ntroller s
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-26 Infinity Controller Programmer’s Guide
Figure 3-13 shows the User window.
Figure 3-13. User Window
Notice that each text box is labeled: USER NAME, FULL NAME, and so on. These labels are called “attributes.”
The attribute name, as stored in the controller, differs from the label shown on the screen. Below, the controller view of the attribute is shown in capital letters in parentheses. You may enter each attribute as follows:
7. User Name (NAME)—You should already see the name you entered in the Open a User window. This is the name you use to log on. You cannot change or delete the ACC name. (You may, however, create more than one Administrate level user.)
8. Full Name (FULLNAME)—Type your full name, up to 32 characters, including spaces. You can include a period
The User Window
User Name
Full Name
Password
Login Program
Logout Program
Kevin
User – FLOOR1 Kevin
Security Level
( ) Change Values( ) Enable/Disable( ) Configure
DELETE
SAVE AS
CANCEL
SAVE
( ) View Only( ) Acknowledge Alarms
( ) Administrate
View Edit Connect Logout
TEACH
( ) No Access
( ) Program
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-27
after your middle initial if you want. This name is for information only—you do not log on with it.
9. Password (PASSWORD)—You enter your password.It can be up to 16 alphanumeric characters, including underscores, periods, and numbers, but must start with a letter of the alphabet.
10. Login Program (LOGINPROGRAM)—You type the name of the program you want to automatically run each time you log on. You may leave this text box blank until you have written a program.
11. Logout Program (LOGOUTPROGRAM)—You type the name of the program you want to automatically run each time you log out. You may leave this text box blank until you have written a program.
12. Security Level (LEVEL)—You arrow down to the Administrate radio button. Press the space bar to select it. For ACC, Infinity has already selected Administrate .
Administrate is the security level of the administrator, who has access to all user passwords, programs, and functions on all controllers. You are usually the only user with such control.
You may, however, have more than one user with Ad-ministrate security level.
13. Press the NEXT ATTRIBUTE key until the cursor lands on the SAVE button and press the EXECUTE key. This is called “pressing the SAVE button.”
(You can also press the QUICK BUTTON key, then S, to press the SAVE button. See Appendix A for a com-plete list of quick button keys.)
You press SAVE to save the information you have en-tered only on the controller you are connected to. The window automatically closes.
One User Should Have Administrate Cont rol
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-28 Infinity Controller Programmer’s Guide
(You can also press EXECUTE from anywhere in the win-dow, except on a button, to save and close the window.)
The controller now knows who you are and that you are the administrator.
Now, log out by arrowing across the menu bar to Logout and pressing the EXECUTE key. Or type LOGOUT in the Command window and press EXECUTE.
Try logging on again using your new name and password.
Once you have logged on successfully, you are ready to create logons for other users.
Logou t with Lo gou tMenu
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-29
Summary
• Open the User window by selecting Edit User from the Main Menu bar.
• You use the appropriate keys to enter the logon name of the user in the Name text box.
• The first administrator keeps the ACC logon name. You cannot delete the ACC user or change its name.
• You can (and should) assign the ACC user (yourself) a new password up to 16 characters long.
• You may give the name of a program that runs each time you log on and another that runs each time you log off.
• The ACC user is automatically at Administrate security level. You cannot change the security level for ACC.
You Cannot Change ACC Security Level
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-30 Infinity Controller Programmer’s Guide
Creating Other User Logo ns, Assigning S ecurity Level sBefore anyone else can use the controller system, you must tell the controller who that person is.
You tell the controller about each user approximately the same way that you told it about yourself in Creating Your Own Logon, only you assign each user an appropriate security level.
The security level ensures that the user cannot delete points or programs or make other changes unless you authorize them.
Quic k Method of Setting UpAll Users o n a Single Controlle r
You set up a user as follows:
1. Select Edit Users from the Main menu bar.
2. In the Open a User window, enter the Infinity CX 9000 name in the Controller text box and then the user name
in the Name text box. The user name is the name the user later logs on with, and should be 16 characters or less, starting with a letter of the alphabet; it can include underscores, periods, and numbers, as well as letters.
3. Press the EXECUTE key to go to the User window.
4. Fill in the User Name that the user logs on with, the Full Name of the user, and the Password . (To assign a password for the keypad on SCX 900 or LCX 810, see the end of the chapter.)
5. If you have not yet written a login or logout program, leave those text boxes blank, otherwise type the names of the programs in the text boxes.
Assig n Each User aSecurity Level
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-31
6. Select a security level for that user by arrowing to the appropriate level and pressing the space bar—see the levels described on this page and the next.
7. Press the SAVE AS button. The Open a User window appears.
8. Type the logon name of the user in the Name text box. You have now set up one user.
9. Repeat steps 4 through 8 for each user, only each time you press SAVE AS, change the name to another name and press the EXECUTE key.
10. When you have finished defining all users, press the SAVE button to save the information and close the win-dow. Or press the EXECUTE key anywhere inside the window except on a button. Or press the SAVE key from anywhere in the window.
User Security Le vels
The actions the user can take at each security level include all of those of all lower levels and the following:
• No Access —Lowest level. You have no access.
• View Only —Can view summary windows of points, system variables, Infinet controllers, messages, files, and others, but cannot open windows with further information. Can view the item but not change anything. Can print point or system variable values and run programs in the
Command window if the program’s COMMANDLINE1 attribute is TRUE. A user you assign to this level may not access the Edit menu.
• Acknowledge Alarms —Same as View Only . Has more capabilities on Infinity SX 80000 workstations.
1. You learn about the COMMANDLINE attribute in Chapter 5.
User Security Levels
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-32 Infinity Controller Programmer’s Guide
• Change Values —Can change point or system variable values in the Point , System Variable through the View menu or the Command window. Cannot alter any other attributes of a point. Can change values of changeable system variables (such as HOUR or DATE). Can open a program from the summary window, look at the lines and statements, even alter the statements, but cannot save any changes.
• Enable/Disable —Can change point or system variable values and enable or disable them through the View menu or the Command window. Cannot enable or disable programs.
• Configure —This is the first level user that can load or save the database.
Can delete a point (even if it is disabled) or change any of its attributes. Can alter any attributes of a program or other file, including all information in the File Configuration window. Can change the program text or delete any file. This is the first user level that can alter triggers. This level can also clear messages from the Messages window.
The user on this level can run programs from the command line even if the COMMANDLINE attribute is FALSE.
• Program —Same as Configure for this version; to be determined.
• Administrate —Can change anything in the controller. Only users on the Administrate level can create more users, change user security levels, or change passwords. No user below this level (on Infinity CX) can add, delete, or change any attribute of an EnergyNet or Infinet controller or a comm port. This level user is also the only user who can change the system time and date.
The security level applies to the controller whose name is displayed in the Controller text box. So, you can give a
Secur ity Levels A re forParticu lar Controllers
Only Ad ministr ator CanChange Users
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-33
single user Change Values level access on one Infinity CX 9000 and View Only access on another.
If one Infinity CX 9000 handles building access and several others handle HVAC control, then you would want the head of security to have Configure security level on the first controller and View Only security level on the others.
You need to set up each user on every controller the person should have access to, but not by repeating the process you just carried out. You can create the same users with the same security levels on every Infinity CX controller from one terminal (see the next section), then individualize each controller as required.
Summary
• Before anyone else can use the system, you must tell the controller who that person is.
• You fill in each user’s logon name, full name, password, and security level.
• You can also include login and logout program names in the user attributes. The programs are optional.
• You press the SAVE button when you have finished defining one user and do not want to define more.
• You can also press the SAVE key or EXECUTE key to both save information and close the window in one stroke.
• Press the SAVE AS button to save the user under the same or another name without closing the window. You use SAVE AS to define multiple users.
• The user’s security level applies to the controller you assign it on. You can assign the same user different security levels on different controllers.
User Access Changes for Each Contr oller
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-34 Infinity Controller Programmer’s Guide
Copyi ng All User Logonsto Multiple Controll ersYou can set up users on every controller on your EnergyNet without leaving your terminal by carrying out the following steps:
1. Create all the user logon names on a single controller.
2. Open the User window for any user.
3. Press the TEACH button.
4. The Teach window appears.
Figure 3-14 shows the Teach window.
Figure 3-14. Teach Windo w
5. You can teach all controllers about only the user you opened or about all users on the controller you are connected to. Press the DOWN key to move the X down to All Users and the UP key to move it back up to This User Only .
Copy All User Logons t oMult ip le Controllers
View Edit Connect Logout
(X) This User Only
( ) All Users
OK CANCEL
Teach
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-35
6. Press the OK button to begin the teaching process.
If you selected This User Only , in a few minutes every controller on EnergyNet has the same information about the user you have open.
If you selected All Users , in a few minutes every controller on EnergyNet has the same information about all users on the controller you are connected to.
You may not want to all users to have the same security level on every controller on the EnergyNet, so plan accordingly.
7. After you press TEACH here, you can then connect to any particular controller separately and alter the security level of any user.
8. Later, if you change a user logon name or password, you must press TEACH to be sure the information is the same on all Infinity CX controllers on the EnergyNet.
Press OK Buttonto Begin Teaching
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-36 Infinity Controller Programmer’s Guide
CautionSince this is the first time you have taught the controllers on EnergyNet about users, you teach every controller all of the attributes you have assigned each user:
• NAME
• FULLNAME
• LEVEL
• PASSWORD
• LOGINPROGRAM
• LOGOUTPROGRAM
Once you have taught the controller about a user, if youuse TEACH again, the control system teaches only the FULLNAME and PASSWORD of any user the controller al-ready knows about; it does not teach the logon name or security level.
This means that if you want to change a user security level to NoAccess , you must change that user on each controller.
If you want to give all users a logon program, you should give it to all users the first time you press TEACH. Otherwise, you must modify each user at each controller.
Now, if you do not have any Infinet controllers with keypads, you have finished setting up the controller system. You can now proceed to Chapter 4, where you assign all points.
If you do have Infinet controllers with keypads, you must assign a password for each keypad as covered in the next section.
Teach Controllers
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-37
Summary
• To save time, you can create all user logons on one controller then teach them to the other controllers on EnergyNet.
• Be sure that the first time you teach about users, you have set all attributes you want to set. Later, if you change those attributes, you must change them for each user separately on each controller.
• You press the TEACH button in the User window to teach all controllers about either a single user or all user on the controller you are connected to.
Teach Saves Time
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-38 Infinity Controller Programmer’s Guide
Setting the Passwords for Keypads on Infinet ControllersIf you have a keypad on an SCX 900 or LCX 810 controller, you must set the password for each one. You must have the Admin security level to carry out this procedure. You set the password using a special word called LCDPASSWORD, as follows:
1. Press the CANCEL WINDOW key as many times as necessary to get to the Main menu bar and press C to get to Connect .
Figure 3-15 shows the Open a Connection window that appears.
Figure 3-15. The Open a Connection Window
2. If the name of the Infinity CX controller in the Controller text box is not the one the Infinet controller is connected to, change it to the correct name.
3. Press NEXT ATTRIBUTE to move to the Infinet Ctlr text box.
Give SCX 900 and LCX810 Keypads Passw ords
Controller
Open a Connection
Infinet Ctlr
FLOOR1
ROOM
View Edit Connect Logout
2
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
Infinity Controller Programmer’s Guide 3-39
4. Type the name of the Infinet controller and press the EXECUTE key.
5. Select Edit System Variables from the Main menu bar.
6. Press the SHOW LIST key to see a list of the system variables.
7. Arrow down to LCDPASSWORD and press the EXECUTE key until you have opened the System Variables window.
8. Enter the password in the text box to the right of Name. The password must be three digits.
You can change it to any three digits you like at any time. No one else can change the password unless you assign that person the Administrate security level.
9. Press the SAVE button or the EXECUTE key to save the new password.
10. Repeat these steps for each keypad.
You can now proceed to Chapter 4, where you assign all points.
Summary
• To assign a password to an SCX 900 or LCX 810 keypad, you must have Administrate security level.
• To assign the keypad password:
Connect to the controller from the Connect menu.
Open the System Variable window for LCDPASSWORD and enter three digits you choose for the password.
• When you press the SAVE button or EXECUTE key, the three digits become the password for that controller’s keypad.
Set LCDPASSWORD Equal to the Three Digi ts
www.PDF-Zoo.com
LBuses, Terminals, Printers, TankNets, Users
3-40 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Chapter 4
Naming and DefiningPoint s
NoteBefore you define any points, consider that EMX 140 and 150 expansion module outputs do not give standard feedback indicating when you are controlling a point manually or its manual control setting. If you want this kind of feedback from a particular piece of equipment, do not use an EMX 140 or 150 to control it.
For more information see Chapter 1 and Chapter 10.
We recommend you read this chapter sequentially. In it you define points used in the sample program in Chapter 5. This chapter presents the following generic procedures:
• Naming Points
• Setting Point Attributes
• Filling in Point Details
• Understanding How Input and Output Points Update
• Naming Several Similar Points
• Converting to Electrical Units
• Knowing about Tristate Points
• Naming a Tristate Point
• Setting Up MIN, MAX, and SP Points on TCX 850
• Naming Points on Another Controller
www.PDF-Zoo.com
Naming Points
4-2 Infinity Controller Programmer’s Guide
• An Alternative Method of Naming Points on Other Controllers
• Viewing Points
• Deleting a Point from the View List
• Printing a Series of Point Values
• Being Sure the Reference or Ground Voltage Is Correct
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-3
Table 4-1 shows the input and output points we name in this chapter.
Table 4-1. Input and Output Points
Controller
Dampers Floor1 AHU
SupplyFan Floor1 AHU
PrehtValve Floor1 AHU
ReturnFan Floor1 AHU
SCX 900
SCX 900
SCX 900
SCX 900
Point Point TypeModel
Current Output
Digital Output
Current Output
Digital Output
HWConvValve CENTRALPLANT
StaticPress Floor1 AHU
HWTemp1 CENTRALPLANT
Burner CENTRALPLANT
CX 9000 IOU
SCX 900
CX 9000 IOU
CX 9000 IOU
Current Output
Voltage Input
Thermistor
Digital Output
MinAirFlow Floor1 Room1 TCX 850 Voltage Input
FanStatus Floor1 AHU SCX 900 Digital Input
www.PDF-Zoo.com
Naming Points
4-4 Infinity Controller Programmer’s Guide
Naming PointsOnce you have logged on and gathered information on the points you need, to name a point:
1. Select Edit Points from the pulldown menu.
Figure 4-1 shows how the pulldown menu looks.
Figure 4-1. Select ing Edit Poin ts from the Menu
Figure 4-2 shows the window that appears on the screen.
Figure 4-2. Open a Point Window
Select Edit Points
View Edit Connect Logout
UsersPointsFilesCommPortsControllerInfinet ControllerSystem Date & TimeSystem VariablesPersonsAreasDoors
Controller
Open a Point
Infinet Ctlr
Name
View Edit Connect Logout
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-5
In the Open a Point window, the cursor is in the Name text box.
2. Refer to the Infinity CX 9000 or Infinet controller drawings from Chapter 1.
The name of your Infinity CX 9000 is displayed in the Controller text box. Because you are not working on a SCX 900 or other Infinity CX 9000 controller, the Infinet Ctlr text box is empty. To name a point on this “ Infinet controller,” you have two options:
• Type the name of a new point after Name. It may be up to 16 characters long and must start with a letter of the alphabet. You can include underscores, periods, and numbers in point names.
OR
• Press the SHOW LIST key to bring up a list of already defined points. This list is called a “choice list.”
Use the up and down arrow keys or the PAGE UP and PAGE DOWN keys to move up and down the choice list to highlight the point you want.
Name the Point in the Open a Poin t Window
www.PDF-Zoo.com
Naming Points
4-6 Infinity Controller Programmer’s Guide
The points are listed by types first, then alphabetically within the type. They are listed in the following order:
• Input
• Output
• Numeric
• Datetime
• String (Infinity CX controllers only)
3. To select a point from the list of points, press the EXECUTE key while the point is highlighted. The name
of the point appears in the Name text box.
If you make a mistake, you can erase text with either the BACKSPACE (erase backwards) key or the DELETE TEXT key (erase forward).
To cancel, press the CANCEL WINDOW key or the MENU BAR key to return to the Main menu bar.
4. Then press the EXECUTE key to proceed.
Choice Lists Are in Order
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-7
Summary
To name a point:
1. Select Edit Points from the Main menu bar.
2. In the Open a Point window, you type the name of a new point in the Name text box.
OR
In the Open a Point window, you press the SHOW LIST key to see a choice list of point names already assigned that you may want to change.
You choose one of the point names using one of these:
• Arrow keys.
• PAGE UP and PAGE DOWN keys.
Then press the EXECUTE key to complete the selection.
3. Press the EXECUTE key to proceed.
Points Must Be Named
www.PDF-Zoo.com
Naming Points
4-8 Infinity Controller Programmer’s Guide
Sett ing Point Att ribut es
As shown in Figure 4-3, the Point window appears after you have named your point.
Figure 4-3. Point Window fo r an Input Poin t
Remember, the labels are called “attributes.” Some attributes are abbreviated in the controller’s memory. They are abbreviated as shown in capital letters below. You set attributes as follows:
1. Name (NAME)—You can change the name on this screen. It may be up to 16 characters long and must start with a letter of the alphabet. You can include underscores, periods, and numbers in the name. If you rename it here, the new name replaces the old name.
The value (VALUE) of the point later appears in the text box after the equal sign.
Point Window
View Edit Connect Logout
Name HWTemp1 = 0.00 deg F
(X) Input ( ) Output
( ) Numeric
( ) Datetime
( ) String
(X) Enabled( ) Disabled
Type
State
IOU Number Channel Number
( ) Voltage( ) Digital( ) Counter(X) ACC Temp (DEG F)( ) ACC Temp (DEG C)
Electrical Type
Point – CENTRALPLANT HWTemp1
1
1
DETAILS
SAVE AS
CANCEL
SAVE
UnitsValue
( ) RTD Temp (DEG F)( ) RTD Temp (DEG C)( ) TankProbe( ) Supervised
Labels Are Attri but es
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-9
2. The text box to the right of the VALUE automatically sets to the engineering units (UNITS) associated with the particular sensor type (ELECTYPE) you select. If you want, you can change the type of engineering units in this text box.
3. Type (TYPE)—Arrow to your choice and press the space bar. The X appears in the parentheses.
If you select Input , the Electrical Type box stays on the screen as is. If you select Output , the Electrical Type lists different types.
If you select Numeric , String , or Datetime , the
Electrical Type box and the IOU Number and Channel Number disappear from the screen, because those attributes are not applicable.
Figure 4-4 shows how the Type box appears when you connect to an Infinet controller.
Figure 4-4. TYPE At tribute Selections on an Infinet Controlle r
The controller also automatically removes the String selection from the Type box if you are connected to an Infinet controller.
4. State (STATE)—Arrow to your choice and press the space bar. The X appears in the parentheses.
Set the State to Enabled , so you do not have to enable the point before you can use it.
NAME, VALUE, UNITS Are Together
( ) Input(X) Output( ) Numeric
( ) Datetime
Type
www.PDF-Zoo.com
Naming Points
4-10 Infinity Controller Programmer’s Guide
5. IOU Number (IOU)—This attribute applies only to Infinity CX 9000 controllers. Refer to the network map. You may recall that each controller on that map has one or more input-output units, called IOUs. Each IOU is numbered. If you are setting up a TankNet probe, be sure the IOU number is 0.
Type the IOU number from the map into this text box.
6. Channel Number (CHANNEL)—Refer to controller drawing. Each input or output point (channel) is numbered.
Type the number of the input or output point from the controller into this text box. If you are setting up a TankNet probe, you must check the address setting of the probe. Address setting 0 to channel 1, 1 corresponds to channel 2, and 2 corresponds to channel 3. Subsequent addresses correspond to subsequent channel numbers in the same way. Refer to the Infinity CX 9200 Installation Guide for exact switch settings.
If you are not using any EMX expansion modules, go to the next step now.
CautionYou must be absolutely correct in assigning the channel num-ber and electrical type to a point on an EMX module. Be sure you know the order the modules are chained in and the type of each input/output on the chain. Remember Board 1 must al-ways be immediately before Board 2 for modules of the same model number.
Suppose, for example, when you attempt to assign a Board 1 module with a pneumatic output and you assign it the voltage type by mistake. Infinity does not know you meant the pneu-matic output, and sets the voltage output on another Board 1 instead. The output then controls the equipment attached to the voltage output—the wrong equipment! So, be very care-ful when naming your EMX inputs and outputs.
Assig n Channel Number
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-11
If you are using EMX expansion modules, you should be careful to assign the inputs and outputs the appropriate number based on the type of controller and the electrical type of the input or output. Be sure you have a map to follow.
Be sure you assign the Board 1 outputs for the first module with the first expansion output numbers, then Board 2 outputs for the second module with the next output numbers, then Board 1 outputs for the third module, and so on, in the order they occur regardless of the module model number. (Be sure you have read and followed the ACC EMX Modules Configuration Guide when you install modules.)
Before you assign a channel number to any EMX 170 or 190 module input or output, go to the next two steps and assign an electrical type. Then come back to this step and assign the Channel . Be sure you assign both before you save the point.
7. Electrical Type (ELECTYPE) for an input—Select the type of input the point senses from the following:
• Voltage —Select this type if the point is a voltage sensor or a current sensor. The controller always gives a voltage for the sensor with this type, so if you want the value to be a current (milliamps), you enter a conversion, as described in Chapter 8.
• Digital —Select this type if the point is an ON or OFF sensor.
• Counter —Select this type if the point is a pulse counter. A pulse counter counts the falling edges of an input waveform.
• ACC Temp (DEG F or DEG C) —Select one of these types (degrees Fahrenheit or degrees Celsius) only if the point uses a standard Andover Controls Corporation thermistor. You also select this type for the SmartSensor module (EMX 170) input.
Select the Electr ical Type for Inputs
www.PDF-Zoo.com
Naming Points
4-12 Infinity Controller Programmer’s Guide
For the EMX 170 input, you must assign a particular input number that changes from one Infinet controller to another. It is always the highest input number possible on that controller.
Table 4-2 shows the input number you must assign if you use an EMX 170 expansion module on any of the various Infinet controllers.
• RTD Temp (DEG F or DEG C) —Available only on Infinity CX 9500. Select this type only for an ACC RTD wired to two consecutive inputs where the first is an odd number—and assign the odd number as the Channel .
• TankProbe —Available only if you have a probe on TankNet. Select this type for a tank probe.
• Supervised —Available only for access control. These inputs apply to the eight supervised inputs (labeled Supervisory ) on the ACX 700 controller. Do not set them up as inputs unless you want to control them through an Andover Controls Plain English program or associate them with alarms. You normally set up these “inputs” as part of the Door , as explained in the chapter on doors and areas. See the SX 8000 Programmer’s Guide for how you associate these inputs with alarms.
Table 4-2. Numbers You Must Assign Part icular Expansion Inputs/Output s on Various Cont ro llers
ControllerModel No.
EMX 190 Outputs EMX 170 Input
Output Number(s) Input Number
TCX 850/851 7 for Board 1and 8 for Board 2 25
LCX 810 15 and 16 25
SCX 900 15 and 16 33
ACX 710 4 and 5 26
Assig n EMX 170 CorrectChannel Number
Select RTD Type Onlyfor Properly Wired RTDs
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-13
8. Electrical Type (ELECTYPE) for an output—Select the type of output.
Figure 4-5 shows the Electrical Type radio button box. The types you can select are:
• Voltage —Select this type if the point is a voltage output.
• Digital —Select this type if the point is Form C, which sets equipment to ON or OFF. (Output 3 on a ACX 700 is digital.)
• Current —Select this type if the point is a current output.
• Tristate —Select this type if the point is a tristate output.
Figure 4-5. Poin t Window for an Output Poin t on an Infini ty CX Cont roller
• Pneumatic —Applies only to Infinet controllers. Select this type for the EMX 140 expansion module outputs. If
Assig n Outputs to the Correct Channels
View Edit Connect Logout
Name Burner = 0.00
( ) Input (X) Output
( ) Numeric
( ) Datetime
( ) String
(X) Enabled( ) Disabled
Type
State
IOU Number Channel Number
( ) Voltage( ) Digital(X) Current( ) Tristate( ) Pneumatic
Electrical Type
Point – CENTRALPLANT Burner
1
1
DETAILS
SAVE AS
CANCEL
SAVE
( ) ReaderDoor( ) HiResVoltage( ) HiResCurrent
www.PDF-Zoo.com
Naming Points
4-14 Infinity Controller Programmer’s Guide
you have an EMX 141 or 143 with only one output, you must skip an output for the missing one.
• ReaderDoor —Applies only to Infinet controllers oth-er than the ACX 700.
NoteDo not assign any doors on an ACX 700 as ReaderDoor type points. Set them up as Doors following the instruc-tions in the chapter on doors (if you have access control).
Select this type for a door with a card reader. The card reader and door switch may be on a ACX 710 controller (see Chapter 1 and Chapter 16) or a EMX 190 module.
Refer to the table (on previous page) for the output num-bers you must assign if you use a EMX 190 expansion module on any of the various Infinet controllers. The numbers must be the highest output numbers possible for the controller.
• HiResVoltage —Applies only to Infinet controllers. Select this type for an voltage output.
• HiResCurrent —Applies only to Infinet controllers. Select this type for an EMX 151 current output.
Assig n EMX 151 Outputsto HiRes Types
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-15
Figure 4-6 is a sample of the kind of map you might want to follow when setting up your EMX module inputs and outputs. A map like this helps you avoid making errors.
Figure 4-6. Sampl e Map of EMX Modul es on an SCX 900 Controll er
Sample Map of EMX Modules
SCX900
EMX 150
EMX 150
EMX 190
EMX 190
EMX 160
EMX 170
EMX 141
ExternalPower
Supplies
Output 9—VoltageOutput 10—Voltage
Output 11—CurrentOutput 12—Current
Output 13—Pneumatic
Output 15—ReaderDoor
Output 16—ReaderDoor
Inputs 17–24—Digital
—1 InputInput 33—Temperature
Board 1
Board 2
Board 1
Board 1
Board 2
Board 1
The EMX 170 input mustbe input number 33.
The EMX 190 outputs must beoutput numbers 15 and 16. For only one EMX 190, the output would be number 15on Board 1 or 16 on Board 2.
(Count Output 14 but do not assign)
www.PDF-Zoo.com
Naming Points
4-16 Infinity Controller Programmer’s Guide
9. If you selected String for the type, you must define one other attribute.
String Size (STRINGSIZE)—Set to the number of characters in the string. It is set to 132 automatically and stays that value if you do not change it.
Figure 4-7 shows settings for a MESSAGE point with a STRINGSIZE of 45. Notice that this point is on the Infinity CX controller. You cannot have string points on an Infinet controller.
Figure 4-7. Point Window for a String Po int
Strings Have a StringSize
( ) Input ( ) Output
( ) Numeric
( ) Datetime
(X) String
(X) Enabled( ) Disabled
Type
State
Point – Floor1 Message
String Size 45
DETAILS
SAVE AS
CANCEL
SAVE
Name Msg.Spec = The Preheat Valve Is OPEN
View Edit Connect Logout
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-17
10. Press the NEXT ATTRIBUTE key to move to the DETAILS button; then press the EXECUTE key. (This is called “pressing the DETAILS button.”)
11. If you do not want to fill in the point details, you may press the SAVE button, EXECUTE key, or SAVE key. The controller saves the point and closes the window.
You can also press the CANCEL button to cancel the point definition.
Press th e Details B utto n
www.PDF-Zoo.com
Naming Points
4-18 Infinity Controller Programmer’s Guide
Summary
• You can set some point attributes in the Point window.
• Some attributes are NAME, TYPE, STATE, ELECTYPE, IOU, and CHANNEL.
• Once you fill in the attributes, you can press the NEXT ATTRIBUTE key to move to the DETAILS button; then press the EXECUTE key to open the Details window.
• When you assign point numbers, you must assign the inputs and outputs to the corresponding channel on the controller.
• EMX modules are the following types with the following types of inputs and outputs:
EMX 140—Two Pneumatic Outputs (Some variations on the model have only one output; however, you must al-ways treat each EMX 140 as if it has two outputs.)
EMX 150—Two Voltage/Current Outputs
EMX 151—Two High Resolution Voltage/Current Outputs
EMX 155—Two Digital Outputs (Form C)
EMX 160—Eight Digital Inputs
EMX 170—One Temperature Input
EMX 190—One Reader Door Output
Press CANCEL to Cancelthe Point
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-19
We strongly recommend you have a map of the chain of EMX modules. You must be sure to assign the correct type and always assign Board 1 inputs/outputs to numbers low-er than those for Board 2 of the same model number module.
If you have any questions about how to set up a module chain, refer to the ACC EMX Modules Configuration Guide included with the module.
• The EMX 170 module input must always have the highest input number possible for the controller.
• The EMX 190 module outputs must always have the highest output number possible for the controller.
• String points require an attribute called STRINGSIZE.
• When you should move to a button and press the EXECUTE key, we say “Press the button,” rather than explaining how each time.
• You can press the CANCEL button to cancel the point.
Refer to Modu lesConfiguration Guide
www.PDF-Zoo.com
Naming Points
4-20 Infinity Controller Programmer’s Guide
Fil ling in P oint Detail sOnce you have pressed the DETAILS button, the Details window appears.
As shown in Figure 4-8, the input point details define the point in more detail.
Figure 4-8. Input Poin t Details Window
Figure 4-9 shows how the output point details differ from those for input points.
You set these additional point attributes as follows:
1. Description (DESCRIPTION)—Enter a description of the point if you would like. It is optional. This description later displays in View menu windows.
2. Display Format (FORMAT)—Automatically set to the display format associated with the engineering units you selected in the Point window. You can change the display format in this text box.
Press th e Details B utto n
Description
Display Format
Exported
Conversion
###.##
X
Point – Floor1 AHU StaticPress
TRIGGERS
DELETE
LOGS
SAVE
CANCEL
Volts
Top
Bottom
Inches
Threshold
Auto-Conversion
Static Pressure
.02
5 5
0 1
View Edit Connect Logout
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-21
Figure 4-9. Output Poin t Details Window
Pound signs each stand for a digit or character. A dollar sign and three pound signs ($###) always print out ON, –ON, or OFF for a digital or tristate point. The percent sign followed by three pound signs prints 1 as 100%. So units of % Open do not require the percent sign, as it prints with the number. More format details are described under the PRINT keyword in the Andover Controls Plain English Language Reference.
3. Exported (EXPORT)—You do not change this setting. An X appears here if the point is being used by another program in a different controller.
4. Threshold (THRESHOLD)—(Appears for input points only.) Enter the amount of change that must occur before the input should update. For instance, you may want the temperature updated only if it changes by at least 2 degrees.
mA
Top
Bottom
OpenAuto-Conversion
1 20
0 4
Description
Display Format
Conversion
%###
Point – CENTRALPLANT HWConvValve
TRIGGERS
DELETE
LOGS
SAVE
CANCELExported X
HW Converter Valve
View Edit Connect Logout
Addi tional Point At tributes
www.PDF-Zoo.com
Naming Points
4-22 Infinity Controller Programmer’s Guide
5. Conversion (CONVERSION)—Enter a conversion if you need to convert electrical units to engineering units or, for outputs, convert in the other direction.
If your units do not automatically convert, use this field for the formula. The conversion can contain up to 132 charac-ters. After you fill the portion of the box that shows on the screen, it scrolls so that you can continue to fill it. Only in-put or output points can have a conversion.
6. Top (ENGSCALETOP)—(Input and output points only.) In the grid at the bottom of the screen, enter the top of the scale for the point in the first column to the right of Top under the units that appear. The units you put next to
Engineering Units reappear here. If a Current output were in %Open, you might enter 1 (100%) for top of scale. (See Display Format for where % sign appears.)
7. Bottom (ENGSCALEBOT)—Enter the bottom of the scale for the point in the first column to the right of Bottom under the units that appear. For the bottom, you might enter 0 for 0%.
8. Top (ELECSCALETOP)—The second column to the right of Top is automatically labeled with Volts for a
Voltage type, Pulses for a Counter , and mA for a Current type. Enter what you want your engineering units’ top of scale to convert to in electrical units. The controller automatically converts engineering units to this value. You would enter 20 mA for the example in step 7.
9. Bottom (ELECSCALEBOT)—Same as top of scale. You enter 4 mA for the example in step 8.
You Enter a Conver sio nFormula
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-23
Special Attribute s of Digital Inputs
Figure 4-10 shows the details for a digital input point that has been inverted. Notice that another text box, Invert On/Off , appears for digital points.
Figure 4-10. Input Point Detai ls Window for Dig ital Type Input wit h Inverted ON/OFF
Invert On/Off (INVERT)—(Appears for digital points only.) Press the space bar (the X appears) to invert ON and OFF. Press the space bar again to return to normal ON/OFF.
Special Attribute s of Supervi sed Inputs
A supervised input point requires that you tell the controller the type of resistor.
Figure 4-11 shows the input point Details window for a supervised input. In this case, the switch is normally open and the resistor is in series.
Description
Display Format
Exported
Conversion
$###
X
Point – Floor1 AHU FanStatus
Fan Status is Inverted
Invert On/Off X
View Edit Connect Logout
TRIGGERS
DELETE
LOGS
SAVE
CANCEL
You Can Invert a Digi tal Point
www.PDF-Zoo.com
Naming Points
4-24 Infinity Controller Programmer’s Guide
Figure 4-11. Input Point Detai ls Window for Superv ised Type Input
Resistor Type —This text box appears only if you selected Supervised for the electrical type. Here, press the SHOW LIST key and select the type of resistor in the supervised input from the choice list: NOSeries , NOParallel , NOSerPar , NCSeries , NCParallel , NCSerPar . If the resistor is for a supervised input on an EMX 190 (channel 9, 10, 11, or 12), you must select NOSeries , NOParallel , NCSeries , or NCParallel ; other options are not available on the EMX 190.
Special Attribute s of Numeric Points
Figure 4-12 shows how the numeric point details differ from those for input and output points.
Setpoint (SETPOINT)—Set to ON by pressing the space bar so that the (X) appears. When ON, the controller remembers the current value as the setpoint.
Description
Display Format
Exported
Conversion
$######
X
Point – Floor1 Room1 GlassBreak
TRIGGERS
DELETE
LOGS
SAVE
CANCEL
GlassBreak Sensor in Room1
View Edit Connect Logout
Resistor Type NOSeries
Set the Resis tor Type
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-25
Figure 4-12. Numeric Point Detail s Window
Special Attribute s of Str ing Poin ts
Figure 4-13 shows the string point details.
Figure 4-13. String Point Detai ls Window
Description
Display Format %###
Point – Floor1 Room1 NUM
TRIGGERS
DELETE
LOGS
SAVE
CANCELSetpoint
Exported X
View Edit Connect Logout
String Poin t Detai ls
Description
Point – Floor1 Message
TRIGGERS
DELETE
LOGS
SAVE
CANCEL
Setpoint
View Edit Connect Logout
www.PDF-Zoo.com
Naming Points
4-26 Infinity Controller Programmer’s Guide
Special Attribute s of DateTim e Points
Figure 4-14 shows the datetime point details.
Figure 4-14. DateTime Point Detai ls Window
For the sample program, connect to the AHU SCX 900 and name this output point:
SUPPLYFAN—Output (channel) 1. The supply fan. Set the electrical type to Digital .
DateTime Point Details
Description
Details – Floor1 AHU DTS
TRIGGERS
DELETE
LOGS
SAVE
CANCELExported X
Setpoint
View Edit Connect Logout
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-27
Saving the Point
To save the point, press the SAVE button to return to the Point window and press SAVE there. Or, you can press the SAVE key or EXECUTE key anywhere in either window, as long as you do not press EXECUTE on a button that directs another action (such as TRIGGERS).
You can press the TRIGGERS button to set triggers, but first you must have written a program. We show how to set up logs and triggers in a later chapter.
You can press DELETE to delete the point at any time. Note that users with access level below Configure cannot delete points.
Summary
• After you press the DETAILS button, the Details window appears on the screen.
• You fill in the details about each point.
• Input and output points can have a conversion.
• Input, numeric, string, and datetime points can be arrays.
• You can press the TRIGGERS button to set triggers.
• You can press the DELETE button to delete the point.
Press SAVE Button or Press SAVE key
www.PDF-Zoo.com
Naming Points
4-28 Infinity Controller Programmer’s Guide
Under standing How Input and Output Points Up dateExactly how do input points update? Each input constantly re-ceives an ELECVALUE, a raw value, from the environment.
If the ELECVALUE changes, the controller converts it to the VALUE. Otherwise, the input VALUE does not update.
Figure 4-15 illustrates how an input point updates.
Figure 4-15. Process o f Input Poin t Update
Input Updating
2.6 Volts
If Numberof Volts
60 psi
Changes,Convert to psi
ELECVALUE:
CONVERSION:
VALUE:
(Occurs only when newELECVALUE is different from old ELECVALUE)
UNITS= psi
PressureSensor
P/V
(Value updates only when difference between new VALUEand old VALUE is at least the THRESHOLD value)
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-29
An output point updates similarly, only the VALUE changes first. If you change the setting of an output, the controller then converts the VALUE to an ELECVALUE.
The ELECVALUE is the number of volts or milliamps (or other raw units) that actually set the output equipment to the new value.
Figure 4-16 illustrates how an output point updates.
Figure 4-16. Process o f Output Point Update
Outpu t Updat ing
12 mA
60 % Open
ELECVALUE:
CONVERSION:
VALUE:
UNITS= % Open
If % OpenChanges,Convert
to milliamps
DamperOutput
(Occurs only when newVALUE is different from old VALUE)
www.PDF-Zoo.com
Naming Points
4-30 Infinity Controller Programmer’s Guide
Naming S everal Simila r PointsOnce you have named the first output point, to name several more output points, you can alter the first point’s settings and just change the name. How do you do it?
You use the SAVE AS button.
SAVE AS
After you have filled in the attributes for the SUPPLYFAN, you can use SAVE AS to save it and quickly create the three additional points needed for the sample program, as follows:
1. If you are in the Details window for the SUPPLYFAN, press SAVE to return to the Point window.
2. Press the SAVE AS button.
3. A new Open a Point window appears on top of the Point window.
4. Enter the name of the point you now have open (SUPPLYFAN) in the Name text box. Be sure it is the exact same name, then press the EXECUTE key. You have now saved the current point under its own name.
Now, create the next point as follows:
1. Change the output (CHANNEL) number to the output for the next point.
You cannot change the TYPE unless you leave the window and open it again, so make another output point.
2. Move to and press the DETAILS button and fill in the details of the next point.
3. Press SAVE to return to the Point window.
Alter the Point, ThenSave It Under New Name
Use the SAVE AS Butto n
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-31
4. Press SAVE AS again. A new Open a Point window appears on top of the Point window.
5. Type the name of the new point in the Name text box and press the EXECUTE key. You now have two output points.
6. When you have given names to all your output points, press SAVE to leave the window and repeat the process for your input, numeric, datetime, and string points.
Additional points you need to name for the sample program are:
• RETURNFAN—Output (channel) 2. The return fan. Set the electrical type to Digital .
• DAMPERS—Output (channel) 5. The dampers. Set electrical type to Current . Top of scale should be 1 (100%) and bottom 0 in engineering units of %OutsideAir; top 20 mA and bottom 4 mA in electrical units. For the dampers 100% OutsideAir means 100% outside air and no return air. And 0% OutsideAir means all return air. (So, at 60% OutsideAir, the air mixture contains 40% return air.)
• PREHTVALVE—Output (channel) 8. The preheat coil valve. Set the electrical type to Current . Top of scale should be 1 and bottom of scale 0 under the first column in engineering units of %Open; top 4 mA and bottom 20 mA in electrical units.
The PREHTVALVE is the reverse of the scale for the DAMPERS point. Why? Because this valve is normally open and the bottom of scale is the closed setting.
To set up the auto-conversion for this point, proceed to the next section.
Sample Program Po ints
www.PDF-Zoo.com
Naming Points
4-32 Infinity Controller Programmer’s Guide
Converting to Electrical UnitsGOAL: To assign electrical units so that they automatically convert PREHTVALVE settings.
Remember, the PREHTVALVE is the preheat coil valve. The top of scale in engineering units should be 1 (100%) and the bottom 0.
The translation into electrical units is in milliamps. Usually, 0 converts to 4 mA to open and 1 to 20 mA to close; in this case, the electrical units are reversed.
When you say CLOSE this valve, it really means “set this valve to the bottom of its scale.” Unless you reverse the elec-trical units, the bottom of the scale for this valve is OPEN.
To set the point so that it opens when you say OPEN and clos-es when you say CLOSE, you must have the automatic conversion convert engineering units to the opposite positions on the scale in electrical units.
Figure 4-17 shows how the electrical and engineering units are set to opposite scales to setup the conversion.
The auto-conversion in the illustration makes OPEN open the valve and CLOSE close the valve.
You can use the auto-conversion grid only for points that are Voltage , Current , or Counter .
Other types of points require that you enter a conversion in the Conversion text box.
To set ON to OFF and OFF to ON in similar circumstances for a Digital point, you put an X after Invert On/Off in theDetails window.
% Open Converts t oMil liam ps
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-33
Figure 4-17. Auto-Convers ion Sett ing
When you want % Open (or % anything) for units, set your display format to %###. This format automatically multiplies the engineering units by 100, so 1 becomes 100, .8 becomes 80, and .15 becomes 15. Later when you PR the point value, it lists the valve, set at .8, as shown below:
PrehtValve = 80 % Open
Summary
• You can set the Auto-Conversion grid to convert units to their opposite values.
• You can convert analog or counter points with the auto-conversion.
• You can display the value of 0 to 1 engineering units as 0 to 100% by using %### as the display format.
mA
Top
Bottom
OpenAuto-Conversion
1 4
0 20
Description
Display Format
Conversion
%###
TRIGGERS
DELETE
LOGS
SAVE
CANCELExported X
Preheat Coil Valve
View Edit Connect Logout
Point – CENTRALPLANT PrehtValve
Auto-Convert Analog and Counter Points
www.PDF-Zoo.com
Naming Points
4-34 Infinity Controller Programmer’s Guide
Knowing about Tristate Points
Where Tristate Points Are Fou nd
A tristate point can be on one of three controllers:
• An Infinity CX 9000 IOU with all tristate output points.
• An SCX 900 or similar Infinet controller where two universal outputs are wired to be one tristate.
• A TCX 850, which has one dedicated tristate output.
(Details on tristate points are included in the installation guide for each controller.)
Tris tate Points on SCX 900s
When two universal outputs combine to make one tristate out-put on an SCX 900, you indicate the situation to the hardware by setting a slide switch. (See the Andover Controls SCX 900 Installation Guide for details.) The two outputs are always an odd number, followed by an even number.
Under these conditions, the controller does not know how you wired the points. So, you need to tell it that the output is tristate. You select Tristate in the Electrical Type box.
When you use two outputs as one tristate output, you set only one of two outputs (output 1 for outputs 1 and 2 or output 3 for outputs 3 and 4, and so on) in the Point window.
Trist ate Poin ts on IOUsand Infinet Controllers
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-35
Figure 4-18 shows how the two are wired together.
Figure 4-18. Wiring Two Outputs on an SCX 900 to Form One Trist ate Output
(If you run short of points, you can assign the even numbered output as a Voltage or Current type, but not as a Digital . You would wire the V or I and the ground (GND)). So when output 3 becomes tristate, output 4 can be voltage or current.
Summary
• Tristate points are either on IOUs of an Infinity CX 9000, on a TCX 850, or on an SCX 900.
• Tristate points on SCX 900 are formed by setting a slide switch and wiring two points, an even and odd output, as one.
• The TCX 850 has one dedicated tristate output.
Odd Output is T rist ate, Even is A nalog
NCCNOIVGNDGNDIVNCCNO
C+ON
–ON
OFF
OddOutput
EvenOutput
output number. output on even a current or voltage You can wire as
www.PDF-Zoo.com
Naming Points
4-36 Infinity Controller Programmer’s Guide
Naming a Tristate PointGOAL: To name a tristate point, called CHILLERVANES, for the chiller vanes on the second IOU of the CENTRAL-PLANT Infinity CX 9000.
You name a tristate output point as follows:
1. Start on the terminal connected to the CENTRALPLANT Infinity CX 9000 or connect to that controller using the Connect menu.
2. Select Edit Points from the Main menu bar.
3. Enter the point name (CHILLERVANES) and press the EXECUTE key.
4. Enter all point attributes (including IOU 2 and CHANNEL 7 for output 7) and move to the DETAILS button.
5. Press the DETAILS button to open the Details window.
6. Enter a description and display format if you want to.
7. Move to and press the SAVE button.
8. When the Point window displays, press the SAVE AS button. Enter the name of the point you just defined to save the changes to the information under that name.
9. Repeat the steps above, saving the points to different controllers and point names, until you have entered all the tristate points you need.
10. Once you have finished creating points, press the EXECUTE key to save the information and close the window. You can also press the SAVE key or the SAVE button; each automatically closes the window.
CHILLERVANES Is on aTrista te IOU
Save the Altered Info t oAnother Trista te Point
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-37
Summary
• To have a tristate point on an Infinity CX 9000, you must have a tristate IOU attached to the controller.
• You use SAVE AS to enter one point after another. Use SAVE AS to Enter More Than One Point
www.PDF-Zoo.com
Naming Points
4-38 Infinity Controller Programmer’s Guide
Sett ing Up M IN, MAX, and SP Point s on TCX 850GOAL: To assign names and types to the MIN, MAX, and SP knobs (inputs 5, 6, and 7) on TCX 850 controllers.
Ass igni ng TCX 850 Input Po ints
You set the three knobs on the TCX 850 labeled MIN, MAX, and SP (inputs 5, 6, and 7, in that order) manually.
They all read in voltage, from 0 to 5.12 V, so you must set them up as voltage inputs in the Point window.
But what do you do with them?
You can program MIN and MAX to be, for instance, the mini-mum and maximum air flow. When you turn them clockwise, you increase the voltage. Increasing the voltage can either in-crease or decrease the air flow, depending on how you set up the auto conversion.
Figure 4-19 shows the way you could set up MIN as a point called MINAIRFLOW with an auto-conversion.
TCX 850 Knobs AreProgrammable Inputs
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-39
Figure 4-19. Input Point Detai ls Window
You can also program SP for any purpose that you would like, such as to set the setpoint.
Summary
• The knobs on the TCX 850 are inputs 5, 6, and 7. You can set them to Voltage type and convert them to any purpose you would like.
• You can use MIN and MAX knobs to set minimum and maximum air flow.
• You can use SP to set the setpoint for air flow.
Description
Display Format
Exported
Conversion
%###
X
Point – Floor1 Room1 MinAirFlow
TRIGGERS
DELETE
LOGS
SAVE
CANCEL
Volts
Top
Bottom
Inches
Threshold
Auto-Conversion
Minimum Air Flow in Room 1
.05
1 5.12
0 0
View Edit Connect Logout
Program SP for Any Purpose
www.PDF-Zoo.com
Naming Points
4-40 Infinity Controller Programmer’s Guide
Naming Points on Anot her ControllerIf the point you are naming is on an Infinity CX 9000 or Infinet controller different from the one you are working on, refer to your network map.
Find the type and name of the controller the point is on.
1. Select Connect from the Main menu bar.
Figure 4-20 shows the Open a Connection window that appears.
Figure 4-20. Open a Conn ection Windo w
The name of your Infinity CX 9000 is displayed in the
Controller text box.
2. To change the Infinity CX 9000 name, you can:
• Erase it using the DELETE LINE/TEXT key and type the name of another Infinity CX 9000.
OR
Select Connect f rom theMain Menu Bar
Controller
Infinet Ctlr
Floor1
Open a Connection
View Edit Connect Logout
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-41
• Press the SHOW LIST key to bring up a choice list of Infinity CX 9000 controllers.
The list of Infinity CX 9000 controllers is in alphabetical order.
Use the up and down arrow keys or the PAGE UP and PAGE DOWN keys to move up and down the list of controllers to highlight the one you want.
Press the EXECUTE key to put the name you want in the Controller text box.
3. Press the NEXT ATTRIBUTE key to move to the Infinet Ctlr text box (or press the down arrow key).
4. Repeat step 2, only this time type or select the name of an Infinet controller.
The list of controllers is in alphabetical order. Arrow down to AHU.
Press the EXECUTE key to place the name in the text box.
5. Press the EXECUTE key.
6. When the OK button appears, press the EXECUTE key again. From now on, the Infinity CX 9000 you selected here and the Infinet controller are the ones that will appear
in the Open a Point window each time you select Edit Points .
(Later, you can use Connect to connect to a different controller.)
7. Return to the section called Naming Points and proceed to name the points on the controller you are now on.
Select the Name of anInfin et Contr oller
www.PDF-Zoo.com
Naming Points
4-42 Infinity Controller Programmer’s Guide
An Alter native Method of Naming Points on Other Controlle rs1. Press the CANCEL WINDOW key. The cursor moves to
the Command window.
2. Type CD followed by the name of the Infinity CX controller and the name of the Infinet controller, as in the example that follows:
CD FLOOR1 ROOM4
Figure 4-21 shows the CD command in the Command window.
Figure 4-21. CD Command Li ne
3. Press the EXECUTE key. Now you name points on the Infinity CX 9000 or Infinet controller you selected here. The controller name or names appear in the Open a Point window each time you select Edit Points .
Change Controller s wit hCD Command
R> CD FLOOR1 ROOM2 R>
Command Window – FLOOR1
View Edit Connect Logout
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-43
4. Return to the section on Naming Points you read earlier.
5. To select another controller and name points on it, repeat these steps.
Summary
• You can connect to another controller either from the Main menu bar or from the Command window.
• On the Main menu bar, arrow to the Connect menu and press the EXECUTE key.
• In the Command window, type the CD command followed by the name of the Infinity CX controller, then the Infinet controller.
• The names of the controller or controllers you connect to
appear in the Open a Point window each time you select Edit Points .
Two Ways to Connect to a Controller
www.PDF-Zoo.com
Naming Points
4-44 Infinity Controller Programmer’s Guide
Viewing Points
After you return to the Main menu bar, select View Points . Information about the named points appears.
The name of each point is in the far left column.
As shown in Figure 4-22, the other columns contain the other attributes:
The VALUE attribute is either ON or OFF for each fan in the sample program. The other points, however, are in units of% Open and % OutsideAir .
The TYPE attribute reveals whether each point is Input , Output , Numeric , String , or Datetime . If the point is an input or output point, the point summary gives the IOU num-ber if applicable (under I) and the channel number (under C) after it.
The STATE attribute should be set to Enabled .
Figure 4-22. Point Summary Window
Notice that the points shown in the summary are the ones on the AHU SCX 900 Because they are not on IOUs, the IOU number is 0. The number after the zero is the channel.
Displ ay Informatio nabout Points
Point Summary – Floor1 AHU
Name Value Units Type State
SupplyFan OFF
ReturnFan OFF
Dampers 100% OutsideAir
Output
Output
Output
Output PrehtValve 100% Open
View Edit Connect Logout
I C
0,4 Enabled
0,3 Enabled0, 2 Enabled0, 1 Enabled
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-45
the actual output number. To see points on other SCX 900s or other Infinity CX 9000 controllers, first connect to that con-troller through the Connect menu.
If you see a point in the summary that you want more infor-mation about, arrow down until it is highlighted and press the EXECUTE key to open its Controller window.
The SUPPLYFAN, RETURNFAN, DAMPERS, andPREHTVALVE points are the ones you use in Chapter 5 to write your first program.
Press the CANCEL WINDOW key to close the window. The cursor returns to the Main menu bar.
Summary
• Select View Points from the Main menu bar.
• View the name, value, units, type (including IOU and channel numbers), and state.
• If a point is on an Infinet controller, the IOU number is 0.
Press EXECUTE to Close the Window
www.PDF-Zoo.com
Naming Points
4-46 Infinity Controller Programmer’s Guide
Deleting a Point f rom t he View ListWhile you are displaying the summary you opened with View Points , you can delete a point from the list.
Arrow down to the point you want to delete and when it is highlighted, press the DELETE TEXT key.
You have then removed that point from the controller.
Figure 4-23 shows removing the DAMPERS point. (Do not actually delete the point. You use the point in the sample program in the next chapter.)
Figure 4-23. A Selected Poin t in the Poin t Summary Window
You can also return to the point Details window and remove the point by pressing the DELETE button.
In either case, when you try to delete a point, a window ap-pears on the screen asking if you want to cancel.
Figure 4-24 shows the window.
You Can Delete Pointfrom View List
Point Summary – Floor1 AHU
Name Value Units Type State
SupplyFan OFF
ReturnFan OFF
Dampers 100% OutsideAir
Output
Output
Output
Output PrehtValve 100% Open
View Edit Connect Logout
I C
1,4 Enabled
1,3 Enabled1, 2 Enabled1, 1 Enabled
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-47
Figure 4-24. A Message to Prevent Acci dentall y Deletin g a Poin t
Press the YES button to cancel or the NO button to actually delete the point.
Summary
• You can delete a point from the Details window.
• You can delete a point from the View Points list using the DELETE TEXT key.
• If you decide you want to cancel, and not delete the point, press the YES button to cancel.
Delete a Point
You are about to delete this point. Do you want to cancel?
YES NO
Press EXECUTE to Close the Window
www.PDF-Zoo.com
Naming Points
4-48 Infinity Controller Programmer’s Guide
Print ing a Series of Point ValuesAnother way to see a series of point values, and to look at only the specific ones you want to see, is to use the P (or PR) key-word in the Command window. P prints a series of points and their values. You enter P and a list of points separated by commas, like this:
P OAT, SPACE20TEMP, SPACE8TEMP
The results that print on the screen include the name of the point, its value, and the engineering units of the point.
Figure 4-25 shows the commands in the window. (Remember not to type the R>. The R> indicates where you may type.)
Figure 4-25. P or PR Command Lines
You can also display system variable and point values on the LCD of the keypad found on some Infinet controllers (SCX 900 and LCX 810 controllers). Details on how to display them are in the Andover Controls Infinity CX Operator’s Guide.
Prin t Particular PointValues with P or PR
R>P OutsideAir, SpaceTemp
OutsideAir = 56 degrees F
SpaceTemp = 66 degrees F
R>PR SupplyFan, PrehtValve
SupplyFan = ON
PrehtValve = 100%Open
View Edit Connect Logout
Command Window – Floor1 AHU
www.PDF-Zoo.com
Naming Points
Infinity Controller Programmer’s Guide 4-49
Summary
• You can use the P (or PR) command to print the point name or predefined name and its value in the Command window.
• If you use P, the units are printed after the value.
• P and PR are the same command.
P Prints t he Name, Value, and Units
www.PDF-Zoo.com
Naming Points
4-50 Infinity Controller Programmer’s Guide
Being Sure the Input Vol tage or Ground Voltage Is CorrectSuppose all inputs on your TCX 850 series or LCX 800 series controller show a value of 999.99. How could that happen?
If the input or ground voltage to one input is too high,Infinity sets all inputs on that controller to the 999.99 value until situation is corrected.
If this occurs, get out your Volt-Ohm Meter and test each in-put to find out which has the high input or ground voltage.
Consult the hardware installation guide for any TCX 85series of LCX 800 series controller to find out the correct ground voltage for the inputs on that controller.
Check Inpu tor Ground Voltage
www.PDF-Zoo.com
Chapter 5
An Overview of theProgramming Pr ocess
This chapter presents these procedures while it develops one sample program using the points created in Chapter 4:
• Defining the Program Action
• Talking to the Controller
• Understanding Keyword Formats
• Acting on Lists of Points
• Writing the Program
• Creating a Program File
• Setting File Attributes
• Entering a Program
• Entering Statements
• Exiting and Saving a Program
• Searching for Errors
• Starting a Program from the Command Window
• Monitoring Point Values
• Monitoring Program Action
• Stopping a Program
www.PDF-Zoo.com
Overview of Programming
5-2 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-3
Table 5-1 shows the input and output points we program with in this chapter.
Table 5-1. Input and Output Points
Controller
Dampers FLOOR1 AHU
SupplyFan FLOOR1 AHU
PrehtValve FLOOR1 AHU
ReturnFan FLOOR1 AHU
SCX 900
SCX 900
SCX 900
SCX 900
Point Point TypeModel
Form C Output
Form C Output
Current Output
Current Output
www.PDF-Zoo.com
Overview of Programming
5-4 Infinity Controller Programmer’s Guide
Defining the Program ActionYou begin by deciding what you want your controller to do.
GOAL: To have the controller activate morning warmup.
You instruct the Infinity CX 9000 controller and network of Infinet controllers using an English-like programming lan-guage called Andover Controls Plain English. You write instructions in that language that direct the controller.
You must break your instructions down into single-action steps.
Activating morning warmup means, for a given air handler, using 100% return air (0% outside air), turning on the fan, then opening the preheat valve.
To tell the controller to activate the morning warmup, you must remember to tell it every step required to do so. You would break down the steps in chronological order:
1. Close the dampers (to have only return air).
2. Turn on the supply air fan.
3. Turn on the return air fan.
4. Turn on the preheat coil.
The order you put the steps in is the order the controller actually carries them out in. The time that elapses between steps, however, is so short you do not notice it; so the actions appear to be occurring at the same time.
Since the actions occur in such quick succession, order is only significant where you introduce time delays. You might, for instance, close the dampers, then wait 15 seconds to be sure they are completely closed before proceeding to turn on the fans.
You Set a Program Goal
Outlin e Every Step
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-5
The controller needs to know:
• Specific actions to take (listed on previous page).
• The Infinity CX 9000 IOUs, SCX 900s, or TCX 850s the points are on. For the sample program, let’s say that the points are on the FLOOR1 Infinity CX 9000’s AHU SCX 900.
• The points that go with the damper, fans, and heater the controller is to act on. They are all output points. The dampers are DAMPERS, the fans are SUPPLYFAN and RETURNFAN, and the preheat coil is PREHTVALVE.
You should then choose the controller to store the program on. Since the outputs are on the SCX 900 called AHU attached to the Infinity CX 9000 called FLOOR1, you should change the controller setting to FLOOR1 AHU before you write the program. You should always connect to the controller the outputs are on before you write the program that controls them.
Summary
To plan a program:
• Decide what you want the controller to do.
• Break down the action into single-action steps.
• Find the locations of the equipment it is to act on (see the map of the network).
• Find the names of the points (see any controller drawings you may have).
Locate Points o n Controllers
www.PDF-Zoo.com
Overview of Programming
5-6 Infinity Controller Programmer’s Guide
Talking to the Co ntroll erThe controller knows a limited set of words. They include:
• Words in the Andover Controls Plain English language, called “keywords.”
• Names you give to items on the controller, such as points, terminals, printers, and so on. Names are explained in
Chapter 1. Procedures for naming points are in Chapter 4.
• Reserved words the controller knows, such as POINT, PROGRAM, and NAME. You cannot use these words as names.
Plain Eng lish Keyw ords
The Infinity CX 9000 controller knows approximately 40 fundamental Andover Controls Plain English keywords. With these words you can program the controller to execute fundamental process/building control.
Some fundamental keywords the controller knows that you can use to write the sample program are:
TURN ON OFF THE
AND OR OPEN CLOSE
The controller also has approximately 130 additional advanced keywords. These words are the source of Infinity’s power. You can exercise Infinty’s full capability by learning these advanced words.
Cont ro ller Language
Fundamental Keywords
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-7
Summary
You talk to the controller using three types of words:
• Andover Controls Plain English keywords.
• Names of points, terminals, printers, Infinet controllers, and Infinity CX 9000s.
• Reserved words such as POINT, PROGRAM, and NAME.
Andover Controls Plain English has approximately 40 fundamental keywords and over 130 advanced keywords.
Three Types o f Words
www.PDF-Zoo.com
Overview of Programming
5-8 Infinity Controller Programmer’s Guide
Under standing Keyword Forma tsSome keywords tell the controller to take action. In Andover Controls Plain English some of them are:
OPENTURN
The sentence (instruction) you create with an action keyword is called a “statement.” You write, for instance, a “TURN statement.”
A statement is any complete instruction that tells the program what to do next or what action to take in the controller.
Each keyword has one or more formats that tell how you use the keyword in a statement. If you look up TURN in the Andover Controls Plain English Language Reference, the format looks like this:
Format 1
TURN ON output_point_listTURN OFF output_point_list
Format 2
TURN output_point_list ONTURN output_point_list OFF
All words in CAPITALS in the format must be entered in the instruction. You must use ON or OFF with TURN.
All words in bold italics must be replaced with a name, number, or other item. Words in bold italics are required.
You replace output_point_list with a single output point name or a list of those names. You list the points with commas
Keyword Formats
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-9
separating one from the next. Any time you see list, you can also use a single item.
Words in nonbold italics can be replaced with an item but are not required to complete the statement.
Turning O N and OFF Points
Since all of the points for the sample program are output points, any of them can be used with TURN. Here are some sample TURN statements:
TURN OFF THE SupplyFan
TURN THE PrehtValve ON
Setting SUPPLYFAN to ON or OFF makes sense because the fan has an electrical type of Digital , which you turn ON or OFF.
But what does a TURN statement do to the PREHTVALVE when its electrical type is Current and its value can be from 0 to 100% Open?
TURN ON sets the output point to the top of the scale (you indicated it in the Details window) and TURN OFF sets it to the bottom of the scale. Top of scale, in this case, is 1 (fully open) and bottom is 0 (fully closed).
TURN acts on all output points that have a top and bottom of scale the same way. Two types of output points have this kind of scale:
• Voltage
• Current
Use TURN wit h Output Points
www.PDF-Zoo.com
Overview of Programming
5-10 Infinity Controller Programmer’s Guide
You can use TURN on a tristate point, but you cannot use TURN to set a tristate point to –ON. Think of ON and OFF as top and bottom of scale for a tristate point and you can see that TURN acts on all points the same basic way. This is why you should avoid using TURN with tristate points.
Limitat ions of TURN
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-11
Summary
• You form a statement with an action keyword.
• A statement is a complete instruction that tells the program what action to take or what to do next.
• Each keyword has one or more formats.
• All words in CAPITALS in the format must be entered as shown.
• All words in bold italics in the format must be replaced with a name, number, or other item.
• All words in nonbold italics in the format can be replaced with a name, number, or other item, but are not required.
• You must use ON or OFF with TURN.
• You must have at least one output point in a TURN statement.
• TURN sets an output point with an output type of Voltage or Current to the top or bottom of its scale.
Keyword Formats and Points
www.PDF-Zoo.com
Overview of Programming
5-12 Infinity Controller Programmer’s Guide
Act ing o n Lists o f PointsWith TURN and many other action keywords, you can list two or more point names with commas between them:
TURN OFF THE SupplyFan, THE ReturnFan
TURN ON THE SupplyFan, ReturnFan, PrehtValve
The AND Keyword
You can use the AND keyword to complete a list:
TURN OFF THE SupplyFan AND THE PrehtValve
TURN ON THE SupplyFan, ReturnFan AND PrehtValve
The THE Keyword
The THE keyword is optional. You can use it to make your statements read like English.
Sample List s with CLO SE and OPEN
Notice that one of the formats for CLOSE is almost the same as for TURN:
Format: CLOSE output_point_list
CLOSE THE DAMPERS, VENTS
CLOSE THE VENTS, DAMPERS, VALVES
Use Commas betweenPoints
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-13
One of the formats for OPEN is also like the format for TURN:
Format: OPEN output_point_list
OPEN THE VENTS AND THE DAMPERS
OPEN THE VENTS, DAMPERS AND VALVES
Both OPEN and CLOSE set the values of points that have an electrical type other than Digital to the top of scale for OPEN (or ON) and bottom of scale for CLOSE (or OFF).
Summary
• You can use lists of points with the TURN, CLOSE, and OPEN keywords.
• You can form lists with commas between points.
• You can list two items with AND between them.
• You can end long lists with AND between the last two items.
Format for OPEN Statement
www.PDF-Zoo.com
Overview of Programming
5-14 Infinity Controller Programmer’s Guide
Writing the ProgramNow to write the MORN.WARMUP program, refer to the list of steps we formed earlier:
1. Close the dampers.
2. Turn on the supply air fan.
3. Turn on the return air fan.
4. Turn on the preheat coil.
You use these keywords: TURN, ON, OFF, CLOSE, OPEN, and THE.
You also use the output points you have named: SUPPLYFAN, RETURNFAN, DAMPERS, PREHTVALVE. (Remember that closing the dampers means setting them to the bottom of scale, 0% outside air and 100% return air.)
The steps above can each form a program statement:
CLOSE THE DAMPERS
TURN ON THE SupplyFan
TURN ON THE ReturnFan
OPEN THE PrehtValve
In Andover Controls Plain English, you can say almost anything you can say in English, as long as the words are keywords, and the statements are set up following the format.
Notice that each single-action statement takes only one physical line.
You must now enter these words into the program file. But before you do, you must create that file.
Plan Steps to Carry Out
Form Statements
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-15
Summary
To write the program, you do the following:
• Look at the steps and find the appropriate keywords.
• Find the names of the points on your controller drawings.
• Create the statements using the keywords. Make your statements like English sentences.
• Make each single-action statement only one line.
Summary ofProgrammer Process
www.PDF-Zoo.com
Overview of Programming
5-16 Infinity Controller Programmer’s Guide
Creating a Program FileA controller file is like a file folder you would put in a filing cabinet, only it is stored in the controller. You create a program file to store the statements that tell the controller what to do.
As shown in Figure 5-1, after you return to the Main menu bar, you select Edit Files .
Figure 5-1. Select ing Edit Files from the Menu
Figure 5-2 shows the Open a File window that appears on
your screen. The cursor is in the Name text box. You press the NEXT ATTRIBUTE key to move from one text box to the next. (Press the PREVIOUS ATTRIBUTE key to move backwards.)
1. To name the file, do the following:
• Type the name of a new file. It may be up to 16 characters long and must start with a letter of the alphabet. You can include underscores, periods, and numbers in file names.
OR
Controller Files Ar e LikeFile Folders
View Edit Connect Logout
UsersPointsFilesCommPortsControllerInfinet ControllerSystem Date & TimeSystem VariablesPersonsAreasDoors
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-17
• Press SHOW LIST to bring up a choice list of files.
Figure 5-2. Open a File Window
Use the up and down arrow keys or the PAGE UP and PAGE DOWN keys to move up and down the list of points to highlight the one you want.
To select a file from the list, press the EXECUTE key while the file is highlighted, or press CANCEL WINDOW to cancel.
2. Press the EXECUTE key to proceed.
Name the sample program MORN.WARMUP.
Controller
Open a File
Infinet Ctlr
Name
View Edit Connect Logout
Select ing from Choice List
www.PDF-Zoo.com
Overview of Programming
5-18 Infinity Controller Programmer’s Guide
Sett ing File At tributesAs shown in Figure 5-3, as soon as you have named your file,
the File window appears.
Figure 5-3. File Window
You press the NEXT ATTRIBUTE key to move from text box to text box. (Press PREVIOUS ATTRIBUTE to move backwards.)
Each mid-size box is labeled: TYPE, STATE, FLOWTYPE. The text boxes are labeled NAME and DESCRIPTION. The check boxes are also labeled, AUTOSTART and COMMANDLINE.
The labels are called “attributes.” You set file attributes as follows:
1. Name (NAME)—Change it if you want. It may be up to 16 characters long and must start with a letter of the alphabet. You can include underscores, periods, and
You Set File Attributes
Name Description
(X) Program
( ) Function
( ) Data
Type
( ) Looping
(X) FallThru
SAVE
CANCEL
DELETE
( ) AutoStart(X) Command Line
(X) Enabled
( ) DisabledState
FLOWTYPE
MORN.WARMUP Warms up heating
File – Floor1 AHU
DETAILS
( ) Report
View Edit Connect Logout
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-19
numbers in file names. If you change it here, the new name replaces the old name, not only here, but throughout the controller system—in every program, function, or other file.
2. Description (DESCRIPTION)—Type one in the text box if you want.
3. Type (TYPE)—Arrow to Program and press the space bar to put the X there. This file is a program file.
Instructions for creating function files are in Chapter 12
and data files are in Chapter 13.
4. State (STATE)—Arrow to Enabled and press the space bar to allow the controller to run the program. If you set it to Disabled you must enable it before the controller can run the program.
5. Flowtype (FLOWTYPE)—Arrow to FallThru and
press the space bar. FallThru means that the program lines are carried out in the order you list them. For now, your programs should be FallThru .
Looping means that the program remains on the line it is on until the program directs it to another line. Looping programs are explained in Chapter 6.
6. AutoStart (AUTOSTART)—Move to it and press the space bar to select it if you want the program to start as soon as you have saved the file. (AUTOSTART also starts the program immediately after you load it from a tape or disk. However, once you disable the file, it does not start again until you give it a command to start. More on this later.)
7. Command Line (COMMANDLINE)—Move to it and press the space bar to select it if you want to be able to start the program from the command line by typing only the
Select ing FLOWTYPE to Control Loo ping
www.PDF-Zoo.com
Overview of Programming
5-20 Infinity Controller Programmer’s Guide
program name (without RUN) and pressing the EXECUTE key.
8. Press NEXT ATTRIBUTE repeatedly or arrow over to the SAVE button; then press the EXECUTE key. The file Editor window appears.
You can also press the CANCEL button and start over or press DELETE to remove the file.
At any time while you are inside the File window you can press the SAVE key. This key saves the information about the file, no matter where you are in the window, even on a button.
To save from anywhere in the File window except on a button, press the EXECUTE key.
Returning to the File Windo w
Once you have left the File window, you can return to it as follows:
1. Press the CANCEL WINDOW key to return to the File menu bar.
2. Press F for File and C for Configuration to open the File window where the attributes display.
The File window opens.
Return ing to the FileWindow
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-21
Summary
• You set file attributes in the File window.
• You can use several buttons in the File window:
• SAVE—Takes you to the previous window or the Editor window where you can enter your program.
• CANCEL—Cancels the file information and exits to the Main menu bar.
• DELETE—Removes the file from the controller.
• DETAILS—Opens the Details window.
• You can press the SAVE key at any time while in the File window to save the information about the file.
• You can return to the File window by pressing CANCEL WINDOW, and selecting File Configuration .
Buttons in the File Window
www.PDF-Zoo.com
Overview of Programming
5-22 Infinity Controller Programmer’s Guide
Entering a ProgramAs shown in Figure 5-4, once you have defined your file, the Editor window appears on the screen.
Figure 5-4. Editor Window
The Editor window is where you type your program.
You see the path to the Infinet controller (FLOOR1 AHU) and the name of the program (MORN.WARMUP) at the top of the window.
Notice that the menu bar has changed. This new menu bar is called the “File menu bar.”
You can press CANCEL WINDOW to go back and forth between the Editor window and the File menu bar.
Type Your Program inthe Editor Window
File Edit Search Check Tools
FLOOR1 AHU MORN.WARMUP
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-23
Summary
• The Editor window is where you type your program.
• The name of the Infinity CX 9000, the Infinet controller, and the name of the program appear at the top of the window.
• Once you are inside the Editor window, the menu bar changes to the File menu bar.
• Press CANCEL WINDOW to go back and forth between the File menu bar and the Editor window.
Press CANCEL WINDOW to Enter and Leave Edito r
www.PDF-Zoo.com
Overview of Programming
5-24 Infinity Controller Programmer’s Guide
Entering StatementsBefore you can type your program, you must know how to move around inside the editor.
Table 5-2 shows the keys you press to move the cursor.Compare the customized names to the keystrokes for your ter-minal’s keyboard in Appendix A.
Table 5-2. Edito r Keys
Key or Keys Action
BACKSPACE Erases the single character that ap-pears before it. (Erases backward).
Erases one word left to right (Erases forward).
INSERT LINE Inserts a blank line below the one the cursor is on.
DELETE WORD
Arrow Keys Move the cursor anywhere on the screen.
PAGE UP Moves cursor up to previous screen.
Moves cursor down to next screen.
BEGIN Takes the cursor to the top of the file and positions it in the leftmost posi-tion in that line.
PAGE DOWN
Takes the cursor to the bottom of the file.
END
DELETE LINE Removes the entire line the cursor is on.
INSERT TEXT At any position on the screen, inserts text after you press it.
DELETE TEXT Erases the single character that is af-ter it. (Erases forward).
Moves the cursor left (back) one word.
PREVIOUS WORD
Moves the cursor right (forward) one word.
NEXT WORD
Special K eys MoveCursor
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-25
Table 5-2. Edito r Keys (cont)
Until you become well acquainted with the characters, you may want to refer to the Infinity CX Keystroke Reference card, supplied with this manual.
Key or Keys Action
QUICK CMD Allows you to use quick commands.
CANCEL WINDOW Moves cursor to menu bar if in the editor, to editor if in menu bar.
DELETE TO RIGHT Deletes text to the right of the cursor through the end of the line.
LEFT SIDE Moves the cursor to the far left end of the line it is on.
RIGHT SIDE Moves the cursor to the far right end of the line it is on.
TOP SCREEN Moves the cursor to the top of the vis-ible screen.
BOTTOM SCREEN Moves the cursor to the bottom of the visible screen.
MARK BLOCK Marks the beginning of a block of text where the cursor is when you press it. You move the cursor to the end of the block of text. You can then select functions from the Edit menu in the File menu bar to cut, copy, or paste the block.
RETURN (Same Key as EXECUTE)
Ends a physical line of text and brings the cursor to the beginning of the next line.
Special Key s Move Cursor
www.PDF-Zoo.com
Overview of Programming
5-26 Infinity Controller Programmer’s Guide
Using the RETURN Key in Edito r
If you are operating on a VT100 terminal, after you press the RETURN key at the end of a line in the editor, on some terminals you cannot use BACKSPACE to erase the text. The cursor does not back up onto the previous line with BACKSPACE. You arrow up to the previous line and then press the BACKSPACE key to delete backward and the DELETE TEXT key to delete forward.
See Figure 5-5. Try entering the program.
Figure 5-5. MORN.WARMUP Program
Moving the Cursor to the En d
Try to use the down arrow key to move the cursor belowPREHTVALVE. The cursor moves down and then, no matter how many times you press the arrow key, moves no further.
The reason you cannot move the cursor further is that you have typed nothing there. As far as the cursor is concerned this space does not exist.
Press the RETURN key several times below the last program line. Now try moving the cursor down. Notice that the cursor moves to any position on the line, as long as you have typed at least one space (or one RETURN) on it.
Cannot Erase theRETURN Keyst roke
CLOSE THE Dampers
TURN ON THE SupplyFan
OPEN THE PrehtValve
TURN ON THE ReturnFan
FLOOR1 AHU MORN.WARMUP
File Edit Search Check Tools
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-27
Saving Typi ng Time
Later, to save typing time, you may want to experiment with the quick commands. Quick commands are a series of single letter keystrokes that bring up entire keywords after you press the QUICK COMMAND key.
When you are ready to use quick commands, see Appendix C of the Andover Controls Plain English Language Reference for a complete list.
Other Features of the Infinity CX Editor
You can enter up to 400 physical lines in any Infinity CX file.
The Infinity CX editor also has several menus. The menu names are shown along the File menu bar.
You use these menus to carry out various activities from inside the file.
Enter Up to 400 Lin es in Any File
www.PDF-Zoo.com
Overview of Programming
5-28 Infinity Controller Programmer’s Guide
Exiting and Saving a ProgramOnce you have typed in the program, do the following:
1. Press CANCEL WINDOW to go to the File menu bar.
2. Select Check from the File menu bar.
When the controller checks a program, it looks at every word to be sure it understands what you want it to do and checks the program for errors.
The words No Errors!! should appear at the bottom of the window in the File status bar.
Figure 5-6 shows where the message appears on the screen.
Figure 5-6. “ No Errors” Message
The cursor returns to the Editor window.
3. Press CANCEL WINDOW to go to the menu bar again.
4. Select File Save to save the file.
5. Press CANCEL WINDOW to go to the menu bar again.
Saving Your Program
File Edit Search Check Tools
FLOOR1 AHU – MORN.WARMUP
CLOSE THE Dampers
TURN ON THE SupplyFan
No Errors!!
OPEN THE PrehtValve
TURN ON THE ReturnFan
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-29
6. Select File Quit to leave the file.
The cursor returns to the Command window.
The controller does not save the program unless it is free of errors. To see how to correct errors, read the next section.
Warning—To Advanced ProgrammersIf when you try to save a program, you receive a Controller Not Responding message and the Infinity CX controller becomes OffLine , the problem may not be a communications problem at all. To diagnose the problem, wait approximately 10 seconds and see if the controller becomes OnLine again. If it does, a program is taking longer than 10 seconds to execute one line and gives the impression it is off-line. The Infinity CX recovers after approximately 10 seconds and you can then save the file.
The problem is really in the program—any program that takes more than 10 seconds to execute a single line is not following good programming practices. You should rewrite the program to reduce the number of times it loops on that line.
Summary
• Select Check from the File menu bar to check for errors.
• Select File Save from the File menu bar to save the program file.
• Select File Quit from the File menu bar to leave the program file and return to the Command window.
Programs Must B e Free of Erro rs
www.PDF-Zoo.com
Overview of Programming
5-30 Infinity Controller Programmer’s Guide
Searching for E rrorsWhile the file is still open, sometimes when you select Check , you receive a message in the File status bar (bottom of screen) saying ERROR: Statement or expression is not correct . This message means the controller has found an error. This particular message indicates a very basic error.
(If you have no errors, go to the next section.)
The most common error is one that makes the statement incorrect: incorrectly using the keyword format. The keyword format is the format explained in the reference manual. For the message above, you need to look at how you used the format. More on how to find such errors is included in
Chapter 6. For now, let’s see how to find the location of each error.
The cursor lands on the physical line that has the error.
You correct that error. Then to search for the next error, proceed as follows:
1. Press the CANCEL WINDOW key to bring the cursor to the File menu bar.
2. Select Search Next Error . The cursor automatically goes to the next physical line with an error.
3. Correct the error.
4. Repeat steps 1 and 2 until you’ve corrected all errors.
You can search for errors starting at the bottom of thefile instead of the top. You would then select Search Previous Error and the cursor would go back to the last line with an error on it. The cursor goes to that line even if you have fixed the error, until you select Check again.
Finding Errors
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-31
When you have moved the cursor to every line with an error on it, you the receive this message: No Errors!!
If the error is a format error such as not enough parentheses or an IF..THEN structure error, correcting the first error may correct all the others. If you suspect this, select Check again and see if the errors are gone.
Summary
• You can start to search programs for errors from the Search menu on the File menu bar.
• If a statement is not correct, it is usually an error in following the keyword format or a typo.
• You select Search Next Error to find the errors one at a time from the top of the file down.
• You select Search Previous Error to find the errors one at a time from the bottom of the file up.
Search for Er ro rs with Search Men u
www.PDF-Zoo.com
Overview of Programming
5-32 Infinity Controller Programmer’s Guide
Starting a Programfrom the Command WindowFrom the Command window, you can start your program. You can use the following keywords to start one or more programs:
RUN OPEN START ROTATE
You enter the command line by naming one or more programs after the keyword. You type:
RUN HEATPROGRAM, FANPROGRAM
OPEN VENTS
ROTATE HEATINGPROG TO STARTUP
To start a program on a Infinet controller from an Infinity CX 9000, you enter the name of that Infinet controller, then the program name. For example if the HEATINGPROG were on the AHU SCX 900, you would run it like this:
RUN AHU HEATINGPROG
START AHU HEATINGPROG
Since the MORN.WARMUP program is on a SCX 900, you type the command line to start the sample program from the FLOOR1 Infinity CX 9000 like this:
START AHU MORN.WARMUP
Or you could connect to the AHU SCX 900 and type the command line to start the sample program from its own controller like this:
START MORN.WARMUP
Keywo rds to StartPrograms
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-33
Figure 5-7 shows the command line to start the sample program while on the Infinet controller. The command appears after the R> prompt.
Figure 5-7. START MORN.WARMUP Command Line
Summary
• You can start programs from the Command window.
• You can start one or more programs from the same command line.
• You can use these four keywords to start programs: RUN, OPEN, START, ROTATE.
• To start a program located on an Infinet controller from the Infinity CX 9000, after RUN include the name of the Infinet controller, then the program name.
View Edit Connect Logout
R> START MORN.WARMUP
Command Window – FLOOR1 AHU
Start Progr ams from Command Window
www.PDF-Zoo.com
Overview of Programming
5-34 Infinity Controller Programmer’s Guide
Monitoring Poi nt ValuesNow you want to see your program do something! So you return to the Main menu bar and select View Points.
As shown in Figure 5-8, the point values should be set to those you expect the sample program to set them to.
Notice that the damper is still set to 0% OutsideAir (equivalent of closed or OFF) and the heat coil is now set to 100% Open (equivalent of open or ON, which is the top of the scale of the point).
Figure 5-8. Point Summary Window
If the value of a point is not set to the one you expect, you should go back into the program and check each keyword statement to be sure it is correct.
Seeing Point ValuesHave Changed
Point Summary – FLOOR1 AHU
Name Value Units Type State
SupplyFan ON
ReturnFan ON
Dampers 0% OutsideAir
Output 1, 1 Enabled
Output 1, 2 Enabled
Output 1, 5 Enabled
PrehtValve 100%Open Output 1, 8 Enabled
View Edit Connect Logout
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-35
Summary
• To see a point value change in response to a program,
select View Points from the menu bar.
• The Point Summary window shows the current value of each point.
Use Point Summary Window
www.PDF-Zoo.com
Overview of Programming
5-36 Infinity Controller Programmer’s Guide
Monitoring Pr ogram Act ionAnother way to monitor your program is to proceed as follows:
1. Select Edit File from the Main menu bar.
2. When the Open a File window appears, press the SHOW LIST key and select the file you want to open.
3. When the Editor window appears, go to the File menu bar and select File Configuration . The File window appears.
4. From the File window, press the DETAILS button.
As shown in Figure 5-9, the Details window for that program appears on the screen.
Figure 5-9. File Details Window
Seeing Program Actionin File Detail s Window
Default Port
Last Changed SAVE
CANCELCurrent Line
Current Line Start
File Size
Program Status
Details Floor1 AHU MORN.WARMUP
SCREEN1
10/5/91 8:03 AM
10/30/91 10:01 AM
1
100
Active
View Edit Connect Logout
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-37
You cannot change any of the information in this window. It is updated by the controller. The information in each text box is explained below:
1. Default Port (DEFAULTPORT)—The name of the terminal screen the program was run from.
2. Last Changed (LASTCHANGE)—The date and time the program was last altered.
3. Current Line (CURRENTLINE)—The name or number of the currently active line of the program (more about this in the next chapter). The current line of MORN.WARMUP is line 1 because, although no label has been given, the first line is always line 1.
4. Current Line Start (LINESTARTTIME)—The date and time the current line began executing.
5. File Size (FILESIZE)—The number of characters (bytes) in the file. 1024 bytes is 1KB. If you have used a substantial amount of memory, you may want to start monitoring how much is left using the FREEMEM keyword, described in Chapter 11.
You use this information to determine how much memory is taken and how much is still available.
6. Program Status (STATUS)—Active or Inactive .
Summary
• Open the File window and press DETAILS to see what a program is doing.
• The Details window of a file tells which line is currently running.
Find When Program Started Current Line
www.PDF-Zoo.com
Overview of Programming
5-38 Infinity Controller Programmer’s Guide
Stopping a Pr ogramThe following keywords stop one or more programs:
STOP CLOSE
To enter the command line type:
STOP HEATUP, FANS
CLOSE VENTS
STOP HEATING
Figure 5-10 shows some STOP command lines in the Command window.
Figure 5-10. STOP and CLOSE Command Lines
Keywords t o StopPrograms
R> STOP MORN.WARMUP, HEATUPR> CLOSE VENTSR> STOP FANS
Command Window – FLOOR1 AHU
View Edit Connect Logout
www.PDF-Zoo.com
Overview of Programming
Infinity Controller Programmer’s Guide 5-39
Summary
• You can stop a program from the Command window.
• Type STOP or CLOSE and the name of the program or programs you want to stop.
Stop Programs from Command Window
www.PDF-Zoo.com
Overview of Programming
5-40 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Chapter 6
WritingFundamental
ProgramsWe recommend you read Chapter 4 and Chapter 5 before you read this chapter, and then proceed sequentially in this one. This chapter includes brief sample programs and presents these programming concepts:
• Planning the Instructions
• Limiting When Action Is Taken
• Continuously Testing the Limitation
• Setting Up Comparisons with IS
• Taking Action at a Certain Time
• Taking Multiple Actions at a Certain Time
• Forming Line Labels
• Using Line Labels to Control Program Flow
• Applying Elapsed Time
• Monitoring the Line a Program Is On
• Taking Action on Certain Days
• Finding Format Errors
www.PDF-Zoo.com
Fundamental Programs
6-2 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-3
Table 6-1 shows the input and output points used in this chap-ter.
Table 6-1. Input and Output Points
Controller
Dampers BLDG1 FLOOR1
SupplyFanST BLDG1 FLOOR1
PrehtValve BLDG1 FLOOR1
ReturnFan BLDG1 FLOOR1
SCX 900
SCX 900
SCX 900
SCX 900
Point Point TypeModel
HWP1ISOValve CENTRALPLANT
Burner CENTRALPLANT
BurnerST CENTRALPLANT
HWPump1 CENTRALPLANT
CX 9000 IOU
CX 9000 IOU
CX 9000 IOU
CX 9000 IOU
OutsideAir CENTRALPLANT CX 9000 IOU
Current Output
Digital Input
Current Output
Form C Output
Digital Output
Form C Output
Digital Input
Digital Output
Thermistor Input
HWPump1ST CENTRALPLANT CX 9000 IOU Digital Input
www.PDF-Zoo.com
Fundamental Programs
6-4 Infinity Controller Programmer’s Guide
Planning the InstructionsGenerally, the steps you must take to plan and write a program are:
1. Decide what you want the controller to do.
2. Break down the action into single-action steps.
3. Find the locations of the equipment it is to act on, on the map of the network.
4. Find the names of the points on the controllers or controller drawings.
5. Find the keywords you need.
Keywords are presented as required in this manual and all are covered in detail in Andover Controls Plain English Language Reference.
6. Write the program.
How to write programs is outlined in Chapter 5, this chapter, and subsequent chapters in this manual.
7. Check the program for errors.
See Appendix B for how to respond to the various error messages that may occur.
8. Save the program.
How to save a file is explained in this chapter. How to save it to magnetic media is covered in detail under the SAVE command in the Andover Controls Plain English Language Reference.
Figure 6-1 shows a diagram of the planning process.
Steps to Planning
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-5
Figure 6-1. Diagram of the Planning Process Diagram of PlanningProcess
Decide Whatto Have theController Do
Make Action into SingleSteps
Find the Controller thePoints Are On
Find the Names of the Points Needed
Find the Keywords Needed
Write theProgram
Check theProgram
Save theProgram
Read theblocksfrom top to bottom
www.PDF-Zoo.com
Fundamental Programs
6-6 Infinity Controller Programmer’s Guide
Lim iting When Action Is TakenGOAL: When the supply fan is on, turn on the preheat valve for the warmup.
How do you tell the controller to turn the preheat valve on only when the supply fan is on?
First, let’s break down the actions to take. The single-action steps to turn the valve on if the fan is on are as follows:
1. Check to see if the supply fan status is on.
2. If the fan is on, turn on the preheat valve.
Figure 6-2 shows a diagram of the program flow. This diagram is called a “flowchart” because it charts the flow of the program.
Figure 6-2. Flowchart of WARMUPl
Flowchart ShowsProgram Flow
Turn On the Preheat valve
Isthe supply fan
ON?
YES
Start
End
ReadfromTop toBottom
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-7
The two points you need to write the program are an input point called SUPPLYFANST (which gives the supply fan status) and an output point called PREHTVALVE.
To check the status of the fan, you would use the keywords IF and THEN as follows:
IF THE SupplyFanST IS ON THEN...
The next step is to turn the heat on. You can use the keyword OPEN to form the statement:
...OPEN THE PrehtValve
As shown in Figure 6-3, in the completed program, the two steps must be combined in one line:
Figure 6-3. WARMUP Program
This complete statement is called an IF..THEN statement. The IF half of the statement is a TRUE-FALSE comparison.
Decide Points Required for Program
File Edit Search Check Tools
FLOOR1 AHU WARMUP
IF THE SupplyFanST IS ON THEN OPEN THE PrehtValve
The TRUE-FALSE Comparison
A Statement That Could Stand OnIts Own
www.PDF-Zoo.com
Fundamental Programs
6-8 Infinity Controller Programmer’s Guide
Figure 6-4 repeats the WARMUP program so you can view it while you read the explanation that follows.
Figure 6-4. WARMUP Program
The controller checks the point called SUPPLYFANST. If it is ON, the statement is TRUE. If it is OFF, the statement is FALSE.
The comparison must be TRUE for the controller to carry out the action after THEN.
Notice that the THEN half of the statement contains a statement that could stand on its own. You can put any action statement after THEN.
If the comparison is FALSE, and the program is set to FallThru in the File window, the controller skips the THEN statement and goes on to the next action in the program. In this case, there is no next action, so the program ends.
File Edit Search Check Tools
IF THE SupplyFanST IS ON THEN OPEN THE PrehtValve
The TRUE-FALSE Comparison
A Statement That Could Stand OnIts Own
FLOOR1 AHU WARMUP
THEN Part ContainsStandard Statement
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-9
Summary
• You can draw a diagram of the flow of program action called a “flowchart.”
• You can limit when action occurs using IF..THEN.
• The IF half of the IF..THEN statement is a TRUE-FALSE comparison.
• The THEN half of the IF..THEN statement contains a statement that could stand on its own.
• When the TRUE-FALSE comparison is TRUE, the controller carries out the THEN statements.
• When the TRUE-FALSE comparison is FALSE, the controller skips the THEN statements and goes to the next statement or, if there is no next statement, ends the program.
IF and THEN Limit When Action Occu rs
www.PDF-Zoo.com
Fundamental Programs
6-10 Infinity Controller Programmer’s Guide
Continuously Test ing the Lim itationLet’s take another look at the WARMUP program. The control-ler checks to see if the supply fan is on. If the fan is not on, the controller skips the action after THEN and ends the program.
How do you get the controller to check again to see if the sup-ply fan is on? You could run it repeatedly using RUN on the command line, but that would quickly become impractical.
When the controller processes each program statement, it “scans” all statements in order. The scan “flows” from statement to statement. (Chapter 9 gives more details on scanning.) It scans a statement or group of statements more than once if you change the program FLOWTYPE.
Changing the Flow of th e Scan
To change the program flow so it automatically keeps checking the status of the supply fan, you do the following:
1. Go the Main menu bar and select Edit File .
2. Once the Editor window opens, to see the file attributes, select File Configuration from the File menu bar.
3. When the File window appears, move to the FLOWTYPE attribute (using the NEXT ATTRIBUTE key) and select Looping .
Figure 6-5 shows the FLOWTYPE attribute reset to Looping .
Figure 6-5. FLOWTYPE File At tribute Set to Loop ing
Controller Scans AllStatements
(X) Looping
( ) FallThru
FLOWTYPE
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-11
Each FLOWTYPE makes the program work differently:
• If WARMUP is FallThru , the controller starts at the beginning and carries out each statement until the end. The flow of the program action “falls thru” the statements until the end.
• If WARMUP is Looping , the controller repeats the current action until instructed to do otherwise. Once you start a looping program, it runs continuously until you disable or stop it.
You saw the flowchart of WARMUP as a FallThru program in the previous section. It started at the beginning and stopped at the end.
Figure 6-6 shows the program flow if WARMUP is a Looping , rather than FallThru , program.
Figure 6-6. Looping Flowchart of WARMUP
Notice that the flowchart does not have ovals that say “start” and “end.”
The reason is that it does not really start in one place and it never ends. Instead it runs continuously, testing to see if the supply fan is on and opening the preheat valve when it is.
FLOWTYPEs Are Loop ing and FallThru
Open the Preheat Valve
Is supply fan ON?
YES
NO KeepChecking
www.PDF-Zoo.com
Fundamental Programs
6-12 Infinity Controller Programmer’s Guide
Starting Fa llThru Programs
If the program is FallThru , you do not have to start it by entering RUN on the command line (or from another program). You can, instead, start it by setting a “trigger.” A trigger is a point that starts a program. When the trigger point value changes, it “triggers” (starts) the program.
In the sample given here, the SUPPLYFANST could be a trigger to start the WARMUP program.
If SUPPLYFANST were a trigger, when the SUPPLYFANST changed from OFF to ON or ON to OFF, the program would then start, test the status, and take the appropriate action. After completing the action, the program would stop and wait to be triggered again.
Starting Lo oping Programs
In contrast, if the program is looping, you start it by either entering a RUN command on the command line or setting it to AUTOSTART in the File window. Once the looping program starts, it does not stop unless you disable it or enter a STOP command on the command line.
Both Openin g and Closin g Equi pmen t
Notice that WARMUP opens the preheat valve, but when does it close it?
The program is not complete until it tells the controller both when to open and when to close the valve. You should always handle opening and closing a particular piece of equipment (or turning it on and off) in the same program. Otherwise, because the controller scans programs in the order they appear on the firing order list, and the entire scan of all programs occurs in a fraction of a second, you could run into a conflict between one program’s instructions and another’s.
Set a Trigger forFallThru Programs
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-13
For example, if WARMUP opens the preheat valve and, later in the scan, STOPVALVE closes it, the preheat valve never actually opens. Problems arise when a program in between WARMUP and STOPVALVE thinks the preheat valve is open and proceeds to run other equipment that should not be run when the valve is closed.
So, let’s alter the sample program to control both opening and closing the valve.
NEW GOAL: When the supply fan is on, open the preheat valve. When the fan is off, close the valve.
The single-action steps are:
1. Check to see if the supply fan is on or off.
2. If the fan is on, open the preheat coil valve.
3. If the fan is off, close the preheat coil valve.
Figure 6-7 shows the expanded flowchart for the program.
Figure 6-7. Expanded Flowchart of WARMUP
Same Program Bot h Opens and Closes Valve
Open the Preheat Valve
Is the Fan ON or OFF?
ON
Close the Preheat Valve
OFF
KeepChecking
www.PDF-Zoo.com
Fundamental Programs
6-14 Infinity Controller Programmer’s Guide
Figure 6-8 shows the looping version of the WARMUP program, made up of two IF..THEN statements.
Figure 6-8. Expanded Loop ing WARMUP Program
In this looping program, the controller constantly executes the statements. The controller may also repeat a group of statements defined as a line under a label. (More about line labels is included later in this chapter.)
Selecti ng Lo oping or Fal lThru
The same program can be FallThru . The FallThru FLOWTYPE saves controller time by running the program only when necessary. The controller runs more efficiently with FallThru programs, but you may find instances when Looping programs are useful.
File Edit Search Check Tools
FLOOR1 AHU WARMUP
IF THE SupplyFanST IS ON THEN OPEN THE PrehtValve
IF THE SupplyFanST IS OFF THEN CLOSE THE PrehtValve
FallThru Programs A reMore Efficien t
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-15
Summary
• A FallThru program carries out each statement in order.
• A Looping program repeats the current action until it is told to do something else.
• To set program flow, you set the FLOWTYPE attribute in
the File window to Looping or FallThru .
• Each time the controller processes statements in all programs, that action is called “scanning.”
• The controller scans all programs in the order you list them in the “firing order list.”
• FallThru programs use the controller more efficiently that Looping programs.
• Turning ON and OFF the same piece of equipment in one program is the safest way to avoid conflicts related to the firing order list.
Scannin g Is Processin g Statements
www.PDF-Zoo.com
Fundamental Programs
6-16 Infinity Controller Programmer’s Guide
Sett ing Up Comparisons w ith ISGOAL: To turn on the return air fan when the supply air fan is on.
You can form many different types of TRUE-FALSE comparisons with one word—IS.
You have seen IS used in an IF..THEN statement. You can use IS to form comparisons that check to see if two items are equal as follows:
IF THE SupplyFanST IS ON THEN...
IF THE SupplyFanST IS EQUAL TO ON THEN...
IF THE SupplyFanST EQUALS ON THEN...
IF THE SupplyFanST = ON THEN...
All of these comparisons state the same idea. You can see how flexible the Andover Controls Plain English language is.
The single-action steps to turn on the return air fan when the supply air fan is on are as follows:
1. Check to see if the supply air fan is on.
2. If the supply fan is on, turn on the return fan.
3. If the supply fan is off, turn off the return fan.
Figure 6-9 shows the flowchart of the program.
You need two points to write the program, SUPPLYFANST (status input) and RETURNFAN.
The keywords you need to write the program are IF, THEN, IS (or EQUALS, = , IS EQUAL TO), ON, OFF, TURN, and THE.
IS Statements Can Be inDifferent Forms
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-17
Figure 6-9. Flowchart of ACTIVATE.FAN
Figure 6-10 shows the program.
Figur e 6-10. ACTIVATE.FAN Program— Loopi ng
Summary
• You use the IS keyword to form comparisons.
• IS, IS EQUAL TO, EQUALS, and = all have the same meaning.
Turn On the
YES
NOIs
ON?Supply Fan
Return Fan
KeepChecking
Turn Off theReturn Fan
FLOOR1 AHU ACTIVATE.FAN
IF THE SupplyFanST IS ON THEN TURN ON THE ReturnFanIF THE SupplyFanST IS OFF THEN TURN OFF THE ReturnFan
File Edit Search Check Tools
IS Has Many Aliase s
www.PDF-Zoo.com
Fundamental Programs
6-18 Infinity Controller Programmer’s Guide
Taking A ction at a Certain TimeGOAL: To start the MORN.WARMUP at 8:30 a.m. and stop it after 9:00 a.m.
How do you tell the controller when to act? You have it check the Time of Day, stored in the controller as TOD.
When you print it, TOD always gives the time on the 12-hour clock, so 6:00 in the evening is 6:00 pm and 6:00 in the morning is 6:00 am.
You can compare TOD to the time with a colon or without, but if you use the colon you must give either “am” or “pm” (with no periods). Without the colon, you must give the 24-hour time. So, 9:00 in the morning is either 9:00 am or 900 and 6:00 in the evening is either 6:00 pm or 18:00 or 1800.
If you do not give “am” or “pm”, the controller assumes you mean a.m.
Usually time is not tested for an exact moment, because exact moments do not last longer than a minute. It is a good practice to use IS GREATER THAN or IS LESS THAN when testing the time.
IF TOD IS GREATER THAN 8:30 am THEN...
IF TOD > 8:30 am THEN...
All the above TRUE-FALSE statements test to see if the time of day (TOD) is greater than 8:30 in the morning.
You can also see if the time is greater than or equal to a certain time of day (TOD):
IF TOD IS GREATER THAN OR EQUAL TO 8:30 am THEN...
IF TOD >= 8:30 am THEN...
Test t he Time of Day,Stored as TOD
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-19
IS LESS THAN is particularly useful in setting one boundary for a range of time while IS GREATER THAN sets the other:
IF TOD > 8:30 am AND TOD < 9:00 am THEN...
The above statement illustrates one common way to use TOD. (Methods employing IS BETWEEN are covered in Chapter 7.)
Another common use of TOD involves both GREATER THAN OR EQUAL TO and LESS THAN OR EQUAL TO:
IF TOD IS >= 8:30 am AND TOD <= 9:00 am THEN...
The single-action steps to start and stop the warmup are:
1. Check the time of day.
2. If the time of day is greater than or equal to 8:30 a.m. but less than or equal to 9:00 a.m., start the warmup.
3. If the time of day is less than or equal to 8:30 a.m. but greater than or equal to 9:00 a.m., stop the warmup.
To start the warmup, you tell the controller to start the program you wrote in the previous chapter. You can use the STOP and START keywords to run and stop the morning warmup from inside another program.
Figure 6-11 shows that program.
Figur e 6-11. STRT.WARMUP Program— Loopi ng
GREATER THAN and LESS THAN wit h TOD
FLOOR1 AHU STRT.WARMUP
File Edit Search Check Tools
IF THE TOD >= 8:30 am AND TOD <= 9:00 am THEN START MORN.WARMUP
IF THE TOD <= 8:30 am AND TOD >= 9:00 am THEN STOP MORN.WARMUP
www.PDF-Zoo.com
Fundamental Programs
6-20 Infinity Controller Programmer’s Guide
To form the same program with less words, you can use the ELSE keyword.
Figure 6-12 shows how ELSE saves words.
Figure 6-12. Modified STRT.WARMUP Program
If you want, you can also put ELSE on the same physical line.
Figure 6-13 shows another program that puts IF, THEN, and ELSE all on one physical line.
Notice that in OCCUPY.WARM, the IF part of the IF..THEN..ELSE statement does not contain a comparison formed with IS. For an ON or OFF point, ON is the same as TRUE and OFF is the same as FALSE. So when IF looks at OCCUPIED and sees ON, the “comparison” is TRUE.
Figure 6-13. OCCUPY.WARM Program
File Edit Search Check Tools
IF THE TOD >= 8:30 am AND TOD <= 9:00 am THEN START MORN.WARMUP
ELSE STOP MORN.WARMUP
FLOOR1 AHU STRT.WARMUP
File Edit Search Check Tools
’Triggered by OCCUPIED
FLOOR1 AHU OCCUPY.WARM
IF OCCUPIED THEN START WARMUP ELSE STOP WARMUP
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-21
The following are equal comparisons when the OCCUPIED point is a numeric point you can set to ON or OFF:
IF OCCUPIED THEN...
is the same as
IF OCCUPIED IS ON THEN...
Also, the following are equal comparisons testing for OFF:
IF NOT OCCUPIED THEN...
is the same as
IF OCCUPIED IS OFF THEN...
Summary
• TOD (Time of Day) always gives the time in 12-hour time.
• You can compare TOD to 8:00 (automatically becomes a.m.), 8:00 am, 800, 8:00 pm, or 2000. Whenever you use the colon, the 12-hour time is required and if you do not use the “am” or “pm,” a.m. is assumed. Whenever you use the 24-hour time, you cannot use the colon.
• Usually you use IS GREATER THAN or IS LESS THAN when comparing the time.
• You use the ELSE keyword to tell the controller what to do if the TRUE-FALSE comparison is FALSE.
• In an IF..THEN comparison, when you test a numeric point, ON is the same as TRUE and OFF is the same as FALSE.
ON Is th e Same as TRUE, OFF as FALSE
www.PDF-Zoo.com
Fundamental Programs
6-22 Infinity Controller Programmer’s Guide
Taking Multiple Actions at a Certain TimeGOAL: After 8:00 a.m. and before 9:00 a.m. run the morning warmup.
The following TRUE-FALSE comparison checks to see if the time is after 8:00 a.m.
IF THE TOD > 8:00 am THEN...
This TRUE-FALSE comparison checks to see if the time is before 9:00 a.m.:
IF THE TOD < 9:00 am THEN...
The two statements can be combined as follows:
IF THE TOD > 8:00 am AND TOD < 9:00 am THEN...
Since there is more than one action after THEN, they can each be put on a separate physical line below the IF..THEN comparison.
Figure 6-14 shows the resulting program.
Figure 6-14. WARMUP Prog ram—Loo ping
Can Have More Than OneAction Af ter THEN
File Edit Search Check Tools
FLOOR1 AHU WARMUP
IF THE TOD > 8:00 am AND THE TOD < 9:00 am THEN
TURN ON THE SupplyFan
TURN ON THE ReturnFan
ENDIF
CLOSE THE Dampers
OPEN THE PrehtValve
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-23
When you use more than one statement after THEN, you must do each of these:
• Put them on separate physical lines below THEN.
• Close the IF..THEN statement with ENDIF.
Summary
• You can take action at a certain time by forming a TRUE-FALSE comparison with TOD.
• When two or more actions occur after THEN, they can each be on separate physical lines below IF..THEN and the statement must be closed with ENDIF.
Put Two or MoreStatements Belo w THEN
www.PDF-Zoo.com
Fundamental Programs
6-24 Infinity Controller Programmer’s Guide
Formi ng Line LabelsYou can use “line labels” to put several statements into one “line.” A line is a statement or series of statements that all belong together under one line label. If the line has multiple statements, they are all executed at the same time.
You label a line using the LINE keyword as follows:
LINE TESTING.TEMP
The word LINE warns you that what follows is a line label. TESTING.TEMP is the line label. You form the line label to:
• Tell the line’s purpose.
• Define the line as a unit.
The label tells that what follows is one line, even if it is several statements.
The line label, like any other name, can be up to 16 characters, including underscores, periods, and numbers, but must start with a letter.
An example of a line follows:
LINE HEATING
TURN ON THE Burner
OPEN HWP1ISOValve
START THE HWPUMP1
START CONVRTR.PRGM
You may notice that this line is similar to the program from Chapter 5. Here, however, all the statements from one program are placed in one line.
Why would you want to make them all one line?
You Put SeveralStatements in a Line
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-25
Because all of those actions are for one goal: to activate the heat.
You don’t want this line to run all the time—only when the outside air temperature drops. So you use the word GOTO to go to the next line when it is appropriate.
The GOTO Keyword
You need to send the program to the line when the temperature is less than 50. You do this with a keyword called GOTO.
GOTO tells the program the line to run. It uses the line label to identify the line. A GOTO statement looks like this:
GOTO HEATING
You can use it after THEN. A TRUE-FALSE comparison determines if the temperature is less than 50 degrees:
IF THE TEMP < 50 THEN GOTO HEATING
Next, we write a real program with two lines.
Combine RelatedAct ions in One Line
www.PDF-Zoo.com
Fundamental Programs
6-26 Infinity Controller Programmer’s Guide
Using Line Labels to Cont rol Program Fl owGOAL: To activate the heat when the outside air temperature is below 50 degrees and deactivate it when the temperature is above 50 degrees.
To go from activating the heat to deactivating it, you use the GOTO keyword.
GOTO tells the program which line to run. It uses the line label to identify the line. A GOTO statement looks like this:
GOTO HEATING
The single-action steps you would use to activate the heat and then deactivate it when the temperature changes are:
1. Check the temperature.
2. If the temperature is below 50 degrees:
• Turn on the burner.
• Open the hot water pump isolation valve.
• Start the hot water pump.
• Start the converter control program.
3. If the temperature is above 50 degrees:
• Turn off the burner.
• Turn off the hot water pump.
• Close the hot water pump isolation valve.
• Stop the converter.
Figure 6-15 shows a flowchart of the program.
Use GOTO to Swit chLines
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-27
Just as in the last looping program, the program stays on the same line until it is told to go to the other line.
Figure 6-15. Flowchart of HEAT.NOHEAT
If the TRUE-FALSE comparison is FALSE, the program skips the THEN and carries out the statements after ELSE.
Figure 6-16 shows the looping program. Before HEATING starts heating, it checks the temperature.
Looping on a Line of Statements
Stop the
Is the Temp < 50?
NO
Is
50? the Temp >
Converter
YES
Turn on theBurner
YESNO
Turn off theBurner
Close the HWPump Valve
Open the HWPump Valve
Start Converter
Start the HWPump
Stop the HWPump
www.PDF-Zoo.com
Fundamental Programs
6-28 Infinity Controller Programmer’s Guide
Figure 6-16. Loo ping HEAT.NOHEAT Progr am
ELSE, like THEN, may have multiple statements following it, each on a separate physical line.
If there are multiple statements after ELSE, the entire IF..THEN..ELSE statement must end with ENDIF.
Because all actions in the same line occur at the same time, this program is not ideal. Some time should elapse between starting the burner and activating the converter control program.
The next program shows how to use elapsed time.
File Edit Search Check Tools
LINE HEATINGIF THE OutsideAir > 50 THEN GOTO NOTHEATING
OPEN HWP1ISOValve
START CONVRTR.PRGMENDIF
LINE NOTHEATINGIF THE OutsideAir < 50 THEN GOTO HEATING
CLOSE HWP1ISOValve
TURN OFF THE Burner
STOP CONVRTR.PRGM
CENTRALPLANT HEAT.NOHEAT
TURN ON THE Burner
ELSE
ELSE
ENDIF
TURN ON THE HWPump1
TURN OFF THE HWPump1
Many Statements AfterELSE Require ENDIF
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-29
Summary
• To go from one line to another, you use GOTO, followed by a line label.
• You form line labels with the LINE keyword.
• A line label should tell the purpose of the line.
• If the TRUE-FALSE comparison is FALSE, the controller skips the THEN statements and carries out the ELSE statements.
• You can have multiple statements after ELSE, but the ELSE group must end with ENDIF on its own physical line.
Use GOTO Foll lowed by a Line Label
www.PDF-Zoo.com
Fundamental Programs
6-30 Infinity Controller Programmer’s Guide
Applying Elapsed TimeGOAL: When the outside air temperature is less than 50, turn on the burner; wait 3 minutes before setting it to high, then start the converter control program. Turn off the burner when the temperature is above 50 degrees.
You can use the amount of time that has elapsed since the program has been on the current (active) line to keep the controller on that line. You use:
TD (Time in Days)
TH (Time in Hours)
TM (Time in Minutes)
TS (Time in Seconds)
You form TRUE-FALSE comparisons as follows:
IF TM > 15 THEN...
IF TH > 1 THEN...
IF TD > 2 THEN...
IF TS > 25 THEN...
You can add a line to the HEAT.NOHEAT program you wrote earlier to determine when the burner has been on for 3 minutes before proceeding:
IF TM > 3 GOTO ADJUSTING
Remember that the controller continues to run the same line until GOTO directs it to another line.
Elapsed Time in Days,Hours, Minutes, Seconds
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-31
So to turn the burner on without doing anything else, you put that action on a separate line:
LINE START.BURNER
TURN ON THE Burner
IF TM > 3 THEN GOTO ADJUSTING
Figure 6-17 shows how the order of lines and statements influences the action of the program. Here HEAT.NOHEAT starts the CONVRTR.PRGM before going to the adjusting phase.
Figure 6-17. Timed HEAT.NOHEAT Program
Put Action on Separate Line to Isolate
File Edit Search Check Tools
LINE NOTHEATINGIF THE OutsideAir < 50 THEN GOTO START.BURNER
TURN OFF THE Burner
STOP THE CONVRTR.PRGMENDIF
LINE START.BURNER
CENTRALPLANT HEAT.NOHEAT
CLOSE THE HWP1ISOValve
ELSE
TURN ON THE Burner IF TM > 3 THEN
LINE ADJUSTING
IF THE OutsideAir > 50 THEN GOTO NOTHEATING
OPEN THE HWP1ISOValveTURN THE BurnerHiFire ON
STOP THE HWPUMP1
TURN ON THE HWPump1
START THE CONVRTR.PRGMGOTO ADJUSTING
ENDIF
www.PDF-Zoo.com
Fundamental Programs
6-32 Infinity Controller Programmer’s Guide
Monitoring the Line a Program Is OnLet’s try running the HEAT.NOHEAT program on the last page.
Details on how to exit and save a program file are inChapter 5 if you need a memory jogger.
1. Press the CANCEL WINDOW key to enter the Command window and type:
RUN HEAT.NOHEAT
2. Press the EXECUTE key.
3. To check the line the program is on, first return to the Main menu bar. Then select View Programs .
As shown in Figure 6-18, the Program Summary window displays this information:
• File name.
• Name of the line the file is currently running.
• The amount of time that has elapsed since the program has been on the current line, displayed as TD, TH, TM,and TS.
• State of the file—E for enabled, D for disabled.
• Status of the file—A for active, I for inactive.
View Program Summaryfrom Main Menu Bar
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-33
Figure 6-18. Prog ram Summa ry Windo w
You can display this window and see the whole minutes and whole seconds that have elapsed (here, 1 minute and 15 seconds shows as 1 whole minute under TM and 75 seconds under TS). You can see that the current line, because it is appropriately named, actually tells you what action is taking place—starting the burner.
To see this same screen from inside a program, you select Tools View Program Summary from the File menu bar.
Summary
• You run a program in the Command window by entering RUN and the program name.
• Select View Programs to see information about programs in the controller.
• The Program Summary window shows each program, the line it is currently running, how long it has been on that line, the STATE (enabled or disabled) of the program, and the STATUS of the program (active or inactive).
• To see the program summary from inside a program, select Tools View Program Summary .
Logon Edit View Connect
Program Summary – FLOOR1 AHU
Name Current Line TD TH TM TS State
HEAT.NOHEAT START.BURNER 0 0 1 75 E / A
RUN and Program Name in Command Window
www.PDF-Zoo.com
Fundamental Programs
6-34 Infinity Controller Programmer’s Guide
Taking Act ion on Certain DaysGOAL: To lower the hot water setpoint on Sundays and raise it to the usual level on other days of the week.
How do you tell the controller to lower the setpoint on a particular day? You have it check the day of the week, stored in WEEKDAY in the controller. The WEEKDAY is one of the following:
SUNDAY SUN 1MONDAY MON 2TUESDAY TUE 3WEDNESDAY WED 4THURSDAY THU 5FRIDAY FRI 6SATURDAY SAT 7
You can compare WEEKDAY to the fully spelled-out day of the week, the abbreviated day, or the number of the day.
So all these TRUE-FALSE comparisons are valid:
IF WEEKDAY IS SUNDAY THEN...IF WEEKDAY IS SUN THEN...IF WEEKDAY IS 1 THEN...
The single-action steps to turn down the heat on Sundays are:
1. Check the day.
2. If the day is Sunday and the burner is ON, lower the hot water setpoint.
3. If the day is not Sunday, run the HEAT.NOHEAT program.
Figure 6-19 shows the flowchart of the program.
WEEKDAY Is Equal toCurrent Day of Week
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-35
Figure 6-19. Flowchart of SUNDAY.HEAT
The points you need are as follows:
• BURNERST—An input point to find the status of the burner, ON or OFF.
• HWSETPT—A numeric point set to 130 for normal or 100 for Sundays.
Forming a Numeric Po int
Since it is neither input nor output, but holds a number, you must define HWSETPT as a numeric point, as follows:
1. Select Numeric for TYPE in the Point window.
2. Put an X next to Setpoint in the Details window by pressing the space bar when the cursor is in the parentheses. Once the point is a setpoint, the controller remembers the point value along with the name whenever you save the controller information with the SAVE command.
Is
? the day Sun
YES
KeepCheckingNO
RunHEAT.NOHEAT
Lower theSetpoint
Is
ON? the Burner
NO
YES
Numeric Point Holds a Number
www.PDF-Zoo.com
Fundamental Programs
6-36 Infinity Controller Programmer’s Guide
Joinin g Two TRUE-FALSE Compariso ns
You can join the two or more TRUE-FALSE comparisons in one statement using AND as follows:
IF WEEKDAY IS SUN AND THE BurnerST IS ON THEN...
Remember, the burner is on only if the temperature outside is less than 50 degrees. So if the burner is off, you do not need to adjust the setpoint.
Figure 6-20 shows the resulting program.
Figure 6-20. SUNDAY.HEAT Program—Looping
Notice the squiggly character (~) at the end of the first physical line in the above program. This character, called a tilde, continues the statement on the next physical line.
To continue any statement on the next physical line, insert a tilde (~), press the EXECUTE key, and keep typing.
Use AND to Join TRUE-FALSE Comparisons
File Edit Search Check Tools
FLOOR1 AHU SUNDAY.HEAT
IF WEEKDAY IS SUN AND THE BurnerST = ON THEN~ ELSE
SET THE HWsetpt TO 100
RUN HEAT.NOHEAT
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-37
An Alternativ e Approach
You can also integrate the SUNDAY.HEAT and HEAT.NOHEAT programs, so that HEAT.NOHEAT includes the question of what day it is.
It is easiest to insert the weekday check under ADJUSTING, since the burner should still be on when the temperature drops, but not on high.
It is also good to test for NOT SUNDAY, since that means the day can be any other weekday. The NOT keyword comes in handy in this situation.
Three minutes should go by before the controller turns off the burner after adjusting it. So, a TRUE-FALSE comparison can check the elapsed time at the end of the ADJUSTING line.
Figure 6-21 shows the looping HEAT.NOHEAT program with both statements altered under ADJUSTING.
Add a Test for the Day of Week
www.PDF-Zoo.com
Fundamental Programs
6-38 Infinity Controller Programmer’s Guide
Figure 6-21. Modi fied HEAT.NOHEAT Program
File Edit Search Check Tools
LINE NOTHEATINGIF THE OutsideAir < 50 THEN GOTO START.BURNER
TURN OFF THE Burner AND THE HWPump1
ENDIF
LINE START.BURNER
OPEN THE HWP1ISOValve
CENTRALPLANT HEAT.NOHEAT
ELSE
TURN ON THE Burner IF TM > 3 THEN
LINE ADJUSTING
IF THE OutsideAir > 50 AND TM > 3 THEN GOTO NOTHEATING
IF THE WEEKDAY IS NOT SUNDAY THEN
ELSESET THE HWsetpt TO 130
SET THE HWsetpt TO 100
CLOSE THE HWP1ISOValve AND THE CONVRTR.PRGM
TURN THE BurnerHiFire ON ’Sets Burner to High
TURN ON THE HWPump1
ENDIF
START THE CONVRTR.PRGMGOTO ADJUSTING
ENDIF
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-39
Add ing Com ments
Also, to make a program more readable, you can include a “comment” on the same physical line or on a separate one. The controller ignores comments.
To add a comment, type a single quotation mark and type the text after it. Do not exceed the length of the physical line. The following is an example of a comment:
’This is a comment. Program ends here.
(See also the comment in the HEAT.NOHEAT ADJUSTING line.)
Summary
• You can take action on certain days of the week by forming a TRUE-FALSE comparison with WEEKDAY.
• WEEKDAY contains one of the days of the week. It can be a number, fully spelled-out name, or three-letter abbreviation.
• You can use two TRUE-FALSE comparisons in one statement by joining them with AND.
• You can create a numeric point by setting the TYPE to Numeric in the Point window.
• You can make any point a setpoint by putting an X next to Setpoint in the point’s Details window.
• You can continue a long statement on the next physical line by putting a tilde (~) at the end of the first physical line.
• You add a comment to a program by typing a single quotation mark before it.
• A comment cannot be longer than a physical line.
Controller IgnoresComments
www.PDF-Zoo.com
Fundamental Programs
6-40 Infinity Controller Programmer’s Guide
Finding Format ErrorsAfter you select Check from the File menu bar, you see the words you’ve feared in the message bar at the bottom of the Editor window: Statement or expression is not correct .
Look for the cursor. The cursor is on the first statement containing an error.
Here are some basic problems you can look for in that statement:
1. Be sure you have used the keyword with correct accompanying words.
For example, with TURN, be sure you used ON or OFF. You cannot say TURN VALVE1 TO 70. You can use MOVE, SET, ADJUST, or CHANGE to set VALVE1 to a particular setting rather than simply ON or OFF.
2. Be sure you have spelled the point names correctly. If not, you may receive a message that says No item with that name exists .
The controller may know a point called SupplyFan , but not one called SuplyFan . If you do not spell the name correctly, the controller does not know which point you mean and considers that an error.
(If you included a symbol that does not belong in the name, you receive a message saying Symbol(s) are not from the correct set .)
3. Be sure you have spelled all keywords or their aliases correctly.
If you typed RUM instead of RUN, the controller cannot guess the correct word.
Check Selecti on FindsFormat Error s
www.PDF-Zoo.com
Fundamental Programs
Infinity Controller Programmer’s Guide 6-41
4. If you put a list of points or programs in a statement, be sure you didn’t leave out a comma or put in an extra one.
STOP HEATER, FAN COIL, VALVE needs another comma between FAN and COIL.
STOP, HEATER, FAN, COIL, VALVE should not have a comma after STOP.
5. If you put a list of points or programs in a statement, be sure you use AND or OR only once.
STOP HEATER OR FAN OR COIL OR VALVE is not correct. STOP HEATER AND FAN AND COIL AND VALVE is not correct.
6. Be sure you have all the required information in the statement.
If all you said was MODULATE VALVE and did not say to what setting or what percentage of scale, the statement would not be complete.
7. Be sure you put IF and THEN on the same physical line.
You cannot break an IF..THEN statement between IF and THEN, only after THEN. If you do break an IF..THEN statement after THEN, check to be sure you used ENDIF or ELSE as required.
8. With IS, check to be sure you used the correct words for an operator.
Do no use IS and > together. The symbols do not require IS; they are alternatives to IS GREATER THAN, IS LESS THAN, and similar wordings.
Be Sure Statements Are Complete
www.PDF-Zoo.com
Fundamental Programs
6-42 Infinity Controller Programmer’s Guide
9. Be sure comments start with a single quotation mark.
If you leave the quotation mark out, the controller thinks the comment is a programming statement using incorrect words.
(If the comment does have the quotation mark, but exceeds the 132 character limit, you receive a message that says Comment has more than 132 characters .)
Refer to the Andover Controls Plain English Language Reference for more on formats.
Also, refer to the appendix for a list of messages that can occur and how to correct the related errors.
Append ix Has CompleteList o f Messag es
www.PDF-Zoo.com
Chapter 7
MoreFundamental
KeywordsThis chapter includes brief sample programs strictly for the purpose of illustrating some fundamental keywords and programming concepts. The chapter presents these programming concepts:
• Comparisons with IS NOT
• Comparisons with IS and OR
• Comparisons with IS NOT and OR
• Comparisons with Ranges
• Changing Point Values
• Setting Tristate and Other Pulsing Outputs
• Setting Values with Expressions
• Forming Expressions with TIMES and DIVIDED BY
• Forming Complex Expressions
• Changing the Controller Hour
• Setting the Hour
• Acting on a Change in the Hour of the Day
• Finding More Errors
• Finding Runtime Errors
• Helpful Hints
www.PDF-Zoo.com
More Fundamental Keywords
7-2 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-3
Table 7-1 shows the input and output points used in this chap-ter.
Table 7-1. Input and Output Points
Controller
Damper FLOOR1 ROOM101
Humidifier FLOOR1 AHU
SupplyFan FLOOR1 AHU
ReturnFan FLOOR1 AHU
TCX 850
SCX 900
SCX 900
SCX 900
Point Point TypeModel
Current Output
Current Output
Digital Output
Digital Output
HWConvValve CENTRALPLANT CX 9000 IOU Current Output
www.PDF-Zoo.com
More Fundamental Keywords
7-4 Infinity Controller Programmer’s Guide
Compa risons with IS NOTGOAL: To turn off the humidifier when it is not a weekday, otherwise allow it to operate.
Just as you can form TRUE-FALSE comparisons with IS, you can form them with IS NOT.
IS NOT forms comparisons that check to see if two items are not equal as follows:
IF THE WEEKDAY IS NOT TUESDAY THEN...
IF THE WEEKDAY IS NOT EQUAL TO TUE THEN...
IF THE WEEKDAY DOES NOT EQUAL TUE THEN...
IF THE WEEKDAY <>TUE THEN...
All of the above statements make exactly the same comparison even though they are each worded slightly differently.
The single-action steps to turn the humidifier off when it is not a weekday are:
1. Check to see what day it is.
2. If the day is not a weekday, turn off the humidifier.
3. Otherwise turn on the humidifier.
Figure 7-1 shows the flowchart of the program.
The point you need to write the program is HUMIDIFIER. You also need to check the WEEKDAY.
Compariso ns wi th ISNOT vs. IS
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-5
Figure 7-1. Flowchart of HUMID.CTRL
You can check to see if the WEEKDAY is in a range of weekdays using THRU like this:
IF THE WEEKDAY IS NOT MON THRU FRI THEN...
THRU is always inclusive, so MON THRU FRI includes both Monday and Friday. The statement can also be phrased like this:
IF WEEKDAY IS NOT EQUAL TO TUE THRU FRI THEN...
Or the statement can be phrased like this:
IF THE WEEKDAY IS NOT TUE THRU FRI THEN...
Since the week starts with Sunday and ends with Saturday, you cannot have a range of FRIDAY THRU MONDAY, because Friday and Saturday are in one week and Sunday and Monday are in the next week.
The range must contain days all in the same week. It may not run from Saturday of one week to Sunday of the next.
Figure 7-2 shows the program.
Turn Off the
NO KeepChecking
Is it
Humidifier
YES
not Mon thru Fri?
Start theHumid.Prgm
Must Have Range with in One Week
www.PDF-Zoo.com
More Fundamental Keywords
7-6 Infinity Controller Programmer’s Guide
Figure 7-2. HUMID.CTRL Program—Looping
File Edit Search Check Tools
FLOOR1 AHU HUMID.CTRL
IF THE WEEKDAY IS NOT Mon THRU Fri THEN TURN OFF the Humidifier
ELSE START HUMID.PRGM
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-7
Summary
• You can form TRUE-FALSE statements with IS NOT.
• You can set up a range with THRU, such as MONDAY THRU FRIDAY.
• The THRU range is always inclusive.
• A range of weekdays must always include days in the same week, starting with Sunday and ending with Saturday.
Range with THRU isAlway s Inclu sive
www.PDF-Zoo.com
More Fundamental Keywords
7-8 Infinity Controller Programmer’s Guide
Compa risons with IS and ORGOAL: To modulate the humidifier if the day of the week is Monday, Wednesday, or Friday and to turn off the humidifier if the day is Sunday, Tuesday, Thursday, or Saturday.
You can see if a name or number is in a list by forming another type of TRUE-FALSE statement:
IF WEEKDAY IS IN MON, WED OR FRI THEN...
IF WEEKDAY IS IN MON, WED, FRI THEN...
If one of the days is the weekday, the statement is TRUE. Even if you leave out the OR, with IS the word OR is always understood.
You can also put the word EITHER in the statement:
IF WEEKDAY IS EITHER MON, WED, FRI THEN...
You must precede a list with IN or EITHER.
The single-action steps to see if the weekday is Monday, Wednesday, or Friday are:
1. Check the day of the week.
2. If day of the week is Monday, Wednesday, or Friday, then modulate the humidifier.
3. Otherwise turn off the humidifier.
Figure 7-3 shows the flowchart of the program.
EITHER Goes wit h OR
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-9
Figure 7-3. Flowchart of HUMID.CTRL
The only point you need is HUMIDIFIER.
You run the HUMID.PRGM to modulate the humidifier.
Figure 7-4 shows the program.
Figure 7-4. HUMID.CTRL Program wit h List
Summary
• In TRUE-FALSE comparisons with IS the word OR is understood in a list.
• You must use the word EITHER or IN before a list.
Diagram of PlanningProcess
Modulate the
NO
Humidifier
YES
KeepChecking
Is theDay Mon, Wed
or Fri?
Turn off theHumidifier
File Edit Search Check Tools
FLOOR1 AHU HUMID.CTRL
IF THE WEEKDAY IS EITHER MON, WED OR FRI THEN START HUMID.PRGM
ELSE TURN OFF THE HUMIDIFIER
www.PDF-Zoo.com
More Fundamental Keywords
7-10 Infinity Controller Programmer’s Guide
Comparisons with I S NOT and ORGOAL: To turn off the humidifier if the day of the week is not Monday, Thursday, or Saturday and modulate the humidifier otherwise.
A TRUE-FALSE statement can test to see if a name or number is not in a list:
IF WEEKDAY IS NOT IN MON, THU, SAT THEN...
You can also use the word NEITHER:
IF WEEKDAY IS NEITHER MON, THU, OR SAT THEN...
If the weekday is not any of them, the statement is TRUE.
The single-action steps to turn off the humidifier if the weekday is not Monday, Thursday, or Saturday are:
1. Check the day of the week.
2. If the day of the week is not Monday, Thursday, or Saturday, turn off the humidifier.
3. Otherwise run the humidity control program.
Figure 7-5 shows the flowchart of the program.
Test t o See if Name IsNot in List
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-11
Figure 7-5. Flowchart of HUMID.CTRL2
The only point you need is HUMIDIFIER.
The HUMID.PRGM program modulates the humidifier.
Figure 7-6 shows the program.
Figure 7-6. HUMID.CTRL2 Program—Loo ping
Summary
• You can use NOT or NEITHER to see if a name or number is not in a list.
• You must use IN or NEITHER before the list.
Turn off the
NO KeepChecking
Is the
Humidifier
YES
day not Mon, Thu or Sat?
Modulatethe Humidifier
File Edit Search Check Tools
FLOOR1 AHU HUMID.CTRL2
IF WEEKDAY IS NOT MON, THU OR SAT THEN TURN OFF THE HUMIDIFIER
ELSE START THE HUMID.PRGM
www.PDF-Zoo.com
More Fundamental Keywords
7-12 Infinity Controller Programmer’s Guide
Comparisons with RangesGOAL: To modulate the humidifier if the weekday is Monday, Tuesday, Wednesday, or Thursday and turn the humidifier off otherwise.
Whether you plan to see if a value is in a list or not in a list, you can use a range of values like this:
IF ZONE1TEMP IS 60 THRU 62 THEN...
IF ZONE1 IS NOT 70 THRU 72 THEN...
Notice that you do not include IN in either of these statements.
Be sure to give the number at the bottom of the range first.
Since temperatures and other point values are rarely exactly equal to a whole value, ranges are useful.
Another way to phrase a range is as follows:
IF WEEKDAY IS BETWEEN MON AND THU THEN...
IF WEEKDAY IS NOT BETWEEN THU AND SAT THEN...
Both THRU and BETWEEN are always inclusive. You cannot use the symbols <> with THRU or BETWEEN.
As discussed earlier, a range must be within the same week. Remember, the week starts with Sunday.
The single-action steps to reach the goal are:
1. Check the day of the week.
2. If the weekday is between Monday and Thursday, then run the humidity control program.
3. Otherwise turn off the humidifier.
Figure 7-7 shows the flowchart of the program.
Give L ower Number inRange First
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-13
Figure 7-7. Flowchart of RANGEPROG
The only point you need is HUMIDIFIER.
The HUMID. PRGM program modulates the humidifier.
Figure 7-8 shows the program.
Figure 7-8. RANGEPROG Program—Looping
Summary
• You can set up a range in a TRUE-FALSE statement with THRU or BETWEEN.
• Both THRU and BETWEEN are always inclusive.
• You cannot use <> with THRU or BETWEEN.
Start the
Is the
YES
Thurs?
Day Mon thruNO Turn Off
the Humidifier
Humid.Program
KeepChecking
FLOOR1 AHU RANGEPROG
File Edit Search Check Tools
IF WEEKDAY IS BETWEEN MON AND THU THEN START HUMID.PRGM
ELSE TURN OFF THE HUMIDIFIER
www.PDF-Zoo.com
More Fundamental Keywords
7-14 Infinity Controller Programmer’s Guide
Changi ng Point ValuesYou can change the value of a point from within your program or from the command using one of these three keywords:
TURN (ON or OFF)SETMOVE
The TURN Keyword
You can use TURN as described in Chapter 5 to turn a point or points ON or OFF.
The SET Keyword
The SET keyword sets the value of any type of point to any appropriate value, as follows:
SET THE ROOM101 SpaceSP TO 72
SET THE ROOM101 SpaceSP = 72
The SET keyword itself is optional and understood with the equal sign:
ROOM101 SpaceSP = 72
The MOVE Keyword
Remember that each analog output point has a top of scale and bottom of scale. You can use MOVE to convert engineering units to electrical units to control an output point, using the top and bottom of scale for that point.
If a valve has engineering units of 0 to 360 degrees, and the corresponding electrical units are 0 to 20 mA, when you move the setting to 180 degrees, it sets to 10 mA.
Use Keywords t oChange Point Values
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-15
To give engineering units in a statement and have them automatically convert to electrical units, you use MOVE (or MODULATE) as follows:
MOVE THE HWConvValve TO .8
You can also MOVE a valve to a percentage of a scale from 0 to 1 engineering units. To do this you would set up an auto-conversion in the Details window so that the engineering units are, for example, % Open, and the bottom of scale is 0, the top of scale 1.
See Figure 7-9. Notice that the corresponding number of milliamps is from 0 to 20. One hundred percent open (1.0) corresponds to 20 mA. Fifty percent open (.5) corresponds to 10 mA, halfway between 0 and 20 mA.
Figure 7-9. Auto-Convers ion of Units
MOVE Automatic ally Converts Units
View Edit Connect Logout
Description
Display Format
Exported
Conversion
%###
X
Details – CENTRALPLANT HWConvValve
TRIGGERS
DELETE
LOGS
EXIT
CANCEL
mA
Top
Bottom
Auto-Conversion
HWConvValve
1 20
0 0
Open
www.PDF-Zoo.com
More Fundamental Keywords
7-16 Infinity Controller Programmer’s Guide
The following statement sets the valve to the amount in electrical units (milliamps) that corresponds to .8 engineering units (% Open):
MOVE THE HWConvValve TO 80%
The corresponding value in electrical units on a scale of 0 to 20 mA becomes 16 mA. So the above statements sets the valve to 16 mA.
NoteTo use the percentage to set a valve, the scale in engineering units must be from 0 to 1. Otherwise, the percentage does not give an accurate setting.
You can also move the position of a valve to ON (top of scale) or OFF (bottom of scale):
MOVE THE HW.VALVE TO OFF
You can move a valve to a certain value to, for instance, set a temperature setpoint:
MOVE THE SpaceSP TO 72
Remember, MODULATE is the same as MOVE, so you can use it in appropriate statements:
MODULATE THE HWConvValve TO 50%
Set Valve Using aPercentage of Scale
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-17
The ADJUST and CHANGE Ke ywords
Other alternatives to SET are ADJUST and CHANGE. Each requires that you use TO in the statement and never use the equals sign:
ADJUST THE HW.VALVE TO OFF
CHANGE THE SpaceSP TO 72
LET is another substitute for SET, but requires that you use the equal sign and never use TO:
LET SpaceSP = 68
Summary
You can set a value with the following keywords:
• TURN—ON or OFF.
• SET—With the equal sign (=) or TO.
• SET is optional, so you can set a point as follows:
TEMP = 72
• MOVE or MODULATE—Can move to a setting in engineering units that the controller converts to electrical units, or can move to ON, OFF, or a number.
• MOVE or MODULATE to a percentage of scale—You can move a valve or similar modulating point to a percentage of a scale if and only if you set the scale in engineering units to from 0 (bottom) to 1 (top).
• ADJUST—With TO only, not the equals sign.
• CHANGE—With TO only, not the equals sign.
• LET—With the equals sign only, not with TO.
Alias es of SET Are LET,ADJUST, CHANGE
www.PDF-Zoo.com
More Fundamental Keywords
7-18 Infinity Controller Programmer’s Guide
Sett ing Tristat e and Other Pulsing O utputsTristate output points and digital outputs are controlled by pulsing. Although you can set a tristate point to ON, –ON, or OFF and you can set a digital point to ON or OFF, you can also set each to pulse.
To set a pulsing point to ON, OFF, or –ON for a specific number of seconds, you can set the point to a number.
You may, for example, set a vent that is controlled by pulsing (rather than current) to a value of 90 using either SET or MOVE (or MODULATE), and the point stays set to ON for 90 seconds:
MODULATE THE VENT TO 90
The point pulses for that number of seconds.
You can set a tristate point the same way, or set a tristate point to a negative number and it remains set to –ON for that number of seconds:
MODULATE THE ROOM101 Damper TO –60
A tristate point also pulses when given a numeric setting rather than one of the three standard settings.
Set Trist ate and DigitalPoints t o Pulsed Values
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-19
Summary
You can set a pulsing point value as follows:
• Digital outputs to ON or OFF.
• Tristate outputs to ON, –ON, or OFF.
• Digital or tristate outputs to a positive number to set them to ON for that number of seconds.
• Tristate outputs to a negative number to set them to –ON for that number of seconds.
Set Tristate Outpu ts to –ON with Negat ive Value
www.PDF-Zoo.com
More Fundamental Keywords
7-20 Infinity Controller Programmer’s Guide
Setti ng Values with Expressi onsGOAL: To set the hot water temperature setpoint based on the lowest space temperature. The range for the setpoint is 100 to 180 degrees Fahrenheit.
You can set a value of an output point (or numeric point) to any number or any expression that gives a number.
For instance, instead of setting the setpoint to a specific number of degrees, you can set it to a formula that gives a number, such as:
CHW.SETPT PLUS .25 or CHW.SETPT + .25
180 MINUS LOWSPACEFCTR
or 180 – LOWSPACEFCTR
You then set a value as follows:
SET HWTEMP.SETPT TO 180 – LowSpaceFctr
Or you can update a setting by adding to its current value:
SET CHWTEMP.STPT = CHWTEMP.STPT + .25
This statement sets the new chilled water temperature setpoint to the current chilled water temperature setpoint plus .25.
The single-action steps to set the hot water temperature are:
1. Check the lowest space temperature to determine the lowest space temperature adjustment factor (LOWSPACEFCTR).
2. Set the hot water temperature setpoint based on the LOWSPACEFCTR.
Set a Numeric Point toAn Expressio n
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-21
3. Be sure hot water is between 100 and 180 degrees.
Figure 7-10 shows the flowchart of the program.
You need two numeric points, called HWTEMP.SETPT and LOWSPACEFCTR.
Figure 7-10. Flowchart of WATERTEMP
Figure 7-11 shows the program that combines the two steps in one statement. The controller automatically checks the lowest space temperature to update the LOWSPACEFCTR point value.
Keep Value with in a Range
Set the
Check the Low-
based on
Space Factor
Is
< 100? 180 – LowSpaceFctr
NO
YES
Set the HotWater Tempto 100 degrees
LowSpace-
Hot WaterTemp
KeepChecking
Is
>180 ? 180 – LowSpaceFctr
YES
Set the HotWater Tempto 180 degrees
NO
Fctr
www.PDF-Zoo.com
More Fundamental Keywords
7-22 Infinity Controller Programmer’s Guide
Figure 7-11. WATERTEMP Prog ram—Loo ping
You can also substitute the following for the comparisons in the program:
IF 180 MINUS LowSpaceFctr IS BELOW 100 THEN...
IF 180 MINUS LowSpaceFctr IS ABOVE 180 THEN...
You can use IS BELOW for IS LESS THAN and IS ABOVE for IS GREATER THAN.
An alternative way to write this program is shown inChapter 8 under the MINIMUM and MAXIMUM keywords.
File Edit Search Check Tools
FLOOR1 AHU WATERTEMP
IF 180 MINUS LowSpaceFctr < 100 THEN HWTEMP.SETPT = 100IF 180 MINUS LowSpaceFctr > 180 THEN HWTEMP.SETPT = 180
IF 180 MINUS LowSpaceFctr IS 100 THRU 180 THEN
SET HWTEMP.SETPT TO 180 MINUS LowSpaceFctr
ELSE
ENDIF
IS BELOW Means ISLESS THAN
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-23
Summary
• You can use the keywords PLUS and MINUS to form expressions.
• You can substitute the symbols + and – for the keywords.
• You can use an expression anywhere you would use a number.
• You can set a point value to an expression.
• You can use IS BELOW for IS LESS THAN.
• You can use IS ABOVE for IS GREATER THAN.
Use PLUS and MINUS to Form Expressions
www.PDF-Zoo.com
More Fundamental Keywords
7-24 Infinity Controller Programmer’s Guide
Formi ng Expr essions with TIMES and DIVIDED BYAs you saw in the last two pages, forming expressions in Andover Controls Plain English is really straightforward.
Expressions that require multiplication and division are formed with the TIMES and DIVIDED BY keywords.
Suppose that, for instance, you want to perform calculations on the outside air temperature before you use it.
To set up a calculation with multiplication in it, you use TIMES or the asterisk (*):
OutsideAir TIMES RATEOFRISE
OutsideAir * RATEOFRISE
Suppose, also, that you want to calculate the average kwh usage. To set up a calculation with division in it, you use DIVIDED BY or the slash (/):
SET KWH = KWMeter DIVIDED BY SCAN + KWH
SET KWH = KWMeter / SCAN + KWH
SCAN is a system variable (a keyword that Infinity assigns a value) that measures the length of the controller scan of all programs. You learn more about SCAN later in this manual.
You can also combine multiplication and division in one expression.
Use TIMES and DIVIDEDBY to Form Expressions
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-25
Summary
• You can use the keywords TIMES and DIVIDED BY to form expressions.
• You can substitute the asterisk (*) for TIMES and the slash (/) for DIVIDED BY in expressions.
Use Aster isk and Slash Symbol s
www.PDF-Zoo.com
More Fundamental Keywords
7-26 Infinity Controller Programmer’s Guide
Formi ng Complex Expressi onsYou can combine addition, subtraction, multiplication, and division in one expression as follows:
STARTHR = 6.0 + (70 – OutsideAir) * OATCHANGE/TIME
If the parentheses were not in the above statement, the OUTSIDEAIR would be multiplied by the OATCHANGE before subtracting OUTSIDEAIR from 70. The result would not be useful.
The “Order of Calculation” is important, because without the parentheses, the controller would give a different result.
The controller always carries out the operation in parentheses first.
All multiplication and division are carried out from left to right, and are always carried out before addition and subtraction.
Addition and subtraction are also carried out from left to right.
So, the controller carries out the calculation above in the following order:
1. Subtracts OUTSIDEAIR from 70 (the first parentheses).
2. Multiplies the result of step 1 by OATCHANGE.
3. Divides the result of step 2 by TIME to set the rate of rise.
4. Adds the result of step 3 to 6.0.
Use Parentheses inComplex Expressio ns
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-27
Summary
• You can form one complex expression using multiple operations.
• The controller carries out operations in parentheses first.
• Multiplication and division are carried out before addition and subtraction; all four of these operations are carried out from left to right.
Process es Occ ur in a Specific Or der
www.PDF-Zoo.com
More Fundamental Keywords
7-28 Infinity Controller Programmer’s Guide
Changi ng the Cont rol ler HourYou can use SET to set a system variable called HOUR. The HOUR is automatically updated by the controller, but you can change the setting for daylight savings time or a time zone change. (Daylight savings time is the only reason to reset HOUR once Infinity is functioning.)
You must be at Administrate security level to change the HOUR.
You set the hour like this:
SET HOUR TO 6
Or you can set the hour in any one of the following ways:
SET HOUR = 5 + 1
HOUR = HOUR – 1
SET HOUR TO HOUR + 1
You cannot set any date or time system variable except HOUR and DATE. All of the others are set and updated by the controller. Here is a list of the others:
WEEKDAYDAYOFYEARMONTHDAYOFMONTHYEARHOURMINUTESECONDHOD (Hour of Day)TOD (Time of Day)
WEEKDAY and TOD were introduced earlier. The others are covered in the Andover Controls Plain English Language Reference.
Must Have Administ rateAccess to Set HOUR
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-29
You also cannot delete any system variable, since each is a permanent part of Infinity.
Summary
• HOUR and DATE are the only system variables you can set.
• You must be at Administrate security level to set HOUR.
• You can set HOUR equal to an expression that contains HOUR. (HOUR = HOUR MINUS 1). The hour to the right is the old value of HOUR.
• You cannot delete any system variable.
You Can Set HOUR and DATE
www.PDF-Zoo.com
More Fundamental Keywords
7-30 Infinity Controller Programmer’s Guide
Sett ing t he HourGOAL: To set HOUR when daylight savings time begins.
To set the HOUR when daylight savings time begins, you need to check for the correct day every time the DAYOFYEAR changes.
DAYOFYEAR is the number from 1 to 365 that stands for a particular day of the year. January 1 is 1, January 2 is 2, and, finally, December 31 as 365.
The single-action steps are:
1. Check the month to see if it is April.
2. Check the day of the month to see if it is the first week (between 1 and 7).
3. Check the day of the week to see if it is Sunday.
4. If it is the day daylight savings time starts, at 2:00 a.m. set the HOUR to one hour later than the current hour.
5. If it is the day daylight savings time starts, but it is not yet 2:00 a.m., wait until 2:00 a.m., then set the HOUR.
Figure 7-12 shows the flowchart of the program.
First you set up the TRUE-FALSE comparisons:
IF MONTH IS NOT APRIL THEN STOP DAYLIGHT
IF DAYOFMONTH IS BETWEEN 1 AND 7 THEN...
IF WEEKDAY IS SUNDAY THEN...
IF HOUR = 2 THEN...
Then you form the statement to set the HOUR:
SET HOUR TO HOUR + 1
DAYOFYEAR Is Numberfrom 1 to 365
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-31
Figure 7-12. Flowchart of DAYLIGHT
Figure 7-13 shows the program that results when you combine the steps.
Is
April?
YES
NO
End
Start
Set the Hour toDST
the month
Is
2? the Hour
YES
Is
1-7? day of month
Is
Sun? weekday
YES
YES
NO
NO
NO
Flowch art of Dayl igh t Program
www.PDF-Zoo.com
More Fundamental Keywords
7-32 Infinity Controller Programmer’s Guide
Figure 7-13. DAYLIGHT Program—FallThru
Notice that tilde (~) continues the IF..THEN statement as if it were on the same physical line. ELSE with only one statement after it fills in for ENDIF.
You definitely don’t want the DAYLIGHT program to be looping. It would continue to check the month, day of month, and day of week over and over during the same day. What you really want it to do is check only when the DAYOFYEAR changes.
Set it to FallThru in the File window so that after it runs, it ends.
Then, so that it starts only when the DAYOFYEAR changes, you set a trigger (see the next chapter).
File Edit Search Check Tools
FLOOR1 AHU DAYLIGHT
IF THE MONTH IS APRIL AND DAYOFMONTH IS BETWEEN 1 AND 7~
IF THE HOUR = 2 THEN
STOP DAYLIGHTSET THE HOUR TO HOUR + 1
ELSE GOTO ADJUSTHOUR
LINE ADJUSTHOUR
THEN
LINE SETHOUR
’Triggered by DAYOFYEAR
ELSE STOP DAYLIGHTIF THE WEEKDAY IS SUNDAY THEN GOTO SETHOUR
ENDIF
Set a Trigger to StartProgram
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-33
Summary
• The system administrator is the only user who can set the HOUR.
• DAYOFYEAR is the number of the day of the year, from 1 to 365.
• You can place an IF..THEN statement inside another IF..THEN statement (after THEN).
• To make a program run once, then stop, you set it to FallThru in the File window.
You Can Put One IF.. THEN Insid e Another
www.PDF-Zoo.com
More Fundamental Keywords
7-34 Infinity Controller Programmer’s Guide
Act ing on a Change in the Hour of the DayGOAL: To leave the supply and return fans on for 1/2 hour after the building is no longer occupied.
To take action at a specific hour of the day (HOD), the controller has the HOD system variable.
The HOD Keyword
The HOD, unlike the HOUR, cannot be changed. It gives the hour of the day in decimal form. If it is 2:30, the HOD is 2.5. If it is 3:30, the HOD is 3.5.
You can use HOD like this:
IF THE HOD > 6.5 THEN TURN OFF THE LIGHTS
But HOD is most useful in calculations. Since it is not possible to add 3:30 + 1 to get 4:30, how do you add an hour to the time?
You add an HOD of 3.50 + 1 to get 4.50 and the controller automatically understands that an HOD of 4.5 is 4:30. Similarly, you add .5 to the HOD to add 1/2 hour, making 3.25 into 3.75, or 3:45.
The single-action steps are:
1. Check to see if the building is still occupied.
2. If it is occupied, continue checking.
3. If the area is not occupied, proceed.
4. Check the current HOD to see if 1/2 hour has gone by.
5. If 1/2 hour has not gone by, keep checking.
Steps to Planning
Adding to the Hour
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-35
6. If 1/2 hour has gone by, turn off the supply fan and return fan.
Figure 7-14 shows the flowchart of the program.
Figure 7-14. Flowchart of TIMEOUT.FAN
Points Required
You need the SUPPLYFAN and RETURNFAN points. You also need a customized keyword called OCCUPANCY, which checks for occupancy and sets it to ON or OFF.
You can make a note of the current hour by putting it in LASTHOUR using a SET statement, as follows:
SET LASTHOUR = HOD
The trouble with this is that LASTHOUR doesn’t mean anything to the controller. You must define it as a point.
Since it is neither input nor output, but holds a number, you must define it as a numeric point in the Point window, by selecting Numeric for TYPE.
Is
?
YES
NO Keep Checking
Turn off the Fans
Has
By?
YES
NO Keep Checking
Occupied On
1/2 Hour Gone
Diagram of PlanningProcess
www.PDF-Zoo.com
More Fundamental Keywords
7-36 Infinity Controller Programmer’s Guide
So, in addition to the other points, you need the LASTHOUR point.
Completi ng the Program
You would construct the calculation to see if 1/2 hour has gone by like this:
IF THE HOD = THE LASTHOUR + .5 THEN...
Remember that if you use two or more statements after THEN, you must end the block with ENDIF.
Remember, also, that you can label a line with either the keyword LINE or the name of the line followed by a colon. The colon is used in the example here.
Figure 7-15 shows the complete program.
Figure 7-15. TIMEOUT.FAN Program—Loopi ng
If the building is occupied, then the LASTHOUR is set over and over until OCCUPANCY is OFF. When OCCUPANCY
Calculate Hour UsingHOD
File Edit Search Check Tools
FLOOR1 AHU TIMEOUT.FAN
OCCUPIED:
SET LASTHOUR = HOD
IF OCCUPANCY() = OFF THEN GOTO TIMING
ENDIF
IF THE HOD = THE LASTHOUR + .5 THEN
TURN OFF THE SupplyFan
TURN OFF THE ReturnFan
IF and ENDIFPair
TIMING:
IF OCCUPANCY() = ON THEN GOTO OCCUPIED
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-37
is OFF, the controller goes to TIMING and uses the last value of LASTHOUR in TRUE-FALSE comparison with HOD.
Summary
• HOD is the decimal form of the hour of the day.
• HOD is most useful in calculations, where you add hours to the current hour.
• You can create a numeric point using the NUMERIC keyword at the top of your program.
• You can use a numeric point in any program on the controller.
HOD Is a Decimal Form of HOUR
www.PDF-Zoo.com
More Fundamental Keywords
7-38 Infinity Controller Programmer’s Guide
Finding More Err orsAfter you select Check from the File menu bar, you see these words at the bottom of the Editor window: ERROR: Statement or expression is not correct or similar words indicating an error.
Remember, the cursor is on the first statement containing an error.
Check first to see if any of the errors described at the end of Chapter 6 have occurred. If you still cannot find the error, check the following:
1. Be sure that for every opening parenthesis you have a closing one.
Check all equations twice for this easy-to-miss error.
2. Be sure you have not tried to set a system variable other than HOUR or DATE unless you have the Admin security level. The error for such a statement would say something like You cannot change value of system variable .
3. Be sure all ranges start with the lowest number and end with the highest. (Remember also that a range of weekdays must include only days within the same week.)
4. Check to be sure every IF has a THEN. In everyday English you can say IF THE TEMP < 50 TURN ON THE HEAT, but in Andover Controls Plain English, the THEN is required:
IF THE TEMP < 50 THEN TURN ON THE HEAT
5. Check to be sure every IF..THEN comparison is complete; for example, the following is incorrect:
IF WEEKDAY IS SUN OR MON THEN...
Errors Inclu de Missin gParenthesis
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-39
The OR keyword must go between two complete comparisons, as follows:
IF WEEKDAY IS SUN OR WEEKDAY IS MON THEN...
Other correct ways to phrase the comparison are as follows:
IF WKD IS BETWEEN SUNDAY AND MONDAY THEN...
IF WEEKDAY IS SUNDAY THRU MONDAY THEN....
You can look up any messages that occur in Appendix B, where we explain what you can do to resolve each message.
Messag es Help YouResolve Issu es
www.PDF-Zoo.com
More Fundamental Keywords
7-40 Infinity Controller Programmer’s Guide
Finding Runtime Err orsSuppose you have eliminated all format errors or other errors Check found. Later, you run the program and discover a new kind of error—the runtime error. Two types of runtime errors can occur:
• Errors that the controller identifies
The controller finds a problem and disables the program because you tried to use a keyword or point in a way that does not work. The controller gives you a message that points to the problem.
• Logical errors (you must identify)
The program does not do what you want it to, or does it at the wrong time, temperature, or the like. The controller does not know anything is wrong—you must recognize the problem.
Eliminate All FormatErrors with Check
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-41
Errors t he Cont roller Id entifie s
Suppose the fan is not being turned on when it should be. How do you know which program has failed to operate the fan? Sometimes the controller can tell you. When the controller finds a problem in a program, it disables the file.
You look at the Disabled Program Summary window and find a program that has been disabled.
You can then open the File Configuration window and the error appears in the lower left corner of the window. An error message that appears once the program is running is called a “runtime error message.”
The controller gives a variety of runtime error messages. We present the messages and explanations for them in Appendix B. Each explanation gives steps you can take to resolve the error.
Examples
One error that produces a runtime error message is attempting to set a tristate point with TURN or any point to a value that is not correct for it.
For example, if you set a digital point to –ON, that would be an error. The error would say something like Set a point or var to value of wrong type .
Another error that produces a runtime error message is nam-ing the wrong path for the point. The error would say Path name is not an actual path .
For instance, the path to the fan might be CENTRALPLANT TOWER FAN and you might have named only TOWER FAN in the program.
Analyze Error Messag es
www.PDF-Zoo.com
More Fundamental Keywords
7-42 Infinity Controller Programmer’s Guide
Sometimes you calculate the value you want to set the HOUR to. If the controller calculates 26, when the program tries to set HOUR to 26, the runtime error message says Must set HOUR to value from 0 to 23 .
The tricky part of finding the error is determining which line the error is on in the program. Unlike format error messages, runtime error messages do not indicate which line the error is on. You have to investigate—open the program and look for a situation that might produce that particular error.
To learn some techniques that help pinpoint the source of the error, refer to Chapter 14.
Errors Yo u Identify (Logic al Errors)
Let’s look at an example of a logical runtime error. Suppose the burner is running almost constantly, even when the building is not occupied. You set the burner to manual control and turn it off for now.
You look at the Disabled Program Summary and find the controller has not disabled any programs.
You search through your programs for statements controlling heating processes. You find this statement:
IF 3 THEN GOTO HEATING
The statement above is in the correct format, because comparisons (after IF and before THEN) must be a number or give a numeric result.
Since 3 is numeric, the statement is TRUE. The problem with the statement is that it is always TRUE. So even if it is 80 degrees Fahrenheit outside, the program still goes to the HEATING line. The same happens with this statement:
IF SUNDAY THEN GOTO HEATING
Statements MustContain Correct Logic
www.PDF-Zoo.com
More Fundamental Keywords
Infinity Controller Programmer’s Guide 7-43
No matter what the actual day is, SUNDAY is always greater than 0, so the controller considers the statement TRUE. Only a value of 0 would be FALSE, and SUNDAY is never 0.
These examples are errors in logic.
To correct these statements, you correct the comparisons:
IF WEEKDAY IS TUE THEN GOTO HEATING
IF WEEKDAY IS SUNDAY THEN GOTO HEATING
Debuggin g Techniq ues
Runtime errors are also called “bugs.” The process of finding those errors is called “debugging.” Many sophisticated techniques exist for debugging programs. We discuss these techniques in Chapter 14.
Summary
Two types of runtime errors exist:
• Errors the controller recognizes and disables a program because of. You can open the File Configuration window and find an error message. Look up how to resolve each message in Appendix B or apply techniques discussed in Chapter 14.
• Logical errors. Refer to Chapter 14 for debugging techniques that help uncover logical and other runtime errors.
Debugging Techn iques
www.PDF-Zoo.com
More Fundamental Keywords
7-44 Infinity Controller Programmer’s Guide
Helpf ul Hint sYou can save yourself from potential problems by following some guidelines when you write your programs.
Add ing Com ments
Suppose a fallthru program should be running but is not. What do you do? Start by checking to see if its trigger is enabled. How do you know the program’s trigger? Maybe you remem-ber them all, but it is not likely.
To jog your memory later, when you first write the program, enter a comment at the top that tells the program’s trigger.
Figure 7-16 shows a trigger comment at the top of a program.
Figure 7-16. Comment to Name the Trigger of FallThru Program
Comments may also be useful to tell the following:
• The program that calls this program.
• The program or programs that call this function.
• The functions this program calls.
For more on functions, refer to Chapter 12.
Use Comments toRemember Triggers
File Edit Search Check Tools
’Trigger is Occupied
FLOOR1 OccTest
If Occupied = ON THEN RUN Chiller.Prog ELSE STOP Chiller.Prog
www.PDF-Zoo.com
Chapter 8
Working with Tri ggers, Logs,and Special Conversions
We recommend you read Chapters 5, 6, and 7 before you read this chapter. This chapter presents:
• Taking Action Only When a Point Changes
• Setting Point Triggers
• Triggering a Program by the Day of Year
• Understanding Logs and Arrays
• Setting Up Logs and Arrays
• Setting the Entry Type and Interval
• Finding the Sum of Logged Values
• Finding the Average of Logged Values
• Finding the Minimum or Maximum Logged Value
• Converting a Flow Sensor Input Point
• Converting a Voltage Producing Transducer Input Point
• Setting Auto-Conversion Voltage Scale of Current Input Point on the SCX 900
• Naming a Series of Points with/without Conversions
• Enabling and Disabling Points
• Summary of Buttons in Point Windows
www.PDF-Zoo.com
Triggers and Logs
8-2 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-3
Table 8-1 shows the input and output points used in this chapter.
Table 8-1. Input and Output Points
Controller
FLOW BLDG1 ROOM101
OutsideAir CENTRALPLANT
SupplyAir BLDG1 FLOOR1
TCX 850
CX 9000 IOU
SCX 900
Point Point TypeModel
Voltage Input
Thermistor Input
Thermistor Input
StaticPress BLDG1 BASEMENT LCX 800 Voltage Input
PRESSURE BLDG1 FLOOR1 SCX 900 Voltage Input
www.PDF-Zoo.com
Triggers and Logs
8-4 Infinity Controller Programmer’s Guide
Taking Act ion Only When a Point ChangesGOAL: Keep HEAT.NOHEAT inactive and start it only when the outside air temperature is below 50 degrees.
You could have HEAT.NOHEAT running constantly, always checking the temperature and turning off the burner, but you would tie up controller time needlessly if the temperature were in, for instance, the 80s.
Instead, you could leave the program inactive until the point value changes. Using a point like this is called “triggering” a program, and the point is called a “trigger.”
The point value is updated only when the temperature changes by an amount equal to the THRESHOLD attribute setting. (For instance if the THRESHOLD is 2 degrees, then the point VALUE updates only if the temperature changes by at least that amount.) So the program is not triggered every time the temperature changes by a small fraction of an amount, but only when the temperature changes by a significant amount.
The ways you can start the HEAT.NOHEAT program are:
• Run it from the command line or from another program using RUN, OPEN, or START.
• Have it automatically start as soon as you exit the file editor.
• Have it triggered by a point value changing.
• Have it triggered by a system variable changing.
System variables are related to date and time. WEEKDAY, for instance, is a system variable. They are called system variables because the controller system sets their values. You
Some Points TriggerPrograms
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-5
cannot change the WEEKDAY, because its value is related to the date the system stores.
The system variables are:
DAYOFYEARMONTHDAYOFMONTHYEARHOURMINUTESECONDHOD (Hour of Day)TOD (Time of Day)
You can use them to trigger an action when the month changes, the year changes, or the season (using DAYOFYEAR) changes.
Summary
• You can start a program from the command line.
• You can have a program start automatically.
• You can have a program triggered by a point or system variable.
• System variables are date and time values updated by the controller.
Syst em Variables Can Be Triggers
www.PDF-Zoo.com
Triggers and Logs
8-6 Infinity Controller Programmer’s Guide
Sett ing Point TriggersA trigger is a point that starts a program. To set a trigger you alter the point as follows:
1. Select Edit Points from the menu bar.
Press the SHOW LIST key and select a point name from the choice list. Press the EXECUTE key and the Point window appears.
2. Move to and press the DETAILS button.
3. In the Details window, press the TRIGGERS button.
Figure 8-1 shows the Triggers window that appears.
Figure 8-1. Triggers Window for OUTSIDEAIR Point
(If you have not yet saved the point, a popup message box appears stating that the point does not exist and asking if you want to create it. Press the OK button to proceed.)
Triggers Are Points ThatStart Programs
Logon Edit View Connect
ADD
DELETE
EXIT
Triggers CENTRALPLANT OutsideAir
Program Name
Programs to Trigger
HEAT.NOHEAT
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-7
To make OUTSIDEAIR trigger a program you add the program name to the list as follows:
1. To enter the name of the program:
• Type the name in the Program Name text box.
OR
• Press the SHOW LIST key to see a list of names and select one.
Use the up and down arrow keys or the PAGE UP and PAGE DOWN keys to move up and down the list of names to highlight the one you want.
Press the EXECUTE key to put the name in the Program Name text box.
2. Press the ADD button.
The program name appears in the Programs to Trigger window.
Figure 8-2 shows the HEAT.NOHEAT program in the Triggers window.
Press ADD to Add Trigger to List
www.PDF-Zoo.com
Triggers and Logs
8-8 Infinity Controller Programmer’s Guide
Figure 8-2. Triggers Window with Program Added
Instead of pressing ADD, you can press DELETE to delete
the program in the Program Name text box from the list.
Press EXIT to return to the Details window.
You could have OUTSIDEAIR trigger several programs by adding them all to the Programs to Trigger list.
Logon Edit View Connect
ADD
DELETE
EXIT
Triggers CENTRALPLANT OutsideAir
Program Name
Programs to Trigger
HEAT.NOHEAT
Triggers Listed inWindow
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-9
Summary
• A trigger is a point or system variable that starts a program.
• To set point triggers you select Edit Points from the menu bar. After you open the point, go to the Details window and press the TRIGGERS button.
• In the Programs to Trigger window is a list of programs the point triggers.
• You can press the ADD or DELETE button to add or delete a program from the program list.
• You can press EXIT to return to the Details window.
Press TRIGGERS to Open Trigger List
www.PDF-Zoo.com
Triggers and Logs
8-10 Infinity Controller Programmer’s Guide
Triggering a Program by the Day of YearGOAL: To trigger the DAYLIGHT program (see preceding chapter) by the DAYOFYEAR system variable.
So that you don’t have to start the DAYLIGHT program manually, or run it continually, it should run only when the DAYOFYEAR changes. A change in the DAYOFYEAR should trigger the program.
You can make a system variable a trigger, just as you can make a point a trigger. To set up DAYOFYEAR as a trigger:
1. Select Edit System Variable from the Main menu bar.
2. When Open a System Variable appears on the screen, press the SHOW LIST key to see a list of the system variables. Arrow to the variable name and press the EXECUTE key.
3. Press the EXECUTE key to continue.
4. Move to the DETAILS button and press it.
5. Move to the TRIGGERS button and press it.
6. Now type the name of the program in the Program Name text box.
Figure 8-3 shows the program name in the Triggers window.
Triggers Li mit WhenProgram Runs
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-11
Figure 8-3. Triggers Window for DAYOFYEAR
7. Press the ADD button.
8. Press the EXECUTE key or SAVE key to save the triggers and return to the previous window. Or press the EXIT button to return to the previous window.
From now on, whenever the DAYOFYEAR changes the program checks to see if it’s the day to reset the HOUR. If it isn’t, the program stops until DAYOFYEAR changes again.
You can also set a system variable to trigger programs from inside a program file by selecting Tools Edit a System Variable from the File menu bar. You then proceed as detailed in Chapter 5.
Summary
To trigger a program with a system variable, you edit the system variable and add the program name to the Programs to Trigger list.
Logon Edit View Connect
ADD
DELETE
EXIT
Triggers FLOOR1 AHU DAYOFYEAR
Program Name
Programs to Trigger
DAYLIGHT
Set a System Variable from Tools Menu
www.PDF-Zoo.com
Triggers and Logs
8-12 Infinity Controller Programmer’s Guide
Under standing Logs and Arra ysSometimes you may want the controller to update a point every few minutes or every hour, and save the values it has re-corded up to that time.
Logs
Logs are points that automatically update and save the “read-
ings” from the environment.1
You can picture the values of the SUPPLYAIR log in a table.
Table 8-2 shows the SUPPLYAIR log positions labeled with index numbers.
Table 8-2. SUPPLYAIR Log Values
In a log, you can access the last (most recent) value recorded in the first position:
PRINT SupplyAir[1]
1. Logs can be input, output, numeric, string, or datetime points. The examplehere illustrates an input. More about other types of logs appears in futurechapters.
Logs AutomaticallyUpdate
Index Value
1 234
72737574
5 736 727 718 73
Last Value Recorded
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-13
The previous statement prints 72, the value held in the first position in the log.
The second to the last value recorded is in the second position:
PRINT SupplyAir[2]
The above statement prints 73.
The third to the last value is in the third position, the fourth in the fourth position, and so on.
Arra ys
Arrays, like logs, save more than one value, but, unlike logs, they do not automatically update. Your program must update an array.
Table 8-3 shows the AVSUPPLYAIR array positions labeled with index numbers.
Table 8-3. AVSUPPLYAIR Arr ay Values
Arrays Update When Programs Set Them
Index Value
1 234
72.573.171.278.2
5 72.16 76.57 77.58 74.2 Last Value
in Array, but NotNecessarily LastOne Recorded
www.PDF-Zoo.com
Triggers and Logs
8-14 Infinity Controller Programmer’s Guide
Since the array does not automatically update, you may have a program calculate a total and place it in an array as follows:
SET AVSupplyAir[3] TO AVERAGE(SupplyAir)1
This program statement sets the third position in the AVSUPPLYAIR array to the average supply air temperature. You write similar statements to set other values in the array. You can also use some advanced programming techniques to change the index number (see later chapters).
Later, you can access the values recorded as follows:
PRINT AVSupplyAir[2]
This statement prints the second value in the array, 73.1
You can access the last value in an eight-item array as follows:
PRINT AVSupplyAir[8]
This statement prints the last value in the array, 74.2.
Remember, you can set an array from a program, but you can-not set a log.
A point can be a log or an array; it cannot be both.
1. We present the AVERAGE keyword later in this chapter.
You Must Set ArrayValues in a Program
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-15
Summary
• Logs are points that automatically update and save the “readings” from the environment.
• Arrays are points that contain a series of values set by programs.
• Each entry in a log or array has a numbered position. The number of the entry is called the “index number.”
• You access entries in a log or array by the name and index number; you access the third entry in a SUPPLYAIR log as follows:
PRINT SupplyAir[3]
Get Log Entries with Index Numbers
www.PDF-Zoo.com
Triggers and Logs
8-16 Infinity Controller Programmer’s Guide
Sett ing Up Logs and ArraysTo make a point log values, do the following:
1. Select Edit Points from the Main menu bar.
2. Enter a new point name or choose a name from the choice list and press the EXECUTE key.
3. Enter all point attributes or press the NEXT ATTRIBUTE key to move through them to the DETAILS button.
4. Press the DETAILS button.
5. Enter all the attributes or press the NEXT ATTRIBUTE key to move through them to the LOGS button.
Press the LOGS button to open the Logs window.
Figure 8-4 shows the Logs window.
Figure 8-4. Logs Window for Automatic Log
Logs Window
View Edit Connect Logout
Number of Entries(X) LogInstantaneous( ) LogAverage( ) LogMinimum( ) LogMaximum
Entry Type
(X) Automatic Log( ) Manual Array
SAVE
CANCEL
Hours 0
Days 0
Interval
Log Type
Point – FLOOR1 AHU SupplyAir
Minutes 15
Seconds 0
LOGS – FLOOR1 AHU SupplyAir
95
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-17
You set the attributes as follows:
1. Number of Entries (SIZE)—Put the number of entries in the log, up to 32,767. For instance, if you want the supply air temperature entry updated every hour, you can place the values in a log with 23 items.
2. Log Type —Select Automatic Log or Manual Array . The controller updates the log automatically and your program updates the array. If you select Manual Array , the rest of the attributes disappear from the screen, since they apply only to automatic logs.
3. Entry Type (LOGTYPE)—Select one of the four types of values the controller can enter into the log or array:
LOGINSTANTANEOUS—Select to have the log take in the exact value for the scan that occurs when the interval of time has elapsed.
LOGAVERAGE—Select to have the log take in the value at every scan in the interval and put the average value over that interval into the log.
LOGMINIMUM—Select to have the log take in the value at every scan in the interval and put the minimum value of that interval into the log.
LOGMAXIMUM—Select to have the log take in the value at every scan in the interval and put the maximum value of that interval into the log.
The next section suggests when you might select each of these entry types.
4. Interval (LOGINTERVAL)—Enter the amount of time you want to elapse between the logging of each value. Break down the total length of the interval into:
• Days—Up to 365.
Four Log Entry Types
www.PDF-Zoo.com
Triggers and Logs
8-18 Infinity Controller Programmer’s Guide
• Hours—Up to 23.
• Minutes—Up to 59.
• Seconds—Up to 59.
The length of the interval should be equal to the total—days + hours + minutes + seconds. The minimum length of the interval is 1 second.
The next section explains how you set the interval.
5. Press the EXIT button repeatedly in each window until you arrive at the Point window; then press EXIT to save the point as a log. Or press the CANCEL button to erase the log settings. You can also press the EXECUTE or SAVE key to save the log.
Figure 8-5 shows how the Logs window appears for a manual array.
Figure 8-5. The Logs Window fo r Manual Array
Logs Window for Arrays
Number of Entries
( ) Automatic Log(X) Manual Array
EXIT
CANCEL
Log Type
Point – FLOOR1 AHU AVG.SAT
LOGS – FLOOR1 AHU AVG.SAT
7
View Edit Connect Logout
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-19
Summary
• You can create logs and arrays in the Logs window.
• In a log, the last (most recent) value entered is always in the first position: SupplyAir[1]
• In an array, you can enter a value in any position or access the value entered in that position with its index number: SupplyAir[24]
• The number of entries is the SIZE attribute—you enter the number of items in the array or log.
• Select Automatic Log or Manual Array for the log type.
• Select LOGINSTANTANEOUS, LOGAVERAGE, LOGMINIMUM, or LOGMAXIMUM as the way the log enters the value in relation to the scans for that interval.
• Enter the interval in days, hours, minutes, and seconds.
• You press the SAVE button to return to the previous window. Keep pressing SAVE until you are at the Point window where you press SAVE to save the point as a log. Or you can press the EXECUTE or SAVE key from the Logs window and save the log information.
• You press the CANCEL button to erase the log information.
Summary of Logs and Arrays
www.PDF-Zoo.com
Triggers and Logs
8-20 Infinity Controller Programmer’s Guide
Sett ing t he Entry Type and IntervalThe entry type for a log is one of these:
• LogInstantaneous
• LogAverage
• LogMinimum
• LogMaximum
Under what circumstances would you select each of these types? The following are some examples of when you might select each.
LogIns tantan eous
You select LOGINSTANTANEOUS when you must have the value of the point at the moment of the scan. A circumstance you might want this under is logging the exact amount of en-ergy consumption for the day. In that situation you would not be interested in the average, minimum, or maximum con-sumption. Instead you want to know the precise value at the beginning of the occupancy.
You might want to log the startup time on a once a day basis, so the interval would be 1 day.
LogAvera ge
You might select LOGAVERAGE for the entry type when you are logging information on general conditions. For exam-ple, you might record the average hourly outside air temperature to compare it to the hourly energy consumption.
To set up this log, you would make the interval 1 hour to record the average value for the hour.
Log Exact Time Buildin gStarts Up
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-21
LogMinimu m
You might select LOGMINIMUM if, for instance, you wanted to make sure that the liquid level in a tank always remained above a certain point. You would log the daily minimum values of that level so that you could respond to them.
Again, the interval for this log would be 1 day.
LogMaximum
You might select LOGMAXIMUM to monitor the top value of a point, such as the peak electrical demand. You could log electrical demand over a 30 minute period, recording the maximum value of each interval.
The interval for the electrical demand log would be 30 minutes. You could instead record the peak for the day or the week by setting the interval to 1 day or 7 days, respectively.
Summary
• You may want to select each of the entry types for logs in different circumstances.
• You base the length of the log interval on the kind of information you need.
Log the Minimum Liqu id Level in a Tank
Log the Maximum Power Demand
www.PDF-Zoo.com
Triggers and Logs
8-22 Infinity Controller Programmer’s Guide
Finding the Sum of Logged ValuesGOAL: To total the logged values of kilowatt usage for the month and print a message telling the amount.
You can add up all the values in a log using SUM. SUM totals logs, arrays, and lists. The following totals a log called KWH.USAGE:
SUM(KWH.USAGE)
You use only the name of the log to indicate that you want SUM to add up the entire log.
SUM adds up the values in parentheses in the following:
SUM(345, 267, KWH.USAGE[2], KWH)
You might also find SUM useful in a calculation that does not involve points at all:
SUM(234, 356, 899, 200)
Or you may, for instance, need to add up a series of numeric point values.
To put SUM into a program, you could use the result in a program statement, like this:
IF SUM(KWH.USAGE) IS ABOVE USAGE.SP THEN...
You could also set a numeric point to the sum for later use in a report:
SET TOTAL TO SUM(KWH.USAGE)
Figure 8-6 shows the program.
SUM Totals Log Values
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-23
Figure 8-6. TOTAL.USAGE Program—FallThru
(The vertical bar followed by an asterisk (|*) in the TOTAL.USAGE program tells PRINT to print any number of digits that the value contains.)
Summary
• SUM adds up the values in a log, list, or array.
• SUM automatically adds up all the values in a log or array when you give the point name with no index number.
File Edit Search Check Tools
TOTAL = SUM(KWH.USAGE)
CENTRALPLANT TOTAL.USAGE
PRINT "TOTAL KWH USAGE IS |*", TOTAL
www.PDF-Zoo.com
Triggers and Logs
8-24 Infinity Controller Programmer’s Guide
Finding t he Average of Logged Val uesGOAL: To find the average outside air temperature for each week. Store the values in an array log for later use in a report.
Assume the OUTSIDEAIR point logs the temperature every 15 minutes for a week. It would take some work to find the average using a standard approach of adding and dividing, because the log would contain 672 values.
To average the log in one quick statement, you use AVERAGE. AVERAGE works like this:
AVERAGE (OutsideAir)
When you put OUTSIDEAIR in parentheses after AVERAGE, the keyword assumes that the point is a log or array. It finds the average of all the values logged.
You usually put AVERAGE into a statement that uses the value it produces.
IF AVERAGE(OutsideAir) > 75 THEN STOP WARMUP
To store the average in a numeric point for a report at the end of the week, use this statement:
SET OATAVG[2] TO AVERAGE(OutsideAir)
(Details on creating numeric points are included in Chapter 4. Using numeric points is covered in a later chapter.)
Figure 8-7 shows the program.
AVERAGE Av erages LogValues
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-25
Figure 8-7. WEEKLY.OAT Progr am—FallThru
So when the day of week is Saturday, the program:
• Calculates the average of the OUTSIDEAIR log values.
• Runs a report program.
You can also find the average of a list of values using AVERAGE, just as you found the sum of a list.
Summary
• AVERAGE finds the average of the values in a log, list, or array.
• AVERAGE automatically averages all the values in a log or array when you give the point name with no index number.
File Edit Search Check Tools
FLOOR1 AHU WEEKLY.OAT
RUN OAT.REPTSET OATAVG TO AVERAGE(OutsideAir)
ENDIF
IF WEEKDAY = SATURDAY and TOD > 11:55 pm THEN
’Triggered by WEEKDAY
AVERAGE Au tomatically Uses Entir e Log
www.PDF-Zoo.com
Triggers and Logs
8-26 Infinity Controller Programmer’s Guide
Finding the Minimum or Maximum L ogged ValueGOAL: To find the adjusted average outside air temperatures for the week (minus the lowest and highest values before averaging).
Assume again that OUTSIDEAIR input point logs the outside air temperature every 15 minutes for a week. It would be outrageously time consuming to find the lowest or highest OAT using a standard approach of TRUE-FALSE statements comparing each value to the next.
Finding the Mini mum
To find the lowest value logged in one quick statement, you use MINIMUM. MINIMUM works like this:
MINOAT = MINIMUM (OutsideAir)
When you put OUTSIDEAIR in parentheses after MINIMUM, the keyword assumes that point is a log or array. It finds the lowest value logged.
Before you can use this statement, you must create a numeric point called MINOAT to put the result of MINIMUM into.
Finding the Maximum
To find the highest value logged in one quick statement, you use MAXIMUM. MAXIMUM works like this:
MAXOAT = MAXIMUM (OutsideAir)
When you put OUTSIDEAIR in parentheses after MAXIMUM, the keyword assumes that point is a log or array. It finds the highest value logged.
MINIMUM Finds LowestValue in Log
MAXIMUM Finds HighestValue in Log
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-27
Before you can use this statement, you must create a numeric point called MAXOAT to put the result of the function into.
Finding the Total
To add up the values in a log, then subtract the minimum and maximum values, you proceed as follows:
1. Total the log values with SUM.
2. Subtract the minimum value found with MINIMUM.
3. Subtract the maximum value found with MAXIMUM.
4. Divide the total by the number of items in the array (SIZE attribute) minus 2 (the minimum and maximum that have been removed).
5. Put the results in a numeric point called ADJUSTED.AVG.
Use SUM, MINIMUM, and MAXIMUM
www.PDF-Zoo.com
Triggers and Logs
8-28 Infinity Controller Programmer’s Guide
Figure 8-8 shows the program.
Figure 8-8. MINMAX.MINUS Program—FallThru
You can also find the minimum of the maximum of a series of values in a list. You use MINIMUM and MAXIMUM this way to simplify the WATERTEMP program from Chapter 7.
Remember that the hot water setpoint has to be set to between 100 and 180 degrees, depending on the LOWSPACEFCTR. If 180 minus the LOWSPACEFCTR gives a value below 100 degrees, the hot water setpoint is set to 100 degrees, not lower.
Figure 8-9 shows the WATERTEMP program rewritten to set the hot water to the correct setpoint in one statement.
Figure 8-9. WATERTEMP Program—Looping
File Edit Search Check Tools
IF WEEKDAY IS SATURDAY AND TOD IS 1:00 pm THEN
CENTRALPLANT MINMAX.MINUS
SET TOTAL TO SUM(OutsideAir)
ADJUSTED.AVG = (TOTAL – (MINOAT + MAXOAT)) / (OutsideAir SIZE – 2)
ENDIF
SET MINOAT TO MINIMUM(OutsideAir)
SET MAXOAT TO MAXIMUM(OutsideAir)
’Triggered by WEEKDAY
File Edit Search Check Tools
FLOOR1 AHU WATERTEMP
SET HWTemp.Setpt TO MINIMUM(MAX((180 – LowSpaceFctr),100),180)
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-29
In this program, MAXIMUM (shortened to MAX) finds the maximum value of the list in parentheses after it—either of these:
• 180 – LowSpaceFctr
• 100
Then MINIMUM (cannot be shortened) then finds the minimum value inside the next layer of parentheses—either of these:
• The result of MAXIMUM
• 180
The setpoint is set to the final result of first the MAXIMUM, then the MINIMUM.
Summary
• The MAXIMUM or MINIMUM keyword finds the maximum or minimum value in a log, list, or array.
• The MAXIMUM and MINIMUM keywords automatically act on all the values in a log or array when you give no index number.
Take Action on Entire Array, Log, or List
www.PDF-Zoo.com
Triggers and Logs
8-30 Infinity Controller Programmer’s Guide
Converting a Flow Sensor Input P ointGOAL: To write a conversion for the FLOW air flow sensor input (Input 8) on a TCX 850 that automatically converts the reading of the input into flow in cubic feet per minute.
Although you set the electrical type to Voltage when defin-ing the point, it actually reads inches of water.
How do you get from inches of water to cubic feet per minute? Because the conversion is not linear, you cannot use the auto-conversion box. Instead, you must develop a formula and en-ter the formula in the Conversion text box.
Develop ing th e Conv ersio n
The words and symbols you use to form the conversion are the same ones you program with—Andover Controls Plain English keywords.
You need to use the inches of water to cubic feet per minute relationship and the K factor for the VAV box to convert to cubic feet. Since the K factor in this case is 425, the following expression converts the units:
flow = 425 * SQRT(FLOW ELECVALUE)
As shown in Figure 8-10, “flow =” is not required in the formula.
This formula uses the * for TIMES.
The formula also uses both the ELECVALUE attribute of the point. Remember the ELECVALUE is the value in electrical units, in this case the voltage read by the input.
SQRT finds the square root of the value in parentheses after it, in this case the ELECVALUE of FLOW.
Convert Inches of Waterto Cubic Feet per Minute
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-31
Figure 8-10. FLOW Poin t Conversion in the Point Details Window
SQRT is a mathematical keyword, like SUM, AVERAGE, MINIMUM, and MAXIMUM. You may need other mathe-matical keywords to write other conversions. (See Chapter 18 for more information.)
You can use similar conversions on output points.
Entering th e Conv ersio n
Once you have developed the conversion, open the Point window, name the point, and proceed as follows:
1. Press the DETAILS button.
2. Enter a description and format if you want.
Description
Display Format
Exported
Conversion
#.##
X
Details – FLOOR1 AHU Flow
TRIGGERS
DELETE
LOGS
SAVE
CANCEL
Volts
Top
Bottom
wg
Threshold
Auto-Conversion
Flow AirFlow Sensor
.02
0
0 0
View Edit Connect Logout
425 * SQRT (FLOW ELECVALUE)
0
Mathematical K eywo rds
www.PDF-Zoo.com
Triggers and Logs
8-32 Infinity Controller Programmer’s Guide
3. Enter the conversion in the Conversion text box. The text box scrolls so you can enter up to 132 characters and symbols in the conversion. The conversion is as follows:
425 * SQRT(FLOW ELECVALUE)
The controller automatically sets the point’s value to the result of the expression you enter.
You can also leave out the point name before ELECVALUE, because the controller assumes that the ELECVALUE belongs to the point you are converting:
425 * SQRT(ELECVALUE)
If, however, you name another point before ELECVALUE, that point is pulled into the equation rather than the current point’s attribute.
If you do not enter the conversion in correct Andover Controls Plain English, the controller does not let you move to the next text box. Error messages like those you might see in a file appear along the status bar.
4. After you enter the complete conversion, press the NEXT ATTRIBUTE key and a popup window appears.
Figure 8-11 shows the message in the popup window. It tells you the point does not exist, because you haven’t saved it yet. You either press OK to keep the conversion for the point or CANCEL to cancel the conversion.
Figure 8-11. Conv ersion Popup Message Box
Popup Messag e Window
Error
Point does not exist. Create it?
OK CANCEL
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-33
5. Move to and press the SAVE button to return to the Point window.
6. Move to the SAVE button and press it to save the point. Or press the EXECUTE key or SAVE key to save the point and close the window.
Summary
• To convert to engineering units that do not have a linear relationship to the electrical units of a point, you enter a conversion in the Conversion text box.
• You use Andover Controls Plain English language keywords and symbols to create a conversion. You usually employ a mathematical keyword to form a nonlinear conversion.
• SQRT is a mathematical keyword.
• ELECVALUE when given after a point name refers to the point’s ELECVALUE attribute, the electrical value read by the input.
• When you press NEXT ATTRIBUTE from the Conversion text box, a popup message box appears asking you if you want to create the point with this conversion.
Nonlin ear Conversion s Go in Conversion Box
www.PDF-Zoo.com
Triggers and Logs
8-34 Infinity Controller Programmer’s Guide
Converting a Voltage Producing Transducer Input PointGOAL: To write a conversion for the STATICPRESS volt-age producing transducer input on an LCX 800 that automati-cally converts the reading based on the reference voltage and impedance of the transducer. The voltage the controller reads is not the true value due to the voltage supplied by the LCX 800.
Given the following information, you can form an equation:
• VOLT is the amount read by a Voltage input.
• The RES is the output impedance of the transducer in KΩs.
• REF.VOLT is the reference voltage of the controller.
You can formulate this equation to correct the distortion in the value read:
(VOLT – (REF.VOLT * (RES/(10 + RES))))/(10/(10+RES))
The reference voltage of an LCX 800 or a TCX 850 is 5.120 V.
The SCX 900 and LCX 810 do not require a conversion for high impedance inputs because you set the input reference re-sistor switch to OUT for such inputs when you install the controller. (See the installation guide for each controller for details.)
You enter the formula in the Conversion text box.
Convert Input Voltage toCorrect Value
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-35
Summary
• To convert to a transducer input voltage to the corrected voltage, you enter a conversion in the Conversion text box.
• LCX 800s and TCX 850s both have has a reference voltage of 5.120 V.
• SCX 900s and LCX 810s both have input reference resistor switches that must be set to OUT for high impedance inputs. No conversion is required.
Use Reference Voltage of Cont ro ller
www.PDF-Zoo.com
Triggers and Logs
8-36 Infinity Controller Programmer’s Guide
Sett ing Aut o-Conver sion Voltage Scale of Current Input Point on the SCX 900GOAL: To set up the auto-conversion for the PRESSURE current-producing pressure sensor on a SCX 900.
You may remember setting up a current input as a Voltage type earlier in this manual. The controller reads the voltage of a cur-rent input that results from the resistor you wire across the input.
The best way to convert that voltage to, for instance, the psi units for the pressure gauge, is to insert a conversion for the PRESSURE input on a SCX 900 into the Auto-Conversion box for the point.
Given the following information, you can select the values to put into the auto-conversion:
• The maximum current produced by the input.
• The amount of resistance you wire across the current input in KΩs (for example, 0.475 KΩ for a 475 Ω resistor).
Figure 8-12 shows a current sensor wired to an input point.
Figure 8-12. Wiring Diagram for Current Input
Take the following steps:
1. Calculate the voltage from an input with a 475 Ω resistor:
Convert Voltage toPressur e Units
RL= 475 Ω
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-37
Voltage = Current (mA) * Resistance (Ω)/1000
So for 4 mA (bottom of scale) and a 475 Ω resistor, the following is the result:
4 mA * 475 Ω/1000 = 1.9 V
For 20 mA (top of scale) and a 475 Ω resistor, the following is the result:
20 mA * 475 Ω/1000 = 9.5 V
Figure 8-13 shows where you place the top and bottom of scale in the Auto-Conversion box.
Figure 8-13. Auto-Conversion Box in Point Window
2. After you have calculated the correct voltage for the electrical value (ELECVALUE), you then enter the top and bottom of scale in psi units.
You are now ready to use the input.
Summary
• You calculate the voltage from a current input (on a SCX 900 or LCX 810) as follows:
Voltage = Current (mA) * Resistance (Ω)/1000
• The resistance for a current input is usually 475 Ω on a SCX 900 or LCX 810.
Volts
Top
Bottom
psi
20 9.5
0 1.9
Auto-Conversion
Calculat e wit h Current, Resistan ce
www.PDF-Zoo.com
Triggers and Logs
8-38 Infinity Controller Programmer’s Guide
Naming a Series of Points with/without ConversionsOnce you have named the first point with a conversion,to name several more points, you can alter the first point’ssettings and save it under another name with SAVE AS. Keeping the conversion, however, involves responding to controller questions.
Saving Conve rted Poin ts
After you have saved the FLOW point by pressing the SAVE AS button and typing FLOW in the Name text box of the Open a Point window, when you attempt to create several additional points using SAVE AS, each with or without a con-version, notice that the SAVE AS procedure changes:
1. When you press SAVE AS and the new Open a Point window appears on top of the Point window, type the name of the new point in the Name text box and press the EXECUTE key.
After you type the name, if your new point has a conversion, a new window appears on top of the Point window.
Figure 8-14 shows the window, called the Conversion Check window. It displays a message.
Create a Point, Save Itund er Another Name
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-39
Figure 8-14. Conversion Check Window
2. Press the YES button to check the conversion for the new point just as you would “check” a program.
Press NO to discard the conversion.
Press CANCEL to discard the new point.
3. If you pressed YES, enter the conversion for the new point in the Conversion text box.
4. Press the SAVE button to save the point. Or press the EXECUTE key or the SAVE key. The window automatically closes.
CONVERSION CHECK
The conversion has not been checked. Select: YES to edit and check the conversion. NO to discard the conversion.
CANCEL YES NO
View Edit Connect Logout
A Check Conversio n Message Appears
www.PDF-Zoo.com
Triggers and Logs
8-40 Infinity Controller Programmer’s Guide
Enabling and Disabling PointsGOAL: To take the BURNER point out of program control, so the heater functions while you alter the point. Later, after you alter the point, to let the program use it again.
To take the BURNER point out of program control, you enter the following either in the Command window or inside a program:
DISABLE THE BURNER
When you have disabled the point, the burner itself still runs (if it has been running), so you have not stopped the equipment, as you would with the STOP keyword. Think of disabling the point as disconnecting it from the controller.
To later allow the program to control the burner, you use the ENABLE keyword:
ENABLE THE BURNER
You can disable or enable more than one point as follows:
DISABLE THE BURNER, HWPump1, AND HWPump2
ENABLE THE BURNER, HWPump1, AND HWPump2
ENABLED and DISABLED set the STATE of a point.
(You can also stop points from displaying on the LCD keypad, but not the same way. See Chapter 9 for details.)
Disabled Point Runs byManual Control Only
www.PDF-Zoo.com
Triggers and Logs
Infinity Controller Programmer’s Guide 8-41
Summary
• Disabling a point is not the same as stopping it.
• A disabled point is disconnected from the controller.
• Enabling a point is not the same as starting it or turning it ON.
• An enabled point is under the control of the controller.
• You can use ENABLE or DISABLE on the command line or inside a program.
Enabled Poin ts Can Be Set by the Contr oller
www.PDF-Zoo.com
Triggers and Logs
8-42 Infinity Controller Programmer’s Guide
Summary of Buttons in Point WindowsThese buttons appear in the Point and Point Details windows:
• SAVE—In the first point window, saves the point under the name you originally gave it and closes the Pointwindow. Press the QUICK BUTTON key and then S.
• SAVE—In the Details and Logs windows, returns to the previous window.
• SAVE AS—Saves the information to another point if you enter a new name in the Open a Point window and leaves that point displayed on the screen. Press the QUICK BUTTON key and then A.
• CANCEL—Cancels the point information and exits the window. Press the QUICK BUTTON key and then C.
• DETAILS—Opens the Details window. Press the QUICK BUTTON key and then D.
• EXIT—Returns to the previous window. Press QUICK BUTTON key and then X.
• LOGS—Opens the Logs window. Press the QUICK BUTTON key and then L.
• TRIGGERS—Opens the Triggers window. Press the QUICK BUTTON key and then T.
• DELETE—Removes the point from the controller. Press the QUICK BUTTON key and then E.
Butto ns Take Action
www.PDF-Zoo.com
Chapter 9
Altering andFurther Developing
Programs in Y our SetThis chapter includes sample programs and presents these programming concepts:
• Cutting, Copying, and Moving Text in a File
• Finding and Replacing Text in a File
• Finding and Replacing Text with Regular Expressions
• Opening a Command Window from Inside a File
• Looking at, Creating, and Altering Points from Insidea Program File
• Looking at Messages from Inside a Program File
• Looking at a List of Files from Inside a Program File
• Copying Programs to Other Controllers
• Using Points on Another Controller
• Preventing Particular Point Values from Displaying on a Keypad LCD
• Finding Errors Resulting from Deleting an Item
• Enabling and Disabling Programs
• Understanding the Scanning Process
• Altering the Firing Order
• Helpful Hints for the Programming Set
www.PDF-Zoo.com
Developing Programs
9-2 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-3
Table 9-1 shows the input and output points used in this chap-ter.
Table 9-1. Input and Output Points
Controller
Damper BLDG1 ROOM 101
Reheat BLDG1 ROOM 101
TCX 850
TCX 850
Point Point Type Model
Current Output
Current Output
Fan1 CENTRALPLANT TOWER
Fan2 CENTRALPLANT TOWER
SCX 900
SCX 900
Form C Output
Form C Output
Fan3 CENTRALPLANT TOWER SCX 900 Form C Output
CW1ISOValve CENTRALPLANT CX 9000 Current Output
CHWP1Valve CENTRALPLANT CX 9000 Current Output
www.PDF-Zoo.com
Developing Programs
9-4 Infinity Controller Programmer’s Guide
Cutt ing, Copying, and Moving Text in a FileAfter you have typed your program, you may want to cut some text and move it to (paste it into) a different location.
Selecti ng the Text
First, you select the text you want to cut (or copy):
1. Move the cursor to the beginning of the text you want to cut (or copy) and press the CANCEL WINDOW key.
The cursor goes to the File menu bar.
2. Select Edit Select . The cursor immediately returns to the file.
3. Now move the cursor to the end of the text you want to cut (or copy) and press the CANCEL WINDOW key.
You have now selected all the text between the original cursor location and the current cursor location.
Cutti ng an d Moving or Copy ing T ext
Now cut and paste (or copy and paste) the text:
1. To move the cursor to the menu bar, press the CANCEL WINDOW key.
2. Select Edit Cut or Edit Copy to cut or copy the text. The cursor returns to the file. If you selected Edit Cut , the text you selected is removed from the screen.
3. Move the cursor to the beginning of the location you want to move the text to and press the CANCEL WINDOW key. (The location you want to move the text to can be in
Edit Select, Cu t, Copy,and Paste
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-5
another file; open that file as you normally would and position the cursor to paste text there.)
4. Select Edit Paste . The text appears in the new location.
5. Repeat steps 2 and 3 to paste the same text in another location. You can continue to paste the same piece of text until you use Edit Select and Edit Cut or Edit Copy on another piece of text.
If you select Edit Cut or Edit Copy without first selecting text, a message appears on the screen.
Figure 9-1 shows the message.
Figure 9-1. Paste Error Message
Press the OK button to acknowledge the message.
Pasting and Creating Long Statem ents
If you copy 100 characters and paste them in the middle of a statement of 50 characters, the result is a statement longer than 132 characters. The controller responds with a message.
Figure 9-2 shows the message that appears.
Figure 9-2. Cauti on fo r Past ing Lo ng Statements
Af ter You Select, Cut or Copy before You Paste
Paste Error
You did not select any text to Cut.
OK
Caution
Search Replace inserted a continuation character, ~,
OK
which may produce errors in your program.
www.PDF-Zoo.com
Developing Programs
9-6 Infinity Controller Programmer’s Guide
When you see this message, Infinity has placed a continuation character at the end of the first physical line of the new statement. However, Infinity does not always put the tilde (~) after a complete word. The physical line may end like this:
te~
It should end like this:
test~
You now must find the tilde at the end of the line and if it does not fall after a complete word, alter the text so it does. Be sure no characters are to the right of the tilde.
If you form a long statement at any time, such as by searching and replacing, the same caution occurs.
Pasting and Reaching En d of Fi le
If you paste 25 physical lines into a 375 line file, Infinity enters as many physical lines as it can up to 400 total for the entire file. Any lines after 400 are cut. (Watch the line number in the lower right corner of the file window.)
Figure 9-3 shows the paste error message that appears.
Figure 9-3. Paste Error End-of-File Message
If this message appears, you can paste the cut or copied text into another file to save all of it. However, when you do, the current file closes automatically, because you can have only one file open at a time.
Infin ity Adds a Tild e toLong Lines
File Can Contain Up to400 Lines
Paste Error
You have reached the end of file.
OK
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-7
Selecti ng the Text with MARK BLOCKInstead of Ed it Sele ct
You can also select text to copy by marking it with the MARK BLOCK key instead of the Edit Select menu selection, as follows:
1. Move the cursor to the beginning of the text you want to cut (or copy) and press the MARK BLOCK key.
2. Move the cursor to the end of the text you want to cut (or copy) and press the CANCEL WINDOW key.
The cursor goes to the File menu bar.
3. You have now selected all the text between the original cursor location and the current cursor location. To copy the text select Edit Copy .
4. To paste the text, position the cursor at the beginning of where you want to paste and press CANCEL WINDOW.
5. Select Edit Paste to paste the text.
Erasing T ext in a File
To erase all text from the file, first, you select the text you want to erase. Then to erase the text you just selected, proceed as follows:
1. To move the cursor to the menu bar, press the CANCEL WINDOW key.
2. Select Edit Clear .
The selected text is now gone. It is not even available to paste.
If you select Edit Paste now, you paste the last piece of text you cut or copied with Edit Cut or Edit Copy .
MARK BL OCK Key Marks to C ut or Copy
Erase Text w ith Edit Clear
www.PDF-Zoo.com
Developing Programs
9-8 Infinity Controller Programmer’s Guide
Finding and Replacing Text in a FileAfter you have typed your program, you may want to search for a word or phrase and replace it with a different one.
Suppose you want to search for DAMPERS and replace it with DAMPER:
1. Bring the cursor to the location in the file you want to start searching from.
2. Press the CANCEL WINDOW key to bring the cursor to the File menu bar.
3. Select Search Replace . The Search:Replace window appears.
Figure 9-4 shows the window.
Figure 9-4. Search:Replace Window
4. Enter up to 32 characters in the Search For text box. Move from the Search For to the Replace With text
Search and Replace
FLOOR1 AHU MORN.WARMUP
Search For
Replace With
(X) Ignore Case
DAMPERS
Damper
Search:Replace
OK
CANCEL
(X) Prompt/Replace(X) Entire File( ) Regular Expression Search
File Edit Search Check Tools
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-9
box using the NEXT ATTRIBUTE key. Again, enter up to 32 characters.
5. Select Ignore Case to find not only “DAMPERS”, but “Dampers” and “dampers” as well.
(Skip Regular Expression Search for now.)
6. To search through the entire file, select Entire File . Otherwise, you find only one occurrence of the text.
(Remember, the search starts where you put the cursor.)
7. To get a prompt (question) to appear on the screen that stops at each instance and lets you decide whether you want to replace it, select Prompt/Replace .
8. Press the OK button to begin the search. The search starts where the cursor currently is and stops at the end of the file. When Infinity finds the first instance of the text, it puts the cursor on that text.
9. If you did not select Prompt/Replace , Infinity finds the text and replaces it every time it occurs in the file. The cursor lands on the last instance of the text.
10. If you selected Prompt/Replace , when the prompt appears, you can do one of these:
• To replace the text and then find the next occurrence, press the space bar.
• To skip that occurrence and search for the next, press the EXECUTE key. The cursor lands on the next occurrence.
• To cancel the entire search, press the CANCEL WINDOW key (referred to as F4 on the screen).
Repeat step 10 until you have searched and replaced all instances.
Search f or Text wit h Upper- and Lowercase
www.PDF-Zoo.com
Developing Programs
9-10 Infinity Controller Programmer’s Guide
11. If Infinity cannot find the text, Text not found appears in the message bar.
If, when you replace text, a line exceeds 132 characters or the file grows beyond 400 lines, the same messages appear as when you paste text.
If you do not select the Prompt/Replace option, and you search for and replace long words or phrases that occur frequently, the search may take some time.
As shown in Figure 9-5, a message displays during the search.
Figure 9-5. Long Search Message
Moving the Cursor to a Partic ular W ord
Suppose you want to change a particular statement. To bring the cursor to the statement, you can search for a particular keyword in the file. Finding the word brings the cursor to the line it is on. You can then edit the statement as required.
1. Be sure the cursor is at the beginning of the file or at the point you want to begin searching from.
2. Press the CANCEL WINDOW key and select Search Find .
Figure 9-6 shows the window that appears.
Search Replace Mode is Active.
Use Find to Move theCursor to Text
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-11
Figure 9-6. Search:Find Windo w
3. The text you last entered is still in the Search For text box. To change the text, you need not erase it. With the cursor on the leftmost character in the text box, as soon as you type a character, the old text erases.
To keep the old text and merely alter it, use the arrow keys to position the cursor, then press BACKSPACE or DELETE TEXT to erase single characters.
4. Press the OK button to start the search.
The search window disappears and the cursor lands on the first line that contains the text.
File Edit Search Check Tools
FLOOR1 AHU MORN.WARMUP
Search For CLOSE
Search:Find
OK
CANCEL
(X) Ignore Case( ) Regular Expression Search
The Cursor Lands on t he Text It Finds
www.PDF-Zoo.com
Developing Programs
9-12 Infinity Controller Programmer’s Guide
Finding Next Occurrenc e
1. To stop on each occurrence of a piece of text, you press the CANCEL WINDOW key and select Search Find Next .
Figure 9-7 shows the Search:Find Next window that appears.
2. Press the OK button and the cursor lands on the first occurrence of the piece of text.
3. Press the EXECUTE key to move to the next occurrence.
4. Repeat step 3 until you’ve reached the particular occurrence you are looking for.
Figure 9-7. Search:Find Next Window
Search and Find Next
File Edit Search Check Tools
FLOOR1 AHU MORN.WARMUP
Search For DAMPER
Search:Find Next
OK
CANCEL
(X) Ignore Case( ) Regular Expression Search
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-13
Summary
• You can use the Search Replace , Search Find , and Search Find Next selections from the File menu bar to search for a particular piece of text in a file.
• You always move the cursor to where you want the search to begin. The search occurs from the cursor location to the end of file.
• You can automatically replace text with the Search Replace selection.
• With Search Replace you can automatically find text disregarding capital letters by selecting Ignore Case .
• With Search Replace you can automatically change only select instances of the text by selecting Prompt/Replace .
• With Search Replace , you can press the CANCEL WINDOW key to stop searching in the middle of the search.
• With Search Find Next you can press the EXECUTE key repeatedly to move to the next occurrence of that text.
Use Search Menu to Find Text
www.PDF-Zoo.com
Developing Programs
9-14 Infinity Controller Programmer’s Guide
Finding and Replaci ng Text with Regular Expr essionsAfter you have typed your program, you may want to search for words or phrases that contain some of the same characters. You can then replace the entire word with a different one.
Finding Text That Contain sSome of the Same Characters
Suppose you want to go through the file and search for a series of thermistors you have removed and replace their names with the name of the new input point.
You can search for SPACE1TEMP, SPACE2TEMP, SPACE3TEMP, and so on by searching for a single digit in between SPACE and TEMP as follows:
1. Be sure the cursor is at the top of the file. The controller searches from the top of the file to the end and does not start over unless you move the cursor back to the top.
2. Press the CANCEL WINDOW key and select Search Find , Search Find Next , or Search Replace .
3. Press the NEXT ATTRIBUTE key or arrow to move to Regular Expression Search and press the space bar.
4. Press the PREVIOUS ATTRIBUTE key to return to the Search For text box, and place a period (.) between SPACE and TEMP, as follows:
SPACE.TEMP
The period means “any single letter, number, or symbol.”
5. Press the NEXT ATTRIBUTE key to move to the Replace With text box and enter the new point name.
Search for Words ThatAre Similar
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-15
6. Press the OK button. The editor begins the searching process.
The editor finds all SPACE#TEMP names with only a single letter or digit between SPACE and TEMP. So, it finds SPACE1TEMP through SPACE9TEMP and SPACEATEMP through SPACEZTEMP.
7. When the cursor lands on the point name, you can press the space bar to replace it with the replace word.
What if you want to find SPACE10TEMP through SPACE99TEMP and SPACEAATEMP through SPACEZZTEMP? You enter two periods instead of one, as follows:
SPACE..TEMP
When the cursor lands on the point name, you can press the space bar to replace it with the replace word.
To find only a letter, and not a number, you can search for SPACETEMP with any letter in the middle. You do this by placing the range you want the character to be within in square brackets, as in the following:
SPACE[A-Z]TEMP
This expression finds SPACETEMP with a single letter from A to Z in the middle.
The text with characters like periods and brackets that have special meanings is called a “regular expression.” These characters (*, [, ], ., $,\) have special meanings only when you select Regular Expression Search in a Search window.
You Press OK to Begin the Search
www.PDF-Zoo.com
Developing Programs
9-16 Infinity Controller Programmer’s Guide
Figure 9-8 shows a regular expression in a Search window.
Figure 9-8. Regul ar Expression i n Search Window
You can find many other combinations of characters with regular expressions.
Finding Text with a SingleDigit That Varies
You can find any single digit except zero in the middle of SPACETEMP with the following regular expression:
Space[1-9]Temp
Finding Text with MultipleCharacters That Vary
To find more than one letter in the middle, add the asterisk (*) to a regular expression searching for a single character:
Space[A-Z]*Temp
The asterisk means “repeat the previous character or range of characters indefinitely.”
The Regular Expressi onGoes after Search For
File Edit Search Check Tools
Search For SPACE[0-9]*TEMP
Search:Find
OK
CANCEL
(X) Ignore Case(X) Regular Expression Search
FLOOR1 AHU MORN.WARMUP
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-17
To find more than one digit in the middle of SPACETEMP, search for only the numerals with the asterisk:
Space[0-9]*Temp
This expression finds SPACE32TEMP, SPACE99TEMP, SPACE105TEMP, and so on.
Finding Text with One of TwoPoss ible Characters
You could search for either a particular letter or a particular number with a vertical bar, which means “or,” as follows:
Space[Z | 9]Temp
This expression finds SPACEZTEMP and SPACE9TEMP only.
Finding Text with Chara ctersfrom One of Two Poss ible Sets
You could search for either all letters or all numbers with the vertical bar, as follows:
Space[A-Z | 0-9]*Temp
This expression finds SPACEATEMP, SPACEAATEMP, SPACE1TEMP, SPACE99TEMP, and so on. It does not find SPACE2ATEMP, because it does not combine letters and numbers—it finds one or the other.
Finding Text That Ends a Lin e
To find a group of characters that ends a physical line, use the $ after them:
THEN$
The Asterisk FindsMultip le Characters
www.PDF-Zoo.com
Developing Programs
9-18 Infinity Controller Programmer’s Guide
All Speci al Characters You CanUse in Regula r Expres sions
Table 9-2 shows the special characters in regular expressions.
Table 9-2. Regular Expressio n Characters
Finding SpecialCharacters as Text
Suppose you want to find all occurrences of array entries that contain temperatures. Since the square brackets ([]) introduce or end a range, how do you find the actual square brackets? You can proceed in two ways:
• You place either bracket or a slash immediately after a left bracket.
• You place a slash immediately before the special character to cancel its special meaning.
For example, find the left bracket by putting it first inside the range, as follows:
Space[[0-9]Temp
Regular Expressio nCharacters
Character Meaning
Cancel special meaning of next character.Backslash (\)
Asterisk (*) Any number of repetitions of previous character(s).
Bar (|) OR
Characters that end a physical line.Dollar ($)
Period (.) Any single letter, number, or symbol.
Left [ Beginning of a range.
Right ] End of a range.
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-19
The editor automatically understands that the bracket immediately inside the brackets is a character to search for, rather than the beginning or end of a range.
In the Search For box, the above expression would find not only all single digits between SPACE and TEMP, but the following as well:
Space[Temp
This is not likely to be a point name. You really want to search for two brackets at the end of a point name with a number or name between them.
Find ing Both Bracke ts
You find the other bracket by putting it after the range with a backslash in front of it:
Space.Temp[[A-Z|0-9]*\]
In the Search For box, this expression would find, for example, the following:
Space1Temp[HOUR]
Space2Temp[3]
Space3Temp[32]
Space9Temp[125]
Finding the Period in a Poin t Name
If you use periods in your point names, you can find them with regular expressions. You put a backslash (\) in front of any special character you want to find as text, including the period:
SpaceTemp\.[1-9]*
Editor Underst ands to Search For Bracket
www.PDF-Zoo.com
Developing Programs
9-20 Infinity Controller Programmer’s Guide
This expression finds the actual period, rather than any single character, such as, for example, the following:
SpaceTemp.1
SpaceTemp.9SpaceTemp.81
SpaceTemp.1982
You can find the asterisk (*) or dollar sign ($) the same way.
You can also search for a backslash (\), as well as either square bracket, by placing it as the first character inside the brackets.
Search f or AnyCharacter as Text
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-21
Summary
• You select Regular Expression Search in a Search window to use special characters in a search.
• A word or phrase you use special characters in is called a “regular expression.”
• You use a backslash in a regular expression to cancel the special meaning of the character that immediately follows it.
• You can find any characters within a range by putting them inside square brackets in a regular expression, as follows:
[ABCDEF] or [A-F]
• You can find a backslash, left square bracket, or right square bracket as text by placing it in the first character position in a range inside square brackets.
Select RegularExpressi on Search
www.PDF-Zoo.com
Developing Programs
9-22 Infinity Controller Programmer’s Guide
Opening a Command Window from I nside a Fi leSuppose you are inside a file and want to print some information on system variables. You want to print it in the Command window, but you do not want to exit the file.
Instead of exiting the file, proceed as follows:
1. Press the CANCEL WINDOW key to bring the cursor to the File menu bar.
2. Select Tools Command Window . A new Command window appears above the file Editor window.
Figure 9-9 shows how the windows appear.
Figure 9-9. A New Command Window
Now you can enter any commands here that you would enter in the original Command window.
Opening AnotherCommand Window
File Edit Search Check Tools
Command Window – BLDG1 FLOOR1
FLOOR1 AHU MORN.WARMUP
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-23
Moving from Windo w to Wind ow
To move the cursor from the file to the Command window to the File menu bar, press the CANCEL WINDOW key and then press it again.
Removing the Comm and Window
To close (remove) the Command window, press the CANCEL WINDOW key. The cursor moves to the File menu bar. Press Tools Command Window again. The Command window disappears.
Summary
• You select Tools Command Window to open a Command window from inside a file.
• The Command window appears above the Editor window.
• You press the CANCEL WINDOW key to move from window to window to the File menu bar.
• You select Tools Command Window again to remove the Command window.
Press CANCEL WINDOW to Leave Window
www.PDF-Zoo.com
Developing Programs
9-24 Infinity Controller Programmer’s Guide
Looki ng at, Creating, and Alter ing Points from Insi de a Program Fi leSuppose you are inside a program file, entering a program, and can’t remember the name of a point. You do not have to exit the file. You can go back to the File menu bar (press the CANCEL WINDOW key) and select Tools Point Summary to see the points available.
Figure 9-10 shows the Point Summary selection in the
Tools menu.
Figure 9-10. Selec ting Tools Poin t Summary
As shown in Figure 9-11, the Point Summary window appears.
Remembering Points
File Edit Search Check Tools
Edit a Point
Point Summary
Messages
File Summary
Program Summary
Edit a System Variable
Command Window
System Variables
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-25
Figure 9-11. Tools Point Summary Window
Press the up and down arrows to move the cursor from point to point in the list.
Press the PAGE UP key. Notice the cursor moves up to the previous screen or to the top of the same screen of points.
Press the PAGE DOWN key. Notice the cursor moves down to previous screen or to the bottom of the same screen of points.
While a particular point is highlighted, you can press the EXECUTE key. The Open a Point window appears. You then proceed as described in Chapter 4.
You can also create a new point, alter an old one, or look at a point’s attributes by selecting Tools Edit a Point . The Open a Point window appears and you then proceed as described in Chapter 4.
Point Summary – Floor1 AHU
Name Value Units Type State
SupplyFan OFF
ReturnFan OFF
Dampers 100% OutsideAir
Output
Output
Output
Output PrehtValve 100% Open
View Edit Connect Logout
I C
0,4 Enabled
0,3 Enabled0, 2 Enabled0, 1 Enabled
Moving through the List
www.PDF-Zoo.com
Developing Programs
9-26 Infinity Controller Programmer’s Guide
Looki ng at Messages from Inside a Program Fi leSuppose you are inside a program file, entering a program, and you want to see the messages pending on the system. You can go back to the File menu bar (press the CANCEL
WINDOW key) and select Tools Messages to see the messages pending.
Figure 9-12 shows the Messages selection in the Tools menu.
Figure 9-12. Selec ting Tools Messages
Once you have selected it, the Messages window appears.
Figure 9-13 shows the Messages window.
Seeing Messages
Edit a Point
Point Summary
File Edit Search Check Tools
Messages
File Summary
Program Summary
Edit a System Variable
Command Window
System Variable Summary
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-27
Figure 9-13. Messages Window
To erase the messages, press the CLEAR button.
To leave the window without erasing the messages, press the EXIT button.
Messages – BLDG1 FLOOR1
EXIT CLEAR
View Edit Connect Logout
Erase Messages wit h CLEAR Bu tton
www.PDF-Zoo.com
Developing Programs
9-28 Infinity Controller Programmer’s Guide
Looki ng at List of Files from Inside a Program Fi leSuppose you are inside a program file, entering a program, and you want to use another program but cannot recall its name. You can go back to the File menu bar (press the
CANCEL WINDOW key) and select Tools File Summary to see the files on this controller or select Tools Program Summary to see only the program files on this controller.
Figure 9-14 shows the File Summary selection in the Tools menu.
Figure 9-14. Selec ting Tools File Summary
Once you have selected it, the File Summary window appears.
Figure 9-15 shows the File Summary window.
Seeing List of Files
Edit a Point
Point Summary
File Edit Search Check Tools
Messages
File Summary
Program Summary
Edit a System Variable
Command Window
System Variable Summary
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-29
Figure 9-15. Tools File Summary Window
The file summary lists general information on all the files in the controller, no matter what their type. It takes the information from the File window you defined it in.
Once you are inside the summary list, if you want to open a file and make changes to it, you can move down the list with the arrow keys or the PAGE DOWN key. When the file you want to change is highlighted, press the EXECUTE key. The Open a File window appears.
Proceed as described in Chapter 5.
Name Description Type State
MORN.WARMUP Warms up heating. Program Enabled
File Summary – BLDG1 FLOOR1
Function EnabledSTOP.START Starts equipment.
View Edit Connect Logout
View File Summary Window
www.PDF-Zoo.com
Developing Programs
9-30 Infinity Controller Programmer’s Guide
Copyi ng Programs to Other Controlle rsGOAL: To close the damper and turn off the reheat coil in the first VAV box on the first floor. Close the dampers and turn off the coils on all other VAV boxes on the first floor, then on all other floors.
Each damper and coil is named:
DAMPER and REHEAT
You would start by using the Connect menu from the Main menu bar to connect to the ROOM101 Infinet controller on the BLDG1 Infinity CX 9000. Then:
1. Close the damper.
2. Turn off the reheat coil.
Figure 9-16 shows the flowchart of the program.
Figure 9-16. A Flowchart o f VAV1.STOP
Figure 9-17 shows the program, which is a FallThru program.
Connect Menu OpensOther Controllers
Turn Off theReheat Coil
Close the Damper
Start
End
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-31
Figure 9-17. VAV1.STOP Progr am
This simple program controls only one VAV box. To control all VAV boxes on the first floor, proceed as follows:
1. Make sure the points on each VAV box have the same names.
Then connect to another Infinet controller and copy the program to it as follows:
2. Press the CANCEL WINDOW key to return the cursor to the File menu bar.
3. Select File Save As .
As shown in Figure 9-18, the Open a File window appears.
The name of the Infinity CX 9000 controller appears in the Controller text box.
File Edit Search Check Tools
CLOSE THE Damper, THE Reheat
ROOM101 VAV1.STOP
Select FILE SAVE AS to Copy File
www.PDF-Zoo.com
Developing Programs
9-32 Infinity Controller Programmer’s Guide
Figure 9-18. Open a File Window
4. Fill in the name of the Infinet controller in the Infinet Ctlr text box.
5. Fill in the name for the program in the Name text box. You might call the second VAV program VAV2.STOP, the third VAV3.STOP, and so on. Or you might name all of them VAV.STOP, since you can have programs with the same name on different controllers.
6. Press the EXECUTE key to complete the copying process.
7. Repeat steps 2 through 6 for each VAV box on each floor.
To copy from one Infinity CX 9000 to another, you would proceed the same way, only you would change the controller name in the Controller text box and leave the Infinet Ctlr text box empty.
Controller
Open a File
Infinet Ctlr
Name
File Edit Search Check Tools
BLDG1
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-33
Summary
• The controller knows the Infinity CX 9000 you are on when you open the file and displays the name in the Controller text box.
• You can take the same action in several rooms on several floors by copying the program from one TCX 850 or similar Infinet controller to many others under different names.
• To copy a program to another Infinet controller:
• Select the File Save As command from the File menu bar.
• Fill in the name of the Infinet controller.
• Fill in a new name for the program.
• Be sure each copy of the program has a unique name for that controller.
• Press the EXECUTE key to complete the process.
Give Program a Unique Name for That Controller
www.PDF-Zoo.com
Developing Programs
9-34 Infinity Controller Programmer’s Guide
Using Points on Another ControllerYou can use paths to points to print or perform other actions with a point from the command line as well as inside an Infinity CX 9000 program. The path gives you access to a point that may be on another controller. For instance, you can print the temperature in room 408 of building 1 from any controller on the network:
PRINT BLDG1 ROOM408 SpaceTemp
You can also print the attributes of the point. To find out how many digits of accuracy the input gives, print the format of the SPACE point:
PRINT BLDG1 ROOM408 Space FORMAT
Or you can print the units to see if they are in degrees Celsius or Fahrenheit:
PRINT BLDG1 ROOM408 Space UNITS
If you are not sure what the conversion is for a point, you might want to print it to the screen:
PRINT BLDG1 ROOM400 AirFlow CONVERSION
Besides printing points from another controller, you can check their values:
IF BLDG1 ROOM402 Reheat = ON THEN...
IF CENTRALPLANT CW1ISOValve IS 80% THEN...
IF CENTRALPLANT CHWP1Valve IS OPEN THEN...
IF CENTRALPLANT TOWER Fan1ST IS OFF...
Print th e FORMATAttribut e of a Poin t
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-35
You can set values of points on another controller, although we do not recommend it:
SET BLDG1 ROOM403 Damper TO –ON
OPEN BLDG1 ROOM209 Damper
For the most reliable and efficient programs, we recommend you set all points from their own controllers.
Using the path naming structure, you can do the following to any point on the network from any controller on the network:
• Print the point value.
• Check the point value.
• Set the point value.
• Print other point attributes.
• Check other point attributes.
• Set some attributes.
Summary
• You can use full path names to access points on the Infinet controllers on your network.
• To access points on a Infinet controller from an its own Infinity CX 9000, you need only give the name of the Infinet controller followed by the name of the point.
• To access points on a Infinet controller from another Infinity CX 9000, you must give the full path to that Infinet controller—the Infinity CX 9000 name followed by the Infinet controller name.
• Using full path names, you can print or check any point attribute from the command line or from inside a program.
• For the most reliable and efficient programs, set all points from their own controllers.
Follo w Path Name to Any Point on Network
www.PDF-Zoo.com
Developing Programs
9-36 Infinity Controller Programmer’s Guide
Preventing Particular Poi nt Values from D isplaying o n the Keypad LC DGOAL: To prevent the FAN1 point from displaying on the CENTRALPLANT TOWER SCX 900 keypad’s LCD.
You can display point and system variable values on the LCD of the keypad found on some Infinet controllers (SCX 900 and LCX 810 controllers). Details on how to display them are in the Andover Controls Infinity CX Operator’s Guide.
Unless you stop particular points (or system variables) from displaying, any operator with the password can change the value of that point. To prevent a particular point from display-ing in the LCD, you (with Admin access level) set its LCDSTATE to DISABLED.
Figure 9-19 shows what you enter in the Command window.
Figure 9-19. Command to Prevent the FAN1 Point from Disp laying on the TOWER LCD
This command sets the LCDSTATE attribute on the FAN1 point on the FLOOR1 ROOM1 SCX 900 to DISABLED.
Display Only Particu larPoin t Values on the LCD
R>SET CENTRALPLANT TOWER FAN1 LCDSTATE = DISABLED
Command Window - BLDG1
R>
View Edit Connect Logout
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-37
The result is that the point is not disabled in any other way, only from displaying on the keypad LCD.
As shown in Figure 9-20, you can do the same for system variables, such as HOUR or DATE.
Figure 9-20. Commands to Prevent HOUR and DATE from Disp laying on the TOWER LCD
Later, if you would like, you can change the LCDSTATE of each point to ENABLED.
Summary
• You can prevent a particular point value or system variable from displaying on the LCD of any SCX 900 and LCX 810 controller.
• You set the LCDSTATE attribute of any point to DISABLED to prevent that point from displaying on the LCD.
• You set the LCDSTATE attribute of any point to ENABLED to allow that point to display on the LCD.
Point Is Di sab led from Displaying on LCD
View Edit Connect Logout
R>SET CENTRALPLANT TOWER HOUR LCDSTATE = DISABLED
Command Window - BLDG1
R>SET CENTRALPLANT TOWER DATE LCDSTATE = DISABLEDR>
www.PDF-Zoo.com
Developing Programs
9-38 Infinity Controller Programmer’s Guide
Finding Errors Resulting from Deleting a n ItemSometimes when you open a file you receive a message in the status bar. This type of message is called an “opening file error message.”
The message may say the following:
Controller cannot find an item
The controller cannot find a point or other item that is in a statement in the file you have opened. Why? Usually because it has been deleted.
For instance, if your file is a program that has a statement to turn off a fan and the point for that fan has been deleted, the controller cannot find that point and gives the above message.
So now what do you do? You look in the file at the line the cursor has landed on. The deleted point has been replaced with the following:
?_1
So the program line now reads
TURN OFF THE ?_1
instead of
TURN OFF THE FAN
Each time the name of the same deleted point occurs in the file, the controller replaces it with the same designation. Also, if you have deleted two fans, one is ?_1 and the other ?_2. These replacements are used throughout the file.
If the item is a single item not in a path, the replacement for it is always ?_n where n is a number.
Deleted Item May Still B ein File
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-39
If the item is in a path name, different items in the path are replaced as follows:
• An Infinity CX becomes ?n
• An Infinet controller becomes ?n_n
• A point becomes ?_n
Here are some examples of paths you might see:
IF ?2 ?2_1 ?_4 > 82 THEN OPEN DAMPER
?2 is an Infinity CX, ?2_1 is an Infinet controller, and ?_n is a point.
IF FLOOR1 ?2_2 ?_1 > 82 THEN OPEN DAMPER
If an Infinet controller is replaced with ?n_n, then the point that follows it may not have been deleted; often the controller cannot find the point because it cannot find its controller.
Correc ting th e Error
If the item is a point, to correct this error find the item and be sure the point is connected to a sensor or piece of hardware. Then rename the point. You can open up the Tools menu while inside the file and name the point from there.
Since ?_1 always refers to the same point, you can use the Search menu to find all occurrences of ?_1 and replace them with the new name. Replace any complete path names used in the file first; then replace any single item names. For example, when you replace FLOOR1 ROOM2 ?_2, search for the entire path, even though only one name is in question.
If an Infinity CX 9000 or Infinet controller comes up with a ?, check to see if the controller is still on the network. If it is not on the network, find out why it is down using the Andover Controls Infinet Controller Troubleshooting Guide or Ener-gyNet and Infinet Troubleshooting Guide.
Items in Path Names Are Replaced by Symbols
www.PDF-Zoo.com
Developing Programs
9-40 Infinity Controller Programmer’s Guide
Enabling and Disabling ProgramsGOAL: To take the VAV.STOP program out of software control, so that you can alter it. Later, after altering it, to let the controller control the program once more.
To stop the controller from running VAV.STOP you use a keyword called DISABLE in the command line, like this:
DISABLE VAV.STOP
Disabling a program is not the same as stopping a program with STOP. If you stop a program with STOP, someone can still start it again with RUN. If you disable a program, then try to run it, the controller does not take action. DISABLE protects a program from being run.
You can also disable more than one program at a time:
DISABLE VAV.STOP, MORN.WARMUP, PRECOOL
After you alter the program, the controller cannot run VAV.STOP again until you give control back to the system. To do so, you use a keyword called ENABLE:
ENABLE VAV.STOP
You can also enable more than one program at a time:
ENABLE VAV.STOP, MORN.WARMUP, PRECOOL
Remember, enabling and disabling a program is different from running and stopping one. A program must be enabled before you can run it.
You can enable or disable a program from the command line or from inside a program.
Disab lin g Is Not theSame as Stopping
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-41
Summary
• Disabling a program is not the same as stopping it.
• Enabling a program is not the same as running it.
• A disabled program cannot be run by the controller.
• An enabled program can be run by the controller.
• You can enable or disable a program from both the command line and inside a program.
Disab lin g and Enablin g Programs
www.PDF-Zoo.com
Developing Programs
9-42 Infinity Controller Programmer’s Guide
Under standing the Scanning ProcessThe controller is constantly scanning. In general, the interpreter inside the controller gathers all data it needs for the next scan through the programs, reads and executes one line from each enabled program starting with the first program in the firing order list and continuing to the last, then converts and sets outputs. This type of single run through the list of programs is called a “scan.”
The controller then returns to the beginning of the firing order list and scans the next appropriate line of each program. The scans continue.
What is the “next appropriate line”? The line determined by the scan process sequence.
A complete list of scan actions in the order the controller carries them out is as follows:
• Updating system variables
• Updating schedules, setting occupied and unoccupied events
• Gathering and converting input points
• Processing program statements and commands
• Converting output points and setting hardware
• Evaluating alarms
• Updating the status bar
Figure 9-21 illustrates the scanning process.
Scan Proces s Occ urs ina Particu lar Order
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-43
Figure 9-21. Illu str atio n of Scanning Process
The following take effect immediately at any time in the scan:
• Triggers set program STATUS to active
• Value of numeric, string, or datetime points change• Attribute values update• Point logs update• Command lines execute (between programs)
Update System Variables
Start Here and Proceed Clockwise
UpdateOutputPoints
RunPrograms& Com- mands
ProcessAlarms
UpdateSchedules
Update Input Points
• Points go to and from other controllers
www.PDF-Zoo.com
Developing Programs
9-44 Infinity Controller Programmer’s Guide
A complete list of scan actions in the order the controller carries them out is as follows:
1. Updating System Variables
The controller updates the values of all ENABLED system variables (DATE, SECOND, MINUTE, HOUR, WEEKDAY, and so on) at the start of each scan. Setting the DATE first ensures that all programs work from the same time base.
System variables keep the value they begin with throughout the scan. So, if the scan starts on the 12th second of the minute, SECOND equals 12 throughout the scan.
(If the scan itself is .25 seconds long, then the some actions are taking place at between 12 and 12.25 seconds. This is a factor to keep in mind when seconds really matter.)
If a program is in the trigger list for a system variable that has changed, and the program’s STATE is ENABLED, its STATUS is set to ACTIVE so it runs during the upcoming scan.
2. Updating Schedules
Before proceeding to other points, Infinity processes schedules by updating each occupied and unoccupied point and variable so that later, when programs run, the actions are based on the latest schedules. You create and store the schedules on an Infinity SX workstation, but they take effect only on a controller.
3. Gathering and Converting Input Points
The scan gathers electrical values (represented by theELECVALUE attribute) of all ENABLED inputs from re-mote and local inputs, in numeric order starting with input 1. The inputs for the electrical values are in the electrical units specified for that point.
Contr oller UpdatesEnabled Variables
Controller GathersInput Electr ical Values
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-45
The controller converts each input that has changed since the last scan into engineering units. Conversions methods may be different, but all occur at this moment in the scan, whether an auto-conversion, customized conversion, system conversion (such as ACC Degrees F or C), or null conversion (where VALUE equals ELECVALUE).
Input points, like system variables, retain the value they have at the beginning of the scan throughout the scan. All action taken during the scan is based on the initial input values.
If a program is in the trigger list for an input point that has changed, and the program’s STATE is ENABLED, its STA-TUS is set to ACTIVE so it runs during the upcoming scan.
4. Processing Program Statements
During each scan, the controller executes the current line from each program that has the following:
• STATE is ENABLED
• STATUS is ACTIVE
• Current line is not zero
The controller executes one line from each program in the order the firing order list specifies.
The controller has a safety mechanism so no single program can monopolize the scan. The mechanism is a statement counter that disables a program and sets its ERROR attribute to “Statement count exceeded!” if the scanner tries to execute more than 5000 statements in a single line during a single scan.
Processing Command Lines
The controller treats command lines entered in the Command windows of the various terminals and computers like one-line programs. The scanner checks for command
Controller ExecutesCurrent Program Lines
Controller Checks for Command L ines
www.PDF-Zoo.com
Developing Programs
9-46 Infinity Controller Programmer’s Guide
lines at the beginning of each scan and between each program during the scan and responds immediately. So each command line is processed quickly.
5. Converting Outpu t Points and Sett ing Hardw are
The scan sets output values as instructed in programs or command lines during the scanning process. At the end of the scan, the controller converts the value of each output that changed in the previous scan from engineering units to electrical units.
Conversions methods may be different, but all occur at this moment in the scan, whether an auto-conversion, customized conversion, or null conversion (where ELECVALUE equals VALUE).
After converting all output point values, the ELECVALUEs are sent to the local or remote outputs.
If the first program sets the output of HEATER to ON and the last program sets it to OFF, how does the controller resolve this kind of conflict?
The HEATER is set to OFF, because output points change at the end of the scan—so the setting of the last program is the one that takes affect.
You can use the fact that the output hardware is not updated until the end of the scan to carry out certain advanced control strategies, but we do not encourage you to program this way. You should handle both turning on and turning off a piece of equipment in one program, so that no conflicts arise based on the firing order list.
We do, however, recognize that you may want a master emergency program to override output settings of all other programs in certain circumstances. That is why you are allowed to alter the firing order.
Controller Sets Outputs
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-47
6. Evaluatin g Alarms
Finally, the last action of the scan is evaluating alarms.
All points can have up to eight conditions that the controller sets an alarm under. You set these conditions on an Infinity SX 8000 workstation. Whenever the point’s value changes during the scan, the controller evaluates each condition associated with an alarm at the end of the scan and updates the alarm’s ALARMSTATUS (or calculates its delay time). Thealarm is activated immediately unless it has a delay.
If the controller has set the ALARMDELAY, and the condition to set the alarm is TRUE, the controller adds the ALARMDELAY time to the current system time to calculate the alarm delay time. The scan places the alarm in a list of alarms to be evaluated again based on their alarm delay time (ALARMTIME).
At the end of each scan, the scanner checks the list of delayed alarms. The scanner reevaluates the alarm conditions of the alarms that have not yet reached their delay times, and if they are still TRUE, sets the alarms.
After the scan processes the alarms, it updates the Status bar.
Numeric, String, and DateTime Poin ts
Numeric, string, and datetime points change values immediately within a program. So if the first program sets the setpoint to 72, and later in the same scan another program tests the setpoint, the later program sees the new value of 72.
Updating Point Logs
As it alters point values, the scan evaluates all points that are automatic logs and updates them if necessary (based on the log interval).
Controller EvaluatesAlarms
Cont ro ller Sets Numeric Points Im mediately
www.PDF-Zoo.com
Developing Programs
9-48 Infinity Controller Programmer’s Guide
Trig gering Program s from Points
Scan length varies depending on the amount of work done. You can reduce scan time by setting up all programs like this:
• Set up all points a program uses to make decisions as triggers for that program.
• Have the program make the decision and set some points.
• Have the program end (by being FallThru or having a STOP statement).
Such programs run only when necessary, reducing scan time.
Exported Points and the Scan
Point values can be exported at any time during the scan. So if PROGRAM1 turns the fan on early in the scan and PROGRAM99 turns it off later, although the fan would never physically turn on, the VALUE of ON could be exported to another controller between PROGRAM1 and PROGRAM99. This is another reason you should handle both turning on and turning off a piece of equipment in one program.
You Can Reduce ScanLength
Point Values Can BeExported During Scan
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-49
Summary
• To reduce scan time, write FallThru programs run by triggers.
• Be careful to handle turning on and turning off the same piece of equipment in one program.
During the scan, the controller takes the following actions in the order listed:
• Updates system variables.
• Processes schedules.
• Gathers electrical values of inputs and converts them.
• Executes current lines from each program. Treats command lines as one line programs and checks for them between each current line.
• Converts outputs and sets hardware.
• Evaluates alarms and updates the status bar.
Reduce Scan Time with FallThru Programs
www.PDF-Zoo.com
Developing Programs
9-50 Infinity Controller Programmer’s Guide
Alter ing the Firi ng OrderWhen you enter a new program, it is automatically placed at the top of the firing order list.
To see the list, select File Firing Order from the File menu bar.
As shown in Figure 9-22, the firing order list appears.
Figure 9-22. Firing Order List Window
Suppose the program you just entered is OCCUPY, shown at the top of the firing order list. To move it to after ACTIVATEFAN and before MORN.WARMUP, arrow down to MORN.WARMUP. Press the NEXT ATTRIBUTE key to move to the PREVIOUS button. Once you press the button, OCCUPY then appears before MORN.WARMUP.
To move OCCUPY to after MORN.WARMUP, arrow to MORN.WARMUP and press the NEXT button. OCCUPY then appears after MORN.WARMUP.
New Program Is Last onFiring Order List
Firing Order – FLOOR1 OCCUPY
QUIT
PREVIOUS
Insert Program
NEXT
File Edit Search Check Tools
MORN.WARMUP
ACTIVATEFAN
OCCUPY
FLOOR1 OCCUPY
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-51
When you have positioned the program, press QUIT to exit the window and return to the program Editor window.
You can look at the firing order list from inside a function or data file, but can alter it only from a program file.
Summary
• The controller always places a new program at the top of the firing order list.
• To move the new program to before another program in the list, highlight the other program and press the PREVIOUS button.
• To move the new program to after another program in the list, highlight the other program and press the NEXT button.
• To exit the window, press the QUIT button.
• You can open the firing order list from a function or data file.
• You can change the firing order list only from a program file.
Press QUIT to Exit the Firing Order Window
www.PDF-Zoo.com
Developing Programs
9-52 Infinity Controller Programmer’s Guide
Helpf ul Hint s for Pr ogram Set
Controlling Firing O rder
What factors should influence the order you create in the firing order list?
When you later save all your points and programs to a tape or disk (details in Chapter 18), the controller saves the programs in the order they are listed in the list, starting with the last one listed and proceeding back to the first.
And when you reload the programs from the tape or disk, the controller loads the programs starting with the first one listed and proceeding to the last.
When you form your list, consider the following:
• Programs that call other programs should load after them, so you should list them later in the list.
• Since AUTOSTART programs start immediately after loading, they may start before the programs that work interdependently with them have been loaded. To be sure this does not happen, create a program to stop all programs. Make it AUTOSTART and put it at the top of the firing order list. Now, when you reload them after a power outage, all AUTOSTART programs remain stopped until you start them.
• Add a program at the bottom of the list that starts the same AUTOSTART programs you stopped at the top of the list.
Saves in Reverse FiringOrder, Loads in Order
Programs to Cont ro lResults of Loading
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-53
Figure 9-23 shows a sample HALTPROGRAMS program.
Figure 9-23. Sample Program to Stop Programs
Figure 9-24 shows a sample STARTPROGRAMS program.
Figure 9-24. Sample Program to Start Programs
File Edit Search Check Tools
FLOOR1 BLDG1 HaltPrograms
STOP OutsideAirTest, SpaceTempTest, VentilationTest
File Edit Search Check Tools
FLOOR1 BLDG1 StartPrograms
START OutsideAirTest, SpaceTempTest, VentilationTest
www.PDF-Zoo.com
Developing Programs
9-54 Infinity Controller Programmer’s Guide
Controlling Exporte d Point Update s
Suppose OUTSIDEAIR travels out from (exports from) an Infinity CX 9000 to several TCX 850s for VAV box control. (Remember that the OUTSIDEAIR point updates only when the temperature changes by more than the threshold amount.) What happens if one of the TCX 850s loses power and misses some value changes while power is down? How does it get values of points that have not updated since the controller powered up?
While the TCX 850 is down, OUTSIDEAIR updates to all other boxes, but not to it. To ensure that crucial points (such as OUTSIDEAIR is to an air handling system) update to all controllers periodically, you can set an attribute called REFRESH, as follows:
SET OUTSIDEAIR REFRESH = TRUE
When REFRESH is TRUE for that point, the point updates as if its value had changed. You could update crucial points every 5 minutes using TM:
IF TM > 5 THEN SET OUTSIDEAIR REFRESH = TRUE
Updating Points Despi teLocali zed Power Failure
Occasionally, an Infinet controller does not receive a point update sent down from an Infinity CX controller because of either a localized power failure or the controller being offline for some reason. For most points, the change is automatically sent on the next scan.
However if this occurs for a setpoint or flag that does not change often, the controller can miss the change. To avoid this problem, set the REFRESH attribute for all setpoints or flags to ON every few minutes.
You Can Force CrucialPoin ts to Update
www.PDF-Zoo.com
Developing Programs
Infinity Controller Programmer’s Guide 9-55
The following is an example of a program that ensures the hot water setpoint receives all updates:
Checking:IF TM > 5 THEN GOTO Updating
Updating:SET HWSetpoint REFRESH to ON
GOTO Checking
Sample Program to Update HWSetpoint
www.PDF-Zoo.com
Developing Programs
9-56 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Chapter 10
Creating and Using Numeri c,Stri ng, and Dat eTime Points
This chapter introduces more types of points to the programming process:
• Using Numeric Points
• Using String Points
• Creating Date and Time Stamps
• Switching Lead/Lag with Positions of Minimum and Maximum in Log
• Forming a Log You Control
• Printing and Setting Point Attributes
www.PDF-Zoo.com
Advanced Points
10-2 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Advanced Points
Infinity Controller Programmer’s Guide 10-3
Table 10-1 shows the input and output points used in this chapter.
Table 10-1. Input and Output Points
Controller
OutsideAir CENTRALPLANT
CWSupply CENTRALPLANT
CX 9000 IOU
CX 9000 IOU
Point Point Type Model
Thermistor
Thermistor
CWBypassVlve CENTRALPLANT
Fan1 CENTRALPLANT TOWER
CX 9000 IOU
SCX 900
Form C Output
Form C Output
Fan2 CENTRALPLANT TOWER SCX 900 Form C Output
Fan1ST CENTRALPLANT TOWER SCX 900 Digital Input
Fan2ST CENTRALPLANT TOWER SCX 900 Digital Input
www.PDF-Zoo.com
Advanced Points
10-4 Infinity Controller Programmer’s Guide
Using Nume ric PointsGOAL: To set the setpoint of the chilled water temperature based on the outside air temperature. The range for the chilled water temperature is 40 to 50 degrees.
The single action steps to set the chilled water temperature are:
1. Check the outside air temperature.
2. Set the chilled water temperature based on the OUTSIDEAIR.
3. Do not allow the chilled water temperature to be higher than 50 degrees or lower than 40 degrees.
The points you need are OUTSIDEAIR and CHW.SETPT.
The OUTSIDEAIR is an input point. The CHW.TEMP is an input point with a setpoint set by CHW.SETPT.
If CHW.SETPT is not an input or an output, what kind of point is it?
It is a numeric point. It contains a numeric value stored in the controller for use by all programs, but does not actually interact with the environment in any way. You can also make a numeric point a log or array.
To set the CHW.SETPT, you must first create it as a numeric point. You then proceed with the program.
Numeric Points ContainNumeric Values
www.PDF-Zoo.com
Advanced Points
Infinity Controller Programmer’s Guide 10-5
Figure 10-1 shows the flowchart of the program.
Figure 10-1. Flowchart of CH.WATER
Flowchart ProgramUsing Numeric Point
Set the
Check the Out-
based
side Air Temp
Is
? 120 – OAT < 40
NO
YES
Set the ChilledWater Tempto 40 degrees
on OAT
Chilled Water
KeepChecking
Is
? 120 – OAT > 50
YES
Set the ChilledWater Tempto 50 degrees
Temp
NO
www.PDF-Zoo.com
Advanced Points
10-6 Infinity Controller Programmer’s Guide
Figure 10-2 shows the actual program.
Figure 10-2. CH.WATER Program—Looping
You can also employ MINIMUM and MAXIMUM towrite this program, just as you did with WATERTEMP in Chapter 8.
File Edit Search Check Tools
CENTRALPLANT CH.WATER
IF 120 – OutsideAir IS LESS THAN 40 THEN SET CHW.SETPT TO 40
IF 120 – OutsideAir IS GREATER THAN 50 THEN SET CHW.SETPT TO 50
IF 120 – OutsideAir IS 40 THRU 50 THEN CHW.SETPT = 120 – OutsideAir
www.PDF-Zoo.com
Advanced Points
Infinity Controller Programmer’s Guide 10-7
Summary
• A numeric point is a point that does not interact with the environment, but has a numeric value.
• A numeric point is stored in the controller for use by all programs.
Numeric Points Storedin Controller
www.PDF-Zoo.com
Advanced Points
10-8 Infinity Controller Programmer’s Guide
Using String P oint sGOAL: To control the cooling tower fans based on the temperature of condenser water. To print a message when a fan fails.
Since you want the message to be available whenever you need it for all fans, it is a good idea to store a message in a string point.
A string point is a point that stores characters. You can name such a point FAILMESSAGE. You then give it a value in one of two ways:
• Enter the value in the Details window.
• Enter the value using the SET keyword in the Command window.
Setting Strin g in Details Wind ow
1. Select Edit Points from the Main menu bar.
2. Press the SHOW LIST key and select the
FAILMESSAGE point or type the name in the Name text box to create a new point.
3. Select String for TYPE, and set the STATE to either Enabled or Disabled .
4. Move (press the NEXT ATTRIBUTE key) to the text box after the equal sign (to the right of the name).
5. Type the message in the text box.
Figure 10-3 shows the message in the window.
String Poin ts OftenContain Messages
www.PDF-Zoo.com
Advanced Points
Infinity Controller Programmer’s Guide 10-9
Figure 10-3. Sett ing a String Poin t Message
Setting Strin g in Command Wi ndow
To set the string in the Command window, you enter the point value in quotation marks, like this:
FAILMESSAGE = "The fan has failed."
But how, then, does the person receiving the message know which fan has failed?
You should print the point name in the message. Since that name changes from point to point, you enter a format to receive any point name, as follows:
FAILMESSAGE="|@@@@@@@@@@@@@@@@ has failed."
View Edit Connect Logout
( ) Input ( ) Output
( ) Numeric
( ) Datetime
(X) String
(X) Enabled( ) Disabled
Type
State
Point – BLDG1 FAILMESSAGE
String Size 45
DETAILS
SAVE AS
CANCEL
SAVE
Name FAILMESSAGE = The fan has failed.
Enter Point Value inQuotation Marks
www.PDF-Zoo.com
Advanced Points
10-10 Infinity Controller Programmer’s Guide
The “|@@@@@@@@@@@@@@@@” part of the message is a format for the name of the point. Each at sign (@) stands for a character in the point name. The point name can be up to 16 characters long, so there are 16 @ signs.
A program prints the message as follows:
PRINT FAILMESSAGE, Fan1 NAME
The word NAME is the NAME attribute of FAN1. You can give the attribute after the point name and the controller understands you want that attribute of the point rather than the value. (If you just gave FAN1 without NAME, you’d get FAN1’s value. More about using point attributes is presented later in this chapter.) The name of the point fills the @ signs, leaving this on the screen:
Fan1 has failed.
Setting Fan s Based on Conden ser Wate r Temperatur e
The single-action steps to control the tower fans are as follows:
1. Check the temperature of the condenser water.
2. If the temperature is less than 75, set the condenser water bypass valve to 50%.
3. If the temperature is greater than 77, close the condenser water bypass valve.
4. If the temperature is less than 79, turn off the fans and stop LEAD.LAG.FAN, a program that runs while the fans are on and switches from the lead fan to the lag.
5. If the temperature is greater than 82, start LEAD.LAG.FAN, a program that controls the fans. (See LEAD.LAG.FAN later in this chapter.)
@ Signs Create Formatfor String Poin t
www.PDF-Zoo.com
Advanced Points
Infinity Controller Programmer’s Guide 10-11
Figure 10-4 shows a diagram of the chiller system so you can see why the bypass valve is opened at certain times and closed at others.
Figure 10-4. Chil ler System
Diagram of Chil ler and Fan Setup
Chiller
Fan1 Fan2
CWBypassVlve
NormallyClosed
NormallyOpen
CWPump
CWSupply
To open the bypass valvemeans to divertcondenserwater from thetower fans.To close thevalve means todivert water to the fans.
www.PDF-Zoo.com
Advanced Points
10-12 Infinity Controller Programmer’s Guide
Figure 10-5 shows the flowchart of the CW.CONTROL program to control the temperature of the condenser water. The program is looping, so it continuously tests the temperature of the condenser water.
Figure 10-5. Flowchart of CW.CONTROL
Figure 10-6 shows the program. The program is written on the TOWER Infinet controller, so the program refers to the
Flowchart of CondenserWater Program
Is the
Water Temp <75?
YES
YES
NO
Close the Bypass Valve
Is theWater Temp >77?
Set BypassValve to 50%
Start
Is the
Water Temp <79?
YES
YES
StartLead.Lag.Fan
Is theWater Temp >82?
Turn off Fan1 and Fan2
NO
NO
NO
www.PDF-Zoo.com
Advanced Points
Infinity Controller Programmer’s Guide 10-13
CWSUPPLY point on the CENTRALPLANT’s IOU using its full path.
Figure 10-6. CW.CONTROL Program—Looping
Checkin g the Fan Status
The single-action steps to print the string point to the screen when a tower fan fails are as follows:
1. After 15 seconds have elapsed, check to be sure the fan status is equal to the output setting.
2. If the fan status is not equal to the output setting, print the FAILMESSAGE.
Figure 10-7 shows the flowchart for the tower fan status check-ing program. The program is FallThru but loops manually, so that it can check elapsed time. You make a program loop man-ually by sending it to the line it is on with GOTO.
By looping manually, the program stays on the same line for more than one scan, somewhat like a Looping program. However, as a FallThru program, it continues to carry out the actions in order and carry out each action only once.
File Edit Search Check Tools
CENTRALPLANT TOWER CW.CONTROL
IF CentralPlant CWSupply > 77 THEN CLOSE THE CWBypassVlve
IF CentralPlant CWSupply > 79 THEN
IF CentralPlant CWSupply < 75 THEN MOVE CWBypassVlve TO 50%
TURN OFF Fan1 AND Fan2
STOP LEAD.LAG.FAN
IF CentralPlant CWSupply > 82 THEN START LEAD.LAG.FAN
ENDIF
Checking the Fan Status
www.PDF-Zoo.com
Advanced Points
10-14 Infinity Controller Programmer’s Guide
Since CW.CONTROL can stop the fans, and LEAD.LAG.FAN can stop the fans, set FAN1, FAN2, FAN1ST, and FAN2ST to all trigger the TOWER.FAN.CK program. Once the program is triggered, it then checks the fan status against the actual setting of the fan to determine that the equipment is functioning.
Figure 10-7. Flowchart of TOWER.FAN.CK
Since the setting of a fan or its status could also be changed by a malfunction in the equipment, rather than by a program, you would be better off setting the triggers than waiting for either LEAD.LAG.FAN or CW.CONTROL to run the checking program. Then, no matter which program or circumstance starts or stops the fans, the controller still checks to be sure they are working.
Notice that although these programs work independently, they also work together. Good programming technique dictates that you check the status of equipment in a program separate from the one that runs the equipment.
Figure 10-8 shows the TOWER.FAN.CK program. The program is FallThru and contains a GOTO statement in the WAIT line to wait for 15 seconds before going to the
Flowchart of Tower FanCheck Program
Is theFanstatus Not
= Output ?
YES
NO
STOP
Wait 15 sec
Print the Message
www.PDF-Zoo.com
Advanced Points
Infinity Controller Programmer’s Guide 10-15
FANTEST line. The STOP statements keep the program from running indefinitely. Once the program has checked the fan, it stops.
Figure 10-8. TOWER.FAN.CK Program—FallThru
Summary
• You use a string point to contain a message you expect to use in more than one program.
• You can create a string point in the Point window.
• You can assign the string point a value in the Point window or the Command window.
• You can insert values into the message and format the way the values display on the screen or printer.
• You can make a FallThru program loop by using GOTO to send it to the line it is currently on.
File Edit Search Check Tools
CENTRALPLANT TOWER TOWER.FAN.CK
LINE WAIT
IF TS > 15 THEN GOTO FANTEST ELSE GOTO WAIT
LINE FANTEST
ELSE IF Fan2ST IS NOT Fan2 THEN STOP TOWER.FAN.CK
IF Fan1ST IS NOT Fan1 THENPRINT FAILMESSAGE,Fan1 NAME
PRINT FAILMESSAGE, Fan2 NAMESTOP TOWER.FAN.CK
ELSE STOP TOWER.FAN.CK
’Triggered by Fan1, Fan2, Fan1ST, or Fan2ST
You Can Set String Point Value
www.PDF-Zoo.com
Advanced Points
10-16 Infinity Controller Programmer’s Guide
Creating Date and Tim e StampsGOAL: To record the date and time the FAILMESSAGE is sent to the screen and print it after the message.
To set up a point that records the date and time, you create a datetime point.
Creating a DateTime Point
You create a datetime point as follows:
1. Select Edit Points from the Main menu bar.
2. Type the name (FANFAILTIME) in the Name text box to create a new point.
3. Select Datetime for TYPE, and set the STATE to either Enabled or Disabled .
4. Press the SAVE button, the EXECUTE key, or the SAVE key. The controller saves the point and closes the window.
Print ing the DateTime to the Screen
You print a datetime point value to the screen just as you would any other. You do not have to specify a format—the date and time print in a standard format.
The single-action steps to print the string point to the screen when the equipment fails and record the date and time of the message would be:
1. Give the fan 15 seconds to change status. Use GOTO to form the manual loop.
2. Check the fan status.
Create a DateTime Poin t
www.PDF-Zoo.com
Advanced Points
Infinity Controller Programmer’s Guide 10-17
3. If the status of the fan is not equal to the fan output, then send the message and set the datetime stamp.
4. Print the datetime stamp.
5. Stop the program.
Figure 10-9 shows the revised program.
Figure 10-9. TOWER.FAN.CK Progr am with a Timestamp—FallThru
Why not just print the DATE system variable? Because you could not then store the DATE. The point saves the date/time of the fan failure so can use it in another message or report.
You can also make FANFAILTIME a log or array and store several date/times in it to keep a history of fan failure times.
File Edit Search Check Tools
CENTRALPLANT TOWER TOWER.FAN.CK
LINE WAIT
IF TS > 15 THEN GOTO FANTEST ELSE GOTO WAIT
LINE FANTEST
ELSE IF Fan2ST IS NOT Fan2 THEN STOP TOWER.FAN.CK
IF Fan1ST IS NOT Fan1 THENPRINT FAILMESSAGE,Fan1 NAME
PRINT FAILMESSAGE, Fan2 NAME
STOP TOWER.FAN.CKELSE STOP TOWER.FAN.CK
SET FanFailTime = DATEPRINT "The date and time fan failed is ",FanFailTime
SET FanFailTime = DATEPRINT "The date and time fan failed is ",FanFailTime
’Triggered by Fan1, Fan2, Fan1ST, or Fan2ST
www.PDF-Zoo.com
Advanced Points
10-18 Infinity Controller Programmer’s Guide
Switching Le ad/Lag with Positions of Mini mum and Maximum in LogGOAL: To total the time the tower fans have been running and switch from the lead to the lag.
Setting Up a Manual Array
Start by setting up a manual array with two positions, each containing the runtimes of the tower fans. Position 1 would contain the runtime of FAN1, position 2 that of FAN2. The manual array could be called FANTIME.
Forming an Equ ation to Add Up Time
The program would add up the time the fan status is ON in hours.
To add up the time FAN1 has been running and set the first position in the FANTIME array:
SET FANTIME[1] = FANTIME[1] + (SCAN/3600 * Fan1ST)
This equation converts the SCAN system variable into hours by dividing it by 3600.
SCAN, to simplify it for this example, gives the number of seconds since the last time the point values were changed. If it has been 6 seconds, that is .1 minutes or .01 hours.
Then the equation multiplies number of hours by the fan status (1 for ON, 0 for OFF). If the fan is OFF during the scan, the controller adds 0 to FANTIME[1]. Only when the fan is ON does the controller add the SCAN to FANTIME[1].
You would use the same equation to set FANTIME[2] to the hours the other fan has been ON.
Set Up a Manual Array toHold Positio ns
www.PDF-Zoo.com
Advanced Points
Infinity Controller Programmer’s Guide 10-19
Finding the L ead and Lag
You would then want the program to find out which fan has been on the shortest time and which the longest. How do you find the positions of the longest and shortest times in the log?
You use the MINITEM and MAXITEM keywords:
MINITEM(FANTIME)
MAXITEM(FANTIME)
These keywords give the number of the item’s position in the log. If the minimum item (MINITEM) in the log is in position 1, MINITEM gives 1; if it is in position 2, MINITEM gives 2.
Before you use these keywords, however, you should define two local numeric variables to contain the lead and lag fan numbers:
NUMERIC LEAD, LAG
The variables are different from numeric points—they are known only to the program you create them in. You cannot use them in another program.
Because they are numeric, you can calculate with them or put the results of a calculation in them.
Now, the two numeric variables can contain the results of MINITEM and MAXITEM to determine the lead and lag:
LEAD = MINITEM(FANTIME)
LAG = MAXITEM(FANTIME)
The lead is the fan that has been running the shortest time. The lag is the one that has been running the longest.
MINITEM and MAXITEM Find Array Position
www.PDF-Zoo.com
Advanced Points
10-20 Infinity Controller Programmer’s Guide
The LEAD.LAG.FAN program should be looping. The CW.CONTROL program (presented earlier) calls it when required.
Figure 10-10 shows the program.
Figure 10-10. LEAD.LAG.FAN Program—Looping
File Edit Search Check Tools
CENTRALPLANT TOWER LEAD.LAG.FAN
SET FANTIME[1] = FANTIME[1] + (SCAN/3600 * Fan1ST)SET FANTIME[2] = FANTIME[2] + (SCAN/3600 * Fan2ST)
TURN ON Fan1TURN OFF Fan2
NUMERIC LEAD, LAG
IF MAXIMUM(FANTIME) > 24 THEN GOTO LeadLagSwap
LINE Fan1ON
LINE FanTimeChk
IF LEAD = 0 THEN LINE Decide
SET LEAD TO 1SET LAG TO 2
ENDIFIF LEAD = 1 THEN GOTO Fan1ON ELSE GOTO Fan2ON
GOTO FanTimeChk
LINE Fan2ONTURN ON Fan2TURN OFF Fan1GOTO FanTimeChk
LINE LeadLagSwapLEAD = MINITEM(FANTIME)LAG = MAXITEM(FANTIME)SET FANTIME[1] = FANTIME[1] – 24SET FANTIME[2] = FANTIME[2] – 24GOTO Decide
www.PDF-Zoo.com
Advanced Points
Infinity Controller Programmer’s Guide 10-21
Summary
• You can set up a manual array with each position representing the number of a piece of equipment. The array can then hold related information about each piece of equipment.
• To find the position of the highest value in an array, you use the MAXITEM keyword.
• To find the position of the lowest value in an array, you use the MINITEM keyword.
• You can create local numeric variables in a program. Local variables are known only to the program you create them in.
• The SCAN system variable tells you the number of seconds that have passed since the points were last updated.
SCAN System Variables Gives Scan Length
www.PDF-Zoo.com
Advanced Points
10-22 Infinity Controller Programmer’s Guide
Formi ng a Log Y ou Con trolGOAL: To set up a log that records the difference between the space temperature and the setpoint only when the outside air drops to 0 degrees Fahrenheit or lower. In addition, to record the time with each temperature.
To update a log called TEMPDIFF only when the temperature outside drops below zero, you must first setup TEMPDIFF as a log that you can control.
This type of log is called a “semi-automatic log.” You form it as follows:
1. Create the TEMPDIFF point, set its type to numeric.
2. Select Automatic Log for the log type.
3. Set the log interval to zero.
The log then updates only when your program sets the value of the log.
To use the TEMPDIFF log:
1. Evaluate the OUTSIDEAIR input.
2. If the OUTSIDEAIR value is at or below 0 degrees Fahrenheit, set TEMPDIFF to the difference between VAV.SETPT and VAVSPACE.
The controller automatically puts the new value in the TEMPDIFF[1] position in the log.
Ordinary logs automatically record the time with each log update, but semi-automatic logs do not.
3. To log the time that the temperature change is recorded, you can have a parallel log record the TEMPTIME and set that one to the DATE (or TIME) system variable value at the same time you record the TEMPDIFF.
Semi-Automatic LogsHave Log Interval of Zero
www.PDF-Zoo.com
Advanced Points
Infinity Controller Programmer’s Guide 10-23
The TEMPTIME log would be another semi-automatic log, only its type would be datetime.
Figure 10-11 shows the program with two semi-automatic logs.
Figur e 10-11. AVG.MIN.MAX Program— FallThru
In the last line of the program, the information stored in the two logs prints out on the first of every month.
Summary
• You can set a semi-automatic log that updates only when a program updates it.
• You make a log semi-automatic by setting its interval of zero.
• You use a semi-automatic log to set a datetime log to the time an event occurs.
File Edit Search Check Tools
BLDG1 FLOOR1 AVG.MIN.MAX
SET TEMPDIFF TO VAVSpace MINUS VAV.Setpt
SET TEMPTIME TO TIMEENDIF
IF OutsideAir IS LESS THAN OR EQUAL TO 0 THEN
IF DAYOFMONTH = 1 THEN RUN ZERO.REPT
’Triggered by OutsideAir
www.PDF-Zoo.com
Advanced Points
10-24 Infinity Controller Programmer’s Guide
Printing and S etting Point Attribut esGOAL: To print the basic information about a point in the Command window.
How do you find out basic information about a point? You
could select View Points from the Main menu bar, but you would see limited information. You can print any point attribute in the Command window.
Some point attributes, to refresh your memory, are:
NAME VALUE
TYPE STATE
CHANNEL UNITS
DESCRIPTION (Display) FORMAT
ENGSCALETOP ENGSCALEBOT
SETPOINT EXPORT
(Array or Log) SIZE THRESHOLD
ELECTYPE IOU
The controller sets two other important point attributes:
• OVERRIDE, equal to either TRUE or FALSE—TRUEif the override switch is set to manual, FALSE if set to AUTO (under controller control). (Not available for EMX 140 or EMX 150 outputs.)
• OVERRIDEVALUE—For voltage or current outputs, the OVERRIDEVALUE is the voltage or current you would read if you connected a meter to the point. For digital
Most Point Attr ibu tesWere Set in Windows
Two Attr ibutes Are Setby the Contro ller
www.PDF-Zoo.com
Advanced Points
Infinity Controller Programmer’s Guide 10-25
outputs, it is ON or OFF. For tristate, ON, OFF, or –ON. (Not available for EMX 150 outputs.)
To see if a point is set to manual control, print its OVERRIDE status as follows:
PRINT Burner OVERRIDE
To print the description of a point, you use the PRINT keyword, like this:
PRINT Burner DESCRIPTION
The description prints out in the window.
To find out if a temperature is a setpoint, you can also print that attribute:
PRINT TEMP.SP SETPOINT
The SETPOINT attribute is either TRUE if a setpoint or FALSE if not.
You could print the array size, like this:
PRINT SupplyAir SIZE
If you do not specify otherwise, the information prints to the local terminal’s message window. You can specify a printer name or another terminal using TO with PRINT:
PRINT Burner STATE TO SCREEN1
PRINT Fan1 DESCRIPTION TO SCREEN2
You can take other actions on attributes:
SET TEMPERATURE STATE TO ENABLED
MOVE CW1ISOValve VALUE TO 80%
SET CHW2ISOValv ENGSCALETOP TO 1
OVERRIDE At tribute Is True or False
SETPOINT Att ribute Is True or False
www.PDF-Zoo.com
Advanced Points
10-26 Infinity Controller Programmer’s Guide
SET Burner FORMAT TO "###"
SET CHW2ISOValv ENGSCALEBOT TO 0
You have control over point attributes, even in a program or on the command line. For instance, you can reset a point value or alter the top or bottom of scale for a point from within a program (as long as the point is enabled).
(You cannot set the VALUE of a point from within a program if the point is disabled. You can, however, set the VALUE of a disabled point from the Command window.)
You can even set a program’s STATUS attribute to ACTIVE to start it, INACTIVE to stop it, from the command line:
SET MORN.WARMUP STATUS TO INACTIVE
You Can Change PointAtt ributes in Programs
www.PDF-Zoo.com
Chapter 11
Programming wi thAdva nced Keywords
This chapter covers the following topics:
• Summary on Local Variables
• Acting on Errors with Local String Variables
• Changing the Status Bar
• Going to Lines Based on a Value
• Going to Lead, Lag, or Standby
• Finding the Difference between Date-and-Times
• Looping with FOR..NEXT
• Nesting FOR..NEXT Loops
• Forming WHILE Structures
• Breaking Loops
• Using the Scan Length
• Selecting Part of a Date and Time
• Determining Amount of Free Memory
• Determining the Version on a Controller
www.PDF-Zoo.com
Advanced Keywords
11-2 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-3
Table 11-1 shows the input and output points we program with in this chapter.
Table 11-1. Input and Output Points
Controller
TEMPLOG BLDG1 FLOOR1 SCX 900
Point Point Type Model
Thermistor Input
MixedAir BLDG1 FLOOR1 SCX 900 Thermistor Input
Fan1 CENTRALPLANT TOWER SCX 900 Form C Output
Fan2 CENTRALPLANT TOWER
Fan3 CENTRALPLANT TOWER
SCX 900
SCX 900
Form C Output
Form C Output
Fan1ST CENTRALPLANT TOWER SCX 900 Digital Input
Fan2ST CENTRALPLANT TOWER
Fan3ST CENTRALPLANT TOWER
SCX 900
SCX 900
Digital Input
Digital Input
www.PDF-Zoo.com
Advanced Keywords
11-4 Infinity Controller Programmer’s Guide
Summary on Loca l VariablesSometimes you need a variable to hold a value that is neither an input nor an output and only needed in one program. Such a value need not be a point at all; instead, it can be a local vari-able.
A local variable can be either a number (numeric), text (string of characters), or a date and time (datetime). You can have a total of up to 255 local variables in a single program.
Variables Vs. Points
How do numeric, string, and datetime local variables differ from numeric, string, and datetime points?
Only the program you put them in knows the local variables. You define them at the top of the program and use them only in that program. You cannot use a local variable in another program or in a function.
Numeric, string, and datetime points, however, are usable sys-tem-wide.
Below are some statements that define local variables.
NoteAlways remember to define local variables at the top of the program! If you try to define them anywhere else in the program, the program does not run.
Local Variables Belongto Particu lar Programs
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-5
Numeric Variables
The following statement defines a local numeric variable:
NUMERIC FLOORNO
The NUMERIC keyword tells the controller that the name that follows is a local numeric variable.
You can also use NUMERIC to define several numeric vari-ables at once:
NUMERIC FLOORNO, ROOMNO, SPACENO
You can form a numeric array with NUMERIC by putting the number of items in the array in square brackets after the name:
NUMERIC FLOORNO [10]
Strin g Varia bles
The following statement defines a local string variable:
STRING 40 BOILERNOTE
The STRING keyword tells the controller the following:
• The number that follows is the number of characters in the string.
• The name that follows is a variable that accepts a string of characters.
You can also use STRING to define several string variables at once:
STRING WARNING1, WARNING2, WARNING3
Numeric VariablesContain Numbers
String Variables Contain Text
www.PDF-Zoo.com
Advanced Keywords
11-6 Infinity Controller Programmer’s Guide
You can form a string array with STRING by putting the number of items in the array in square brackets after the name:
STRING WARNING [6]
DateTime Variables
The following statement defines a local datetime variable:
DATETIME TODAY
The DATETIME keyword tells the controller that the name that follows is a variable that accepts a date and time.
You can also use DATETIME to define several datetime vari-ables at once:
DATETIME MORNING, AFTERNOON, EVENING
You can form a datetime array with DATETIME by putting the number of items in the array in square brackets after the name:
DATETIME DOWNTIME [10]
DateTime Variables EachContain Date and Time
You Can Make VariablesBe Arrays
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-7
Summary
• Only the program you put them in knows the local variables you define.
• The entire controller system knows numeric, string, and datetime points.
• You must define all local variables at the top of a program—before the first program line. If you define them anywhere else, the program does not work.
• To create one or more numeric variables, use the NUMERIC keyword.
• To create one or more string variables, use the STRING keyword.
• To create one or more datetime variables, use the DATETIME keyword.
• When you define a local variable, you can make it an array by putting the number of items in square brackets after the name.
• You can give a length to a string variable. You Can Give Length fo r String
www.PDF-Zoo.com
Advanced Keywords
11-8 Infinity Controller Programmer’s Guide
Act ing on Errors with Local String Var iablesGOAL: To print a message when the number of errors is greater than 5, print another message when the number of errors is greater than 10, and sound a beep at 12 errors.
You use a system variable called ERRORS to determine how many errors have occurred in the controller.
You have already seen how to form messages in a string point, known to the entire system. You can also form messages known only to the program you form them in. They go in local string variables.
You set up a local string variable using the STRING keyword as follows:
STRING 50 ERRORMSG
This string is 50 characters long. You could put all three messages under the same string name in an array with three holding places by adding the array to the string definition like this:
STRING 50 ERRORMSG[3]
Now you can call the message ERRORMSG[1], ERRORMSG[2], and ERRORMSG[3].
To set the values of these variables, you use the SET statement:
SET ERRORMSG[1] = "One to five errors have occurred."
SET ERRORMSG[2] = "Five to ten errors have occurred."
SET ERRORMSG[3]="Twelve or more errors have occurred. |7"1
1. The vertical bar and 7 indicate an ASCII code for a beep. See Appendix Aof the Andover Controls Plain English Language Reference for more onASCII codes.
ERRORS EqualsNumber of ERRORS
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-9
All you have to do now is check the ERRORS value in an IF..THEN statement as follows:
IF ERRORS > 4 AND ERRORS <10 THEN PRINT ERRORMSG[1]
IF ERRORS > 9 AND ERRORS <12 THEN PRINT ERRORMSG[2]
IF ERRORS >= 12 THEN PRINT ERRORMSG[3]
Figure 11-1 shows the program, called ERROR.TEST.
Figure 11-1. ERROR.TEST Prog ram—FallThru
When you have many errors, you often display the number on the status bar. You can set the status bar to display the kind of information you want. See how in the next section.
Summary
• The ERRORS system variable contains the number of errors that have occurred in the controller system.
• You can create a local string variable to contain text or a message.
Check ERRORS inIF..THEN Statement
File Edit Search Check Tools
BLDG1 FLOOR1 ERROR.TEST
IF ERRORS >= 10 AND ERRORS < 12 THEN PRINT ERRORMSG[2]IF ERRORS >= 12 THEN PRINT ERRORMSG[3]
IF ERRORS >= 5 AND ERRORS < 10 THEN PRINT ERRORMSG[1]
STRING 50 ERRORMSG[3]
ERRORMSG[2] = "Ten errors have occurred."ERRORMSG[3] = "12 errors have occurred. |7"
ERRORMSG[1] = "Five errors have occurred."
’Triggered by ERRORS System Variable
www.PDF-Zoo.com
Advanced Keywords
11-10 Infinity Controller Programmer’s Guide
Changi ng the Status BarGOAL: To reset the current status bar so it shows the number of errors, current user, and other select information.
Whenever you are running the menu and window system, the bar across the bottom of the screen displays. It is called the “status bar.”
You can change the status bar so it shows the number of errors accumulated. Say you also want it to show the user name and the time.
You do this by writing a program called STAT.BAR that is set to AUTOSTART with a FLOW of looping. You place a PRINT statement in it that tells what to print in the status bar. The statement should look like the following:
PRINT "Errors: |## User: |@@@@@@@@ Time:",~ERRORS, SCREEN1 CURRENTUSER, TIME TO~SCREEN1 STATUSBAR
Let’s dissect this statement.
• The information in quotation marks prints in the status bar on the screen, except for the pound signs, which hold places for digits or characters.
• ERRORS is a system variable that prints in the first format, after Errors: .
• CURRENTUSER is the attribute that holds the logon name assigned to the user who is currently logged on. It prints in the second format in the statement, after User: .
• TIME is another system variable that displays the complete date and 24-hour time. It prints after Time: but you do not specify a format, since it prints in a standard format.
• All of this prints to a terminal called SCREEN1 and to the status bar (indicated by the STATUSBAR attribute).
You Can Change theStatus Bar
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-11
You can change the formats to allow for three digits for ERRORS or other predefined values.
You can change the variables used to ones you have defined.
You can change anything in the statement, except:
• TO
• SCREEN1 STATUSBAR (use your terminal name in place of SCREEN1)
Figure 11-2 shows a complete STAT.BAR program. You might want to put the name of the STAT.BAR program in the user window as the login program so that the program runs every time you log on.
Figure 11-2. STAT.BAR Pr ogram—Looping
Summary
• To alter the status bar, you write a program and call it STAT.BAR, make it AUTOSTART with looping FLOW.
• In STAT.BAR you put a statement that tells what to print to the status bar.
• To direct the PRINT statement to the status bar, you use TO SCREEN1 (the terminal name) STATUSBAR.
STAT.BAR Program Cont ro ls Status Bar
File Edit Search Check Tools
BLDG1 FLOOR1 STAT.BAR
PRINT "Errors: |## User: |@@@@@@@@ Time: ", ERRORS, ~CURRENTUSER, TIME, TO SCREEN1 STATUSBAR
www.PDF-Zoo.com
Advanced Keywords
11-12 Infinity Controller Programmer’s Guide
Going to Lines Based on a ValueGOAL: To print out a series of reports based on the day of the week.
One way to proceed is to check the WEEKDAY system variable and when it has a certain value, go to a line and carry out that line.
You can use GOTO or you can use BASEDON..GOTO. BASEDON..GOTO is set up to test a variable and then, based on its value, go to one of the lines listed after GOTO:
BASEDON WEEKDAY GOTO SUN.REPT, MON.REPT,~ TUE.REPT, WED.REPT, THU.REPT, FRI.REPT, SAT.REPT
If WEEKDAY is 1 (SUNDAY), the program goes to the first line label listed after GOTO (SUN.REPT); if WEEKDAY is 2, the program goes to the second line label (MON.REPT); if WEEKDAY is 3, the third line label (TUE.REPT), and so on. The values must begin with 1 and increase by 1 (increment).
BASEDON..GOTO is most useful with the system variables that increment, WEEKDAY, HOUR, MINUTE, and similar values that increment, such as the ERRORS system variable.
You Can GOTO Diff erentLines Based on a Value
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-13
Figure 11-3 shows a program that branches, based on the ERRORS value, to three different lines.
Figure 11-3. MSG.REPT Program—FallThru
File Edit Search Check Tools
BLDG1 FLOOR1 MSG.REPT
RUN MESSGPROG2LINE MSG2
BASEDON TERM1 ERRORS GOTO MSG1, MSG2, MSG3
RUN MESSGPROGLINE MSG1
RUN MESSGPROG3LINE MSG3
’Triggered by ERRORS System Variable
STOP MSG.REPT
STOP MSG.REPT
STOP MSG.REPT
www.PDF-Zoo.com
Advanced Keywords
11-14 Infinity Controller Programmer’s Guide
Figure 11-4 shows a program that prints a different report or series of reports for each day of the week, starting on Sunday (1) and proceeding through Saturday (7). Here to help you remember which day’s report it is, REPT1 prints when WEEKDAY is 1, REPT2 when WEEKDAY is 2, and so on.
Figure 11-4. DAILY.REPT Program—FallThru
GOTO Different Li nesBased on WEEKDAY
File Edit Search Check Tools
BLDG1 FLOOR1 DAILY.REPT
RUN ERROR.REPTLINE REPT2
BASEDON WEEKDAY GOTO REPT1, REPT2, REPT3, REPT4~
RUN TEMP.REPT
RUN HUMID.REPT
LINE REPT1
REPT5, REPT6, REPT7
LINE REPT3RUN MEMORY.REPT
LINE REPT4RUN COMM.REPT
LINE REPT5RUN MESG.REPT
LINE REPT6
LINE REPT7RUN WEEKLY.REPT
’Triggered by WEEKDAY
STOP DAILY.REPT
STOP DAILY.REPT
STOP DAILY.REPT
STOP DAILY.REPT
STOP DAILY.REPT
STOP DAILY.REPT
STOP DAILY.REPT
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-15
The controller automatically interprets the WEEKDAY as a number in this situation.
Summary
BASEDON..GOTO checks a variable value and if it is 1, goes to the first line listed after GOTO, if it is 2 goes to the second, if it is 3 goes to the third, and so on.
BASEDON..GOTO Goes to the Appropriate Lin e
www.PDF-Zoo.com
Advanced Keywords
11-16 Infinity Controller Programmer’s Guide
Going to Lead, Lag, or StandbyGOAL: To select the fan to turn on of the three tower fans based on the value of the LEAD and LAG variables. We restructure the LEAD.LAG.FAN program from Chapter 10 using BASEDON..GOTO.
Remember that FAN1 corresponds to the time running in FANTIME[1], FAN2 to FANTIME[2], and FAN3 to FANTIME[3].
You would leave the structure of the FANTIMECK line the same to find out how long each fan has been running. You would then find LEAD and LAG using MINITEM and MAXITEM.
But instead of using a series of IF..THEN statements, you would set up a different line for each fan and if the value of LEAD is 1, go to the FAN1 line; if LEAD is 2, go to the FAN2 line, and if LEAD is 3, go to the FAN3 line, as follows:
BASEDON LEAD GOTO TFAN1, TFAN2, TFAN3
LINE TFAN1
TURN ON Fan1
LINE TFAN2
TURN ON Fan2
LINE TFAN3
TURN ON Fan3
Since you would have to turn off the other two fans if you turned on one, you could incorporate that action in the same line. You would also then go back to check the FANTIME value once more.
GOTO Differ ent LineBased on LEAD Value
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-17
Figure 11-5 shows the changes to the program using BASEDON..GOTO (this example also has three fans instead of two).
Figure 11-5. Modified LEAD.LAG.FAN Program—Looping
BASEDON..GOTO Works Effic ient ly
File Edit Search Check Tools
CENTRALPLANT TOWER LEAD.LAG.FAN
LEAD = MINITEM(FANTIME)
NUMERIC LEAD
LINE LeadSwap
BASEDON LEAD GOTO TFAN1, TFAN2, TFAN3
TURN ON Fan1
GOTO FanTimeCk
TURN ON Fan2
LINE TFAN3
TURN OFF Fan1 AND Fan2 TURN ON Fan3
LINE TFAN2
LINE TFAN1
TURN OFF Fan1 AND Fan3
TURN OFF Fan2 AND Fan3
GOTO FANTIMECK
GOTO FANTIMECK
SET FANTIME[1] = FANTIME[1] + (SCAN/3600 * Fan1ST)
SET FANTIME[2] = FANTIME[2] + (SCAN/3600 * Fan2ST)
SET FANTIME[3] = FANTIME[3] + (SCAN/3600 * Fan3ST)
IF MAXIMUM(FANTIME) > 24 THEN GOTO LeadSwap
LINE FanTimeCk
www.PDF-Zoo.com
Advanced Keywords
11-18 Infinity Controller Programmer’s Guide
Finding t he Diff erence between Date-and-TimesGOAL: To measure the amount of time each tower fan has been on or off and send the information to a report if a fan has been on longer than seven days.
To find out how long a fan has been on if only a few seconds go by, you can use TS, TM, or other keywords that measure time elapsed on that line. But to determine that a fan has been on for seven days, you would not want keep the controller on one line for seven days.
Instead, you set a timestamp when you turn the fan on and another timestamp when you turn it off.
You create the timestamps TIMER1 and TIMER2 as local variables that contain the complete date and time of an event. You do this with the DATETIME keyword:
DATETIME TIMER1
DATETIME TIMER2
You can also create both variables on one line:
DATETIME TIMER1, TIMER2
You can measure the time a fan has been on and the time a fan has been off separately from the LEAD.LAG.FAN program by using the status inputs, FAN1ST, FAN2ST, and FAN3ST.
After you set up the variable, you write lines to set the timestamps equal to the DATE system variable:
IF Fan1ST IS ON THEN SET TIMER1 = DATE
ELSE SET TIMER2 = DATE
Timestamps Are LocalDateTime Variables
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-19
Remember that the DATE system variable contains both the date and the time.
Calculating th e Diffe rence
After the two timers are set, you can find the difference between them using the DIFFTIME function.
DIFFTIME can find the difference between two datetimestamps in seconds, minutes, hours, or days. To find the difference in days, you set up the function like this:
FAN1.ON.TIME = DIFFTIME (WKD, TIMER1, TIMER2)
The controller places the difference in a numeric variable called FAN1.ON.TIME.
The difference is always the number of whole days. If the difference is six days and 23 hours, FAN1.ON.TIME is set to 6. You could also find the difference in hours:
FAN1.ON.TIME = DIFFTIME (HOUR, TIMER1, TIMER2)
To find the difference in minutes or seconds, you would use MINUTE or SECOND in place of WKD or HOUR.
You could also find the difference in seconds using a mathematical expression:
FAN1.ON.TIME = TIMER2 MINUS TIMER1
NoteWhen calculating the difference between timers, be sure that TIMER1 occurs before TIMER2.
This kind of difference between a date and time always gives the result in seconds, no matter how large the difference. This technique is simple and direct, and useful as long as you want seconds.
DIFFTIME Is in Units You Ask For
www.PDF-Zoo.com
Advanced Keywords
11-20 Infinity Controller Programmer’s Guide
Taking Action Based on the Diffe rence
Instead of setting the difference equal to a numeric variable, you can take action based on the difference:
IF DIFFTIME(WKD,TIMER1,TIMER2)>=7 THEN RUN FANRPT
Instead of writing two statements, this way you need only one.
Figure 11-6 shows the FallThru program. It is triggered by a change in the fan status of FAN1.
Once the fan status changes to ON, the program triggers. The first IF statement is TRUE, so the controller sets the first timer to the current DATE. The second IF statement is FALSE, so the controller falls through it to the end and stops.
When the fan status changes to OFF, the program triggers again. The first IF statement is FALSE, so the controller falls through it. The second IF statement is TRUE, so the controller sets the second timer to the current DATE. The controller then checks to see if the difference between the first date and the second date is seven days. If it is, the controller prints out a fan report.
The program triggers again when the fan status changes back to ON and the first timer is set to the new DATE. The process continues with each change in fan status.
DIFFTIME CalculatesDif ference
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-21
Figure 11-6. FAN.TIMING Program—FallThru
You can copy this program multiple times; then find and replace FAN1 with FAN2 in one copy and with FAN3 in another.
If the fans are on different controllers, you can assign the copies of the program the same name.
If the fans are on the same controller, you can change the names of the copies of the program to FAN2.TIMING and FAN3.TIMING.
File Edit Search Check Tools
CENTRALPLANT TOWER FAN1.TIMING
IF Fan1ST = ON THEN SET TIMER1.FAN = DATE
DATETIME TIMER1.FAN, TIMER2.FAN
IF Fan1ST = OFF THEN
IF DIFFTIME(WKD, TIMER1.FAN, TIMER2.FAN) >= 7 THENRUN FANRPT
SET TIMER2.FAN = DATE
ENDIF
’Triggered by Fan1ST
ENDIF
www.PDF-Zoo.com
Advanced Keywords
11-22 Infinity Controller Programmer’s Guide
Looping w ith FOR..NEXTGOAL: To print all the values in a 96 item log calledMIXEDAIR.
To print a single value of the MIXEDAIR, you would write this statement:
PRINT "The mixed air temperature |###.#", MixedAir[1]
To print 96 values of the MIXEDAIR, you would not want to have to type this statement 96 times! You would, instead, use a statement called a “FOR..NEXT loop.” A FOR..NEXT statement allows you to repeat an action for a particular set of values.
LINE MIXTEMP.REPT
PRINT "The Mixed Air Temperatures for |*", DATE
FOR LOGPOS = 1 TO 96
PRINT MixedAir[LOGPOS]
NEXT LOGPOS
In this case, FOR..NEXT prints the mixed air temperature for the first log position, and the next log position, and the next log position, and so on, up to 96 positions. FOR..NEXT be-comes a real time and memory saving technique.
The line carries out the following steps:
1. Prints the heading line and fills in the date.
2. Sets LOGPOS equal to 1.
3. Prints the mixed air temperature for the LOGPOS equal to 1.
4. Repeats step 3 for the next log position, where LOGPOS equals 2.
Print Values Stored in anArray with FOR..NEXT
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-23
5. Repeats step 3 for LOGPOS equal to 3, then 4, then 5 and so on, up to 96.
6. Goes to the next program line in a FallThru program.
You can also repeat an action for values that do not count 1, 2, 3, but instead count by 3, 5, 7, 10, 20, or any other differ-ence. To do so, you add STEP to the end of FOR portion of the statement, like this:
FOR COUNT = 5 TO 50 STEP 5
STEP tells the controller to put the values 5, 10, 15, 20, 25, and so on into the COUNT variable.
Counting by 5 might come in handy when you want to print a report based on the number of errors being equal to 5, 10, or 15.
LINE TEST.REPT
FOR COUNT = 5 TO 15 STEP 5
IF ERRORS = COUNT THEN RUN ERR.REPT
NEXT COUNT
Local Variabl e/Index Variable
Before you can write the program, remember that the control-ler needs to know all your points and all other names. What about LOGPOS? It is not a point and not the name of an In-finity CX 9000 controller.
Because the LOGPOS is neither an input nor an output, it need not even be a point. It can, instead, be a “local variable.” Remember, local variables are known only to the program you use them in.
FOR..NEXT Loop Can Count by More Than One
www.PDF-Zoo.com
Advanced Keywords
11-24 Infinity Controller Programmer’s Guide
Since the LOGPOS variable contains a number, you must make it a numeric variable:
NUMERIC LOGPOS
Inside a FOR..NEXT loop, the LOGPOS local numeric vari-able is called the “index” variable.
The program also remains FallThru , since once the loop is complete, the program ends.
As shown in Figure 11-7, you give all variable names at the top of the program.
Figure 11-7. Modified MIXED.REPT Program—FallThru
Variable in FOR..NEXTLoop Is Numeric
File Edit Search Check Tools
BLDG1 FLOOR1 MIXED.REPT
NUMERIC LOGPOS
LINE MIXTEMP.REPT
PRINT "The Mixed Air Temperatures for |*", DATE
FOR LOGPOS = 1 TO 96
PRINT MixedAirT[LOGPOS]
NEXT LOGPOS
’Triggered by WEEKDAY
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-25
Summary
• You use the FOR..NEXT statement to carry out a statement or statements a set number of times.
• All the statements between FOR and NEXT are carried out for each value of the numeric variable.
• You create a numeric variable and give it a name using the NUMERIC keyword. Inside the FOR..NEXT loop this variable is called the index variable.
• You use a numeric variable rather than a numeric point, because the value applies only to the current program.
• Even with a loop built into a program, the program can still be FallThru if it should end after all actions have occurred.
You Can Use FOR..NEXT in FallThru Program
www.PDF-Zoo.com
Advanced Keywords
11-26 Infinity Controller Programmer’s Guide
Nesting FOR..NE XT LoopsGOAL: To find the average outside air temperature for each day and print a report on averages. Then expand the program to find the average outside air temperature for each quarter of the day and print a report on the four averages for the day.
Start by setting up a FOR..NEXT loop that adds up the elements in a log called TEMPLOG. TEMPLOG contains 24 values—one temperature for each hour in a day.
FOR Element = 1 TO 24TOTAL = TOTAL + TEMPLOG[Element]
NEXT Element
Figure 11-8 shows the program.
Figure 11-8. DAILY.AVG Program—FallThru
The program then finds the average as follows:
AverTemp = TOTAL / 24
Add Up Elements in aLog with FOR..NEXT
File Edit Search Check Tools
BLDG1 FLOOR1 DAILY.AVG
TOTAL = 0
FOR Element = 1 TO 24TOTAL = TOTAL + TEMPLOG[Element]
NEXT ElementAverTemp = TOTAL / 24
NUMERIC TOTAL, Element
’Triggered by WEEKDAY
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-27
To calculate similar results for every quarter of the day, you can use two FOR..NEXT loops.
Here is the first loop:
FOR EndQuarter = 6 TO 24 Step 6...NEXT EndQuarter
Here is the second loop:
FOR Element = StartQuarter to EndQuarterTotal = Total + TempLog[element]
NEXT Element
How do you make these two loops work together? To make these two loops work together, you put one inside the other.
Putting one loop inside another is called “nesting” loops and the loops are called “nested loops.” You nest the loops as shown below (FOR and NEXT are bold so you can easily find them):
FOR EndQuarter = 6 To 24 Step 6FOR Element = (StartQuarter + 1) To EndQuarter
Total = Total + TempLog[element]NEXT ElementAverTemp = Total/6PRINT "Ave Temp is |##.##", AverTempSet StartQuarter = EndQuarter
NEXT EndQuarter
Notice how the second loop is indented inside the first.
Before you proceed to analyze how the loops work, you need to look more closely at exactly what the loops are trying to calculate.
Nesting Lo ops Is Put ting One Inside Another
www.PDF-Zoo.com
Advanced Keywords
11-28 Infinity Controller Programmer’s Guide
Taking a Closer Lo ok at the Purposeof the Nested Loops
Figure 11-9 illustrates quarters of the day that the program averages. Remember the first element in a log is always the last value logged. So, for instance, the first quarter totaled is from 6 p.m. to midnight (the last quarter of the day). The first FOR..NEXT loop (the “outside” loop) always adds 6 to the ENDQUARTER index variable.
Figur e 11-9. Quarters of the Day Averaged by Quarterl y.Avg Program
The program is triggered by the WEEKDAY system variable. When the day changes, the program uses all of the values stored in TEMPLOG from the previous 24 hours. It always adds up six values in the inside loop and then divides by 6 to find the average. The next time it loops, the program then pro-ceeds to add up the next 6 values.
Follow ing First Time through Loop
Before the loop, you set STARTQUARTER to 0, as follows:
StartQuarter = 0
When the action begins, the outside FOR..NEXT loop sets ENDQUARTER to 6 the first time it loops.
0 6 12 18 24
Value ofEndQuarter
You use STEP 6 to set the number of hoursto add to the value of EndQuarter at thebeginning of the outside loop.
6 p.m. to Noon to 6 p.m. 6 a.m. to Noon Midnightto 6 a.m.
Totals Log Totals Log
Average Temperature for Each Quarter of the Day
Elements 1 – 6 Elements 7 – 12Totals Log
Elements 13 – 18Totals Log
Elements 19 – 24
Midnight
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-29
Figure 11-10 shows how the STARTQUARTER is 0 and the ENDQUARTER is 6 for the first quarter of the day to be averaged.
Figur e 11-10. Values of StartQ uarte r and EndQ uarter for First Quarter of the Day
Since the first setting of STARTQUARTER is 0, the inside FOR NEXT loop must add 1 to STARTQUARTER to begin with the first element in the TEMPLOG:
For Element = (StartQuarter + 1) to EndQuarter...
The inside FOR..NEXT loop then adds up the temperatures for the first six values in the log, starting with STARTQUAR-TER + 1 (0 + 1), which is 1, and finishing with ENDQUARTER, which is 6. Without the outside loop, the in-side loop does not know the value of ENDQUARTER. So, you can see how the two loops work together.
FOR EndQuarter = 6 TO 24 Step 6FOR Element = (StartQuarter + 1) to EndQuarter
Total = Total + TempLog[element]NEXT ElementAverTemp = Total/6PRINT "Ave Temp is |##.##", AverTempSet StartQuarter = EndQuarter
NEXT EndQuarter
0 6 12
6 p.m. to Noon to 6 p.m.
Elements 1–6 Elements 7–12
Midnight
StartQuarterFirst TimeThrough Loops
QuarterFirst Time Through LoopsBecomes StartQuarterfor Second Time Through Loops
Set Values of StartQuar-ter and EndQuarter
www.PDF-Zoo.com
Advanced Keywords
11-30 Infinity Controller Programmer’s Guide
The outside loop now finds the average by dividing the total by 6.
Before the outside loop starts over, it sets STARTQUARTER to the value of ENDQUARTER, so that when the inside loop starts again, STARTQUARTER is 6.
Set StartQuarter = EndQuarter
Follow ing Secon d Time throu gh Lo op
Figure 11-11 shows the complete program, so you can follow along with the description.
Figur e 11-11. Quarterly.Avg Program— FallThru
At the beginning of the outside loop once again, the outside loop sets ENDQUARTER using STEP. STEP indicates how much the outside loop should “count by.” In this case STEP 6 indicates that the loop should add 6 to the value of END-QUARTER, so it becomes 12.
FOR EndQuarter = 6 TO 24 Step 6
AverTemp = TOTAL /6
TOTAL = 0
NEXT EndQuarter
BLDG1 FLOOR1 Quarterly.Avg
NUMERIC EndQuarter, StartQuarter, Total, Element, AverTemp
FOR Element = ( StartQuarter + 1) TO EndQuarterTOTAL = TOTAL + TempLog[Element]
NEXT Element
PRINT "Ave Temp is |##.##", AverTemp
’Triggered by Weekday
Set StartQuarter = EndQuarter
StartQuarter = 0
File Edit Search Check Tools
InsideLoopTotalsValues
Outside LoopFinds the Averageand Prints It, ThenSets StartQuarter
You Indi cate Number ofSteps When “C ount ing ”
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-31
So when the inside loop begins to add up temperatures from the second quarter of the day, it starts with STARTQUAR-TER set to 6 and ENDQUARTER set to 12.
Figure 11-12 shows how the STARTQUARTER is 6 and the ENDQUARTER is 12 for the second quarter of the day to be averaged.
Figur e 11-12. Values of StartQ uarte r and EndQ uarter for Second Q uarter of t he Day
Since the elements of TEMPLOG that contain the values for the second quarter of the day are elements 7 through 12, at the top of the inside loop, you add 1 to STARTQUARTER, so it becomes 7.
Now the inside loop totals the values of elements 7 through 12 and the outside loop averages them. After it prints the aver-age, the outside loop sets STARTQUARTER to the current value of ENDQUARTER once more, so it becomes 12 this time.
The third time through the loop, the process repeats, with ENDQUARTER set to 18 and STARTQUARTER set to 12.
0 6 12
6 p.m. to Noon to 6 p.m.
Elements 1–6 Elements 7–12
Midnight
StartQuarterSecond TimeThrough Loops
EndQuarter SecondTime Through LoopsBecomes StartQuarterfor Third Time ThroughLoops
Loop Totals Rangeof Values
www.PDF-Zoo.com
Advanced Keywords
11-32 Infinity Controller Programmer’s Guide
Understan ding STEP
By “stepping” 6 in the outside loop, you have the FOR..NEXT loops retrieve elements in the TEMPLOG up to the 6th element, then up to the 12th, the 18th, and the 24th. This way, the inside loop can use the first six elements the first time it loops, the second six elements the second time it loops, the third six elements the third time it loops, and finally, the fourth six elements the last time it loops.
To average the temperatures every 3 hours instead of every 6, you could STEP 3. The program would otherwise be the same.
Other Ways of Nes ting Loops
You can also use a FOR..NEXT loop inside an IF..THEN statement and an IF..THEN statement inside a FOR..NEXT loop.
For example, if you want the temperature averaged once a day only if the current temperature has exceeded the setpoint, you would put the FOR..NEXT loop inside an IF..THEN state-ment as follows:
IF TempLog > 80 THENFOR Element = 1 to 24
Total = Total + TempLog[Element]NEXT Element
ENDIF
If you want to add the temperature to the total only if the tem-perature is not more than 3 degrees away from setpoint, you
Can Nest FOR..NEXTLoop insid e IF..THEN
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-33
can put the IF..THEN statement inside the FOR..NEXT loop as follows:
FOR Elem = 1 to 24If Abs(TempLog[Elem]) –TempLog[Elem] > 3 Then
Total = Total + TempLog[Element]Endif
NEXT Elem
Summary
• You can create more than one numeric variable in one NUMERIC statement.
• You can use nested FOR..NEXT statements, putting one FOR..NEXT loop inside another.
• You can use STEP 6 to have a FOR..NEXT loop retrieve every sixth element from the array. Similarly, you can use STEP 2, STEP 3, or and other number of steps that seems appropriate.
• You can use STEP 10 (or any other number with STEP) to set a limit on the range of elements to retrieve from the array.
• You can put a FOR..NEXT loop inside an IF..THEN statement.
• You can put an IF..THEN statement inside a FOR..NEXT loop.
STEP Specifies LogElements to Retr ieve
www.PDF-Zoo.com
Advanced Keywords
11-34 Infinity Controller Programmer’s Guide
Formi ng WHILE StructuresGOAL: To set all the values of a 96 item array called TIMER to zero.
To tell the controller to take action while a TRUE-FALSE comparison is TRUE, you can use a WHILE loop. WHILE loops work like this:
COUNT = 0
WHILE COUNT IS LESS THAN 97
SET TIMER1[COUNT] = 0
SET COUNT = COUNT + 1
ENDWHILE
This loop continues to carry out the action as long as the COUNT is less than 97.
Notice that you close the WHILE loop with ENDWHILE, just as you close an IF statement with ENDIF.
WHILE loops are most useful in working with data files. For an example of WHILE with a data file, see Chapter 13.
WHILE Does ActionWhile Statement Is True
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-35
Figure 11-13 shows the program.
Figure 11-13. AVG.EXC.SP Prog ram—FallThru
Summary
• A WHILE loop carries out the actions inside the loop WHILE the TRUE-FALSE comparison is TRUE.
• A WHILE loop always ends with ENDWHILE.
• WHILE loops are useful in working with data files.
File Edit Search Check Tools
WHILE COUNT IS LESS THAN 97
SET TIMER1[COUNT] = 0
BLDG1 FLR1VAV1 AVG.EXC.SP
SET COUNT = COUNT + 1
ENDWHILE
NUMERIC COUNT
’Triggered by HOUR
WHILE Loops Alwa ys End wit h ENDWHILE
www.PDF-Zoo.com
Advanced Keywords
11-36 Infinity Controller Programmer’s Guide
Breaking LoopsGOAL: To loop through an array of average temperatures. If you find a value 2 degrees or more over the setpoint, print a message on that room and stop looping.
To plan ahead for this program, you would set up an array so its index numbers correspond to the room numbers on that floor.
VAVSPACE.AVG[1] would be the value of the averagetemperature for room 1, where the first VAV box is.VAVSPACE.AVG has 30 values. You can loop through itusing FOR..NEXT.
The controller stops the loop in the middle when you use the BREAK keyword. BREAK ends the nearest enclosing FOR..NEXT, WHILE, or REPEAT..UNTIL loop and exits to the next statement.
Figure 11-14 shows the program.
Figure 11-14. Breaking the FOR..NEXT Loop in the AVGSETPOINT Progr am—FallThru
Break Lo op with BREAK
File Edit Search Check Tools
FOR ROOM = 1 TO 30
ENDIF
IF VAVSpace.AVG[ROOM] >= VAVSpace.SP + 2 THEN
NEXT ROOM
BLDG1 FLR1VAV1 AVGSetPoint
SET STORE.RM = ROOM
BREAKPRINT "ROOM |##’s temp exceeds the setpoint",STORE.RM
NUMERIC ROOM
’Triggered by HOUR
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-37
If the loop you break out of is nested inside another, the other loop continues to completion. BREAK only ends the particu-lar loop it is inside of.
Notice that in the sample loop, you store the ROOM value in another variable before breaking. Once you use BREAK, the index variable automatically resets to 1, so use the index vari-able before BREAK if you need to save it.
Summary
• You break out of a loop before it is complete using the BREAK keyword.
• BREAK exits the loop and takes the controller to the next consecutive statement.
• You can use BREAK with FOR..NEXT, WHILE, or REPEAT..UNTIL loops.
WHILE Loops Are Useful with Data Files
www.PDF-Zoo.com
Advanced Keywords
11-38 Infinity Controller Programmer’s Guide
Using th e Scan Lengt hGOAL: To accrue time using the SCAN system variable.
The SCAN system variable measures the length of the last scan interval to an accuracy of .01 seconds.
One way to accrue the time in a numeric variable called ACCUMTIME is as follows:
ACCUMTIME = SupplyFanST TIMES SCAN PLUS ACCUMTIME
The SUPPLYFANST is a point that indicates the equipment is ON or OFF. If the equipment is ON, the fan’s status is 1, if OFF, the status is 0. So this calculation adds the value of the scan to the accumulated time only when the fan is 1 (ON). If the equipment is OFF (0), SUPPLYFANST TIMES SCAN gives 0, so nothing is added to the accumulated time.
(Remember that the multiplication occurs first, so there is no danger of ACCUMTIME being wiped out by multiplying by zero.)
Ano ther Way to Use SCAN
Another way you can use SCAN is to determine the rate of de-mand for kilowatts for the last 30 minutes. You could use a digital filter equation. The following equation gives the de-mand in kilowatts for a 30-minute sliding window:
DEMAND = CONV.CONST * KWH.Pulses * .001278 * 3600 + ((1 – (SCAN * .001278)) * DEMAND)
The DEMAND is the total number of kilowatts.
SCAN Measures Lengthof Last Scan
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-39
The complete equation to calculate the demand is made up of two addends. The first calculates the demand rate in kilowatts for one scan, as follows:
CONV.CONST * KWH.Pulses * .001278 * 3600
• CONV.CONST is the conversion constant, in kwh/pulse, for the electrical meter being used to read the kilowatt hours.
• KWH.PULSES is the number of pulses the meter counts in the current scan. (Pulses are counted per scan.)
• .001278 is a time constant for a 30-minute interval.
When you multiply the conversion constant times the number of pulses counted, then times the time constant, you get the demand in kilowatts per hour for one scan.
• Multiplying by 3600 converts kilowatt hours to seconds.
When you add the demand of the current scan to the 30-minute interval, to keep the interval 30 minutes, you must also subtract an equal amount that represents the scan that oc-curred before the 30-minute interval.
Figure 11-15 shows the 30-minute interval of time in a window that slides along a continuum of time. The window is called a “sliding window.” As you slide the window up the continuum, you add new scans and remove “old” scans.
Figure 11-15. 30-Minute Sliding Window
Sliding Window for 30-Minute Interval
Scans of Time
www.PDF-Zoo.com
Advanced Keywords
11-40 Infinity Controller Programmer’s Guide
Figure 11-16 shows how each time you add one scan’s demand to the interval you must remove an equivalent scan’s demand.
Figure 11-16. Main taining the 30-Minute Interval wit h a Slid ing Window
The second addend removes the amount of demand accrued in the scan at the beginning of the 30-minute interval, as follows:
((1 – (SCAN * .001278)) * DEMAND)
• The 1 represents the 30-minute interval of demand as a whole.
• SCAN times the time constant (.001278) gives the fraction of the interval that the scan that preceded the interval equals. The equation subtracts that scan from the whole 30-minute interval (1).
The result of subtracting the scan from 30-minute interval is the total of the lengths of all the other scans in the interval.
• You multiply this total length of all scans in the interval by the present DEMAND to give the new DEMAND.
Demand duringScan Being Addedto Interval (Entering Window)
Demand during ScanBeing Removedfrom Interval
Sliding Window for 30-Minute Interval
(Leaving Window))
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-41
When you add the two addends, the result is the total kilowatts for the current scan plus the demand accrued for the previous scans in the 30-minute interval.
Summary
• SCAN measures the length of the last scan interval.
• You can use SCAN in a variety of HVAC calculations. You Can Use SCAN in Many Calculations
www.PDF-Zoo.com
Advanced Keywords
11-42 Infinity Controller Programmer’s Guide
Selecting Part of a Dat e and TimeGOAL: To print the date from several datestamps and the time from several timestamps for a report.
The entire date and time are always stored together in any datetime point or variable. You can pull out the various parts of the date and time from a log like TIMER1 using the TIMEPIECE keyword:
MONTHSTAMP = TIMEPIECE (MONTH, TIMER1)
DOMSTAMP = TIMEPIECE (DAYOFMONTH, TIMER1)
YEARSTAMP = TIMEPIECE (YEAR, TIMER1)
TODSTAMP = TIMEPIECE (TOD, TIMER1)
The various pieces of the date and time are now separated, so you can print them in a report that does not require both date and time together.
You can use any of the datetime system variables, except, of course, DATE.
TIMEPIECE Pulls OutPart of DateTime
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-43
Figure 11-17 shows a program that retrieves the parts of the date and time from a datetime log and then prints them in formats.
Figure 11-17. AVGSetptPR Program—FallThru
Retr ieves Parts of Date and Time
File Edit Search Check Tools
SET MONTHSTAMP = TIMEPIECE(MONTH, TIMER1[NUM])
SET DOMSTAMP = TIMEPIECE(DOM, TIMER1[NUM])
BLDG1 FLR1VAV1 AVGSetptPR
SET YEARSTAMP = TIMEPIECE(YEAR, TIMER1[NUM])
SET TODSTAMP = TIMEPIECE(TOD, TIMER1[NUM])
PRINT MONTHSTAMP;
NUMERIC, MONTHSTAMP, DOMSTAMP, YEARSTAMP, TODSTAMP
PRINT " ";
PRINT DOMSTAMP;
PRINT ", ";
PRINT YEARSTAMP
PRINT " ";
PRINT TODSTAMP
FOR NUM = 1 TO 10
NEXT NUM
www.PDF-Zoo.com
Advanced Keywords
11-44 Infinity Controller Programmer’s Guide
Determining Amount of Free MemoryGOAL: To determine whether or not you have room in mem-ory to add another program.
Go to the Command window and enter the following com-mand line:
P FREEMEM
The largest number of consecutive bytes of memory available prints on the screen:
FREEMEM = 21086
To determine how many bytes of memory are required to en-ter your program, you can open a Command window from inside the program file (see Chapter 9 for how) and enter this command:
PR MORNING.WARM FILESIZE
This command prints the number of bytes in memory the MORNING.WARM program file takes up. The FILESIZE at-tribute is equal to the number of bytes a program requires. The controller prints a response like this:
MORNING.WARM Filesize = 101
The program requires 101 bytes. If you have enough room in memory, you can continue to add to the program.
FREEMEM ContainsNumber of Bytes
www.PDF-Zoo.com
Advanced Keywords
Infinity Controller Programmer’s Guide 11-45
Determining the Versionon a Cont rollerGOAL: To determine which version of Infinity CX software is running on any controller on the EnergyNet.
If you run into a problem with a program and call the Andover Controls customer support office, you may be asked the ver-sion of Infinity CX that is running on your controller.
If you do not know which version is on the controller, go to the Command window and enter the following command:
P BLDG1 VERSION
(You would use, of course, the name of your controller in-stead of BLDG1.)
The version number prints on the screen as follows:
VERSION = 1.0
The version may be different for different controllers on the EnergyNet.
Find Out Version of Infinity CX
www.PDF-Zoo.com
Advanced Keywords
11-46 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Chapter 12
Defining YourOwn Functions
This chapter covers the following topics:
• Understanding Categories of Keywords—Including Functions
• Understanding the Purpose of Functions
• Determining You Need a Customized Function
• Creating a Function File
• Setting Attributes of a Function File
• Forming an Occupancy Function
• Using Arguments in a Function
• Forming a Start-Stop Function
www.PDF-Zoo.com
Defining Your Own Functions
12-2 Infinity Controller Programmer’s Guide
Under standing Cat egories of Keywords—Includi ng FunctionsEvery word in the Andover Controls Plain English language is a keyword. Keywords can also be particular types.
The types and some examples of each are as follows:
• Statements—Action words such as MOVE, TURN, PRINT, GOTO that tell the controller to do something
• Operators—IS, OR, AND
• System Variables—MONTH, DAYOFMONTH, YEAR
• System Constants—ON, OFF, PASSED
• Programmable System Variables (discussed in future chapters)—CPUPOWER, MODEMPOWER
• Functions—MINIMUM, MAXIMUM, SUM
In the Andover Controls Plain English Language Reference you find that every keyword is assigned to a category, listed below its name in the complete command and keyword description.
A hierarchy illustrates the relationships:
Keywords
Statements
Operators
System Variables
System Constants
Programmable System Variables
Functions (predefined)
Keywo rds Belo ng inCategories
www.PDF-Zoo.com
Defining Your Own Functions
Infinity Controller Programmer’s Guide 12-3
All Andover Controls Plain English words are keywords.
A statement always contains one statement word. You can write a statement that contains operators, system variables, system constants, or programmable system variables.
You can use a predefined function in a statement. For instance, in the statement below, you use the MAXIMUM function:
PRINT THE MAXIMUM (Room1Temp, Room2Temp)
Summary
• All Andover Controls Plain English words are keywords.
• Statements are action keywords that you use to form program statements.
• Statements can contain other types of keywords, such as system variables and operators, even functions.
• Functions can form statements without another statement type keyword.
• MINIMUM, MAXIMUM, and SUM are examples of predefined functions.
Statements Can Contain Other Keyword Types
www.PDF-Zoo.com
Defining Your Own Functions
12-4 Infinity Controller Programmer’s Guide
Under standing the P urpose of FunctionsYou use a function to carry out a particular task or calculation and come up with a value or set of values.
An example of a function is the square root function, carried out by the SQRT keyword:
SQRT(25)
A function is usually followed by parentheses, often with one or more values inside them (although sometimes with no values). The function acts on that value to obtain a result.
Any program can use a function. When a program uses a function, the program “calls” the function.
The function is said to “return” the resulting value because it brings the value back to the calling program. SQRT(25) returns 5.
To call a function, you should set a numeric point equal to the result of the function, as follows:
SET ROOT = SQRT(25)
Or you can simply print the result of the function:
PRINT SQRT(25)
The controller has many predefined functions, all of them advanced keywords. Some of them are mathematical, such as SUM, AVERAGE, MINIMUM, and MAXIMUM, designed to be used with logs and presented in Chapter 8.
Other functions are for looking up values in data files (see Chapter 13), still others for advanced math and advanced string functions (see Chapter 18).
Funct ions Carry OutTasks o r Calcu latio ns
www.PDF-Zoo.com
Defining Your Own Functions
Infinity Controller Programmer’s Guide 12-5
Summary
• A function carries out a particular task or calculation.
• A function is usually followed by parentheses, with or without a value inside them.
• We say a program “calls” a function.
• We say a function “returns” a result.
• The controller has many types of predefined functions, some data file, some mathematical, and some string functions.
Functions Usually Have Parenth eses
www.PDF-Zoo.com
Defining Your Own Functions
12-6 Infinity Controller Programmer’s Guide
Determining Y ou Need a Customiz ed FunctionIf a calculation or process is complex enough and you use it often enough, you do not want to have to type it in many times. Instead, you type it once, in a function file. You then use the function like a customized keyword whenever you need it—in programs or command lines. You can use the function only on the controller it resides on; however, you may copy the same function to many controllers.
To determine you need a function, look at the kinds of actions you repeat:
• You frequently test for occupancy.
• You start and stop different pieces of equipment on the basis of the same or related information.
In each case, you can avoid repetitions in programs by creating a function to do that task whenever you need it.
The first few steps to writing a function are different from those to write a program. They are:
1. Define the task or calculation you want to carry out.
2. Define the values you want to bring in to the task or calculation.
3. Define the values you want the task or calculation to return.
After that you proceed just as you would to write a program.
Functions AreCustomized Keywords
www.PDF-Zoo.com
Defining Your Own Functions
Infinity Controller Programmer’s Guide 12-7
Summary
• Writing a function is like creating your own keyword.
• You use a function to avoid repeating a procedure or calculation in more than one program.
• You can use a function whenever you need it in programs or command lines.
• You must use the function on the controller it is located on.
• Before you write a function, you must:
• Define the task or calculation.
• Define the values you want to use.
• Determine the values you want to return.
You Can Call Funct ions Whenever Needed
www.PDF-Zoo.com
Defining Your Own Functions
12-8 Infinity Controller Programmer’s Guide
Creating a Function FileTo create a function file, you proceed just as you would to create any other file.
As shown in Figure 12-1, from the Main menu bar, you select Edit Files .
Figure 12-1. Selec ting Edit Files f rom the Menu
Figure 12-2 shows the Open a File window that appears on your screen. The cursor is in the Name text box. You press the NEXT ATTRIBUTE key to move from text box to text box. (Press the PREVIOUS ATTRIBUTE key to move backwards.)
Select Edit Files from theMain Menu Bar
View Edit Connect Logout
UsersPointsFilesCommPortsControllerInfinet ControllerSystem Date & TimeSystem VariablesPersonsAreasDoors
www.PDF-Zoo.com
Defining Your Own Functions
Infinity Controller Programmer’s Guide 12-9
Figure 12-2. Open a File Window
1. To name the function file, type the name of a new function. This name later becomes a keyword that you use to activate the function. The name can have up to 16 characters and must begin with a letter of the alphabet. You can include underscores, periods, and numbers in the name.
2. Press the EXECUTE key to proceed.
Controller
View Edit Connect Logout
Open a File
Infinet Ctlr
Name
www.PDF-Zoo.com
Defining Your Own Functions
12-10 Infinity Controller Programmer’s Guide
Sett ing At tributes of a Function F ileAs shown in Figure 12-3, as soon as you have named your file, the File Configuration window appears.
Figure 12-3. File Configuration Window
You press the NEXT ATTRIBUTE key to move from text box to text box. (Press the PREVIOUS ATTRIBUTE key to move backwards.)
You set file attributes as follows:
1. Name—Change it if you want. If you change the name here, the new name replaces the old name for that function, just as for a point or program. Remember, this name becomes the keyword you later use to call the function. See previous page for characters allowed.
2. Description —Type one in the text box if you want. It is optional.
Edit View Connect Logout
Name Description
( ) Program
(X) Function
( ) Data
Type
OCCUPANCY Decides if occupied
File Configuration – BLDG1 FLOOR1
CANCEL
DELETE
DETAILS
SAVE
( ) Report
(X) Command Line
Select Funct ion in FileConfiguration Window
www.PDF-Zoo.com
Defining Your Own Functions
Infinity Controller Programmer’s Guide 12-11
3. Type—Arrow to Function and press the space bar. This file is a function file.
4. CommandLine —Press the space bar to toggle this ON if you want to be able to run this function from the Command window by typing only the “command” (function) name.
5. Move to the SAVE button and press the EXECUTE key. Or press the EXECUTE key from any other text box in the window to save. Or press the SAVE key to save the file configuration information and enter the Editor window.
6. You can press the CANCEL button and start over or press the DELETE button to remove the file.
Summary
• You set function file attributes in the File Configuration window.
• You can move to the editor with the SAVE button, or press the EXECUTE key or SAVE key.
• You can cancel or delete the function using the CANCEL or DELETE buttons.
Select Funct ion File as File Type
www.PDF-Zoo.com
Defining Your Own Functions
12-12 Infinity Controller Programmer’s Guide
Formi ng an Occupancy FunctionGOAL: To determine whether or not the building is occupied and return ON if it is and OFF it is not. Occupancy is based on the time of day and day of the week.
According to the sequence of operation, whether the building is occupied or not is the basis for many changes in operation, so it is a good idea to make it a function.
In the Open a File window, name the file OCCUPANCY.
Later, after you press the SAVE button in the File Configuration window, the Editor window appears, just as it does for a program.
Writing the Function
Suppose the building is normally occupied between 8:00 a.m. and 7:00 p.m. Monday through Friday, but only until 1:00 p.m. on Saturday. The TRUE-FALSE comparisons and statements required to create this function are very straightforward.
The first one would test for Monday through Saturday:
IF WEEKDAY IS MON THRU SAT THEN...
You would then use a nested IF to select the time for Monday through Friday:
IF WEEKDAY IS MON THRU SAT THEN
IF WEEKDAY IS MON THRU FRI AND TOD IS ~800 THRU 1900 THEN SET OCCUPIED TO ON
Occupancy Is Bas is fo rMany Actions
www.PDF-Zoo.com
Defining Your Own Functions
Infinity Controller Programmer’s Guide 12-13
You then use another nested IF to test for Saturday and set OCCUPIED to ON for before 1:00 p.m. and to OFF for after:
IF WEEKDAY IS MON THRU SAT THEN
IF WEEKDAY IS MON THRU FRI AND TOD IS~800 THRU 1900 THEN SET OCCUPIED TO ON
ELSE
IF WEEKDAY IS SAT AND TOD IS 800 THRU 1300 THEN~SET OCCUPIED TO ON
ELSE SET OCCUPIED TO OFF
Finally, you would complete the first IF..THEN statement with a closing ELSE that tells what to set OCCUPIED to when the day is not Monday through Saturday:
ELSE SET OCCUPIED TO OFF
A major difference between a function and a program is that the function is always FallThru , which means it proceeds sequentially. You cannot use LINE statements or GOTO in a function.
Sending Result B ack to Calli ng Program
Finally, to complete the function, you have to return to the calling program with the value of the function. To carry out this action you need a new keyword: RETURN
RETURN carries out two actions:
• Returns the controller to the calling program.
• Brings the value you designate to the calling program.
Nest IF..THEN by Putting One Inside Another
www.PDF-Zoo.com
Defining Your Own Functions
12-14 Infinity Controller Programmer’s Guide
You enter a RETURN statement like this:
RETURN OCCUPIED
RETURN is usually the last statement in the function.
The value being returned occurs after RETURN. Since OCCUPIED is a numeric point equal to either ON or OFF, the program that receives the returned value gets ON or OFF for OCCUPANCY.
You may return with no values by using simply:
RETURN
Figure 12-4 shows the entire function file. Notice that in this example, you do not see ELSE ending an IF..THEN state-ment. Whenever you use nested IFs, to keep the structure of the IF..THEN clear, use ENDIF in your statements.
To see if OCCUPANCY is working properly, insert a PR statement inside the function to print OCCUPIED. When you call the function in a program, any PR and PRINT statements print information in the Message window.
If you, however, call the function from the Command window, its PR and PRINT statements print the information in the Command window.
Calling the Fu nctio n from a Program
The programs that call OCCUPANCY may include one of the following statements:
IF OCCUPANCY() IS ON THEN...
OR
IF OutsideAir < 40 AND OCCUPANCY() IS ON THEN...
RETURN Is the LastStatement in a Function
www.PDF-Zoo.com
Defining Your Own Functions
Infinity Controller Programmer’s Guide 12-15
Figure 12-4. OCCUPANCY Function
Calling the Functio n from the Command Window
You can also call OCCUPANCY from the Command window, as follows:
OCCUPANCY1
The following response prints in the Command window:
OCCUPIED = ON
1. In this case, you do not need the parentheses, because OCCUPANCY is thefirst word in the command line. The same is true in a program statement—parentheses are not required if the function is the first word in a statement,even after THEN or ELSE.
File Edit Search Check Tools
BLDG1 FLOOR1 OCCUPANCY
IF WEEKDAY IS MON THRU SAT THENIF WKD IS MON THRU FRI AND TOD IS 800 THRU 1900 THEN
SET OCCUPIED TO ON
IF WKD IS SAT AND TOD IS 800 THRU 1300 THEN
ELSE
ELSE
RETURN OCCUPIEDPR OCCUPIED
ELSE
ENDIF
OCCUPIED = ON
OCCUPIED = OFF
ENDIF
SET OCCUPIED TO OFFENDIF
Commands Can UseFunctions
www.PDF-Zoo.com
Defining Your Own Functions
12-16 Infinity Controller Programmer’s Guide
How Functio n Makes Program More Effi cien t
The HEAT.NOHEAT program you wrote earlier had a test for if the day of the week was Sunday.
As shown in Figure 12-5, using the OCCUPANCY function more easily tests for occupied or not, without forcing you to rewrite the entire program.
Figure 12-5. Modi fied HEAT.NOHEAT Program—Loop ing
File Edit Search Check Tools
LINE NOTHEATINGIF THE OutsideAir < 50 THEN GOTO START.BURNER
TURN OFF THE Burner AND THE HWPump1
ENDIF
LINE START.BURNER
OPEN THE HWP1ISOValve
CENTRALPLANT HEAT.NOHEAT
ELSE
TURN ON THE Burner IF TM > 3 THEN
LINE ADJUSTING
IF THE OutsideAir > 50 AND TM > 3 THEN GOTO NOTHEATING
IF OCCUPANCY() IS ON THEN SET THE HWsetpt TO 130 ELSE SET THE HWsetpt TO 100
CLOSE THE HWP1ISOValve AND THE CONVRTR.PRGM
TURN THE BurnerHiFire ON ’Sets Burner to High
TURN ON THE HWPump1
START THE CONVRTR.PRGMGOTO ADJUSTING
ENDIF
www.PDF-Zoo.com
Defining Your Own Functions
Infinity Controller Programmer’s Guide 12-17
Summary
• Create a function when you find a condition that is the basis for many different actions.
• Every function must define any local variables at the top of the file.
• You cannot use LINE or GOTO in a function.
• Every function must use the RETURN keyword to:
• Return to the calling program.
• Bring the resulting value (if any) to the calling program.
You Cannot Use LINE or GOTO in Functi ons
www.PDF-Zoo.com
Defining Your Own Functions
12-18 Infinity Controller Programmer’s Guide
Using Arguments in a FunctionSuppose you want to calculate a value you use frequently.
To calculate the result, the function must get three values from a point:
OutsideAir[1]
OutsideAir[2]
OutsideAir[3]
So how does the function get values from the calling program?
They are passed into the function as “arguments.”
The line in the program that “calls” the function includes the arguments in parentheses after the function name.
Figure 12-6 shows a calling line in a program.
Figure 12-6. Calli ng Program Line fo r TESTING Func tion
Create a Functi on toCalcul ate a Value
File Edit Search Check Tools
CENTRALPLANT CALLINGPROG
SET RESULT TO TESTING(OutsideAir[1], OutsideAir[2], OutsideAir[3])
www.PDF-Zoo.com
Defining Your Own Functions
Infinity Controller Programmer’s Guide 12-19
The function then uses the first value for ARG[1], the second for ARG[2], the third for ARG[3].
You can use ARG[1], ARG[2], and ARG[3] (up to 15) for argument names in a function. Or you can rename them in the function file using the ARG keyword:
ARG 1 OAT1
ARG 2 OAT2
ARG 3 OAT3
These statements give the new arguments names to make them easier to understand. You usually put these at the top of the program and then define your local variables to hold the results of your calculations. You use NUMERIC, STRING, and DATETIME keywords to form the local variables, just as you would in a program.
With NUMERIC, you can define more than one local variable in one statement:
NUMERIC RESULT1, RESULT2
The keywords you need in addition to ARG and NUMERIC are SET and RETURN.
Figure 12-7 shows an entire function file.
ARG As signs Names to Functions in Order
www.PDF-Zoo.com
Defining Your Own Functions
12-20 Infinity Controller Programmer’s Guide
Figure 12-7. TESTING Function
Usually, you write more complex functions, such as the stop-start function in the next section. You use the same elements in every function that receives arguments or requires calculations.
File Edit Search Check Tools
CENTRALPLANT TESTING
NUMERIC RESULT1, RESULT2
SET RESULT1 = AVERAGE(OAT1, OAT2)
ARG 1 OAT1
ARG 2 OAT2
ARG 3 OAT3
SET RESULT2 = AVERAGE(OAT2, OAT3) – RESULT1
RETURN RESULT2
www.PDF-Zoo.com
Defining Your Own Functions
Infinity Controller Programmer’s Guide 12-21
Summary
• ARG[1] through ARG[15] contain arguments passed to a function. They accept all types.
• You can rename ARG variables using this format:
ARG 1 OAT1
This statement renames ARG[1] to OAT1.
• The function assigns the first argument from the calling program to ARG[1], the second to ARG[2], the third to ARG[3], and so on.
• You can name variables in a function that are not arguments. You use NUMERIC, STRING, and DATETIME to name variables.
ARG Can Rename Up to 15 Arguments
www.PDF-Zoo.com
Defining Your Own Functions
12-22 Infinity Controller Programmer’s Guide
Formi ng a Start-Stop FunctionGOAL: To start and stop the chiller or air handler based on the outside air temperature and occupancy.
You can write one function that starts and stops any piece of equipment. When you call the function, you give it arguments that tell it the name of the piece of equipment, the outside air temperature, and the occupancy.
You can have a function call another function, so you could have this function call the OCCUPANCY function. Or you could have a point called OCCUPIED.
CautionDo not use recursive functions when programming Infinity.
If you use a point to determine occupancy instead of calling a function, you can trigger the new function based on occupancy. Since this function should be triggered by either a change in temperature or a change in occupancy, you would make both these points triggers:
OutsideAir
Occupied
You start the function by renaming the three arguments:
ARG 1 EQUIPMENT
ARG 2 TEMP
ARG 3 OCCUPANCY
Then you test the temperature and occupancy, as shown at the top of the next page.
One Function Can StartDifferent Equip ment
www.PDF-Zoo.com
Defining Your Own Functions
Infinity Controller Programmer’s Guide 12-23
IF TEMP > 75 AND OCCUPANCY IS ON THEN SET~ EQUIPMENT TO ON
ELSE SET EQUIPMENT TO OFF
Either the chiller or the fan could be the equipment. The calling program uses the function as required—to stop or to start any appropriate piece of equipment.
Figure 12-8 shows the entire function file.
Figure 12-8. STOP.START Function
The calling program must give three arguments. All of the following could be statements calling this function:
STOP.START(FLOW, AV.SpTemp, OCCUPIED)
STOP.START (Chiller, OutsideAir, OCCUPIED)
Notice that each calling statement names a different piece of equipment and source of temperature. The statement calling the FLOW point gives an average of the space temperature, rather than a simple input point value. Each statement could also use a different point to determine occupancy, although both of these use OCCUPIED.
This function is simple, yet versatile. You can use it in a variety of programs to avoid reprogramming similar actions.
File Edit Search Check Tools
CENTRALPLANT STOP.START
IF TEMP > 75 AND OCCUPANCY IS ON THEN SET EQUIPMENT TO ON
ELSE SET EQUIPMENT TO OFF
ARG 1 EQUIPMENT
ARG 2 TEMP
ARG 3 OCCUPANCY
Callin g Statements Use Different A rguments
www.PDF-Zoo.com
Defining Your Own Functions
12-24 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Chapter 13
Creating, Us ing, and Searching for Data in File s
This chapter covers how to create and write to a data file, read one to write a report, and how to look up facts in data files with a function called LOOKUP:
• Understanding Data Files
• Creating Your Own Data File
• Filling the Data File with Values
• Using the Data in a Report
• Retrieving the Data for More Manipulation
• Looking Up Facts in Data Files
• Looking Up More Facts in Data Files
www.PDF-Zoo.com
Data Files
13-2 Infinity Controller Programmer’s Guide
Under standing Dat a FilesA data file is a file where you store information. You could store temperatures of zones, kilowatt usage of zones, standard deviations of temperatures from setpoints and so on. To understand data files, let’s look at one that already exists.
It contains two pieces of data—the zone name and the kilowatt usage for the last complete month.
Figure 13-1 shows the structure of the data file.
Figure 13-1. KW.USAGE Data File
The RECORD keyword is at the top of the data file. It tells that there are six “records” in this file.
Each line of information is a “record.” The records start with the fourth line of this file.
Each record in this file contains two pieces of information called “fields,” separated by a comma.
Each field in any data file is defined by assigning it a type. (As with a point, the type can be NUMERIC, STRING, or DATETIME.) The first field is designated by the first
Data Files StoreInformation
File Edit Search Check Tools
BLGD1 KW.USAGE
RECORD 6STRING ZONENAME 5
NUMERIC KW 4"Zone1", 400"Zone2", 450"Zone3", 425"Zone4", 375"Zone5", 280"Zone6", 467
The First Record
www.PDF-Zoo.com
Data Files
Infinity Controller Programmer’s Guide 13-3
statement below the RECORD statement, the second field by the second. For more fields, the statements continue, in order.
In this file, each field has not only a type, but a name, after the type. Each also has a number after the name to tell the length of the field.
Figure 13-2 breaks down the fields in one record. The first field is a string. The STRING keyword, followed by the name and length, ZONENAME 5, defines the field as a string field called ZONENAME with five characters.
Figure 13-2. Two Fields in a Data File Record
The second field is a numeric type. The NUMERIC keyword, followed by the name and length, KW 4, tells you the field is a numeric field called KW with four characters.
Referring to a Sing le Piece of Data
You can refer to any particular piece of data in the file by the record number for the row and the field name or column number for the column.
Figure 13-3 points out a single piece of data in the file.
Fields Can Have Types and Names
File Edit Search Check Tools
"Zone1", 400
STRING ZONENAME 5NUMERIC KW 4
STRING Field, called ZONENAME
NUMERIC Field, called KW
BLGD1 KW.USAGE
www.PDF-Zoo.com
Data Files
13-4 Infinity Controller Programmer’s Guide
Figure 13-3. A Single Piece of Data in KW.USAGE File
You can call out the number 280 above by its location in two ways:
• Record 5, KW field
OR
• Record 5, Column 2
To print the value in that field of this file (named KW.USAGE), you use PRINT like this (must on the same controller):
PRINT KW.USAGE [5].KW
PRINT KW.USAGE [5] [2]
Either of these statements would print:
280
It is convenient that Zone 5 is in the fifth record. But that is more than mere coincidence. You can set up a file in a way that makes it easy to use.
File Edit Search Check Tools
BLGD1 KW.USAGE
RECORD 6STRING ZONENAME 5
NUMERIC KW 4"Zone1", 400"Zone2", 450"Zone3", 425"Zone4", 375
"Zone6", 467"Zone5", 280 Single Piece of Data in a Record,
Row 5, Column 2 (Record 5, KW Fieldor Record 5, Column 2)
Special PRINT StatementPrints Data fro m Recor d
www.PDF-Zoo.com
Data Files
Infinity Controller Programmer’s Guide 13-5
Summary
• All data files have the RECORD keyword at the top of the file.
• After the RECORD keyword is the number of records in the file.
• Each line of data in a file is called a “record.”
• Items in records are in “fields,” separated by commas.
• Each field must have a type given in a NUMERIC, STRING, or DATETIME statement.
• Each field can have a name and a length in addition to a type, but only the type is required.
• You can call on a single piece of data by its record number (row) and field name (column), or record number (row) and column number.
• You can print a single piece of data two ways:
—PRINT followed by the file name, record number, and field name, as follows:
PRINT FILE1 [4].ZONENAME
—PRINT followed by the file name, record number, and column number, as follows:
PRINT FILE1 [4] [2]
• A program that accesses a data file must be located on the same controller as the data file. You cannot retrieve data from a data file on another controller.
RECORD Keyword Must Be at Top of File
www.PDF-Zoo.com
Data Files
13-6 Infinity Controller Programmer’s Guide
Creating Your Own Data FileGOAL: To create a data file that contains the daily averages of three logs for a week, OAT, TEMP, and DEWPT, and to note whether or not the average temperature exceeded setpoint on any day that week.
You create a data file as follows:
1. Return to the Main menu bar and select Edit Files.
2. Name the file in the Open a File window. The name may be up to 16 characters long and must begin with a letter of the alphabet. You can include underscores, periods, and numbers in the name.
After you press EXECUTE the File window appears.
3. Select Data for the TYPE attribute of the file.
4. Press the SAVE button or the EXECUTE or SAVE key to move to the Editor window.
5. In the Editor window, enter the RECORD statement. Since the file is to contain a week’s worth of entries, have it contain seven records.
(If you enter no number after RECORD, the number of records is automatically set to 1.)
6. Below the RECORD statement, define your fields using NUMERIC, STRING, and DATETIME as required. For this file, define four fields:
• A numeric field to contain SUNDAY through SATURDAY, with a length of 9. Remember that even though the days of the week have names, they are still understood as numbers.
• A numeric field for the average OAT, with a length of 4.
Create a Data File
Belo w RECORDStatement, Defin e Fields
www.PDF-Zoo.com
Data Files
Infinity Controller Programmer’s Guide 13-7
• A numeric field for the average TEMP, with a length of 4.
• A numeric field for the average DEWPT, with a length of 4.
• A string field for the “exceeded” or “below” setpoint.
You may make a string up to 128 characters long. If you do not give a length, the different types are automatically set to these lengths:
• NUMERIC = 15
• STRING = 16
• DATETIME = 20 (Your setting must be atleast 20, or 20 automatically replaces it.)
Figure 13-4 shows the statements after you’ve entered them in the WK.AVGS data file.
Figure 13-4. Sett ing Up the WK.AVGS Data File
7. Press the CANCEL WINDOW key to return to the File menu bar and select Check .
DateTime Fields Require Length o f at Least 20
File Edit Search Check Tools
BLDG1 WK.AVGS
RECORD 7NUMERIC DAY.WK 9
NUMERIC DEWPTAVG 4NUMERIC TEMPAVG 4 NUMERIC OATAVG 4
STRING EXCEED 8
www.PDF-Zoo.com
Data Files
13-8 Infinity Controller Programmer’s Guide
8. You should receive a No Errors! message in the message bar.
9. Select File Save and File Quit to save and exit the file.
10. Reopen the file.
Figure 13-5 shows the skeletal set up of the WK.AVGS data file.
Figure 13-5. Skeletal Setup of WK.AVGS Data File
The empty records have quotation marks around blanks for the strings and zeros for the numbers. Each field allows the number of characters you indicated for the length.
An “empty” DATETIME field would be filled with 1/1/89 12:00:00 am .
Now you have a skeleton for the data file you want to put values into. Next, you must write a program to calculate the values and put (“write”) them into the file.
The next section explain how to fill the file from a program.
File Edit Search Check Tools
BLDG1 WK.AVGS
RECORD 7NUMERIC DAY.WK 9
NUMERIC DEWPTAVG 4NUMERIC TEMPAVG 4 NUMERIC OATAVG 4
0, 0, 0, 0, " " 0, 0, 0, 0, " " 0, 0, 0, 0, " " 0, 0, 0, 0, " " 0, 0, 0, 0, " " 0, 0, 0, 0, " " 0, 0, 0, 0, " "
STRING EXCEED 8
Empty Data File Ap pearswith Field Formats
www.PDF-Zoo.com
Data Files
Infinity Controller Programmer’s Guide 13-9
Summary
• To create a data file, select Data for the TYPE attribute of the file.
• Always enter a RECORD statement at the top of the file.
• If you do not specify a number of records, the number is set to 1.
• When you give the field types below the record statement, if you do not specify a length for each field, the automatic settings are:
• NUMERIC 15
• STRING 16
• DATETIME 20
• A DATETIME field must have at least 20 characters.
• After you check for errors, save, and close the data file, when you reopen it, the “empty” fields are displayed with blanks for strings, zeros for numbers, and 1/1/89 12:00:00 am for datetimes.
Number of Records Sets to 1 Autom atically
www.PDF-Zoo.com
Data Files
13-10 Infinity Controller Programmer’s Guide
Fil ling the Da ta File wi th ValuesGOAL: To fill the skeleton of WK.AVGS with the daily averages for a week of three logs, OAT, TEMP, and DEWPT.
The WRITE Func tion
To put values into a data file, you use an advanced keyword called WRITE.
WRITE is a function that returns the status of the writing process:
• SUCCESS—Write successful.
• EOF—Write failed because the data file is full.
It also fills a particular data file you name, putting the data in a record number you specify, and then filling the fields with the data or variable values you include.
IF WRITE(WK.AVGS, REC, WKD, OATAVG, ~TEMPAVG, DEWPTAVG, EXCEED) = SUCCESS THEN
This statement writes the data into the data file named WK.AVGS, filling the record number REC field 1 with the WEEKDAY (WKD), field 2 with the value of OATAVG, field 3 with the value of TEMPAVG, field 4 with the value of DEWPTAVG, and field 5 with EXCEEDED or BELOW.
The statement also tests the WRITE to see if it returns SUCCESS.
WRITE Puts Values into aData File
www.PDF-Zoo.com
Data Files
Infinity Controller Programmer’s Guide 13-11
The Progra m Steps
To complete the program, let’s look at the single-action steps required:
NoteA program that accesses a data file must be located on the same controller as the data file. You cannot retrieve data from a data file on another controller.
Trigger if WEEKDAY changes and the logs (OAT, TEMP, and DEWPT) have been filled for the day.
1. Set DAY.WK.
2. Calculate the OATAVG for that day and store it in the array.
3. Calculate the TEMPAVG for that day and store it in the array.
4. Calculate the DEWPTAVG for that day and store it in the array.
5. Check to see if setpoint has been exceeded and set EXCEED to either “EXCEEDED” or “BELOW.”
6. Write the day’s values into that day’s record.
7. Repeat steps 1 through 7 until the data file is full (contains seven records).
This data is written into the file over a period of a week. Each day the same action must take place.
Figure 13-6 shows the program. It should be triggered by WEEKDAY changing.
Write Single Act ion Steps of Program
www.PDF-Zoo.com
Data Files
13-12 Infinity Controller Programmer’s Guide
Figure 13-6. CREATE.DATA Program
Variables in the Prog ram
The first two statements in the program define the local variables. They are:
• Four numeric arrays, each with seven entries, one for each day of the week.
• A string array with nine characters and seven entries, one for each day of the week.
Trig gering the Pro gram
The program triggers when the day changes. When the HOUR is equal to 23 (time is after 11:00 p.m.), the controller:
• Sets the DAY.WK to the day of the week.
• Averages each log (OAT, TEMP, and DEWPT).
File Edit Search Check Tools
DAY.WK [WEEKDAY] = WEEKIF HOUR IS = 23 THEN
OATAVG [WEEKDAY] = AVERAGE(OAT)TEMPAVG [WEEKDAY] = AVERAGE (TEMP)DEWPTAVG [WEEKDAY] = AVERAGE (DEWPT)
IF WRITE (WK.AVGS,WKD,DAY.WK[WEEKDAY],~
ENDIF
OATAVG[WEEKDAY],TEMPAVG[WEEKDAY], ~
BLDG1 FLOOR1 CREATE.DATA
NUMERIC DAY.WK[7], OATAVG [7], TEMPAVG [7], DEWPTAVG [7]
STRING 9 EXCEED[7]
DEWPTAVG[WEEKDAY],EXCEED[WEEKDAY])IS EOF~
IF TEMPAVG [WEEKDAY] > TEMPSETPT THEN SET EXCEED ~TO "EXCEEDED" ELSE SET EXCEED TO "BELOW"
THEN RUN WKLY.AVG.RPT
Variables to ContainData Are Ar rays
www.PDF-Zoo.com
Data Files
Infinity Controller Programmer’s Guide 13-13
• Checks the temperature setpoint against the average temperature for the day and sets EXCEED to either “EXCEEDED” or “BELOW.”
Using WEEKDAY a s an Index Varia ble
WEEKDAY is especially useful here because it is both a number and a word, depending on how you use it.
If you set a field to the WEEKDAY, the controller puts the spelled-out weekday in the field. (If you want only the first three characters of the weekday, print weekday to a string that is only three characters long and the controller automatically cuts the name short.)
Since each record number matches the day of the week number for that record (first record is Sunday, second is Monday, and so on), the WEEKDAY system variable can be both the record number and the array index variable.
When WEEKDAY is Sunday, its numeric value is 1, so OATAVG[WEEKDAY] becomes OATAVG[1] and prints in record 1.
When WEEKDAY is Wednesday, its numeric value is 4, so OATAVG[WEEKDAY] becomes OATAVG[4] and prints in record 4.
If WRITE has filled all the records, the status of the writing process is then EOF.
When the status is EOF, the program prints a report called WKLY.AVG.RPT. The report reads the data and prints it out in a particular format.
WEEKDAY Can BeNumber or String
www.PDF-Zoo.com
Data Files
13-14 Infinity Controller Programmer’s Guide
Figure 13-7 shows the filled WK.AVGS data file.
Figure 13-7. Fill ed WK.AVGS Data File
Details on how the report file uses the data file are covered next.
If you enter all this data by hand, you need only enter the first three letters of each weekday. Once you close, then reopen the file, the controller replaces each abbreviation with the full weekday name.
In addition, you can have numeric fields containing ON, OFF, –ON, SUCCESS, FAILURE, EOF, and any of the months of the year as well as the days of the week.
A Sample Filled Data File
File Edit Search Check Tools
BLDG1 WK.AVGS
RECORD 7
TUESDAY, 29.8, 71.6, 32.0, "EXCEEDED"
WEDNESDAY, 28.5, 71.2, 32.1, "BELOW "
THURSDAY, 26.7, 70.3, 30.5, "BELOW "
FRIDAY, 25.1, 70.0, 28.6, "BELOW "
SATURDAY, 27.6, 71.0, 29.1, "BELOW "
SUNDAY, 28.2, 70.1, 27.5, "BELOW "
MONDAY, 31.1, 72.2, 32.1, "EXCEEDED"
NUMERIC DAY.WK 9
NUMERIC DEWPTAVG 4NUMERIC TEMPAVG 4 NUMERIC OATAVG 4
STRING EXCEED 8
www.PDF-Zoo.com
Data Files
Infinity Controller Programmer’s Guide 13-15
Summary
• To create the skeleton of a data file, you enter the RECORD statement and the field types in a data file.
• You use the WRITE keyword to fill a data file with values.
• WRITE returns the status of the writing process, SUCCESS or EOF (end of file).
• WRITE puts the data in a particular file you name and a particular record number you specify.
• WRITE puts each piece of data into a field that matches the type of the name or number you specify.
• Because WEEKDAY is both a word and a number, you can use it for each of these:
—To put the spelled-out weekday name in a numeric field.
—As a record number or array index variable.
—To fill a string variable with the weekday name.
• A program that accesses a data file must be located on the same controller as the data file. You cannot retrieve data from a data file on another controller.
WRITE Is Either SUCCESS or End of File
www.PDF-Zoo.com
Data Files
13-16 Infinity Controller Programmer’s Guide
Using th e Data in a Re portGOAL: To print a report using the WK.AVGS data file (in the previous section).
A data file contains straight facts, without a PRINT format. You can print out each record in a format using a program. The program would contain a series of PRINT statements, each with a format indicating how the text should appear.
Some of the formats for PRINT were presented in Chapter 9. We won’t repeat much of that information here. If you do not recognize the formats (shown with pound signs and @ signs in a PRINT statement) used here, refer to the PRINT keyword in the Andover Controls Plain English Language Reference.
The program should include:
• The title of the report.
• The week ending date (the current day’s date is the end of the week).
• Column heads for Day, Average Outside, Average Indoor, and Average Dewpoint.
• The data.
Figure 13-8 shows what the report file could contain.
A Repor t Program PrintsData in Readable Format
www.PDF-Zoo.com
Data Files
Infinity Controller Programmer’s Guide 13-17
Figure 13-8. WKLY.AVG.RPT Program—FallThru
Figure 13-9 shows the report that prints.
Figure 13-9. WKLY.AVG.RPT Report
File Edit Search Check Tools
PRINT "Week Average Average Average"
PRINT " "
PRINT "Day Outside Indoor Dewpoint"
PRINT " |@@@", WK.AVGS[N].DAY.WK, ~
BLDG1 FLOOR1 WKLY.AVG.RPT
PRINT " Weekly Report on Heat Control System"
PRINT " for Week Ending |################", DATE
PRINT " "
PRINT " Temperatures (degrees Fahrenheit)"
" |###.#", ~WK.AVGS [N].DEWPTAVG
" |###.#", WK.AVGS [N].TEMPAVG,~
FOR N = 1 TO 7
NEXT N
NUMERIC N
" |###.#",~WK.AVGS [N].OATAVG, ~
Temperatures (degrees Fahrenheit)
Weekly Report on Heat Control System for Week Ending January 20, 1990
Week Average Average AverageDay Outside Indoor Dewpoint
Sun 28.2 70.1 27.5
Wed 28.5 71.2 26.7
Thu 26.7 70.3 24.3
Fri 25.1 70.0 23.6
Sat 27.6 71.0 25.8
Mon 31.1 72.2 30.1
Tue 29.8 71.6 28.0
www.PDF-Zoo.com
Data Files
13-18 Infinity Controller Programmer’s Guide
Retr ieving the Data for More Manipu lationGOAL: Retrieve the OATAVG, TEMPAVG, and DEWPTAVG for each day from the WK.AVGS data file and add it to a data file that stores the daily averages for every day of the year.
To get information from a data file, you can use an advanced keyword called READ. READ reads an entire record in a data file and puts the data into a list of variables for use in a program. The program, in this case, writes the data into another data file.
READ can put the data into different variable names. As long as the types match, you can read or write data to different names.
First, to retrieve (read) the data, use a typical READ statement:
RESULT = READ (WK.AVGS, REC, OATS, TEMPS,~DEWPTS)
The statement reads the WK.AVGS file, record number REC, and reads three variables, all numeric, in the order they occur in the record.
READ, like WRITE, returns a status of SUCCESS or EOF. So the READ statement is not complete unless it is set equal to a status variable (named RESULT here) or tested for being equal to SUCCESS in an IF..THEN statement.
NUMERIC RESULT
The program needs to test the RESULT to be sure the reading was successful before it can write any of the data. A statement that tests WRITE for success is at top of next page.
Figure 13-10 shows the complete program, where you must also define the variables.
READ Retr ieves Valuesfrom Data File
www.PDF-Zoo.com
Data Files
Infinity Controller Programmer’s Guide 13-19
IF RESULT = SUCCESS THENIF WRITE (DAY.AVGS.90, WRITE.REC, DY.WK,~ OATS, TEMPS, DEWPTS) = SUCCESS
PRINT "Writing Record Number ", WRITE.REC
ELSE PRINT "End of Writing to DAY.AVGS.90 File."
ELSE PRINT "End of Reading from WK.AVGS File."
Since REC is the record number for READ, and the record numbers are not the same for WRITE, you can use WRITE.REC as the record number for WRITE.
To find the WRITE.REC, since you are writing a record for every day of the year, you use DAYOFYEAR.
Figure 13-10. DAY.DATA.PROG Program—FallThru
Program Checks for Status of WRITE
File Edit Search Check Tools
ELSE PRINT "End of Writing to DAY.AVGS.90 File."
IF WRITE(DAY.AVGS.90, WRITE.REC, DY.WK, OATS,TEMPS,~
BLDG1 FLOOR1 DAY.DATA.PROG
RESULT = READ(WK.AVGS, REC, DY.WK, OATS, TEMPS, DEWPTS)IF RESULT = SUCCESS THEN
NUMERIC OATS, TEMPS, DEWPTSFOR REC = 1 TO 7
DEWPTS)=SUCCESS THEN PRINT"Writing Record Number ",~
ELSE
STRING DY.WK
SET WRITE.REC TO (DAYOFYEAR -8) + REC
NUMERIC RESULT
WRITE.REC
IF WRITE.REC IS LESS THAN OR EQUAL TO 0 THEN CONTINUE
ENDIF
PRINT "End of Reading WK.AVGS File."BREAK
NEXT REC
www.PDF-Zoo.com
Data Files
13-20 Infinity Controller Programmer’s Guide
The DAYOFYEAR when the write begins is the last day of the week from WK.AVGS. You do not want to write the first record to the current day of the year, but to one seven days before it. So you calculate DAYOFYEAR – 8 PLUS WEEKDAY (or PLUS REC) to find the correct record to store the data in.
What would you do then if the WRITE.REC is less than 7? For instance, what if Saturday is January 6, so DAYOFYEAR is 6? Then 6 minus 8 is –2, plus 1 for Sunday is –1. This means that the Sunday of the first week’s data is from the previous year! In that case, you employ the CONTINUE statement.
CONTINUE halts the FOR..NEXT loop at the current line and starts the loop over with the next value. So, for the week ending January 6, the program skips Sunday (1) and proceeds to Monday (2).
Figure 13-11 shows what DAY.DATA.PROG prints in the Message window if the writing process is successful.
Figure 13-11. Text That Prints in Command Window
Figure 13-12 shows the what DAY.DATA.PROG writes into the DAY.AVGS.90 data file.
CONTINUE Takes Loopto Next Value
View Edit Connect Logout
Messages – FLOOR1
Writing Record Number 14Writing Record Number 15Writing Record Number 16Writing Record Number 17Writing Record Number 18Writing Record Number 19Writing Record Number 20
www.PDF-Zoo.com
Data Files
Infinity Controller Programmer’s Guide 13-21
Figure 13-12. DAY.AVGS.90 Data File
File Edit Search Check Tools
BLDG1 WK.AVGS
RECORD 365
"TUE", 39.8, 71.6, 42.0 "WED", 38.5, 71.2, 42.1"THU", 36.7, 70.3, 40.5
NUMERIC DAYDEWPTAVGNUMERIC DAYTEMPAVG NUMERIC DAYOATAVG
"FRI", 35.1, 70.0, 38.6"SAT", 37.6, 71.0, 39.1
"MON", 42.1, 72.2, 42.7
STRING DY.WK
"TUE", 29.8, 71.6, 32.0 "WED", 28.5, 71.2, 32.1"THU", 26.7, 70.3, 30.5 "FRI", 25.1, 70.0, 28.6"SAT", 27.6, 71.0, 29.1
"MON", 41.1, 72.2, 42.1 "SUN", 38.2, 70.1, 37.5
"TUE", 29.8, 71.6, 32.0 "WED", 28.5, 71.2, 32.1"THU", 26.7, 70.3, 30.5 "FRI", 25.1, 70.0, 28.6"SAT", 27.6, 71.0, 29.1
"MON", 31.1, 72.2, 32.1 "SUN", 28.2, 70.1, 27.5
The Last Week’s Seven RecordsAdded onto the End of the File.
www.PDF-Zoo.com
Data Files
13-22 Infinity Controller Programmer’s Guide
Summary
• To retrieve a record from a data file, you use the READ statement.
• In a READ statement, you give the first record to read and the names of the variables to put the data into.
• READ returns the status of the reading process, either SUCCESS or EOF (end of file).
• READ puts each of the fields in the data file into a variable name that matches the type of the field.
• You can put the same data into different variable names with READ or WRITE, as long as the types match.
• CONTINUE stops the FOR..NEXT loop on the current line and returns to the beginning to execute it again using the next index variable value.
• Remember that a program that accesses a data file must be located on the same controller as the data file. You cannot retrieve data from a data file on another controller.
Types of Data andVariable Must Match
www.PDF-Zoo.com
Data Files
Infinity Controller Programmer’s Guide 13-23
Looking Up Fact s in Dat a FilesGOAL: To find and print the average OAT and average DEWPT for this past Tuesday in the WK.AVGS file (from earlier section).
To find data in a file where you know the contents of a field (for example, you know DAY.WK contains the weekday name and is the first column of the data file), you use a keyword called LOOKUP.
Searchin g Records
Before you can use LOOKUP, you must define a variable to represent the first record to search. Let’s call that variable RECNUM and set it equal to 1, for the first record.
NUMERIC RECNUM
RECNUM = 1
To look up a record in this data file, you then use the LOOKUP keyword, giving it the exact word or number you are looking up and the column number of the field it is in, as follows (strings must be in quotation marks):
NUMERIC RESULT
RESULT = LOOKUP(WK.AVGS, "TUESDAY", 1,~RECNUM)
The LOOKUP function searches the file named WK.AVGS for TUESDAY in the first column, starting with the first record (the record number in RECNUM).
LOOKUP returns two pieces of information:
• The status of the search—SUCCESS, FAILURE, or EOF.
• The number of the record found. (This number replaces the one you originally assigned to RECNUM).
Variable ContainsNumber of First Record
www.PDF-Zoo.com
Data Files
13-24 Infinity Controller Programmer’s Guide
You can then print any of the information in the record LOOKUP found, using the record number. For instance, to print the dewpoint average from the record found, use PRINT as follows:
PRINT WK.AVGS [RECNUM].DEWPTAVG
In the PRINT statement, you give the file name, the record number, and the field name. The PRINT statement prints:
32.0
You can set another variable to the value found for use in other calculations:
SET TEMPHOLDER = WK.AVGS [RECNUM].DEWPTAVG
Figure 13-13 shows the program to search the data file and print out the average dewpoint on a specific day of the week.
Figure 13-13. DEWPT.FIND Program—Looping
Figure 13-14 shows what DEWPT.FIND prints.
Use Recor d Number toPrint Data Found
File Edit Search Check Tools
BLDG1 FLOOR1 DEWPT.FIND
RESULT = LOOKUP(WK.AVGS, "TUESDAY", 1, RECNUM)
IF RESULT = SUCCESS THEN
NUMERIC RESULT, RECNUM
RECNUM = 1
PRINT " Average Dewpoint on Tuesday was ";
PRINT WK.AVGS [RECNUM].DEWPTAVG, " degrees F."
ELSE PRINT "Error in Search of WK.AVGS File."
www.PDF-Zoo.com
Data Files
Infinity Controller Programmer’s Guide 13-25
Figure 13-14. Printout from DEWPT.FIND
Summary
• You use LOOKUP to find data in a file where you know the name and contents of a field you can refer to but do not know the record number.
• Before you use LOOKUP, you must define two numeric variables:
—One to hold the record number.
—One to hold the status of the search.
• When executing LOOKUP, the record number is the number of the first record to search.
• When LOOKUP finds a field with contents matching the information you give, it replaces the original record number with the number of the one found.
• LOOKUP returns:
—The status of the search in a local numeric variable:
SUCCESSFAILUREEOF
—The number of the record found (stored in the original record number variable).
Average Dewpoint on Tuesday was 32.0 degrees F.
LOOKUP Requires Two Variables
www.PDF-Zoo.com
Data Files
13-26 Infinity Controller Programmer’s Guide
Looki ng Up Mo re Facts i n Data FilesGOAL: To find the days in the week of January 7 to 13 that the power usage setpoint was exceeded.
The Data File
Suppose you have a data file that contains the average daily energy usage for the last week, and whether or not it exceeds the setpoint for usage. Each piece of information is from a particular date and time.
Figure 13-15 shows the structure of the data in the data file.
Figure 13-15. USAGE Data File
The RECORD keyword tells that there are seven records in this file.
DATETIME tells us the first field is a datetime type field called DTSTAMP.
A Sample Data File
File Edit Search Check Tools
BLDG1 FLOOR1 USAGE
RECORD 7DATETIME DTSTAMP
NUMERIC KW.USAGE
1/ 7/90 12:00:00 pm, 398, "BELOW " 1/ 8/90 12:00:00 pm, 450, "EXCEEDS " 1/ 9/90 12:00:00 pm, 425, "EXCEEDS " 1/10/90 12:00:00 pm, 415, "EXCEEDS " 1/11/90 12:00:00 pm, 389, "BELOW " 1/12/90 12:00:00 pm, 376, "BELOW " 1/13/90 12:00:00 pm, 395, "BELOW "
STRING EXCEED.SPT 8
www.PDF-Zoo.com
Data Files
Infinity Controller Programmer’s Guide 13-27
The NUMERIC keyword tells us the second field is a numeric field called KW.USAGE.
The STRING keyword tells us that the third field is a string field of eight characters called EXCEED.SPT.
Searchin g Records
Let’s call the record number variable RECNUM and set it equal to 1, for the first record:
NUMERIC RECNUM
RECNUM = 1
To look up a record in this data file, you then use the LOOKUP keyword, giving it the exact value you are looking up and the name of the field it is in, as follows:
NUMERIC RESULT
RESULT = LOOKUP(USAGE, "EXCEEDS", 3,~ RECNUM)
The LOOKUP function searches the file named USAGE for “EXCEEDS” in the EXCEEDS.SPT column, starting with the record number in RECNUM (1).
The search string does not have to include any trailing blanks that may be in the field. “EXCEEDS” is the same as “EXCEEDS ” and “EXCEEDS ” to the controller.
After the search has found a record, you can print the date from the first column of that record number. You use the PRINT statement:
PRINT USAGE [RECNUM].DTSTAMP
This statement prints the date in DTSTAMP for a single record.
Give Looku p the Value You Are Loo kin g Up
www.PDF-Zoo.com
Data Files
13-28 Infinity Controller Programmer’s Guide
After printing the date, the program can search again, starting with the number after the record found. The controller then searches the rest of the file for other days the setpoint may have been exceeded on. It repeats the search while the EOF (end of file) has not been reached.
Figure 13-16 shows the program.
Figure 13-16. THRESHOLD.PT Program—FallThru
You can alter the program to format the information you print out using any of the formats covered under the PRINT keyword in the Andover Controls Plain English Language Reference.
You can also search a file for a string using the selections in the Search menu of the File menu bar.
LOOKUP Searches Unti lIt Reaches End of File
File Edit Search Check Tools
BLDG1 FLOOR1 THRESHOLD.PT
RESULT = LOOKUP(USAGE,"EXCEEDS", 3, RECNUM)
IF RESULT IS NOT EOF THEN
ENDIF
NUMERIC RESULT, RECNUM
RECNUM = 1
PRINT USAGE [RECNUM].DTSTAMP
SET RECNUM = RECNUM + 1
GOTO BEGINNING
BEGINNING:
www.PDF-Zoo.com
Data Files
Infinity Controller Programmer’s Guide 13-29
Summary
• When using LOOKUP to search for a string, you do not have to include trailing blanks in the search string.
• To continue searching a file for more occurrences of the same value in a field, add 1 to the record number found and repeat the search through to the end of the file.
• You can also search a data file using Search menu selections, just as you did with program files earlier in this manual.
• Remember that a program that accesses a data file must be located on the same controller as the data file. You cannot retrieve data from a data file on another controller.
Ending Blanks NotRequired in String
www.PDF-Zoo.com
Data Files
13-30 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Chapter 14
Debuggi ng Techniques
This chapter presents some common techniques for debugging programs—removing all runtime errors. These errors are not the ones that occur when you “check” the program with the Check selection from the File menu bar. These errors occur after you run the program:
• Preparing to Debug
• Recognizing Runtime Errors
• Tracing Point Values
• Setting Point Values
• Employing a Debugging Function
• Employing a Debugging Program
• Tracing Current Lines
• Employing a Debugging Program That Printson the Status Bar
• Debugging Sample Programs
• Indicating an Error with Line E
For special information about debugging comm port programs, refer to Chapter 17.
www.PDF-Zoo.com
Debugging Techniques
14-2 Infinity Controller Programmer’s Guide
Preparing to DebugBefore you proceed, take any emergency measures required.
If necessary, set outputs to manual override and intervene un-til the problem is temporarily resolved.
How do you recognize a runtime error? Suppose you receive multiple alarms for each of the following:
• Chiller not starting.
• Space temperature not reaching setpoint within a reasonable period.
• Space temperature constantly rising unless you intervene.
• VAV damper staying closed for long intervals.
• Outside air to a floor not adequate.
If you constantly receive the same alarms, you should check to be sure they are not bugs. The problem could be any of the following:
• Sensors
• Equipment
• Your Andover Controls Plain English program(s)
Figure 14-1 shows the three possible sources of a problem.
Identify Any Equip mentProb lems
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-3
Figure 14-1. Poss ib le Sources of Problems
Because some errors mimic equipment problems, first you eliminate the possibility that the problem is the sensors or equipment:
1. Check to be sure the sensors are functioning. Refer tothe Andover Controls Infinet Controller Troubleshooting Guide.
2. Check physical output points (relays) in the controller. If a point is ON and the equipment is OFF, then the equipment itself is not working.
If the point is OFF because a program is not setting it to ON, the program is not working properly—that is a bug in your Andover Controls Plain English program.
Remember, the bug can be one of the following:
• An error the controller identifies
• A logical error
Programs
Sensors Equipment
in Controller
Check Hardware First
www.PDF-Zoo.com
Debugging Techniques
14-4 Infinity Controller Programmer’s Guide
Recognizing Runtime ErrorsTo determine which program has failed to operate the equip-ment, proceed as follows:
1. Select View Programs and see whether or not the STATE of the program is DISABLED. If no programs are disabled, the controller has not identified an error and you must identify the error.
2. If the file is disabled, open the File window. You should see an error message in the lower left corner.
3. Look up the error message in Appendix B. The explanation gives steps you can take to resolve the error.
Some runtime errors do not send messages. You know some-thing is wrong because you keep receiving an alarm and the equipment (valve, fan, chiller, boiler) does not require maintenance.
For instance, cooling may not start because the chill water valve is stuck. But since you checked the valve and it is oper-ating, the source of the problem must be in your Andover Controls Plain English program.
Maybe the value of the trigger to the COOLING program has not changed.
If the trigger is a temperature or other input, the sensor could be bad. Once you check the sensor and determine it is not the source of the problem, you must look elsewhere. Maybe the point is not updating frequently enough because the THRESHOLD is too high or the logging interval is too long.
Also, the trigger might not be the best one for the job. An ex-treme example would be using MONTH to trigger a program that must run daily. Obviously, the month changes only every 30 days, but the program needs to start every day.
Determine Whether orNot Program Is Disabl ed
Some Runt ime Errors DoNot Produce Messages
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-5
So how do you go about finding out what is actually going on?
1. Select View Programs and see if the STATUS of a program is INACTIVE. If a program is inactive and should be active, that program could be the source of your problem.
2. Proceed with the remainder of this chapter. The sections that follow each explain a debugging technique.
Summary
To resolve runtime errors, you determine the following:
• Has the equipment failed? If not, go to the next bullet.
• Has the controller disabled a program due to error? If not, go to the next bullet. Otherwise, open the File window and find the error message. You can look up how to resolve each message in Appendix B or apply debugging techniques discussed later in this chapter.
• Does a program contain errors in logic? Apply the debugging techniques later in this chapter that help uncover logical and other runtime errors.
Determine Whether or Not Program Is Disab led
www.PDF-Zoo.com
Debugging Techniques
14-6 Infinity Controller Programmer’s Guide
Tracing P oint ValuesYou can trace the point values in a program, seeing them change as the program takes action. Proceed as follows:
1. Open the program file.
2. Open a Command window from inside the file, as described in Chapter 9.
Having the two windows open at the same time is useful during debugging. You can now run the program and if you need to change a line, change it immediately.
Figure 14-2 shows the two windows open at the same time.
Figure 14-2. Bo th Program File Window and Comman d Window Open
3. This program is fallthru. Although the program has no format errors, COOLING is often running well into the night.
4. Change the FLOWTYPE of the program to looping for testing. This way the program runs continuously rather than waiting to be triggered.
Trace Changes in Poin tValues
File Edit Search Check Tools
Command Window – BLDG1 FLOOR1R>
BLDG1 FLOOR1 COOLCONTROL
IF OCCUPIED THEN IF SPACETEMP > 75 THEN START COOLING ELSE STOP COOLINGENDIF
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-7
5. Run the program from the Command window.
6. Print the point values in the Command window: OCCUPIED, SPACETEMP, and COOLING.
7. Print the STATUS of the program.
Figure 14-3 shows the debugging commands in the Command window.
Figure 14-3. Debugging Commands i n Comman d Window
8. Examine the point values. In the example, you can see the point values tracing the action of the program.
OCCUPIED is on, so the program tests the SPACETEMP. SPACETEMP is high enough to start the COOLING, so the COOLING starts. The controller ignores the ELSE statement.
To explore the problem, you can try setting the point values.
Trace the StatusAt tribute
File Edit Search Check Tools
Command Window – BLDG1 FLOOR1
IF OCCUPIED THEN IF SPACETEMP > 75 THEN START COOLING ELSE STOP COOLING
R>RUN COOLCONTROL
ENDIF
R>PR OCCUPIED, SPACETEMP, COOLINGOCCUPIED = ONSPACETEMP = 76COOLING = ON
BLDG1 FLOOR1 COOLCONTROL
R>PR COOLCONTROL STATUSCOOLCONTROL STATUS = ACTIVE
www.PDF-Zoo.com
Debugging Techniques
14-8 Infinity Controller Programmer’s Guide
Sett ing P oint V aluesTo find out what happens when an input is at a particular set-ting (OCCUPIED is ON or OFF, SPACETEMP is under or over 75), do the following:
1. Disable the inputs (OCCUPIED and SPACETEMP) so that you can set them.
2. In the Command window, set one input to a value you want to test. (Set OCCUPIED or SPACETEMP.)
3. Run the program.
4. Print the point values. If they are different determine why. Are the settings what you expected?
For example, if you set OCCUPIED to ON and SPACETEMP to 72, the COOLING stays OFF.
If you leave OCCUPIED ON and set SPACETEMP to 76, the VALUE of COOLING becomes ON.
So the temperature has the effect you expected at occupied times.
5. Change the settings and see the direction the program takes.
If OCCUPIED is OFF, what happens?
If you set the temperature to 72 when OCCUPIED is OFF, the COOLING turns OFF. That seems fine.
Figure 14-4 shows the point values that occur when OCCUPIED is OFF and the temperature is 76.
Although OCCUPIED is OFF, COOLING remains ON.
So SPACETEMP controls the COOLING, even when the space is not occupied.
No wonder COOLING was ON at 10 p.m.!
Runtime Erro rs OccurWhen You Run Program
Are Poin t Values ThoseYou Expected?
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-9
Figure 14-4. Response to OCCUPIED Being OFF
What about OCCUPIED—why does it have no effect? Be-cause ELSE goes with the IF..THEN that checks temperature. The controller carries out the ELSE state-ment only when the temperature is not greater than 75.
Correc ting th e Bug
Since two values are required to start cooling, you should use AND between them in the same IF..THEN statement:
IF OCCUPIED AND SPACETEMP > 75 THEN
START COOLING
ELSE
STOP COOLING
ENDIF
Always be wary of nested IF statements.
File Edit Search Check Tools
Command Window – BLDG1 FLOOR1
IF OCCUPIED THEN IF SPACETEMP > 75 THEN START COOLING ELSE STOP COOLING
R>RUN COOLCONTROL
ENDIF
R>PR OCCUPIED, SPACETEMP, COOLING OCCUPIED = OFF
BLDG1 FLOOR1 COOLCONTROL
SPACETEMP = 76COOLING = ONR>PR COOLCONTROL STATUSCOOLCONTROL STATUS = ACTIVE
Correct the Nested IF Statement
www.PDF-Zoo.com
Debugging Techniques
14-10 Infinity Controller Programmer’s Guide
Employing a Debugging FunctionIf you expect to repeat the same commands an extensive num-ber of times while debugging, write a function containing them, so that later, you need only run the function by typing its name (and any arguments) in the Command window.
Proceed as follows:
1. Open a function file.
2. Put PR statements in the function, including one for each point, point attribute, or program attribute you want infor-mation about.
Figure 14-5 shows a debugging function to trace the point values of COOLCONTROL.
Figure 14-5. Funct ion f or Debuggi ng by Tracing Point Values
3. Set the point value you want to test from the command line.
4. Run the debugging function as many times as necessary to resolve the problem.
Put PR CommandsInside a Function
File Edit Search Check Tools
FLOOR1 BLDG1 CHBUG
PR OCCUPIED, SPACETEMP, COOLING, COOLCONTROL STATUS
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-11
The information from PR appears in the Command window because it is printed by a function run from the Command window. (A program would send PR statements to the Messages window.)
Running t he Sample Func tion
Suppose you want to find out if the COOLING starts when occupancy changes. Try running the CHBUG function and giving it first OCCUPIED = ON, then OCCUPIED = OFF, keeping the temperature constant. Switch back and forth to see what happens if OCCUPIED is OFF first, then ON.
You could then switch to systematic tests of various temperatures, keeping OCCUPIED ON for 74, 75, 76, and so on. Then test the same temperatures with OCCUPIED OFF to see if responses differ.
Figure 14-6 shows the results of running the function.
Figur e 14-6. Resul ts of CHBUG Debug ging Functi on
The function prints the point values in the Command window.
Run the Program for a Particu lar Poin t Value
View Edit Connect Logout
Command Window – BLDG1 FLOOR1
R>CHBUG
SPACETEMP = 76COOLING = ON
OCCUPIED = ON
R>SET OCCUPIED = OFF
COOLING = ONSPACETEMP = 76OCCUPIED = OFF
R> RUN COOLCONTROLR>CHBUG
R>SET OCCUPIED = ON
R> RUN COOLCONTROL
www.PDF-Zoo.com
Debugging Techniques
14-12 Infinity Controller Programmer’s Guide
Employing a Debugging ProgramAnother debugging tool is a debugging program. It can have a loop to repeat a series of steps. Write the program as follows:
1. Create a numeric point that represents the input, to test the input, such as SPACETEMPTEST.
2. Open the program you want to debug.
3. Search for the input that the numeric point you just created represents and replace it with the numeric point name.
4. Save the program file under another name for testing, such as ST.CHILL.TEST. The original program remains intact.
5. Disable the original program.
6. If applicable, set up the numeric point to trigger the program you are testing.
7. Open a new program file and in it, set the test point to a starting value.
8. Create a loop with GOTO that sets the testing point to increasing values, then runs the program once for each value.
Figure 14-7 shows a debugging program.
The debugging program sets the SPTEMPTEST value and traces how it affects other point values in ST.CHILL.TEST. When the COOLING is eventually on, the program stops itself.
All data from PR goes to the Messages window.
9. Put the program last on the firing order list.
10. Run the debugging program.
Write a Debug gingProgram with a Loop
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-13
11. Open the Messages window (described in Chapter 9). Here you see the results of PR statements from the debugging program.
Figure 14-7. Prog ram fo r Debugg ing by Altering Poin t Values—FallThru
Figure 14-8 shows the messages from TESTPG that print in the window.
You could also try creating an OCCUPIEDTEST and setting it to OFF to be sure the COOLING does not start when the floor is not occupied.
12. Close and reopen the Messages window to see updates of the program activity. The Messages window can hold up to 48 physical lines of data unless you reset it.
Message WindowDisplays P R Results
File Edit Search Check Tools
FLOOR1 BLDG1 TESTPG
SET SPTEMPTEST = 74
PR OCCUPIED, SPTEMPTEST, COOLING, COOLCTRLTEST STATUSRUN COOLCTRLTEST
REDO:SET SPTEMPTEST = SPTEMPTEST + 1
IF COOLING = OFF THEN GOTO REDO ELSE STOP TESTPG
www.PDF-Zoo.com
Debugging Techniques
14-14 Infinity Controller Programmer’s Guide
Figure 14-8. Messages from TESTPG Debuggi ng Progr am
Tracing Current LinesIn a multiline program, you can trace the lines as they execute. Follow these steps:
1. Add the following statement to the beginning of each line:
PR CURRENTLINE
You might also print the time that the current line isbeing run. (You can use either DATE or TIME, since each prints the full date and time.)
Figure 14-9 shows how you would alter the HEAT.NOHEAT program to print the current line whenever the program runs that line.
Edit View Connect Logout
Messages – BLDG1 FLOOR1 TESTPG
EXIT CLEAR
OCCUPIED = ONSPTEMPTEST = 74COOLING = OFFCOOLCTRLTEST STATUS = INACTIVEOCCUPIED = ONSPTEMPTEST = 75COOLING = OFFCOOLCTRLTEST STATUS = INACTIVEOCCUPIED = ONSPTEMPTEST = 76COOLING = ONCOOLCTRLTEST STATUS = ACTIVE
Add PR Statement toYour Program
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-15
Later, once the program is working properly, you can remove the debugging PR statements.
Figure 14-9. Multil ine Looping Program with Debuggi ng PR Statements
2. You can also add PR statements to print each point value after any statement that may change that point value.
File Edit Search Check Tools
LINE NOTHEATING
IF THE OutsideAir < 50 THEN GOTO START.BURNER
TURN OFF THE Burner AND THE HWPump1
ENDIF
LINE START.BURNER
OPEN THE HWP1ISOValve
CENTRALPLANT HEAT.NOHEAT
ELSE
TURN ON THE Burner IF TM > 3 THEN
LINE ADJUSTING
IF THE OutsideAir > 50 AND TM > 3 THEN GOTO NOTHEATING
IF THE WEEKDAY IS NOT SUNDAY THEN
ELSESET THE HWsetpt TO 130
SET THE HWsetpt TO 100
CLOSE THE HWP1ISOValve AND THE CONVRTR.PRGM
TURN THE BurnerHiFire ON ’Sets Burner to High
TURN ON THE HWPump1
ENDIF
START THE CONVRTR.PRGMGOTO ADJUSTING
ENDIF
PR CURRENTLINE, TIME
PR CURRENTLINE, TIME
PR CURRENTLINE, TIME
Add PR Statements t o a Program
www.PDF-Zoo.com
Debugging Techniques
14-16 Infinity Controller Programmer’s Guide
The NOHEATING line would be as follows:
LINE NOTHEATING
PR CURRENTLINE, TIME
PR OutsideAir
IF OutsideAir < 50 THEN GOTO START.BURNER
ELSE
TURN OFF THE Burner AND THE HWPump1
PR Burner, HWPump1
CLOSE THE HWP1ISOValve
PR HWP1ISOValve
CLOSE THE CONVRTR.PRGM
PR CONVRTR.PRGM STATUS
ENDIF
3. Open the Messages window as described in Chapter 9. Here you see the results of PR statements from programs.
Figure 14-10 shows the messages from HEAT.NOHEAT that print in the window.
See PR Results inMessag e Window
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-17
Figure 14-10. Messages Tracing HEAT.NOHEAT
Notice how you can follow the action of the program by the name of the current line. HEAT.NOHEAT goes from NOTHEATING to NOTHEATING to START.BURNER.
You can see that the reason the program proceeds toSTART.BURNER is because the OUTSIDEAIR drops below 50 degrees.
4. Close and reopen the Messages window to see updates of the program activity. The Messages window can hold up to 48 physical lines.
Edit View Connect Logout
Messages – BLDG1 FLOOR1
CURRENTLINE = NOTHEATINGDATE = 10/25/91 22:36:56
CONVRTR.PRGM STATUS = INACTIVEHWP1ISOValve = OffHWPump1 = OffBurner = OffOutsideAir = 50.1degrees F
CURRENTLINE = NOTHEATINGDATE = 10/25/91 22:37:08
DATE = 10/25/91 22:37:12CURRENTLINE = START.BURNEROutsideAir = 49.7 degrees F
EXIT CLEAR
Current Line Tells Action Program Is Taking
www.PDF-Zoo.com
Debugging Techniques
14-18 Infinity Controller Programmer’s Guide
Employing a Debugging Program That Prints on t he Status BarIf you use a function, you have to keep rerunning the function. If you use a GOTO loop in a program, you have to open, close, and reopen the Messages window—or do you? You have another alternative.
Suppose you do not want to go to the Messages window. In-stead, while you look at the program you are debugging, you want to see the values of points, attributes, and the current line updating continuously.
You can have a debugging program that prints values on the status bar. The status bar continuously updates. See Chapter 11 for how to change the status bar if you have never changed it. Below are steps to write a debug status bar program:
1. Open a new program file. For the example, name it STATUS.DEBUG.
2. Make the program AUTOSTART and its FLOWTYPE looping.
3. Enter a single formatted PRINT statement to print all the point names and their values in a row, one after another. (Remember, the status line is only one line.) Do not use PR.
4. End the PRINT statement with TO COMM3 STATUSBAR (or to the terminal name you changed COMM3 to, such as SCREEN1).
Figure 14-11 , for example, shows a formatted PRINT statement that would print point values from HEAT.NOHEAT.
Look at Point ValuesWhile Program Disp lays
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-19
Figure 14-11. Status Bar Disp lay Program for Debuggi ng—Loo ping
5. Save the program. Until you run HEAT.NOHEAT, the status bar debugging program says the current line is 0 and all the points in the program remain on one setting.
6. Run the program you are debugging. In this case, it is HEAT.NOHEAT.
Notice that the status bar, at the bottom of the screen, prints the point names and values. Each one updates every scan and the information remains on the screen until you stop or disable the STATUS.DEBUG program.
You can delete the debugging program when you have debugged the main program. Or you can modify it to debug the next program.
Now that you have seen some debugging techniques, you are ready to debug some sample programs.
File Edit Search Check Tools
‘Prints Point Values from HEAT.NOHEAT
FLOOR1 BLDG1 STATUS.DEBUG
PRINT "CurrentLine: |@@@@@@@@@@@@ Time: |* OutsideAir:~ |###.# Burner: |$### HWPump1: |$### HWP1ISOValve: |$###~ CONVRTR.PRGM STATUS |@@@@@@@@ Burner Fire |* HWsetpt~|* , HEAT.NOHEAT CURRENT LINE, TIME, OutsideAir, Burner,~HWPump1, HWP1ISOValve, CONVRTR.PRGM STATUS, BurnerHiFire,~HWsetpt TO SCREEN1 STATUSBAR
CurrentLine: Heating Time: 2/25/91 08:09:14 OutsideAir: 42.2 Burner: On HWPump1: ON
Current Line Tells Action Program Is Taking
www.PDF-Zoo.com
Debugging Techniques
14-20 Infinity Controller Programmer’s Guide
Debugging Sampl e ProgramsBoi lerControl Stays on Fi rst Line
Suppose the boiler control process begins, but then often does not progress to the point where the space is properly heated, especially late in the day. The process is run by a program called BOILERCONTROL.
First, look at the program summary. BOILERCONTROL is active and on the SHUTTINGDOWN line.
Now look at the program file.
Figure 14-12 shows the BOILERCONTROL program.
Figure 14-12. BoilerControl Program—Loop ing
Why Program Is NotFully Executed
File Edit Search Check Tools
FLOOR1 BLDG1 BoilerControl
Turn OFF BlrStage1 AND BlrStage2ShuttingDown:
’Started by OutsideAirTest Program
If BlrEnable is ON then GOTO StartingUp
StartingUp:Turn ON BlrStage1Goto Waiting
Waiting:If TS > 119 THEN GOTO BeginningStage1
BeginningStage1:Turn ON BlrStage1Turn OFF BlrStage2If BoilerPSI < StmSetpt – 0.5 and TM > 3 THEN GOTO RunningHiFire
RunningHiFire:Turn ON BlrStage1, BlrStage2If BoilerPSI > StmSetpt + 0.25 and TM > 3 then goto BeginningStage1
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-21
After SHUTTINGDOWN, the program should go to STARTINGUP. For some reason, it never gets there. Is this where the bug is? The GOTO statement sends the controller there. How could the program remain on the SHUTTING-DOWN line?
It could keep starting over. Another program could START or RUN it, which begins it on the first line in the program.
Find out how BOILERCONTROL starts. In this case, a fallth-ru program, triggered by the outside air temperature, starts and stops the BOILERCONTROL.
Figure 14-13 shows the outside air program.
Figure 14-13. FallThru Outs ideAir Test Program to Start and Stop BoilerControl Program
The error could be here. To be sure, disable this program and start the BOILERCONTROL program manually. If the entire BOILERCONTROL program executes without any difficulty, then OUTSIDEAIRTEST is the source of the problem.
Why would this program start the BOILERCONTROL program more than once? If you use a debug program on it, you find that the OUTSIDEAIR point is updating as follows: 63, then 62.5, then 62, and so on. Each time, OUTSIDEAIR
Program Never Runs a Particular Line
File Edit Search Check Tools
FLOOR1 BLDG1 OutsideAirTest
If OutsideAir > 66 THEN STOP BoilerControlIf OutsideAir < 64 THEN START BoilerControl’Trigger: OutsideAir
www.PDF-Zoo.com
Debugging Techniques
14-22 Infinity Controller Programmer’s Guide
is less than 64, so the controller carries out the statement after THEN on the first line, even if BOILERCONTROL is already active.
So OUTSIDEAIRTEST constantly starts BOILERCONTROL at SHUTTINGDOWN, never letting it progress to any other line.
To correct this problem, alter the OUTSIDEAIRTEST program.
Figure 14-14 shows the altered outside air program.
Figure 14-14. Corrected OutsideAirTest Program
Looping Program Alw ays Skips Step
Suppose a looping program always skips a particular step.
Figure 14-15 shows a program that bounces between STARTUP and WAIT lines in the program summary, and never executes BURNHIFIRE.
Notice that the WAIT line tests to see if BOILERPSI is below setpoint by half a pound and if 30 minutes have gone by. If nei-ther of these has happened, the program goes back to STARTUP.
Prevent FrequentlyStarting
File Edit Search Check Tools
FLOOR1 BLDG1 OutsideAirTest
If BoilerControl STATUS IS NOT Active and OutsideAir < 64 THEN’Trigger: OutsideAir
If BoilerControl STATUS IS Active and OutsideAir > 66 THEN
START BoilerControl
STOP BoilerControl
ENDIF
ENDIF
Use TS in an IF..THENwithout ELSE
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-23
Since elapsed time is never 30 minutes initially, the controller immediately carries out the ELSE statement on the WAIT line and never carries out the THEN statement. To prevent this problem, never use ELSE in the same IF..THEN statement with TS, TM, TH, or TD.
Figure 14-15. Bo iler Ctrl Program wit h ELSE Error
Figure 14-16 shows the corrected program without ELSE.
Figure 14-16. Corrected BoilerCtrl Program—Loop ing
ELSE with Elapsed Time Is Alwa ys a Bug
File Edit Search Check Tools
StartUp:FLOOR1 BLDG1 BoilerCtrl
Start BoilerStage1
Wait:IF BoilerPSI < StmSetpt – 0.5 AND TM > 30 THEN goto BurnHiFire
BurnHiFire:Start BoilerStage2
GOTO Wait
ELSE GOTO StartUp
If BoilerPSI > StmSetpt + 0.25 AND TM > 10 THEN GOTO StartUp
Stop BoilerStage2
File Edit Search Check Tools
FLOOR1 BLDG1 BoilerCtrl
Wait:IF BoilerPSI < StmSetpt – 0.5 AND TM > 30 THEN goto BurnHiFire
BurnHiFire:Start BoilerStage2If BoilerPSI > StmSetpt + 0.25 AND TM > 10 THEN GOTO StartUp
StartUp:
Start BoilerStage1GOTO Wait
Stop BoilerStage2
www.PDF-Zoo.com
Debugging Techniques
14-24 Infinity Controller Programmer’s Guide
Valve Fails to Pul se
A looping program is designed to repeatedly pulse a valve to –ON for 5 seconds, then turn it off. But the program does not actually pulse the valve; instead, it opens the valve to –ON and keeps it open for an indefinite length of time.
Figure 14-17 shows the PULSEVALVE program. Notice that the HILIMITCHECK line repeats until the discharge temperature is below the high limit.
Figure 14-17. PulseValve Program wit h Error—Loop ing
Since the program stays on the line that sets the valve to –5, the line repeats so quickly that the valve does not pulse open, then close, but remains open.
The valve remains open until the program leaves the line and the 5 seconds can elapse.
The only way to repeatedly pulse the valve is to add another line that resets it to OFF.
Why Valve Never Closes
File Edit Search Check Tools
LINE HiLimitCheck
FLOOR1 BLDG1 PulseValve
Set Valve to –5ELSE GOTO WithinLimit
IF DischargeTemp > DischargeHiLimit THEN
ENDIF
LINE WithinLimitAdjustFactor = ValveSet(1, SpaceTemp, 40, Setpt, 0.75, 0.05, 0.05,~
0.5, Total, Err, Lt)If AdjustFactor > 0.05 or AdjustFactor < –0.05 THEN
Valve = Valve + AdjustFactor * 60GOTO HiLimitCheck
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-25
Figure 14-18 shows the program with the additional line that corrects it.
Figure 14-18. Corrected PulseValve Program—Loop ing
Notice that the test for the number of seconds that have elapsed falls after the ELSE statement in the HILIMITCHECK line. Otherwise, you would have ELSE after TS, which would make the controller go to WITHINLIMIT every time.
(Under WITHINLIMIT the program uses a user-defined function called VALVESET that is like a PID loop.)
File Edit Search Check Tools
LINE HiLimitCheckFLOOR1 BLDG1PulseValve
Set Valve to –5
LINE ResetValveSet Valve to 0
LINE WithinLimitAdjustFactor = ValveSet(1, SpaceTemp, 40, Setpt, 0.75, 0.05, 0.05,~
ELSE GOTO WithinRange
GOTO HiLimitCheck
IF DischargeTemp > DischargeHiLimit THEN
0.5, Total, Err, Lt)If AdjustFactor > 0.05 or AdjustFactor < –0.05 THEN
Valve = Valve + AdjustFactor * 60GOTO HiLimitCheck
IF TS > 30 THEN GOTO ResetValve
ENDIF
Check Elapsed Timeafter ELSE Statement
www.PDF-Zoo.com
Debugging Techniques
14-26 Infinity Controller Programmer’s Guide
Prog ram Never Alters Valve Setti ng
Suppose you have another version of the PULSEVALVE program that never changes the valve setting.
You check the program status and find it is enabled and active, but that no line name appears under current line. What is going on here?
Figure 14-19 shows the program. Can you determine what is wrong now?
Figure 14-19. PulseValve Progr am That Sets Setpoi nt but Fails—Loopi ng
The controller goes to the unlabeled line that sets the constants KP, KI, and KD for the VALVESET function. What happens next? The controller never leaves that line because no GOTO
Why Valve NeverChanges
File Edit Search Check Tools
LINE HiLimitCheck
FLOOR1 BLDG1 PulseValve
Set Valve to –5
LINE ResetValveSet Valve to 0
LINE WithinLimitAdjustFactor = ValveSet(1, Space1Temp, 40, Setpt, KP, KI, KD,~
ELSE GOTO WithinRange
GOTO HiLimitCheck
IF DischargeTemp > DischargeHiLimit THEN
0.5, Total, Err, Lt)If AdjustFactor > 0.05 or AdjustFactor < –0.05 THEN
Valve = Valve + AdjustFactor * 60GOTO HiLimitCheck
IF TS > 30 THEN GOTO ResetValve
Numeric KP, KI, KDSet KP = 0.75Set KI, KD = 0.05
ENDIF
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-27
ever tells it to. Be careful when you set a value at the beginning of a program that you also go to a line.
Figure 14-20 shows the corrected program.
Figure 14-20. PulseValve Progr am That Sets Setpoi nt and Pro ceeds—Loop ing
You could also label the first line so its name appears in the program summary, but if you do not, Infinity interprets it as an implied line.
Occasionally you may experience a situation where an error occurs that is unavoidable—such as being unable to retrieve a point value because the controller is off-line. The next section gives a technique for dealing with such errors.
Check Elapsed Timeafter ELSE Statement
File Edit Search Check Tools
LINE HiLimitCheck
FLOOR1 BLDG1 PulseValve
Set Valve to –5
LINE ResetValveSet Valve to 0
LINE WithinLimitAdjustFactor = ValveSet(1, Space1Temp, 40, Setpt, KP, KI, KD,~
ELSE GOTO WithinRange
GOTO HiLimitCheck
IF DischargeTemp > DischargeHiLimit THEN
0.5, Total, Err, Lt)If AdjustFactor > 0.05 or AdjustFactor < –o.05 THEN
Valve = Valve + AdjustFactor * 60GOTO HiLimitCheck
IF TS > 30 THEN GOTO ResetValve
GOTO HiLimitCheck
Numeric KP, KI, KDSet KP = 0.75Set KI, KD = 0.05
ENDIF
www.PDF-Zoo.com
Debugging Techniques
14-28 Infinity Controller Programmer’s Guide
Indi cating an Error wi th Line ESuppose you have run a program that retrieves point values from another controller. When that other controller goes off line, the program becomes disabled. This is a situation you want to prevent. But how do you prevent it? You use LINE E.
If you create a line called LINE E, when an error has occurred, the program goes to LINE E automatically—instead of disabling the program.
If you have LINE E in a program, when an error occurs and the program goes to it, you can see E as the line in the File Details window.
Figure 14-21 shows the File Details window displaying E as the Current Line .
Figure 14-21. Line E as Current Line in File Details Window
But how do you know where the error occurred? You can employ another form of tracing along with LINE E.
Set Up L INE E for Errors
Default Port
Last Changed SAVE
CANCEL
Current Line
Current Line Start
File Size
Program Status
Details – CENTRALPLANT HEAT.NOHEAT
COMM3
10/5/93 8:03 AM
10/30/93 10:01 AM
E
100
Active
File Edit Search Check Logout
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-29
To trace the source of the error, whenever the program goes to a new line, you set a local variable to the name of the line.
You could then have LINE E print a message about the line the program was on when the error occurred in addition to taking other action.
For instance, suppose the HEAT.NOHEAT program is retrieving point values from another controller.
To avoid having the program disable when the controller goes off line, you could set local variables called ACTION and TIMELINE on each line. You would set those local variables on the NOTHEATING line as follows:
LINE NotHeatingACTION = CURRENTLINE
TIMELINE = TIME
IF THE Building 1 OutsideAir Value < 50 THEN
GOTO START.BURNER
ELSE
TURN OFF the Building1 Burner
TURN OFF the Building1 HWPump1
CLOSE the Building1 HWP1ISOValve
CLOSE the Building1 CONVRTR.PRGM
ENDIF
Retrieve Point Values from Anoth er Controller
www.PDF-Zoo.com
Debugging Techniques
14-30 Infinity Controller Programmer’s Guide
You could then add the following to LINE E:
LINE EPrint "Error in Heat.Noheat on |* at |*", Action, ~Timeline
IF TS > Building1 ProbeTime Then
GOTO NotHeating
ENDIF
In this case, LINE E waits for the number of seconds equal to the PROBETIME attribute of Building1—how long it takes to update its communications status from being off-line to being on-line.
Direc ting Program Respon se Basedon Where Error O ccurred
Does it make a difference if the error retrieving the value of OUTSIDEAIR occurs on the NOTHEATING line or the ADJUSTING line? Of course it does.
If the error occurs on NOTHEATING, you want to return there after waiting for the required number of seconds. If the error occurs on ADJUSTING, you want to return to that line instead.
To have the controller take a distinct action based on the line the error occurred on, add the following to LINE E:
If Action = Adjusting Then
If TS > Building1 ProbeTime Then Goto Adjusting
Endif
If Action = NotHeating Then
If TS > Building1 ProbeTime Then Goto NotHeating
Endif
Program Goes to LIN E EIf Erro r Occurs
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-31
Figure 14-22 shows how the program changes using LINE E.
Figure 14-22. Looping Program with Local Variables to Store the Line Where and Time When the Erro r Occurs
File Edit Search Check Tools
Line NotHeating
If The Building1 OutsideAir Value < 50 Then Goto Start.Burner
Endif
Open The Hwp1ISOValve
CENTRALPLANT HEAT.NOHEAT
...
Line Adjusting
If The Building1 OutsideAir Value > 50 and TM > 3 Then Goto NotHeating
If The Weekday Is Not Sunday Then ...
Turn the BurnerHiFire On ’sets Burner To High
Turn On The HWPump1
Endif
Set Action = Currentline
Set Action = Currentline
Set Timeline = Time
String ActionDateTime TimeLine
Set Timeline = Time
Set Timeline = Time
Line Start.Burner
Turn On The Building1 Burner If Tm > 3 Then
Start The Building1 Convrtr.PrgmGoto Adjusting
Endif
Set Action = CurrentLine
When Building1 is off-line, the program cannot retrievethe OutsideAir point value,so it goes to Line E.
www.PDF-Zoo.com
Debugging Techniques
14-32 Infinity Controller Programmer’s Guide
Figure 14-22. Looping Program with Local Variables to Store the Line Where and Time When the Erro r Occurs (cont)
Although LINE E helps you debug, it can also remain in the program permanently—unseen unless an error occurs. You can put it in many programs to help you follow up on problems like this one described here. With LINE E, once a program is functioning, the controller never disables it.
Line E in Loo ping or Fall Thru Progra ms
Since HEAT.NOHEAT is looping, the program does not go to LINE E unless an error occurs. In a fallthru program, however, the program can fall through to LINE E. So, in a fallthru program, you should place LINE E at the end and be sure to use STOP on the line before LINE E; otherwise, the program goes to line E as part of the falling through process.
Employ ing a Debug ging F uncti onin Program with LINE E
Since adding the statements that set ACTION and TIMELINE is repetitious, you may want to put them into a function called DEBUGINFO to avoid repeating them in the program.
File Edit Search Check Tools
Line EPrint "Heat.Noheat Failed On Line |* at |*", Action, TimelineIf Action = NotHeating and TS > Building1 ProbeTime Then
Goto NotHeatingEndifIf Action = Adjusting and TS > Building1 ProbeTime Then
Goto AdjustingEndif
LINE E Dif fersfrom Tracin g Techniq ue
www.PDF-Zoo.com
Debugging Techniques
Infinity Controller Programmer’s Guide 14-33
Figure 14-23 shows such a DEBUGINFO function.
Figure 14-23. DebugInfo Function
You can then have the program call the function rather than setting the ACTION and TIMELINE values in the program. You call the function from each line of the program:
DebugInfo (Action, TimeLine)
You can also add other arguments to the function.
LINE E is useful in a variety of situations where errors can occur even though the program is normally error free. Some examples of such situations are the following:
• Programs that use GETNAME
• Programs that use GETOBJECT
If GETNAME tries to retrieve a name that does not exist, the program eventually disables. If GETOBJECT gets an object from the controller and then, while working with that object, the controller goes off line, the program disables. In both of these cases LINE E can keep the program running.
File Edit Search Check Tools
CENTRALPLANT DebugInfo
Arg 1 Action
Arg 2 TimeLine
Set Action = CurrentLineSet TimeLine = Time
Return
www.PDF-Zoo.com
Debugging Techniques
14-34 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Chapter 15
Programming the DCX Screen
Your Infinity CX 9000 controller may have a 4.9 × 4.2 inch liquid crystal display (LCD) screen in the upper right front door of the cabinet. This screen is the DCX 250. You may also have a DCX 250 located elsewhere in the building, connected to the control system via Infinet.
You use the DCX 250 to display predrawn controls or your own graphics/text, and to receive operator responses.
This chapter shows how to program the DCX screen:
• Understanding Predrawn Graphic Control Types
• Placing Predrawn Button Control on DCX Screen
• Placing Other Control Styles on DCX Screen
• Drawing Your Own Graphics on DCX Screen
• Drawing Your Own Air Handler Unit with Polygons
• Receiving Responses from the DCX Screen
• Erasing the DCX Screen
• Making the DCX Beep and Stop Beeping
• Making the Background Light Flash On and Off
• Making Text Blink
www.PDF-Zoo.com
DCX Screen
15-2 Infinity Controller Programmer’s Guide
Under standing P redrawn Graphic Con trolsA control is a graphic that represents a single point or point at-tribute. An example would be a knob that you can use to either display the setting of or set the air flow. Or a button that can en-able or disable the point because it represents the point’s STATE attribute. Or, perhaps, a switch you can use to open or close a valve, turn on or off a light.
You can display a button, knob, switch, or similar graphic from the set of predrawn controls and program it to work with a partic-ular point or attribute. Or you can draw a graphic control of your own.
If you are unfamiliar with the predrawn graphic controls you can place on the DCX screen, refer to Appendix C of this manual.
The controls are of several classes:
• Buttons
• Switches
• Knobs/Gauges
• Sliders
• Levels
• Text
Defining Type s of Graphic Controls
All controls display a point value. You can also allow the opera-tor (user) to change the point value through the control; for example, turn the knob to set a temperature.
Buttons
Buttons are graphics you can press (with your finger) to do one of the following:
Get Predrawn Graphicsfrom Library
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-3
• Change the screen
• View another graphic
• Change a point or attribute setting
• Acknowledge an alarm
Swit ches
Switches are graphics you can touch to turn on or off a point. You can also use a switch to set any digital (two-position) point or any attribute that has only two values, such as the STATE (enabled or disabled).
Knobs /Gauges
Knobs and gauges are graphics that you can turn in an arc or cir-cle to display (or set) a point value.
Slid ers
Sliders are graphics that show several possible values and a slid-ing arrow that points to (or you can set to) the value.
Levels
Levels are graphics that show a shape that fills up (like mercury in a thermometer) to indicate the value of a point. (You can also fill the shape to set the value).
Text
Text is exactly what it sounds like—words or numbers that indi-cate the value of a point. (You may also set the value in text.)
You can have up to 24 graphic controls on a single DCX 250 dis-play at one time.
The next section covers how you can place predrawn controls on the DCX 250.
Knobs and Gauges Turn in an Arc or Circle
www.PDF-Zoo.com
DCX Screen
15-4 Infinity Controller Programmer’s Guide
Placing a Predr awn B utton Control on DCX S creenSuppose you want to place a predrawn three-dimensional but-ton on the DCX 250 screen and label it FAN2. The button should turn on and off the fan.
Before You Place a Control
Before you place the control, always be sure to carry out these steps:
1. Connect to the DCX 250 through the Connect menu.
2. Open a file and set its FLOWTYPE attribute to FallThru .
3. Begin the program by erasing any graphic or text already on the screen that you do not want to display along with this control.
Once you display any graphic control, graphic, or text, it remains on the screen until you erase it from a program. If you display a second control without erasing the first, both appear.
4. Turn on the background light. If you do not turn on the background light, the control never appears.
Erasing t he DCX 250 Screen
You erase the DCX screen with the CLEARSCREEN keyword. It erases all text and graphics currently on the screen, but leaves all screen attributes (such as the screen color) and system vari-ables (more later) set to their current values. You give the word alone, as follows:
CLEARSCREEN
You can use CLEARSCREEN only in a program, not on the command line.
Enter CLEARSCREEN toErase DCX Screen
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-5
Turning o n the Back groundLight
To turn on the background light for a particular length of time, you can set the background light to the number of seconds.
The following statement turns it on for 1 minute:
BACKLIGHT = 360
The following statements turns it on or off indefinitely:
TURN ON THE BACKLIGHT1
TURN OFF THE BACKLIGHT
You must turn on the background light before you display a graphic control. If you do not, the control does not appear.
You are now ready to display the control. You need the following information about the control:
• Style Number
• Location
• Whether or not operator should be able to change the point value using the control.
• Name and path to the point or attribute
• Number of settings the control can be set to (called steps)
You may also want to include a title to label the control.
Determini ng the Style Numbe rof the Control
If you have not yet looked through Appendix C, go to it now and look at Control Style 1—the button that appears three-dimen-
1. Because the background light has a limited life span, always turn off thebackground light within minutes of turning it on. Never leave it on for pro-longed periods.
Turn On or Off theBackg round Light
www.PDF-Zoo.com
DCX Screen
15-6 Infinity Controller Programmer’s Guide
sional. This control is the one you place on the DCX 250 screen in this section.
Determini ng Lo catio non the Screen
To give the location of the button on the screen, you tell Infinity the position of the lower left corner of the button, then the upper right corner. How? Picture the screen covered by hundreds of tiny dots. It has 200 dots up and down and 320 dots across.
As shown in Figure 15-1, the dots, called “line points,” are numbered from the lower left corner to the top and to the right.
You refer to a line point location by first its horizontal position, then its vertical position. For example, 15, 20 is the line point that is 15 dots across from the left and 20 dots up from the bottom.
Figure 15-1. Line Poin ts on the DCX 250 and Location of Line Point 15, 20
1, 200
320,1
1,1
+ (15, 20)
Lin e Points Positi onControl on DCX Screen
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-7
Telling Infin ity to Displa y the Control
To display a button control (Control Style 1) in the approxi-mate center of the screen, you enter the information you have collected with the CONTROL keyword. The format for the CONTROL keyword is as follows:
CONTROL (style, left, bottom, right, top, user_change, point_or_attribute_path, title, frame, direction, bot_scale, top_scale, tickmarks, steps, format)
Figure 15-2 shows how you would use CONTROL to enter the information required to display the button control for the fan.
Figure 15-2. Button Cont rol Progr am Statement
You always give the style first, then the location, then the TRUE or FALSE for whether the operator can change the val-ue, and the path to the point. These pieces of information are required. The order is always the same, so that the controller knows what each piece of information means. None of the other information you could give for other controls applies to the button control.
File Edit Search Check Tools
FLOOR1 DISPLAY1 FanButton
CONTROL (1, 40, 75, 280, 125, TRUE, FLOOR1 ROOM2 Fan2 , " Fan 2")
Control Style
LocationControllerand Point Nameon Screen
Title forGraphicControl
When TRUE, Operator Can Change Setting
(optional)
www.PDF-Zoo.com
DCX Screen
15-8 Infinity Controller Programmer’s Guide
After the path to the point, you can give the control a title. No-tice that the title is in quotation marks—they are required. The title itself, however, is not required. The button can be blank.
Figure 15-3 shows the complete FANBUTTON program, which erases the screen, turns on the background light, then displays the control. Pressing the button toggles the fan between ON and OFF. The button flashes when you press it, but otherwise does not indicate the value of the point.
Figure 15-3. Compl ete FanButton Pr ogr am
Figure 15-4 shows how the button appears.
Determini ng the Size of th e Button
This program would display Control Style 1 as a 240 line point wide by 50 line point high rectangle with the title “Fan 2.” All rectangular shaped controls (such as Control Styles 1 and 2) stretch to fit tall/wide areas and shrink to fit short/narrow areas. Try altering the left, bottom, right, and top values to see how they change the shape and size of the button.
This control style (1) and Control Style 2 must be a minimum (in line points) of 40 wide by 25 high.
Title Should Be inQuotation Marks
File Edit Search Check Tools
FLOOR1 DISPLAY1 FanButton
CLEARSCREENTURN ON THE BACKLIGHTCONTROL (1, 40, 75, 280, 125, TRUE, FLOOR1 ROOM2 Fan2, " Fan 2")
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-9
Figure 15-4. Fan 2 Button on DCX 250 Screen
Selecti ng the Button Frame
For control styles 1 and 2, you cannot give a frame style (see end of Appendix C), because the frame is automatically included with the control. If you give a frame style, Infinity ignores it.
Other Arguments for CONTRO L
Notice that the direction, bottom and top of scale, tickmarks, steps, and format are not required. Because you did not specify them, the bottom and top of scale are automatically OFF and ON, because the fan is a digital point. All buttons and switches (con-trol styles 1, 2, 3, 4, and 5) are digital and always set top and bottom of scale automatically.
You do not include the number of steps, because for any dig-ital control, Infinity assumes a single step between two values. So the step information is not applicable to buttons and switches.
Fan 2
Directio n, Steps, and Format Not Appli cabl e
www.PDF-Zoo.com
DCX Screen
15-10 Infinity Controller Programmer’s Guide
Placing Other Control Styles on t he ScreenWhile rectangular shaped controls (such as Control Styles 1 and 2) stretch to fit tall/wide areas and shrink to fit short/narrowareas, gauge controls such as Control Styles 7 and 8 retain their shape.
Setting Con trol Siz e
When you specify the left, bottom, right, and top, Infinity auto-matically sizes the control to fit into the area you designate unless it is Control Style 3, 4, or 5 (switches), or Control Style 6 (knob).
You cannot resize Control Styles 3, 4, 5, or 6. However, when you give the location for any of the switches (Control Styles 3, 4, and 5), the center of the control must be at least 21 line points from any edge of the screen. The center of a knob (Control Style 6) must be at least 30 line points from any edge of the screen.
If you designate a tall narrow area for a gauge control, its width fits the area and its height becomes proportional to the width.
As shown in Figure 15-5, the gauge control is then vertically centered within the space you have defined (crosshatches (+) show the locations of the left-bottom and right-top).
On the other hand, if you designate a short wide area for acircular control, its height fits the area and its width becomes proportional to the height. The control is then horizontally centered within the space you have defined.
If the control cannot display in the space you give, Infinity dis-ables the file; you can then find the error message in the File Configuration window. Any time the control does not ap-pear, check the size area you designated.
GaugeControls Ret ain Shape
You Cannot ResizeSwit ches or Knobs
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-11
Figure 15-5. Loc ation and Size of Control Style 7 on DCX 250 Screen
Any control style that you can resize never displays unless it is at least the size of one cell on the DCX 250—approximately 0.5 inch square. What are cells? The DCX 250 screen has an underlying grid of 64 squares, approximately .6 × .5 inch. The blocks are called “cells” or “touch cells.”
Figure 15-6 (on the next page) shows where the cells are on the screen. Infinity can sense when you have touched one of these cells. You must position the control so that it can use these cells.
If a control is a button or switch, it can be as small as one cell, approximately 40 line points wide and 25 line points high. Any other control style must be at least two cells wide, 80 line points wide if horizontally positioned or 50 line points high if
+
+
Control Must Be on at Least Two Cells
www.PDF-Zoo.com
DCX Screen
15-12 Infinity Controller Programmer’s Guide
vertically positioned. (To be sure about the minimum size for any particular control, refer to Appendix C.)
Figure 15-6. DCX 250 LCD Screen Touch Cell Grid
Position ing th e Control
Notice that the gauge control has two arrows. You press these arrows to raise or lower the setting of the point or attribute.
If the control has arrows, it must be the size of at least two cells, rather than one. You should position this control so that the two arrows are each on top of separate cells.
The rule applies as long as you want the operator to have the option of setting the control. If you set that argument to FALSE, the arrows do not appear.
1 2 3 4 5 6 7 8
9 10 11 12 13 14 15 16
17 18 19 20 21 22 23 24
25 26 27 28 29 30 31 32
33 34 35 36 37 38 39 40
41 42 43 44 45 46 47 48
49 50 51 52 53 54 55 56
57 58 59 60 61 62 63 64
Put Each Arrow onSeparate Cell
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-13
Setting O ther Control Cha racteristics
Title
The title is always optional. Notice that for each controller style (see Appendix C), the title appears in a different location.
Frame Style
You do not have to give a frame style for most controls. You must, however, give Frame Style 3 for Control Style 3, the light switch; otherwise you get only the switch and it does not look like a typical light switch.
If you give a frame style, Infinity centers the frame style, rath-er than the control, in the area you designate. The frame resizes and reshapes (becoming a square or rectangle) to fit the area. Since the control fits inside the frame, the control ends up somewhat smaller than it would be without the frame.
Direction
The direction does not apply to any button, switch, knob, or gauge controls. It also does not apply to controls that display values as text (such as Control Styles 8, 9, 10, and 13).
Direction applies only to sliders with scales (Control Styles 11 and 12). You may position the sliders either horizontally or vertically. Set the direction for a slider control to either HOR-IZONTAL or VERTICAL.
Top and Bottom of Scale
For any button or switch control (Control Styles 1, 2, 3, 4, 5) you do not have to set a top and bottom of scale. Infinity automatical-ly sets them to ON and OFF for a digital point or to the two values of a digital attribute, such as ENABLED and DISABLED for STATE.
For Control Styles 6, 7, and 8, you must give a top and bottom of scale if the control does not represent a digital point or attribute.
Frame Style Op tio nal for Most Controls
Buttons and Switches Assu me ON/OFF
www.PDF-Zoo.com
DCX Screen
15-14 Infinity Controller Programmer’s Guide
If you do not give a top and bottom of scale, Infinity assumes ON and OFF or other digital values.
For Control Styles 8, 9, and 10, you must give a top and bottom of scale unless you assign it to a digital point or attribute.
TickMarks
Tick marks do not apply to buttons or switches, but they do apply to knobs and gauges. They also apply to sliders that point to a scale. You give the number of tick marks you want to appear.
Steps
The Control Styles 6, 7, and 8 are circular and semicircular con-trols. Unless you give a number of steps, they automatically set to one step for each degree in the arc of the circle—for example, 180 degrees in the semicircular controls, or 180 steps. The max-imum number of degrees is 240, not a full circle, but two-thirds of one. Infinity automatically places the 240 steps around the knob control if you do not give another number of steps.
If you do not give a number of steps greater than 1 for Control Styles 9 and 10, Infinity automatically sets the number to 1 step. The one step is the step from the initial setting (bottom of scale) to the alternative position (top of scale). This same setting applies to buttons and switches, but you do not have to designate steps for those controls.
Format
This format applies to the numbers that label the tick marks. Con-struct the format just as you would for a point format, using # and @ signs, % and $ signs, decimal points, or other symbols allowed (see the PRINT keyword). If you do not give a format for the numbers, Infinity allows enough space for numbers next to the tick marks to be four digits long with no decimal places.
Now, let’s try putting some controls on the DCX 250 screen us-ing this information.
Tick Marks Form a Scale
Set th e Format for TickMark Numbers
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-15
CONTROL Statement for Knobwith Scale
Suppose you want to display a knob, Control Style 6, to belocated in the center of the DCX 250 display.
You want the operator to be able to turn the knob. The knob always turns clockwise, so you do not have to concern your-self about the direction. The point the knob controls is on the FLOOR1 Infinity CX and the ROOM2 Infinet controller.
You want the knob to be in frame style 3 and to title the knob with the name of the point, AIRFLOW. For now, let’s make the point a digital one, where air flow is either off or on.
Figure 15-7 shows how you would enter this information with the CONTROL statement.
Figure 15-7. Knob Control CONTROL Program Statement
You always give the control style first, then the location, then the TRUE or FALSE for whether the operator can change the value, and so on.
Operator Can Turn Knob if Fifth Argument Is True
File Edit Search Check Tools
CONTROL 6, 10, 10, 310, 190, TRUE, Floor1 Room2 AirFlow , "AirFlow", , , , , , 1
Control Style
Location Controllerand Point Name
on Screen
When TRUE, Operator Can Change Setting
Title
Commas MeanSkipping Arguments
Steps
FLOOR1 DISPLAY1 KnobProg
www.PDF-Zoo.com
DCX Screen
15-16 Infinity Controller Programmer’s Guide
This style control is always one size. When you give the left, bottom, top, and right, Infinity automatically centers the con-trol in the area you designate, as long as the center of the knob is at least 30 line points away from any edge of the screen.
The extra commas indicate arguments you have left out.
Figure 15-8 shows how the control defined in the above CONTROL statement appears and where Infinity positions it on the screen (the crosshatches (+) show the locations of the left-bottom and top-right boundaries). Notice that this style control is centered within the boundaries.
This control is automatically a digital knob, because you did not specify a top or bottom of scale. The bottom of scale be-comes OFF and the top of scale becomes ON. If you did not specify the number of steps (1), you would never see the knob setting change, because it would automatically have 240 knob settings (one for each degree around the arc of the circle).
Figur e 15-8. Air Flow Knob Control (Control Styl e 6)
Infinity AutomaticallySizes Knob
+
+AirFlow
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-17
Add ing a Scale and Tic k Marks
Suppose you want to add seven tick marks to the knob and labels so you know the value of each position on the scale, from 60 to 180 cfm. You need to tell the controller the following:
• Bottom of scale (60)
• Top of scale (180)
• Number of tick marks (7)
• Number of steps to knob settings (6 between tick marks)
• Format for the scale values (###)
You would modify the CONTROL statement as follows:
CONTROL (6, 10, 10, 310, 190, TRUE, FLOOR1 ROOM2 AirFlow,~ "AirFlow", 3, , 60, 180, 7, 6, "###")
Figure 15-9 shows how the control looks.
Figure 15-9. Air Flow Control w ith Complete Scale
You Desig nate Number of Tick Marks
Insert a Comma forMissing Info rmation
AirFlow
60
80
100
120
140
160
180
www.PDF-Zoo.com
DCX Screen
15-18 Infinity Controller Programmer’s Guide
CONTROL Statement for Rotatio nal Needle Gauge
You may display a vertically positioned rotational needle gauge (Control Style 7) on the DCX 250 screen in any size that fits on the screen; however, it always maintains its proportions.
You can place the control in Frame Style 4 in the approximate center of the screen with 5 tick marks and allow the operator to set it to any of 9 values.
Figure 15-10 shows the CONTROL statement you would use to enter the information.
Figure 15-10. Rotat ional Needle Gauge Control CONTROL Program Statement
The 7 is the control style number.
The left, bottom, right, and top values position the frame so its lower left corner is at 50, 50 and its upper right at 280, 180. The control appears sized and centered within the frame (Frame Style 4, later).
Rotatio nal Needle GaugeIs Control Style 7
File Edit Search Check Tools
FLOOR1 DISPLAY1 AirFlowGauge
CONTROL 7, 50, 50, 280, 180, TRUE, ROOM6 AirFlow , "AirFlow", 4,, 50, 250, 5, 8, "###"
Control Style
Location Controllerand Point Nameon Screen
When TRUE, Operator Can Change Setting
Frame Style
Comma MeansSkipping Argument
Top andBottom of Scale
TickMarks
Steps
Format
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-19
Figure 15-11 shows the resulting control. If you gave the same position for the control without the frame, it would be somewhat larger.
Figure 15-11. Display of Rotational Needle Gauge (Control Style 7)
TRUE allows the operator to set the value of the control.
ROOM6 AIRFLOW is the path to the point.
“AirFlow” is the title of the control.
The 4 is the frame style. You can look up the frame styles in Appendix C.
Figure 15-12 shows how the frame style appears alone.
The extra comma after the 4 indicates you are leaving out an ar-gument—the direction. The direction does not apply to gauges. The gauge always turns clockwise.
Control Is Slig htly L arger without Fr ame
AirFlow
50
100
150
200
250
www.PDF-Zoo.com
DCX Screen
15-20 Infinity Controller Programmer’s Guide
The 50 is the bottom of scale, the 250 the top.
If you did not specify a bottom and top of scale, this control would automatically be a digital gauge. The bottom of scale would become OFF and the top of scale ON.
If you did not specify a number of steps, you would never see the gauge setting change, because it would automatically have 180 settings (one for each degree around the portion of the cir-cle the gauge is composed of).
Figure 15-12. Frame Style 4 wi thout a Cont rol
Must Specify a Top andBottom of Scale
Title
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-21
To specify a particular number of steps, set 5 as the number of tick marks, 8 the number of steps. Normally the control would have 4 steps with 5 tick marks. Because the control has 8 steps, it has an extra step between each pair of tick marks.
Why not assign 5 tick marks and 5 steps? Because each step is between two tick marks.
The unnumbered steps (settings) would be 75, 125, 175, and 225. You can set the needle to one of those values.
“###” is the format for the numbers around the gauge, three digits.
Now, let’s see how to place a text control on the DCX 250.
Tick Marks and Steps Are Never Equal
www.PDF-Zoo.com
DCX Screen
15-22 Infinity Controller Programmer’s Guide
CONTROL Statement for Valu e Barwith Raised Arr ows
Bars with text in them are text controls. You can choose Con-trol Style 8, 9, or 10 to display a value as text. You could also select Control Style 13 to display a date and time in the standard format.
When Infinity displays a value in a text control (other than a datetime), the value displays in the format for the point (from the Point Details window) that the control represents.
Figure 15-13 shows the CONTROL statement you would use to display a value bar with raised arrow buttons (Control Style 9) showing a temperature setpoint.
Figure 15-13. Value Bar Text Control wit h Raised Ar rows CONTROL Program Statement
The 9 is the control style number. After the style number, the left, bottom, right, and top values position the frame so its low-er left corner is at 150, 80 and its upper right at 250, 180.
Value Bars Are TextControls
File Edit Search Check Tools
CONTROL 9, 120, 75, 200, 125, TRUE, Floor1 Setpt2 , "Setpt Room 2", ,,, 60, 90, , 60
Control Style
Location Controllerand Point Name
on Screen
When TRUE, Operator Can Change Setting
Title
Commas MeanSkipping Arguments
Top andBottom of Scale
Steps
FLOOR1 DISPLAY1 SetptBar
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-23
Figure 15-14 shows the resulting control with the grid behind it. Note that the two arrows absolutely must be on separate touch cells—preferably with a grid line between them (bolded in the figure). If both buttons overlap a single cell in the middle, the control does not function correctly.
TRUE allows the operator to set the value of the control by pressing the arrow buttons.
FLOOR1 SETPT2 is the path to the point.
“Setpt, Room 2” is the title of the control. The extra commas af-ter the title indicate you are leaving out arguments—the frame and the direction—which do not apply to this control style.
The 60 is the bottom of scale, the 90 the top.
Figure 15-14. Display o f Value Bar wit h Raised Arrow Buttons (Cont rol Style 9)
Extra Commas Indic ate Missing Arguments
72.5
Setpt Room 2
www.PDF-Zoo.com
DCX Screen
15-24 Infinity Controller Programmer’s Guide
The 60 is the number of steps (one for every 0.5 degree between 60 and 90). If you do not include a number of steps, Infinity as-sumes 1 step, the number of steps for a digital control. But one step is not useful in this situation, because the one step would go from the bottom of scale to the top and vice versa.
CONTROL Statement for Slide r
The rules change from one control style to another. For in-stance, suppose you decide you want Control Style 12 (a slider, pointer, and scale—shown in Appendix C) to be locat-ed from 50, 50 (left and bottom) and 250, 125 (right and top).
For this particular control style, you must give the direction you want the slider to move, either horizontal or vertical. You want the operator to be able to slide the pointer up and down the scale. The point the slider controls is on the FLOOR1 In-finity CX and is called “TempSetpt.”
Figure 15-15 shows the CONTROL statement to draw the slider.
Figure 15-15. Slider CONTROL Program Statement
You Give Direct ion for aSlid er
File Edit Search Check Tools
FLoor1 TempSetpt
CONTROL (12, 50, 10, 250, 170, TRUE, FLOOR1 TempSetpt , "Setpt", 4,~
Control Style
Frame
Controllerand Point Name
Title forGraphicControl
Operator Can Change
Style(optional)
Direction(requiredfor this
(optional)
controlstyle)
Locationon Screen
horizontal, 60, 80, 5, 4, " ##" )
Top andBottom
TickNumber of Steps
Format
Marksof Scale
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-25
When you alter the area for a this control, Infinity sizes its height and width fit the area.
Figure 15-16 shows how the slider control appears in the DCX 250 screen. Compare this to the appearance of the sample Control Style 12 in Appendix C. Notice how the shape changes to fill the area you designate.
Figure 15-16. Display o f Slid er Control (Control Style 12)
Since the arguments required to draw each control differ from one style to the next, Appendix C includes not only a drawing of each type of control, but also the arguments required to display the control with the CONTROL statement.
TempSetpt
60 65 70 75 80
Append ix Gives Requ ire-ments fo r Each Contr ol
www.PDF-Zoo.com
DCX Screen
15-26 Infinity Controller Programmer’s Guide
Drawing Y our OwnGraphics on DCX ScreenYou can draw your own graphics on the DCX 250 using lines, circles, ellipses, squares, rectangles, polylines, and polygons. You use a series of keywords that are exclusively for the DCX controllers. Here are three of them:
DRAWLINE DRAWELLIPSE DRAWRECTANGLE
You tell the DCX two facts using these keywords:
• The shape to draw.
• The line points to join.
Drawing a Line
Before you draw a line, connect to the DCX from theConnect menu and open a program file. Position the line by telling the DCX about the two line points (dots) that mark the beginning and the end of the line.
Then use the word DRAWLINE to draw the line.
Draw the line as follows:
1. Indicate you want to draw a line:
DRAWLINE
Do not press the RETURN key yet.
2. Imagine the line on the DCX screen or draw it out on a grid.
Figure 15-17 shows where the line should be and the line points on either end.
Special Key words Drawon DCX Screen
DRAWLINE Draws Lines
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-27
3. Position the beginning of the line—how many line points across from the left, then how many up from the bottom. Add the position to the statement:
DRAWLINE 40, 25,
Figure 15-17. Line Points at Ends of Line
4. Position the end of the line the same way.
DRAWLINE 40, 25, 100, 125
Be sure to put commas between the numbers.
5. Now press the RETURN key to complete the statement.
When you run the program, the line appears on the DCX.
•
•
Beginningof Line (40, 25)
End of Line(100, 125)
+
+
Position the End of the Line
www.PDF-Zoo.com
DCX Screen
15-28 Infinity Controller Programmer’s Guide
Drawing a Rectangl e
Before you draw a rectangle, connect to the DCX from theConnect menu and open a program file. You position the rectangle by telling the DCX about the two line points that mark the lower left and upper right corners of the rectangle.
Draw the rectangle as follows:
1. Indicate you want to draw a rectangle:
DRAWRECTANGLE
Do not press the RETURN key yet.
Figure 15-18 shows where the rectangle should be and the line points in the lower left and upper right corners.
Figure 15-18. Line Points at Corners of Rectangle
DRAWRECTANGLEDraws Rectangles
Lower LeftCorner (40, 40)
Upper RightCorner (190, 75)+
+
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-29
2. Position the lower left corner—how many line points across from the left, then how many up from the bottom. Add the position to the statement:
DRAWRECTANGLE 40, 40,
3. Position the upper right corner the same way and add the position to the statement:
DRAWRECTANGLE 40, 40, 190, 75
Be sure to put commas between the numbers.
4. Now press the RETURN key to complete the statement.
When you run the program, the rectangle appears on the DCX.
You can make the rectangle a button or part of another drawing.
Drawing an El lipse
Before you draw an ellipse, connect to the DCX from theConnect menu and open a program file. Draw a rectangle. Then tell the DCX about the two line points that mark the low-er left and upper right corners. DRAWELLIPSE draws the ellipse so it fits inside the rectangle. Draw the ellipse as fol-lows:
1. Indicate you want to draw an ellipse:
DRAWELLIPSE
Do not press the RETURN key yet.
Figure 15-19 shows where the ellipse should be and the line points in the lower left and upper right corners of the imaginary rectangle that surrounds it.
Position Upper andLower Corners
DRAWELLIPSE Draws Ellip ses and Circles
www.PDF-Zoo.com
DCX Screen
15-30 Infinity Controller Programmer’s Guide
Figure 15-19. Ellip se wit h Line Points at Corners o f Imaginary Rectangle
2. Position the lower left corner—how many line points across from the left, then how many up from the bottom. Add the position to the statement:
DRAWELLIPSE 50, 70,
3. Position the upper right corner the same way and add the position to the statement:
DRAWELLIPSE 50, 70, 220, 125
Be sure to put commas between the numbers.
4. Now press the RETURN key to complete the statement.
When you run the program, the ellipse appears on the DCX. You can use the ellipse as a button or make it a part of another drawing.
Lower LeftCorner (50,70)
Upper RightCorner (220,125)
+
+
Ellip se Ap pears on theDCX Screen
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-31
Display ing T ext
After placing a predrawn control on the screen or drawing a con-trol of your own, you may want to print text to accompany it. You can display text on the DCX 250 using PRINT.
But first you position the text with a keyword called LOCATE. With LOCATE, you tell the DCX where the lower left corner of the first character should print. LOCATE uses the same line point locations that the CONTROL keyword used. Here is an example:
LOCATE 50, 190
PRINT "Building1 Temperatures"
Figure 15-20 shows text positioned near the top of the screen.
Figure 15-20. Text to Accompany a Graphic
The text you print with PRINT is not a control; you add it so the controls on the DCX 250 are easier to use.
You Posi tion Text with LOCATE
Lower LeftCorner (50,190)
+Building1 Temperatures
www.PDF-Zoo.com
DCX Screen
15-32 Infinity Controller Programmer’s Guide
Drawing Y our Own Designs on DCX ScreenYou can connect more than one line together in a continuous line called a “polyline.” Using these polylines you can draw almost any shape you would like.
Before you draw these lines, however, you may want to set the display characteristics of the DCX 250—including the col-or of the background, the color to draw, and whether or not to fill in a shape.
Setting Dis play Attribute s
You can change the color, make text or graphics blink, and change the drawing characteristics of the DCX screen display. You use the SETDISPLAY keyword in a program to set the screen display to these values:
Colors:
• BLUE
• WHITE
Drawing:
• FILL
FILL makes a series of lines a graphic filled with the color you have set.
• NOFILL
NOFILL does not make a series of lines a filled graphic.
You can set one attribute at a time or a list of them, as illustrated in the following examples:
SETDISPLAY (BLUE)
Multip le ContinuousLines Ar e a Polylin e
Change the Color andDrawin g Character ist ics
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-33
Once you enter this statement in a program, every line or graphic you draw is blue from now on, until you set the screen display to WHITE as follows:
SETDISPLAY (WHITE)
The following statement sets two display characteristics:
SETDISPLAY (BLUE, FILL)
Once you enter this statement in a program, every line or graphic you draw is blue and each graphic is filled in as a solid blue object.
Drawing Conne cted Lines
To draw “polylines,” you give the line points you want con-nected and then give the command to connect them into lines.
The keywords you use are the following:
BEGINPOLYLINE LINEPOINTENDPOLYLINE
Draw a polyline as follows:
1. Set the display drawing attribute to NOFILL:
SETDISPLAY (NOFILL)
If you were to draw a polygon (solid object), you would set the display to FILL instead of NOFILL.
2. Open the block with BEGINPOLYLINE.
3. Name the line point you want the line to start at:
LINEPOINT 10, 10
Switc h from WHITE to BLUE
www.PDF-Zoo.com
DCX Screen
15-34 Infinity Controller Programmer’s Guide
4. Name the next line point you want the line to go to:
LINEPOINT 20, 50
5. Repeat the last step until you have entered all the line points you want connected.
6. Close the block with ENDPOLYLINE.
Figure 15-21 shows a complete program.
Figure 15-21. EDGE.DR Program—FallThru
A Poly lin e Can Create aScreen Border
File Edit Search Check Tools
FLOOR1 DISPLAY1 EDGE.DR
SETDISPLAY NOFILLBEGINPOLYLINE
LINEPOINT 110, 200LINEPOINT 90, 180LINEPOINT 70, 200LINEPOINT 50,180 LINEPOINT 30, 200LINEPOINT10, 180
ENDPOLYLINE
CLEARSCREENTURN ON THE BACKLIGHT
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-35
Figure 15-22 shows the polyline the program draws.
Figure 15-22. Polyli nes on the DCX Screen
www.PDF-Zoo.com
DCX Screen
15-36 Infinity Controller Programmer’s Guide
Drawing Y our Own Air Handler Unit wi th PolygonsYou can connect more than one line together in a closed shape with as many sides as you want (up to 99 sides or 100 line points) to form a polygon.
You draw a polygon the same way you drew a polyline, only you change the display drawing attribute to FILL.
Draw a polygon as follows:
1. Set the display drawing attribute to FILL:
SETDISPLAY (FILL)
2. You can also set the display to draw the polygon in BLUE or WHITE.
3. Open the block with BEGINPOLYLINE.
4. Name the line point you want the outline of the polygon to start at:
LINEPOINT 10, 10
5. Name the next line point you want the outline of the polygon to go to:
LINEPOINT 20, 50
6. Repeat the last step until you have entered all the line points you want connected. The last line point should be the same line point you started with.
7. Close the block with ENDPOLYLINE.
Draw a Polygo n insteadof a Polylin e
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-37
Figure 15-23 shows the complete program.
Figure 15-23. AHU.DRAW Program—FallThru
File Edit Search Check Tools
FLOOR1 DISPLAY1 AHU.DRW
SETDISPLAY FILL, BLUEBEGINPOLYLINE
LINEPOINT 150, 130LINEPOINT 150, 100LINEPOINT 300, 100LINEPOINT 310, 75LINEPOINT 300, 50LINEPOINT 10, 50
LINEPOINT 310, 130
ENDPOLYLINE
LINEPOINT 300, 155LINEPOINT 310, 180LINEPOINT 20, 180LINEPOINT 10, 155LINEPOINT 20, 130LINEPOINT 70, 130LINEPOINT 70, 100LINEPOINT 10, 100LINEPOINT 20, 75LINEPOINT 10, 50
CLEARSCREENTURN ON THE BACKLIGHT
www.PDF-Zoo.com
DCX Screen
15-38 Infinity Controller Programmer’s Guide
Figure 15-24 shows the polygon the program draws. You can draw almost any shape this way.
Figure 15-24. Polyg on on the DCX Screen
Once you have drawn a polygon like this one, you can add other parts to the graphic to form fans and dampers. You can also add buttons and switches, whether predrawn or your own.
Figure 15-25 shows a more complete drawing of an air handler. You could enter ellipses and rectangles to form the fans. You would change the display settings to WHITE and FILL for each fan. You could then use LOCATE and PRINT to display the names of the fans.
Draw a Polyg on of AnyShape
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-39
You could use a value bar (Control Style 10), a simple text control, to display the setting (value) of each fan. No arrows display near the value because the operator cannot change the value (the fifth argument after CONTROL is FALSE).
Try adding to the AHU.DRW program to form these addition-al features.
Figure 15-25. A More Complete Drawin g of an Air Handler
You can create the customized buttons like those you see at the bottom of this air handler drawing. You can then create a customized response to each. But first you must determine how to read an operator response—using the TOUCHED-CELL system variable.
A More Complete Air Handler Unit
ON OFF ReturnAir SupplyAir
ReturnAir 130 cfm
SupplyAir140 cfm
www.PDF-Zoo.com
DCX Screen
15-40 Infinity Controller Programmer’s Guide
Receiving Responses from the DCX ScreenWhen you display your own graphics on the DCX 250, you can select an option or press a button with your finger. You can program the DCX so it knows how to respond.
Receiv ing O perator Resp onse s
Since the DCX 250 screen has no keypad, how do you respond to it? You touch the screen. The DCX senses the touch and knows the particular square (cell) you touched.
As shown in Figure 15-26, the cell you touched can be any of up to 64 squares, each approximately .6 × .5 inch.
Figure 15-26. DCX 250 LCD Screen Touch Cell Grid
The DCX stores the number of the cell in a system variable called TOUCHEDCELL. If you have touched the screen, you
DCX ReceivesOperator Response
1 2 3 4 5 6 7 8
9 10 11 12 13 14 15 16
17 18 19 20 21 22 23 24
25 26 27 28 29 30 31 32
33 34 35 36 37 38 39 40
41 42 43 44 45 46 47 48
49 50 51 52 53 54 55 56
57 58 59 60 61 62 63 64
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-41
do not have to know exactly where unless you have more than one button. If TOUCHEDCELL is greater than zero, then someone touched the screen. If that is sufficient information, you can have an IF..THEN statement say IF TOUCHEDCELL THEN... However, to find out the particular cell a button is on, edit the program that draws it and add the following:
1. Create a local numeric variable called CELLNUM.
2. Enter the following lines below the drawing statements:
TESTING:
IF TOUCHEDCELL THEN
CELLNUM = TOUCHEDCELL
GOTO PRINTING
ENDIF
PRINTING:
LOCATE 10, 10
PR CELLNUM, " "
GOTO Testing
These lines retrieve the number of the cell you touch and display it on on the DCX 250.
3. Run the program you have just altered.
4. Go to the DCX screen and press any part of the drawing with your finger.
5. You should press a button in the left, right, and middle to see if TOUCHEDCELL records different values. The button may overlay more than one cell.
6. Now add statements to the program that test to see if the button has been pressed, as follows:
IF TOUCHEDCELL IS IN 42, 43 OR 44 THEN...
Each DCX 250 Touch Cell Has a Numeric Value
www.PDF-Zoo.com
DCX Screen
15-42 Infinity Controller Programmer’s Guide
Erasing t he DCX ScreenYou erase the DCX screen with the CLEARSCREEN key-word. It erases all text and graphics currently on the screen, but leaves all screen attributes and system variables (such as BACKLIGHT and TOUCHEDCELL) set to their current values.
You can use CLEARSCREEN only in a program, not on the command line.
Suppose you want to erase the DCX screen when an alarm has been acknowledged. First you run the fallthru program that dis-plays the acknowledge button. Then you proceed as follows, this time in a looping program:
1. Test for the TOUCHEDCELL value.
2. If TOUCHEDCELL equals one of the correct values, erase the DCX screen with CLEARSCREEN.
Figure 15-27 shows the one-line looping program that tests for the touched cell. Since TOUCHEDCELL retains its value for only one scan, this program must loop to get the value in the same scan that it changes in.
Figure 15-27. TOUCHTEST Program—Looping
Enter CLEARSCREEN toErase DCX Screen
File Edit Search Check Tools
FLOOR1 DISPLAY1 AHU.DRW
IF TOUCHECELL IS IN 43, 44, 45 or 46 THEN CLEARSCREEN()
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-43
Figure 15-28 shows the alarm message program that the TOUCHTEST program works with.
Figure 15-28. ALM.MSG Progr am wi th Acknow ledge Button—FallThru
You could also set the TOUCHTEST program up as fallthru and have TOUCHEDCELL trigger it.
File Edit Search Check Tools
FLOOR1 DISPLAY1 AHU.DRW
SETDISPLAY NOFILL, WHITELOCATE 50, 100
LOCATE 100, 60PRINT "Press Here"LOCATE 100, 70DRAWRECTANGLE 90, 50, 220, 80PRINT "Temperature too high in Lobby"
CLEARSCREENTURN ON THE BACKLIGHT
PRINT "To Acknowledge"
TOUCHTEST Can Be FallThru and Triggered
www.PDF-Zoo.com
DCX Screen
15-44 Infinity Controller Programmer’s Guide
Making the DCX Beep and Stop BeepingSuppose you want DCX to beep when an alarm is active and stop when the alarm is acknowledged. You use a keyword called AUDIOBELL. From the command line or in a pro-gram, you set AUDIOBELL to the number of seconds you want the DCX controller to beep:
AUDIOBELL = 10
To stop the beeping, use TURN OFF:
TURN OFF AUDIOBELL
Figure 15-29 shows a program that beeps for 5 minutes when the alarm is active. (This version assumes the backlight is on.)
Figure 15-29. ALM.MSG Program—FallThru
Figure 15-30 shows the program that turns off the beep when you press ACKNOWLEDGE. It also clears the screen and
Make the DCX Beep withAUDIOBEL L
File Edit Search Check Tools
FLOOR1 DISPLAY1 ALM.MSG
If Lobby Temp > 76 THEN
LOCATE 50, 100
ELSE STOP ALM.MSG
PRINT "Acknowledge"LOCATE 100, 70DRAWRECTANGLE 90, 60, 220, 80PRINT "Temperature too high in Lobby"
SET AUDIOBELL = 18000
CLEARSCREEN
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-45
turns off the backlight. This program is fallthru and triggered by the TOUCHEDCELL system variable.
Figure 15-30. TOUCHTEST Program Revised to Turn off Beep—FallThru and Tr iggered by TOUCHEDCELL
Turn Off th e Beep wit h Triggered Program
File Edit Search Check Tools
FLOOR1 DISPLAY1 ALM.MSG
IF TOUCHEDCELL = 43, 44, 45, or 46 THEN CLEARSCREEN
TURN OFF AUDIOBELLCLEARSCREEN
ENDIFTURN OFF BACKLIGHT
www.PDF-Zoo.com
DCX Screen
15-46 Infinity Controller Programmer’s Guide
Making the Backgrou nd LightFlash O n and OffYou can also make the background light flash on and off by turn-ing it on for a short period of time, then turning it off:
STARTING:
IF Lobby TEMP > 76 THEN
TURN ON THE BACKLIGHT
LOCATE 60, 100
PRINT "Temperature Too High in Lobby"
IF TS > 1 THEN GOTO TIMING
ELSE STOP ALM.MSG
TIMING:
TURN OFF THE BACKLIGHT
IF TS > 1 THEN GOTO STARTING
If the temperature is greater than 76, then the backlight flashes on for 1 second and the message appears. After 20 seconds the backlight flashes off. After a total of 40 seconds, it flashes on again—and the flashing continues as long as the temperature is still greater than 76.
Once the temperature is no longer greater than 76, the pro-gram stops. When the TEMP point value changes, it triggers the program.
Make Background LightFlash
www.PDF-Zoo.com
DCX Screen
Infinity Controller Programmer’s Guide 15-47
Making Text BlinkTo make text blink when an alarm goes off, you set the color of the text to first BLUE, then WHITE, and repeat the process until an operator responds.
For instance, suppose you want the alarm message from the ALM.MSG program to blink.
You add lines to set the display to BLUE, then WHITE, switching after a time delay of 1 second. For each color, you must print the message again. The new color becomes the col-or of the next text or graphic your display.
Figure 15-31 shows how the program would look.
The IF..THEN statement under the BlinkOff line tests to see if a 1 second of time has elapsed and if the temperature is still greater than 76 degrees. If both are true, the program then goes to the BlinkOn line.
In the BlinkOn line, you use the same IF..THEN statement. As long as the temperature is greater than 76 degrees, the pro-gram goes back and forth between BlinkOn and BlinkOff—between printing the message in white, then blue.
As soon as the temperature is 76 degrees or lower, the pro-gram returns to the Checking line, where it again checks the temperature. If the temperature remains 76 or lower, the pro-gram then clears the screen and stops the program.
Blink by Toggl ingBLUE to WHITE
www.PDF-Zoo.com
DCX Screen
15-48 Infinity Controller Programmer’s Guide
Figure 15-31. ALM.MSG Program That Blin ks—Loop ing
File Edit Search Check Tools
FLOOR1 DISPLAY1 ALM.MSG
ELSE
LINE BlinkOffSETDISPLAY (BLUE)
IF Lobby TEMP > 76 THEN GOTO BlinkOff
LINE Checking
LINE BlinkOnSETDISPLAY (WHITE)LOCATE 60, 100PRINT "Temperature Too High in Lobby"IF TS > 1 and TEMP > 76 THEN
LOCATE 60, 100
GOTO BlinkOff
CLEARSCREENSTOP ALM.MSG
ENDIF
PRINT "Temperature Too High in Lobby"IF TS > 1 and TEMP > 76 THEN
GOTO BlinkOnELSE GOTO Checking
ELSE GOTO Checking
www.PDF-Zoo.com
Chapter 16
Programming Modules,ReaderDoor Outputs,
and Lighting Controllers
This chapter covers the various aspects of programming the EMX 170 module, the EMX 190 with ReaderDoor outputs, and the LCX 890 lighting controller:
NoteYou should program your ACX 700 using the access control information in Chapters 21 through 23. The method of using the EMX 190 with ReaderDoor outputs explained in this chapter is an alternative that does not give you the features of access control that doors, areas, and personnel give you.
• Understanding the EMX 170 Sensor Attributes
• Programming the EMX 170
• Using EMX 170 Buttons as Arrows
• Understanding the EMX 190 ReaderDoor Output Attributes
• Programming the EMX 190 with ReaderDoor Outputs
• Programming the Access Controller with ReaderDoor Outputs
• Programming the LCX 890 Lighting Controller
www.PDF-Zoo.com
Programming EMX Modules
16-2 Infinity Controller Programmer’s Guide
Under standing E MX 170 Sensor A ttributesThe EMX 170 has a single temperature input. Suppose you assign the input the name SPACE. The input has the attributes outlined in the table.
Table 16-1. At tr ibutes fo r EMX 170 Module Sensor
Figure 16-1 shows the locations of buttons 1 through 6.
Figure 16-1. Locat ions of Buttons on EMX 170
Attributes fo r EMX170Modu le
Attribute Name Possible Settings
DISPLAYSELECT ClearDisplay, ShowMessage,ShowSpaceTemp, ShowDisplayValue, ShowTimeValue. Displays the information on the LCD within 0.5 sec. after you set it.
DISPLAYVALUE Floating point number you set from thelanguage.
DISPLAYMSG A series of eight characters in quotation marks.
BUTTON1 throughBUTTON6
Contains the value of the correspondingbutton on the module. ON if being pressed or OFF if not. Operator must hold the button down for it to be ON.
1 2 3
4 5 6
www.PDF-Zoo.com
Programming EMX Modules
Infinity Controller Programmer’s Guide 16-3
Display ing T ext (Messages)
To display a message on the EMX 170 LCD, you set the DISPLAYMSG attribute to the message. Then you print the message by setting the DISPLAYSELECT attribute to the ShowMessage value:
SET SPACE DISPLAYMSG = "Setpoint"SET SPACE DISPLAYSELECT = ShowMessage
The LCD can display up to eight characters.
The first statement assigns DISPLAYMSG the word Setpoint and then the next line displays the message.
Once Infinity scans the DISPLAYSELECT statement, the message displays within 0.5 seconds.
The display remains on the LCD until you direct the EMX 170 to display something else or to erase the LCD.
Revers ing t he Order
You can also give the two statements in reverse order:
SET SPACE DISPLAYSELECT = ShowMessageSET SPACE DISPLAYMSG = "Setpoint"
You can set DISPLAYSELECT to ShowMessage even if you have not set DISPLAYMSG. No message prints until you assign a message to DISPLAYMSG.
Changing t he Message
Once you have set the DISPLAYSELECT to ShowMessage, you can change the DISPLAYMSG attribute as many times as you want, and each time you set DISPLAYMSG, the message displays within 0.5 seconds.
Displayin g Text onEMX 170 LCD
www.PDF-Zoo.com
Programming EMX Modules
16-4 Infinity Controller Programmer’s Guide
For instance, you can display first Setpoint , then Override , then Schedule each for approximately 10 seconds, as follows:
SETTINGSETPTSET SPACE DISPLAYSELECT = ShowMessage
SET SPACE DISPLAYMSG = "Setpoint"
IF TS > 10 THEN GOTO OVERRIDING
OVERRIDINGSET SPACE DISPLAYMSG = "Override"
IF TS > 10 GOTO SCHEDULING
SCHEDULINGSET SPACE DISPLAYMSG = "Schedule"
IF TS > 10 GOTO SETTINGSETPT
If you set DISPLAYMSG but do not set DISPLAYSELECT, the message never shows on the LCD. However, once you set DISPLAYSELECT to ShowMessage, you need not set it again as long as you are displaying messages.
Display ing a Setpo int Val ue
Displaying a setpoint value requires two statements—you set the DISPLAYVALUE attribute to the value you want to display, then set the DISPLAYSELECT attribute to ShowDisplayValue:
SET SPACE DISPLAYVALUE = 72SET SPACE DISPLAYSELECT = ShowDisplayValue
You can also reverse the order of these steps, just as you can with displaying a message.
If you have already set DISPLAYSELECT to ShowDisplayValue and have not changed it, you can simply change the
Disp laying a Setpoint
www.PDF-Zoo.com
Programming EMX Modules
Infinity Controller Programmer’s Guide 16-5
DISPLAYVALUE and it automatically displays within 0.5 seconds.
These same steps apply for displaying any related value other than the value of the input itself.
Just as with DISPLAYMSG, once you have set the DISPLAYSELECT to ShowDisplayValue, you can change the DISPLAYVALUE attribute as many times as you want, and each time you set it, the value displays within 0.5 seconds.
Display ing a Time Value
Displaying a time involves two statements—you set the DISPLAYSELECT attribute to ShowTimeValue, then set the DISPLAYVALUE attribute to the time you want to display:
SET SPACE DISPLAYSELECT = ShowTimeValueSET SPACE DISPLAYVALUE = TOD
You can, of course, reverse the order of the two statements.
To keep changing the time displayed, you need only set DISPLAYSELECT to ShowTimeValue once. Then change the DISPLAYVALUE to the various datetime variable values:
SET SPACE DISPLAYSELECT = ShowTimeValue
SET SPACE DISPLAYVALUE = FIRSTTIME
SET SPACE DISPLAYVALUE = SECTIMESET SPACE DISPLAYVALUE = THIRDTIME
Display ing I nput T emperature
You can display the input temperature in one statement—you set the DISPLAYSELECT attribute to ShowSpaceTemp, and the temperature displays within 0.5 seconds:
SET SPACE DISPLAYSELECT = ShowSpaceTemp
Display Updates wit hin 0.5 Seconds
Displayin g the Space Temperature
www.PDF-Zoo.com
Programming EMX Modules
16-6 Infinity Controller Programmer’s Guide
Erasing t he LCD Dis play
You can erase the text or value displayed on the LCD by setting the DISPLAYSELECT attribute to ClearDisplay:
SET SPACE DISPLAYSELECT = ClearDisplay
The screen clears within 0.5 seconds.
Reminde rs
Remember, you must always include the input name before the attribute or the controller does not know which input you are referring to.
For instance, SET DISPLAYSELECT = ShowSpaceTemp is not a correct statement. You must enter:
SET SPACE DISPLAYSELECT = ShowSpaceTemp
DISPLAYSELECT Is anAttribute of the Input
www.PDF-Zoo.com
Programming EMX Modules
Infinity Controller Programmer’s Guide 16-7
Determini ng B utton Has Been Pressed
If you press a button on the EMX 170, the button value is ON, which is the same as TRUE or 1. Otherwise it is OFF, which is the same as FALSE or 0.
You can structure a statement to see if the button has been pressed as follows:
if Space Button1 then space DisplaySelect=ShowSpaceTemp
OR:
If Space Button6 then Space DisplaySelect=ClearDisplay
If someone has pressed the button, the TRUE-FALSE comparison IF BUTTON1 becomes TRUE. The following three IF statements are the same:
IF SPACE BUTTON1
IF SPACE BUTTON1 IS ONIF SPACE BUTTON1 = ON
If no one has pressed the button, the button is OFF and the TRUE-FALSE comparison is FALSE.
In the next section, you write a sample program employing the EMX 170 sensor attributes.
If Button Is Pressed, It Is ON
www.PDF-Zoo.com
Programming EMX Modules
16-8 Infinity Controller Programmer’s Guide
Programmi ng t he EMX 170Suppose you wanted to use Button 1 to display the temperature, Button 2 to display the time of day, Button 3 to display the setpoint. You call the sensor SPACE and the setpoint SETPTTEMP. Your goal is to press a button and retrieve the corresponding value.
At the beginning of the program, you can have a line or lines that determine which button has been pressed.
The buttons are attributes of the SPACE point, so you can ask if a button is being pressed with the following statement:
IF SPACE BUTTON1 THEN...
If the button is being pressed, then the IF statement is TRUE; otherwise it is FALSE.
When Button 1 has been pressed, you can take the following steps to first display the message, then the temperature:
1. Set the DISPLAYMSG attribute to a string that says the following (remember, it must be eight characters or fewer):
"Temp = "
2. Then set the DISPLAYSELECT attribute to SHOWMESSAGE. The message displays within0.5 seconds.
3. After the elapsed time is 6 seconds (guaranteeing the message displays for at least 5.5 seconds), set the DISPLAYSELECT attribute to ShowSpaceTemp.
4. Display the temperature until an operator presses another button.
Figure 16-2 shows the program statements.
Programming EMX 170
www.PDF-Zoo.com
Programming EMX Modules
Infinity Controller Programmer’s Guide 16-9
Figure 16-2. TempDisplay Program—Loop ing
Infinity displays the temperature until the operator presses another button.
What happens when you press the other buttons? With a few simple modifications, you can test for any button pressed, set the mode in the first line, then go to a line that displays the appropriate information for that button. See the next sample.
Figure 16-3 expands the program to respond to each button.
File Edit Search Check Tools
BLDG1 TempDisplay
LINE ButtonTestIf SPACE Button1 Then
SET SPACE DisplayMsg = "Temp = "SET SPACE DisplaySelect = ShowMessageGOTO Waiting
Endif
LINE Waiting
IF TS > 5 THEN GOTO TempDisplay
LINE TempDisplaySET SPACE DisplaySelect = ShowSpaceTempIF SPACE Button4 THEN GOTO ButtonTest
www.PDF-Zoo.com
Programming EMX Modules
16-10 Infinity Controller Programmer’s Guide
Figure 16-3. TempTi meSetpt Pro gram—Looping
File Edit Search Check Tools
BLDG1 TempTimeSetpt
LINE ShowTempSET SPACE DisplayMsg = "Temp = "SET SPACE DisplaySelect = ShowMessageIF TS > 5 THEN GOTO TEMPDISPLAY
LINE TempDisplaySET SPACE DisplaySelect = ShowSpaceTempGOTO ButtonTest
LINE ShowTODSET SPACE DisplayMsg = "TOD = "SET SPACE DisplaySelect = ShowMessageIF TS > 5 THEN GOTO TODDisplay
LINE ButtonTest IF SPACE Button1 THEN SET Pressed = 1IF SPACE Button 2 THEN SET Pressed = 2IF SPACE Button 3 THEN SET Pressed = 3BASEDON Pressed GOTO (ShowTemp, ShowTOD, ShowSetPt)
NUMERIC Pressed
LINE TODDisplaySET SPACE DisplaySelect = ShowTimeValueGOTO ButtonTest
LINE ShowSetPtSET SPACE DisplayMsg = "Setpt = "SET SPACE DisplaySelect = ShowMessageIF TS >5 THEN GOTO SPDISPLAY
LINE SetPtDisplaySET SPACE DisplayValue = SETPTTEMPSET SPACE DisplaySelect = ShowDisplayValueGOTO ButtonTest
www.PDF-Zoo.com
Programming EMX Modules
Infinity Controller Programmer’s Guide 16-11
Note that the BASEDON..GOTO statement branches to the appropriate statement for each mode.
You could also use the EMX 170 buttons as arrows. This way, you could have an entire menu of selections and arrow your way up and down the menu. In the next section, you write a program to do just that.
BASEDON..GOTO Branches to Each Mode
www.PDF-Zoo.com
Programming EMX Modules
16-12 Infinity Controller Programmer’s Guide
Using EMX 170But tons as Arrow sYou can make Button 1 an up arrow and Button 4 a down arrow, so that you can move up and down a menu. Button 6 would be OK and you press it after you get to the choice you want. Button 5 could then be to close the menu and display START.
Figure 16-4 shows the up arrow on Button 1 and the down arrow on Button 4.
Figure 16-4. Labels for Buttons on EMX 170
Creating th e Menu
You create the menu by first outlining the choices you want. Each word in the menu can be up to eight characters. Here is a sample menu:
Weekday
OccupiedSpTemp
You want the Weekday to appear on the EMX 170 LCD screen after someone presses OK. Then, when you press the down arrow, Occupied appears, and when you press it again, Temp appears. If you are on Occupied and press the up arrow, Weekday should appear. This works like many menus you have seen, except that you see only one menu choice at a time.
Decid e How to LabelButtons on EMX 170
Done OK
www.PDF-Zoo.com
Programming EMX Modules
Infinity Controller Programmer’s Guide 16-13
To create this menu, you need to know the number of times that someone has pressed an arrow button. You create a local numeric variable to add 1 to each time someone presses the down arrow and to subtract 1 from each time someone presses the up arrow. If the choice is less than 3 you can add 1 to it, if it is greater than 1, you can subtract 1 from it.
NUMERIC CHOICE
Line ChoosingIF SPACE Button4 and Choice < 3 THEN
CHOICE = CHOICE + 1
ELSE IF SPACE Button1 and Choice > 1 THEN
CHOICE = CHOICE – 1
ENDIF
If you entered this line, it would not work. Why? When you press a button on the EMX 170, because the scan is so fast, the button remains ON for more than a single scan. So, Infinity interprets one press as two or three presses.
The result is that the first choice displays, then suddenly the third choice displays because Infinity thinks you pressed the button twice instead of once. You can never keep up with the scan, so how do you fix this?
Determini ng B utton Has Been Pressed
To display the correct choice, set a local numeric variable (such as PRESSED) to OFF until after the button has been pressed. Then only when the button is OFF can the program add 1 to the CHOICE. You include PRESSED as follows:
If Space Button4 and Choice < 3 and Pressed = Off ThenCHOICE = CHOICE + 1
PRESSED = ON
ENDIF
Create a Menu fo rEMX 170
www.PDF-Zoo.com
Programming EMX Modules
16-14 Infinity Controller Programmer’s Guide
If Space Button1 and Choice > 1 and Pressed = Off ThenCHOICE = CHOICE – 1
PRESSED = ON
ENDIF
if Space Button1 is OFF and Space Button4 is OFF thenPRESSED = OFF
ENDIF
Although Infinity must know how many times you press the arrow button to add up the correct choice, Infinity does not have to know how many times you press OK or DONE, only that the button has been pressed, period.
But, because the scan is quick, you do have to be sure the pro-gram is on the line long enough to give someone a chance to press the button.
So, when you check to see the button was pressed, you should also check to be sure time has elapsed on that line. If, for ex-ample, 3 seconds have not elapsed, you did not give the person enough time to press the button.
Once you are sure OK has been pressed, then proceed to an appropriate line based on the value of the choice:
IF Space Button6 AND TS > 3 THENBASEDON Choice GOTO DayDisp, OccDisp, TempDisp
ENDIF
Figure 16-5 shows the complete program.
Infin ity Determines YouPressed OK
www.PDF-Zoo.com
Programming EMX Modules
Infinity Controller Programmer’s Guide 16-15
Figure 16-5. EMXMenu Pro gram—Loopi ng
File Edit Search Check Tools
BLDG1 TempTimeSetpt
Choosing:If Space Button4 and Choice < 3 and Pressed = Off Then
CHOICE = CHOICE + 1PRESSED = ON
ENDIFIf Space Button1 and Choice > 1 and Pressed = Off Then
CHOICE = CHOICE – 1PRESSED = ON
ENDIF
Starting:
NUMERIC Choice, Pressed
PressingOK:IF Space Button6 AND TS > 3 THEN
BASEDON Choice GOTO DayDisp, OccDisp, TempDisp
OccDisp:Set Space DisplayMsg = "Occupied"
Set Space DisplaySelect = ShowMessageSet Space DisplayMsg = "Starting"Pressed = Off
If Space Button1 is OFF and Space Button4 is OFF ThenPRESSED = OFF
ENDIF
ENDIF
DayDisp:Set Space DisplayMsg = "Weekday"
TempDisp:Set Space DisplayMsg = "SpTemp"
PressingDONE:IF Space Button5 AND TS > 3 THEN GOTO Starting
GOTO Choosing
GOTO PressingDone
GOTO PressingDone
GOTO PressingDone
www.PDF-Zoo.com
Programming EMX Modules
16-16 Infinity Controller Programmer’s Guide
Under standing E MX 190 ReaderDoor O utput Att ribut es
NoteReaderDoor outputs exist only on EMX 190 expansion modules used with controllers other than the ACX 700. If you use an EMX 190 with a 700 controller, you should set up Doors rather than ReaderDoor outputs. For information on how to set up doors, see the Access Control chapters at the end of this volume.
The EMX 190 has a single output of a type called ReaderDoor, which is a door controlled by a card reader. You assign the output a name, such as FRONTDOOR. The output has theattributes outlined in the table. You cannot set any of these at-tributes except the VALUE of the door and the value of the READERLED.
Cards provided are in sets that have a single preassigned site code; each individual card has a unique card number, also pre-assigned.
The descriptions of each attribute of the door assume that the door circuit is normally closed. In this case, when the door is closed its value is OFF.
Of course, if the door is wired to a normally open circuit, when the door is open its value is OFF, but this may be con-fusing. Choose the kind of circuit you are comfortable with.
You can buy a door switch that is either normally open or nor-mally closed. So the switch is OFF when in a normal position, whether normal means the circuit is open or the circuit is closed. Just be sure you know which way the circuit works be-fore you program it.
Since the door switch is an attribute of a point, rather than a point, to invert ON and OFF, you have to write a function.
Attribut es for EMX 190Modu le
www.PDF-Zoo.com
Programming EMX Modules
Infinity Controller Programmer’s Guide 16-17
Table 16-2. At tr ibutes fo r EMX 190 Module Output At tributes
Attr ibu tes for CardReader Door Output
Attribute Name Possible Settings
VALUE Value of the door output, either ON for open, OFF for closed, or a number of seconds it has left to be open (positive number). You can set this value.
SITECODE Numeric site code from the last card swiped through the reader. The code remains the same for one scan after a swipe and updates every 100 ms. The code may be any number from 1 through 64,000. If the SiteCode is 0, no one has swiped a card through the reader in the last scan of the controller in the last 100 ms.Cards in one set are precoded with a single site code.
CARDNUMBER Card number from the last card swiped through the reader. The card number remains the same for one scan after a swipe and updates every 100 ms. Each card has a number built into it ranging from 1 to 600,000. Cards in a set are each pre-coded with a unique card number.
DOORSWITCH Indicates the current position of the door switch.OFF means the switch is in the normal po-sition (for example, a normally closed switch is closed). ON indicates that the switch is not in the normal position (a normally closed switch is open) or the door switch has been tampered with. Updates every 100 ms.
EXITREQUEST Indicates whether or not a person has tried to leave through the door. ON means either some-one pressed the button to leave or has been de-tected by a motion sensor. OFF means neither action has occurred. Updates every 100 ms.
OVERRIDE Indicates whether or not the door output is under manual control. ON if set to manual, OFF if con-troller controls. Updates every 100 ms.
OVERRIDEVALUE Indicates the value of the door when on manual override. ON if a normally closed door is open or a normally open door is closed. OFF if the door is in its normal position. Updates every 100 ms.
READERLED Sets the color of the light emitting diode (LED) on the card reader; red when OFF, green when ON. Updates every 100 ms. You can set this value.
www.PDF-Zoo.com
Programming EMX Modules
16-18 Infinity Controller Programmer’s Guide
To access any of these attributes, you must always use the name of the ReaderDoor output, as follows:
IF FRONTDOOR SITECODE IS 10 THEN...
IF FRONTDOOR EXITREQUEST IS ON THEN...
PR FRONTDOOR OVERRIDE
PR FRONTDOOR OVERRIDEVALUE
If you enter the attribute without the door name, Infinity does not understand it.
Acces sing the CardReader Door Attr ibut es
www.PDF-Zoo.com
Programming EMX Modules
Infinity Controller Programmer’s Guide 16-19
Programmi ng t he EMX 190 wi th ReaderDoor OutputsSuppose you want to control access through the main door of Building1. First, you set up a ReaderDoor output on an EMX 190 module. Name the output DOOR1. (You cannot name the door simply DOOR, because that is a reserved word. For more reserved words, see Appendix E of the Andover Controls Plain English Language Reference.)
Checkin g the Access Card
Once you have set up the output, you then check to see if any-one has swiped a valid card through the card reader, as follows:
IF DOOR1 SITECODE = 4 AND~DOOR1 CARDNUMBER IS BETWEEN 1 AND 50 THEN...
Remember that the SITECODE and CARDNUMBER are at-tributes of DOOR1, so you must give the DOOR1 name first.
Opening th e Door fo r 20 Second s
Once you have determined the card is a valid card, you can set the door to ON for 20 seconds. Because the door is a pulsing output, you set it to 20, as follows:
SET DOOR1 TO 20
If someone swipes a card with the wrong site code or card num-ber through the card reader, the EMX 190 keeps waiting.
Opening th e Door a s an Exit
Another circumstance that should open the door is someone at-tempting to leave through the door:
IF DOOR1 EXITREQUEST IS ON THEN GOTO OPENDOOR
Creatin g a ReaderDoorOutput
Opening the Door for20 Seconds
www.PDF-Zoo.com
Programming EMX Modules
16-20 Infinity Controller Programmer’s Guide
Checkin g for Ta mpering
You can check to see if the door is ajar when it should not be, as follows, assuming door switch that is normally closed:
IF DOOR1 DOORSWITCH IS ON AND~THE DOOR1 IS OFF THEN GOTO DOORTAMPER
Completi ng Progra m to Co ntrolBui lding A ccess
Figure 16-6 shows how you put the complete program together.
Figure 16-6. AccCont rol Progr am—Loop ing
You could also turn on the card reader LED when you open the door, as follows:
SET DOOR1 ReaderLED TO ON
This statement makes the LED flash for one scan.
Writ ing Program toCont rol Building Access
File Edit Search Check Tools
BLDG1 AccControl
WAITING:IF Door1 ExitRequest IS ON THEN goto OpenDoorIF Door1 SiteCode = 4 and Door1 CardNumber IS Between~
IF Door1 DoorSwitch IS On and Door IS Off THEN~
OPENDOOR:SET DOOR1 TO 20GOTO WAITING
1 AND 50 THEN GOTO OpenDoor
Turn ON the DoorTamperAlarm
www.PDF-Zoo.com
Programming EMX Modules
Infinity Controller Programmer’s Guide 16-21
Programmi ng t he Access Controller with ReaderDoor Outputs
NoteYou should program your ACX 700 using the access control information in Chapters 21 through 23. The following method is an alternative that does not give you the features of access control that doors, areas, and personnel give you.
You can program an ACX 700 access controller just the way you would an EMX 190 module (see the previous two sec-tions) if you choose. The same attributes can apply to the outputs on the ACX 700. Because the value of each Door-Switch, ExitRequest, and ReaderLED input is an attribute of a particular ReaderDoor output, you do not have to define these inputs as points.
You must define the first two outputs as ReaderDoor types. To ensure the outputs operate correctly with the inputs as at-tributes, wire the card reader, door switch, and exit request inputs to the correct corresponding inputs outlined in the table below.
This information applies only to ReaderDoor outputs on EMX 170 modules connected to controllers other than the ACX 700.
Table 16-3. Correspondi ng Inputs for ReaderDoor Outputs on A CX 700
ReaderDoor Output
Card Reader DoorSwitch ExitRequest
Door 1 Output Reader 1 Input
Supervisory Input 1
Supervisory Input 2
Door 2 Output Reader 2 Input
Supervisory Input 3
Supervisory Input 4
Can Program ACX 700 Contr ollers EMX 190s
www.PDF-Zoo.com
Programming EMX Modules
16-22 Infinity Controller Programmer’s Guide
Programmi ng t he LCX 890 Lighting ControllerYou program the LCX 890 to control lighting panels.
The LCX 890 has three types of entities:
• Digital inputs (such as switches or buttons) (1 through 16)
• Universal inputs (where you can connect voltage, current, temperature, or digital sensors) (17 through 24)
• Momentary Switches—Not software detectable (may be manual switches, buttons, or the like; or can be motion sensors or similar occupancy sensors) (one for each of up to 24 outputs)
• Two-Position Lighting Outputs (actual digital output relays) (1 through 24)
Controlling HI/LO Ligh tingthrough In puts
Among the various ways you can control the lighting in an area is to employ two switches—you flick the first for low lighting, flick both the first and the second for high lighting. If you try to use only the second switch, the controller does not take any action.
The first of the switches would turn on, for example, the first lighting panel to produce low lighting. The second would turn on another panel, producing high lighting.
To create a program that works with these inputs, you must remember that if the first lighting panel is OFF, the second can never be ON.
Suppose you want LIGHT1 and LIGHT2 to work together with SWITCH1 turning on the first panel (LIGHT1) and SWITCH2 turning on the second (LIGHT2). SWITCH1 is
Lighting Control throughLCX 890
www.PDF-Zoo.com
Programming EMX Modules
Infinity Controller Programmer’s Guide 16-23
ON/OFF and SWITCH2 is its adjunct, setting the lighting to either high or low.
Figure 16-7 shows a program you might produce and have triggered by SWITCH2.
Figure 16-7. Hi.LoL ight ing Program—FallThru
File Edit Search Check Tools
BLDG1 Hi.LoLighting
If Switch1 IS OFF AND Switch2 IS OFF THENSET Light1, Light2 TO OFFSTOP
Endif
If Switch1 IS ON AND Switch2 IS OFF THEN ’Set to Low LightingSET Light1 TO ONSET Light2 TO OFF
Endif
If Switch1 IS ON AND Switch2 IS ON THEN ’Set to High LightingSET Light1, Light2 TO ONRUN TestingOcc
Else
RUN TestingOcc
SET Light2 TO OFF ’Set to Low LightingRUN TestingOcc
Endif
IF Switch1 IS OFF AND Switch2 IS ON OR Switch2 is OFF THEN SET Light1, Light2 TO OFF
Endif
www.PDF-Zoo.com
Programming EMX Modules
16-24 Infinity Controller Programmer’s Guide
Controlling Lights throug h Buttonor Motio n Sensor
Although the momentary switches are not typical manual overrides, sometimes not manual at all (such as a motion sensor electronic eye), they do momentarily override the software.
So, the OVERRIDE attribute of the corresponding output is set to TRUE when the current setting of the lighting panel has been set by the momentary switch. OVERRIDEVALUE tells you the actual setting of the light at that time.
Returni ng Li ghting Controlto a Program
The VALUE and OVERRIDEVALUE attributes should always be the same or the controller cannot take over lighting.
So, you would want to check that the OVERRIDEVALUE of the relay if its OVERRIDE attribute is TRUE.
You might check these attribute values by triggering a program on the OVERRIDE attribute of one of the outputs.
Figure 16-8 shows a sample program that triggers on the OVERRIDE of the FirstLightPanel output. The program sets a timer to monitor and control how long the “momentary” setting remains in place.
Momentary Switc hes inLighting Control
www.PDF-Zoo.com
Programming EMX Modules
Infinity Controller Programmer’s Guide 16-25
Figure 16-8. TimedLi ghting Program—Loo ping
File Edit Search Check Tools
BLDG1 TimedLighting
TimingLightsOn:IF THE FirstLightPanel IS ON and FirstLightPanel OVERRIDE IS~ON THEN
SET TIMER=TIMEGOTO CalculatingTime
ELSEIF THE FirstLightPanel IS OFF and OVERIDE is~OFF and OVERRIDEVALUE IS OFF THEN
GOTO CheckingLightsOffEndif
Endif
CalculatingTime:IF TM > 60 and FLOOR1 ROOM1 IS UNOCCUPIED THEN
TURN FirstLightPanel OFF ELSE STOPENDIF
CheckingLightsOff:IF FLOOR1 ROOM1 IS OCCUPIED THEN
TURN FirstLightPanel ONELSE STOP
www.PDF-Zoo.com
Programming EMX Modules
16-26 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Chapter 17
Dialing Modems
NoteBefore you proceed with this chapter, be sure you have set up your modem as explained in Chapter 3 under Setting Up Modem Attached Directly to the Controller or Setting Up Modem or Setting Up Modem Attached to a Terminal.
This chapter covers how to dial a modem and how to send data through the comm port on the Infinity CX 9000. It also covers how to use the modem on an Infinity CMX controller. If you have not already read Chapter 12, you should read it before you proceed with this chapter.
The information is in the following sections:
• Forming a Modem Dial Function
• Using the Modem Dial Function on the Infinity CX 9000 Controller
• Calling Out on Infinity CMX 220 Built-in Modem
For information about how to call an SX 8000 workstation, refer to the SX 8000 Programmer’s Guide or the Release Notes—Andover Controls Infinity SX Workstations.
www.PDF-Zoo.com
Comm Port and Modem Functions
17-2 Infinity Controller Programmer’s Guide
Formi ng a Modem Dial FunctionGOAL: To set up a function that dials to connect a modem from one building to a modem in another building and then send a message to the printer.
Suppose the distance from building 1 to building 2 is 10 miles. Instead of cabling between them, you use modems to connect them.
Once the modems are in place on the Infinity CX 9000 of each building, the controller in building 1 can call to send data, messages, reports, or alarms to the printer in building 2.
Steps to Carry Out
The steps you carry out are as follows:
1. Identify the modem by its comm port (in this case, COMM3).
2. Send the phone number to the comm port.
3. Return to the calling program.
Dialing the Number
Now, you dial the phone number by using PRINT to send the number to the comm port (for pulse dialing):
PRINT "ATD5551212" TO COMM3
Or, for touchtone dialing, add a T after ATD, as follows:
PRINT "ATDT5551212" TO COMM3
ATDT is required; then you can use the phone number required from your location. (Only include the area code if it’s usually required to dial the call.) PRINT can send the
One Funct ion DialsModems
Use PRINT to Dial PhoneNumber
www.PDF-Zoo.com
Comm Port and Modem Functions
Infinity Controller Programmer’s Guide 17-3
information in any string down any path you request, even where there is no printer.
Forming the Com plete Function
A function named CALL that calls any phone number needs the following arguments:
ARG 1 PHONE.PORT
ARG 2 PHONE.NUMBER
You then form the body of the function using the PRINT statement presented earlier, but using the argument names instead of particular names.
Figure 17-1 shows the entire function file. (Remember to remove the T after ATD if you do not have touchtone dialing.)
Figure 17-1. CALL Function
Phone Number and Port as Funct ion Arguments
File Edit Search Check Tools
BLDG1 CALL
PRINT "ATDT";PHONE.NUMBER TO PHONE.PORT
ARG 1 PHONE.PORT
ARG 2 PHONE.NUMBER
RETURN
www.PDF-Zoo.com
Comm Port and Modem Functions
17-4 Infinity Controller Programmer’s Guide
Using th e Modem Dial Function o n Inf inity CX ControllerFor purposes of the example illustrated in this section, you should have a string point called ErrorText. In the program, you set this point to a message about the dialing action.
Opening th e Comm Port
The program that calls the function should first open the communications port to the modem. You open the port with the OPEN function. The OPEN function must always be either on a line by itself or the last statement in a line:
Line OpeningPort
Opening = Open (Comm3)
You do not have to include a GOTO statement in the line, because OPEN automatically goes to the next line. The next line, however, must test to see if the OPEN was successful. OPEN returns either SUCCESS or FAILURE and places it in the local variable OPENING. You check OPENING in the next line:
Calling:
If Opening = Success Then...
Opening fails if the port is busy doing another task.
Open the Comm Port
www.PDF-Zoo.com
Comm Port and Modem Functions
Infinity Controller Programmer’s Guide 17-5
Act ing on Alread y Open Port
Because when the port is open, its mode is Raw, you can see if the port is already open before opening it as follows:
If Comm3 Mode = Raw Then...
When you check the port, you have two possible options:
• If it is open, use the port immediately (since it is already open)
• Try to open the port with the OPEN comm port function
In the sample program later in this section, if the port is open, the program uses the port. The line that takes this action is called OpeningPort and appears as follows:
OpeningPort
ErrorText = ""
If Comm3 Mode = Raw ThenSet Opening to Successgoto Calling
ElseOpening = Open (Comm3)
Endif
Remember that OPEN automatically goes to the next line, so no GOTO is required after opening the comm port. The program proceeds to the Calling line.
Notice also that this line sets the ErrorText point, the string point mentioned earlier, to an empty string.
Acc essing M odem
After it determines the port is open or opens the port, the program must turn on the DTR (Data Terminal Ready) attribute of the port to indicate it wants to access the modem.
Test Comm Port Status before Opening
www.PDF-Zoo.com
Comm Port and Modem Functions
17-6 Infinity Controller Programmer’s Guide
The cable that connects your modem to your controller has a series of pins in it; one of those pins is the DTR pin. Turning ON the DTR attribute turns on the DTR pin, indicating the terminal is read to communicate through the modem.
You turn on DTR in either of the following ways:
Set Comm3 DTR = ON
or
Turn On Comm3 DTR
You use this statement in the Calling line of the program.
Forming Statem ents to Cal l the Func tion
After it turns on the DTR attribute, the program calls the CALL function you created in the previous section with any of these statements:
Call(Comm3, "5551212")
Call(Comm2, PhNumb)
Call(Comm1, "6035551212")
Notice that the phone number is a string. Later you join the ATDT prefix to the string with the joining operator, the semicolon (;).
“Calling” through the modem this way “rings the phone” of another modem at the other site.
Connecting
To see if the modem connects (“answers the phone”) the program checks the CXD (carrier detect) attribute of COMM3:
If Comm3 CXD = On Then Print Alarmsg To Comm3
Program StatementsCallin g Functio n
www.PDF-Zoo.com
Comm Port and Modem Functions
Infinity Controller Programmer’s Guide 17-7
Among the pins on the cable that connects your modem to your controller is the CXD pin.
CXD attribute indicates that the CXD pin is ON. This means a signal (carrier) has been detected, and the modems are ready to communicate. If the controller determines that the modem’s CXD pin is ON, the statement above sends the message. If the controller determines that the CXD pin is not ON, the program statement does not try to send the message.
Since the CXD pin may take a few seconds to turn on, the calling program might have a statement that keeps trying to get through for a certain number of seconds.
For instance, the program must call the function, then check to see if the connection occurs within, for example, 40 seconds.
If TS > 40 Then Goto ClosingPort
The above statement closes the port if the call does not go through. An alternative would be to set an error message, then close the port, as the following statement does:
If TS > 40 ThenErrorText = "Could not connect to 508/555-1212"Goto ClosingPort
Endif
Later, you can print the error message.
The ringing line of the sample program puts together all of these actions, as follows:
Ringing
If Comm3 CXD Is On Then Goto SendMsg
If TS is greater than 40 ThenErrorText = "Could not connect to 508/555-1212"Goto ClosingPort
Endif
CXD Pin Indicates Signal Has Been Detected
www.PDF-Zoo.com
Comm Port and Modem Functions
17-8 Infinity Controller Programmer’s Guide
Transmitting
If the CXD is on, and the controller prints the message to the comm port, how does it know when the complete message has been sent?
You can check in the program to be sure the message has been completely sent, using the PRINTDONE attribute of the comm port. PRINTDONE becomes true when all the characters in the message have been sent out to the comm port:
If Comm3 PrintDone = True Then...
NoteSome modems require a delay after CXD turns on before you can send data to them. If you find that the receiving controller never receives the first part of your message, try adding a5 second delay before sending the message. Refer to the example in the next section (for CMX controllers) for how to program the delay.
Handling Errors
What if an error occurs and the port is open? If an error occurred, any message in response to the error would go to the comm port—to the modem if the port is open. A way to save the message so that you can later print it at the terminal is to put it in the string point you created, ErrorText. ErrorText holds any error message. At first, remember, you set it to an empty string:
Set ErrorText = ""
Now, if you suspect an error has occurred, you can print the ErrorText value at the terminal and see any message the program may have sent to it.
Check th e PrintDoneAttribute
Send Error Messag es toa String Point fo r Later
www.PDF-Zoo.com
Comm Port and Modem Functions
Infinity Controller Programmer’s Guide 17-9
Figure 17-2. CallOut9000 Program—Looping1
1. This program assumes an Andover Controls UDS modem. Any othermodem may require a delay after CXD occurs.
File Edit Search Check Tools
BLDG1 Callout9000
Numeric Opening, Closing
OpeningPort:ErrorText = ""If Comm3 mode = RAW then
set Opening to success goto calling
else Opening = Open(Comm3)
endif
Calling:If Opening = Success then
Turn Comm3 DTR ONCall (Comm3,"15085551212")goto Ringing
Elseprint "Could not open port." to ErrorTextstop Connecting
Endif
Ringing:
If Comm3 CXD is on then goto SendMsgif TS is greater than 40 then
ErrorText = "Could not connect to 508/555-1212."goto ClosingPort
Endif
SendMsg:Print AlarmMessage to Comm3Goto WaitForPrintDone
WaitForPrintDone:if Comm3 PrintDone = True then goto ClosingPort
’This program is designed to run on the 9000 controller only.
www.PDF-Zoo.com
Comm Port and Modem Functions
17-10 Infinity Controller Programmer’s Guide
Hanging Up an d Closing the Comm Port
Once you have complete the communication, you then hang up the modem (as you would hang up a phone), by turning off the DTR attribute of the port:
Turn Off Comm3 DTR
NoteRefer to your modem manual for how to configure your modem to hang up the phone.
You then close the comm port. You close it with the CLOSE function:
Closing = Close (Comm3)
ClosingPort:
Turn off Comm3 DTR
Closing = Close (Comm3)
CLOSE, like OPEN, must be either the last statement on a line or on a line by itself. CLOSE automatically goes to the next line. The CLOSE statement, like OPEN, returns either SUCCESS or FAILURE. The next line must always include a test for the success of the closing.
Figure 17-2 shows the entire program, including lines to test for SUCCESS or FAILURE of OPEN and CLOSE. The program is looping.
A more typical program would use a string point for the phone number, so that all you have to do is change the point value to change the phone number.
The CLOSE FunctionCloses t he Comm Port
www.PDF-Zoo.com
Comm Port and Modem Functions
Infinity Controller Programmer’s Guide 17-11
Figure 17-2. CallOut9000 Program—Looping (cont)
Changing the Baud Rat e, Parit y, or Number of Stop Bits
When you first define the comm port, you assign it a baud rate.
Suppose you want to send a message through a modem that has a baud rate different from the original baud rate of the comm port. Before you send the message to that modem, you must change the BAUD attribute setting.
The following example shows how you first store the original baud in a numeric local variable called MODEMBAUD:
Numeric ModemBaud
ModemBaud = Modem1 Baud
Set Modem1 Baud = Baud300
Then, after opening the comm port, and completing the tasks on the modem, you must set the BAUD attribute back to its original value:
Set Modem1 Baud = ModemBaud
File Edit Search Check Tools
BLDG1 CallOut9000
ClosingPort:Turn Comm3 DTR OffClosing = Close(Comm3)
EndingProgram:If Closing = Success then
stop CallOut9000Else
Print "Could not close port." to ErrorTextstop CallOut9000
Endif
Changin g the Baud Rate, Parity, Stop Bits
www.PDF-Zoo.com
Comm Port and Modem Functions
17-12 Infinity Controller Programmer’s Guide
The same applies to both the PARITY and STOPBITS if you must them for a particular modem. For more on those attributes, see Appendix B of the Andover Controls Plain English Language Reference.
Revisin g the Program for CM X 240
You can revise the CONNECTMOD program to run on a CMX 240 by changing the comm port from COMM3 to the comm port that connects to the modem, either COMM1 or COMM2. Otherwise, the program is the same for both controllers.
Do Not Turn Off RTS Attrib uteof LBus o r Infine t
Do not turn off the RTS (“Ready To Send”) attribute for the comm port of LBus or Infinet. If you do, it shuts the port down and you cannot access the LBus or Infinet.
RTS Attr ibu te Must BeON
www.PDF-Zoo.com
Comm Port and Modem Functions
Infinity Controller Programmer’s Guide 17-13
Summary
• You can write a function that carries out the same action on different pieces of equipment.
• A function can call another function.
• Before you dial a modem, you must turn on the comm port’s DTR (data terminal ready) attribute to indicate you want to use the modem.
• To dial a modem, you print the phone number to the comm port of the modem one of two ways:
PRINT "ATD";PHONE.NUMBER (for pulse dial)
PRINT "ATDT";PHONE.NUMBER (for touchtone dial)
• To avoid printing an error to the open comm port, you may choose to store the error in a string point.
• The CXD (carrier detect) attribute of a comm port is ON when the controller detects the CXD pin of the port is ON, meaning the modems are ready to communicate.
• Before calling the function to dial the modem, you must have a line that determine the port is already open or opens the comm port with OPEN.
• After you connect and send the message to the comm port with PRINT, you check to see the entire message was sent with PRINTDONE.
• After the message has been sent, you hang up on the comm port by turning off the comm port’s DTR attribute.
• After you use the modem, you must have a line that closes the comm port with CLOSE.
• OPEN and CLOSE each require a line that tests to see if the opening or closing process is successful.
PRINT Sends Phone Number to Comm Port
www.PDF-Zoo.com
Comm Port and Modem Functions
17-14 Infinity Controller Programmer’s Guide
Calling Out on I nfinity CMX Built-in ModemTo call in on the Infinity CMX built-in modem from another building, you do not need a special program. Since the CMX controller’s built-in modem is automatically set up to receive incoming calls, when you call in, Infinity automatically sets the modem baud to 2400 and returns it to the original baud setting on hangup. And the CMX automatically logs off any operator who is logged on when the incoming call occurs.
To call out on a CMX, however, requires a special program.
GOAL: To call out from the built-in modem on an Infinity CMX using the CALL function created earlier in this chapter.
Diffe rence s between Callingfrom CMX and Infinity CX Controlle rs
What is different about calling from an CMX rather than an Infinity CX? Here are some of the differences:
• Infinity sees the built-in modem on a CMX as the UserPort rather than as COMM3.
• To indicate you want to access the modem, you set the UserPort DTR attribute to ON and set the baud to 2400.
• Once you access the modem, you can send it AT dial and hangup modem commands only, shown in the modem man-ual. Other modem commands may create issues on the CMX.
• Once you determine the call has connected (CXD attribute is TRUE), you must wait for a minimum of 6 seconds(TS > 5) before actually sending a message to the port.
• To disconnect from the modem, you turn UserPort DTR off.
Call ing In Versus Callin gOut on CMX
www.PDF-Zoo.com
Comm Port and Modem Functions
Infinity Controller Programmer’s Guide 17-15
Creating Strin g to Hol d Error
Since you cannot print to the terminal if the port is open, you store the error in a string. So, begin by creating a string point called ERRORTEXT and setting it to an empty string:
SET ErrorText = ""
Before Opening CMX 220 User Port
To call out on the built-in modem, you must open the port. Before you can open the port, you must store the current baud in a local variable called MODEMBAUD, as follows:
SET ModemBaud to UserPort Baud
Because when the port is open, its mode is Raw, you can see if the port is already open before opening it as follows:
If UserPort Mode = Raw Then...
If the port is already open, you have two possible options:
• Use the port immediately (since it is already open)
• Consider the port unavailable and stop the program
Opening CM X 220 User Port
The first line tests to see if the UserPort is already open. If the port is not open, the program opens it; if it is open, the program proceeds to make the call (on the CALLING line):
IF UserPort Mode = Raw Then
Set Opening to Success
Goto Calling
Else
Opening = Open (UserPort)
Endif
Storin g the DefaultMode Baud
www.PDF-Zoo.com
Comm Port and Modem Functions
17-16 Infinity Controller Programmer’s Guide
Once OPEN opens the port, the line does not need a GOTO statement, because OPEN automatically goes to the next line. The next line always tests to see if OPEN was successful.
Preparing to Call Out
The OPEN function returns either SUCCESS or FAILURE and places it in the local variable OPENING. You check OPENING in the next line:
Calling:
If Opening = SUCCESS Then...
Once you have opened the port successfully, to access the built-in modem, you must set the UserPort DTR attribute (for “Data Terminal Ready”) to ON and set the baud to 2400 for the built-in modem on the CMX 220:
TURN UserPort DTR ON
SET UserPort Baud = Baud2400
Forming Statem ent to Call Out
After it opens the port, the program runs the function you created earlier in this chapter:
CALL(UserPort, "5551212")
Figure 17-3 shows the program (the figure continues on subsequent pages). Notice that the complete CALLING line combines statements formed in the this subsection and the last.
Connecting
To see if the modem connects, you set up a line called RINGING that checks the CXD (carrier detect) attribute of the UserPort:
If UserPort CXD = ON Then GoTo DelayAfterCXD
If the controller detects communication signals, CXD is ON.
Setti ng DTR and Baudbefore Callin g Out
Statement to Call Out
www.PDF-Zoo.com
Comm Port and Modem Functions
Infinity Controller Programmer’s Guide 17-17
Figure 17-3. CMXDialOut Program—Looping
File Edit Search Check Tools
BLDG1 CMXDialOut
Numeric Opening, Closing, ModemBaud
OpeningPort:Set ModemBaud to UserPort BaudErrorText = ""If userport mode = RAW then
set opening to success goto calling
else Opening = Open(UserPort)
endif
Calling:If Opening = Success then
Turn UserPort DTR OnSet UserPort Baud to Baud2400Call (UserPort,"15085551212")goto Ringing
Elseprint "Could not open port." to ErrorTextstop CMXDialOut
Endif
Ringing:If UserPort CXD is on then goto DelayAfterCxdif TS is greater than 40 then
ErrorText = "Could not connect to 508/555-1212."goto ClosingPort
Endif
DelayAfterCxd:if ts is greater than 5 then goto SendMsg
SendMsg:Print AlarmMessage to UserPortGoto WaitForPrintDone
’This program is designed to run on the 220 controller only.
www.PDF-Zoo.com
Comm Port and Modem Functions
17-18 Infinity Controller Programmer’s Guide
If CXD is not ON, you can have a statement that keeps trying to get through for a certain number of seconds. The one shown below calls the CALL function, then checks to see if the connection occurs within, for example, 40 seconds:
IF TS > 40 THEN
Set ErrorText = "Could not connect to 508/555-1212"
Goto ClosingPort
ENDIF
If 40 seconds elapse and the program does not connect, you then set the ERRORTEXT variable to an error message. You do this because while the port is open, you cannot print to the Messages window. Later, after you close the port, you can send the message to the Messages window.
Transmitting
Once CXD is ON, you must wait at least 6 seconds before you can send text through the port. If you do not wait the 6 seconds, you lose some characters at the beginning of the message. To wait those 6 seconds, you can set up a DELAYAFTERCXD line to measure elapsed time:
If TS is greater than 5 then goto SendMsg
The SENDMSG line then sends the string variable to the UserPort with a PRINT statement:
Print AlarmMessage to UserPort
The PRINTDONE attribute of the UserPort becomes TRUE when all characters in the message have been sent:
If UserPort printdone = TRUE Then goto WaitForModem
CXD At tribute Indicates aSignal Is Det ected
www.PDF-Zoo.com
Comm Port and Modem Functions
Infinity Controller Programmer’s Guide 17-19
Hanging U p the Mod em
Once the PRINTDONE attribute is TRUE, you must begin the process of hanging up the modem. You hang up the modem by doing each of the following:
1. Wait 1 second
2. Send the characters “+++” to the modem
3. Be sure the modem has received the “+++”
4. Wait 1 second
5. Send the hangup command to the modem (see the AT commands)
To carry out the process, you form several separate lines. Each line that measures elapsed time must be a separate line:
WaitForModem:
If TS > 1 then goto PrepModem
After you wait 1 second, you can then send three plus signs to the modem to indicate you want to send a command. be sure the three plus signs are in a string (in quotation marks) and followed by a semicolon:
PrepModem:
Print "+++"; to UserPort
Goto WaitToFinishPrep
Now be sure you have sent the string:
WaitToFinishPrep:
If UserPort PRINTDONE = True then WaitToHangup
Carry Out Specif ic Steps to Hang Up
www.PDF-Zoo.com
Comm Port and Modem Functions
17-20 Infinity Controller Programmer’s Guide
Finally, you are ready to hang up. You must first wait 1 second, or the modem could falter and force you to start the process over:
WaitToHangup:
If TS > 1 then goto HangupModem
Once you have waited the 1 second, you can then send the AT command H. The AT gets the modem’s attention and the H hangs up:
HangupModem:
Print "ATH" to UserPort
Goto PrepToClose
Closing the Port
Be sure the modem has received the hangup command before you close the comm port by testing to be sure the PRINTDONE attribute of the port is TRUE:
PrepToClose:
If UserPort printdone = True then goto ClosingPort
Then be sure to restore the port by setting the DTR attribute to OFF and the BAUD to its original setting with MODEMBAUD. Then use the CLOSE comm port function:
ClosingPort:
Turn UserPort DTR Off
Set UserPort Baud to ModemBaud
Closing = Close (UserPort)
Ending th e Progra m
The last line of the program must test to be sure CLOSE is successful and take action if it is not.
ATH Command TellsModem to Hang Up
www.PDF-Zoo.com
Comm Port and Modem Functions
Infinity Controller Programmer’s Guide 17-21
Figure 17-3. CMXDialOut Program—Looping (cont)
If the CLOSE function is successful, the program stops.
File Edit Search Check Tools
BLDG1 CMXDialOut
ClosingPort:Turn UserPort DTR OffSet UserPort Baud to ModemBaudClosing = Close(UserPort)
EndingProgram:If Closing = Success then
stop CMXDialOutElse
Print "Could not close port." to ErrorTextstop CMXDialOut
Endif
WaitForPrintDone:if UserPort PrintDone = True then goto WaitForModem
WaitToFinishPrep:if UserPort PrintDone = True then goto WaitToHangup
WaitToHangup:if ts is greater than 1 then goto HangupModem
HangupModem:print "ATH" to UserPortgoto PrepToClose
PrepToClose:if UserPort PrintDone = True then goto ClosingPort
PrepModem:print "+++"; to UserPortgoto WaitToFinishPrep
WaitForModem:if ts is greater than 1 then goto PrepModem
www.PDF-Zoo.com
Comm Port and Modem Functions
17-22 Infinity Controller Programmer’s Guide
If the CLOSE function fails, the message that you could not close the port prints to the ERRORTEXT string point.
Whether CLOSE succeeds or fails, you stop the program so that it does not continue to loop.
To see if anything has gone wrong, print ERRORTEXTat a terminal. If the program has stored a message in ERRORTEXT, you can take action in response to the message.
Now, try calling out on your CMX controller.
WarningUse Extra Terminal to Debug OPEN and CLOSE Comm Port Functions
Remember that OPEN comm port and CLOSE comm port are advanced functions and only experienced programmers should use them.
If you plan to run programs that contain the OPEN and CLOSE comm port functions, you should have two terminals attached to the same controller while debugging. This way if you open the comm port and do not close it (locking out the terminal), you can access the controller from the other terminal. Otherwise, you must reset the controller.
If the program that should close the port has an error, it becomes disabled. The port does not close and is then locked open. Once it is locked open, you cannot access the controller through that terminal. So be careful to thoroughly debug any programs that use OPEN and CLOSE comm port functions.
ERRORTEXT ContainsAny Error
You Must Be Sure toClose Comm Ports
www.PDF-Zoo.com
Chapter 18
Advanced Functionsfor Experts
This chapter lists some advanced functions and operators:
• Advanced Math Functions
• Advanced Math Operators
• Advanced String Functions
www.PDF-Zoo.com
Advanced Functions
18-2 Infinity Controller Programmer’s Guide
Advanced Math FunctionsThe following math functions are available for advancedusers:
ABS LN
ACOS LOG
ASIN MOD
ATAN RANDOM
ATAN2 ROUND
CEILING SIN
COS SQRT
EXPONENTIAL STANDARDDEVIATION
FACTORIAL TAN
FLOOR TRUNCATE
Details on these functions are provided in the Andover Controls Plain English Language Reference.
Advanced MathFunction Keywords
www.PDF-Zoo.com
Advanced Functions
Infinity Controller Programmer’s Guide 18-3
Advanced Math OperatorsThe following math operators are available for advancedusers:
BITAND BITOR
BITNOT BITXOR
Details on these operators are provided in the Andover Controls Plain English Language Reference.
Advanced Math Operator Keywords
www.PDF-Zoo.com
Advanced Functions
18-4 Infinity Controller Programmer’s Guide
Advanced String Funct ionsThe following string functions are available for advancedusers:
ASC RIGHT
CHR SEARCH
LEFT STRINGFILL
LENGTH STRTODATE
MID STRTONUM
NUMTOSTR TAB
Details on these functions are provided in the Andover Controls Plain English Language Reference.
Advanced StringFunction Keywords
www.PDF-Zoo.com
Chapter 19
Loading and SavingPoints and Programs
This chapter covers the following topics:
• Saving Points and Programs to Magnetic Media
• Loading Points and Programs from Magnetic Media
• Using LOAD Command to Correct Memory Fragmentation
www.PDF-Zoo.com
Loading and Saving
19-2 Infinity Controller Programmer’s Guide
Saving Points and Programs to Magnet ic MediaAfter you have written your programs, it is good to have a backup copy of them.
Should the power go down, the battery backup on the control-ler has enough power to maintain memory for 48 hours. Your programs are safe until then. What you need to do is plan ahead:
• Keep printed copies of your programs in your filing cabinet.
• Have a list of emergency procedures (to turn on or off equipment, turn on a generator) for handling power loss.
• Save your programs on a disk so that you can reload them in the event that a power outage destroys them.
The first two bullets are self-explanatory. But how do you send information to a disk? You use a keyword called SAVE or DUMP.
Before You Can Save
Before you can use SAVE or DUMP, you must have a com-puter on your network with a disk. The computer should be running a communications package, such as CROSSTALK.
(You may also want to consider the helpful hints regarding the firing order list, given in Chapter 9.)
Backup Copies of Files
Preparing to Save
www.PDF-Zoo.com
Loading and Saving
Infinity Controller Programmer’s Guide 19-3
Proc edure to Sav e
You prepare the computer to receive a file from the controller using the communications package commands. (The follow-ing example uses CROSSTALK in step 2. To use another package, refer to that package’s documentation):
1. Go to the host (active) computer on your network and enter the communications package.
2. Type capture C: allinfo and press the EXECUTE key to prepare the computer to receive a file on disk C and save it under the name “allinfo.”
3. Go to the controller and type SAVE ALL and press the EXECUTE key.
This procedure saves all information about your controller (except alarms information), including all points and pro-grams, onto disk C. The programs save in the order on the firing order list, starting with the last one and proceeding back to the first.
You can type SAVE ALL on the controller before you type the communications command on the computer, but if you do, you have only 60 seconds to type the communications com-mand before the save fails.
Other Savin g Rules
You can also save a particular point or file by including its name:
SAVE HEAT.PROG
DUMP SupplyAirT
Or you could save a list of points or programs:
SAVE SupplyAir1, SupplyAir2, SupplyAir3
Save Files on Host Computer
Using SAVE ALL
www.PDF-Zoo.com
Loading and Saving
19-4 Infinity Controller Programmer’s Guide
DUMP HEAT.NOHEAT, MORN.WARMUP, AIRPROG
You can save all input points this way:
SAVE INPUT
You can save any type that is defined in the controller, including:
INPUT OUTPUT NUMERICSTRING DATETIME PROGRAMFUNCTION DATA
Saving O nly Definition s
To save only the dictionary of all items on the Infinet control-ler, include the -d option in the command line:
SAVE ALL -d
DUMP ALL -d
Saving Item s on EnergyNe t
To save all items on the entire EnergyNet network with a def-inition of each item, include ENERGYNET in the command line:
SAVE ENERGYNET
DUMP ENERGYNET
Saving Item s on Infine t
To save all items on the Infinity CX 9000 and all Infinet con-trollers on the Infinet or Infinets connected to it with a definition of each item, include INFINET in the command line:
SAVE INFINET
Save with ItemDefin itio ns
Save All o f Infin et
www.PDF-Zoo.com
Loading and Saving
Infinity Controller Programmer’s Guide 19-5
DUMP INFINET
Saving Item s on B oth EnergyNetand In finet
To save all items on all Infinity CX 9000s and all Infinet con-trollers on all Infinets with a definition of each item, include SITE in the command line:
SAVE SITE
DUMP SITE
Summary
• Before you can save, you must have a computer running an ANSI terminal emulator program and a file storage device (tape or disk).
• To save all items on the controller and all its Infinets, add INFINET to the SAVE command line.
• To save all items on the entire EnergyNet, add ENERGYNET to the SAVE command line.
• To save all items on the entire EnergyNet and all the Infinets attached to every controller, add SITE to the SAVE command line.
• To save only the dictionary of items, add the -d option to the SAVE command line.
Computer Must Run ANSI Terminal Emulator
www.PDF-Zoo.com
Loading and Saving
19-6 Infinity Controller Programmer’s Guide
Load ing Points and Programs from Magn etic MediaTo load points and programs you have saved on tape back into the controller after power comes back on, you use the LOAD or RELOAD keyword.
Before You Can Lo ad
Before you can use LOAD or RELOAD, you must have a computer on your network with a disk. The computer should be running a communications package, such as CROSSTALK.
You must also have a file that has been saved (called a “dump file”) or an ASCII file typed in dump file format. For more on dump file format, see the Andover Controls Plain English Language Reference.
Proc edure to Loa d
You prepare the computer to send a file to the controller using the communications package commands. (The following example uses CROSSTALK in step 2. To use another pack-age, refer to that package’s documentation):
To reload all points and programs at once:
1. Go to the host (active) computer on your network and enter the communications package.
2. Type upload C: allinfo and press the EXECUTE key to prepare the computer to send a file named “allinfo” from disk C.
3. Go to the controller and type LOAD and press the EXECUTE key.
LOAD or RELOAD Po intsand Pr ograms
www.PDF-Zoo.com
Loading and Saving
Infinity Controller Programmer’s Guide 19-7
This procedure loads the file onto your controller, adding the information to the already-present database.
To reload all information onto the controller and replace the information already on the controller, you use the -o option with LOAD, like this:
LOAD -o
The “o” stands for “overwrite.” The computer “writes” to the RAM, so to overwrite is to replace information.
To see messages concerning the loading process in theMessages window while loading, add the -m option:
LOAD -m
Programs always load in the order on the firing order list, starting with the first one listed.
Summary
• To load or save programs, points, or other controller information, you must have a computer on the network.
• The computer must have a disk and be running a communications program, such as CROSSTALK.
• You use SAVE or DUMP to save information onto disk.
• You use LOAD or RELOAD to load information from disk.
• You use the -o (overwrite) option with LOAD or RELOAD to replace all information in the controller with the information you are loading.
• You use the -m (messages) option with LOAD or RELOAD to see messages in the Messages window during loading.
Adding to Present Database
www.PDF-Zoo.com
Loading and Saving
19-8 Infinity Controller Programmer’s Guide
Using LOAD Command to Corre ct Memory FragmentingIf you have trouble saving a file you have made changes to on an Infinet controller when adequate free memory exists, the problem may be caused by memory fragmentation. Although this situation is rare, it could occur. If this occurs, proceed as follows:
1. SAVE the files on the controller with the SAVE or DUMP command.
2. RESET the controller by either pressing the RESET button in the Infinet Controller window, or disconnecting the battery and then powering down the controller.
3. Reload the programs with the LOAD or RELOAD command.
The reload stores the files more compactly in the controller memory and corrects the fragmentation problem.
LOAD Stores Files MoreCompactly
www.PDF-Zoo.com
Chapter 20
Operating on Bat tery BackupThis chapter covers the following topics:
• Reacting When AC Power Goes Down
• Writing a Simple Power Down Program
• Writing Another Power Down Program
• Calling for Intervention on Power Loss
www.PDF-Zoo.com
Operating on Battery Backup
20-2 Infinity Controller Programmer’s Guide
React ing W hen AC Power Goes DownOnce the battery is connected, RAM and the real-time clock are always operating. When the AC power is down (the controller is off), you are then operating on only RAM with the real-time clock.
Under battery power, you can choose to have full controller operation for 2 hours. For short power losses, you may never even see a lapse in controller activity. (If you have a backup generator for major equipment, reasonably normal building control could continue without alarms.)
But if you expect the power to remain down, you may want to extend the length of time you can operate on battery backup. Shutting down parts of the controller extends that length of time beyond 2 hours and to potentially as long as 48 hours (although that length of time varies depending on the controller model and the battery power consumed before you turn off the various parts of the controller).
You can shut down the various parts connected to the controller and keep only the CPU running:
• Modem
• DCX 250attached directly to the Infinity CX 9000
WarningIf you take down the CPU power, you cannot turn on the controller until AC power returns.
You can also turn off the CPU and run the equipment manually.
RAM and Real-TimeClock A lways Op erate
www.PDF-Zoo.com
Operating on Battery Backup
Infinity Controller Programmer’s Guide 20-3
Shutting Do wn the Parts
You shut down the parts by setting a programmable system variable to control each part.
The programmable system variables to control the power are as follows:
• MODEMPOWER
• DCXPOWER
• CPUPOWER
These system variables correspond to particular lights on the Power Supply Voltage Status Display inside the Infinity CX 9000 cabinet.
Figure 20-1 shows the lights. The ones with the asterisks to the right correspond to the programmable system variables.
Figure 20-1. Power Supply Voltage Status Disp lay
From either a program or the Command window, you can set each one to OFF as follows:
SET DCXPOWER = OFF
Programmable Syst em Variables
–5+15–15+24
MainIOU
ModemDCX 250
AC PowerEnergyLink 2000
*
**
www.PDF-Zoo.com
Operating on Battery Backup
20-4 Infinity Controller Programmer’s Guide
SET MODEMPOWER = OFF
or you can turn one off as follows:
TURN OFF DCXPOWER
TURN OFF CPUPOWER
You later turn them on the same way.
But which is appropriate when? How do you use them? You use them in conjunction with the POWERFAIL system variable.
Using the POWERFAILSystem Variable
Each time you lose AC power to a particular controller, its POWERFAIL system variable is automatically set to ON. It remains ON until one scan after AC power returns.
You can use the POWERFAIL system variable as a trigger to tell the controller when to shut down system parts.
In the next section, you write some programs that take various actions when AC power fails.
POWERFAIL IndicatesPower Has Been Lost
www.PDF-Zoo.com
Operating on Battery Backup
Infinity Controller Programmer’s Guide 20-5
Writing a S imple Power Down ProgramFigure 20-2 shows a sample POWERLOSS program that is looping and triggered by the POWERFAIL system variable.
Figure 20-2. Sample PowerLoss Program—Looping
This POWERLOSS program turns off parts of the controller system after AC power has been down for 10 minutes.
Notice that the program turns off power to the DCX 250 immediately, but waits before turning off power to the modem and CPU. The DCX 250 draws more power than any other part on the controller and turning it off immediately saves the battery.
If POWERFAIL is on when it triggers the program, the program turns on power to the CPU, DCX 250, and modem.
File Edit Search Compile Tools
BLDG1 FLOOR1 PowerLoss
NUMERIC STOPTIME
IF POWERFAIL IS ON THEN
IF TM > 10 and POWERFAIL IS ON THENTURN OFF MODEMPOWER, CPUPOWER
ENDIF
LINE TestPower
LINE TimePowerOff
TURN OFF DCXPOWER
ELSE
IF POWERFAIL IS OFF THEN GOTO TestPower
GOTO TimePowerOff
TURN ON CPUPOWER, DCXPOWER, MODEMPOWERSTOP
ENDIF
www.PDF-Zoo.com
Operating on Battery Backup
20-6 Infinity Controller Programmer’s Guide
Writing Another P ower Down ProgramAfter you turn off power to the DCX 250, you may want to take further action before shutting down the other controller parts. For instance, you may want to light up a status light on the controller that has been labeled OPERATING ON BATTERY.
Each status light on the front of the Infinity CX controller has a programmable system variable called STATUS1 for the first light, STATUS2 for the second, and so on up to STATUS8.
You turn on the first status light with the following statement:
TURN ON FLOOR1 STATUS1
OR
SET FLOOR1 STATUS1 = ON
As shown in Figure 12-3, an alternative PowerLoss program, you can set a status light when the power loss occurs.
This program immediately turns off power to the DCX 250. It then turns on the status light that says OPERATING ON BATTERY.
After 5 minutes elapse, the program shuts down battery power.
You could, instead of having the program turn off the CPU, have a different procedure. For instance, the first operator to notice the status light is on could contact the system administra-tor, who would then start any emergency procedures, including turning off power to the CPU from the command line.
Suppose you have a generator for major parts of your HVAC system, such as the boiler, the chiller, and the fans. You can leave the CPUPOWER up and allow the programs to continue running the equipment. Or you can shut down CPUPOWER
Preparing for PowerDown
www.PDF-Zoo.com
Operating on Battery Backup
Infinity Controller Programmer’s Guide 20-7
to save the battery and run the equipment manually until the crisis has passed.
Figure 20-3. Alternative PowerLoss Program That Turns on Status Ligh ts—Looping
Shutting down CPUPOWER supersedes any other power, since no other part of the controller functions if the CPU has no power.
File Edit Search Compile Tools
BLDG1 FLOOR1 PowerLoss
IF POWERFAIL IS ON THENLINE TestPower
IF TM > 5 and POWERFAIL IS ON THENTURN OFF MODEMPOWER, CPUPOWER, Status1
ENDIF
TURN OFF DCXPOWER
ENDIFGOTO TimePowerOffTURN ON Status1
LINE TimePowerOff
www.PDF-Zoo.com
Operating on Battery Backup
20-8 Infinity Controller Programmer’s Guide
Figure 20-4 shows the status light panel on the front of the FLOOR1 controller after the PowerLoss program has run for more than 5 minutes.
Figure 20-4. Status Ligh t Panel on Floor1 Cont ro ller in Response to PowerLoss Program
Status Light Panel onController Door
STATUS
SYSTEMSTATUS
Operating On Battery1
2
3
4
5
6
7
8
SCAN
COMM1
COMM3
www.PDF-Zoo.com
Operating on Battery Backup
Infinity Controller Programmer’s Guide 20-9
Calling for Interv entionon Power LossYou might choose to call another site on the modem when power fails, or call an individual to respond to the alarms.
Figure 20-5 shows another program that a PowerLoss program could call. The program that has four phone numbers to call when the power is down. If the equipment cannot connect to the first number, it tries the second.
Figure 20-5. Alternative PowerLoss Program That Dials Phone Numbers—Looping
Callin g an Operator Who Is Responsible
File Edit Search Compile Tools
BLDG1 FLOOR1 DialHelp
if TM > 2 and POWERFAIL IS ON~
NUMERIC NUM1, NUM2, NUM3, NUM4, OPENING, CLOSING NUM1 = "9,5085551212"NUM2 = "9,5085552222"NUM3 = "9,5085551111"NUM4 = "9,5085553333"
LINE Testing
and TOD > 7:00pm OR TOD < 6:00am thenSET PhoneNum = NUM1SET Seq = 1GOTO OpenPort
endif
LINE OpenPortOPENING = OPEN (COMM3)
LINE CallingIF OPENING = SUCCESS THEN
CALL (COMM3, PhoneNum)GOTO Ringing
endif
www.PDF-Zoo.com
Operating on Battery Backup
20-10 Infinity Controller Programmer’s Guide
Figure 20-5. Alternative PowerLoss Program That Dials Phone Numbers—Looping (cont)
Notice that on the RINGING line, the program allows 40 sec-onds for COMM3 to connect. If no connection occurs, the line adds 1 to the SEQ number, uses SEQ to form the next phone number, and goes to the CALLING line to call the new number.
This program would be an evening alternative. You would need a day program to cover daytime actions.
LINE Ringingif TS > 40 and COMM3 CXD = ON then
GOTO Connected
IF TS > 40 and COMM3 CXD = OFF thenif Seq = 4 then SET Seq = 0if Seq < 4 then SET PhoneNum = "Num";Seq + 1GOTO Calling
endif
LINE ConnectedPrint "AC Power down." To COMM3Print "Implement emergency procedures." To COMM3PRINT "Please respond immediately." To COMM3if COMM3 PrintDone = True then
TURN OFF COMM3 DTRGOTO ClosePort
endif
LINE ClosePortCLOSING = CLOSE (COMM3)
LINE EndingIF CLOSING = SUCCESS THEN STOPelse
Print "Could not close port" to Printer1
endif
endif
STOP
www.PDF-Zoo.com
Chapter 21
Introducing and P lanningAccess Cont rol
NoteIf you are not using Infinity for an access control system, skip this chapter and subsequent chapters.
Before you attempt to set up and program your access control system, this chapter explains how you get started. It covers how to plan your sites. It explains the relationships between the types of hardware you use for access control. It also intro-duces you to other elements of the access control system—access cards, card readers, keypads, and motion detectors.
You should be familiar with the concepts presented in this chapter before you set up your access control system:
• Planning Access Control Sites
• Understanding Elements of an Access Control System
• How Access Control Elements Control Entrythrough Door
• How Access Control Elements Control Exitingthrough Door
• How to Secure Windows
• Deciding Where to Mount Access Controllers
• Where Doors and Related Inputs/Outputs Areon ACX 700 Controller
• Where Doors and Related Inputs/Outputs Areon Expansion Modules
• Where Doors and Related Inputs/Outputs Are on ACX 780 Controllers
www.PDF-Zoo.com
Introducing Access Control
21-2 Infinity Controller Programmer’s Guide
Planning the Access Cont rol NetworkBefore you can control access to the various areas in a build-ing, you must begin with a drawing of the floor plan—one you will refer to many times while setting up access control.
In this drawing, show every area you want to control access to and the door or doors that provide access to each area.
Figure 21-1 shows such a drawing of a small site.
Figure 21-1. Drawin g of a SimpleSite fo r Access Control
Draw a Graphic o f Bu ild -ing or Site
Lobby
Lab
Outside
www.PDF-Zoo.com
Introducing Access Control
Infinity Controller Programmer’s Guide 21-3
Ass igni ng Areas Names
You begin by giving each area a name. In the example above, each area is labeled with an appropriate name. Notice that in addition to the Lobby and the Lab , Outside is also an area.
Since your site undoubtedly has more areas, write all the area names in the drawing so you can refer to them later.
Ass igni ng Doors Names
Once you have established the areas, you can assign each door a name, such as FrontDoor . In this particular drawing, the doors are not labeled, but below is a list of their names and where they allow access:
• FrontDoor —from Outside to Lobby• LabDoor —from Lobby to Lab
Be sure to write down the names of your doors in your draw-ing so you can refer to them later.
Assign Each Area and Door a Name
www.PDF-Zoo.com
Introducing Access Control
21-4 Infinity Controller Programmer’s Guide
Under standing Elements of an Access Cont rol S ystemBefore you can control access to the various areas in a site, you must have the following:
• An Infinity CX 9000 Controller (or any controller in the 9000 series or 220 series)
• Access Controllers (ACX 700 series)—Infinet controllers specifically designed to handle access control
• An SX 8000 Workstation—Recommended, but optional
• Card Readers and/or Keypads
• At Least One Set of Access Cards(if you are using card readers)
• Door Switches
• Door Lock Relays
• Motion Detectors or Request-to-Exit Buttons
The ACX 700 controller cabinet has a built-in cabinet tamper switch.
Also, you may want to employ the following optional devices:
• Alarm Relays—Buzzers, Lights to Flash
• GlassBreak Sensors to Detect Broken Windows
Elements Contro lling a Sing le Doorwith a 700 Contr oller
Figure 21-2 shows the required/optional access control devices for a single door that you enter and exit an area
Draw a Graphic o fBu ild ing or Site
www.PDF-Zoo.com
Introducing Access Control
Infinity Controller Programmer’s Guide 21-5
through. In this illustration, the door is controlled by an ACX 700 controller.
Figure 21-2. Access Control Elements Possib lefor a Singl e Door
Note that the SX 8000 file server is optional for access con-trol. However, it may be required if you expect to have a large database of personnel.
SX 8000File Server
9000Controller
Entry Card
1 2 34 5 67 8 9
0 * #
Entry Keypad
Reader
Request-to-ExitButton
Motion
ACX 700Controller
One ElectromagneticDoor Lock/Door Striker
12/24V
One Door Switchfor Each Door(This is a supervisoryswitch that detectstampering)
Exit CardReader
per Door
1 2 34 5 67 8 9
0 * #
Exit Keypad
Detector
One ACX 700 Controller Can Have Up to Three Doors,and Up to Two AdditionalDoors if You Use ExpansionModules
AlarmBuzzer
(or other 9000/220 series)except the 9500)
Rs
www.PDF-Zoo.com
Introducing Access Control
21-6 Infinity Controller Programmer’s Guide
Elements Contro lling a Sing le Doorwith a ACX 780 Contr oller
An ACX 780 controller uses the same access control system elements to control a door as the ACX 700 does; however in this case, notice that card readers and keypads are right next to each other. The card reader and keypad are on the same ter-minal block connector and control the same door (more later).
Figure 21-3 shows the required/optional access control devices for a single door that you enter and exit an area through. In this case, the door is controlled by a ACX 780 controller.
The ACX 780 also has an extra tamper switch that sets off an alarm if someone tries to remove the cabinet from the wall.
Understand Differencebetween 700 and 780
www.PDF-Zoo.com
Introducing Access Control
Infinity Controller Programmer’s Guide 21-7
Figure 21-3. Access Control Elements fo r a Single Door on the ACX 780 Controlle r
How does all this equipment work to control access to an area?
SX 8000File Server
9000Controller
Entry Card
123456789
0 *#
Entry Keypad
Reader
Request-to-ExitButton
Motion
780Controller
One ElectromagneticDoor Lock/Door
12/24V
One Door Switchfor Each Door(This is asupervisoryswitch that
Exit CardReader
Striker per Door
1 2 34 5 67 8 9
0 * #
Exit Keypad
Detector
One ACX 780 Controller CanHave Up to Eight Doors,with an Alarm Buzzer
AlarmBuzzer
(or other 9000/220 seriesexcept the 9500)
Rsselects tampering)
Tamper Switch
ACX 780 hasan additionaltamper switchthat indicatessomeone isattempting toremove thecabinet fromthe wall.
www.PDF-Zoo.com
Introducing Access Control
21-8 Infinity Controller Programmer’s Guide
How Access Cont rol Elements Control E ntry throug h DoorWhich elements of the control system control entry through a door? Card readers and keypads provide information to deter-mine when the controller should open the door lock. How does it all happen?
Using Ac cess Cards to Ente r
When you purchase your access control system, you alsopurchase a set (or multiple sets) of access cards that you dis-tribute to personnel. (Unless you choose to use strictly keypads.)
As shown in Figure 21-4, each card holder swipes the card through a card reader to gain access to an area.
Figure 21-4. Swiping an Access Card Through a Card Reader
The set of cards is either Wiegand or ABA, to match the card reader you have selected. (You can also use cards from your AC4+4 if you are upgrading to the new access control system.)
Each card is encoded with two numbers: site code and card number.
The site code is a number from that identifies the site. This number is the same for the entire set of cards. To accommo-date multiple sets of cards for the same area, you can have up to four different site codes for the same area.
You May Purchase Setsof Acces s Cards
www.PDF-Zoo.com
Introducing Access Control
Infinity Controller Programmer’s Guide 21-9
The card number is a number unique to that particular card that allows you to identify the individual card holder. The card number is up to five digits encoded into the card.
The person holding the card does not need to know the card number—the individual need only swipe the card through the card reader. The control system then reads the number from the card, finds it in the database, and checks to see if the per-son should be allowed to enter. If so, the system then unlocks the door.
The system also records whether or not the person actually opens the door. The door switch indicates whether or not the door was opened. If the person opens the door and, presum-ably, enters through it, the access control system records an event—a Valid Access event.
Using Key pads to En ter
When you purchase your access control system, you also pur-chase a numeric keypad that you wire to the controller. The individual who wants to enter the area types a series of digits (called an “punching an access code”) on the keypad and presses the pound (#) key. You assign the access codes.
You can assign two types of access codes:
• Same code to all personnel (called a “general code”)
• Unique personal identification number (PIN) to each individual
The person who wants access must remember the access code.
Once the individual punches the code on the keypad and presses the pound key, the control system reads the number, finds it in the database, and checks to see if the person should be allowed to enter. If so, the system then unlocks the door.
The door switch indicates whether or not the door was opened. If the person opens the door and, presumably, enters
You May PurchaseNumeric Keypads
www.PDF-Zoo.com
Introducing Access Control
21-10 Infinity Controller Programmer’s Guide
through it, the access control system records an event—aValid Access event.
Figure 21-5 shows an entry door with an entry card reader, entry keypad, door lock, and door switch wired to the controller.
Figure 21-5. Entry Door Hardware Setup
Card Reader, Keypad,Door Lock an d Swit ch
ACX 700 SeriesController
Entry Card
1 2 34 5 67 8 9
0 * # Entry Keypad
Outside of Door
Reader
ElectromagneticDoor Lock/Door Striker
Rs
Door Switch
12/24V
—Entry
One Card Reader,or One Keypad, or Bothfor Allowing Entry throughDoor/Monitoring Who Enters
Person swipes access card through card reader.Person punches an access code on the keypad.(You can require the person to do both to enter.)The controller verifies that the person is allowed to enter andunlocks the door lock. The door switch determines that the door opens.
www.PDF-Zoo.com
Introducing Access Control
Infinity Controller Programmer’s Guide 21-11
Using Both Card Readersand Keypads to Enter
You can have all personnel allowed to enter an area both swipe an access card through a card reader and punch an ac-cess code on a keypad. This arrangement is useful for extremely high-security areas.
Card numbers and PINs allow you to track the access of per-sonnel. If a valid access event occurs, the control system also records the time the event occurs, so you have a record of who enters and when.
Card Reader and Keypad Provide Strong Securi ty
www.PDF-Zoo.com
Introducing Access Control
21-12 Infinity Controller Programmer’s Guide
How Access Cont rol Elements Control E xiting through DoorWhich elements of the control system control exiting through a door? You can choose more than one way to control exit-ing—monitoring the particular personnel that exit or not monitoring the particular personnel, but simply unlocking the door as personnel approach it.
Unlocki ng the Door on Request
When a person approaches the door, if you want the door to automatically unlock so the person can exit, you can set up a motion detector above the door so that it detects someone ap-proaching. The motion detector senses motion and sends that fact into the controller. The controller then unlocks the door, so that the person can open it.
Instead of having a motion detector, you can set up a button the person should press to unlock the door. This type of button is called a request-to-exit button.
Figure 21-6 shows an exit door that automatically opens as personnel approach. It has a motion detector or request-to-exit button. The door is, of course, still wired to the door switch and door lock.
Install Motion Sensor toUnlock Door on Request
www.PDF-Zoo.com
Introducing Access Control
Infinity Controller Programmer’s Guide 21-13
Figure 21-6. Exit Door Hardware Setup to Allow Exit on Request
Exit Door Automatical ly Opens on Approach
Inside of Door
Request-to-ExitButton
Motion Detector
700 seriesController
ElectromagneticDoor Lock/Door Striker
Door
12/24V
Either Request-to-Exit Button or Motion
Person approaches door to exit and either amotion detector detects movement or the personmust press an exit button (Request-to-Exit). The controller then unlocks the door lock for the person.
Switch
—Exiting
Detector
The door switch determines that the door opened.
Rs
www.PDF-Zoo.com
Introducing Access Control
21-14 Infinity Controller Programmer’s Guide
Monito ring Wh o Exits When
If you want the control system to record who is exiting and the time the person exits, you can have each person swipe an ac-cess card to exit or punch a PIN on a keypad. The control system records the person’s card number of PIN and then un-locks the door. For this arrangement, you do not require a motion detector or request-to-exit button.
In a high-security situation, you may want personnel to both swipe a card and punch a PIN on a keypad.
Figure 21-7 shows an exit door that monitors who exits when. It has an exit card reader and exit keypad; you can use either one or the other. The door is, of course, still wired to the door switch and door lock.
Assign PIN Code toMonitor Who Exits When
www.PDF-Zoo.com
Introducing Access Control
Infinity Controller Programmer’s Guide 21-15
Figure 21-7. Exit Door Hardware Setup to Monitor Who Exits When
Now, determine the kind of access control you need. Then you can wire the appropriate sensors and relays for each door to the controller. Where do you wire all of the sensors and re-lays to control a door?
Card
Inside of Door
Reader
700 seriesController
ElectromagneticDoor Lock/Door Striker
Door
12/24V
Optional Card Reader or Keypad, or Both, forAllowing Exit through Doorand Monitoring Who Exits
123456789
0 *#
Entry Keypad
The controller records the card site code, card number,keypad general code or personal identification number (PIN),and then unlocks the door lock.
Person swipes an access card through the card reader.Person punches an access code on the keypad.(You can require the person to do both to exit.)
Switch
—Exiting
Rs
Determine AccessControl Required
www.PDF-Zoo.com
Introducing Access Control
21-16 Infinity Controller Programmer’s Guide
How to S ecure WindowsIn addition to wiring doors for security, you can also wire windows. Andover’s complete access control system ensures that no one can break in through a window.
For instance, you can purchase a glassbreak and/or acoustic vibration sensor that you attach to the window according to the manufacturer’s instructions. You then wire the sensor to one of the eight supervisory inputs on the ACX 700 series con-troller. The sensor detects acoustic energy or vibration (or both) when the glass breaks.
Figure 21-8 shows a window that has been secured with a glass break sensor.
Figure 21-8. Secured Window Setup
A glassbreak sensor is considered a supervisory input.
Protect Windows fromBreak-Ins
700Controller
GlassBreakSensor
Rs
www.PDF-Zoo.com
Introducing Access Control
Infinity Controller Programmer’s Guide 21-17
Determining Wher e to Mount Access Cont rolle rsNow, let’s return to your drawing.
Using your drawing, you can decide where you want to put your access controllers, ACX 700 series controllers. Be sure to place the ACX 700 series controller inside the secured area, so it is not available to potential tampering from outside the area.
Add the name and location of each ACX 700 series controller to your drawing.
Figure 21-9 shows the ACX 700 and 780s used at the Andover site.
Figure 21-9. Drawing of a SiteShowin g Location of ACX 700 or 780 Controlle r
Mount Your AccessController s Strategical ly
Lobby
Lab
Outside
700 Series Controller (DoorController)
www.PDF-Zoo.com
Introducing Access Control
21-18 Infinity Controller Programmer’s Guide
Where Doors and Related Inputs/ Outp uts Are on ACX 700 ControllerFigure 21-10 illustrates where the sensors and relays should be wired.
You wire the following sensors to any of the eight supervisory input terminals:
• Door Switch
• Motion Detector
• Request-to-Exit Button
• GlassBreak Sensors (for windows or windows on doors)
You choose either a motion detector or a request-to-exit but-ton, not both.
You wire a card reader to one of the two Reader terminals and a keypad to one of the Keypad terminals. You can have both an entry and an exit card reader for one door. You can also have both an entry and an exit keypad for one door.
You wire the door lock to one of the two Door terminals. After you have wired a door to each of the Door terminals, if you want a third door, you can wire a third one to Output3 (below the Door terminals).
If you prefer, you can wire an alarm buzzer to Output3.
NoteYou can program any supervisory input to go with any door. And you can program any card reader and/or keypad to go with any door. So, wire them as you see fit, then be sure you write down which one goes with which, so that you can later properly set up the Door .
Wire Doors and RelatedInputs/Outputs
www.PDF-Zoo.com
Introducing Access Control
Infinity Controller Programmer’s Guide 21-19
For details on how to wire each type of sensor and relay, refer to the ACX 700 Installation Guide.
Figure 21-10. Where to Connect Access Cont rol Sensors and Relays on ACX 700 Cont roller
In addition to having up to three doors on an ACX 700 control-ler, you can also have up to two additional doors on EMX 190 expansion modules.
AUTO/OFF/ON
AUTO/OFF/ON
DOOR OUTPUT
KEYPAD 2C3C2C1
DOOR 1OUTPUT
AUTO/OFF/ON
INFINET
OVERRIDE
C3C2C1
SHLD–
GNDO/CLKI/DATALED+5V
GNDO/CLKI/DATALED WIEGAND
ABA
RET8
RET4
IN8RET7IN7RET6IN6RET5IN5
IN4RET3IN3RET2IN2RET1
----
AC INPUT VOLTAGE SELECTION
TO230V
E6
P1
FROM24V
TOE6
P1
FROM
E2
TO
P1
FROM115V
ACX700
B1
3.6V
1.8AHr
LITHIUM
RD
TD
CPU
EXPANSION
PORT
SERVICE
PORT
+
KEYPAD 1SUPERVISORYINPUTS
EXT
TAMPER
SWITCH
RESET
+5V
WIEGAND
ABA
IN1
-INPUT
+12VDC PWRON
-
+
USE COPPERCONDUCTORS
ONLY
F13A,250V
SLOW BLOW
NEU
HOT
GND
ACINPUT
E7 E5E4 E3 E4 E4 E5
E1 E1 E2
READER 1
READER 2
TAMPER
SWITCH 9
R1R2R3R4RET
RETR4R3R2R1
OUTPUT 3
OVERRIDE
+24VDC CLASS 11160 mA
Motion DetectorsDoor Switches
Request-to-Exit Buttons
GlassBreak Sensors
Card Readers
Keypads
Door Locks
Door Lockor Buzzerfor Alarm
12VDCPowerSupply
(if needed)
www.PDF-Zoo.com
Introducing Access Control
21-20 Infinity Controller Programmer’s Guide
Where Doors and Related Inputs/ Outp uts Are Located on Expansion ModulesFigure 21-11 is a drawing of an EMX 190 module. You can attach up to two EMX 190 expansion modules to the Expansion Port on each ACX 700 controller.
The expansion module has a single door terminal. It also has terminals for a door switch, request-to-exit button, and card reader. It does not have terminals for a keypad. You can wire any two “supervisory” inputs to the channels labeled Door Switch and Exit Request. You must, of course, always wire the card reader to the Card Reader Input channel.
Figure 21-11. Points on 190 Expansi on Modul e
Poin ts on an EMX 190
EMX190
OVERRIDE
DOOROUTPUT
NO CNC
ABA
CARD READER
AUTO
24VDC
CLASS
+5V
1/DATALED
0-CLKRTN
2
1BOARD
OVERRIDEOFF
ON
DOOR SWITCHRTN
EXIT REQUESTRTN
CARDREADER
INPUT
WIEGAND
II
Door Channel
If you have a card reader,you must wire it to CardReader channel. You canwire a door switch, exit button, motion detector, glassbreak sensor, or anyother type of supervisoryinput to the DoorSwitch and Exit Request channels.
www.PDF-Zoo.com
Introducing Access Control
Infinity Controller Programmer’s Guide 21-21
The EMX 190s must always be the first output modules on a chain of modules attached to the ACX 700. If you have one, it must be Board 1. If you have two EMX 190s, they must be Board 1, then Board 2.
You can also connect other modules to an ACX 700 controller, as long as you do not exceed the maximum number of inputs/outputs allowed:
• Base Inputs (Supervisory) (Already on Controller)—8
• Expansion Inputs (on Modules)—21
• Total Inputs—29
(Note that card readers and keypads are not inputs, but set up as parts of the door, as you see in later chapters.)
• Base Outputs (Already on Controller)—3
• Expansion Outputs (on Modules)—4
• Total Outputs—7
Figure 21-12 shows a sample map of modules on an ACX 700 controller, using the maximum number of input and output channels allowed. (You assign door-related input and output channels later, when you set up the access control system.)
Can Have Mult ipleExpansi on Modules
www.PDF-Zoo.com
Introducing Access Control
21-22 Infinity Controller Programmer’s Guide
Rules fo r Attach ing Sensors/Relays to Expans ion Modu les on A CX 700 Control lers
The following rules apply to the output expansion modules on an ACX 700 controller:
• The first two output expansion modules must be EMX 190s). The following applies to them.
—Wire a door or alarm buzzer to the Door output.
—Wire up to two inputs to the following to total of the channels: DoorSwitch, ExitRequest, and Card Reader.
—Wire any of the following to the channels labeled DoorSwitch and ExitRequest: Door switch,request-to-exit button, motion detector, glassbreak sensor, or similar supervisory input.
—Wire a card reader to the channel labeled Card Reader.
• For the third output expansion module—You must assign channels as output points 6 and 7. They can be any of the following:
— EMX 150
—EMX 151
—EMX 155
—EMX 140
Wire a relay of the following type to the appropriate output module: Voltage , Current , Digital , HiResVoltage , HiResCurrent , and Pneumatic . For further informa-tion on these modules, refer to Chapter 1.
Carefully Follo w Rulesfor Expansion Modu les
www.PDF-Zoo.com
Introducing Access Control
Infinity Controller Programmer’s Guide 21-23
The following rules apply to the input expansion modules on a ACX 700 controller:
• The first and second input modules must be either counter or digital inputs found on a EMX 160 expansion module.
• The EMX 170 module must be the very last module on the chain.
Figure 21-12. Sampl e Set Up of Expansion Modules on ACX 700 Controlle r
You Can Have Up to16 Coun ter/Digital Inp uts
ACX 700
EMX 190—Board 1
EMX 190—Board 2
EMX 160—Board 1
EMX 160—Board 2
EMX 170
EMX 150—Board 1
ExternalPowerSupply
1 Output, 2 Inputs
1 Output, 2 Inputs
2 Outputs
8 Digital Inputs
8 Digital Inputs
Door or Alarm Channel
Door or Alarm ChannelSupervisory Inputs
Two Outputs—Voltage
Eight Inputs—Digital or Counter
Eight Inputs—Digital or Counter
One Input—Temperature
You assign these outputnumbers very carefully, as covered laterin chapter on setting up access control.
Supervisory Inputs Wirefor SameDoor
Wirefor SameDoor
Instead of a EMX 150, you canput any output module, exceptanother EMX 190, for a total oftwo outputs after any EMX 190s.
—1 Input
www.PDF-Zoo.com
Introducing Access Control
21-24 Infinity Controller Programmer’s Guide
Now that you have wired all of your hardware, you are ready to set up your controllers, terminals, and users, then your ar-eas, doors, and personnel. Later, you also set up points if you need them. Go back to the Chapters 2 and 3 and proceed
through them sequentially. Then go to Chapter 22.
www.PDF-Zoo.com
Introducing Access Control
Infinity Controller Programmer’s Guide 21-25
Where Doors and R elated I nputs/Output s Ar e on AC X 780 ControllersFigure 21-13 illustrates where the sensors and relays should be wired on an ACX 780 controller.
You wire the following sensors to any of the supervisory input terminals:
• Door Switch
• Motion Detector
• Request-to-Exit Button
• GlassBreak Sensors (for windows or windows on doors)
You choose either a motion detector or a request-to-exit but-ton, not both.
You wire a card reader to one of the Reader terminals and a keypad to one of the Keypad terminals. You can have both an entry and an exit card reader for one door. You can also have both an entry and an exit keypad for one door.
Notice that card readers and keypads are in pairs, the card reader right next to the keypad that goes to the same door.
For instance Card Reader 1 and Keypad 1 are wired next to each other, assigned the same channel number in the software, and control either entry or exit through the same door output, such as the door wired to Output 1.
You wire the door lock to one of the Output terminals. After you have wired a door to each of the eight Output terminals, if you want another door, you can wire a ninth one to Output 9.
If you prefer, you can wire an alarm buzzer to Output 9.
For details on how to wire each type of sensor and relay, refer to the ACX 780 Installation Guide.
Wire Door s and RelatedInput s/Output s
www.PDF-Zoo.com
Introducing Access Control
21-26 Infinity Controller Programmer’s Guide
F
igu
re 2
1-13. W
h
er
e to C
on
n
ect A
cces
s C
on
tro
l S
en
so
rs a
nd
R
elay
s o
n
A
C
X
780
C
on
tro
ller
AC
X78
0
IN5
RE
T
IN8
IN7
RE
T
RE
T
IN4
IN3
RE
T
IN2
IN1
RE
T
IN6
IN13
RE
T
IN16
IN15
RE
T
RE
T
IN12
IN11
RE
T
IN10
IN9
RE
T
IN14
IN21
RE
T
IN24
IN23
RE
T
RE
T
IN20
IN19
RE
T
IN18
IN17
RE
T
IN22
IN29
RE
T
IN32
IN31
RE
T
RE
T
IN28
IN27
RE
T
IN26
IN25
RE
T
IN30
INF
INE
T
+ — SH
LDR
D
TD
ER
RO
RN
O S
RV
CP
U+
5V+2
4V+1
5V-1
5V-5
VA
C P
WR
SE
RV
ICE
PO
RT
RE
SE
TO
VE
RR
IDE
OU
TP
UT
S
NC
C NO
1
NC
C NO
2
NC
C NO
3
NC
C NO
4
ON
OF
F
AU
TO
OU
TP
UT
1
ON
OF
F
AU
TO
OU
TP
UT
2
ON
OF
F
AU
TO
OU
TP
UT
3
ON
OF
F
AU
TO
OU
TP
UT
4
ON
OF
F
AU
TO
OU
TP
UT
5
ON
OF
F
AU
TO
OU
TP
UT
6
ON
OF
F
AU
TO
OU
TP
UT
7
ON
OF
F
AU
TO
OU
TP
UT
8
ON
OF
F
AU
TO
OU
TP
UT
9
D I S P L A Y
+ 5 V
L E D
1 / D A T A
0 / C L K
G N DR I
R 2R 3
R 4C 1
C 2C 3
R E T
RE
AD
ER
1 —
KE
YP
AD
1
FO
R D
ET
AIL
ED
INS
TA
LLA
TIO
N IN
ST
RU
CT
ION
S,
RE
VIE
W D
OC
UM
EN
T, 3
0-30
01-3
92,
DA
TE
D 1
993
RE
AD
ER
2 —
KE
YP
AD
2
+ 5 V
L E D
1 / D A T A
0 / C L K
G N DR I
R 2R 3
R 4C 1
C 2C 3
R E T
RE
AD
ER
5 —
KE
YP
AD
5
RE
AD
ER
6 —
KE
YP
AD
6
+ 5 V
L E D
1 / D A T A
0 / C L K
G N DR I
R 2R 3
R 4C 1
C 2C 3
R E T
RE
AD
ER
3 —
KE
YP
AD
3
RE
AD
ER
4 —
KE
YP
AD
4
+ 5 V
L E D
1 / D A T A
0 / C L K
G N DR I
R 2R 3
R 4C 1
C 2C 3
R E T
RE
AD
ER
7 —
KE
YP
AD
7
RE
AD
ER
8 —
KE
YP
AD
8T
AM
PE
RS
WIT
CH
WA
RN
ING
HIG
H V
OLT
AG
E P
RE
SE
NT
DIS
CO
NN
EC
TP
OW
ER
PR
IOR
TO
SE
RV
ICIN
G
SC
AN
NC
C NO
5
NC
C NO
6
NC
C NO
7
NC
C NO
8
NC
C NO
9
Car
d R
eade
rs a
nd K
eypa
ds
Mot
ion
Doo
r S
witc
hes
Exi
t Req
uest
But
tons
Sup
ervi
sory
Inpu
ts
Doo
r Lo
cks
Gla
ss B
reak
Doo
r Lo
ckor
Buz
zer
for
Ala
rm
Tam
per
Sw
itch
Det
ecto
rs
Sen
sors
www.PDF-Zoo.com
Chapter 22
Setting UpAreas and Doors
for Access Cont rolThis chapter tells you how to set up areas and doors to useInfinity CX as an access control system.
www.PDF-Zoo.com
Areas and Doors
22-2 Infinity Controller Programmer’s Guide
Before You P roceedBefore you proceed, you must have already done the follow-ing:
• Set up your network following the EnergyNet and Infinet Configuration Guide and Chapters 1 and 21.
• Wire your ACX 700 series controllers as shown in the hardware installation guide (see also guidelines in Chapter 21).
• Plan a map of your areas and assigned names to areas and doors (in the map), as explained in Chapter 21.
Preparing to Set UpAreas and Doors
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-3
Getting Started in Access ControlBegin by reading Chapter 21. If you have not read it, you are not yet ready to proceed. Once you have a labeled map of your areas, return to Volume 1 and proceed as follows:
• Set up your controllers as explained in Chapter 2.
• Set up your terminals and printers as explained in Chapter 3.
You are now ready to carry out the following procedures:
• Deciding Where to Store Access Control Information
• Designating Where to Store Access Control Information
• Setting Up Areas
• Setting Area Attributes
• Setting Up Doors
• Setting Door Attributes
• Setting Door Channel Information
• Setting Card Formats
• Setting Up the Entry Card Reader or Keypad
• Setting Up the Entry Card Reader or Keypad Options
• Finding Out Entry Reader or Keypad Status
• Setting up the Exit Card Reader or Keypad
Set Up Controlle rs
www.PDF-Zoo.com
Areas and Doors
22-4 Infinity Controller Programmer’s Guide
Deciding Wher e to Store Access Cont rol I nforma tionOnce you have drawn the map of your areas and doors, there is one more item you need to make decisions about before you give all this information to the access control system—the people who access the area.
Each person who has an access card or keypad number that al-lows access to one or more areas is called a“person” in the access control system. You can set up each person to have ac-cess to all areas or to only particular areas.
Now, estimate the number of people you expect to have enter-ing through the doors on a single controller. You can store up to 1500 people in an ACX 700 controller, without programs or other information there. You can store up to 6400 people in the ACX 780 controller, without programs or other informa-tion. If you want to store areas, doors, programs, or other information in an ACX 700 series controller, you would do best to store fewer than the maximum number of people. And, of course, the ACX 700 series controllers run more quickly when it is not filled to capacity.
If you want to store all access control information (areas, doors, and people) on the ACX 700 or 780, you may. But if you think not all people can be on the ACX 700 or 780, store them, instead, in one of the following locations:
• The Infinity CX 9000 controller that the ACX 700 series controller’s Infinet is connected to
• In the SX database, under the root (above the sites in the Object Tree )
You can choose one of these options, but not both. To deter-mine where to store your access control information, you determine first where to store the people.
Follow the flowchart in Figure 22-1 to decide where.
People Use Cardsor Keypads
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-5
Figure 22-1. Flowchart fo r Decidin g Where to Store Access People
Fol low Flowchar tfor Where to Put People
Do PeopleAccess Multiple
Sites?
Are PeopleAll on One LAN
?
Number GreaterThan Can Fit on
9000/220?
Would YouPrefer People
on 8000?
NumberGreater Than
1500?
Put underRoot inSX 8000Database
Put in9000 or 220ControllerDatabase
Do PeopleAccess Doors on More
Than One 700?
No
No
No
No
No
No
Put Peoplein 700ControllerDatabase
Yes
Yes
Yes
Yes
Yes
Yes
www.PDF-Zoo.com
Areas and Doors
22-6 Infinity Controller Programmer’s Guide
If you are still uncertain where to store people, refer to the guidelines that follow.
Stor ing Person Information
If you expect to have close to 1500 people or considerably more people, do not store them on the ACX 700 controller. Similarly, if you expect to have 6400 people or considerably more people, do not store them on the ACX 780 controller.
You can store more people in an Infinity CX 9000 series (or CMX 220) controller and should store people on an Infinity CX 9000 or CMX 220 only if you can fit all of the people on one controller. Refer to Appendix D to determine how many people you can store on a single Infinity CX 9000 controller.
If you cannot store all people on an Infinity CX 9000 control-ler, you should store people on the workstation database. You can store and up to 57,000 people (or up to the limit of your disk capacity) under the root in the SX 8000 database.
Storing Area Info rmation
If you choose, you can store area information in the Infinity CX 9000 controller or under the root in the SX database.
If you choose to store people in the Infinity CX 9000, then you must also store areas in the Infinity CX 9000, and cannot store any access control information under the root in the SX data-base.
If you choose to store people under the root in the SX data-base, then you must also store areas in the SX database, and cannot store any access control information in the Infinity CX 9000 controller.
Choose Where to StoreAccess Control Inf o
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-7
If you store the areas in the SX software, you must access the information about them through an SX 8000 workstation, not through the windows on a terminal connected to the Infinity CX 9000 controller.
This manual assumes you are storing areas and personnel in the Infinity CX 9000 or ACX 700 series controller. For infor-mation on how to store areas and personnel on a workstation, refer to the SX 8000 Programmer’s Guide.
Stor ing Door Information
You must always store doors in the ACX 700 series controller. You cannot store doors anywhere else—not in an Infinity CX 9000 controller and not under the root in the SX database.
Figure 22-2 shows three basic options for storing access control information.
Determine Where to Store Acces s Info
www.PDF-Zoo.com
Areas and Doors
22-8 Infinity Controller Programmer’s Guide
Figure 22-2. Three Basic Options fo r Stor ing Acc ess Control Information
Once you have decided where to store areas and people, you are now ready to tell the control system where you want to store your information.
9000 Controller
Option 1. Store All Access Control Information on 700s
700 Controller(s)
700 Controller(s)
Option 2. Store Some Access Control Information on 9000,
SX Server Database
700 Controller(s)
Option 3. Store Some Access Control Information in SX Database,Some on 700s
Some on 700s
Store Areas, Doors, and PeopleAll in 700s
Store Doors andCopies of Key
Store Doors andCopies of Key
Store Areas
Store Areas
and People
and People
People
People
Decide Where to StoreAcces s Inf o
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-9
Summary
Before you set up Infinity to control access to your areas, you must decide where to store the access control information based on a number of factors:
• You must store all people and all areas in same controller (or all in the workstation database).
• You must store doors in the ACX 700 series controller you wired them to.
• You can store up to 1500 people in a single ACX 700series controller.
• You can store a varying number of people on a single Infinity CX 9000 controller. You can calculate the exact number by following the instructions in Appendix D.
• You can store all people, areas, and doors on the ACX 700 series controller if you can fit all of them on a single controller. This situation is likely only at very small sites.
Decide Where to Store Access Info
www.PDF-Zoo.com
Areas and Doors
22-10 Infinity Controller Programmer’s Guide
Designating Wher e to Store Access Cont rol I nforma tionBefore you proceed, you must tell the control system which piece of hardware on the EnergyNet or Infinet is storing most of the access control information—the areas and people. That unit becomes the “access server.”
Making the ACX 700 Series Control lerthe Access Server
If you are storing all access control information on the ACX 700 series controller, it is its own “access server,” because it functions as a “stand-alone” controller. In this situation, you do not have to take any special action. The control system ex-pects the ACX 700 series controller to be its own access server.
Making the Infin ity CX 9 000 Controlle r the Access Server
If you are storing any access control information on the Infin-ity CX 9000 controller, it becomes the access server. You must indicate this by connecting to the ACX 700 series con-troller (using CD as described in the Andover Controls Plain English Language Reference), then typing the following in the Command window:
Set AccessServer = 120
The 120 is an example of the EnergyNet ID of an Infinity CX 9000 controller. You should, of course, give the ID of yourInfinity CX 9000 controller. This command sets theAccessServer system variable to the EnergyNet ID of the access control server.
Tell Cont rol Syste mWhere to S tore Info
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-11
If you are not connected to the ACX 700 series controller, you must give the full path to it when typing in the Command window. For instance, to set the AccessServer value on an ACX 700 series controller called FRONTBLDG that is con-nected to the FLOOR1 Infinity CX 9000, type the following in the Command window:
Set Floor1 FrontBldg AccessServer = 120
Repeat this procedure for each ACX 700 series controller.
Summary
If you use an Infinity CX 9000 controller to store areas and people, you must tell the ACX 700 series controllers on the Infinet which controller stores them. To tell the controllers, you set the AccessServer on each one as follows:
1. Find out the EnergyNet ID of the controller that stores the areas and people. Refer to your system map or look at the controller itself.
2. Select Connect on the Main menu bar and connect to the ACX 700 series controller.
3. Go to the Command window and type the following:
Set AccessServer = 118
4. Replace 118 with the EnergyNet ID of the Infinity CX 9000 controller.
Connect to 700Controller
www.PDF-Zoo.com
Areas and Doors
22-12 Infinity Controller Programmer’s Guide
Sett ing Up Are asBefore the control system can control access to an area, you must tell it about all areas. You tell the control system the names you have given those areas as follows (remember to press the NEXT ATTRIBUTE key to move from text box to text box):
1. Go to the Main Menu bar and select Edit , then Areas .
Figure 22-3 shows the menu.
Figure 22-3. Selec ting Edit Areas
In a moment, the Open an Area window appears.
Figure 22-4 shows the window.
2. Look at your network map to verify the name of the controller that is the access server. If the correct name does not appear in the Controller text box, press the DELETE LINE/TEXT key to erase the name. Then type the correct one. Or use the SHOW LIST key to select another name.
Tell Control Syst emabout Each A rea
UsersPointsFilesCommPortsControllerInfinet ControllerSystem Date & Time
View
System VariablesPersonsAreasDoors
Edit Connect Logout
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-13
Figure 22-4. Open an Area Window
3. If you are using the ACX 700 series controller as the access server, verify the name of the Infinet controller from your network map. If the correct name does not appear in the InfinetCtlr text box, press the DELETE LINE/TEXT key to erase the name. Then type the correct one. Or use the SHOW LIST key to select another name.
4. Check your access control map for the name of your area. Remember the name can be up to 16 characters, including letters, numbers, and underscores, and must begin with a letter of the alphabet.
5. Type the name of your area in the Name text box and press the EXECUTE key to proceed.
The Area window opens. To fill in the text boxes in that window, proceed to the next section.
Controller
Open an Area
InfinetCtlr
View Edit Connect Logout
Name
DELETE LINE/TEXT Erases Entire Name
www.PDF-Zoo.com
Areas and Doors
22-14 Infinity Controller Programmer’s Guide
Sett ing Area At tributesFigure 22-5 shows the Area window that now appears. In this window, you press the NEXT ATTRIBUTE key to move from attribute to attribute.
You see only two attributes for an area:
1. In the Name text box, you see the name you just assigned the area. You can change it here if you would like. Then press the NEXT ATTRIBUTE key to move to the next text box.
2. You can fill in the Description , up to 32 characters including spaces. The description is optional.
3. Known Occupancy Count (KnownOccupCount)—Usually, the control system calculates the number of people that enter the area and displays the total number here. Each time a person swipes a card through a card reader to enter an area, the control system adds that person to the count and each time a known person swipes a card through a card reader to leave an area, the control system subtracts that person from the count. This count is not necessarily perfect, since more than one person can enter or exit through the door once a single cardholder opens it.
Because the count can be inaccurate, you may want to alter it in the future. Type the number here.
Type Descr iption of Areain Area Setup Window
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-15
Figure 22-5. Area Window 1
4. Press the DETAILS button and the Area Details window appears. To the left you see a large empty box and to the right a QUIT button. The large empty box is where you later see a list of the doors associated with this area. They appear here after you have set up the doors.
Figure 22-6 shows the Area Details window.
To the left you see a large empty box and to the right a QUIT button. The large empty box is where you later see a list of the doors associated with this area. They appear here after you have set up the doors.
1. If you see other attributes in your window, ignore them. They are not avail-able for Version 1.4.
View Edit Connect Logout
Name
Description
Lab
DELETE
SAVE AS
CANCEL
SAVE
Known Occupancy Count
DETAILS
Andover Lab area
14
Area – Floor1 Lab
Area Details Bla nk until You Set Up Doors
www.PDF-Zoo.com
Areas and Doors
22-16 Infinity Controller Programmer’s Guide
Figure 22-6. Area Details W indow—Doors That You Can Ent er Thi s Area Throu gh
5. To return to the previous window, press the QUIT button.
6. To save the area and keep the window open so that you can define more areas, use the SAVE AS button, just as you have done with other objects.
7. To save the area and close the window, press the SAVE button.
8. To cancel the area, press the CANCEL button.
9. To delete the area, press the DELETE button. If you press the DELETE button, a window appears asking you if you want to cancel the action. This window prevents you from deleting an area by mistake.
Next, you set up the doors for each area.
View Edit Connect Logout
QUIT
Area – Floor1 Lab
Floor1 Lab
Save Area with SAVE ASButton
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-17
Summary
You open the Area window by selecting Edit Areas from the Main menu bar.
Inside the Area window opens, fill in the attributes of the area. Attributes of an area are as follows:
• Name
• Description
• Known Occupancy Count
You can change the Known Occupancy Count to correct it if some people have entered the area without being counted.
Later, after you have set up doors, you can press theDETAILS button and see a list of doors you can enter this area through.
Points Must Be Named
www.PDF-Zoo.com
Areas and Doors
22-18 Infinity Controller Programmer’s Guide
Sett ing Up Doo rsTo tell the control system the name of each door that accesses an area, you set up each door as follows:
1. Go to the Main Menu bar and select Edit , then Doors .
Figure 22-7 shows the menu.
Figure 22-7. Selec ting Edit Doors
In a moment, the Open a Door window appears.
Figure 22-8 shows the window.
Tell Control Syst emName of Each Door
UsersPointsFilesCommPortsControllerInfinet ControllerSystem Date & Time
View
System VariablesPersonsAreasDoors
Edit Connect Logout
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-19
Figure 22-8. Window fo r Opening a Door
2. Verify the name of the controller from the network map. If the correct name does not appear in the Controller text box, press the DELETE LINE/TEXT key to erase the name. Then type the correct one. Or use the SHOW LIST key to select another name.
3. Verify the name of the ACX 700 series controller the doors are wired to (refer to your network map). If the correct name does not appear in the InfinetCtlr text box, press the DELETE LINE/TEXT key to erase the name. Then type the correct one. Or use the SHOW LIST key to select another name. Remember, all doors are on ACX 700 series controllers.
4. Check your access control map for the name of your door. Remember the name can be up to 16 characters, including letters, numbers, and underscores, and must begin with a letter of the alphabet.
5. Type the name of your door in the Name text box and press the EXECUTE key to proceed. (Do not name any door “door,” since that is the class name.)
The Main Door Setup window opens. To fill in the text boxes in that window, proceed to the next section.
Controller
Open a Door
InfinetCtlr
View Edit Connect Logout
Name
DELETE LINE/TEXT Erases Entire Name
www.PDF-Zoo.com
Areas and Doors
22-20 Infinity Controller Programmer’s Guide
Sett ing Doo r At tributesIn the Main Door Setup window, you observe the attributes of the door, and set some of them.
Figure 22-9 shows the Main Door Setup window. Press the NEXT ATTRIBUTE key to move from text box to text box.
Figure 22-9. Main Door Setup Window
Respond to each attribute as follows:
1. In the Name text box, you see the name you just assigned the door. You can change it here if you would like.
2. You can fill in the Description , up to 32 characters including spaces. The description is optional.
3. Door Lock (VALUE)—Displays the current setting of the door striker relay, which controls the door lock—Locked or Unlocked . You can change the setting in this text box to lock or unlock the door.
Set Door Attributes
View Edit Connect Logout
Name
Description
LabDoor
Door Lock
Alarm StatusENTRY READER
SAVE AS
CANCEL
SAVE
Door Status
EXIT READER
Door to first floor lab
Normal
Enabled (X) Disabled ( )
State
Locked
Normal
DETAILS1
Door Switch
Door – Floor1 Front LabDoor
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-21
4. Door Status —Displays a quick summary of the door situation at this moment. It can include any of the following:
• DoorAjar —Door is ajar.
• ForcedEntry —Intruder has broken in through the door.
• Override —Person has set the door to manual control (override), so that the controller does not control it.
• DoorFault —Wires to the card reader or keypad have been cut, shorted, or otherwise tampered with.
• Normal —Door is closed and none of the above situations exist.
5. Door Switch (DoorSwitch)—You can wire a separate status switch to one of the supervisory inputs on the ACX 700 series controller. The DoorSwitch attribute displays the status of the door based on the input from the supervisory input channel. It can be Opened , Closed , or Trouble . Like any supervisory input, the door switch can detect when someone is cutting or shorting the wires, or otherwise tampering with the door. The switch indicates the situation by showing a setting of Trouble . (All supervisory inputs can have the Trouble setting.)
6. Alarm Status —Displays the status of the most recent alarm for the door—Normal , RTN UnAcked , Acked , or Active .
7. State—You can set to Enabled or Disabled . If Enabled , the door allows access to all people who swipe a valid card through the card reader. If Disabled , the door does not allow anyone access to or from the area.
8. Before you set up any card readers, you complete the Door information by pressing the DETAILS1 button.
Door Status Indica tes Door Situation
www.PDF-Zoo.com
Areas and Doors
22-22 Infinity Controller Programmer’s Guide
Sett ing Doo r Channel Informa tionAs shown in Figure 5-10, after you press the DETAILS1 button, the Door Channel Information window opens. In this window, fill in the following additional door attributes:
1. Site Numbers —Each set of cards you purchase is encoded with a single site code. If you purchase multiple sets of cards for the same site and each has a different site code, you can set up the door to accept up to four different site codes. Type each acceptable site code in one of the four text boxes to the right. The following site codes are allowed for the given card type:
• Infinity 37—0 to 4095
• AC4+4 32—0 to 4095
• Wiegand 26—0 to 256
2. Door Channel —Set this to the door channel, 1, 2, or 3 based on whether you wired the door to the Door1 channel on the controller, the Door2 channel, or Output 3 (refer to Figure 22-11 for the location of each channel), or set it to 4 if you wired the door to the first expansion module door channel, 5 for the second. Set to 0 to have no door channel or to control the door through an Andover Controls Plain English program. (To have a Plain English program control the door, after you set the channel to 0, set up the door as a digital output. Assign it as output 1, 2, or 3 if wired to the ACX 700, as output 4 or 5 if on an expansion module.)
If the door lock relay is actuated when the door is locked, then Lock and Unlock will be backwards for the Door Lock setting. You resolve this situation by moving to Invert and pressing the space bar to display an X there. This action inverts Lock and Unlock .
Assign Door Channel
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-23
Figure 22-10. Door Channel Info rmation Window
3. Door Strike Seconds (DoorStrikeTime)—Set this to the number of seconds you want the door to remain open for when valid access occurs. It is automatically set to 10 seconds unless you change it. Keep the door strike time short for a door you do not have visually monitored.
4. Door Ajar Seconds (DoorAjarTime)—Set to the number of additional seconds you want to allow the door to be ajar after the time designated for the door strike has elapsed, from 0 to 255. Any time the door remains ajar longer than the time you set in this text box, the access control software automatically sets the door status to Door Ajar and sends a record of the action to the Event Log , where all access events are logged.
In a high-security situation, especially if you do not have a visual monitor for the door, you can have this attribute set an alarm based on the door being ajar too long, since
View Edit Connect Logout
Site Numbers
Details1
Door Channel
Door Strike Seconds
Alarm Channel
Record Valid Attempts ( )
Door Switch Channel
Exit Request Channel
Invert ( )
Door Ajar Seconds
Alarm Relay Seconds
Record Invalid Attempts ( )
Door Switch Type
Exit Request Type
CANCEL
DETAILS2
SAVE
DELETENOSeries
NOSeries
Door – Floor1 Front LabDoor
Allow Exit on Exit Request ( )
Set Number of Secon ds to Allo w Door to Be Ajar
www.PDF-Zoo.com
Areas and Doors
22-24 Infinity Controller Programmer’s Guide
someone could violate security in the few extra seconds. Automatically set to 20 seconds if you do not change it.
5. Alarm Channel —Suppose you want to have a light flash or a buzzer sound when the door is in alarm. You can wire a light or buzzer to a pulsing relay on your ACX 700 series controller—any of the following: Door 1 , Door 2 , Output 3 , or the door channels on the EMX 190 expansion modules. In this text box, indicate the location of the alarm channel, 1 to 5. If you do not want to have a relay for this purpose, set this text box to 0.
6. Alarm Relay Seconds (AlarmRelayTime)—Number of seconds alarm buzzer should remain on for when an alarm occurs.
7. Record Valid Attempts (RecordValHist)—You can choose to record the information each time a person enters through this door and the controller allows the person to enter—a valid entry. Once you move to Record Valid Attempts , press the space bar (the X appears) to toggle it on.
8. Record Invalid Attempts (RecordInValHist)—You can choose to record the information each time a person attempts to enter through this door and the controller does not allow the person to enter—an invalid entry attempt. Once you move to Record Invalid Attempts , press the space bar (the X appears) to toggle it on.
9. Door Switch Channel (DoorSwitchChan)—You wire the door switch to one of the supervisory “inputs” on the ACX 700 series controller. Set this attribute to the channel number of the supervisory input either on the ACX 700 from 1 through 8, or on its expansion modules, 9 and 10 for the first EMX 190 and 11 and 12 for the second. Or set this attribute to the channel number of the supervisory input on the ACX 780 from 1 through 32.
Figure 22-11 shows the location of each channel on the ACX 700.
Alarm Channel forBuzzer
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-25
Figure 22-11. Location of Channels on ACX 700 Controlle r
AUTO/OFF/ON
AUTO/OFF/ON
DOOR 2OUTPUT
KEYPAD 2 C3C2C1
DOOR 1OUTPUT
AUTO/OFF/ON
INFINET
OVERRIDE
C3C2C1
SHLD–
GNDO/CLKI/DATALED+5V
GNDO/CLKI/DATALED WIEGAND
ABA
RET8
RET4
IN8RET7IN7RET6IN6RET5IN5
IN4RET3IN3RET2IN2RET1
----
AC INPUT VOLTAGE SELECTION
TO230V
E6
P1
FROM24V
TOE6
P1
FROM
E2
TO
P1
FROM115V
ACX700
B1
3.6V
1.8AHr
LITHIUM
RD
TD
CPU
EXPANSIONPORT
SERVICEPORT
+
KEYPAD 1 SUPERVISORYINPUTS
EXT
TAMPER
SWITCH
RESET
+5V
WIEGAND
ABA
IN1
-INPUT+12VDC PWR
ON
-
+
USE COPPERCONDUCTORS
ONLY
F13A,250V
SLOW BLOW
NEU
HOT
GND
ACINPUT
E7 E5E4 E3 E4 E4 E5
E1 E1 E2
READER 1
READER 2
TAMPER
SWITCH 9
R1R2R3R4RET
RETR4R3R2R1
OUTPUT 3
OVERRIDE
+24VDC CLASS 11160 m A
KeypadChannels
DoorChannels
Super-visedInputChannels
CardReaderChannels
Door orAlarmChannel
www.PDF-Zoo.com
Areas and Doors
22-26 Infinity Controller Programmer’s Guide
Figure 22-12 shows the location of each channel on the EMX 190 expansion module.
Figure 22-12. Points on EMX 190 Expansion Modu le
Figure 22-13 shows the location of each channel on the ACX 780.
EMX190
OVERRIDE
DOOROUTPUT
NO CNC
ABA
CARD READER
AUTO
24VDC
CLASS
+5V
1/DATALED
0-CLKRTN
2
1BOARD
OVERRIDEOFF
ON
DOOR SWITCHRTN
EXIT REQUESTRTN
CARDREADER
INPUT
WIEGAND
II
Door Channel
as 11 and 12.
If you use these channels,on first module you identifythe channels as numbers 9and 10. On the secondmodule you identify them
On the first module you identify the Door channel as number 4, on the secondmodule you identify it as 5.
On first module,identify this channel
as 3, on second as 4.
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-27
F
igu
re 2
2-13. P
o
ints on
th
e
A
C
X
780
C
o
n
troller
AC
X78
0
IN5
RE
T
IN8
IN7
RE
T
RE
T
IN4
IN3
RE
T
IN2
IN1
RE
T
IN6
IN13
RE
T
IN16
IN15
RE
T
RE
T
IN12
IN11
RE
T
IN10
IN9
RE
T
IN14
IN2
1
RE
T
IN2
4
IN2
3
RE
T
RE
T
IN2
0
IN1
9
RE
T
IN1
8
IN1
7
RE
T
IN2
2
IN29
RE
T
IN32
IN31
RE
T
RE
T
IN28
IN27
RE
T
IN26
IN25
RE
T
IN30
INF
INE
T
+ — SH
LDR
D
TD
ER
RO
RN
O S
RV
CP
U+
5V+2
4V+1
5V-1
5V-5
VA
C P
WR
SE
RV
ICE
PO
RT
RE
SE
TO
VE
RR
IDE
OU
TP
UT
S
NC
C NO
1
NC
C NO
2
NC
C NO
3
NC
C NO
4
ON
OF
F
AU
TO
OU
TP
UT
1
ON
OF
F
AU
TO
OU
TP
UT
2
ON
OF
F
AU
TO
OU
TP
UT
3
ON
OF
F
AU
TO
OU
TP
UT
4
ON
OF
F
AU
TO
OU
TP
UT
5
ON
OF
F
AU
TO
OU
TP
UT
6
ON
OF
F
AU
TO
OU
TP
UT
7
ON
OF
F
AU
TO
OU
TP
UT
8
ON
OF
F
AU
TO
OU
TP
UT
9
D I S P L A Y
+ 5 V
L E D
1 / D A T A
0 / C L K
G N DR I
R 2R 3
R 4C 1
C 2C 3
R E T
RE
AD
ER
1 —
KE
YP
AD
1
FO
R D
ET
AIL
ED
INS
TA
LLA
TIO
N I
NS
TR
UC
TIO
NS
,R
EV
IEW
DO
CU
ME
NT
, 30-
3001
-392
, DA
TE
D 1
993
RE
AD
ER
2 —
KE
YP
AD
2
+ 5 V
L E D
1 / D A T A
0 / C L K
G N DR I
R 2R 3
R 4C 1
C 2C 3
R E T
RE
AD
ER
5 —
KE
YP
AD
5
RE
AD
ER
6 —
KE
YP
AD
6
+ 5 V
L E D
1 / D A T A
0 / C L K
G N DR I
R 2R 3
R 4C 1
C 2C 3
R E T
RE
AD
ER
3 —
KE
YP
AD
3
RE
AD
ER
4 —
KE
YP
AD
4
+ 5 V
L E D
1 / D A T A
0 / C L K
G N DR I
R 2R 3
R 4C 1
C 2C 3
R E T
RE
AD
ER
7 —
KE
YP
AD
7
RE
AD
ER
8 —
KE
YP
AD
8T
AM
PE
RS
WIT
CH
WA
RN
ING
HIG
H V
OLT
AG
E P
RE
SE
NT
DIS
CO
NN
EC
TP
OW
ER
PR
IOR
TO
SE
RV
ICIN
G
SC
AN
NC
C NO
5
NC
C NO
6
NC
C NO
7
NC
C NO
8
NC
C NO
9
Car
d R
eade
rs a
nd K
eypa
ds
Mot
ion
Doo
r S
witc
hes
Exi
t Req
uest
But
tons
Sup
ervi
sory
Inpu
ts
Doo
r Lo
cks
Gla
ss B
reak
Doo
r Lo
ckor
Buz
zer
for
Ala
rm
Tam
per
Sw
itch
Dec
tect
ors
Sen
sors
www.PDF-Zoo.com
Areas and Doors
22-28 Infinity Controller Programmer’s Guide
10. Door Switch Type —In this text box you indicate the type of switch the door switch is—press the SHOW LIST key and arrow to one of the following:
• NOSeries for a normally open switch with a resistor in series.
• NOParallel for a normally open switch with a resistor in parallel.
• NOSerPar for a normally open switch with a resistor in parallel that you have added a series resistor to. This option, of course, provides the highest security.
• NCSeries for a normally closed switch with a resistor in series.
• NCParallel for a normally open switch with a resistor in parallel.
• NCSerPar for a normally open switch with a resistor in parallel that you have added a series resistor to. This option, of course, provides the highest security.
When the selection you want is highlighted, press the EXECUTE key to select it.
11. Exit Request Channel (ExitRequestChan)—You wire the request-to-exit button or motion detector to one of the supervisory “inputs,” numbered 1 through 8 on the left side of the ACX 700 controller or to the supervised inputs on the EMX 190 expansion modules, 9 and 10 on the first module and 11 and 12 on the second. Set this attribute to the channel number of the input.
Indicate Type of Swit chfor Door
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-29
12. Exit Request Type —In this text box you indicate the type of switch the exit request switch is—press the SHOW LIST key and arrow to one of the following:
• NOSeries for a normally open switch with a resistor in series.
• NOParallel for a normally open switch with a resistor in parallel.
• NOSerPar for a normally open switch with a resistor in parallel that you have added a series resistor to. This option, of course, provides the highest security.
• NCSeries for a normally closed switch with a resistor in series.
• NCParallel for a normally open switch with a resistor in parallel.
• NCSerPar for a normally open switch with a resistor in parallel that you have added a series resistor to. This option, of course, provides the highest security.
When the selection you want is highlighted, press the EXECUTE key to select it.
13. Allow Exit on Exit Request (OpenOnExitReqst)—To allow any person to exit when he/she presses the exit request button, press the space bar to put an X in this check box.
14. If you have any doors wired to expansion modules, read the next subsection. If not, skip the procedure and press the DETAILS2 button. Then go on to the next major section.
Indicate the Type of Exit to Request Switch
www.PDF-Zoo.com
Areas and Doors
22-30 Infinity Controller Programmer’s Guide
Summary
To set up each door, in addition to the name and description, you can set the following attributes in the Main Door Setup window:
• Door Lock —Displays whether the door is Locked or Unlocked . You can change this setting.
• Door Status —Displays the current status of the door. The door can be ajar, forced open, set to manual override, tampered with (displays DoorFault ), or in a normal state.
• Door Switch —Displays whether the door is opened or closed. You can change this setting.
• Alarm Status —Displays the status of the most recent alarm that occurred for the door—normal, returned to normal but unacknowledged, acknowledged, or active.
• State—You can set to allow (Enable ) or disallow (Disable ) access through the door.
You then proceed to the Door Channel Information(Details1) window, where you indicate the following:
• Site Numbers —Set codes based on the numbers encoded in the access cards.
• Door Channel —Set to the number of the door lock channel. Then toggle on Invert if the relay for the door is actuated when the door is locked.
• Door Strike Seconds —Set to number of seconds door can remain open.
• Door Ajar Seconds —Set to number of additional seconds door can remain open before door is ajar.
• Alarm Channel —Set to channel number of buzzer.
Summary of DoorAttributes
Door ChannelInformation
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-31
• Alarm Relay Seconds —Set to number of seconds buzzer to buzz.
• Record Valid Attempts —Toggle on to record valid attempts at entry.
• Records Invalid Attempts —Toggle on to record invalid attempts at entry.
• Door Switch Channel —Set to number of the door switch channel.
• Door Switch Type —Set to type of door switch.
• Exit Request Channel —Set to number exit request sensor channel.
• Exit Request Type —Set to type of exit request switch.
Door ChannelInfor matio n
www.PDF-Zoo.com
Areas and Doors
22-32 Infinity Controller Programmer’s Guide
Rules fo r Expansion Module Inputs /Outputson ACX 700 Controlle rs
If you have no expansion modules, skip these rules and pro-ceed with the next step.
When you assign output channels on EMX 190 expansion modules on the ACX 700 controller, abide by the following rules:
• Door Output Channel—Assign as door or alarm channel 4 on first module, 5 on second module.
• Card Reader Channel—Assign as entry or exit reader channel 3 on first module, 4 on second.
• Supervisory Input Channels—Assign as card reader or supervisory inputs 9 and 10 on first module, 11 and 12 on second module.
The third output expansion module can have two channels; you must assign each only as output points. Refer to the chap-ter on points for how to set up the points. The types you can have for these channels include Voltage , Current , Digital , HiResVoltage , HiResCurrent , and Pneumatic .
Assign ExpansionModule Output Channels
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-33
When you assign input channels on EMX 190expansion mod-ules on the ACX 700 controller, abide by the following rules:
• The first four expansion inputs are always those on the EMX 190 expansion modules and you should set them up as part of a door, channels 9 and 10 on the first module, 11 and 12 on the second. You use these channels for door switches, motion detectors, glassbreak sensors, request-to-exit buttons, and any similar sensors.
• If you have input modules, you must set up the input channels on them as either counter or digital input points, channels 13 to 20 on the first, channels 21 through 28 on the second. Refer to the chapter on points for how to set up input points.
• If you have a EMX 170 module, you must set it up as a temperature input point and set it to channel number 29. Refer to the chapter on points for how to set up the input point.
Figure 22-14 illustrates a full chain of expansion modules and gives the object types and numbers you can assign to each channel.
Assign Expans ionModule Input Channels
www.PDF-Zoo.com
Areas and Doors
22-34 Infinity Controller Programmer’s Guide
Figure 22-14. Object Type and Channel Numbers to Assign Expans ion Modu le Channels
15. When you are ready to proceed, press the NEXT ATTRIBUTE key until the cursor is on the DETAILS2 button and then press the EXECUTE key to proceed.
Complete ExpansionModule Chain
Model700
190—Board 1
190—Board 2
160—Board 1
160—Board 2
170—1 Input
150—Board 1
ExternalPowerSupply
1 Output, 2 Inputs
1 Output, 2 Inputs
2 Outputs
8 Digital Inputs
8 Digital Inputs
Door or Alarm Channel 4
Door or Alarm Channel 5Supervisory Inputs 11 & 12
Output 6—Voltage
Inputs 13–20—Digital or Counter
Inputs 21–28—Digital or Counter
Input 29—Temperature
You assign these channelnumbers very carefully
Output 7—Voltage
Supervisory Inputs 9 & 10
Instead of a 150, you can putany output module, exceptanother 190, for a total oftwo outputs after any 190s.
Card Reader Channel 3
Card Reader Channel 4
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-35
Summary
Specific rules exist for setting up the inputs and outputs on EMX 190 expansion modules.
Table 22-1 gives the rules for channel numbers on output ex-pansion modules.
Table 22-2 gives the rules for channel numbers on input ex-pansion modules.
Table 22-1. Rules for Assigning Channels on Out-pu t Expansion Modu les
Type of OutputChannel(s) on First Module
Channel(s) on Second Module
Door 4 5
Card Reader 3 4
Supervisory Inputs 9 and10 11 and 12
Voltage 6 7
Current 6 7
Digital 6 7
HiResVoltage 6 7
HiResCurrent 6 7
Pneumatic 6 7
Table 22-2. Rules for Assig ning Channels on Input Expansion Modu les
Type of InputChannel(s) on First Module
Channel(s) on Second Module
Digital or Counter 13 – 20 21 – 28
Temperature Input 29 (not allowed)
Follo w Ru les to Number Expansi on Channels
www.PDF-Zoo.com
Areas and Doors
22-36 Infinity Controller Programmer’s Guide
Sett ing Card FormatsOnce you press the DETAILS2 button, the Card Formats window opens. Even if you are using only keypads for access control, you set up some information in this window.
Figure 22-15 shows the Cards Formats (Details2) window. In this window, you fill in the following additional door attributes:
1. Door Schedule —If you have set up a schedule (on the SX 8000 workstation) of when to allow access through the door, you can type the full path to and name of the schedule’s occupancy point in this text box.
Remember that the occupancy point is always a numeric point. If you have not set up schedules or created occupan-cy points, you can skip this text box and return here after you have set up schedules.
Figure 22-15. Card Formats Window
Card Formats Tell Typesof Access Cards
View Edit Connect Logout
Door Schedule
General Code
CANCEL
SAVE
0
Details 2
Wiegand (X) ABA ( )
Card Format
AC4Plus432( )
Wiegand26
Infinity37( ) ( )
Door – Floor1 Front LabDoor
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-37
2. General Code —If you want everyone who has access to the site to type the same code into the keypad, you can enter this general code here. The general code can be from 0 to 65535.
3. Card Format —Choose the one of the two major card formats that applies to your card set, Wiegand or ABA .
Wiegand Formats —If you have a Wiegand card reader, choose the card format to the right that matches your card set. You may have Infinity 37-bit cards (Infinity37 ), AC 4+4 32-bit cards (you may have these if you have been using an AC 4+4 controller prior to purchasing the ACX 700 or 780) (AC4Plus432 ), or Wiegand 26-bit cards (Wiegand26 ).
4. ABA Formats —If you have an ABA card reader, choose the card format that matches your card set, ABA1 or ABA2 .
5. When you have finished responding to these details, you are ready to set up the entry card reader. Press the NEXTATTRIBUTE key until the cursor lands on the SAVE but-ton. Then press the EXECUTE key to save the information.
6. Press SAVE in each window until you see the Main Door Setup window again.
7. When you are ready to proceed, press the ENTRY READER button to set up the entry card reader and/or keypad for the door.
Summary
You set the card formats the card reader can read in the Card Formats (Details2) window.
If you have a keypad, you set the general code for the keypad in this window.
Choose the Card Format
Proceed to the EntryReader Window
www.PDF-Zoo.com
Areas and Doors
22-38 Infinity Controller Programmer’s Guide
Sett ing Up t he Entry Ca rd Reader or KeypadEach door can have any combination of entry card reader, exit card reader, entry keypad, and exit keypad. You can choose to have entry reader and keypad only, rather than both entry and exit ones. Or you can choose to have only the card reader or only the keypad for either entry or egress.
To set up the card reader or keypad, you begin by opening the Main Door Setup window. You then press the ENTRY READER button.
Figure 22-16 shows the window that appears. In this window you set up the entry card reader and keypad as follows (remember these are still attributes of the door):
1. Reader Channel (EntryChannel or ExitChannel)—Type the number of the channel you wired the reader for this door to. Reader1 is channel 1, Reader2 channel 2, the first reader on an expansion module is channel 3, and the second reader on an expansion module channel 4. Type 0 if you have no entry card reader for this door.
2. Keypad Channel (EntryKyPdChan or ExitKyPdChan)—Type 1 if you wired the keypad for this door to Keypad1 or 2 if you wired it to Keypad2 . Set to 0 if you have no entry keypad for this door.
3. Current Mode (EntryMode or ExitMode)—Displays the current mode that the door controller (ACX 700 series controller) is running under:
• Normal means the ACX 700 series controller is working normally.
• NoComm means that communication between the access server and the ACX 700 series controller has failed.
Set Up the Card Readeror Keypad
Find Out Current Modeof Contro ller
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-39
• No Database means that the access server or the ACX 700 series controller that has the doors on it has been reset or has otherwise lost the database to check access card numbers and PINs against.
Figure 22-16. Entry Reader Window
4. Access Validation —In this box you move to each selection and toggle it on if you want to allow access when the condition exists:
• Normal (EntryNormMode)—When the ACX 700 series controller is functioning normally.
• Comm Fail (EntryNoCommMode)—When communication between the access server and the ACX 700 series controller fails.
• No Database (EntryNoDataMode)—When the access server or the ACX 700 series controller that stores the doors has been reset or has otherwise lost the database, for instance, during a reload to the controller. When this
View Edit Connect Logout
Reader Channel Keypad Channel2
General Code
Comm Fail
0
Schedule
Valid Card( )
Valid PIN
( ) Valid SiteNormal CANCEL
DETAILS1
SAVE
( ) ( ) ( ) ( )
No Database
( ) ( ) ( ) ( )
( )
( )
Access Validation
Current Mode Normal
Door – Floor1 Front LabDoor
Check fo r Valid Personal Ident ifica tio n Number
www.PDF-Zoo.com
Areas and Doors
22-40 Infinity Controller Programmer’s Guide
occurs, the controller cannot check access card numbers and PINs against the database.
In the first two cases, Normal and Comm Fail , you select as many of the following as apply:
• Valid Site —Toggle on to check the access card for a valid site code, one acceptable at this site.
• Valid Card —Toggle on to check the access card for a valid card number.
• Valid PIN —Toggle on to check the digits the person types on the keypad to see if they form a valid personal identification number.
• General Code —Toggle on to check the digits the person types on the keypad to see if they form a valid general code.
• Schedule —Toggle on to check the schedule to see if the system should allow access at the present time.
In the third case, No Database , you can choose from two options—Valid Site and General Code . Since the controller stores the site and general codes so that they cannot be erased, the control system can still validate a site code or general code under these conditions.
Figure 22-17 shows, for example, the choices toggled on to check for a valid card number and schedule under normal conditions. Alternatively, the figure shows checking for a valid site code and valid general code if communication fails. If the database is erased by someone resetting the controller, in this case, the figure shows that the controller then checks for a valid site code only.
Check f or Valid PersonalIdent ific atio n Number
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-41
Figure 22-17. Entry Reader Window
5. Press the DETAILS1 button to proceed to the Entry Reader Details1 window.
Summary
To set up the card reader or keypad you use to enter each door, you assign the following attributes in the Entry Reader window:
• Reader Channel —Set to number of reader channel.
• Keypad Channel —Set to number of keypad channel.
• Current Mode —Displays the current mode.
• Access Validation —Select the information you want the controller to check whenever a person swipes a card through a reader or punches a code on a keypad.
View Edit Connect Logout
Reader Channel Keypad Channel2
General Code
Comm Fail
0
Schedule
Door – Floor1 Front LabDoor
Valid Card( )
Valid PIN
(X) Valid SiteNormal CANCEL
DETAILS1
SAVE
(X) ( ) ( ) (X)
No Database
( ) ( ) (X) ( )
( )
(X)
Access Validation
Current Mode Normal
Entry Reader Details1
Proceed to Entry Reader Details W indow
www.PDF-Zoo.com
Areas and Doors
22-42 Infinity Controller Programmer’s Guide
Sett ing Entry Card Reader or Keypad O ptionsFigure 22-18 shows the window that appears when you press the DETAILS1 button. You now respond to the card reader details as follows:
1. Area (EntryArea or ExitArea)—Type the name of the area the door accesses. Set to the name of the area. Include with it the path with the name of the Infinity CX 9000 controller (and the ACX 700 series controller if applicable).
2. Department Point —Each person you later set up has a department number. Type the full path to a numeric point that should contain the department number of the last per-son who walked through the door. The point automatically retrieves the department number from the person whoenters. You can use this point to control HVAC, lighting, or another process based on the person’s department. For instance, if someone from the Engineering department en-ters the area, you may want to turn on the lights. You may decide not to turn on the lights if a person from another de-partment enters the Engineering area.
3. Zone Number —Type a number, up to 65535, that indicates the zone this card reader controls access to. The zone number must be different for the entry card reader and the exit card reader. Later, when a person swipes a card through the reader, the access control system sets the point you assign as the person’s Zone Point to the number you assigned in this text box. Set this attribute to 0 to indicate you did not assign a zone number.
4. AntiPassBack Minutes (EntryAntiPassTime or ExitAntiPassTime)—After a person enters an area, the individual should not be allowed to enter again within a short duration of time. If the “same person” appears to
Set More Entry CardReader/Keypad Optio ns
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-43
attempt access within, say, 2 minutes, the person may have allowed someone else to use the same access card by passing it back through the door while the door is open. Or the person may have allowed someone else to use his/her individual PIN. In this text box, set the number of minutes you want the card or PIN to be invalid for immediately after the system detects it has been used to enter an area.
Figure 22-18. Entry Reader Options Window
5. Reader Options —In this box, move to the options you want to select and press the space bar (put an X in the check box) for the conditions you want the control system to allow access under:
• Allow Entry Upon AntiPassback Violation (ExitAntiPassTime)—If the individual attempts to enter the area again within the number of minutes you set under AntiPassBack Minutes , depending on how high-security the area is, you may want to simply allow
View Edit Connect Logout
Area
Department Point
Floor1 Lab
Zone Number
PIN Duress
0
Reverse Card Duress
Entry Reader –Details1
Entry/Egress
(X)
Allow Entry Upon Entry/Egress Violation
Allow Entry Upon AntiPassback Violation
(X)
( )
( )
( )
( )
Reader Options
Anti-Passback Minutes 60
Allow Entry Upon Reverse Card
CANCEL
DETAILS2
SAVE
Door – Floor1 Front LabDoor
Decide to Allo w Entryon AntiPassB ack
www.PDF-Zoo.com
Areas and Doors
22-44 Infinity Controller Programmer’s Guide
the individual access anyway. Click in this check box to allow access.
• Entry/Egress (EntryEntEgr)—Toggle on this check box to indicate you want to check for entry/egress violations. What is an entry/egress violation?
Figure 22-19 shows the entry/egress concept. Notice that to get into the Lab , you must go through the Lobby area. If you do not swipe to get into the lobby, but sud-denly you swipe your card to get into the Lab (from Outside ), that is an entry/egress violation.
Keeping track of entry/egress violations prevents an individual from entering the secured area by slipping in behind someone else—tailgating.
CautionTo detect entry/egress violations, you must have an exit card reader defined for the door even if one does not exist. To de-fine a card reader that does not exist, you set the channel for the exit reader to 0 and fill in all the other pertinent informa-tion just as you have done for the entry card reader.
After you have completed the entry card reader, you proceed to the exit card reader.
Check f or Entry/EgressViolations
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-45
Figure 22-19. Valid and Invalid Entry/Egress Routes
• Allow Entry Upon Entry/Egress Violation (EntryEntrEntEgr)—If the person violates entry/egress (described above) you may want to allow access anyway. Toggle on this check box to allow access.
• PIN Duress (EntryPINDuress)—If you want, you can have a person who is being forced into the building by an unauthorized individual indicate that situation by typing the PIN or general code on the keypad, then pressing the star (*) key, instead of the pound (#) sign. Toggle on this check box to allow entry when the person indicates they are under duress. (Then be sure to set an alarm as well.)
Lobby
Lab
Outside
Valid Entry/Egress
Invalid Entry/EgressRoute
Route
Decide to Allo w Access under PIN Duress
www.PDF-Zoo.com
Areas and Doors
22-46 Infinity Controller Programmer’s Guide
• Reverse Card Duress (EntryEntrRvrsCrd)—If you want, you can have a person who is being forced into the building (or area) by an unauthorized individual indicate that situation by swiping the access card so the front of the card faces the building rather than facing the away from the building. Toggle on this check box to allow the card reader to read the card when it is swiped in reverse.
• Allow Entry Upon Reverse Card (ExitEntrRvrsCrd)—Toggle on this check box to allow entry when the person swipes the access card so it is facing in the reverse direction. This action may or may not indicate duress, based on the selection above it.
6. Press the DETAILS2 button to see the status of the entry reader or keypad.
Allo w Access When CardIs Reversed
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-47
Summary
In the Entry Reader Options window, set up the following:
• Area—Set to the name of the area. Include the full path.
• Department Point —Set to point that contains depart-ment number of the last person to walk through the door.
• Zone Number —Set to number of zone this door controls access to.
• AntiPassback Minutes —Set to number of minutes a person’s card remains invalid immediately after the person goes through this door.
• Reader Options —Select the conditions you want the control system to allow access under.
Set Up the Entry Reader Optio ns
www.PDF-Zoo.com
Areas and Doors
22-48 Infinity Controller Programmer’s Guide
Finding Out Entry Readeror Ke ypad StatusFigure 22-20 shows the Entry Reader Status window that appears when you press the DETAILS2 button in the Entry Reader Options window.
Figure 22-20. Entry Reader Status Window
You now see a series of details about the area accessed through this door. Most of these are blank right now, unless your system is already up and running:
1. Last Person Entered (LastPersonEnterd or LastPersonExited)—Displays the name of the last person who entered through the door.
2. Time Entered (TimeEntered or TimeExited)—Displays the time the last person entered through the door.
View Edit Connect Logout
Last Person Entered
Time Entered
Area Entered
Entry Count
EXITLast Person’s Dept
1-14-93 4:02:16 pm
4
Entry Reader – Details2
Floor1 Lab
8
Last Invalid Person RMSingleton
Last Invalid Time 1-1-93 10:21:42 am
PLansing
Check Status of A rea
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-49
3. Area Entered —Displays the name of the area entered via this door.
4. Last Person’s Dept —Displays the department code of the last person to enter through the door.
5. Entry Count (EntryCount or ExitCount)—Displays the total number of people who have entered through the door at the current time. For the exit card reader or keypad, the entry count totals the number of people that have entered the adjacent area through the door.
6. Last Invalid Person (LastInvalidEntry or LastInvalidExit)—Displays the name of the person who last attempted to enter the area but was not allowed to enter.
7. Last Invalid Time —Displays the time that the last invalid attempt to enter through the door occurred.
8. Press the EXIT button to return to the Entry Reader Options window.
9. Press the SAVE button to return to the Main Door Setup window.
If you have an exit card reader or keypad, proceed to the next section.
If you do not have an exit card reader or keypad, you have fin-ished setting up this door. You can repeat the door procedures for each door or use SAVE AS to create multiple doors and modify each one.
Find Out Last Person Who Entered Area
www.PDF-Zoo.com
Areas and Doors
22-50 Infinity Controller Programmer’s Guide
Summary
To find out the status of the card reader or keypad used to en-ter an area, you open the Entry Reader Status (Details2) window and see the following:
• Last Person Entered —Displays the name of the last person who entered.
• Time Entered —Displays the date and time the last person entered.
• Area Entered —Displays the area the last person entered.
• Last Person’s Department —Displays the department of the last person to enter.
• Entry Count —Displays a total of the number of people who have entered the area.
• Last Invalid Person —Displays the name of the last person who attempted to enter but was not allowed access.
• Last Invalid Time —Displays the time that the last person attempted to enter who was not allowed access.
Display Door Status
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-51
Setti ng Up the Exit Card Reader or Keypad
CautionTo detect entry/egress violations, you must have an exit card reader defined for the door even if one does not exist. To define a card reader that does not exist, you set the channel for the exit reader to 0 and fill in all the other pertinent information just as you have done for the entry card reader.
To set up the exit card reader or keypad, return to the Main Door Setup window, press the EXIT READER button to proceed to the Exit Reader window and set up the same in-formation on the exit reader that you set up on the entry reader. (Return to the section called Setting Up the Entry Card Reader or Keypad.)
You then proceed to the Exit Reader Options and Exit Reader Status windows, just as you did for the entry read-er. When you have completed the exit card reader or keypad information, press the SAVE button until you return to the Main Door Setup window.
You can repeat the door procedures for each door or use SAVE AS to create multiple doors and modify each one.
When you have finished setting up all doors, you are ready to proceed to set up people—each called a “person.”
Sett ing Up the Exit Card Reader or Keypad
www.PDF-Zoo.com
Areas and Doors
22-52 Infinity Controller Programmer’s Guide
Summary
To set up the card reader or keypad used to exit an area, you follow the same procedures as you followed for the entry card reader or keypad.
Now that you have completed setting up areas and doors, you are ready to learn about points. Proceed to the next chapter to learn about points.
www.PDF-Zoo.com
Areas and Doors
Infinity Controller Programmer’s Guide 22-53
Setting Up GlassB reak Sensors an d Other Supervi sed Input sIf you want to set up a glassbreak sensor or other supervised input and control it through a Andover Controls Plain English program, go to Chapter 4 and follow the instructions there for setting the sensor up as a point. You can set up any supervised input as a point even if you have already set it up as part of the door.
Set Up GlassB reakSenso rs as Points
www.PDF-Zoo.com
Areas and Doors
22-54 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Chapter 23
Sett ing Up Personsfor Access Cont rol
This chapter tells you how to set up people or “persons.” A “person” is someone who accesses areas when you are using Infinity CX as an access control system.
• Setting Up Persons Who Can Access Each Area
• Setting Person Attributes
• Entering Person’s Card Information
• Completing Employee Information about Person
• Setting Areas the Person Can Access
• Adding More Employee Information
• Entering Personal Information
www.PDF-Zoo.com
Personnel
23-2 Infinity Controller Programmer’s Guide
Sett ing Up Persons Who Can Access Each AreaTo tell the access control system who can enter each area, you have two ways to identify a person:
• By a card number encoded into an access card.
• By a personal identification number (PIN) that you have the person type on a keypad.
To assign a card number or PIN to a particular individual, you tell the access control system about the person as follows:
1. Go to the Main Menu bar and select Edit , then Person .
Figure 23-1 shows the menu.
Figure 23-1. Selec ting Edit Persons
In a moment, the Open a Person window appears.
Figure 23-2 shows the window.
2. Verify the name of the controller from the network map. This controller should be the access server you set up earlier. If the correct name does not appear in the Controller text box, press the DELETE LINE/TEXT key
Tell Cont rol Syste mabout Each Person
UsersPointsFilesCommPortsControllerInfinet ControllerSystem Date & Time
View
System VariablesPersonsAreasDoors
Edit Connect Logout
www.PDF-Zoo.com
Personnel
Infinity Controller Programmer’s Guide 23-3
to erase the name. Then type the correct one. Or use the SHOW LIST key to select another name.
Figure 23-2. Open a Person Window
3. If you are using the ACX 700 series controller as the access server, verify the name of the Infinet controller from your network map (otherwise, skip this text box). If the correct name does not appear in the InfinetCtlr text box, press the DELETE LINE/TEXT key to erase the name. Then type the correct one. Or use the SHOW LIST key to select another name.
4. Type a name to stand for the person item in the Name text box. It does not have to be the person’s name, but a name you refer to the “person item” by. (You fill in the individual’s first and last names later.) The person item name can be up to 16 characters, including periods and underscores, but cannot contain spaces. If you have only a few people, you may want to use the person’s initials. Or you may want to use the first five letters of the last name followed by the first initial. The decision is yours. When you are ready, press the EXECUTE key to proceed.
The Person window opens. To fill in the text boxes in that window, proceed to the next section.
Controller
Open a Person
InfinetCtlr
View Edit Connect Logout
Name
DELETE LINE/TEXT Erases Entire Name
www.PDF-Zoo.com
Personnel
23-4 Infinity Controller Programmer’s Guide
Sett ing Person Att ribut esFigure 23-3 shows the Person window that appears.
Figure 23-3. Person Window
You set the following attributes for each person:
1. Description —(Optional.) You can type a description of the person, up to 32 characters, including spaces. The description is optional and does not affect the controller.
2. Expiration Date —Set to the date and time the person is no longer allowed access, if known. You enter this information if, for instance, an employee leaves the company.
3. Department Number (DepartmentCode)—The number assigned to the person’s department. For instance, if Engineering is Department 2, then you enter 2 here. You
View Edit Connect Logout
Name
Expiration Date
JJones
Department Number
Time of EntryCARD INFO
SAVE AS
CANCEL
SAVE
Zone Point
DELETE
10-23-93 8:00:00 am
PresentArea
Person – Floor1 JJones
Enabled(X) Disabled( )
State
3
1-10-93 9:46:04 am
Current Area
Entry Egress ( ) Duress ( )
Set Person Attri but es
www.PDF-Zoo.com
Personnel
Infinity Controller Programmer’s Guide 23-5
can assign any number from 0 to 65535. When the person swipes the card assigned through the card reader or enters an access code on a keypad, the access control software sets the LastDeptCode attribute of the door to this number.
4. Zone Point (LastZonePoint)—Type the full path to a numeric point that stores a number that indicates the last door the person accessed, and whether the person entered or exited through the door. Remember, you assigned a Zone Number to a door’s entry card reader and another Zone Number to a door’s exit card reader.
Whenever the person enters an area through a particular door, the control system sets this point to the door’s entry card Zone Number . Whenever the person exits an area through a particular door, the control system sets this point to the door’s exit card reader Zone Number .
You can use the zone point to carry out other forms of control, for instance, turning on the lights or starting the morning warmup.
5. Current Area (Value)—Right now, no area displays. Once the person begins swiping a card or typing an access code on a keypad, the name of the area the person is in displays here. If you go to the Command window and type
PR JJONES
The controller prints the name of the area the person is located in.
6. Time of Entry (TimeEntered)—Right now, no time or date displays. Once the person begins swiping a card, the time and date that the person entered the area displays.
7. Entry Egress —(Optional.) This attribute displays whether or not the person’s last entry was an entry/egress violation. Displays X if it was.
Set Entry and Egress
www.PDF-Zoo.com
Personnel
23-6 Infinity Controller Programmer’s Guide
8. Duress —(Optional.) This attribute displays whether or not the person’s last entry was under duress (being forced into the area by an unauthorized person). Displays X if it was. The person indicates duress through a card swipe by swiping the card so the front of it faces the wall rather than facing away from the wall. To indicate duress on a keypad, the person can type the usual PIN or general code and press the asterisk (*) instead of the pound sign (#) to complete the code.
9. State—(Optional.) If you want to allow the person to access all or any areas, move to Enabled and press the space bar so that the X appears. If you want to temporarily stop the person from entering all areas, move to Disabled and press the space bar. Be sure to select Enabled for a new person.
10. Press the CARD INFO button to proceed to the Card Information window.
www.PDF-Zoo.com
Personnel
Infinity Controller Programmer’s Guide 23-7
Summary
You set up the following attributes for each person who you give an access card or keypad code:
• Name—Name of “person item,” not of person.
• Description —Description of the person.
• Expiration Date —Date and time the person is no longer allowed access, if known.
• Department Number —Number you assigned to the person’s department.
• Zone Point —Point that stores a number that indicates the last door the person accessed, and whether the person entered or exited through the door.
• State—To allow the person to access all or any areas, set to Enabled . To temporarily stop the person from entering all areas, set to Disabled .
The controller sets the following attributes for each person once the person begins swiping a card or punching a code:
• CurrentArea —The controller prints the name of the area the person is located in.
• Time of Entry —Once the person begins swiping a card, displays the time and date that the person entered the area.
• Entry Egress —Displays X if the person’s last entry was an entry/egress violation.
• Duress —Displays X if the person’s last entry was under duress (being forced into area by an unauthorized person).
www.PDF-Zoo.com
Personnel
23-8 Infinity Controller Programmer’s Guide
Entering Person’s Car d Informa tionFigure 23-4 shows the Card Information window.
Figure 23-4. Card Information Window
In this window, you enter the card type, card number, site code, PIN, and access details of the individual, as follows:
1. Card Type —You see a list of possible card types.Select the type of card this person holds—Infinity37 , AC4Plus432 , Wiegand26 , ABA1 , or ABA2 . Select PINOnly where no card reader is involved, but a keypad instead.
2. Card Number —Type the person’s card number as encoded on the person’s access card. Do not exceed the
View Edit Connect Logout
PIN
DETAILS1
CANCEL
DELETE
SAVE
Card Number
AREAS
Person – Floor1 JJones
Infinity37(X) AC4Plus432( )
Card Type
Site Code
Card Information
( )( )( )( )
Wiegand26ABA1ABA2PINOnly
Indicate Card Type, CardNumber, Site Code, PIN
www.PDF-Zoo.com
Personnel
Infinity Controller Programmer’s Guide 23-9
highest card number. The highest card number is based on the card type:
• Infinity 37—0 to 524287
• AC4+4 32—0 to 16383
• Wiegand 26—0 to 65535
3. Site Code —Type the person’s site code. This number is encoded in the person’s access card and is the same for a set of cards. The numbers available on the different card types are as follows:
• Infinity 37—0 to 4095
• AC4+4 32—0 to 4095
• Wiegand 26—0 to 256
4. PIN—Type the person’s personal identification number (PIN). It should be unique to the individual and a number from 0 to 65535.
5. To complete the card information, press the DETAILS1 button and you see the Details1 window.
Summary
You tell the controller the card information of the person by responding to the following attributes:
• Card Type —The type of card this person holds or PINOnly where you have a keypad only.
• Card Number —Card number encoded in the person’s card.
• Site Code —Site code encoded in the person’s card.
• PIN—Personal identification number for a keypad.
Indicate PersonalIdentifica tion Number
www.PDF-Zoo.com
Personnel
23-10 Infinity Controller Programmer’s Guide
Complet ing Employee Informat ion about PersonFigure 23-5 shows the Details1 window that appears after you press the DETAILS1 button in the Employee Information window.
Figure 23-5. Empl oyee Information Window
In the Details1 window, you set the remaining information about the card as follows:
1. Last Name —(Optional.) Type up to 32 characters, including spaces, for the person’s last name.
2. First Name —(Optional.) Type up to 16 characters, including spaces, for the person’s first name.
3. Middle Initial —(Optional.) Type the person’s middle initial, if applicable.
View Edit Connect Logout
AREAS
CANCEL
DETAILS2
SAVE
Person – Floor1 JJones
Details 1
Last Name
First Name
Jones
SSN
Activation Date
Department
Jessica
Engineering
00-000-0000
4-10-93 9:00:00 am
Employee Number
Office Location
Middle Initial
Office Phone
www.PDF-Zoo.com
Personnel
Infinity Controller Programmer’s Guide 23-11
4. SSN (SocSecNum)—(Optional.) Type the person’s social security number.
5. Department —(Optional.) Type up to 32 characters, including letters and numbers, that indicate the person’s department name.
6. Employee Number —(Optional.) Type up to 16 characters, including both letters and numbers, indicating the employee number of the person.
7. Activation Date —(Optional.) Set to the date and time you want the access system to begin allowing the person to enter areas. Give either today’s date or the date you expect the person to begin entering areas.
8. Office Location —(Optional.) Type up to 16 characters, including both letters and numbers, indicating the location of the person’s office.
9. Office Phone (WorkPhone)—(Optional.) Type up to 40 characters, including letters and numbers, indicating the person’s office phone number.
10. Press the AREAS button to proceed to the Current Areas window.
Summary
You give employee information in the following attributes:
• Last Name, First Name, Middle Initial —Person’s real name rather than “person item” name.
• SSN—Social Security number.
• Department , Employee Number .
• Activation Date —Date you enter person in controller.
• Office Location and Office Phone .
www.PDF-Zoo.com
Personnel
23-12 Infinity Controller Programmer’s Guide
Sett ing Areas the Perso n Can AccessFigure 23-6 shows the Current Areas window.
In Current Areas window, you indicate the areas the person has access to. The window is empty at first and the cursor is in the upper left corner. Proceed to put area names in this win-dow as follows:
1. Press the INSERT TEXT key (refer to your keystroke reference card for the correct keystrokes).
Figure 23-6. Current Areas Window
Figure 23-7 shows the a list of available areas that opens.
Set Areas Person CanAccess
View Edit Connect Logout
Person – Floor1 JJones
Areas
Current Areas
Use <INSERT> to Add an Area
Use <DELETE> to Delete an AreaUse <ENTER> to Edit an Area
Use <EXIT> to Exit Form
www.PDF-Zoo.com
Personnel
Infinity Controller Programmer’s Guide 23-13
Figure 23-7. List of Avai lab le Areas
The cursor is automatically on the first area in the list.
2. To move the cursor to another area, press the down arrow key until it lands on the area you want.
3. To select the area the cursor is on, press the EXECUTE key.
In a moment, the area appears in the Current Areas list. If you add more than one area, the next one you add always appears at the top of the Current Areas list.
Notice that the areas that appear in the list have two pieces of information to the right of them—TRUE or FALSE and ENABLED or DISABLED.
View Edit Connect Logout
Person – Floor1 JJones
Areas
Current Areas
Use <INSERT> to Add an Area
Use <DELETE> to Delete an AreaUse <ENTER> to Edit an Area
Use <EXIT> to Exit Form
Areas ab1Lab2Lab3LobbyFrontOfficeEngOfficesAdminOfficesPresOfficeVeepOffice
L
Use downarrow to move down list.
www.PDF-Zoo.com
Personnel
23-14 Infinity Controller Programmer’s Guide
Figure 23-8 shows the areas the person called JJones can access. Notice that the areas are all FALSE and ENABLED. To find out what these settings mean, put the cursor on the area you want more information about and press the EXECUTE key.
Figure 23-8. Current Areas Window
In a moment the Area Detail window appears.
Figure 23-9 shows the window. Notice that the area name appears to the right of Area .
4. Schedule —(Optional.) Type the full path to the occupancy point of the schedule you want to have control this person’s access to the area.
View Edit Connect Logout
Person – Floor1 JJones
Areas
Current Areas
Use <INSERT> to Add an Area
Use <DELETE> to Delete an AreaUse <ENTER> to Edit an Area
Use <EXIT> to Exit Form
ab1Lab2Lab3LobbyFrontOfficeEngOffices
L FalseFalseFalseFalseFalseFalse
EnabledEnabledEnabledEnabledEnabledEnabled
www.PDF-Zoo.com
Personnel
Infinity Controller Programmer’s Guide 23-15
Figure 23-9. Area Detail Window
5. Load to ACX —(Optional.) If you have an Infinity CX 9000 as an access server, in this box you indicate where the person is stored.
If this person is very important, works on this floor, or for any reason should have immediate access to the area, store a copy of the person on the ACX 700 series controller by putting the X next to Load . If the person is seldom in the area or can wait for the ACX 700 series controller to retrieve names and access codes from the database on an Infinity CX 9000 or an SX 8000, store the person on the access server unit by putting the X next to Don’t Load .
If you are using the ACX 700 series controller as its own access server, you can ignore this attribute.
6. State—(Optional.) If you want to allow the person access to the area immediately, put the X next to Enabled . If you
View Edit Connect Logout
Person – Floor1 JJones
Area Detail
CANCEL
SAVE
Area
Schedule
Floor1 Lab1
Load(X) Don’t Load( )
Load to ACX
Enabled(X) Disabled( )
State
Indicate Where to Store the Person
www.PDF-Zoo.com
Personnel
23-16 Infinity Controller Programmer’s Guide
want to temporarily stop the person from entering the area, put the X next to Disabled .
7. Press the SAVE button to add the changes and alter the person’s access to the area. The Area Detail window closes and you see the changes to the area in the Current Areas window.
8. If you decide you want to change one of the areas from Enabled to Disabled or from Load to Don’t Load under Load to ACX , press the INSERT key again and repeat the above steps.
9. If you would like to deny the person access to any areas in the list, proceed to the next subsection (below).
10. When you have added all the areas the person should have access to, to close the area list, press the CANCEL WINDOW key. You return to the Details1 window.
Removing A ccess to an Area
While in the Person’s Areas window, you can change the person’s access to an area by removing it from the areas list as follows:
1. To remove an area from those the person can access, press the appropriate arrow key until the cursor lands on the area name.
2. Press the DELETE key to delete the area from the list.
Edit an Area after YouHave Added It to List
www.PDF-Zoo.com
Personnel
Infinity Controller Programmer’s Guide 23-17
Summary
In the Current Areas window, you set up a list of the areas that the person can access as follows:
• Press the INSERT TEXT key to insert an area in the list.
• When the list of Available Areas appears, select one with the arrow key and press EXECUTE to put it in the list.
In the Area Detail window, you can set the following:
• To allow the person access based on a schedule, type the name of the schedule occupancy point in the Schedule text box.
• To copy the person onto the ACX 700 series controller, you set the Copy to ACX attribute to Load .
• To deny the person access to any areas, set the State attribute to Disabled .
www.PDF-Zoo.com
Personnel
23-18 Infinity Controller Programmer’s Guide
Adding More Employee Informa tionFrom the first Employee Information (Details1 ) window, when you press the DETAILS2 button the second Employee Information window appears.
Figure 23-10 shows the second Employee Information (Details2 ) window.
Figure 23-10. Second Employee Information Window
In this window, you fill in employee data, as follows:
1. Supervisor —(Optional.) Type up to 32 characters, including both letters and numbers, stating the name of the person’s supervisor.
View Edit Connect Logout
Person – Floor1 JJones
AREAS
CANCEL
DETAILS3
SAVE
Details 2
Supervisor
Job Title
Jones
License Number
Zip
Address
Jessica
Engineering
00-000-0000
4-10-93 9:00:00 am
City
Country
Home Phone
State
DOB
Add Person Information
www.PDF-Zoo.com
Personnel
Infinity Controller Programmer’s Guide 23-19
2. Job Title —(Optional.) Type up to 32 characters, including both letters and numbers, stating the person’s job title.
3. License Number —(Optional.) Type up to 12 characters, including both letters and numbers, indicating the person’s license number. This is especially useful in parking lot access control.
4. Address —(Optional.) Type up to 32 characters, including both letters and numbers, indicating the person’s home street address.
5. City —(Optional.) Type up to 16 characters, including both letters and numbers, indicating the city or town the person lives in.
6. State (StateOfResidence)—(Optional.) Type two characters, both letters, indicating the standard abbreviation of the state the person lives in.
7. Zip—(Optional.) Type up to nine characters, including letters and numbers, indicating the zip code of the person’s home address.
8. Country —(Optional.) Type up to 12 characters, including both letters and numbers, indicating the country the person lives in.
9. Home Phone —(Optional.) Type up to 40 characters, including both letters and numbers, indicating the person’s home phone number.
10. DOB (DateOfBirth)—(Optional.) Type up to eight characters, including numbers and any type of dividing character (slashes, dashes, periods, commas, and so on) indicating the person’s date of birth.
11. Press the DETAILS3 button to proceed to the Person Information window.
Indic ate the Person’sCount ry
www.PDF-Zoo.com
Personnel
23-20 Infinity Controller Programmer’s Guide
Entering Personal InformationFigure 23-11 shows the Personal Information window that appears when you press the DETAILS3 button in the Employee Information window.
Figure 23-11. Personal Information Window
In this window, you fill in more information about the person as follows:
1. Blood Type —(Optional.) Type up three characters, including both letters and numbers, indicating the person’s blood type.
2. Sex—(Optional.) Type one character, including both letters and numbers, indicating the person’s gender.
View Edit Connect Logout
Person – Floor1 JJones
AREAS
CANCEL
SAVE
Details 3
Blood Type
Sex
Hair Color
Weight
Eye Color
125
Height
Parking Sticker
5 feet 7 inches
AF276
Add Some PersonalInformatio n
www.PDF-Zoo.com
Personnel
Infinity Controller Programmer’s Guide 23-21
3. Hair Color —(Optional.) Type up to 12 characters, including both letters and numbers, indicating the person’s hair color.
4. Eye Color —(Optional.) Type up to 12 characters, including both letters and numbers, indicating the person’s eye color.
5. Height —(Optional.) Type up to 16 characters, including both letters and numbers, indicating the person’s height. You can include spaces.
6. Weight —(Optional.) Type the person’s weight.
7. Parking Sticker —(Optional.) Type up to eight characters, including letters and numbers, indicating the person’s parking sticker label.
Summary
In the second Employee Information window, you com-plete the remaining job-related information about the person:
• Supervisor , Job Title
• License Number, Address, City, State, Zip, Country, Home Phone, DOB
In the Personal Information window, you add information that you may or may not need:
• Blood Type , Sex
• Hair Color and Eye Color
• Height and Weight
You can also set the person’s parking sticker number, which can come in handy in controlling parking lot access.
www.PDF-Zoo.com
Personnel
23-22 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Appendix A
Keystrokes
This appendix covers the Infinity CX keystrokes for the four terminal types the product works on:
• VT 100
• VT 220
• Wyse 50
• CROSSTALK
The key names are listed alphabetically for easy reference.
After the terminal keystrokes, four tables present the action each key takes in the different Infinity CX modes:
• Menus
• Choice Lists
• Edit Menu Windows
• File Editor
Again, the key names are listed alphabetically.
Finally, a table lists the keys you press after the QUICKBUTTON key to press particular buttons.
www.PDF-Zoo.com
Keystrokes
A-2 Infinity Controller Programmer’s Guide
Terminal KeystrokesWhere you see ESC, press ESC first, then the other key. With CTRL, hold down CTRL while you press the other key.
Table A-1. Keystrokes on Various Terminals to Execute Inf inity Keys Keystrokes Differ on
Each Ter minal
Key Name VT 100 Keys VT 220 Keys
DeleteDELETE TEXT
Arrow Keys Arrow Keys
CANCEL WINDOW PF4
DELETE TO RIGHT ESC 7
ESC 6DELETE LINE/TEXT
DELETE WORD PF2
ESC 5INSERT LINE
LEFT SIDE ESC h
END ESC e
ESC iINSERT TEXT
EXECUTE Return
BACKSPACE Backspace
BEGIN ESC U
Remove
Arrow Keys
PF4
F7
F6
PF2
ESC 5
Find
Select
Insert Here
Enter
Backspace
ESC U
BOTTOM SCREEN ESC 9 F9
www.PDF-Zoo.com
Keystrokes
Infinity Controller Programmer’s Guide A-3
Some keystrokes are the same for more than one key. The action differs because, for instance, one action applies in the attribute windows and the other to the Editor window.
Table A-1. Keystrokes on Various Terminals to Execute Inf inity Keys (cont) VT 100, VT 220, Wyse 50,
and CROSSTALK
Key Name Wyse 50 Keys CROSSTALK Keys
DeleteDELETE TEXT
Arrow Keys Arrow Keys
CANCEL WINDOW F4
DELETE TO RIGHT F7
F6DELETE LINE/TEXT
DELETE WORD F2
BOTTOM SCREEN F9
ESC 5INSERT LINE
LEFT SIDE Home
END Shift Home
InsertINSERT TEXT
EXECUTE Enter
BACKSPACE Repl
BEGIN ESC U
Del
Arrow Keys
F4
F7
F6
F2
F9
ESC 5
Home
End
Ins
Enter
Backspace
ESC U
www.PDF-Zoo.com
Keystrokes
A-4 Infinity Controller Programmer’s Guide
Table A-1. Keystrokes on Various Terminals to Execute Inf inity Keys (cont)The MARK BLOCK Key
Starts a Block o f Text
Key Name VT 100 Keys VT 220 Keys
ESC TABPREVIOUSATTRIBUTE
MARK BLOCK CTRL B
PAGE DOWN CTRL D
PREVIOUS WORD CTRL L
CTRL UPAGE UP
QUICK BUTTON PF1
ESC ERIGHT SIDE
SHOW LIST PF2
REFRESH CTRL Z
PF3SAVE
RESTORE TEXT ESC 5
MENU BAR ESC ESC
NEXT ATTRIBUTE TAB
ESC TAB
CTRL B
Next Screen
CTRL L
Prev Screen
PF1
Select
PF2
CTRL Z
PF3
ESC 5
ESC ESC
TAB
NEXT WORD CTRL R CTRL R
TOP SCREEN ESC 8 F8
QUICK COMMAND PF3 PF3
www.PDF-Zoo.com
Keystrokes
Infinity Controller Programmer’s Guide A-5
Table A-1. Keystrokes on Various Terminals to Execute Inf inity Keys (cont) The NEXT ATTRIBUTE
Key Is Like a TAB Ke y
Key Name Wyse 50 Keys CROSSTALK Keys
ESC TABPREVIOUSATTRIBUTE
MARK BLOCK CTRL B
PAGE DOWN Page Next
PREVIOUS WORD None
Page PrevPAGE UP
QUICK COMMAND(QUICK CMD)
F3
NEXT WORD None
Shift HomeRIGHT SIDE
SHOW LIST F2
REFRESH CTRL Z
F3SAVE
RESTORE TEXT ESC 5
MENU BAR ESC ESC
NEXT ATTRIBUTE TAB
ESC TAB
CTRL B
PgDn
CTRL L
PgUp
F3
CTRL R
End
F2
CTRL Z
F3
ESC 5
ESC ESC
TAB
TOP SCREEN F8 F8
QUICK BUTTON F1 F1
www.PDF-Zoo.com
Keystrokes
A-6 Infinity Controller Programmer’s Guide
Menu K eysTable A-2. Menu Key ActionsYou Move Around on
Menus with Menu Keys
Key or Keys Action
LEFT SIDE Moves cursor to leftmost menu on the menu bar.
Returns the cursor to the menu bar.MENU BAR
Arrow Keys Move the cursor up and down the menu selections.
RIGHT SIDE Moves cursor to rightmost menu on the menu bar.
CANCEL WINDOW Return the cursor to the menu bar.
EXECUTE Open the menu or carry out the ac-tion of the menu selection.
Moves the cursor down to the next menu selection.
PAGE DOWN
PAGE UP Moves the cursor up to the next menu selection.
SAVE Returns the cursor to the menu bar.
www.PDF-Zoo.com
Keystrokes
Infinity Controller Programmer’s Guide A-7
Edit Menu Window KeysTable A-3. Window Keys to Edit Attributes Use Keys in Windows t o
Change Attr ibutes
Key or Keys Action
BACKSPACE Erases the single character that ap-pears before it. (Erases backward).
RIGHT SIDE Moves cursor to right side of text box.
Arrow Keys Move the cursor left and right in text, or up and down a list of selections.
MENU BAR Closes window and erases changes. Then returns cursor to menu bar.
DELETE TO RIGHT Deletes text to right of cursor.
DELETE LINE/TEXT Erases all text in the text box the cur-sor is in.
RESTORE TEXT Returns text in text box to what it was before you changed it.
Erases the single character that appears after it. (Erases forward).
DELETE TEXT
Moves cursor to left side of text box.LEFT SIDE
NEXT ATTRIBUTE Moves cursor forward one attribute.
PREVIOUSATTRIBUTE
Moves cursor back one attribute.
SAVE Saves all attributes. EXECUTE saves if not on a button that directs another action.
CANCEL WINDOW Closes window and erases changes. Then returns cursor to menu bar.
When you press it, then type, inserts text where cursor is in text box.
INSERT TEXT
EXECUTE Saves all attributes. EXECUTE saves if not on a button that directs another action.
www.PDF-Zoo.com
Keystrokes
A-8 Infinity Controller Programmer’s Guide
Choice List KeysTable A-4. Choice List KeysUse Keys in Choice Lis ts
to Move and Select
Key or Keys Action
Returns the cursor to the menu bar.MENU BAR
Arrow Keys Move the cursor up and down the choice list selections.
CANCEL WINDOW Return the cursor to the menu bar.
EXECUTE Selects the highlighted name from the choice list.
Moves the cursor down to the next choice list selection.
PAGE DOWN
PAGE UP Moves the cursor up to the next choice list selection.
SAVE Returns the cursor to the menu bar.
www.PDF-Zoo.com
Keystrokes
Infinity Controller Programmer’s Guide A-9
File Editor KeysTable A-5. File Editor Keys Use Key s in Edito r
Window to Alter Files
Key or Keys Action
BACKSPACE Erases the single character that ap-pears before it. (Erases backward).
Erases one word left to right (Erases forward).
INSERT LINE Inserts a blank line below the one the cursor is on.
DELETE WORD
Arrow Keys Move the cursor anywhere on the screen.
BEGIN Takes the cursor to the top of the file and positions it in the leftmost posi-tion in that line.
Takes the cursor to the bottom of the file.
END
DELETE LINE Removes the entire line the cursor is on.
DELETE TEXT Erases the single character that is af-ter it. (Erases forward).
DELETE TO RIGHT Deletes text to the right of the cursor through the end of the line.
BOTTOM SCREEN Moves the cursor to the bottom of the visible screen.
CANCEL WINDOW Moves cursor to menu bar if in the editor, to editor if in menu bar.
Return Ends a physical line of text and brings the cursor to the beginning of the next line.
www.PDF-Zoo.com
Keystrokes
A-10 Infinity Controller Programmer’s Guide
Table A-5. File Editor Keys (cont)QUICK COMMAND KeyMakes Keys Commands
Key or Keys Action
QUICK CMD Lets you use quick commands.
RIGHT SIDE Moves the cursor to the far right end of the line it is on.
TOP SCREEN Moves the cursor to the top of the vis-ible screen.
MARK BLOCK Marks the beginning of a block of text where the cursor is when you press it. You move the cursor to the end of the block of text. You can then select functions from the Edit menu in the File menu bar to cut, copy, or paste the block.
Moves the cursor left (back) one word.
PREVIOUS WORD
PAGE UP Moves cursor up to previous screen.
Moves cursor down to next screen.PAGE DOWN
Moves the cursor right (forward) one word.
NEXT WORD
LEFT SIDE Moves the cursor to the far left end of the line it is on.
INSERT TEXT At any position on the screen, inserts text after you press it.
QUICK BUTTON Lets you use a quick button (see Table A-6).
www.PDF-Zoo.com
Keystrokes
Infinity Controller Programmer’s Guide A-11
Quick Button KeysTo press a button quickly (instead of moving to it with the NEXT ATTRIBUTE key), press the QUICK BUTTON key, then press the corresponding letter key, such as S to press the SAVE button.
Most quick button keys are the first letter of the word. How-ever, since D is for DETAILS, the second letter in the word, E, is for DELETE. Since E is for DELETE, X (again the sec-ond letter) is for EXIT. The table lists all quick button keys.
Table A-6. Quick Button Keys
Press Buttons Quickly with Quick Bu tto n Keys
Quick Key Button Pressed
L LOGS or LEARN
R RETRY or RESET
DELETEE
DETAILSD
C CANCEL, CLEAR, or CHECK
A ADD or SAVE AS
S SAVE
T TRIGGERS or TEACH
X EXIT
N NO or NEXT
V VIEW
O OK
Y YES
P PREVIOUS
Q QUIT
www.PDF-Zoo.com
Keystrokes
A-12 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Appendix B
Error Mes sages
This appendix covers the Editor window, runtime, and open-ing file messages from Andover Controls Plain English.
www.PDF-Zoo.com
Messages
B-2 Infinity Controller Programmer’s Guide
Editor Window Error MessagesThe following messages occur inside the editor. Some of them may also occur in the Command window. They are listed in alphabetical order. The cursor lands on the line the message refers to.
Alarm expression is too long
Look for an expression in an alarm that has too many char-acters in it. The maximum length is 132 characters. If the expression is not over 132 characters, it may still be too long for the controller to process, because, for instance, each floating point number you use requires more space to store in the controller than to display on the screen. Try altering the expression.
An argument index must be from 1 to 15
In a function only, when you set up arguments using the ARG keyword, you must give each a number from 1 to 15. You can have up to 15 arguments in a function.
Array is longer than 32,767 entries
Redefine the array with an array SIZE of up to, but not exceeding, 32,767.
Attribute does not apply to the item type
Remove the reference to an attribute that does not existfor that particular item. For instance, programs have CURRENTLINE and FILESIZE; points do not. Refer to Appendix B in the Andover Controls Plain English Lan-guage Reference for more on attributes.
Editor or CommandWindo w Messag es
www.PDF-Zoo.com
Messages
Infinity Controller Programmer’s Guide B-3
Attributes do not apply to local variables
Remove the reference to an attribute after the variable, except in the case of an OBJECT local variable. For more information about OBJECT local variables, see the OBJECT keyword in the Andover Controls Plain English Language Reference.
BREAK or CONTINUE is outside a loop or block
Search the program for the word BREAK or CONTINUE. Rewrite the program so you use BREAK or CONTINUE in a loop (or block of statements) or do not use them at all.
Cannot define any more local variables
Check the number of local variables. You cannot have more than 255. Rewrite the program as required.
Cannot enable/disable all of one type
Alter the statement that tries to enable or disable all points, files, or other items. The controller does not execute such a statement.
Cannot run or stop program from command line
Occurs on the command line only. Check the program’s COMMANDLINE attribute to see if it is TRUE or FALSE. If it is FALSE and you want to run the program from a program or the command line, change the attribute to TRUE.
Cannot use that var as FOR..NEXT index var
Check to be sure you used a local numeric variable, or a point that is not a string, date-time, or input, for the index variable in FOR..NEXT.
FOR..NEXT Variable Must Be Defined
www.PDF-Zoo.com
Messages
B-4 Infinity Controller Programmer’s Guide
Command is valid only from command line
Look for a command in a program that is allowed only on the command line.
Command is valid only in a program or function
If you tried to use a command from the command line that you must use only in a program or function, you receive this message.
Comment has more than 132 characters
Rewrite comment so it is not longer than 132 characters. A tilde cannot extend a comment.
Data file is too long
Alter data file so it does not have more than 32,767 bytes (32 KB); bytes are approximately equal to characters in size. You may copy some data to another file to reduce the number of records.
Data has more chars than field allows
Alter the size of the data field or alter the data to fit the size of the field you defined.
Date or time is not valid
Be sure the date-time field contains the complete date and time. If it does, be sure the date and time are actually valid—do not enter a date or time with a zero for the month or day. Do not enter a month over 12, a day over 31, a year over 2038, or an hour over 23.
Data type is not same as field type
Rewrite the record in the data file so you are not assigning a number (or string or date-time) to a field of a different type.
Data Fields Are aParticular Lengt h
www.PDF-Zoo.com
Messages
Infinity Controller Programmer’s Guide B-5
Fatal, Bad Stack Address
Call your Andover Controls representative.
Fatal, Illegal Stack Operation
Call your Andover Controls representative.
Fatal, Not enough free memory
Call your Andover Controls representative.
Feature not available on this controller
Check for keywords that do not run on the particular con-troller you are on. Refer to the Andover Controls Plain English Language Reference for this detail on each key-word.
Field is too long to display
If the field is more than 129 characters long it cannot dis-play on the screen when you display the data file. Change the length of the field if you want to display it in its entirety.
FOR and NEXT use different index var names
Be sure the index variable after NEXT is the same as the one after FOR. If it is not, then change the statement so they are the same.
GOTO is not allowed inside a loop
Remove GOTO from inside the loop and rewrite that part of the program.
Incorrect array entry type
Check the item type to be sure it is a point or local variable. No other item can be an array. If the item is a point or local
FOR and NEXT Must Name Same Variable
www.PDF-Zoo.com
Messages
B-6 Infinity Controller Programmer’s Guide
variable, check the array type and be sure the entry is the same type—numeric, string, or datetime.
Local variable name cannot be an argument
Look for a situation where you tried to give a local variable and an argument the same name.
More records than RECORD statement allows
Change the number in the RECORD statement to a higher number, or remove records from the file so the total is less than or equal to the number in RECORD statement.
Name given is not a controller name
Double check the name of the controller or its path to be sure it is correct and you did not spell it wrong. For example, this error message appears if you try to connect with CD to an item other than a controller.
Name has more than 16 characters
Rename the item so its name is 16 characters or less.
Name is not a program or function name
Double check the name of the program or function to be sure it is a program or function and you did not spell it wrong. For example, this error message appears if you try to ROTATE an item other than a program.
No chars allowed after continuation symbol
Remove any characters after the tilde (~) that are on the same physical line. The statement continues on the next line, so any extra characters on the same line are an error. If you typed tilde by mistake, delete the tilde, because the controller thinks it is at the end of a line.
Some CommandsRequire a Program Name
www.PDF-Zoo.com
Messages
Infinity Controller Programmer’s Guide B-7
No function with that name exists
When calling a function, you may have spelled the func-tion name wrong. If you spelled the name correctly, check to be sure the function exists.
No item with that name exists
Check the statement for a name you misspelled or never defined. Be sure you did not make a mistake typing it. If you did not define it or spell it correctly, the controller does not recognize it.
No line has this line name
Check after GOTO for a line name that you never assigned or that you spelled incorrectly.
No quotation marks at end of string
Add the quotation marks to close the string.
Number cannot be longer than 132 digits
Redefine the numeric point, variable, or field (in data file) so it does not contain more than 132 digits.
Number is not valid
The number you entered may contain nonnumeric digits or be a number the controller does not understand.
Number must be an integer
Some attributes require an integer value (number with no decimal after it), such as the array or log SIZE attribute. Check to be sure you have not set one to a value with a dec-imal in it.
Sometimes Number Must Be an Integer
www.PDF-Zoo.com
Messages
B-8 Infinity Controller Programmer’s Guide
Operation is not available
Keyword you used does not function at this stage of product development.
Parser stack overflow
Call your Andover Controls representative.
Passed too many arguments to a function
Look for a situation where you have tried pass more than 15 arguments into a function like SUM, MINIMUM, MAXIMUM, or your own function.
Path name has too many names
Alter the path so that it has up to, but not more than, three names, not including attributes. Check the spelling of each controller/point in the path to be sure it matches one of the names you have assigned. If all names are spelled cor-rectly, be sure you used either spaces or backslashes between each. (If you still cannot find the problem, check the location of each controller or point on the network to be sure the path is correct.)
Record has too many or too few fields
Compare the defined fields at the top of the file with those in the record. Be sure you add any missing fields in a record or remove any excess fields.
Report files are not supported yet
If you try to set up a report on a controller, you receive this message in the Editor window as soon as the window appears. You can set up reports only on a workstation.
Same line name given to more than one line
Rename the line so you do not use the same line name more than once in a single program.
Each Path Can HaveThree Names
www.PDF-Zoo.com
Messages
Infinity Controller Programmer’s Guide B-9
Same name for more than one local variable
Rename the variable so it has a unique name.
Same name or number for more than 1 argument
Rename the argument so it has a unique name, or renumber it so it has a unique number.
Statement or expression is not correct
Check the format against the format in the reference manual. Check for misspellings of keywords and names, closing parentheses, extra or missing commas, extra ANDs and ORs, missing words, extra words, or extra char-acters. The error can also be in a conversion or alarm expression.
Statement is too long
Reduce the length of the statement to a maximum of 10 complete physical lines.
String is too long
Redefine the string so it has up to 132 characters. (If the string is a field in a data file, it can be up to 130 characters long.) Or rewrite the program so you do not fill the string with too many characters.
Each Arg Must Have Unique Name/Number
www.PDF-Zoo.com
Messages
B-10 Infinity Controller Programmer’s Guide
Symbol(s) are not from the correct set
Check to be sure you did not enter characters that are not allowed in the language. Symbols you can use include:
– Minus Sign
+ Plus Sign
, Comma
= Equals Sign
* Asterisk (Multiply Symbol)
/ Slash (Divide Symbol)
( Open Parenthesis
) Close Parenthesis
! Exclamation Point (OR Symbol)
% Percent Symbol
& Ampersand (AND Symbol)
^ Exponent Symbol
[ Left Square Bracket
] Right Square Bracket
: Colon (Line Name Symbol)
\ Backslash (Path Separator)
You can use any symbol in a string or comment.
Unknown command option
Appears if you try to use a nonexistent option with LOAD or SAVE on the command line.
You cannot change that attribute value
Remove the statement that attempts to set an attribute that only the controller can set. Refer to Appendix B of the Andover Controls Plain English Language Reference for attributes you cannot set.
Only Certain SymbolsAre Allo wed
www.PDF-Zoo.com
Messages
Infinity Controller Programmer’s Guide B-11
You cannot change value of system variable
Remove any statement that tries to set variables that the controller sets, such as MINUTE and SECOND. (You can set the HOUR, DATE, ERRORS, STATUS1 through STATUS8, and so on. See specific system variables to be sure.)
You cannot set that item value
Change the program so it does not try to set values of items the controller sets, such as input points, or of items that do not have a VALUE attribute, such as programs. Look for keywords such as SET, ADJUST, MOVE, LET, CHANGE, or TURN.
You must give a name of a local data file
Some keywords, such as those that refer to a field within a record, require a data file name. A data file name is required when attempting to access any field in the file, whether to print it, read it, or use it in any other situation. Check to be sure the file you name is a data file and one on the same controller the program is on.
0, C or E is a reserved line name
Change the name of any line that you named 0, C, or E. All three are reserved. You can send a program to line 0 to stop it, but cannot send a program to lines C or E.
You Must Gi ve a Data File o n Same Controller
www.PDF-Zoo.com
Messages
B-12 Infinity Controller Programmer’s Guide
Runt ime Error Me ssagesThe following messages occur only when you run the pro-gram and have errors that keep it from running properly, called runtime errors:
An expression uses an operand incorrectly
Look for an expression contains items, variables, and lit-erals (actual numbers or text) that are not the same type. You cannot add a string to a number, or compare a string to a date-time. See the chapter on operators in the Andover Controls Plain English Language Reference.
Attribute does not apply to the item type
Remove the reference to an attribute that does not exist for that type of item. For instance, a program does not have a SIZE attribute, but a FILESIZE attribute. Refer to Appendix B in the Andover Controls Plain English Lan-guage Reference for more on attributes.
Cannot read data file
Try to read again. File may not be available if being used by another program.
Cannot write to data file
Be sure the data file is set up, and the name in the statement is correct. If name is correct, try to write again. File may not be available if being used by another program. In rare cases, file may be damaged and not accessible.
Chosen area too small for this control
Try changing the coordinates for a control you are sending to the DCX 250 screen with the CONTROL keyword. The area you designated is too small for the style control you selected.
Runtime Messages
www.PDF-Zoo.com
Messages
Infinity Controller Programmer’s Guide B-13
Comm port operation failed
This message appears if you used the workstationCommand line from a controller at another site and the workstation failed (for instance, went off line for a moment). The workstation may have failed for various reasons. You never see this message if you have no work-station.
Date or time is not valid
Be sure the date-time contains the complete date and time. If it does, be sure the date and time are actually valid—do not enter a date or time with a zero for the month or day. Do not enter a month over 12, a day over 31, a year over 2038, or an hour over 23.
Executed too many statements on one line
Reduce the number of statements on one line. If no line has many statements, check your looping statements to be sure the loop does not repeat too many times. Check your func-tion calls to be sure you have not nested too many. Call your Andover Controls representative.
FOR..NEXT loop index variable not numeric
Check the index variable definition at the top of the pro-gram. Be sure it is numeric.
Function did not give the expected result
Look for an expression that uses the result of a function and see the returned value is the same type as the other operands in the expression. You cannot add a string to a number, or compare a string to a date-time. See the chapter on operators in the Andover Controls Plain English Language Reference.
FOR..NEXT Variable Must Be Numeric
www.PDF-Zoo.com
Messages
B-14 Infinity Controller Programmer’s Guide
Gave an array entry that does not exist
Change the statement that tries to assign a value to an array position that does not exist. For instance, if the array has 20 entries, and you attempt to put a value in entry 21, you receive this error. The error also occurs if you use a vari-able for the array index and the value of the variable is set to a negative number.
Gave more or less arguments than allowed
Open the function (or double check your manual if it is an Andover Controls Plain English function) and look at the arguments it can receive. Then alter the statement that calls the function so it sends the correct number of arguments.
Gave non-numeric var as array index
Check to be sure the array index is a numeric variable or point, not a string or date-time.
Invalid coordinates(s)
One or more of the coordinates to position a graphic (such as a control on the DCX 250 with the CONTROL key-word) are either off the screen or not in the an appropriate position for the size of the control.
Must set HOUR to value from 0 to 23
HOUR is the only system variable you can set. Change the statement so it sets the HOUR to a value between 0 and 23.
No more controls allowed -- max reached
You may not have more than 24 controls on a single DCX 250. This error occurs when you try to save a 25th control.
Operation is not available
Keyword you used does not function at this stage of product development.
Array Index VariableMust A lways B e Numeric
www.PDF-Zoo.com
Messages
Infinity Controller Programmer’s Guide B-15
Path name is not an actual path
Check the spelling of each controller, point, or other item in the path to be sure it matches one of the names you have assigned. If all names are spelled correctly, be sure you used either spaces or backslashes between each. If you still cannot find the problem, check the location of each con-troller or point on the network to be sure the path is correct.
Scanner Runtime Stack Overflow
You used too many levels of function calls. Reduce the number of nested levels or reduce the number of argu-ments you pass to functions. If you still receive this message, call your Andover Controls representative.
Set a point or var to value of wrong type
If you try to set a point to a value of a different type, you receive this error. You can enter numbers in a numeric item, letters of the alphabet in a string, and naming charac-ters in a name. Rewrite the program so you do not attempt to set the point or variable to that type.
String is too long
Look through your program for statements that assign values to strings or expressions that manipulate strings. If the statement assigns a value longer than 132, alter the statement. If the string is a field in a data file and has more than 130 characters, alter the string.
Tried to divide a value by zero
Alter any expression that tries to divide by zero. Any expression that divides by zero gives an error. Add an IF..THEN to check that the divisor is not zero before dividing by it.
Dividing by Zero IsAlway s an Error
www.PDF-Zoo.com
Messages
B-16 Infinity Controller Programmer’s Guide
Tried to print to a non-string item
If you try to PRINT a string expression or string of charac-ters to a numeric or date-time point, this error occurs.
Tried to rotate prog to nonexistent line
Open the file containing the program you are trying to rotate. Check the line name to be sure you are rotating to the correct name. Be sure it is spelled correctly.
Tried to set item you cannot set
If you try to set a point (such as an input or a system vari-able) that only the controller can set, you receive this error. Rewrite the program so you do not attempt to set that point. Look for keywords such as SET, ADJUST, MOVE, LET, CHANGE, or TURN. (The HOUR and DATE are the only system variables you can set.)
Tried to use local var that does not exist
Try editing your file and double check each local variable. If you still have this problem, call your Andover Controls representative.
Used an incorrect function argument
Alter the statement in the program that calls the function so that each argument is appropriate for the action the function takes. You may have to look at the function file to determine exactly what kind of arguments it requires. If the function is from Andover Controls Plain English, see the Andover Controls Plain English Language Reference.
Used a type when it is not allowed
Alter statements that attempt to, for instance, rotate a point instead of a program.
Used other where data file name is required
You Must Define LocalVariables
www.PDF-Zoo.com
Messages
Infinity Controller Programmer’s Guide B-17
When trying to access a particular field in the file, you must give a data file name. Check statements that require a data file and be sure the file you named is a data file, not a program or function, and not a point or other item.
Used rec or field data file does not have
Check the data file to see how many records and columns it has. (The column number is the field number.) If the pro-gram tries to access a record or column that is not there, the program stops. Correct the statement based on the data file.
Record Name Not in Data File
www.PDF-Zoo.com
Messages
B-18 Infinity Controller Programmer’s Guide
Opening File Error Mes sagesThe following messages occur only when you try to open a file and the controller finds a problem. The cursor goes to the physical line containing the error. Some of the messages are similar to editor or runtime messages:
Controller cannot find an item
Open the program and look for the names of points, vari-ables, programs, and other items. Look for one that is not defined. Perhaps you recently deleted a point that is used in this program or data file. The item the controller cannot find can be in a point conversion or in a point you tried to use in the file. Correct the file by defining the item or removing the statement from the program or conversion.
Controller cannot open a file of this type
Andover Controls has reserved certain types to become file types in the future. If you try to open a file of a type that is not yet developed, the controller will not let you open it. Try opening another file.
Date or time is not valid
A date-time field in a data file does not contain the com-plete date and time or contains one of these:
• Text or numbers that do not form a date and time.
• A date or time with zero for the month or day.
• A month over 12, a day over 31, a year over 2038, or an hour over 23.
When you open the data file, the date-time field contains 1/ 1/ 89 00:00:00 instead of the data you entered.
Some Erro rs Occur OnlyWhen You Open a File
www.PDF-Zoo.com
Messages
Infinity Controller Programmer’s Guide B-19
Exceeded number of displayable lines
The maximum number of lines the controller can display is 400 physical lines (approximately eight screen pages). A file can end up longer than 400 lines if you search and replace information in a file that lengthens a name or expression. When you try to open the file, you will not be able to view all the lines on the screen.
If you have just completed the search and replace, but not yet saved the file, simply quit the file without saving. This action leaves the file as it was before you searched.
Or, if you really must edit the file, open a Command window from inside the file and use the SAVE keyword to save the program to a dump file. Edit the dump file and reload it using the LOAD keyword.
Fatal, Not enough free memory
Call your Andover Controls representative.
Operation is not available
A keyword you used inside the file does not function at this stage of product development.
Statement is too long
Open the file and look for a statement over 10 physical lines long. Reduce the length of the statement.
String is too long
Look through your program for statements that assign values to strings or expressions that manipulate strings. If the state-ment assigns a value longer than 132, alter the statement. If the string is a field in a data file, it can be up to 130 characters long.
Strings Can Receive Up to 132 Characters
www.PDF-Zoo.com
Messages
B-20 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Appendix C
DCX Graphic Controlsand Frame Styles
This appendix presents a graphic of each DCX 250 control, and its control number, in numeric order. It then presents each frame style, in numeric order.
Requirements for the CONTROL keyword arguments vary based on the control style. Exact requirements for that control style appear with the graphic for that control.
www.PDF-Zoo.com
Control and Frame Styles
C-2 Infinity Controller Programmer’s Guide
Figure C-1. Control Style 1—Raised Butto n
• Resizing—You may resize. Fits any size area, as long as all coordinates are on the screen. The minimum size in line points is 40 wide by 25 high.
• frame—Do not specify. Automatically placed around control.
• direction—Not applicable.
• bot_scale—Optional. Automatically set to OFF or one of the two values of a digital attribute, such as DISABLED for STATE.
• top_scale—Optional. Automatically set to ON or one of the two values of a digital attribute, such as ENABLED for STATE.
• tickmarks—Not applicable.
• steps—Not applicable.
• format—Not applicable.
Title
www.PDF-Zoo.com
Control and Frame Styles
Infinity Controller Programmer’s Guide C-3
Figure C-2. Control Style 2—Flat Button
• Resizing—You may resize. Fits any size area, as long as all coordinates are on the screen. The minimum size in line points is 40 wide by 25 high.
• frame—Do not specify. Automatically placed around control.
• direction—Not applicable.
• bot_scale—Optional. Automatically set to OFF or one of the two values of a digital attribute, such as DISABLED for STATE.
• top_scale—Optional. Automatically set to ON or one of the two values of a digital attribute, such as ENABLED for STATE.
• tickmarks—Not applicable.
• steps—Not applicable.
• format—Not applicable.
Title
www.PDF-Zoo.com
Control and Frame Styles
C-4 Infinity Controller Programmer’s Guide
Figure C-3. Control Style 3—Light Switch
• Resizing—Cannot resize. Positions itself in the center of the coordinates you give, as long as all coordinates are on the screen. Be careful—If the coordinates you give force the control off the screen, it does not appear. The center of the control must be at least 21 line points from any edge of the screen.
• frame—If you do not specify a frame, the switch appears without the frame around it.
• direction—Not applicable.
• bot_scale—Optional. Automatically set to OFF or one of the two values of a digital attribute, such as DISABLED for STATE.
• top_scale—Optional. Automatically set to ON or one of the two values of a digital attribute, such as ENABLED for STATE.
• tickmarks—Not applicable.
Title
www.PDF-Zoo.com
Control and Frame Styles
Infinity Controller Programmer’s Guide C-5
• steps—Not applicable.
• format—Not applicable.
www.PDF-Zoo.com
Control and Frame Styles
C-6 Infinity Controller Programmer’s Guide
Figure C-4. Control Style 4—Toggle Swit ch
• Resizing—Cannot resize. Positions itself in the center of the coordinates you give, as long as all coordinates are on the screen. Be careful—If the coordinates you give force the control off the screen, it does not appear. The center of the control must be at least 21 line points from any edge of the screen.
• frame—If you do not specify a frame, the toggle switch appears without the frame around it.
• direction—Not applicable.
• bot_scale—Optional. Automatically set to OFF or one of the two values of a digital attribute, such as DISABLED for STATE.
• top_scale—Optional. Automatically set to ON or one of the two values of a digital attribute, such as ENABLED for STATE.
• tickmarks—Not applicable.
Title
www.PDF-Zoo.com
Control and Frame Styles
Infinity Controller Programmer’s Guide C-7
• steps—Not applicable.
• format—Not applicable.
www.PDF-Zoo.com
Control and Frame Styles
C-8 Infinity Controller Programmer’s Guide
Figure C-5. Control Style 5—Slid ing Swit ch
• Resizing—Cannot resize. Positions itself in the center of the coordinates you give, as long as all coordinates are on the screen. Be careful—If the coordinates you give force the control off the screen, it does not appear. The center of the control must be at least 21 line points from any edge of the screen.
• frame—If you do not specify a frame, the sliding switch appears without the frame around it.
• direction—Not applicable.
• bot_scale—Optional. Automatically set to OFF or one of the two values of a digital attribute, such as DISABLED for STATE.
• top_scale—Optional. Automatically set to ON or one of the two values of a digital attribute, such as ENABLED for STATE.
• tickmarks—Not applicable.
Title
www.PDF-Zoo.com
Control and Frame Styles
Infinity Controller Programmer’s Guide C-9
• steps—Not applicable.
• format—Not applicable.
www.PDF-Zoo.com
Control and Frame Styles
C-10 Infinity Controller Programmer’s Guide
Figure C-6. Control Style 6—Knob
• user_change—If you do not allow the user to change the setting of the knob, the arrows do not appear.
• Resizing—Cannot resize. Positions itself in the center of the coordinates you give, as long as all coordinates are on the screen. Be careful—If the coordinates you give force the control off the screen, it does not appear. The center of the control must be at least 30 line points from any edge of the screen.
•
• frame—Optional.
• direction—Not applicable. Values always increase in clockwise direction.
• bot_scale—Required if it is not a digital knob. Automatically set to OFF or one of the two values of a digital attribute, such as DISABLED for STATE.
Title
www.PDF-Zoo.com
Control and Frame Styles
Infinity Controller Programmer’s Guide C-11
• top_scale—Required if it is not a digital knob. Automatically set to ON or one of the two values of a digital attribute, such as ENABLED for STATE.
• tickmarks—Optional. You do not have to display tick marks, but you may.
• steps—Automatically sets to the number of degrees in the arc of the circle from the first tick mark shown to the last (approximately 2/3 of a circle), for a total of 240 degrees—240 steps you can set the knob to. You may set the number of steps to a smaller number. If you set it to 0, the knob becomes analog.
• format—Optional. If you do not specify a format for the numbers that label the positions on the knob, Infinity does not display the number but leaves adequate space to display four digits—####.
www.PDF-Zoo.com
Control and Frame Styles
C-12 Infinity Controller Programmer’s Guide
Figure C-7. Control Style 7—Rotational Needle Gauge, Vertical Posi tio n
• user_change—If you do not allow the user to change the setting of the gauge, the arrows do not appear.
• Resizing—You may resize. Positions itself in the center of the coordinates you give, as long as all coordinates are on the screen. Retains its basic shape even if you put it in a tall narrow area or a short wide area. Fits to the smaller of the two dimensions and the other dimension becomes proportional. Size also automatically allows for a four-digit number to appear to the right of each tick mark, even if you do not specify a format. The numbers take up space within the area you specify. The minimum size in line points is 80 wide if arrows are horizontal and 50 wide if vertical.
• frame—Optional.
• direction—Not applicable. Values always increase in clockwise direction.
Title
www.PDF-Zoo.com
Control and Frame Styles
Infinity Controller Programmer’s Guide C-13
• bot_scale—Required if it is not a digital gauge. Automatically set to OFF or one of the two values of a digital attribute, such as DISABLED for STATE.
• top_scale—Required if it is not a digital gauge. Automatically set to ON or one of the two values of a digital attribute, such as ENABLED for STATE.
• tickmarks—Optional. You do not have to display tick marks, but you may.
• steps—Automatically sets to the number of degrees in the arc of the circle from the first tick mark shown to the last (1/2 of a circle), for a total of 180 degrees—180 steps you can set the gauge to. You may set the number of steps to a smaller number. If you set it to 0, the gauge becomes analog.
• format—Optional. If you do not specify a format for the numbers that label the positions on the gauge, Infinity does not display the number but leaves adequate space to display four digits—####.
www.PDF-Zoo.com
Control and Frame Styles
C-14 Infinity Controller Programmer’s Guide
Figure C-8. Control Style 8—Rotational Needle Gauge, Horizontal Positi on
• user_change—If you do not allow the user to change the setting of the gauge, the arrows do not appear.
• Resizing—You may resize. Positions itself in the center of the coordinates you give, as long as all coordinates are on the screen. Retains its basic shape even if you put it in a tall narrow area or a short wide area. Fits to the smaller of the two dimensions and the other dimension becomes proportional. Size also automatically allows for a four-digit number to appear to the right of each tick mark, even if you do not specify a format. The numbers take up space within the area you specify. The minimum size in line points is 80 wide if arrows are horizontal and 50 wide if vertical.
• frame—Optional.
• direction—Not applicable. Values always increase in clockwise direction.
Title
###.##
www.PDF-Zoo.com
Control and Frame Styles
Infinity Controller Programmer’s Guide C-15
• bot_scale—Required if it is not a digital gauge. Automatically set to OFF or one of the two values of a digital attribute, such as DISABLED for STATE.
• top_scale—Required if it is not a digital gauge. Automatically set to ON or one of the two values of a digital attribute, such as ENABLED for STATE.
• tickmarks—Optional. You do not have to display tick marks, but you may.
• steps—Automatically sets to the number of degrees in the arc of the circle from the first tick mark shown to the last (1/2 of a circle), for a total of 180 degrees—180 steps you can set the gauge to. You may set the number of steps to a smaller number. If you set it to 0, the gauge becomes analog.
• format—Optional. If you do not specify a format for the numbers that label the positions on the gauge, Infinity does not display the number but leaves adequate space to display four digits—####.
• The value that appears in the box automatically appears in the format for the point that the control represents.
www.PDF-Zoo.com
Control and Frame Styles
C-16 Infinity Controller Programmer’s Guide
Figure C-9. Control Style 9—Value Bar wit h Ar row Buttons
• user_change—If you do not allow the user to change the setting of the value, the arrows do not appear, so you see only the value in a box.
• Resizing—You may resize. Positions itself in the center of the coordinates you give, as long as all coordinates are on the screen and those coordinates position the arrow buttons each on separate cells. Shapes to a tall narrow area or a short wide area. Must be at least 80 line points wide and 50 line points high.
• frame—Optional.
• direction—Not applicable.
• bot_scale—Required if it is not a digital control. If it is for a digital point or attribute, automatically set to OFF or one of the two values of a digital attribute, such as DISABLED for STATE.
####.##
Title
www.PDF-Zoo.com
Control and Frame Styles
Infinity Controller Programmer’s Guide C-17
• top_scale—Required if it is not a digital control. If it is for a digital point or attribute, automatically set to ON or one of the two values of a digital attribute, such as ENABLED for STATE.
• tickmarks—Not applicable.
• steps—Required. If you do not give a number of steps, the number defaults to 1, the correct number for a digital point or attribute.
• format—Not applicable.
• The value that appears in the box automatically appears in the format for the point that the control represents.
www.PDF-Zoo.com
Control and Frame Styles
C-18 Infinity Controller Programmer’s Guide
Figure C-10. Cont rol Style 10—Value Bar
• user_change—If you do not allow the user to change the setting, the arrows do not appear.
• Resizing—You may resize. Positions itself in the center of the coordinates you give, as long as all coordinates are on the screen. Shapes to a tall narrow area or a short wide area. Must be at least 80 line points wide and 50 line points high.
• frame—Optional.
• direction—Not applicable.
• bot_scale—Required if it is not a digital control. If it is for a digital point or attribute, automatically set to OFF or one of the two values of a digital attribute, such as DISABLED for STATE.
• top_scale—Required if it is not a digital control. If it is for a digital point or attribute, automatically set to ON or one
####.##
Title
www.PDF-Zoo.com
Control and Frame Styles
Infinity Controller Programmer’s Guide C-19
of the two values of a digital attribute, such as ENABLED for STATE.
• tickmarks—Not applicable.
• steps—Required. If you do not give a number of steps, the number defaults to 1, the correct number for a digital point or attribute.
• format—Not applicable.
• The value that appears in the box automatically appears in the format for the point that the control represents.
www.PDF-Zoo.com
Control and Frame Styles
C-20 Infinity Controller Programmer’s Guide
Figure C-11. Control Style 11—Level Fill with Scale
• user_change—If you do not allow the user to change the setting, the arrows do not appear.
• Resizing—You may resize. Positions itself in the center of the coordinates you give, as long as all coordinates are on the screen. Shapes to a tall narrow area or a short wide area. Must be at least 80 line points wide and 50 line points high.
• frame—Optional.
• direction—Required. Set to horizontal or vertical to determine the direction the bar moves to show a change in value. If you do not set, it is automatically horizontal.
• bot_scale—Required if it is not a digital control. If it is for a digital point or attribute, automatically set to OFF or one of the two values of a digital attribute, such as DISABLED for STATE.
Title
www.PDF-Zoo.com
Control and Frame Styles
Infinity Controller Programmer’s Guide C-21
• top_scale—Required if it is not a digital control. If it is for a digital point or attribute, automatically set to ON or one of the two values of a digital attribute, such as ENABLED for STATE.
• tickmarks—Optional. You do not have to display tick marks, but you may.
• steps—Required. If you do not give a number of steps, the number defaults to the number of dots on the screen along the length of the scale.
• format—Optional. If you do not specify a format for the numbers that label the positions on the knob, Infinity does not display the number but leaves adequate space to display four digits—####.
www.PDF-Zoo.com
Control and Frame Styles
C-22 Infinity Controller Programmer’s Guide
Figure C-12. Cont rol Style 12—Slider Pointer and Scale
• user_change—If you do not allow the user to change the setting, the arrows do not appear.
• Resizing—You may resize. Positions itself in the center of the coordinates you give, as long as all coordinates are on the screen. Shape to a tall narrow area or a short wide area. Must be at least 80 line points wide and 50 line points high.
• frame—Optional.
• direction—Required. Set to horizontal or vertical to determine the direction the pointer moves to show a change in value. If you do not set, it is automatically horizontal.
• bot_scale—Required if it is not a digital control. If it is for a digital point or attribute, automatically set to OFF or one of the two values of a digital attribute, such as DISABLED for STATE.
Title
www.PDF-Zoo.com
Control and Frame Styles
Infinity Controller Programmer’s Guide C-23
• top_scale—Required if it is not a digital control. If it is for a digital point or attribute, automatically set to ON or one of the two values of a digital attribute, such as ENABLED for STATE.
• tickmarks—Optional. You do not have to display tick marks, but you may.
• steps—Required. If you do not give a number of steps, the number defaults to the number of dots on the screen along the length of the scale.
• format—Optional. If you do not specify a format for the numbers that label the positions on the knob, Infinity does not display the number but leaves adequate space to display four digits—####.
www.PDF-Zoo.com
Control and Frame Styles
C-24 Infinity Controller Programmer’s Guide
Figure C-13. Control Style 13—DateTime Display Bar
• user_change—If you do not allow the user to change the setting, the arrows do not appear.
• Resizing—You may not resize. Positions itself in the center of the coordinates you give, as long as the center of the control is at least 95 line points from any screen edge. The control automatically positions itself in the single row of cells nearest the coordinates you give. Must be at least 80 line points wide and 50 line points high.
• frame—Optional.
• direction—Not applicable.
• bot_scale—Not applicable.
• top_scale—Not applicable.
• tickmarks—Not applicable.
• steps—Not applicable.
•
###•##•#### ##:##:##
Title
www.PDF-Zoo.com
Control and Frame Styles
Infinity Controller Programmer’s Guide C-25
• format—Not applicable.
• You must specify a datetime point or the control does not appear.
www.PDF-Zoo.com
Control and Frame Styles
C-26 Infinity Controller Programmer’s Guide
Figure C-14. Frame Style 1
Title
www.PDF-Zoo.com
Control and Frame Styles
Infinity Controller Programmer’s Guide C-27
Figure C-15. Frame Style 2
Title
www.PDF-Zoo.com
Control and Frame Styles
C-28 Infinity Controller Programmer’s Guide
Figure C-16. Frame Style 3
Title
www.PDF-Zoo.com
Control and Frame Styles
Infinity Controller Programmer’s Guide C-29
Figure C-17. Frame Style 4
Title
www.PDF-Zoo.com
Control and Frame Styles
C-30 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com
Appendix D
Storing Areas/ Persons onInfinity CX 9000/CMX 220
Series Controlle rsThis appendix explains how you can determine the number of persons you can store on your Infinity CX 9000 series, CMX 220 series, or ACX 700 series controller if it is the access server.
www.PDF-Zoo.com
Persons Calculations
D-2 Infinity Controller Programmer’s Guide
Maximum Number of Person nel Obj ects per DeviceAndover Controls recommends that if you use a controller as the access server, you use one of those named in the table below. This table indicates the maximum number of personnel you can store on each type of controller that can be an access server.
Figure D-1. Maximum N umber of Personnel per Controlle r
The 240, 9001, and 9200 numbers are based on one user port.
Controller Memory Long Records Short Records
700 256 KB 427 1,500
780 1 MB 6,400
240 2 MB 1,300 3,600
9001 2 MB 1,300 3,600
9200 8 MB 5,000 15,000
Select Certain Cont roll erTypes for Ac cessServer
www.PDF-Zoo.com
Persons Calculations
Infinity Controller Programmer’s Guide D-3
Long Rec ords v s. Short Reco rds
What is a “short record”? A short record is one that includes only a basic set of personnel attributes that are required to define a person. The following is a list of the basic required attributes:
The list of areas the person is allowed in is also “required.” If you assign only these basic attributes, and leave all others empty, the personnel record is a “short record.”
A “long record” is one that includes any personnel attributes other than the basic attributes listed here.
Long Re cord v s. Short Records
NameCardTypeCardNumberPINSiteCodeStartDate (Activation Date)ExpirationDate
DepartmentCodeDuressEntryEgressTimeEnteredValue (Current Area)State
www.PDF-Zoo.com
Persons Calculations
D-4 Infinity Controller Programmer’s Guide
www.PDF-Zoo.com