PLCs, DCSs & Controllers


PLC programming standards

July 2007 PLCs, DCSs & Controllers

Why consider standardisation?


According to the PLCOpen organisation, standardising the programming interface harmonises the way people design and operate industrial controls. A standard programming interface allows people with different backgrounds and skills to create different elements of a program during different stages of the software lifecycle: specification, design, implementation, testing, installation and maintenance. Yet all pieces adhere to a common structure and work together harmoniously. Decomposition into logical elements, modularisation and modern software techniques result in programs that are structured, have increased re-usability, fewer errors and that are developed more efficiently.

Standardisation facilitates training by allowing users to learn on one model of hardware, but apply common techniques to all compatible hardware. This approach also facilitates maintainability and removes subjectivity from software development making code and is immediately familiar, even if not developed by the reader of that code.

What standards and guidelines are available?

IEC 61131-3

The primary standard available for programmable logic controller (PLC) programming is defined in IEC 61131. This standard has been embraced by many other international standards organisations. For example, the American National Electrical Manufacturers Association (NEMA) standard IA 2.3-2005 is based on IEC 61131-3 as is the British Standard BS EN 61131-3.

IEC61131-3 programming model
IEC61131-3 programming model

There are other bodies that have developed their own industry related standards, but these do not generally go into the same prescriptive depth as IEC 61131 and tend to be more application specific.

IEC61131-3 sequential function chart steps, action blocks and transitions
IEC61131-3 sequential function chart steps, action blocks and transitions

IEC61131-3 four programming languages
IEC61131-3 four programming languages

IEC61131-3 function block example
IEC61131-3 function block example

US Food and Drug Administration

In pharmaceutical manufacturing, systems have to be formally validated before they can be put into production. The US Food and Drug Administration (FDA) has published 'General Principles of Software Validation; Final Guidance for Industry and FDA Staff'. This requires documentation of the software lifecyle, within which a software design specification (SDS) is required. Development procedures and coding guidelines are an important element of the SDS.

A key paragraph in this document reads:

"Firms frequently adopt specific coding guidelines that establish quality policies and procedures related to the software coding process. Source code should be evaluated to verify its compliance with specified coding guidelines. Such guidelines should include coding conventions regarding clarity, style, complexity management, and commenting. Code comments should provide useful and descriptive information for a module, including expected inputs and outputs, variables referenced, expected data types, and operations to be performed. Source code should also be evaluated to verify its compliance with the corresponding detailed design specification. Modules ready for integration and test should have documentation of compliance with coding guidelines and any other applicable quality policies and procedures."

OMAC

Another body involved in automation standards initiatives is OMAC. On 13 December, 1994, Chrysler, Ford, and General Motors published version 1.1 of 'Requirements of Open, Modular Architecture Controllers for Applications in the Automotive Industry'. The document provided guidelines for a common set of APIs for US industry controllers to better address manufacturing needs for the automotive industry. The requirements for the development are defined in the OMAC Requirements Document whose signatories are Chrysler, Ford, and General Motors. This ultimately led to the establishment of the Open Modular Architecture Controls (OMAC) Users Group. One of the purposes of this group is to establish a specific set of APIs to be used by vendors to sell controller products and services to the aerospace and automotive industries. Another activity in OMAC is the Packaging Workgroup. It deals with a common approach to future product development by the packaging machinery builders that will include more electronic controls from the general motion control (GMC) industry.

Although industry-specific in nature, OMAC has also embraced IEC 61131-3 as its programming guideline.

Black Liquor Recovery Boiler Advisory Committee

The Black Liquor Recovery Boiler Advisory Committee (BLRBAC) covers application specific requirements in its document 'Recommended Good Practice - Safe Firing of Black Liquor in Black Liquor Recovery Boilers'.

IEC 61499

IEC 61499 is an evolving standard which defines a generic architecture and presents guidelines for the use of function blocks in distributed industrial-process measurement and control systems (IPMCSs), or more simply distributed control systems (DCSs). This standard presents the architecture in terms of implementable reference models, textual syntax and graphical representations.

IEC 61131

This standard is broken down into:

* IEC 61131-1 Programmable controllers - Part 1: General information.

* IEC 61131-2:2003 Programmable controllers - Part 2: Equipment requirements and tests.

* IEC 61131-3:2003, Programmable controllers - Part 3: Programming languages.

* IEC 61131-4:2004 Programmable controllers - Part 4: User guidelines.

* IEC 61131-5:2000 Programmable controllers - Part 5: Communications.

* IEC 61131-7: Programmable controllers - Part 7: Fuzzy control programming.

* IEC 61131-8:2003 Programmable controllers - Part 8: Guidelines for the application and implementation of programming languages.

The main sections of interest from a PLC programming standards standpoint are IEC 61131-3, 61131-4 and 61131-8.

