We have discussed many PLC ladder logic examples on our blog and in this article, we are going to see another example. To understand this concept, we have taken the example of lamps that will be controlled with the use of different push buttons.
In the previous article, we have seen the same example for controlling the lamp outputs but it was using switches. In this post, we are going to make use of push buttons.
In this article, we are going to see how to draw a ladder logic diagram for controlling the lamp outputs using PLC. One should note that these are the basic examples of PLC ladder logic examples for PLC ladder logic practices.
Table of Contents
PLC Ladder Logic Example 5
In this ladder logic example, we will see how to draw a ladder logic diagram to control the lamp outputs of a system using push buttons. Lamps are just a representation of output, one can take different parameters like motors, pumps as an output.
Draw a ladder logic diagram to control the lamp output as per the given logic. Make use of only push buttons.
- Start and stop the system using the start push button and stop push button.
- Pressing Push Button PB1 turns lamps L1 and L2 ON.
- Pressing Push Button PB2 turns lamps L3 and L4 ON.
- Pressing Push Button PB3 turns lamps L1 and L3 OFF.
- Pressing Push Button PB4 turns lamps L2 and L4 OFF.
- Pressing Push Button PB5 turns ON all lamps.
Write down a ladder logic diagram for the above problem statement.
List of Input and Output Tags
In this PLC ladder logic example, we have used 7 inputs, 4 outputs, and 6 memories.
|I0.0||START PUSH BUTTON (PB)||INPUT|
|M0.1||PB 1 MEMORY||MEMORY|
|M0.2||PB 2 MEMORY||MEMORY|
|M0.3||PB 3 MEMORY||MEMORY|
|M0.4||PB 4 MEMORY||MEMORY|
|M0.5||PB 5 MEMORY||MEMORY|
Ladder Logic Diagram of Example 5
In this PLC ladder logic example, we have used Siemens S7-1500 PLC and Siemens TIA portal for programming a ladder logic diagram. The PLC we selected has a work memory of 250 kB, 24 V DC power supply with 24V DC 32 digital inputs, 16 digital outputs, 4 analog inputs, and 2 analog outputs on board.
We have seen the same problem statement but with switches in the previous example 4. As in this example, we are using pushbuttons, to set the input even after releasing the push button, latching is required.
Hence, we are going to divide the program into 3 networks for our better understanding.
It is the cycle Start and Stop network. Push Button (PB) is used for starting and stopping purposes.
A Normally Closed (NC) input is taken for Stopping the cycle. A Normally Open (NO) input is taken to start the cycle. A memory (M0.0) is taken that will be used in further networks. This memory is latched to the Start PB.
The cycle is started by pressing START PB (I0.0) and is stopped by pressing STOP PB(I0.1). In our case, STOP PB act as push button 6 as per the problem statement.
Network 2 is used only to create memories of respective push buttons that will be further used in the main program in network 3.
As shown in the above figure, the push button memory is latched with its respective push button.
Network 3 contains the main program that gives desired outputs for the given problem statement.
PB 1 memory (N.O) is connected in series to the output lamps L1 and L2. Similarly, PB 2 memory (N.O) is connected in series to the output lamps L3 and L4.
For lamp L1, PB 3 memory (N.C) and PB 5 memory (N.O) are connected in parallel. Similarly, for lamp L2, PB 4 memory (N.C) and PB 5 memory (N.O) are connected in parallel.
For lamp L3, PB 3 memory (N.C) and PB 5 memory (N.O) are connected in parallel. Similarly, for lamp L4, PB 4 memory (N.C) and PB 5 memory (N.O) are connected in parallel.
Working of Network 3
- When PB 1 is turned ON, PB1 memory turns ON, and lamps L1 and L2 are turned ON. Similarly, when PB 2 is turned ON, PB2 memory turns ON, and lamps L3 and L4 are turned ON.
- When PB 3 is turned ON, PB 3 memory turns ON, and PB 3 memory (N.C) in the network becomes (N.O) and this will turn OFF lamps L1 and L3.
- When PB 4 is turned ON, PB 4 memory turns ON, and PB 4 memory (N.C) in the network becomes (N.O) and this will turn OFF lamps L1 and L3.
- When PB 5 is turned ON, PB 5 memory turns ON, all the outputs i.e lamps L1, L2, L3, and L4 will turn ON.