Professional Documents
Culture Documents
PLC - Iec 61131 PDF
PLC - Iec 61131 PDF
This article gives a brief overview the PLC Software IEC1131-3 (also referred to as
through this document by its full title IEC61131-3) and covers the following:
During the last ten to fifteen years a wide range of different programming techniques has
been used to write programs for industrial control applications and for Programmable
Logic Controllers (PLCs). Control applications have been developed in BASIC, FORTH,
C, Structured English, Instruction List and numerous other proprietary languages
including various dialects of Ladder programming . Unfortunately, the only thing that can
be said of all of these programming languages is that they are all different. For people
involved with such systems from technicians, maintenance personnel, system designers
to plant managers, this results in inefficient use of time and money. There is clearly a
waste of human resources involved in training staff in skills in so many different control
languages.
Fortunately the international industrial community recognized that a new standard for
programmable logic controllers was required. A working group within the International
Electro-technical Commission (IEC) was set up to look at the complete design of
programmable logic controllers, including the hardware design, installation, testing,
documentation, programming and communications. The IEC as a sister organization to
the International Standardization Organization (ISO) based in Geneva, has committees
and working groups formed from representatives put forward by standardization bodies
of most industrial countries of the world.
During the early 1990s, the IEC published various parts of the IEC61131 standard that
covers the complete life-cycle of the Programmable Logic Controllers (PLCs), these are:
The IEC recognise that industrial instrumentation and control systems need an 'open
systems' approach to build large systems using equipment from different manufacturers.
Until the IEC 61131-3 standard was published in March 1993, there was no suitable
standard that defined the way control systems such as PLCs could be programmed.
Ladder Programming has become as one of the most popular graphical languages for
programming PLCs but unfortunately had a number of problems.
1. The ladder symbols and facilities vary between different PLC products.
2. Poor facilities for structured or hierarchical program decomposition,
3. Limited facilities for software re-use,
4. Poor facilities for addressing and manipulating data structures,
5. Limited facilities for building complex sequences,
6. Limited control over program execution,
7. Facilities for arithmetic operations are cumbersome.
For people who work with PLCs everyday, this summary may seem to be somewhat
harsh. With very good programming standards, use of program generators, off-line
documentation tools and the application of information technology (IT) using databases
to manage data addressing and so on, many of these deficiencies can be circumvented
to some degree but never completely ignored. The IEC61131-3 PLC languages do not
exhibit these weaknesses and will significantly improve the quality of PLC software.
The standard requires that there is strong data typing. This means that the IEC
languages reduce programming errors where a programmer erroneously attempts to
write the wrong type of data to a variable.
Facilities are provided so that different parts of a program can be executed at different
times, at different rates and in parallel, i.e. there is support for full execution control, i.e.
different parts can scan at different rates under the control of 'tasks'.
There is full support for describing sequences so that complex sequential behaviour
can be easily broken down using a concise graphical language called Sequential
Function Chart. This allows a sequence to be described in terms of steps, their actions
and transitions between steps.
There is support for defining data structures so that data elements that are associated
can be passed between different parts of a program as if they were a single entity. It is
then possible to pass complex information as a single variable between different
program organisation units. This improves program readability and ensures that
associated data is always accessed correctly.
The standard provides flexible language selection, i.e. a set of three graphical and two
textual languages for expressing different parts of a control application. The system
designer is free to choose the language that is most suitable to solve a part of an
application program. Different parts of a program can be expressed in any of the
languages.
Structured Text (ST) - A high level textual language that encourages structured
programming. It has a language structure (syntax) that strongly resembles PASCAL and
supports a wide range of standard functions and operators. The standard includes a
formal syntax definition of ST.
Fig 1 Structured Text Language
Function Block Diagram (FBD) - A graphical language for depicting signal and
data flows through function blocks - re-usable software elements. FBD is very useful for
expressing the interconnection of control system algorithms and logic.
Ladder Diagram (LD) - A graphical language that is based on the relay ladder logic
- a technique commonly used to program current generation PLCs. However, the IEC
Ladder Diagram language also allows the connection of user defined function blocks and
functions and so can be used in a hierarchical design.
Fig 3 Ladder Diagram Language
Instruction List (IL) - A low level 'assembler like' language that is based on similar
instruction list languages found in a wide range of today's PLCs.