130
SECTION
2
Components
and Systems
Industrial Text & Video Company 1-800-752-8398
www.industrialtext.com
CHAPTER
5
The Memory System
and I/O Interaction
The input/output structure of a programmable controller is designed with one
thing in mind—simplicity. Input/output field devices are connected to a
PLC’s I/O modules, which are located in the rack (the physical enclosure that
houses a PLC’s supplementary devices). The rack location of each I/O device
is then mapped to the I/O table, where the I/O module placement defines the
address of the devices connected to the module. Some PLCs use internal
module switches to define the addresses used by the devices connected to the
module. In the end, however, all of the input and output connections are
mapped to the I/O table.
Assume that a simple relay circuit contains a limit switch driving a pilot light
(see Figure 5-17). This circuit is to be connected to a PLC input module and
output module, as shown in Figure 5-18. For the purpose of our discussion,
let’s assume that each module contains 8 possible input or output channels
and that the PLC has a memory map similar to the one shown previously in
Figure 5-15. The limit switch is connected to the number 5 (octal) terminal of
the input module, while the light is connected to the number 6 (octal) terminal
of the output module.
LS
Hardwired Logic
PL
L1 L2
Figure 5-17. A relay circuit with a limit switch driving a pilot light.
Let’s assume that, due to their placement inside the rack, the I/O modules’
map addresses are word 0000 for the input module and word 0010 for the
output module. Therefore, the processor will reference the limit switch as
input 000005, and it will reference the light as output 001006 (i.e., the input
is mapped to word 0000 bit 05, and the output is mapped to word 0010 bit 06).
These addresses are mapped to the I/O table. Every time the processor reads
the inputs, it will update the input table and turn ON those bits whose input
devices are 1 (ON or closed). When the processor begins the execution of the
ladder program, it will provide power (i.e., continuity) to the ladder element
corresponding to the limit switch, because its reference address is 1 (see
Figure 5-18). At this time, it will set output 001006 ON, and the pilot light
will turn ON after all instructions have been evaluated and the end of scan
(EOS)—where the output update to the module takes place—has been
reached. This operation is repeated every scan, which can be as fast as every
thousandth of a second (1 msec) or less.