Dataliner Message Display DL20 PLC Applications: Allen-Bradley
Dataliner Message Display DL20 PLC Applications: Allen-Bradley
Overview This document provides examples of interfacing a DL20 with PLC-2 and
PLC-5 Programmable Controllers through the DL20 parallel port.
Programming examples and connection diagrams show how to transfer
message triggers and variable data from 1771 I/O modules to the DL20
parallel port.
The examples and diagrams used in this appendix are included solely for
illustrative purposes.
PLC-2 The PLC-2 processor configuration for both examples is listed below. This
Programming Examples configuration may vary for different applications.
2. The “SEARCH 50” command configures the data table for 1 data table
block and 2 I/O racks. The Mini PLC-2/15 or Mini PLC-2/05 processors
automatically default to the 2 I/O rack configuration.
3. The output modules (2) are in Rack 1, module group 0 (word address
010).
Figure 1
Triggering Messages Using Individual Inputs (PLC-2)
057 010
G PUT Rung 1
001 001
If two or more inputs are true at the same time, the rung closest to the end of
the ladder diagram has priority and only this message is triggered during the
program scan.
When no inputs are true, the display clears since the 1st rung shown always
triggers special message #1 if none of the rungs after it are true. Special
message #1 clears the display. If your application requires that the last
message displayed remains displayed indefinitely, do not program the first
rung in this example. The DL20 Auto Clear message feature must be
disabled for this type of operation.
In this example, one rung is required for each unique message triggered.
The DL20 examines 10 bits (D0-D9) on the parallel port when a message
number is strobed in. If binary is selected, a range of message numbers
from 1 to 1022 is allowed. If BCD is selected, a range of message numbers
from 1 to 399 is allowed.
2
Installation Data
Dataliner Message Displays
DL20 PLC Applications
Rung 2
Triggers message 20 if input 112:00 is true and if rungs 3 and 4 are not true.
Rung 3
Triggers message 21 if input 112:01 is true and if rung 4 is not true.
Rung 4
Triggers message 22 if input 112:02 is true.
Bits 14 and 15 of words 057 through 062 must be set. The message numbers
stored in these words are entered while programming the GET instructions as
described below. Next, bit 14 and 15 are set using the “SEARCH 53”
command. Bits 14 and 15 correspond to the strobe terminals MS0 and MS1
on the DL20. Any other available bit addresses can be used for strobes (MS0
and MS1), however, the module outputs must be wired accordingly.
The GET instructions shown in Figure 1 have two additional bits set which
are not visible on the industrial terminal ladder diagram. These are bits 14
and 15. These outputs are connected to the MS0 and MS1 strobe bits on the
DL20 parallel port.
These outputs must be turned on along with any message number being
triggered. In this example, the message numbers stored in addresses 057,
060, 061, and 062 must also include bits 14 and 15 being set in each of those
words. This is done using the SEARCH 53 Data Manipulation instruction
after entering the GET instruction and the message number.
3
Installation Data
DataLiner Message Displays
DL20 PLC Applications
There are 10 data lines (D0-D9) and 2 strobe lines (MS0 and MS1) on the
DL20. If both MS0 and MS1 are high, it indicates to the DL20 that the value
present on the data lines D0-D9 is a message number to be triggered. At this
point all 10 data lines (D0-D9) are examined. If binary message data is
selected in the DL20 menu, the range is 1 to 1022. If BCD message data is
selected, the range is 1 to 399.
The DL20 displays variable data from the programmable controller within a
range of 0 to ±32, 767 binary or 0 to 9999 BCD. Because these are 16 bit
data values and the DL20 has only 10 data lines, each variable must be
strobed into the DL20 in two parts, 8 bits at a time. First the high byte is
strobed in. This is indicated by setting the strobe bit MS0 low and MS1
high. Next the low byte (least significant data) is strobed in to the DL20.
This is indicated by setting the strobe bit MS0 high and MS1 low.
The following program example uses a sequencer output instruction from the
PLC-2 to strobe the information into the DL20 parallel port.
4
Installation Data
Dataliner Message Displays
DL20 PLC Applications
Table A
PLC-2 Sequencer Outputs
BCD
PC Word Step Binary Format Comments
Format
Hi Data
041 3 2012 0010000000010010 (1st Variable)
Low Data
043 5 1034 0001000000110100 (1st Variable)
The NULL STEPS shown in the above sequence are added to satisfy timing
requirements of the DL20.
The variable 1234 shown on the above display and in the example steps is for
illustration purposes only. Actually, the free running timer 032 in the rung
examples to follow range from 0 to 999.
5
Installation Data
DataLiner Message Displays
DL20 PLC Applications
PLC-2 Figure 2 shows the example ladder program for transferring variable data
Programming Examples with a PLC-2.
Figure 2
PLC-2 Ladder Program (Messages with Variable Data)
031 030
SEQUENCER OUTPUT
COUNTER ADDR: 030 EN Rung 1
15 CURRENT STEP: 008 17
SEQ LENGTH: 008
WORDS PER STEP: 1 030
FILE: 037-046 DN
MASK: 035-035
15
OUTPUT WORDS
1: 010 2:
3: 4:
15
032 032
TON Rung 3
15 .01
PR 999
AC 000
030 034
G = ZCL Rung 4
012 002
032 043
Rung 5
00 00
032 043
Rung 6
01 01
032 043
Rung 7
02 02
032 043
Rung 8
03 03
032 043
Rung 9
04 04
032 043
Rung 10
05 05
6
Installation Data
Dataliner Message Displays
DL20 PLC Applications
Figure 2
PLC-2 Ladder Program (Messages with Variable Data) Continued
032 043
Rung 11
06 06
032 043
Rung 12
07 07
032 041
Rung 13
10 00
032 041
Rung 14
11 01
032 041
Rung 15
12 02
032 041
Rung 16
13 03
ZCL Rung 17
MASK: Select any available address and set all bits equal to 1 (035 for
this example).
OUTPUT WORD: I/O address at which the output modules for the DL20
are located (010 for this example).
7
Installation Data
DataLiner Message Displays
DL20 PLC Applications
PLC-2 Rung 2
Programming Examples This is the rung that actually triggers the message. Setting input address
111:14 momentarily will initiate one complete sequence, displaying the
message with variable data. If the application requires the variables to be
continuously updated on the display, then, address 111:14 should be set
high continuously for that period of time.
Timer 031 determines the time between step changes. This time should
not be set lower than 70 milliseconds per step for AC output module
applications using a Parallel Input Converter (2706-NG1, -NG2,
Series A or B).
Rung 3
A free-running timer is used to create the data value being displayed.
Rung 4
This rung and rung 17 assure that both the high byte and low byte data
portion of the variable are both moved to the appropriate word in the
sequencer file at the same time. Otherwise, the timer value could change
between the time that the high byte and low byte are strobed to the DL20.
The GET instruction (address 030) is the same address used for the
sequencer instruction and contains the current “step number”. The equal
instruction (address 034) could have been any available address and must
store a constant (2 in this case), so that rungs 5-16 will only be scanned
and updated once per sequencer cycle. Any step can be selected,
however, step 2 is the last step prior to the variable data being sent to the
DL20.
Rungs 5-12
Transfer the low byte data from timer 032 accumulative value to the
appropriate sequencer step (word 043).
Rungs 13-16
Transfer the high byte data from timer 032 accumulative value to the
appropriate sequencer step (word 041).
Rung 17
Marks the end of the zone to be controlled according to rung 4.
8
Installation Data
Dataliner Message Displays
DL20 PLC Applications
PLC-5 Programming The PLC-5 processor configuration used for both examples is listed below.
Examples This configuration may vary for different applications.
1. An Allen-Bradley 1784-T45 Industrial Computer is used.
2. The Data Monitor command is used to configure the sequencer table.
3. Two output modules in Rack 0, module group 0 (O:000).
4. The DL20 is defined as follows:
• high true logic
• binary message/variable data
• time driven
• DC inputs
• scan = 4, debounce = 1
Figure 3
Triggering Messages Using Individual Inputs (PLC-5)
CPT
COMPUTE Rung 1
Dest O:001
1298
Expression
N7:0
B3 CPT
COMPUTE Rung 2
1 Dest 0:001
12298
Expression
N7:1
B3 CPT
COMPUTE Rung 3
2 Dest: 0:001
12298
Expression
N7:2
B3 CPT
COMPUTE Rung 4
3 Dest: 0:001
12298
Expression
N7:3
9
Installation Data
DataLiner Message Displays
DL20 PLC Applications
PLC-5 Programming When no inputs are true, the display clears since the 1st rung shown always
Examples triggers special message #1. If your application requires that the last
message remains displayed indefinitely, do not program the first rung.
The DL20 Auto Clear message feature must be disabled for this type of
operation.
The DL20 examines 10 bits (D0-D9) on the parallel port when a message
number is strobed in. If binary message data is selected, a range of unique
message numbers from 1 to 1022 is allowed. If BCD message data is
selected, a range of unique message numbers from 1 to 399 is allowed.
Rung 2
Triggers message number 20 if input B3:1 is true and if rungs 3 and 4 are
not true.
Rung 3
Triggers message number 21 if input B3:2 is true and if rung 4 is not true.
Rung 4
Triggers message number 22 if input B3:3 is true.
Complete Instruction
The CPT instruction will get all 16 bits of the designation source word and
move it into the designated destination word. This instruction may also be
substituted with a MOV (move) or MVM (move with mask) instruction.
10
Installation Data
Dataliner Message Displays
DL20 PLC Applications
There are 10 data lines (D0-D9) and 2 strobe lines MS0 and MS1 on the
DL20. If both MS0 and MS1 are high, it indicates to the DL20 that the value
present on the data lines D0-D9 is a message number to be triggered. At this
point, all 10 data lines (D0-D9) are examined. If binary message data is
selected, then the range is 1 to 1022. If BCD message data is selected, then
the range is 1 to 399.
The DL20 displays variable data from the programmable controller within a
range of 0 to ±32, 767 binary or 0 to 9999 BCD. Because these are 16 bit
data values and the DL20 has only 10 data lines, each variable must be
strobed into the DL20 in two parts, 8 bits at a time. First the high byte is
strobed in. This is indicated by setting the strobe bit MS0 low and MS1
high. Next the low byte (least significant data) is strobed in to the DL20.
This is indicated by setting the strobe bit MS0 high and MS1 low.
The following program example uses a sequencer output instruction from the
PLC-5 to strobe the information into the DL20 parallel port.
11
Installation Data
DataLiner Message Displays
DL20 PLC Applications
N7:1 0000 0011 0000 1010 1 1 1 0000 1010 10 Special Msg #10
clears DL20 queue.
N7:2 0000 0010 0000 0001 2 1 0 0000 0001 1 High Byte for variable
data = 256.
N7:3 0000 0001 0001 1111 3 0 1 0001 1111 31 Low Byte for variable
data = 31.
The variable 287 on the above display is the accumulated value for T4:1, free
running timer.
12
Installation Data
Dataliner Message Displays
DL20 PLC Applications
Figure 4
PLC-5 Ladder Program (Messages with Variable Data)
T4:0 SQO
SEQUENCER OUTPUT (EN)
Rung 2:0 File #N7:0
DN Mask 03FF (DN)
Dest O:002
Control R6:0
Length 4
Position 0
T4:0 TON
TIMER ON DELAY (EN)
Rung 2:1 Timer T4:0
DN Time Base 0.01 (DN)
Preset 3
Accum 1
T4:1 TON
TIMER ON DELAY (EN)
Rung 2:2 Timer T4:1
DN Time Base 1.0 (DN)
Preset 1250
Accum 287
MVM
Rung 2:3 MASKED MOVE
Source T4:1.ACC
287
Mask 00FF
Dest N7:9
31
BTD
Rung 2:4 BIT FIELD DISTRIB
Source T4:1.ACC
287
Source bit 8
Dest N7:10
1
Dest bit 0
Length 8
MVM
Rung 2:5 MASKED MOVE
Source N7:10
1
Mask 00FF
Dest N7:2
513
MVM
Rung 2:6 MASKED MOVE
Source N7:9
31
Mask 00FF
Dest N7:3
287
(END OF FILE)
13
Installation Data
DataLiner Message Displays
DL20 PLC Applications
Rung 2:1
Timer T4:0 is a free running timer which drives the SQO. A preset value
of 3 provides a pulse every 30 msec.
Rung 2:2
Timer T4:1 is a free running timer which generates the variable data for
the DL20.
Rung 2:3
Masks off the low byte data from T4:1.ACC and moves it to lower byte of
N7:9. The low byte data is now in a format that can be output to the
DL20 data lines (D0 through D7).
Rung 2:4
Transfers or distributes the high byte of T4:1.ACC to the lower byte of
N7:10. The high byte data is now in a format that can be output to the
DL20 data lines (D0 through D7).
Rung 2:5
Takes the high byte data at N7:10 and moves it to N7:2 for use with the
SQO. The upper byte of N7:2 is preloaded with the correct bit pattern to
control the strobe lines using the Data Monitor. This has the effect of a
logic OR for the changing high byte variable data and the constant strobe
bit settings.
Rung 2:6
Takes the low byte data at N7:9 and moves it to N7:3 for use with the
SQO. The upper byte of N7:3 is preloaded with the correct bit pattern to
control the strobe lines using the Data Monitor. This has the effect of a
logic OR for the changing low byte variable data and the constant strobe
bit settings.
14
Installation Data
Dataliner Message Displays
DL20 PLC Applications
DL20 Parallel Port The following parameters are configured within the SET PARALLEL PORT
Configuration menu of the DL20.
Selecting Y (yes) means that the DL20 is expecting the parallel inputs to be
high (ON) when a logic 1 is represented.
Selecting N (no) means that the DL20 is expecting the parallel inputs to be
low (OFF) when a logic 1 is represented.
Selecting Y (yes) means that the DL20 will expect message triggers in a
binary format. (Binary format works well with the PLC-5)
Selecting N (no) means that the DL20 will expect message triggers in a BCD
format. (BCD format works well with the PLC-2)
Selecting Y (yes) means that the DL20 will expect variable data to be
strobed in a binary format.
Selecting N (no) means that the DL20 will expect variable data to be strobed
in a BCD format.
Selecting Y (yes) means that all parallel port data will be sampled
automatically at a rate determined by the SCAN TIME. If DC parallel port
operation was selected the user is also prompted for DEBOUNCE TIME.
Selecting N (no) means that the user wishes to use the edge triggered strobe
(ETS) input to strobe all data into the parallel port. The user is then
restricted to a DC voltage interface and must select “high to low” or “low to
high” edge sensing for the ETS input. The ETS lines of the DL20 are
provided for use with other manufacturers programmable controllers having
output modules with strobe lines.
15
Installation Data
DataLiner Message Displays
DL20 PLC Applications
Important: You must be sure that data (each step) is present on the parallel
port for at least the scan rate.
Variable Data For AC parallel interface applications using Parallel Input Converters
Update Times (Catalog No. 2706-NG1, -NG2 Series A or B), data should be present (each
step of sequencer) at the parallel port for at least 180 milliseconds.
To determine update time, multiply the time interval between sequencer steps
by the number of sequencer steps. In the PLC-2 variable data example, timer
031 in rung 2 determines the time interval between steps. For a setting of
PR010 (100 milliseconds), the update time for the variable data in this
example of 8 steps, will be 800 milliseconds (100 ms x 8).
16
Installation Data
Dataliner Message Displays
DL20 PLC Applications
Parallel Interface The following connections are applicable to the program examples shown
Connections previously.
The standard voltage levels required for the DL20 parallel port are 5 to 30
VDC. When using DC Output Modules, an external power supply of the
appropriate voltage level and current capacity is required.
17
Installation Data
DataLiner Message Displays
DL20 PLC Applications
Figure 5
Parallel input Converter to AC Output Module
AC
D9 D8 D7 D6 D5 D4 D3 D2 D1 DO MS1 MS0 COM
120
VAC AC NEU
Parallel Input
Conveter Terminals HOT PWR
00-07 10-17
A A
0 0
1 1
2 2
3 3
4 4
5 5
6 6
7 7
8 8
18
Installation Data
Dataliner Message Displays
DL20 PLC Applications
Figure 6
DL20 to DC Output Module (Catalog No. 1771-OB, -OG)
00-07 10-17
A A
0 0
1 1
2 2
3 3
4 4
5 5
6 6
7 7
8 8
Important Note: The 1771-OG TTL output modules 5VDC signals are
more noise susceptible than 12-24 DC signals. In applications where noise
may be a problem, it is strongly recommended that a 1771-OB DC output
module be used.
19
Installation Data
DataLiner Message Displays
DL20 PLC Applications
Figure 7
DL20 to High Density DC Output Module (Catalog No. 1771-OBD)
DL20 Terminals
Publication No. 2706-2.21 – June 1993 1993 Allen-Bradley Company, Inc. Printed in U.S.A.
20