884 Prog Controller Programming Guide
884 Prog Controller Programming Guide
MODICON
PI-884A-001 Rev C
Modicon
884 Programmable Controller
PROGRAMMING GUIDE
SUBJECT: Instructions for using the 884 Programmer and Configurator Tape (AS-T884-001)
with the Modicon P190 Programmer and the 884 Programmable Controller.
June, 1989
Modicon, Inc.
One High Street
No. Andover, Massachusetts 01845
PREFACE
This guide contains information on the configuration, programming and use of the
884 Programmable Controller.
The information in this document is subject to change without notice and should
not be construed as a commitment by Modicon, Inc., Industrial Automation Systems.
Modicon, Inc., assumes no responsibility for any errors that may appear in this
document. No part of this document may be reproduced in any form without the
express written permission of Modicon, Inc., Industrial Automation Systems. All
rights reserved.
Page
SECTION 4 - PC OPERATIONS
..*
III
SECTION 5 - CONFIGURING THE 884 PC
iv
6.10.1 Read Network (READ NET) ........................................... 6-25
6.10.2 Create Network (CREATE NET) ........................................ 6-25
6.10.3 Delete Network (DEL NET) ............................................ 6-26
L
‘ 6.10.4 Replace Network/Insert Network (REPL NETIINSRT NET) ................. 6-26
6.10.4.1 Replace Network (REPL NET) ....................................... 6-26
6.10.4.2 Insert Network (INSRT NET) ........................................ 6-26
6.105 Exchange Network/Flip Stack (EXCH NET/FLIP STACK) .................. 6-27
6.10.6 Expand/Compress (EXPICOMP) ........................................ 6-28
6.10.7 Edit Network (EDIT NET) ............................................. 6-29
6.10.8 Previous Network/Next Network (PREV NET/NEXT NET) .................. 6-29
6.11 CHANGE SCREEN HARDWARE KEY (CHG SCREEN) ........................ 6-29
6.11.1 Drum Display Screen (DRUM DSPLY). .................................. 6.29
6.11.3 Logic Area of the Network Screen (LOGIC) ............................. 6-30
6.11.4 Full Reference Screen (FULL REF) ..................................... 6-31
6.11.4.1 Get Column/Get Reference (GET COLIGET REF) ....................... 6-31
6.11.4.2 Previous Reference/Next Reference (PREV REFlNEXT REF) ............. 6-32
6.11.4.3 Erase Column/Erase Reference (ERASE COL) ......................... 6-32
6.11.4.4 Display Hexadecimal/Display Decimal (DISP HEX/DISP DEC) ............ 6-32
6.11.4.5 Display ASCII/Display Binary (DISP ASClI/DISP BIN .................... 6.33
6.11.4.6 Set All/Set Bit (SET ALL/SET BIT). ................................... 6.33
6.11.4.7 Clear All/Clear Bit (CLEAR ALL/CLEAR BIT). .......................... 6-33
6.11.4.8 Plus/Minus (PLUS/MINUS) .......................................... 6-34
6.11.4.9 Enable/Disable (ENABLE/DISABLE) .................................. 6-34
6.11.4.10 Force On/Force Off (FORCE ON/FORCE OFF ......................... 6-34
6.115 Partial Reference Area of Network Screen (PART. REF). .................. 6-34
6.11.6 Search Display (SRCH DSPLY) ........................................ 6-35
6.12 LOGIC EXAMPLE ....................................................... 6-36
APPENDIX D - GLOSSARY
FIGURES
vi
4-l PC Operations Software Label Key Flow Char1 4-2
4-2 Initialize Table Screen . . . . . . . . . . . . . . . . . . . . . 4-4
vii
10-l SKIP .................................................................. 10-2
10-2 Status OK Logic.. ...................................................... 10-3
10-3 Get Controller l/O Status ................................................. 10-4
10-4 Single to Double Precision Conversion .................................... 10-6
10-5 Double to Single Precision Conversion .................................... 10-7
...
VIII
TABLES
ix
SECTION 1
INTRODUCTION
This manual provides instructions for using the Modicon 884 Programmable
Controller. The 884 PC offers a replacement for relays and solid state electronics,
and performs many types of control functions in a variety of industrial
environments. The 884 PC provides basic relay replacement, diagnostic
monitoring, data collection and storage, and report generation. Easy to learn
ladder logic is used to program the 884 PC via the P190 Programmer.
The 884 PC offers a minimum of 2K words of user logic and 1K registers, as well
as 256 discrete I/O points in any mix, and additional analog/register capacity. The
884/P190 combination provides powerful editing tools and high security bus
protocol.
Section 2 describes the P190 Programming Panel, tape drive, Memory Protect
function and CRT screen. Section 3 explains the Power-Up and Attach levels of the
884 ProgrammerlConfigurator Tape. Section 4 describes the operating functions
that can be accessed through the PC Operations Menu and Section 5 describes
how to configure the 884 PC. Section 6 provides an introduction to ladder logic and
programming and Section 7 introduces basic programming and arithmetic
functions. Section 8 describes the data transfer move functions, and the
sequencer function. Data transfer matrix functions are explained in Section 9 and
special functions are described in Section 10. The Appendices contain the Error
Message definitions, Password Operations and PC Memory Error function.
l-l
SECTION 2
THE Pi90 PROGRAMMER
This section describes the Modicon P190 Programmer. The P190 Programmer is
used to program and configure the 884 PC. For additional P190 information, not
884 PC specific, consult the Modicon P190 Programmer User’s Manual.
2.1 KEYBOARD
The P190 keyboard has four sections: alphabetic keys, numeric keys, function keys
and software label keys. See Figure 2-1. All of the cursor and function keys are
used, except for the CHG NODE and EXIT keys.
2-1
THE P190 PROGRAMMER
0CLEAR
ERROR
nnn
2-2
THE P190 PROGRAMMER
There are eight available labels, alternating white and black blocks at the bottom
of the screen. These labels correspond to the eight software label keys on the top
row of the P190 keyboard, just below the screen as shown in figure 2-5. These are
blank keys, alternating grey and white, corresponding to the software labels above
them. The black software label matches the grey software label key beneath it, and
the white software label matches the white software label key beneath it.
The software label keys change with each new function. All software labels which
use two lines are dual function keys. The bottom function is activated by pressing
the corresponding software label key. To activate the top function, the software
label key must be pressed simultaneously with one of the SHIFT keys.
00000000
Figure 2-5. Software Label Keys
When this key is pressed, the whole keyboard is in SHIFT position and the word
SHIFT appears in the lower left of the P190 screen. Once another key is pressed,
the SHIFT LOCK is released. If this SHIFT key is pressed and then is not needed,
press the key again to return to the normal keyboard.
Tapes are used to load software programs into the P190 and user logic into the 884
PC. You can also copy and save software programs using the Tape Loader Tape.
For more information see the 884 PC Tape Loader User’s Guide.
To insert a tape, hold it so that the metal plate is on the underside and the exposed
tape is toward the tape drive. Insert the tape and press firmly until the tape clicks
into place. To remove the tape, open the door to the tape drive and press the eject
pushbutton.
P1901884 PC tapes use software overlays. Leave the tape in the drive, because the
P190 will be rereading it from time-to-time.
2-3
THE PI90 PROGRAMMER
NOTE
If this key is in the Lock position (see Figure 2-7a), the PI90 is in Monitor mode.
In Monitor mode you can examine any information in the PC, but you cannot
change any portion of the PC’s memory, or start or stop the PC.
If you attempt to Attach to a password protected P1901884 PC, the Password Ops
screen appears and asks for the correct password. If you do not know the
password, turn the Memory Protect key on the P190 to the Lock (Monitor Mode)
position. Monitor Mode redisplays the ATTACH screen. Press the ATTACH
software label key to examine any information in the PC. In Monitor Mode you
cannot make any changes in the PC’s memory, but you can still search and display
logic and l/O configurations already there.
If the key is in the Unlock position (see Figure 2-7b), the P190 is in Program mode.
In Program mode you can examine and change any information in the PC’s
memory, and START or STOP the PC.
NOTE
If the key switch changes during an operation, the system will return to the Power-
Up, ATTACH, level (See Section 3.1).
2-4
THE P190 PROGRAMMER
BAUD RATE
PARITY/NO PARITY
EVEN/ODD PARITY
718 BITS PER CHARACTER
112 STOP BITS
The left set of switches is dedicated to PORT 1 and are used to communicate with
the designated controller. The right set of switches is dedicated to PORT 2 and are
generally used for output communications to a printer. The settings for each of
these ports are as follows: 1 = UP and 0 = DOWN. Table 1 gives the switch
settings for the peripheral port parameters.
NOTE
2-5
THE PI90 PROGRAMMER
Port Settings:
Baud Rate Sl s2 s3 s4
Parity EnalDis s5
Parity Select (Odd/Even) S6
Stop Bits (l/2) s7
Data Bits (718) S8
Sl s2 S3 S4 S5 S6 S7 S8
Baud Rate: Sl s2 s3 s4
19200 - 1 1 1 1
9600* - 1 1 1 0
7200* - 1 1 0 1
4800* - 1 1 0 0
3600* - 1 0 1 1
2400* - 1 0 1 0
2000* - 1 0 0 1
1800* - 1 0 0 0
1200* - 0 1 1 1
600* - 0 1 1 0
300* - 0 1 0 1
150* - 0 1 0 0
134.5* - 0 0 1 1
110* - 0 0 1 0
75 - 0 0 0 1
50 - 0 0 0 0
Parity ENAIDIS: s5
parity enable 1
parity disable 0
Parity Select: S6
even parity 1
odd parity 0
Stop Bits: s7
1 stop bit 1
2 stop bits 0
Data Bits: S8
8 data bits 1
7 data bits 0
The 884 PC factory settings for Modbus port 1 are: RTU mode, parity enabled, one
stop bit, 9600 baud.
2-6
SECTION 3
POWER-UP AND OPERATION LEVELS
This section describes the Power-Up and Operation Levels. After the P190
Programmer is turned on, a simple diagnostic test is automatically run. During the
test a variety of patterns appear on the CRT. When the test ends a message
appears on the CRT that tells you to load the Programmer and Configurator Tape.
I I EVALTAPE AlTACH
The AR (Assembly Register) automatically displays the unit number 1. This value
is the address, or PC unit number of the 884 PC communicating with the P190. Use
this number or enter the applicable number and press the ATTACH software label
key.
3-1
POWER-UP AND OPERATION LEVELS
P1901884 - OPERATIONS
PC OPERATIONS
PC STOPPED
PCOF’S PROGRAM
NOTE
3-2
POWER-UP AND OPERATION LEVELS
If the START PC software label key is pressed while the controller is running, this
message appears on the screen:
ERROR: PC RUNNING.
If the CLEAR PC software label key is pressed, PC Memory menu appears (See
Section 4.1). The PC CONFIG software label key displays the configuration table
and the OPERS software label key redisplays the PC Operations Menu (Figure 3-2).
The functions available by pressing the PC OPS software label key are explained
in Section 4.
NOTE
NOTE
You will notice, that after you press many of the software
label keys, a screen appears that displays the PROCEED
and CANCEL software labels. Press the PROCEED software
label key to begin the procedure or press the CANCEL
software label key to stop it and return to the most recently
used screen.
3-3
SECTION 4
PC OPERATIONS
This section describes the operating functions that can be accessed from the PC
Operations menu. Each software label key, and what it does is discussed. A flow
chart illustrating these software labels is shown in Figure 4-1.
Press the PC OPS software label key and the following software labels appear on
the screen:
I
I
ALL MEM
I
I
USER LOG
I
I
REGISTERS
I
I
EN COIL
I
I
EN DISC
I
1
EVAL TABLE
I
I
I
I
PREV MENU
I
I
Memory Protect must be OFF to Clear memory. If it is not OFF, this message
appears: MEMORY PROTECT IS ON.
4-1
PC OPERATIONS
4-3
PC OPERATIONS
P1901884PC
OPERATIONS-INITIALIZE
TABLE
RECOMMENDEDACTIONS:
ALL TABLESVALID
AR: 00000
PCSTOPPED
ALLMEM INITTABLE
I
The software labels on this screen are ALL MEM, INIT TABLE, and PREV MENU.
If all tables are as they should be, the message, ALL TABLES VALID, appears on
the screen, beneath RECOMMENDED ACTIONS.
If you need to initialize all memory, press the ALL MEM software label key. To
initialize an individual table, enter the applicable letter, A, B or C in the AR and
press the INIT TABLE software label key. Repeat this process, one table at a time
until all recommended tables have been initialized. Remember, the PC must be
STOPPED in order to perform any of these functions.
4.2 PC CONFIG
Press the PC CONFIG software label key, to bring up the software labels UPDATE,
SET SCAN and SET PORT. These software label keys are used to set the scan and
communication parameters.
4-4
PC OPERATIONS
Press the CONSTANT software label key to enter a constant scan time. Enter a
scan time between 1 and 195 milliseconds in the AR and press the ENTER key.
These keys are used to set the communication parameters for the Modbus port on
the 884 PC. The parameters are set in 884 PC memory and the MEM/DIP switch
(located behind the battery access cover on the 884 PC) must be set on MEM
position.
4.2.3.1 RTUIASCII
This software label key selects the Modbus communication mode - RTU or ASCII.
Press the Remote Terminal Unit (RTU) software label key and the SHIFT key for
RTU mode. This mode is generally used to communicate between the 884 PC and
the P190 programmer. It can also be used for other Modbus communications.
Press the ASCII software label key (without the SHIFT key) for ASCII. ASCII
(American Standard Code for Information Interchange) mode is used for Modbus
communications.
4-5
PC OPERATIONS
50, 75, 110, 134.5, 150, 300, 600, 1200, 1800, 2000, 2400, 3600,
4800, 7200, 9600, or 19200.
Press the BAUD RATE software label key to enter the value.
NOTE
The P190 itself cannot communicate at 19200 baud and/or
in ASCII code, but can set the PC to do so for use with other
devices.
4.3 DEVICE ADDRESS
The Device Address is a field displayed on the 884 PC Configuration Table screen.
It is set via a switch on the 884 PC. It is not possible to enter a Device Address
using software.
On the initial configuration, the controller defaults to the device address of 001.
4.4 DETACH
Press the DETACH software label key to terminate communications between the
P190 and the 884 PC. The P190 cannot program the 884 PC if it is not attached to
it. The ATTACH software label key is displayed on the screen.
4-6
SECTION 5
CONFIGURING THE 884 PC
This section describes how to configure the 884 PC. The 884 PC must be
configured to your system requirements before it can be programmed. The 884 PC
System Planning and Installation Guide describes basic system requirements and
general configuration guidelines that must be completed before the Traffic Cop
can be configured.
PCRUNNING
5-l
CONFIGURING THE 884 PC
Press the l/O CONFIG software label key to display the number of the l/O channel
to be configured. Only one channel can be configured in the initial release of the
884 PC. Future releases will have the capability of more configured channels.
Figure 5-3, l/O Channels Configured screen, displays software label keys that are
described in this section. In Programmer Mode, key in the number of l/O channels
to be configured in the AR, and press ENTER. (If you are in Monitor Mode. you can
only display and examine the information).
To build a Traffic Cop, the 884 PC must be stopped. If the PC is running you can
read the I/O modules and the reference numbers, but cannot make any changes.
AR: 00000
KEY IN TOTAL NUMBER OF l/O CHANNELS INTO AR, PRESS ENTER
5-3
CONFIGURING THE 884 PC
CHANNEL #: 01 RACK#: 01
L GETCHNLWRITE
CHN
Up to 11 slots of configuration information can be displayed for one rack. All slots
with a module installed, or all slots, up to the highest number configured, are
displayed. If a slot has not been configured, or has no module installed, “B8”
appears for the MODULE TYPE. A brief description of each field on the l/O Channel
Traffic Cop screen is given below.
5.2.2 CHANNEL #
This is the number of the channel currently displayed on the CRT. You can have
up to 32 fully configured l/O slots per channel, divided between a maximum of five
racks.
5.2.3 RACK #
This is the number of the rack of l/O a!ots currently displayed on the CRT.
5.2.4 SLOT #
This number indicates the physical location of a module for a specific channel.
The number format is “RSS”. The “R” is the rack number and the “SS” is the
number of the specific slot within the rack. It can be any number from 1 through 11.
5-4
CONFIGURING THE 884 PC
The configured module type can be input by the user or read from the existing
module in that slot. If you choose to enter the module type, the cursor must be on
the “MODULE TYPE” field and the number entered must be between 6802 and
B899. The following prompt will appear at the bottom of the CRT screen when the
cursor is positioned on this field: KEY IN MODULE NUMBER (02 TO 99) AFTER B8,
PRESS ENTER. “B8” always is displayed for a new slot; only the last two digits
have to be entered. As soon as the ENTER key is pressed, the number is validated.
Moving the cursor before pressing the ENTER key causes an error message
(ERROR: ILLEGAL MODULE TYPE.) If an invalid module number is entered, an error
will appear at the bottom of the CRT screen.
Any module number can be configured in any slot. Inputs or outputs, 8 or 16 points,
can be put in any location, in any mix, up to the limitations of the system.
When you enter an l/O module number on the screen, it will appear highlighted if
it does not match what is in the actual rack. If an asterisk (*) appears with a module
number on the screen, it means this number was supplied to the 884 PC by the l/O
module already installed in the slot. If you enter a module number that differs with
the one shown, that number will be highlighted to indicate that a mismatch exists.
The configurator allows you to put the modules wherever you want, but it warns
you if your configuration disagrees with what is physically in the slots.
If you enter an invalid number in the module type field, the cursor remains on the
last digit entered. Press the RUBOUTlBACKSPACE key to move the cursor and
enter a new, valid module number.
When entering the module type, the maximum number of I/O points for input or
output for a channel cannot be exceeded. If this occurs, an error appears (ERROR:
MAX OUTPUT/INPUT LENGTH OF 512 l/O POINTS EXCEEDED). More than 32 slots
cannot be entered or an error appears (ERROR: MAX OF 32 ENTERED SLOTS
EXCEEDED).
The configured module type must be entered before the cursor can be moved to
this area. When the cursor is at the REFERENCE NUMBER field, the following
prompt appears at the bottom of the screen: KEY IN APPROPRIATE REFERENCE
FOR MODULE (TYPES 0,1,3,4). After the reference number is entered, press the
ENTER key. This validates the reference number. If an invalid reference number
was entered, the entry will stay on the screen with the cursor positioned at the last
digit entered. Use the RUBOUTIBACKSPACE key to move the cursor and change
an invalid reference number.
5-5
CONFIGURING THE 884 PC
For illegal reference numbers the following error is displayed, ERROR: INVALID
REFERENCE NUMBER OR ILLEGAL REFERENCE TYPE.
For discrete references the starting reference must be at a byte boundary (multiple
of 8 plus 1). If not, an error is displayed at the bottom of the CRT screen, (ERROR:
DISCRETE REF MUST START ON A MULTIPLE OF 8 PLUS 1).
Reference numbers point to the range of memory in the PC for receiving or sending
data for the l/O modules. A caution message is displayed and a confirmation is
required when specifying any reference numbers already used in the l/O
Configuration. This is not an error.
NOTE
No continual checking of what is out in the field occurs
when this table is displayed or modified. Information is only
fetched from the controller when a new channel of
information is displayed. If modules are changed while
looking at a channel, the changes will not be seen until that
channel is re-displayed.
To edit the l/O Channel Traffic Cop, the cursor is moved to the applicable entry.
Use the cursor position keys on the P190 keypad to move the cursor to the
appropriate place.
If the slot is empty, or if changes are to be made to a current module type, only
the two “XX” digits (of the B8XX Configured Module type) and the appropriate
reference numbers are entered. The cursor moves one character to the right each
time data is entered.
When you have finished configuring the 884 PC, press WRITE CHNL software label
key in order to save the TRAFFIC COP in the 884 PC. If WRITE CHNL is not pressed
the TRAFFIC COP will not be saved.
5-6
CONFIGURING THE 884 PC
The software label keys that appear on the I/O Channel Traffic Cop screen are
described below.
5.3.1 HELP
Press this software label key to access four HELP screens for the l/O configuration
table. These screens provide most information required to do a configuration. They
are there to help you when a manual is not available.
When the key is pressed, I/O configuration information appears on the screen
along with the software labels NEXT HELP and TC SCRN (Traffic Cop screen).
To continue reading information, press NEXT HELP. The second screen of l/O
information appears on the CRT screen. To reach the third screen, press NEXT
HELP again. The fourth and final screen is reached by pressing NEXT HELP again.
If the NEXT HELP software label key is pressed when the fourth HELP screen is
displayed, the first HELP screen reappears.
To return to the l/O configuration table from any of the four menus, press TC
SCRN.
5.3.2 BlNARYlBCD
When references are entered into the Reference Number Field on the P190 screen,
the data type defaults to BIN (binary) for 3XXXX and 4XXXX references and to DISC
(discrete) for OXXXX and 1XXXX references.
To convert the register data type from binary to BCD,(Binary Coded Decimal),
position the cursor on the appropriate configured slot and press the BCD software
label key. To change the type back to binary, press BINARY software label key with
the SHIFT key. Binary conversion is allowed for 4 point discrete l/O modules
configured as register references, but not BCD conversion.
The first three slots in rack number 1 of each channel in the Traffic Cop are
reserved for the power supply and mainframe CPU modules. They are slots 101,
102, and 103.
Each channel has a maximum of 32 configured slots distributed among five racks.
Slot information can be entered, beginning at the fourth slot. To enter new data,
press the NEXT SLOT software label key. A message appears on the prompt line:
KEY IN MODULE NUMBER (02 to 99) AFTER B8, PRESS ENTER KEY.
You must use the NEXT SLOT software label key to create a new slot. NEXT SLOT
can also be used to move between existing slot information.
Press the DEL SLOT software label key with the SHIFT key to delete the slot
information currently at the cursor position. This is the DELETE SLOT function.
5-7
CONFIGURING THE 884 PC
Press the PREV RACK software label key with the SHIFT key to gain access to the
information for the rack before the rack currently displayed (the current rack minus
one). This is the Previous Rack function.
Press the NEXT RACK software label key to gain access to the information for the
rack immediately following the rack currently displayed. This is the Next Rack
function.
Press the PREV CHNL software label key with the SHIFT key to gain access to the
slot configuration information for the channel before the channel currently
displayed (the current channel minus one). This is the Previous Channel function.
To gain access to the information for the channel after the channel currently
displayed, press the NEXT CHNL software label key, without the SHIFT key. This
is the Next Channel function.
When the GET CHNL software label key is pressed, the message “KEY IN
CHANNEL # INTO THE AR FOR SLOT INFORMATION, PRESS ENTER KEY”
appears on the prompt line of the P190 screen. Enter a channel number in the AR,
1 through highest configured channel number only, and press the ENTER key.
All the information for rack 1 of the selected channel is displayed. To examine or
modify other racks within the same channel, use the PREV RACK/NEXT RACK
software label key. The PREV CHNLINEXT CHNL software label key is used to
move to another channel. The PREV MENU software label key returns you to the
l/O Channels Configured screen.
5-8
CONFIGURING THE 884 PC
If the WRITE CHNL and PROCEED software label keys are not pressed the new
configuration information is not received by the PC.
5.5 HEALTH
Press the HEALTH software label key, while the controller is running, to see if
individual modules are functioning as they should and agree with the modules
configured in the Traffic Cop.
If you configured the system to match the l/O Modules in the rack, and the PC is
running, all the active lights on the front of the l/O Modules should be on. If not,
a slot has been misconfigured, or there is a defective module.
If all the active lights are on, press the HEALTH software label key. If the Traffic
Cop matches the active modules the following message appears on the screen:
MODULES OK FOR THIS CHANNEL. (See Figure 5-5).
If a module does not match or is defective, it will be listed on the HEALTH screen
as UNHEALTHY.
This command makes it easy to check the configuration and to troubleshoot the
system.
UPDATE PREVMENU
5-9
CONFIGURING THE 884 PC
55.1 UPDATE
Press the UPDATE software label key to update the currently displayed health
information.
NOTE
5-10
CONFIGURING THE 884 PC
Press the l/O CONFIG software label key on the Configurator Menu. The next
screen to appear is the l/O Channels Configured screen (Figure 5-3).
Press the TRAF COP software label key and the I/O Channel Traffic Cop screen
(Figure 5-4) appears.
To configure Input Module B805-016,115 VAC 16 PT, move the cursor to the Module
Type column next to Slot 104. B8* is already displayed on the screen, enter 05 and
press the ENTER key. Notice that as soon as you press ENTER, the 884 PC
automatically displays the appropriate Module Description, 115 VAC 16-IN.
The cursor is now at the Reference Number field. A message is displayed at the
bottom of the screen: KEY IN APPROPRIATE REFERENCE FOR MODULE (TYPES
1,3) Key in 10001 and press ENTER. The 884 PC completes the entry with the
correct number of input addresses, in this case, 10016. It also displays DISC for
Data Type.
If you keyed in 30001, for example, the 884 PC completes the entry and displays
BINARY for Data Type. You can change BINARY to BCD, (Binary Coded Decimal),
by pressing the BCD software label key.
To configure a B804 Output Module, press the NEXT SLOT software label key (or
you can use the Down Arrow cursor key). Key in 04 and press ENTER.
Now the cursor has moved to the Reference Number field, and the message at the
bottom of the screen, again, displays the appropriate references for this module.
Key in 00001. The 884 PC completes the entry and displays DISC for Data Type.
If, for example, you keyed 40001 in the Reference Number field, the 884 PC
automatically completes the entry and displays BINARY in the Data Type field.
Press the WRITE CHNL software label key to save the channel you just configured.
You now have a choice to PROCEED or CANCEL. Remember, if you want to save
this channel you must press WRITE CHNL, followed by PROCEED. If you do not
want to save it, after pressing WRITE CHNL, press CANCEL.
5-l 1
SECTION 6
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
This section provides the information necessary to create, read, delete, and insert
networks as well as edit individual networks. It also describes how to use the
reference screens and the search function.
This section also describes the basic ladder logic used in programming the 884
PC. The logic elements used include relay contacts, coils, references, registers,
and function blocks. The controller’s logic is structured into networks, and
programmed into the 884 PC via a P190 Programmer. The controller scans each
network and solves the logic which controls the input to other logic in the program,
or controls an output (i.e., turning ON a switch, stopping a process, resetting a
meter, etc.).
The P190 Programmer is organized into two logic editing modes; the Element
Editor and the Network Editor. Both editing modes use a series of P190 display
screens and software labels. Instructions on how to use the editing modes and the
appropriate software labels are also covered in this section.
1. Insert the 884 PC Programmer and Configurator Tape into the P190 tape drive.
(The 884 PC must be configured to meet your specifications before a program
will run as programmed. Section 5 provides the configuration and Traffic Cop
information needed to accomplish this).
NOTE
Leave the tape in the drive. The P190 rereads the tape from
time to time.
This is the Attached Level. These software label keys are used to change the
884 PC’s status. (If passwords have been used, the Password Level is next,
not Attached Level. See Appendix C for Password Operation instructions.)
3. Press the PROGRAM software label key and then the PROCEED software
label key. (A thirty second delay occurs while the programming instructions
are read from the tape).
A power rail appears on the left of the P190 screen and the cursor is located in the
top left node. The following software labels are displayed:
NETWRK ED
6-1
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
Each software label key, when pressed, brings up another set of software labels.
The software label keys needed to enter a program are illustrated in a flow chart
in Figure 6-5. To return to the original set of software labels, shown at the top of
Figure 6-5, from any level of software labels except the Power-Up level, press the
PREV MENU software label key.
6.2 NETWORKS
A network is a set of interconnected logic elements which represents all, or part,
of the user’s 884 PC program. Each network has a maximum width of 11 columns
and a maximum length of 7 rows. The eleventh column is provided exclusively for
coils. See Figure 6-1.
A network can contain any combination of relay contacts, coils (eleventh column
only), counters, timers, and arithmetic, data transfer (DX), and special function
blocks. The logic can occupy the whole network area or just a portion of it.
-0
-0
UP TO
-0
7
ROWS
4)
-0
-0
-0
UP TO 7 COILS
6.3 REFERENCES
Reference numbers are used to identify relay contacts, coils, inputs, outputs,
latches and registers. There are seven types of references. Each type has a
different code digit to identify it; this digit is the first of five consecutive digits. The
reference types and their functions are listed in Table 6-1.
NOTE
These numbers refer to actual registers or discretes within
the controller which contain numerical values or ON/OFF
conditions. An X is any digit, 0 through 9; however, it may
have a specific limit (e.g., max. 6) as designated in the
configuration table.
6-2
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
SXXXX - Latch
. A discrete used only in a Latch function block.
. Its state is maintained through a power cycle.
6-3
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
When the coil or discrete input is ON, the normally open (NO) contact is closed and
passes power, and the normally closed (NC) contact is open and does not pass
power.
When the coil or discrete input is OFF, the NO contact is open and does not pass
power, and the NC contact is closed and passes power. See Table 6-2.
NO Contact NC Contact
Since there are two different transitions (OFF to ON and ON to OFF), there are two
transitional contacts:
6-4
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
To change the type of relay contact, position the cursor over the contact to be
changed and press the desired software label key. To change the reference
numbers below a contact, position the cursor over the contact, enter a new value
into the AR, and press the ENTER key.
Vertical shorts are used to connect contacts and function blocks one above the
other in a network. Vertical shorts can also be used to connect inputs or outputs
in a function block to create either/or conditions. When two contacts are
connected by vertical shorts, a vertical short on each side, power is allowed to
pass through if either, or both, contacts receive power.
To enter a vertical short, position the cursor to the left and above the reference
desired for the short, and press the VER OPENlVER SHORT software label key. A
vertical short is cleared (or opened) by pressing the VER OPEN software label key
and the SHIFT key.
Horizontal shorts are used in combination with vertical shorts to expand logic
within a network without breaking the power flow. They can be used to create
either/or conditions using basic relay contacts. (See Figure 6-2.)
A vertical short is used to connect the horizontal short to the top logic line.
To enter a horizontal short, position the cursor over the reference desired for the
short and press the horizontal short software label key. To clear a horizontal short,
press the D
‘ ELETE NODE software label key.
500 - 09999
i t-
10001
100
’ 40001
SUB SUB
40001 - 40001
1
l- __----- --
3)
Figure 6-2. Shorts 0001
6-5
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
6.6 COILS
A coil is used to activate logic within a program, and/or to control an output circuit.
It is represented by a OXXXX reference number and either of two symbols:
A Normal, Non-retentive Coil, + )_! is turned OFF if power is
removed and later restored (power cycle).
A Latched, Retentive Coil, -( Lt-1 retains its previous state through
a power cycle.
NOTE
A normal, non-retentive, disabled coil retains its disabled
state through a power cycle.
Coils are always displayed in the far right (eleventh) column of a network, although
they are actually located and solved in the column of the network in which they
were programmed. Each network can contain a maximum of seven coils.
Each OXXXX reference can be used as a coil only once, but can be referenced to
any number of relay contacts. Some logic functions use coils in groups of 16 (eg.,
DRUM, T+R, BLKM, etc.). Partially programmed logic elements can refer to a
OXXXX coil more than once because the 884 PC’s logic solver passes over
elements displaying I‘????” references on the CRT screen.
A logic coil is inserted into a program the same as a relay contact, except that the
cursor does not have to be over column eleven. The cursor can be directly beside
the last logic element in a row. When the COIL software label key
(< I-or<+-) is pressed, dashed lines are inserted and the coil is placed
in the coil column. The only reference allowed is a OXXXX reference, unlike relay
contacts which allow OXXXX, 1XxXx, or 2XXSS references.
The following coils are reserved for special status indicators:
761 Battery OK
762 Memory Protect
763 Remote l/O Health
764-768 Reserved
6.7 DISABLE/ENABLE
Any logic coil or discrete input in a program can be disabled, and forced ON or
OFF, from the P190 keyboard. DISABLE separates the state of the coil from control
of the PC logic. On inputs, DISABLE separates the input state from the actual field
device. This is an important difference. DISABLE/ENABLE is used for debugging
and wiring l/O devices and allows you to test the changes before you actually
change your existing logic.
Disabling a coil or input causes the programmed logic to bypass that particular
coil or input. Use of the FORCE ON and FORCE OFF software label keys allow you
to control the state of that particular coil or input. Memory Protect must be OFF.
To disable a coil or input, follow the instructions below:
1. Ensure that Memory Protect is OFF on both the P190 Programmer and the 884
PC.
4. Enter the coil reference number or discrete input reference number in the
Assembly Register (AR).
6-6
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
5. Press the GET COUGET REF software label key or the ERASE/GET key.
The reference number appears at the cursor position with its state, ON or OFF, and
the following software labels appear on the screen:
The coil or input is now DISABLED ON or DISABLED OFF, depending on its state
when the DISABLE key was pressed.
Coils may also be DISABLED or ENABLED from the logic screen. If you have a
network displayed on the CRT, and want to DISABLE a coil, position the cursor on
the coil and press the COILS software label key. The DISABLE/ENABLE and
FORCE ON/FORCE OFF software label keys are now displayed and you may
proceed.
Press the FORCE ON or FORCE OFF software label keys to change the state of
the coil or input. Press the ENABLE software label key to enable the coil or input.
If the coil or input is enabled, it cannot be forced ON or forced OFF; it retains the
actual state, based on the logic or real input status.
WARNING
Coils are displayed in the eleventh column on the P190 screen. This does not mean
that they are always solved in this column. If the logic controlling a particular coil
is in column 6 and dashed lines connect the logic to the coil, that coil is solved
in column 7. For example, in Figure 6-4, coil 00006 is solved before contacts 10004
and 10005 and coil 00003.
The scan starts in network 1, continues in network 2 and continues until the scan
reaches the end of the program. This means that when a column of logic is solved,
its solutions are available for use in the next column. Then the outputs are serviced
and the logic solve cycle starts over again.
6-7
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
. ’ P. P . P . P. P . P . P . P . P.
. . . . . . . . . l
. . . . . . . . . .
. . . . . . . . . .
. . . . . . . . . .
. . . . . . . . . .
.
t ’ t + t t .t .t t .t l
l
LJWdULJLJiJU~
l l l
I
3
START SCAN OF
NEXT NETWORK
H I-N-I l-N----
r
10002 10003 10004 10005 00003
1-1 t-______---_-_+ )-
6-8
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
MEM AVAIL
+I- --fLI-- ENABLE DISABLE FORCE ON FORCEOFF PREV MENU
DX MOVES
P
DX MATRIX
I CALCS
I
6-10
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
Press the PROGRAM software label key (on the PC Operation Menu) and then
press the PROCEED software label key. A message is displayed:
When the loading is complete the Element Editor screen, containing the following
software label keys, is displayed on the CRT.
MEM AVAIL
READ NET CREATE NET DEL NET NETWORKED
OPERS
If the 884 PC is running, you can enter one element at a time and see the power
flow change instantly. If the 884 PC is stopped, you can enter an entire network
or group of networks. As soon as the 884 PC is started, the new network, or group
of networks, will run at once. If the 884 PC is running, the power rail is highlighted;
if the 884 PC is stopped, the power rail is dim. See Figure 6-5 for the software label
key flowchart of the Element Editor.
Enter the number of the network to be displayed in the AR. Press the READ NET
software label key and the following software labels are displayed:
The number of the network appears in the upper left-hand corner of the screen. The
network power flow is displayed if the 884 PC is running and if the network is not
within an active skip block. Press the EDIT NET software label key to display the
cursor on the CRT screen and to edit the displayed network.
6-11
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
When the CREATE NET software label key is pressed, the new network will start
at the end of your current group of networks. If you have seven networks in your
system, this will CREATE NET #8.
Both CREATE NET and START NEXT go to the end of the program and start
the next network in sequence.
CREATE NET goes to the end of the program and starts the next network in
sequence.
START NEXT creates a new network, numbered one more than the one
displayed. It then renumbers the remaining networks.
3. If there are any numbers (from 00001 to the highest network number) in the
AR, both CREATE NET and START NEXT will define a new, empty network
using the value in the AR. Any higher numbered networks are renumbered.
To access the Element Editor software labels from the START NEXT screen, press
PREV MENU software label key. The following software label keys appear:
Press the EDIT NET software label key to get the software label keys needed to
create a network.
As the network is entered onto the P190 screen it is entered into the 884 PC.
Enter the number of the network to be deleted in the AR. Press the READ NET
software label key; then press DEL NET to delete the network.
If there are 10 networks in the 884 PC and network #l is deleted, the remaining
networks are renumbered, starting at 1 and ending at 9.
6-12
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
NOTE
Press the EXP/COMP software label key, with the shift key, and the following
software label keys are displayed:
MEM AVAIL
EXPAND V EXPAND H COMPRES V COMPRES H
PREV MENU
NOTE
6-13
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
I I HC ____-_--____-_-_----~~~~-~~~~ 4)
I i t-_____________________________--- -0
t 1 t- __-________--___--__~~~-~~~~-~~-~-~ 0
t I t- _--___-__________--_~~~~~~~-~~~ ___--( )
__-_______-___--__---___-_----___
41
I I_. H ~------______--__---___--____~ )
t i b__________________-----_--____ ____--_O
t 1 I-_________________--____----- __--_-_-_o
I = CURSOR AR = 00000
6-14
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
If you key a non-zero number, such as “2” in the AR, two contacts, beginning with
the contact the cursor is over, will be moved down. Look at the examples in Figure
6-6~ and 6-6d.
.
t
P I i b
t-1
Hl-
H
__________-----_--------_--_--m-w-_
c____-------___-_________---__~
___________-___--_-_----_-------
4
0
)
t 1
____---------mmem------_------em-
4)
I = CURSOR AR = 00002
1-j H l------------------------j)
4t- ____----------------------mm
--4)
l- ____------____----__------- - --_-_( )
t I l- ____-------------- ____-----------_j )
t I l- ______-_--_----_-- ___----------__-()
_----___--____-____- __--__--__+
I I= CURSOR AR = 00002
6-15
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
NOTE
The cursor can be placed anywhere in the column to be created. It does not have
to be over an element. There must be a blank column to the right of the cursor or
the Expand Horizontal is not allowed.
I i HC ______---_-____--____________ 4)
t 4 t-__---____-___---y___----_-______ 4:)
______----_-----------~-~-~~~~~~~~~
I i t- 0
t i b -_______-______-_--------_______ ---4 1
me_--------_----__--__-_---_-----
4)
= CURSOR AR = 00000
-tH H t----------___--__-------m( )
-----------------------_---
-t t I t- -0
-t t t t- ----_____----__-__-_--------- 4)
+
--_--------_---e------------w
4)
t,
El = CURSOR AR = 00000
6-16
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
If the AR has 00002 in it, two contacts, the contact where the cursor is positioned
the one below it are moved horizontally as shown in Figure 6-7~ and 6-7d.
I-___-_____-_--_--___----_-----_-- 4
-------___
__--_----______-_-_----------------
t- 4
t- --------------_--_------_----___--- 4
4
El = CURSOR AR = 00002
-IHHHb __-_-__-__-__-_-___------------ 3)
)HHk e-e_----------------_---w---w- -0
I
----tHk ______----_----_____-~~-~~-~~-~-~ -0
1 H k--_----_-_-- ________--_--__-_______-__I J
I ______-___-_-______-_-_-____--__-____ -0
.
r 1 =CURSOR AR = 00002
6-17
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
NOTE
Compress Vertically is not allowed if the cursor is placed
over a programming element or if the row to be deleted
contains a programming element.
HHI- --______-----_____-_-------- 4)
Hk -_-_----___-_---___-~~~~--~-~~~ 4)
k _____-____---_----------_______---__ 41
:
-0
F”
__---mm----------_--------__---____
El = CURSOR AR = 00000
PHIHI _---___________-___---------- -0
IHHI- ----------mm----------e----w_ 3)
HHt- ___--___--_----___--__________ -0
----------------------------------~ _(I
I =CURSOR AR = 00000
6-18
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
b
‘ If you key a non-zero number, such as 2 in the AR, two contacts, beginning at the
contact the cursor is over, will be deleted, and any contacts below will be moved
up as shown in Figure 6-8~ and 6-8d.
HHHk -----------------------~~--~~--
0
HHF ___-_--------_-__-____________---
. -0
_--_----------_-mm-------------------
0
_____-_---------------------------_-
-0
El = CURSOR AR = 00002
HH Hl- _____-_----_--_--___------- -0
E HH
H+
I- -____-___-__-__-_____-___-__-_____
----_---__--_--__-_--__-___________
-0
-0
____________-___-_--____-___--_-----_--
-0
t
I = CURSOR AR = 00002
6-19
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
The logic in Figure 6-9a shows a network, with 00000 in the AR, before pressing
the COMPRESS HORIZONTAL software label key. The revised network is shown
in Figure 6-9b.
NOTE
Compress Horizontal is not allowed if the cursor is located
over a programming element or if the column to be deleted
contains a programming element.
I_, H I_____________~~--~-~_~~~~~~-~~~ )
= CURSOR AR = 00000
-lHk __-__-__-_-_-_____-_~-~~~-~~~~~~~~~~~~~~ i)
+I- ____________________~~~~~~~~~~~~-~~~~~~~~~~~~
4)
____-___-__-____-__-_--_-__-_____-________ 4)
I I= CURSOR AR = 00000
6-20
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
If you key a non-zero number, such as 2 in the AR, two contacts, beginning with
.
the contact the cursor is positioned on will be moved horizontally as shown in
Figure 6-9c and 6-9d.
HHC _---_--___----_-----______o
HI- _-------____-_______------------ 4
l-__--_----____--____-------~~~~~~-~---~ 41
.
1-4 ~-_-______________---___--____-----_~ )
I
-lH b _---_-----me----me------------m----e-
i)
I+ k ______---_---______-___ _--____--__-_( )
= CURSOR AR = 00002
6-21
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
Press the EDIT NET software label key to reach the programming elements
software labels. (As soon as EDIT NET is pressed the cursor appears on the CRT
screen over the first element of the displayed network.) The following software
labels are displayed:
Press the SHIFT key and the PREV NET software label key to display the network
before the one currently displayed. For example, if network 3 is displayed and
SHIFT key and the PREV NET software label key are pressed, network 2 takes the
place of network 3 on the screen.
Press the NEXT NET software label key (without the SHIFT key) to move to the
network after the one currently displayed.
For example, if network 5 is displayed and the NEXT NET software label key is
pressed, network 6 replaces network 5 on the screen.
This means that you can build an entire network in the NETWORK EDITOR, and
INSERT it anywhere in your existing program. You can also build a new network
in the NETWORK EDITOR and REPLACE a network currently in your existing
program. Troubleshooting is easier because you can make changes to an existing
network, use the EXCHANGE NET function to test them, and if the changes do not
work, use a FLIP NET and another EXCHANGE NET to get back the original
network. These functions are explained later in this section. See Figure 6-10 for the
software label key flowchart of the Network Editor.
6-22
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
,
MEM AVAIL
-_(I- -fLI- ENABLE DISABLE FORCEON FORCEOFF PREV MENU
DX MOVES
1DX MATRIX
I CALCS
6-24
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
To get to the Network Editor mode, press the PROGRAM software label key on the
PC Operations Menu. The Element Editor screen automatically appears with the
following software label keys:
NETWRK ED OPERS
Press the NETWORK ED software label key. Notice the change in the software
label keys:
MEM AVAIL
READ NET -CREATE NET DEL NET
PREV MENU
Enter the number of the network to be read in the AR. Press the READ NET
software label key to read the network from the controller and display it on the
P190 screen. The number of the network appears in the upper left-hand corner of
the screen. Press the EDIT NET software label key to display the cursor and to add
to or change the network. The following software label keys are displayed after you
press READ NET:
b
EXCH NET EXP COMP PREV NET MEM AVAI
READ NET ;ERWTE NET DEL NET REPL NET
_ INSRT NET FLIP NET EDIT NET NEXT NET PREV MEN
NOTE
6-25
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
When this software label key is pressed, the following software labels are
displayed:
If you find that the new A network does not work, and you want the original
network A back, press the FLIP NET software label key, then the EXCH NET
software label key. First the original Network A reappears and then, it replaces
Network A in the 884 PC’s memory.
The FLIP NET function can only be used in conjunction with the EXCH NET
function. The P190 has two memory areas. The contents of one memory area is
visible on the screen. The other memory area is used only for storage of one
network, and its contents are not visible. This part is called the Network Memory
Stack.
6-26
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
To INSERT, create a new network. When it is complete, type the number of the new
network in the AR (00002, for example) and press the INSRT NET software label
key. The message, INSERTED INTO PC, NETWORK:0002 appears, confirming that
the insertion has taken place.
This function allows you to create a network on the screen and then EXCHANGE
it for an existing network in the 884 PC’s memory. For example, if you have a
program with ten networks in the 884 PC, and have a “bug” in network A, you can
read network A into the memory of the P190. Network A can now be edited “off
line”, without disturbing the original network that is still in the 884 PC’s memory.
Press the EXCH NET software label key to exchange the edited A network with the
original A network. A message appears on the screen, CHANGED PC NETWORK:
0005.
If you find that the new A network does not work, and you want the original
network A back, press the FLIP NET software label key, then the EXCH NET
software label key. First the original network A reappears and then it replaces
network A1 in the 884 PC’s memory.
The FLIP NET function can only be used in conjunction with the EXCH NET
function. The PI90 has two memory areas. The contents of one memory area is
visible on the screen. The other memory area is used only for storage of one
network, and its contents are not visible. This part is called the network memory
stack.
The FLIP NET command moves a network shown on the screen into the memory
stack and moves the stored network onto the screen. Figure 6-11 describes the five
commands used in the EXCH NET/FLIP NET functions.
NOTE
6-27
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
P190
NOTES
The Flip Net function can only be used after an Exchange
Network function. Flip Net can be used again and again, i.e.,
as a toggle.
If another function (e.g., Read Network) is used after
Exchange Network, the buffer is cleared and Flip Net is not
allowed (NET EMPTY error message will be displayed.)
6-28
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
After you have pressed CHANGE SCREEN, and accessed whichever function
required, press the LOGIC software label key to return to the Logic screen. You will
find that the network displayed on the Logic screen is exactly as it was prior to
CHANGE SCREEN, including cursor position.
UPDATE GET STEP# ENTER HEX SET BIT CLEAR BIT RESTORE
In the left-hand column is the type of display, the number of the network in which
the Drum function is located, the register or group of discretes holding the
destination, the pointer register, and the drum length. The next column contains
the source register or groups of discretes. Sixteen registers or groups of discretes
can appear in this column at one time. The next column contains the step
numbers. The following four columns contain the register values in binary format
(CONTACT). The last column contains the same register values in hexadecimal
format.
To examine steps which are not currently displayed, enter a step number in the AR
and press the GET STEP software label key, or press the down cursor at the bottom
step.
6-29
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
If the GET STEP function is used, the step requested, plus the next fifteen steps,
if fifteen exist, are displayed.
To change a contact value move the cursor to the CONTACT using the cursor
control keys. Position the cursor over the value to be changed and press either the
ON (= 1) or OFF (=O) software label key. The value changes and the cursor
automatically moves one position to the right. The hexadecimal value
automatically changes to agree with the binary.
CONTACT
DESTINATION
40010
POINTER
21100
SIZE
05
AR = 00000
6-30
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
10002 = OFF
10003 = ON DISABLED
10004 = OFF
10005 = OFF
10006 = ON DISABLED
10007 = OFF
10008 = OFF
10009 = OFF
10010 = OFF
10011 = OFF
10012 = OFF
10013 = OFF
10014 = OFF
10015 = OFF
10016 = OFF
10017 = OFF
10018 = OFF
10019 = OFF 10001 = OFF
AR: 00000
When the FULL REF software label key is pressed, the GET COUGET REF software
label appears on the screen.
The Get Column function is used to list a column of references on the screen.
Enter a valid reference number in the AR. Press the GET COL software label key
and the SHIFT key. Starting at the cursor position, with the reference in the AR,
.
a column of references, and their states or values, are displayed. The column
displays the particular type of reference number, up to a maximum of 18
references (three on partial reference screen). If there are not enough of the
specified reference types to fill the column, the listing stops; the next type of
reference numbers are not displayed.
NOTE
6-31
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
When the PREV REF software label key is pressed with the SHIFT key, the cursor
moves up one position and the previous reference is read in and displayed, erasing
the old reference at the cursor position.
When the cursor reaches the top of the screen, it remains in that position and
displays the new reference over the old reference each time the PREV REF
software label key is pressed.
The Next Reference function is similar to the Previous Reference function. To get
the Next Reference, press the NEXT REF software label key. The cursor moves
down one position and gets the next reference. The new reference writes over the
old reference.
If the cursor is at the bottom of the screen, each time the next reference function
is selected, the new reference writes over the bottom reference.
NOTE
The PREV REFlNEXT REF software label key is only
available if the cursor is over a reference.
Press the ERASE REF software label key to delete a single reference and its state
or contents from the screen. The cursor remains in its original position.
NOTE
The ERASE COLlERASE REF software label key is only
available when the cursor is over a reference.
Press the DISP HEXlDlSP DEC software label key to display the register’s contents
in decimal format. The display looks like this: 40001 = 0000 DECIMAL
NOTE
This software label key is only available when the cursor is
over a register reference (2Xx00, 3XXXX, 4XXXX, or 5XxXx).
6-32
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
Press the DISP BIN software label key to display the register’s contents in binary
format. The display looks like this: 40001 = 1111000011110000.
NOTE
Position the cursor over a register reference displayed binary (2Xx00, 3XXXX, or
4XXXX) and press the SET ALL software label key with the SHIFT key. All the bits
in the specified register are set to one (ON) and the cursor moves to the first bit
position.
To set bits individually, position the cursor over a bit and press the SET BIT
software label key. The cursor moves one bit position to the right. On the 16th bit
the cursor will wrap to bit position one.
NOTE
Position the cursor over a register reference displayed in binary and press the
CLEAR ALL software label key with the SHIFT key. All the bits in the specified
register are cleared to zero (OFF) and the cursor moves to the first bit position.
To clear individual bits, position the cursor over the bit to be cleared, and press
the CLEAR BIT software label key. The cursor moves one bit position to the right.
On the 16th bit, the cursor will wrap to bit position one.
NOTE
6-33
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
The CLEAR ALL/CLEAR BIT software label key is only available when the cursor
is over a register reference displayed in binary (2Xx00, 3XXXX, or 4XXXX). It is not
available when the cursor is over a 5XXXX reference.
These keys only appear when the cursor is over a 5XXXX register reference in the
decimal display mode.
Press the PLUS software label key to make the value in the register positive.
Press the MINUS software label key to make the value a negative.
Press the ENABLE software label key, with the SHIFT key, to enable a disabled coil
or discrete. Press the DISABLE software label key to disable a coil or discrete and
allow that coil or discrete to be forced ON or OFF.
Press the FORCE ON software label key with the SHIFT key to cause a disabled
coil or discrete input to the ON state. For example,
00002 = OFF
Press DISABLE
00002 = OFF DISABLED
Press FORCE ON
00002 = ON DISABLED
Press the FORCE OFF software label key to force a disabled coil or discrete to the
OFF state.
NOTE
FORCE ON/FORCE OFF are available only when the cursor
is over a coil (OXXXX) or discrete input (1XxXx) reference
and may be used only if that reference has been disabled.
6-34
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
NETWORK: 01
/ tf H I--_-----------_-_----__------_____________( )
oiIoo3
H t--_-___--__________---__-__________~ )
00005
t----____--_________---_ _______ --__< )
00006
AR: 00000
PREVREF ERASECOL
ENABLE1 DISABLE FORCEON FORCEOFF
NEXTREF ERASEREF
When the PART. REF software label key is pressed, the GET COLIGET REF
software label key appears. The other software labels, and their functions, are the
same as those used with the Full Reference screen. These are explained in section
6.11.4.
Press the SRCH DSPLY software label key and the cursor moves to the search area
on the network screen (lower right-hand corner). Enter a single search parameter
in the AR. Press the ENTER key, followed by the SEARCH hardware key on the
P190 keyboard. A relay contact, coil, function block, or a function block with a
specific reference can also be searched for. The latter are entered via the
applicable software label key. To return to the Logic screen, press the CHANGE
SCREEN hardware key and then the LOGIC software label key.
6-35
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
Software labels for the relay contacts appear on the screen, along with other
software labels not needed at this time.
3. Press _I +.
4. Press + .
6. Press _I k .
7. Press _ .
9. Press + .
10. Press + .
Software labels for coils appear on the screen, along with other software
labels not needed at this time.
6-36
INTRODUCTION TO LADDER LOGIC AND PROGRAMMING
14. Press -( )- .
15. Press B .
The cursor moves to the first node in the same row (wrap-around).
19. Press 1
20 Enter 12 into the AR.
22. Press i
I-.
6-37
SECTION 7
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
This section covers basic programming functions, relays, counters, timers and a
test function. It also includes two types of arithmetic functions, single precision
and double precision, for addition, subtraction, multiplication, and division.
7.1 RELAYS
The Relay Contact is the basic programming element. It can be referenced to a
logic coil, a discrete input, or a sequencer.
Relay contacts can be normally open or normally closed, or transitional.
When the coil or discrete input is ON, the normally open (NO) contact is closed and
passes power, and the normally closed (NC) is open and does not pass power.
When the coil or discrete input is OFF, the NO contact is open and does not pass
power; the NC contact is closed and does pass power.
FUNCTION
The Timer function uses any one of three time bases to record time. The 884 PC
is capable of counting time in seconds, tenths of seconds, and hundredths of
seconds.
PRESET
CONTROL INPUT TIMER = PRESET
7-1
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
l Tl.O = seconds;
TO.1 = tenths of seconds;
T.O1 = hundredths of seconds.
FUNCTION BLOCK
l The top section (preset) of the function block contains the preset value for the
timer. It can be any constant up to 9999, a 30XxX input register reference, or
a 4XXXX holding register reference.
For example, if the preset value is 009, it represents either 9 seconds (Tl.O), .9
seconds (TO.l) or .09 seconds (T.O1). If the value is 050, it is either 50 seconds
(Tl.O), 5 seconds (TO.l), or .5 seconds (T.Oi).
NOTE
If the preset value is greater than 9999, the timer value is
cleared to zero and both outputs do not pass power. If
preset equals zero and accumulator equals zero, top output
will be ON.
l The bottom section (accumulator) contains a 2XXO0 sequencer register
reference, or a 4XXXX holding register reference. This register holds the timer
value. It increases in time, starting at zero and going up to the preset value, as
long as the top input receives power and the timer is less than the preset. The
timing is cumulative until the reset is activated.
IN PUTS
l The top input controls the operation. When it receives power and the bottom
input also receives power, the timer value increases time. When the top input
loses power, the timer stops increasing.
l When power is removed from the bottom input the timer is reset, clearing the
accumulator to zero. The timer increases in time if the top and bottom inputs
are receiving power simultaneously.
OUTPUTS
l The top output passes power when the timer value equals the preset value.
l The bottom output passes power when the timer value is not equal to the
preset value, and the control input and the bottom input are receiving power.
NOTE
Only one output passes power at a time.
EXAMPLE
The following paragraph provides a detailed explanation of the logic used in
Figure 7-1.
00005
TO.1
40001
7-2
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
When input 10001 is energized, the top input receives power and register 40001
begins accumulating time in seconds. When the value in register 40001 equals 5,
the top output passes power and energizes coil 00001. Power is removed from the
bottom input on the next scan and the timer value is set to zero.
7.3 COUNTERS
PRESET
CONTROL INPUT ciEK+ COUNT = PRESET
3xxxx
4xxxx
m_____
UCTR
2xxoo
ENABLE 4xxxx
ACCUMULATOR
FUNCTION BLOCK
l The top section of the function block contains the preset value for the counter.
It can be a constant up to 9999, a 30XxX input register reference, or a 4XXXX
holding register reference. The preset value is the maximum value the counter
can reach.
NOTES
INPUTS
l The top input controls the operation. The count value increases by one, each
scan. (A transitional contact must be used to count events.)
l The counter is reset when power is removed from the bottom input. Any
transitions of the top input are ignored when power is removed from the bottom
input.
7-3
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
OUTPUT
l The top output passes power when the count value is equal to the preset value.
EXAMPLE
The following paragraph provides a detailed explanation of the logic used in
Figure 7-2.
7’ 1 00005 ------__-- -0
10001 UCTR 0000 1
Y
. 40001
\
00001
Each time input 10001 makes the transition from OFF to ON, the value in register
40001 increases by one. When this value reaches 5, the top output passes power
and coil 00001 is energized. The power is removed from the bottom input on the
next scan and the counter value is reset to zero.
NOTE
A transitional contact ( l jtk ) must be used on the top
input, instead of a normal contact ( + k ), or the counter
will increase the accumulator value by one, for each scan.
PRESET
CONTROL INPUT COUNT = ZERO
-w-w_
RESET
ACCUMULATOR
7-4
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
i FUNCTION BLOCK
l The top section of the function block contains the preset value for the counter.
It can be a constant up to 9999, a 30XxX input register reference, or a 4XXXX
holding register reference.
NOTES
INPUTS
l The top input controls the operation. The count value decreases by one, each
scan.
l The counter is reset when power is removed from the bottom input. Any
transitions of the top input are ignored when power is removed from the bottom
input.
OUTPUTS
l The top output passes power when the count value is equal to zero.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 7-3.
I ()00()5 _-------- -
<>
10001 00001
DCTR
.
40001
r
00001
Figure 7-3. Down Counter
When input 10001 is energized, the top input receives power and the count is
decreased by one.
Each time input 10001 makes the transition from OFF to ON, the value in register
40001 increases by one. When this value reaches 5, the top output passes power
and coil 00001 is energized. The power is removed from the bottom input on the
L
next scan and the counter value is reset to preset.
7-5
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
NOTE
A transitional contact ( -ItI- ) must be used on the top
input, instead of a normal contact ( -I I- ), or the counter
will increase the accumulator value by one, for each scan.
7.4 ADDITION
SOURCE
CONTROL INPUT - ONNNN - COPY OF TOP INPUT
2xxoo
3xxxx
4xxxx
II-----
ONNNN
2xxoo OVERFLOW, SUM OF TWO
CARRY IN 1 -
3xxxx -NUMBERS > 9999
4xxxx
m--L-I
ADD
1 2xxoo
~ 4xxxx - TOP OR MIDDLE NODE > 9999
D ST1 NATI IN
FUNCTION BLOCK
l The top and middle sections of the function block each contain a value which
can be either a constant (up to 9999) or one of the following references: a 2XXO0
sequencer register, a 30XxX input register, or a 4XXXX holding register. The
values in the top and middle sections are added together when the top input
receives power.
INPUTS
l The top input controls the operation. When it receives power, the value in the
top section is added to the value in the middle section, and the sum is placed
in the bottom section’s register.
l The middle input, when receiving power, causes a 1 to be carried into the
operation (i.e., top section plus middle section plus 1 equals bottom section).
Used to “chain” ADD Blocks for multi-precision results.
7-6
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
OUTPUTS
l The top output passes power when the top input receives power.
l The middle output passes power when the result of the operation is greater
than 9999 (overflow). The sum stored in the bottom section is adjusted by
subtracting 10,000 from the sum.
l The bottom output passes power if the value in either the top or the middle
section is greater than 9999. This is an error condition. Add is not performed.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 7-4.
10001
l- 0010 - 0000
9999 0000
ADD - ADD
40001 - 40002
When input 10001 is energized, the top input receives power and the values, 10 and
9999 are added together. The result is placed in register 40001.
In this example, the result will be greater than 9999 and the second ADD block’s
top and middle inputs receive power; the middle input activates a carry of one and
a 1 is placed in register 40002. This is illustrated below:
40001 40002
[oolo] + VI = 1-1 I/ Answer is 10,009
In this way, ADD blocks can be chained together to provide accurate, multi-
precision results.
7-7
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
l The bottom contains a SXXXX double precision register reference. This register
holds the sum of the top and middle values.
INPUT
l The top input controls the operation. When it receives power, the top value is
added to the middle value, and the sum is placed in the bottom double
precision register.
OUTPUTS
l The top output passes power when the top input receives power.
l The bottom output passes power when the result is not within the legal value
range: (- 2),’ result 231. This is either an underflow or overflow error condition.
Add not performed.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 7-5.
10001
I- - 7600
50001
DADD
50002 ----------w---m
-0
0000 1
7-8
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
When input 10001 is energized, the top input receives power and the value, - 7600,
is added to the value in 50001. The result is placed in register 50002.
If the value in register 50001 is +00091980, the result placed in register 50002 is
+00084380. This is illustrated below:
50001 50002
- 7600 + + 00091980 = + 00084380
7.5 SUBTRACTION
INPUT
l The top input controls the operation. When it receives power, the middle value
is subtracted from the top value and the difference is placed in the bottom
register section.
l The middle input, when receiving power, causes a one to be borrowed into the
operation (i.e., a 1 is subtracted from the difference between the top and middle
values). Used to “chain” SUBTRACT blocks for multi-precision results.
OUTPUTS
l The top output passes power when the input receives power.
7-9
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
l The middle output passes power when the result is an underflow condition
(used in “chaining”).
l The bottom output passes power when the top value or the middle value is
greater than 9999. This is an error condition. Subtract not performed.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 7-6.
500 -s - - - - -
)
1000
100
SUB
40001
When input 10001 is energized, the top input receives power. The value, 100, in the
middle section is subtracted from the value, 500, in the top section. The result,
0400, is placed in register 40001. If the value in the middle section had been greater
than the value in the top section, an underflow condition would cause the middle
output to pass power.
-m-m-
RESULT
7-10
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
FUNCTION BLOCK
l The top and middle sections each contain a value which can be a constant
within the range of - 9999 to +9999, or a 5XXXX double precision register
reference. The middle value is subtracted from the top value when the top input
receives power.
l The bottom section contains a 5XXXX double precision register reference. This
register holds the difference between the top and middle values.
INPUT
l The top input controls the operation. When it receives power, the middle value
is subtracted from the top value and the difference is placed in the bottom
double precision register.
OUTPUTS
l The top output passes power when the top input receives power.
l The bottom output passes power when the result is not within the legal value
range: (- 2)31 result 231. This is either an underflow or overflow error condition.
Subtract not performed.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 7-7.
50001
i t-
10001
+ 9696
DSUB
50002 L------e-v-----
-0
00001
When input 10001 is energized, the top input receives power. The value + 9696 is
subtracted from the value in register 50001, and the result is placed in register
50002.
If the value in register 50001 is +01203442, the result placed in register 50002 is
1193746.
50001 50002
7-11
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
7.6 MULTIPLICATION
FUNCTION
The Single Precision Multiply function calculates the product of the values in the
top and middle sections, and places the answer in two consecutive holding
registers referenced in the bottom section of the function block. Two consecutive
holding registers are used because the product of two 4-digit numbers can be up
to eight digits in length.
FUNCTION BLOCK
l The top and middle sections each contain a value which can be a constant up
to 9999, a 3XXXX input register reference, or a 4XXXX holding register
reference. The top and middle values are multiplied together.
l The bottom contains a 4XXXX holding register reference. This holding register
holds the high order portion of the product, even if it is zero. The next
consecutive holding register (4XxXx+ 1) holds the low order portion of the
product. For this reason, the numerically highest holding register in the 884 PC
cannot be used.
INPUT
l The top input controls the operation. When it receives power, the top value is
multiplied by the middle value, and the product is placed in the bottom holding
register(s).
OUTPUT
l The top output passes power when the top input receives power.
l The bottom output passes power if the top or middle value is greater than 9999.
This creates an error condition. Multiply not performed.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 7-8.
7-12
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
r 3 1 500
10001
25
MULT
40001
In this example, when input 10001 is energized, the top input receives power and
0500 is multiplied by the 25. The resulting product is stored in registers 40001 and
40002.
Register 40001 contains 0001 and 40002 contains 2500, the product is 12500.
40001 40002
p-1 x p-j = pq pq
._____
FUNCTION BLOCK
l The top and middle sections contain a value which can be a constant within
the range of - 9999 to + 9999, or a 5XXXX double precision register references.
The top and middle values are multiplied when the top input receives power.
l The bottom contains a 5XXXX double precision register reference. This register
holds the result of the multiplication.
7-13
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
INPUT
l The top input controls the operation. When it receives power, the top and
middle values are multiplied, and the result is placed in the bottom double
precision register.
OUTPUTS
l The top output passes power when the top input receives power.
l The bottom output passes power when the result is not within the legal value
range: (from - 231to 231).This is either an underflow or overflow error condition.
Multiply not performed.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 7-9.
10001
__-------~-~~--
1 -0
00001
When input 10001 is energized, the top input receives power and the value -0280
is multiplied by the value in register 50001. The result is placed in register 50005.
If the value in register 50001 is -00082280, the result placed in register 50005 is
+ 23038400.
50001 50005
(-0280) x ~~~ = 1+230384oo]
7.7 DIVISION
7-14
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
FUNCTION BLOCK
l The top value is the dividend. It can be a constant up to 9999, a 3XXXX input
register reference, or a 4XXXX holding register reference.
l The middle value is the divisor. It contains a constant up to 9999, a 3XXXX input
register reference, or a 4XXXX holding register reference.
l The bottom section contains a 4XXXX holding register. This holding register
holds the result of the division. The next holding register (4XXXX + 1) holds the
remainder. For this reason, the numerically highest holding register in the 884
PC cannot be used.
INPUT
l The top input controls the operation. When it receives power, the top value is
divided by the middle value and the quotient and remainder are placed in two
consecutive holding registers.
OUTPUTS
l The top output passes power when the top input receives power.
l The bottom output passes power when there is an error in the operation. An
error can be any of the following:
7-15
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 7-10.
When contact 10001 is energized, the top input receives power and 5000 is divided
by 24. The result is placed into register 40001 and the remainder into register
40002.
40001 40002
5000 + 24 = 11 I_I
FUNCTION
The Double Precision Divide function divides the top value by the middle value;
these values are signed and can be up to 8 digits in length. The result of the
division is placed in a 5XXXX double precision register.
FUNCTION BLOCK
l The top and middle sections contain values which can be constants within the
range of -9999 to +9999, or a SXXXX double precision register reference.
l The bottom contains a 5XXXX double precision register reference. This register
holds the result of the division. The next register (5XxXx+ 1) holds the
remainder. For this reason, the numerically highest 5XXXX register cannot be
used.
INPUT
. The top input controls the operation. When it receives power, the top value is
divided by the middle value and the quotient and remainder are placed in the
consecutive double precision registers in the bottom of the function block.
7-16
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
OUTPUTS
l The top output passes power when the top input receives power.
l The bottom output passes power when the result is not within the legal value
range of -9999 to +9999. This is either an underflow or overflow error
condition. Divide not performed.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 7-11.
-I t- 10001
50001
0919
DDIV
50010
When contact 10001 is energized, the top input receives power. The value in
register 50001 is divided by the value + 0919. The result is placed in register 50010
and the remainder in register 50011.
If the value in register 50001 is +05270803, the result placed in register 50010 is
+ 00005735 and the remainder placed in register 50011 is + 00000338.
mj l3imq 13ziq
+ 05270803 + (+0919) = +00005735 + 00000338
RESULT REMAINDER
2xxoo
3xxxx -TOP VALUE = MIDDLE VALUE
4xxxx
MAX 9999
7-17
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
FUNCTION BLOCK
l The top and middle sections each contain a value which can be a constant up
to 9999, or one of the following references: a 2XXO0 sequencer register, a
3XXXX input register, or a 4XXXX holding register. The values in these two
sections are compared but not changed.
INPUT
l The top input controls the operation. When it receives power, the top value is
compared with the middle value.
OUTPUTS
l The top output passes power if the top value is greater than the middle value.
l The middle output passes power if the value in the top node equals the value
in the middle node.
l The bottom output passes power if the top value is less than the middle value.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 7-12.
-I t-
10001
30026 .--_---_---_--______------
-0
00001
40015 ,--_-----_--__-___-_~~~~~~~
0
00002
TEST .--_------__----__---~~~~- J\
\J
1 00003
When contact 10001 is energized, the top input receives power. Registers 30026
and 40015 are compared.
If the value in 30026 is greater than the value in 40015, the top output passes power
to energize coil 00001.
If the value in 30026 is equal to the value in 40015, the middle output passes power
to energize coil 00002.
If the value in 30026 is less than the value in 40015, the bottom output passes
power to energize coil 00003.
7-18
BASIC PROGRAMMING AND ARITHMETIC FUNCTIONS
-0
I I
___~~---~-~-
00060
00002
T1.O
w-------B---
I
00060
-(>
00003
00002 UCTR
\
1 40006
\
00003
00024 ------------
-0
00004
UCTR
40005
The top network in this example is the 1 minute timer. At the beginning of the logic
solving, coil 00002 is OFF so both the top and bottom inputs of the timer are
receiving power. Register 40001 starts increasing time in seconds until it reaches
60. At this point, the top output passes power and energizes coil 00002. Register
40001 is reset and the counter in the second network (40006) increases by one,
indicating that one minute has elapsed.
Since the timer in network 1 is no longer equal to the preset, coil 00002 is de-
energized and the timer resumes increasing time. Once the value in 40006 reaches
60, indicating 60 minutes, the top output passes power and energizes coil 00003.
Register 40006 is reset and the counter in the third network (40005) increases by
one, indicating that one hour has passed. The correct time of day can be read in
registers 4000540007 in hours, minutes, and seconds.
7-20
SECTION 8
DATA TRANSFER (DX) MOVE FUNCTIONS
AND SEQUENCER FUNCTIONS
The Move functions copy data from registers, discretes, and/or tables into other
registers, discretes, or tables. The data can then be examined or changed by the
controller without altering the original data.
The top input is the control input; when the top input receives power, the function
is performed. When the top input receives the power, the top output passes power.
This allows function blocks to be cascaded within a network.
A Sequencer function block occupies either two or four areas and its contents vary
by function.
The input(s) to a function block can be a single relay contact, another function
block, or a whole network of logic.
The output(s) can be connected directly to coils, to other function blocks, to relay
contacts, or left unconnected.
NOTE
FREEZE -----
POINTER POINTER = TABLE LENGTH
-w---e
RESET ERROR
POINTER
8-I
DATA TRANSFER, (DX) MOVE FUNCTIONS AND SEQUENCER FUNCTIONS
FUNCTION BLOCK
l The top area of the T+R function block is the source node. It can be one of
the following references: a OXXXX logic coil, a 1XXXX discrete input, a 2XXO0
sequencer register, a 3XXXX input register, or a 4XXXX holding register. The
source is a table of 16-bit locations. Its size is defined in the bottom area.
l The middle area is the destination. It is occupied by two consecutive 4XXXX
holding registers. The first register holds the pointer value. The pointer value
determines what data in the source table is to be moved. Since the pointer
value is increased by one before the move is performed, enter a pointer value
one less than the position of a register in the table (i.e., a pointer value of three
indicates the fourth position in a table). The next consecutive holding register
(4XXXX + 1) receives the data. The pointer does not receive the data.
l The bottom area contains the symbol T+R and the numerical value that
specifies the source table length. This constant can range from 1 to 255.
NOTE
If the pointer register is loaded with a value greater than the
table length, the 884 PC sets the pointer value to the table
length and the function is not performed.
INPUTS
l The top input controls the operation. When it is receiving power and the pointer
is less than the table length, the information from one register or group of
discretes in the source table is copied into a single holding register.
l The middle input is the freeze pointer. When held high, this input prevents the
pointer from advancing.
l The bottom input, when receiving power, resets the pointer to zero, prevents
the pointer from increasing, and does not allow the function to be performed.
OUTPUTS
l The top output passes power when the top input receives power.
l The middle output passes power when the pointer value equals the table length
(end of the table).
l The bottom output passes power when the pointer value is greater than or
equal to the table length before the function is attempted. Error condition,
Pointer = Length; Function not performed.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 8-1.
8-2
DATA TRANSFER, (DX) MOVE FUNCTIONS AND SEQUENCER FUNCTIONS
The table starts at 40010 and is 10 steps long. Each time 10001 is energized (must
be a “one-shot”), a value from the table shifts to register 40002. 40001 keeps track
of the count.
When the pointer value reaches the table length, 10, the middle output passes
power and energizes coil 00003. On the next scan, the bottom input receives power
and resets the pointer as well as temporarily freezing the operation. On the
following scan, provided the top input is still receiving power, the function
resumes.
DESTINATION
FREEZE POINTER 4xxxx POINTER = LAST
R-T
RESET 0255
POINTER (MAW ERROR
8-3
DATA TRANSFER, (DX) MOVE FUNCTIONS AND SEQUENCER FUNCTIONS
FUNCTION BLOCK
l The top area of the function block is the source. It can be one of the following
references: a OXXXX logic coil, a 1XXXX discrete input, a 2XXO0 sequencer
register, a BXXXX input register, or a 4XXXX holding register. The source is a
single 16-bit location (e.g., a register or group of sixteen discretes).
l The middle area is the destination . It consists of consecutive 4XXXX holding
registers. The first register holds the pointer value. The pointer value points to
the position in the table to which the source data will be moved. Enter a pointer
value that is one less than the register position in the table, because the
pointer value is increased by one before each move is performed (i.e., the
pointer value of three points to the fourth position in a table). The table starts
at the next register (4XxXx+ l), not at the pointer.
l The bottom area contains the symbol R+T and a numerical value which
specifies the destination table length. This constant can range from 1 to 255.
NOTE
If the pointer register is loaded with a value greater than the
table length, the 884 PC sets the pointer value to the table
length and the function is not performed.
IN PUTS
l The top input controls the operation. When it is receiving power and the pointer
is less than the table length, the information in the source register or group of
discretes is copied to a location in the table.
l The middle input is the freeze pointer. When held high, this input prevents the
pointer from advancing.
l The bottom input, when receiving power, resets the pointer to zero, prevents
the pointer from increasing, and does not allow the function to be performed.
OUTPUTS
l The top output passes power when the top input receives power.
l The middle output passes power when the pointer equals the table length
(end of table).
l The bottom output passes power when the pointer value is greater than or
equal to the table length before the function is attempted. Error condition when
pointer = length; no function performed.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 8-3.
40001
10001
40010
R-T
10
t-
10003
Figure 8-3. Register-to-Table Move Logic
DATA TRANSFER, (DX) MOVE FUNCTIONS AND SEQUENCER FUNCTIONS
This instruction takes whatever is in Register 40001 and moves it into a table 10
steps long, starting at 40011. Register 40010 keeps track of the count pointer.
After several scans when the pointer value reaches the table length, the middle
output passes power to energize coil 00003. On the next scan, the bottom input
receives power and resets the pointer, as well as temporarily freezing the
operation. On the following scan, provided the top input is still receiving power, the
function resumes.
REGISTER TABLE
m!ml
POINTER
pq
NOTE
FUNCTION BLOCK
l The top area of the function block is the source reference. It can be one of the
following references: a OXXXX logic coil, a 1XXXX discrete input, a 3XXXX input
register, or a 4XXXX holding register. The source is a table of 16-bit locations.
8-5
DATA TRANSFER, (DX) MOVE FUNCTIONS AND SEQUENCER FUNCTIONS
l The middle area is the destination. It can be either a OXXXX logic coil reference
or a 4XXXX holding register reference. The destination is a table of 16-bit
locations, the same size as the source.
WARNING
The BLKM function overrides the disable state of a coil in
the destination area of the function block. This may cause
personal injury if repairs are being made and a coil has not,
in fact, been disabled.
l The bottom area contains the symbol BLKM and a numerical value that
specifies the table length for both the source and the destination. This
constant can range from 1 to 100.
INPUT
l The top input controls the operation. When it receives power, one table of
registers or discretes is copied into another table of the same length.
OUTPUT
l The top output passes power when the top input receives power.
NOTE
Only the top input and top output are used.
EXAMPLE
The following paragraph provides a detailed explanation of the logic used in
Figure 8-5.
40201
BLKM
20
This instruction takes the contents of registers 40201-40220 and copies them into
registers 40031-40050. All the registers are moved in one scan, each time the top
input receives power. No output is required for this function unless cascading is
desired.
8-6
DATA TRANSFER, (DX) MOVE FUNCTIONS AND SEQUENCER FUNCTIONS
Figure 8-6 illustrates the Block Move described in the preceding paragraphs.
SOURCE DESTINATION
.
Figure 8-6. Block Move
SET
RESET
FUNCTION BLOCK
l The top area of the function block contains the symbol LTCH.
l The bottom area contains a SXXXX latch reference.
INPUTS
l The top input, when it receives power, sets the latch to ON.
l The bottom input, when it receives power, resets the latch to OFF.
OUTPUTS
l The top output passes power when the top input only receives power. If both
the top and bottom inputs receive power, this output does not pass power.
l The bottom output passes power when the bottom input receives power.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 8-7.
LATCH -_-_--_--___-_-----
0
00001
10001 90001
--_-a--a--a-----_--
4
EzI
00002
10002
Figure 8-7. Latch Logic
8-7
DATA TRANSFER, (DX) MOVE FUNCTIONS AND SEQUENCER FUNCTIONS
The LATCH function block is the only instruction that outputs power when no
power is input. Either 01 or 02 is always ON (one always on and one always off).
The output status is based on the Truth Table below.
Table 8-1. Truth Table, Latch Function
Input input output output
CONTROL 0099 01
(MAX)
______
SEQ
ENABLE 2xxoo 02
#
FUNCTION BLOCK
l The top area contains the preset value. It is a constant with a maximum value
of 99.
l The bottom area contains the symbol SEQ and a 2XXO0 sequencer register
reference.
IN PUTS
l The top input controls the operation and determines the number of times the
operation is performed.
l The bottom input, when it receives power, enables the sequencer register, and
allows it to increase. The two outputs do not pass power.
OUTPUTS
l The top output passes power when the value in the sequencer register equals
the preset.
l The bottom output passes power when the top input receives power and the
bottom input does not receive power.
EXAMPLE
Figure 8-8 and the following text illustrate the sequencer function.
Each time 10001 is pulsed, the value in register 20100 increases by one. When the
value equals the PRESET value, coil 0002 is energized.
8-8
DATA TRANSFER, (DX) MOVE FUNCTIONS AND SEQUENCER FUNCTIONS
DESTINATION oxxxx
4xxxx
POINTER 2xxoo
4xxxx
FUNCTION BLOCK
This function block has four sections which will be referred to here as top, second,
third, and bottom.
l The top section is the source. It can be either a 3XXXX input register reference,
or a 4XXXX holding register reference. The source is a table of l6-bit locations
whose size is defined in the bottom section.
l The second section is the destination. It can be either a OXXXX discrete output
reference, or a 4XXXX holding register reference. The destination length is one
register or one group of sixteen discretes.
l The third section is the pointer. It is a 2XXO0 register reference which holds the
pointer value. This value controls which register in the source table is moved.
l The bottom section contains the symbol DRUM and the numerical value that
specifies the source table length. This constant can range from 1 to 99.
INPUT
l The top input controls the operation. When it receives power the content of one
register of the source table is moved into the destination, one register per scan.
OUTPUTS
l The top output passes power when the top input receives power.
l The bottom output passes power when the pointer value is greater than the
source table length and the top input is receiving power.
8-9
DATA TRANSFER, (DX) MOVE FUNCTIONS AND SEQUENCER FUNCTIONS
EXAMPLE
The following paragraph provides a detailed explanation of the logic used in
Figure 8-9.
25
it
10001 SEQ
’ 20100
DRUM
25
The logic used to illustrate the Drum Function combines the Sequencer logic
explained in 8.5 with the Drum Function block. Each time 10001 is pulsed it
increments the POINTER, 20100, and moves the applicable REGISTER, 40100
through 40124, into the DESTINATION, 40001.
8-10
DATA TRANSFER, (DX) MOVE FUNCTIONS AND SEQUENCER FUNCTIONS
-i
10101
t+Ft+ 10102 10103
40201
40301
BLKM
00008
\
40109
00008
I
40117
40301
BLKM
00008
8-12
DATA TRANSFER, (DX) MOVE FUNCTIONS AND SEQUENCER FUNCTIONS
The information, or recipe, for each soup is stored in a unique table. Since only one
soup is made at a time, a working table is needed which can apply to any of the
three soups. This is accomplished with a block move as shown in Figure 8-10. The
tables for all the soups contain specific information in corresponding registers.
These registers must also correspond with the working table’s registers. For
example, if the first register in one table contains cooking time, the first register
in &I the tables must contain cooking time.
The process is controlled from an operator panel. The panel can have three input
switches; 10101,10102, and 10103. To make soup A, the operator turns 10101 ON,
and 10102 and 10103 remain OFF.
,
Following the logic in Figure 8-10, input 10101 is energized and passes power
through normally closed contacts 10102 and 10103. The recipe for soup A is moved
from table 40201-40208 to table 40301-40308. Table 40301-40308 is a working table.
Each output register in this table is controlling a specific part of the operation.
When input 10102 is energized, input 10101 stops passing power and the recipe for
soup B is moved from table 40109-40116 into table 40301. Note that when input
10101 stops passing power the recipe for soup A is moved out of table 40301. This
process is repeated by energizing input 10103 to prepare soup C.
If the original recipe tables are used as working tables, three individual programs
are required. By using one working table as illustrated in this example, only one
program is needed to control the output information.
8-13
SECTION 9
DATA TRANSFER (DX) MATRIX FUNCTIONS
Register Bits
I
40051 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
40052 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
40053 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
Each bit has a value of one or zero. Registers are generally displayed in decimal
format and have to be displayed in binary format to read bit information. To obtain
a register value in bit format, do the following:
5. Press the GET COUGET REF software label key or the ERASE/GET key on the
P190 panel. The register number appears with a value next to it in decimal
format (for example, 40250 = 0023 DECIMAL).
6. Press the DISP ASCIVDISP BIN software label key. The following is displayed
on the screen:
40250 = 0000000000010111
Each bit has a value assigned to it. To determine the value of the register in binary
format, add the individual bits.
9-1
DATA TRANSFER (DX) MATRIX FUNCTIONS
BITS 1 2 3 4 5 6 7 8
BITS 9 10 11 12 13 14 15 16
VALUES 128 64 32 16 8 4 2 1
If the bit pattern is 0000000001100100, the value is 100 (64 + 32 + 4). If the bit
pattern is 0000000111110100, the value is 500 (256 + 128 + 64 + 32 + 16 + 4).
The DX MATRIX functions can revise data, shift data, or examine data in a matrix
with or without altering the source.
The Bit Shift Left and Bit Shift Right function blocks occupy two sections in a
10 X 7 section network format and consist of a matrix start reference and the
matrix length.
The Bit Sense and Bit Modify function blocks occupy three sections in a 10 X 7
section network format and consist of a source, a destination, and a specified
matrix length in registers.
In all these function blocks, the top input is the control input; when it receives
power the function is performed. The top output passes power when the top input
receives power. This allows function blocks to be cascaded within a network.
9.1 BIT SHIFT LEFT (BSHL)
FUNCTION
The Bit Shift Left function shifts bits in a matrix to the left, one bit per scan. The
original matrix is replaced by the newly shifted matrix.
FUNCTION BLOCK
l The top section contains either a OXXXX logic coil reference or a 4XXXX holding
register reference. This specifies the first reference in the matrix in which the
shift is taking place.
l The bottom contains the symbol BSHL and the numerical value that specifies
the matrix length in registers or groups of discretes. This constant can range
from 1 to 100 (16 to 1600 bits).
INPUTS
l The top input controls the operation. When it receives power, all the bits in a
matrix are shifted one position to the left. The first bit is shifted out of the
matrix.
9-2
DATA TRANSFER (DX) MATRIX FUNCTIONS
The bottom input, when it receives power, places a 1 in the vacated bit of the
u l
matrix. If this input does not receive power, a 0 is placed in the vacated bit.
OUTPUTS
l The top output passes power when the top input receives power.
l The bottom output passes power when the bit shifted out of the matrix is a one
bit.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 9-2.
,___-------------_-----
-0
10071 00003
When input 10006 is energized, the top input receives power. All the bits in matrix
40052-40060 are shifted one bit position to the left.
The first bit is shifted out of the matrix. If this bit is a one bit, the bottom output
passespower to energize coil 00003.
If input 10071 is energized, the bottom input receives power and a one is placed
in the last bit of the matrix, bit 144. If the bottom input does not receive power, a
zero is placed in the last bit.
(BIT) (BIT)
LENGTH CARRY IN CARRY OUT
9-3
DATA TRANSFER (DX) MATRIX FUNCTIONS
FUNCTION BLOCK
l The top contains a OXXXX logic coil reference or a 4XXXX holding register
reference. This specifies the first reference in the matrix in which the shift is
taking place.
l The bottom contains the symbol BSHR and the numerical value that specifies
the matrix length in registers or groups of discretes. This constant can range
from 1 to 100 (16 to 1600 bits).
INPUTS
l The top input controls the operation. When it receives power, all the bits in a
matrix are shifted one position to the right. The last bit is shifted out of the
matrix.
l The bottom input, when it receives power, places a 1 in the vacated bit of the
matrix. If this input does not receive power, a 0 is placed in the vacated bit.
OUTPUTS
l The top output passes power when the top input receives power.
l The bottom output passes power when the bit shifted out of the matrix is a one
bit.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 9-3.
40021
BSHR
00010 ______
1 <> 00001
When input 10022 is energized, the top input receives power. All the bits in matrix
40021-40030 are shifted one bit position to the right.
The last bit, bit 160, is shifted out of the matrix. If this bit is a one bit, the bottom
outprpasses power to energize coil 00001.
If input 10028 is energized, the bottom input receives power and a one is placed
in the first bit of the matrix. If the bottom input does not receive power, a zero is
placed in the first bit.
9-4
DATA TRANSFER (DX) MATRIX FUNCTIONS
FUNCTION BLOCK
l The top holds the pointer value that controls which bit is examined. It can be
a 3XXXX input register reference, a 4XXXX holding register reference, or a
constant up to 1600.
l The middle is the source. It can be one of the following references: a OXXXX
logic coil, a 1XXXX discrete input, a 3XXXX input register, or a 4XXXX holding
register.
l The bottom contains the symbol SENS and the numerical value that specifies
the source matrix length. This constant can range from 1 to 100 (16 to 1600
bits).
INPUTS
l The top input controls the operation. When it receives power, one bit in a matrix
is examined and its status is reported.
NOTE
OUTPUTS
.
l The top output passes power when the top input receives power.
l The middle output passes power when the bit being examined is a one bit. This
output does not pass power when the bit is a zero bit.
. The bottom output passes power if the pointer value is greater than the matrix
size or if the pointer equals zero. In either case, no operation is performed.
9-5
DATA TRANSFER (DX) MATRIX FUNCTIONS
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 9-4.
-1 I-
00026
30064
40011
SENS
._____--_------__--__
-3)
00033
00005
When contact 00026 is energized, the top input receives power. The bit in matrix
40011-40015 which is pointed to in register 30064, is sensed. If the bit sensed is a
one-bit, the middle output passes power to energize coil 00033. If the bit is a zero
bit, the middle output does not pass power.
If the value in register 30064 is 0035, the bit sensed is the third bit in register 40013.
l The middle contains the source and destination; the revised data replaces the
original data in the matrix. It can be either a OXXXX logic coil reference, or a
4XXXX holding register reference. If a logic coil is used it can only be used
once, in this function block. The logic coil cannot be used in another function
block or in the eleventh column of a network; it can be used as a relay contact.
9-6
DATA TRANSFER (DX) MATRIX FUNCTIONS
WARNING
l The bottom contains the symbol MBIT and the numerical value that specifies
the matrix length. This constant can range from 1 to 100 (16 to 1600 bits).
NOTE
INPUTS
l The top input controls the operation. When it receives power, the bit specified
by the pointer is either set to one or cleared to zero.
l The middle input controls whether the bit is set to one or cleared to zero. If this
input receives power, the bit is set to one. If no power is received, the bit is
cleared to zero.
OUTPUTS
l The top output passes power when the top input receives power.
l The middle output passes power when the bit modified is a disabled discrete.
l The bottom output passes power if the pointer value is greater than the matrix
size or if the pointer equals zero. In either case, no operation is performed and
the pointer value is set to the matrix size.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 9-5.
I
+ I--, 30016
I MBIT
00020
.--------------------~~
-0
00077
9-7
DATA TRANSFER (DX) MATRIX FUNCTIONS
When input 10039 is energized, the top input receives power. The bit in matrix
40061-40080 pointed to by the value in register 30016, is either set to one or cleared
to zero depending on the middle input.
If input 10020 is energized, the middle input receives power and sets the bit to one.
If the middle input does not receive power, the bit is cleared to zero.
If the pointer value is greater than the matrix size or equals zero, the bottom output
passes power and energizes coil 00077.
Top Input Control Input Control Input Control Input Control Input
Bottom Input State of Bit State of Bit Not Used Not Used
In = 1 In = 1
Bottom Node Max. 100 Max. 100 Max. 100 Max. 100
Top Output Copy of Top Copy of Top Copy of Top Copy of Top
Input Input Input Input
Bottom Output State of Bit State of Bit Pointer > Matrix Pointer > Matrix
Out=1 Out=1 or or
Pointer = Zero Pointer = Zero
9-8
SECTION 10
SPECIAL FUNCTIONS
This section covers the special functions that can be accessed by pressing the
SPECIAL software label key. These functions include:
l Skip
ONNNN
1 4xxxx
FUNCTION BLOCK
This function block contains one section. It contains the symbol SKP and a
constant up to 255, or a 4XXXX holding register reference. If a 4XXXX reference is
used it should be unique to this function block to avoid mishaps (for example,
using the same register to hold a counter value, etc.). The value specifies the
number of networks to be skipped. To skip the remainder of the networks in the
program, a value of zero is entered into the function block.
NOTE
INPUT
When the top, and only input, receives power, the remainder of the current network
and the remaining number of specified networks are skipped over by the
controller’s scan. The network in which the skip block is located is counted as the
first network to be skipped.
1o-1
SPECIAL FUNCTIONS
OUTPUT
There is no output with this function.
NOTE
EXAMPLE
The following paragraph provides a detailed explanation of the logic used in
Figure 10-l.
NETWORK: 7
--i
10001
H H t
10002 10003
SKP
When the Skip function block’s input receives power, the remainder of the network
containing the block (if any) is skipped and the next eighteen networks are
skipped. If network 7 contains the Skip function, the remainder of network 7, and
all of networks 8 through 25 are skipped. If there are only five networks left in the
program, the operation stops after the fifth network.
CONTROL+OK)-COMM OK
oxxxx
1xxxx
3xxxx
4xxxx
FUNCTION BLOCK
l This function block contains only one section. It contains the symbol OK and
any available reference:
1o-2
SPECIAL FUNCTIONS
NOTE
INPUT
l The top and only input is the control input. When it receives power, the user
variable reference is checked.
OUTPUT
l The top and only output passes power when the top input receives power and
the user variable status is OK.
EXAMPLE
The following paragraph provides a detailed explanation of the logic used in
Figure 10-2.
OK+-------_--_-----_-___
0
00002
When contact 10001 is energized, the OK contact receives power. The controller
checks to see if reference 40001 is OK to use. If the status is OK, coil 00002 is
energized.
lq
I
J
TABLE
:________r
L_______:
1 I
4xxxx
STAT
t
t-
TABLE
FULL
TABLE LENGTH
FUNCTION BLOCK
l The top section contains a 4XXXX holding register reference which holds the
pointer value. This pointer value indicates the total number of entries in the
table.
1o-3
SPECIAL FUNCTIONS
l The middle section contains a 4XXXX holding register reference. This register
holds the value which determines if the overall l/O channel status is monitored
or the rack/slot status of a particular channel is monitored. A zero specifies all
channels; a non-zero number specifies a particular channel. The table
containing the status information begins at 4XXXX+ 1; its size is defined in the
bottom section.
l The bottom section contains the symbol STAT and the numerical value that
specifies the table length. This constant can range from 1 to 100.
INPUTS
l The top input controls the operation. When it receives power, the status table
is generated. As each entry is made, the pointer is increased.
l The bottom input resets the pointer and destination table to zero.
OUTPUTS
l The top output passes power when the top input receives power.
l The middle output passes power when the table is full, pointer equals table
length.
l The bottom output passes power when the pointer is not equal to zero.
EXAMPLE
The following paragraphs provide a detailed explanation of the logic used in
Figure 10-3.
1 40020
10002
40030
STAT
0100
-’ l
If contact 10002 is ON, the STAT table is generated. If the table is full (POINTER
= SIZE), all outputs are ON and no further checking is done. If the table is not full,
checking continues and the appropriate number of unhealthy l/O is placed in the
table and the pointer is incremented. Testing continues until no more bad l/O STAT
are found, or until the table is full.
1o-4
SPECIAL FUNCTIONS
NOTE
SOURCE
CONTROL COPY
LONNNN I
3XXXX or 4XXXX
DESTINATION
ERROR
I I 4 1
FUNCTION BLOCK
l The top section contains the source. It can be a constant up to 9999, a 3XXXX
input register reference, or a 4XXXX holding register reference. If a reference
is used, the next consecutive reference 3XXXX + 1 (or 4XXXX + 1) is implied.
NOTE
Do not use implied references anywhere else.
l The bottom input, when receiving power, places a negative sign in the 5XXXX
double precision register. If this input is not receiving power, the value in the
5XXXX register is positive.
OUTPUTS
l The top output passes power when the top input receives power.
l The bottom output passes power when either, or both, registers in the top node
are greater than 9999. Error condition: operation not performed.
1o-5
SPECIAL FUNCTIONS
EXAMPLE
The following paragraph provides a detailed explanation of the logic used in
F-iglure 10-4.
30027
e-w-------
0
00007
When input 10001 is energized, the top input receives power. The value in register
30027 is multiplied by 10,000 and added to the value in register 30028. The result
is placed in register 50001 as a positive number because the bottom input is not
receiving power.
10.5 DOUBLE TO SINGLE PRECISION CONVERSION (5-+X)
FUNCTION
This function converts a double precision signed value from a SXXXX double
precision register to two single precision unsigned values in two holding registers.
5+X
4xxxx ERROR
FUNCTION BLOCK
l The top section contains the source. It is a SXXXX double precision register
reference.
l The bottom section contains the destination. It is a 4XXXX holding register
reference. The next consecutive holding register is implied (4XxXx+ 1).
INPUT
l The top input controls the operation. When it receives power, the top value is
split into two 4-digit values. The high order portion is placed in the 4XXXX
register. The low order portion is placed in 4XXXX+ 1.
OUTPUTS
l The top output passes power when the 5XXXX double precision register has a
negative sign.
l The bottom output passes power when the operation is performed and the
value in the top node is greater than 99999999..
NOTE
If the bottom output passes power, the top output cannot
pass power, even if the SXXXX register has a negative sign.
1O-6
SPECIAL FUNCTIONS
EXAMPLE
The following paragraph provides a detailed explanation of the logic used in
Figure 10-5.
-I ------w--e-
73
50002
0
10001 00003
5-X
40100
When input 10001 is energized, the top input receives power. The value in register
50002 is split into two 4-digit values. The high order portion is placed in register
40100. The low order portion is placed in register 40101. If the double precision
signed value is negative, the top output passes power to energize coil 00003.
Top Input Control Input Control Input Control Input Control Input Control Input
Middle Input - - - - -
Top Output Not Used Top Input Copy of Top Copy of Top Sign of SXXXX
Receives Power Input Input is Negative
and Status is
OK.
- - Pointer = -
Middle Output
Table Length
1o-7
SPECIAL FUNCTIONS
10.7.1 Subroutine
The Skip function can be used to create subroutines within a program. This is
useful when a routine needs to be performed every third, or fourth scan, etc. It is
also useful to perform a specific routine several times within a function. The Skip
functions allow the routine’s logic to be written once and performed as many times
as necessary.
The following example uses the SKIP function to allow a different routine to take
place each scan for a limited sequence.
The last network (i.e., 10) in the program contains an ADD block which adds a
one to the holding register (i.e., 40031) used in network 3’s Skip block.
On the first scan, at network 3 the controller skips to the end of the program
because 40031 contains zero. In network 10, a one is placed in 40031. On the next
scan at network 3, the controller skips to network 5. The first function is performed.
At the end of network 5 is a Skip block containing zero. The controller skips to the
end of the program, network 10, and adds a one to 40031, increasing it to two.
On the next scan at network 3, the controller skips to network 6. The second
function is performed. At the end of network 6 is a Skip block containing zero. The
controller skips to the end of the program and adds a one to register 40031,
increasing it to three.
On the next scan at network 3, the controller skips to network 7. The third function
is performed. At the end of network 7 is an ADD block which places a zero in
register 40031. The controller solves the rest of the logic in the program. At
network 10 a one is placed in register 40031.
On the next scan, the process starts all over again. The only difference is that the
controller skips to network 3 on this scan. It does not have to skip to the end of
the program first because there is already a one in register 40031.
NOTE
The logic in the last network of the program is performed
every scan. Logic which is common to three functions can
be placed in this network to avoid repeating the same logic
three times in the program.
1O-8
APPENDIX A
884 PC ERROR CODES
The P190 screen includes an error line for reporting the various P1901884 PC or
Modbus communications error conditions. The error codes which may appear, and
their meanings, are listed in this appendix.
The P190 reports three distinct classes of errors: Panel, PC Link and PC Command
errors.
Type 1, Panel Error, are Modbus communications errors detected by the P19O’s
software. Both transmitted and received Modbus communications packets are
examined. Sometimes the communication attempt is repeated several times
before an error is declared.
A-l
884 PC ERROR MESSAGE DEFINITIONS
022 to 068 are error code numbers not used at this time
A-2
884 PC ERROR MESSAGE DEFINITIONS
105 to 125 are error code numbers not used at this time.
A-3
APPENDIX B
PC MEMORY ERROR
If the PC encounters an error, the PC Memory Error screen appears. If the error
occurs during the initial loading of the programmer and configurator tape, press
the ALL MEMORY software label key. This initializes all PC memory.
If, however, this is not the initial loading, follow the recommended directions
displayed on the screen:
Enter “C” and press the INIT TABLE software label key. The next screen to appear
displays two software label keys: PROCEED and CANCEL. If the CANCEL software
label key is pressed, the current operation will not be completed and you will be
returned to the previous menu.
If the PROCEED software label key is pressed, the current operation will be
performed, and the Power-up and Attach screen reappears. Press the ATTACH
software label key and the PC Operations Menu screen appears.
B-l
APPENDIX C
PASSWORD OPERATIONS
The 884 PC and P190 use passwords to protect the 884 PC’s memory. The use of
a password is optional. If you do not enter a password, the system defaults to
Level 3. If a password has been entered it can only be changed by someone logged
on with Level 3 privleges. If you try to ATTACH to a password protected P1901884
PC and do not know the password, turn the Memory Protect key (on the P190) to
the UNLOCK position to proceed from the Password screen. There are four
password levels, each allowing a higher memory access than the previous. Level
0 does not require a password. The password can contain a maximum of eight
alphanumeric characters.
Level 0 - allows you to read any of the 884 PC’s memory except the password
table. If you ATTACH to a password protected P1901884 PC and do not know the
password, turn the Memory Protect key on the P190 to the UNLOCK position to
proceed from the Password screen. Memory cannot be altered.
Level 1 - allows you to write references, enable or disable coils and discrete
inputs and start, stop or clear the PC.
Level 2 - allows you to enter new networks and/or alter existing logic. Also the
scan rate and Modbus port parameters can be set.
Level 3 - allows you to configure the 884 PC’s I/O specifications. It also allows
the user to read and change the password table.
Access to any given level implies access to all the lower levels without use of the
associated passwords.
The password table is entered the first time the PC is configured. To enter
passwords, press the PSWD OPS software label key. The following software label
keys appear on the screen:
Type in the password and press the appropriate software label key (i.e., ENTER 2,
enters a level 2 password. When a password is entered into level 1, levels 2 and
3 receive the same password if they were previously blank, or if they contained the
same password.
When a password is entered into Level 2, level 3 receives the same password if
level 3 is blank or had the same password as level 2.
NOTE
C-l
PASSWORD OPERATIONS
If the level 3 password is deleted, and a level 2 password exists, the level 2
password is automatically displayed in level 3 as well as in level 2.
c-2
APPENDIX D
GLOSSARY
Address: A numeric value used to identify a specific l/O channel and/or module.
AND (Logical):
A mathematical operation between two bits. The result of the logical AND will be
a one (ON) bit only if both bits are one bits; otherwise, the result will be a zero (OFF)
bit. This operation can be performed between bits with each pair of bits, one from
each, examined by their relative location within each.
Arithmetic Function:
A type of logic used to add, subtract, multiply, or divide two numeric values. The
status of the output is governed by the result of the arithmetic operation:
additional overflow; comparisons (greater than, equal to, or less than); and illegal
division.
A unit of data transmission speed equal to the number of code elements (bits) per
second.
Binary:
A numeric system wherein values are represented only by numbers 1 and 0
(ON/OFF). Also called “base 2”. This system is commonly employed in modern
electronic hardware since circuits can be economically designed for ON/OFF
status.
Contraction of binary digit. A single number whose value can be either a ONE or
a ZERO. The smallest division of a PC word.
D-l
GLOSSARY
Cascade Function:
Connecting two or more functions together to control one output. For example,
timers and counters can be cascaded to produce results that cannot be achieved
by one counter or one timer.
Channel:
A group of l/O modules that are separately connected to the mainframe. For
example, a channel of l/O can contain up to 128 input points and 128 output points.
Counter:
A type of logic that is used to simulate the operation of external counters. In relay
panel hardware, an electromechanical device which can be wired and preset to
control other devices according to the total cycle of one ON or OFF function. In
a PC, a counter is internal to the processor, which is to say it is an electronic
function controlled by a user programmed instruction.
Cursor:
Visual movable pointer used on a CRT or programming panel by the programmer
to indicate where an instruction is to be added to the ladder diagram. The cursor
is also used for editing functions.
D-2
GLOSSARY
Digital:
Having discrete states. Digital logic can have up to 16 states. However, most
digital logic is binary logic with two states, ON or OFF.
Disable:
The capability to disconnect a logic coil or a discrete input from its normal control,
and force it unconditionally ON or OFF. (See Force.)
Discrete Reference:
A reference that can be either ON or OFF. A discrete reference can be an input,
output, or internal logic element.
Element:
The basic building block of the PC ladder logic. An element can be a relay contact,
horizontal short, vertical short, fixed numeric value, register reference, coil, or
function block. Sometimes refered to as a logic element.
E-nable:
To reconnect a logic coil or discrete input after it has been disabled. The opposite
of “Disable.”
Exclusive OR (XOR):
A mathematical operation between two bits. The result of the exclusive OR will be
a one (ON) bit only if either bit is a one bit. Only if they are both zeros (OFF) or both
ones (ON) will the result be a zero.
Force:
The function that can be used to change the state of a disabled reference. The
reference can be changed from OFF to ON or ON to OFF. This allows the user to
energize or de-energize any input or output by means of the program panel
independent of the PC program.
D-3
GLOSSARY
Hexadecimal:
The numbering system that represents all possible ON/OFF combinations of four
bits with sixteen unique digits (O-9 then A-F).
Inclusive OR:
A mathematical operation between two bits. The result of the inclusive OR will be
a one (ON) bit if either bit is a one bit or both bits are ones; only if both bits are
zeros (OFF) will the result be a zero. This operation can be performed between
groups of bits with each pair of bits examined by their relative location within
each.
Input:
A signal that provides information to the controller; can be either discrete input
(pushbutton, relay contacts, limit switches, etc.) or numeric input (thumbwheel,
external solid-state device, etc.)
Input Devices:
Devices such as limit switches, pressure switches, push buttons, etc., that supply
data to a programmable controller. These discrete inputs can have a common
return or an individual return (referred to as isolated inputs). Other inputs include
analog devices and digital encoders.
Ladder Diagram:
An industry standard for representing control logic relay systems with logic lines
representing rungs on a ladder. It expresses the user programmed logic of the
controller in relay equivalent symbology.
Ladder Listing:
A hardcopy listing of the user’s logic program.
Latch.
A
The type of coil that is retentive upon power failure. Can be used similar to a
latching relay. Normally, coils are reset to OFF conditions upon powerup; those
coils selected by the user as latched (L) will not be altered and thus retain their
previous condition (ON or OFF).
Logic:
A systematic interconnection of digital switching functions, circuits, or devices,
as in electronic digital computers.
Logic Diagram:
A graphic description of logic functions and conditions. It is used to find the result
of-an-addition of the contents of two registers; a logical compare of two matrices;
as well as other arithmetic operations.
D-4
GLOSSARY
Logic Element:
Any one of the elements that can be used in a ladder logic diagram. The elements
include relays, coils, shunts, timers, counters, arithmetic functions, and DX
functions.
Loqic Line:
A line of user logic used to construct the unique logic for the application.
Matrix Function:
Matrices are defined as sequential registers, each as 16 bits, up to a maximum of
100 registers (1600 bits). A group of consecutive registers referred to by logic, such
that individual bits can be utilized in lieu of numerical values. Bit operations that
can be performed include: COMPARE, MODIFY, SENSE, SHIFT, and ROTATE.
Memory:
Storage area for binary data and programs.
Memory Protect:
The hardware capability to prevent a portion of the memory from being altered by
an external device. This hardware feature is under keylock control.
Millisecond:
One thousandth of a second.
Move Function:
A DX capability which allows data to be transferred without modification within
the controller. Data can be transferred from a register to a table, from a table to
a register, or from a table to a table.
Network:
A group of logic elements that are connected together to perform a specific
function (e.g., a motor starter control circuit).
Node:
The smallest possible programming increment in a ladder logic diagram. (Most
logic elements require only one node, others require two or more nodes.)
One-Shot:
A discrete reference, typically a logic coil, that is energized (valid) for exactly one
scan of the controller’s logic.
output:
A signal,provided from the Controller to the “real world”; can be either discrete
output (e.g., solenoid valve, relay, motor starter, indicator lamp, etc.) or numeric
output (e.g. display of values stored within the controller).
D-5
GLOSSARY
Output Devices:
Devices such as solenoids, motor starters, etc., that receive signals from the
programmable controller.
Parity:
Method of verifying the accuracy of recorded data.
Parity Bit:
An additional bit added to a memory word to make the sum of the number of “l’s”
in a word always “even parity” or “odd parity.”
Port:
An l/O connection on a processor or peripheral device.
IPreset
The upper limit specified for a counter or timer function. When the specified preset
value is reached, an output is energized indicating the status of a counter or timer.
Program:
A sequence of instructions to be executed by the PC to control a machine or
process.
Ready Light:
A light located on the front of the PC indicating that, when lit, the controller’s
components are functioning properly.
Reference Numbers:
Numbers which identify the elements of the relay ladder logic. References can be
either discrete (logic coils, inputs, or sequencer steps) or register (input or
holding).
Register:
A location within the controller allocated to the storage of numerical values. All
holding registers are retentive on power failure. There are three types of registers:
input whose contents are controlled by the “real world” outside the controller;
holding registers whose contents are controlled from within the controller; and
output registers, which are special holding registers since their contents can also
be provided to the “real world”.
D-6
GLOSSARY
Relay:
An electromagnetic device operated by a variation in conditions of an electric
circuit. When so operated, it controls other devices such as switches.
Relay Element:
A logic symbol used to simulate the effect of a relay. Contacts can be normally
open, normally closed, or transitional contacts.
Run Light:
A light located on the front of the PC indicating that, when lit, logic is being
processed or solved.
Scan:
The technique of examining or solving logic networks one at a time in their
numeric order. After the last logic network is solved, the next scan begins at
network one; logic is always solved in this fixed cyclic process.
Scan Time:
The time it takes to completely execute the entire PC program once.
Skip Function:
This function allows a group of consecutive networks to be skipped or omitted in
the scanned logic solution. The status (ON/OFF) of all coils and the contents of
registers controlled by these networks are not altered when they are skipped.
Table:
A group of consecutive registers used to store numerical values.
Timer:
PC logic used to measure and record the time of an event or sequence of events.
Timers can accumulate time in either seconds, tenths of seconds, or hundredths
of seconds depending on the PC.
Traffic Cop:
A portion of the PC executive that controls how input and output data is
interpreted relative to its channel number and address index position.
Transitional Contact:
A contact which passes power for exactly one scan whenever the coil or discrete
input to which it is referenced is switched from OFF to ON, or ON to OFF
(depending upon the transitional type selected).
D-7
INDEX
--
ABSTRACT \
The 884 controller, system hardware capabilities, installation, troubleshooting, configuration, operation and
programming techniques,along with utilization of the P190 programmer are presented.Hands-on programming
labs are provided.
AUDIENCE
PREREQUISITES
Studentsshould have an understandingof electro-mechanicalcontrols, electrical circuits and basic relay ladder
diagrams. Course Ml00 (Introduction to Programmable Control) is designedto meet these prerequisites.
OBJECTIVES
Provided the prerequisitesare met, the studentcompletingthis coursewill be able to implement and maintain the
full capability of the 884 system.
The studentwill be able to install and power-up the system,attach the appropriate I/O and programmingdevice,
and also write, input and debug programs using the following programmable control functions:
TOPICAL OUTLINE
0520A 11/83
MODICON an AEG company
We are constantly striving to improve the content and usability of our technical documents. You can help us by answer-
ing the questions below and mailing this form to us. Also, if you find any errors or have any suggestions for improve-
ment, please let us know.
0 Programming Procedures
Y N
Are there any terms or concepts that are not defined clearly? 0 q
Y N
After reading this document, are you able to use the equipment? 0 0
What errors did you find in the manual? (Please include page numbers. Attach an extra sheet if necessary.)
Name Street
Title City
MODICON, Inc.
1 High Street
North Andover, MA 018459943
Customer Contact
Name:
Purchase Order No. Date Telephone:
Document
Sub Total
Total
Indicate your purchase order number and date. (You may prepay Payment
by enclosing a check for the full amount.) Terms are net 30 days from date of invoice. Unless otherwise stated,
partial shipments will generate partial invoices.
Give the part number, description, and quantity for each document Prices
ordered. Prices are subject to change without notice. Individual prices can be
found in the Publications Catalog or obtained by calling an Order Entry
Coordinator at I-800-468-5342.
NO POSTAGE
NECESSARY
IF MAILED
IN THE
UNITED STATES
MODICON, Inc.
1 High Street
North Andover, MA 018459943