IEC 61131 Programming Using Ladder, Structured Text and Function Block
With many PLC programming software packages today, you’ll have options for the type of programming languages available.
Languages such as the traditional PLC ladder logic, text-based Structured Text and Function Block Diagram language methods, and a few more.
In this course, you will learn about three of the five most common programming languages defined by IEC 61131-3 and we will apply these languages to a simple application for you to examine the advantages of each.
IEC 61131 is an IEC standard for programmable controllers. It was known as IEC 1131 before the change in the numbering system by IEC. Part 3 is for standardizing programming languages. IEC 61131 is the first international standard for process control software.
An advantage to using IEC 61131, is that a programmer can develop a control program for a particular brand of the controller and import that same program to another PLC brand with minimum modifications.
If you work for an automation solutions provider serving multiple industries providing multiple PLC solutions this standard will be useful in supporting different customers using different PLCs as their in-house standard.
Using defined logic for solutions, ideally, you could cut-copy-paste code from one controller to another. Ask your PLC supplier if their programming software is IEC 61131-3 compliant. But for the most part to many automation software companies, just providing multiple IEC 61131 type languages signifies compliance.
In this course, we will be using Studio 5000 from Rockwell Automation to provide samples of language code performing the same functionality in controlling water level in a tank using an output valve, a pump, and a level transmitter.
The pump will have a turn on a setpoint of 14 feet and a shut-off setpoint of 2 feet. The valve will open when the pump turns ON and Close when the pump turns OFF.
For the three language types, we will create the Ladder routine, which is one of the three IEC-61131 routines.
- First, let’s create the ladder routine. Right-click over the MainProgram folder, select Add, and then New Routine. For the Name, we will type in RealPars_Ladder, and for the Type, we ...
Before we begin to program the Ladder routine, we went ahead and added a few rungs of ladder logic to simulate the tank level. If you would like to follow along, the Studio file, named RealPars_IEC61131 can be downloaded from this link: https://bit.ly/3sPXOO2
- The first three rungs in the MainRo...
Let’s begin to program the ladder logic routine.
We will add two new rungs to our ladder routine.
We use a greater than or equal element that compares the tank level tag, with the pump start setpoint tag, and latches the SoftWaterTank.PumpStarter and SoftWaterTank.WaterValve coils.
Let’s startup Studio 5000, and select the program RealPars_IEC61131, previously created in the first section.
After the Studio 5000 program starts up, the “Logic Designer GUI” appears. In the “Controller Organizer Area” - “Tasks” folder - “MainProgram” folder, we can see the three different progr...