Название: Programmable Logic Controllers
Автор: Su Chen Jonathon Lin
Издательство: Ingram
Жанр: Физика
isbn: 9780831193690
isbn:
4.5.2The AND Function
The AND function has the input elements connected in a series manner. Three examples are shown in Figure 4.16. Next to each Boolean expression is a ladder rung representation of the expression.
4.5.3The OR Function
The OR function has the input elements connected in a parallel manner. Three examples are given in Figure 4.17.
Figure 4.15: NOT functions
Figure 4.16: AND functions
Figure 4.17: OR functions
4.6 Converting Boolean Equations to Ladder Diagrams
There are two types of elements — input and output — that constitute a relay ladder diagram. Input elements can be further divided into groups: relay contacts, and switches. The state of relay contacts is controlled by their associated relay. Because they are not the actual input devices, they are referred to as internal inputs. Table 4.5 shows the graphical symbol and logic expression of typical input elements.
4.6.1Procedure of Converting Boolean Equations to Ladder Diagrams
Most control circuits consist of multiple Boolean equations with combined logic functions. This means there are multiple rungs in the ladder diagram. In principle, each Boolean equation produces one rung in the ladder diagram.
The procedure for converting Boolean equations to ladder logic diagrams has three steps.
Step 1: Identify output elements.
Each Boolean equation has one and only one output element. Therefore, the number of Boolean equations determines the number of output elements. The element on the left side of the equal sign of the Boolean equation is normally the output element.
Step 2: Identify the internal input elements and switch input elements.
All elements appearing on the right side of Boolean equations are input elements. To distinguish an internal input element from a switch input element, determine if the element appears in both sides of the equation. If an element symbol appears in both sides of Boolean equations, it is the internal input element. This means that this element is a contact controlled by its relay coil and has the same label as an output in Boolean equations.
Step 3: Construct the ladder diagram.
In principle, one Boolean equation is constructed as one rung in the ladder diagram. The output element is the last element in the rung. The AND or OR functions between input elements are converted, as in Table 4.6.
Table 4.5: Input elements
Input Element | Symbol | Logic Expression |
---|---|---|
Contact A (NO) | A | |
Contact A (NC) | ||
Limit switch LS (NO) | LS | |
Limit switch LS (NC) | ||
Push button PB (NO) | PB | |
Push button PB (NC) | ||
Pressure switch PS (NO) | PS | |
Pressure switch PS (NC) | ||
Temperature switch TS (NO) | TS | |
Temperature switch TS (NC) | ||
Photodetector PD (NC) | PD | |
Photodetector PD (NO) | ||
Liquid level switch LL (NO) | LL | |
Liquid level switch LL (NC) |
Table 4.6: Logic AND and OR functions
The NOT function is interpreted as a normally closed (NC) state. It can be either a normally closed (NC) switch or normally closed (NC) contact (Figure 4.18). An input element without the NOT function is the normally open type. It can be either a normally open (NO) switch or normally open (NO) contact (Figure 4.19).
4.6.2Converting Examples
The two examples presented in this section show how to convert Boolean equations to their equivalent ladder diagrams.
Example 4.4: Convert these two Boolean equations to a ladder diagram.
The two Xs appearing in the right side of two equations are the contact controlled by the output relay X. Therefore, they shall be represented by a contact symbol. The way to determine whether an input element is an internal input or an external input is to determine if an element symbol appears in both sides of the equations. Because it does, it becomes an internal (contact) input in the right side of both equations. The ladder diagram of these two equations appears as Figure 4.20.
Example 4.5: Convert these three Boolean equations to a ladder diagram.
Figure СКАЧАТЬ