Page 32

Petruzella_ProgrammableLogicControllers__5e

F T T F T T F T T T Input file (I) Slot (3) Bit (12) I:3/12 Closed switch 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 Input image table file 1 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 I:3/12 Bit address I:3 O:4 12 6 L1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 Rung 0 Rung 1 Rung 2 86 Chapter 5  Basics of PLC Programming having logical continuity. When logical continuity exists in at least one path, the rung condition and Output Energize instruction are said to be true. The rung condition and OTE instruction are false if no logical continuity path has been established. During controller operation, the processor evaluates the rung logic and changes the state of the outputs according to the logical continuity of rungs. 5.5  Instruction Addressing To complete the entry of a relay-type instruction, you must assign an address to each instruction. This address indicates what PLC input is connected to what input device and what PLC output will drive what output device. The addressing of real inputs and outputs, as well as internals, depends on the PLC model used. Addressing formats can vary from one PLC family to another as well as for different manufacturers. These addresses can be represented in decimal, octal, or hexadecimal depending on the number system used by the PLC. The address identifies the function of an instruction and links it to a particular bit in the data table portion of the memory. Figure 5-27 shows the addressing format for an Allen-Bradley SLC 500 controller. Addresses contain the slot number of the module where input or output devices are connected. Addresses are formatted as file type, file number, slot number, and bit. Each contact or coil symbol is referenced with an address that identifies what is being evaluated and what is being controlled. The same contact instruction can be used throughout the program whenever that condition needs to be evaluated. While this is true for the XIO and XIC contact instructions, the same cannot be said for the OTE coil instruction. A common mistake for the novice programmer is to place the same addressed OTE instruction on multiple rungs within the same program. This practice is to be avoided since it will lead to unpredictable program outcomes. The number of ladder logic relays and input and output instructions is limited only by memory size. Most PLCs allow more than one output per rung. For an output to be activated or energized, at least one left-to-right true logical path must exist, as illustrated in Figure 5-26. A complete closed path is referred to as Output file (O) Slot (4) Bit (6) Energized output Output image table file 0 O:4/6 Bit address User-programmed rung Figure 5-27  Addressing format for an Allen-Bradley SLC 500 controller. O:4/6 L2 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 Figure 5-26  Logical continuity. T T


Petruzella_ProgrammableLogicControllers__5e
To see the actual publication please follow the link above