Professional Documents
Culture Documents
6. A particular device can appear in more than one rung of a ladder. For example, we might have a
relay which switches on one or more devices. The same letters and/or numbers are used to label
the device in each situation.
7. The inputs and outputs are all identified by their addresses, the notation used depending on the
PLC manufacturer. This is the address of the input or output in the memory of the PLC.
Basic Example
In
drawing
ladder
When there is an input to the switch, it opens and there is then no current in
the circuit. This illustrates a NOT gate in that there is an output when there is no
input and no output when there is an input. The gate is sometimes referred to as an
inverter.
When input A and input B are both not activated, there is a 1 output. When
either X400
or X401 are 1 there is a 0 output.
XOR
The OR gate gives an output when either or both of the inputs are 1.
Sometimes there is, however, a need for a gate that gives an output when either of
the inputs is
1 but not when both are 1. Such a gate is called
an Exclusive
OR or XOR gate. One way of
obtaining such a
gate is by using NOT, AND
and OR
gates.
When input A and input B are not activated then there is 0 output. When just
input A is activated, then the upper branch results in the output being 1. When just
input B is activated, then the lower branch results in the output being 1. When both
input A and input B are activated, there is no output.
In this example of a logic gate, input A and input B have two sets ofcontac ts
in the circuits, one set being normally open and the other normally closed. With PLC
programming, each input may have as many sets of contacts as necessary.
There are often situations where it is necessary to hold an output energised,
even when the input ceases. A simple example of such a situation is a motor which
is started by pressing a push button switch. Though the switch contacts do not
remain closed, the motor is required to continue running until a stop push button
switch is pressed. The term latch circuit is used for the circuit used to carry out
such an operation. It is a self-maintaining circuit in that, after being energised, it
maintains that state until another input is received.
With ladder diagrams, there can be more than one output connected to a
contact. When the input contacts close both the coils give outputs.
SEQUENTIAL OUTPUTS
FUNCTION BLOCKS
The term function block diagram (FBD) is used for PLC programs
described in terms of graphical blocks. It is described as being a graphical language
for depicting signal and data flows through blocks, these being reusable software
elements. A function block is a program instruction unit which, when executed,
yields one or more output values.
Consider the development of a function block diagram and ladder diagram for
an application in which a pump is required to be activated and pump liquid into a
tank when the start switch is closed, the level of liquid in the tank is below the
required level and there is liquid in the reservoir from which it is to be pumped.
What is required is an AND logic situation between the start switch input and
a sensor input which is on when the liquid in the tank is below the required level.
We might have a switch which is on until the liquid is at the required level. These
two elements are then in an AND logic situation with a switch indicating that there is
liquid in the reservoir. Suppose this switch gives an input when there is liquid.
PROGRAM EXAMPLES
1) A signal lamp is required to be switched on if a pump is running and the
pressure is satisfactory, or if the lamp test switch is closed.
2) A valve which is to be operated to lift a load when a pump is running and either the lift switch is
operated or a switch operated indicating that the load has not already been lifted and is at the
bottom of its lift channel.
3) Consider a system where there has to be no output when any one of four sensors gives an output,
otherwise there is to be an output.