0% found this document useful (0 votes)
3 views

lecture58 Function Blockspptx

The document explains function block diagrams (FBD) used in programming, particularly for logic gates and their representations in PLC programs. It details standard circuit symbols for logic gates, the relationship between ladder diagrams and FBDs, and provides examples of Boolean expressions and their corresponding ladder diagrams. Additionally, it illustrates practical applications of these concepts in controlling systems like pumps and valves.

Uploaded by

altyebmusab
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views

lecture58 Function Blockspptx

The document explains function block diagrams (FBD) used in programming, particularly for logic gates and their representations in PLC programs. It details standard circuit symbols for logic gates, the relationship between ladder diagrams and FBDs, and provides examples of Boolean expressions and their corresponding ladder diagrams. Additionally, it illustrates practical applications of these concepts in controlling systems like pumps and valves.

Uploaded by

altyebmusab
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 25

Function blocks

The function block diagram (FBD is a program instruction unit


which, when executed, yields one or more output values. Thus a
block is represented in the manner shown in the figure with the
function name written in the box. Function blocks can have
standard functions, such as those of the logic gates or counters or
times, or have functions defined by the user, e.g. a block to obtain
an average value of inputs.
Function blocks

Programs are often concerned with logic gates. Two forms of


standard circuit symbols are used for logic gates, one having
originated in the United States and the other being an international
standard form (IEEE/ANSI) which uses a rectangle with the logic
function written inside it. The 1 in a box indicates that there is an
output when the input is 1. The OR function is given by ≥1, this is
because there is an output if an input is greater than or equal to 1.
Logic gates
A negated input is represented by a small circle on the input, a
negative output by a small circle on the output. (Figure 2 )

Loading…
Figure 2 (a) Negated input, (b) negated output
Figure 3 shows the symbols. In FBD diagrams the notation used
in the IEEE/ANSI form is often encountered. Figures below shows
the effect of such functional blocks in PLC programs
Logic gates

AND gate OR gate NOT gate

Figure 3 Logic gate symbols


Logic gates

NAND gate
Loading…
NOR gate XOR gate

Figure 3 Logic gate symbols

Figure 4 shows the effect of such functional blocks in PLC


programs.
Logic gates

AND
function

AND
function Figure 4
Logic gates

OR function

OR function
Logic gates

OR function

NOR function
Logic gates

XOR function

XOR function
Ladder diagram and equivalent

functional block diagram


To illustrate the form of such a diagram and its relationship to the
ladder diagram, Figure 5 shows an OR gate. When A or B inputs
are 1 then there is an output.

Figure 5 Ladder diagram and equivalent functional block diagram


Ladder diagram and equivalent
functional block diagram
a ladder diagram involving the output having contacts acting as an
input. The function block diagram equivalent can be shown as a
feedback loop.
Loading…

Figure 6 Ladder diagram and equivalent function block diagram


Siemens notation

a ladder diagram and its function block equivalent in Siemens


notation. The = block is used to indicate an output from the system.

Figure 7 Ladder diagram and equivalent function block diagram


example
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.
example
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.

Figure 8 Pump application


Ladder programs can be derived from Boolean expressions since

we are concerned with a mathematical system of logic. In Boolean


algebra there are just two digits, 0 and 1. When we have an AND
operation for inputs A and B then we can write:
A.B = Q
where Q is the output.
Thus Q is equal to 1 only when A = 1 and B = 1. The OR operation
for inputs A and B is written as:
A+B=Q
Thus Q is equal to 1 only when A = 1 or B = 1. The NOT operation
for an input A is written as:
A=Q

Thus when A is not 1 there is an output. As an illustration of how


we can relate Boolean expressions with ladder diagrams, consider
the expression:
A + B$C = Q
This tells us that we have A or the term B and C giving the output
Q. Figure 9 shows the ladder and functional block diagrams.
Written in terms of Mitsubishi notation, the above expression
might be:
X400 + X401$X402 = Y430
In Siemens notation it might be:
I0.0 + I0.1.I0.2 = Q2.0

Figure 9 Ladder diagram


As a further illustration, consider the Boolean expression:
A+B=Q
Figure 10 shows the ladder and functional block diagrams.

Figure 10 Ladder diagram


Written in terms of Mitsubishi notation, the expression might
be:
X400 + X401 = Y430
and in Siemens notation:
I0.0 + I0.1 = Q2.0
Figure 11 XOR gate
Consider the exclusive-OR gate and its assembly from NOT,
AND and OR gates (Figure 11)
The input to the bottom AND gate is:
A and
and so its output is:
The input to the bottom AND gate is:
and so its output is:
The input to the top AND gate is:
and so its output is:
Thus the Boolean expression for the output from the OR gate is:

Consider a logic diagram with many inputs, as shown in Figure


5.35,and its representation by a Boolean expression and a ladder
rung.
For inputs A and B we obtain an output from the upper AND gate of
A$B. From the OR gate we obtain an output of A$B + C. From the
lower AND gate we obtain an output Q of:
The ladder diagram to represent this is shown in Figure 5.36.
Program examples
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.
For the inputs from the pump and the pressure sensors we have an
AND logic situation since both are required if there is to be an

output from the lamp. We, however, have an OR logic situation


with the test switch in that it is required to give an output of lamp
on regardless of whether there is a signal from the AND system.
Program examples
The function block diagram and the ladder diagram are thus of the
form shown in Figure 5.37. Note that with the ladder diagram we
tell the PLC when it has reached the end of the program by the use
of the END or RET instruction.
Program examples
consider 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. We have an OR situation for the
two switches and an AND situation involving the two switches and
the pump. Figure 5.38 shows a possible program.

You might also like