IEC 61131-3 specifies syntax and semantics of programming languages for programmable controllers, 61131-4 is general in nature but does address some safety related matters, while 61131-8 applies to the programming of programmable controller systems using the programming languages defined in IEC 61131-3. It also provides guidelines for the implementation of these languages in programmable controller systems and their programming support environments (PSEs).

One standard, four languages

The standard includes the definition of the sequential function chart (SFC) language, used to structure the internal organisation of a program, and four inter-operable programming languages: instruction list (IL), ladder diagram (LD), function block diagram (FBD) and structured text (ST). Via decomposition into logical elements, modularisation and modern software techniques, each program is structured, increasing its re-usability, reducing errors and increasing programming and user efficiency.

PLCOpen

The main user resource for IEC 61131 is PLCOpen which was founded in 1992 and is headquartered in The Netherlands. PLCOpen is a vendor- and product-independent worldwide association whose mission is to be the leading association resolving topics related to control programming and to support the use of international standards in this field.

PLCopen has supporting offices in Canada, Tokyo, Japan and China.

The organisation has extensive online resources, and ongoing projects concerning the development and application of standards for special application areas such as motion control and packaging.

For more information contact Andrew Ashton, Technews, +27 (0)11 886 3640, andrew.ashton@technews.co.za, www.instrumentation.co.za



Credit(s)



Share this article:
Share via emailShare via LinkedInPrint this page

Further reading:

The convergence of intelligence: DCS, SCADA and TLC
Schneider Electric South Africa PLCs, DCSs & Controllers
In the early days of industrialisation, control systems were primarily mechanical, and relied on manual intervention and simple feedback loops to manage processes. Now, in the 21st century, industrial process automation systems are mind-blowingly intelligent, and provide almost unparalleled control and monitoring capabilities, making them integral to modern industrial systems.

Read more...
PC-based control for advanced hydrogen storage technology
Beckhoff Automation Editor's Choice PLCs, DCSs & Controllers
The proportion of renewable energies from solar, wind and water is rising continuously. However, sufficient storage options are of the essence to use these energies as efficiently as possible. GKN Hydrogen offers a particularly compact and safe option, low-pressure metal hydride hydrogen storage systems with PC-based control from Beckhoff.

Read more...
ABB modernises key board mill
ABB South Africa PLCs, DCSs & Controllers
ABB has secured a landmark contract to modernise Smurfit Kappa’s Paper Machine 5 at its corrugated cardboard mill near Mexico City. ABB will provide Smurfit Kappa with DCS, accompanied by a comprehensive paper machine drives system, encompassing some of the market’s most advanced drives and motors meticulously designed to optimise PM5’s performance.

Read more...
From the editor's desk: The inhuman truth
Technews Publishing (SA Instrumentation & Control) News
Among all the hype about generative AI, an over-the-top app that attracted my attention was NewsGPT. This claims to be a bias-free news channel with no reporters, and is an alternative to normal news. ...

Read more...
The synapses of the distributed control system
Schneider Electric South Africa PLCs, DCSs & Controllers
Industrial operations require a distributed control system (DCS) to coordinate and control their process subsystems in real time. Like the brain, a DCS is a multitasking maestro, controlling and coordinating complex processes in a myriad of industrial setting such as large manufacturing plants, providing valuable top-down control.

Read more...
Modular assembly platform for clean manufacturing
Beckhoff Automation PLCs, DCSs & Controllers
JR Automation delivers custom automated solutions for numerous industries. It has done this through its scalable, modular automation platform, FlexChassis, which speeds up time to market while cutting costs. The company chose the XTS linear transport system from Beckhoff because of its speed, and modular design that allows for multiple configurations.

Read more...
Selecting the best remote access solution for your application
PLCs, DCSs & Controllers
In today’s Internet of Things (IoT) world, remote mobile access is a necessity for many industrial applications. There are several ways of implementing this connectivity with routers and virtual private networks.

Read more...
PLCs and PACs simplify data acquisition
PLCs, DCSs & Controllers
Data acquisition, data logging and data analysis are required functions for most modern industrial control systems. The simplest and lowest cost way to provide these functions is often by using the same platform providing real-time control, namely the PLC or the PAC.

Read more...
From the editor's desk: Some random thoughts
Technews Publishing (SA Instrumentation & Control) News
In the afterglow of the Olympics, my most enduring memory is the men’s 100-metre finals where the top four were separated by three hundredths of a second; and Noah Lyles beat Kishane Thompson by four thousandths ...

Read more...
Small-scale custom development in the information age
H3iSquared PLCs, DCSs & Controllers
In the twenty-first century, the ability to put together custom electronic devices has become much more accessible to smaller companies, and even the private user. With the open nature of these platforms, potential developers can start learning systems easily, and do not need a massive capital output to do so.

Read more...