January 1, 2021

#99 - Writing a Sequential Function Chart in Ladder Logic and introducing the PackML standard

 There are several languages available to write a PLC program, such as Ladder Logic, Function Block Diagrams, Structured Text, and Sequential Function Charts.

They all have its pros and cons, but sometimes the programmer may be forced to choose one of these languages for different reasons. One of the reasons could be the requirement from the client that is receiving the system, another is the easiness to read, troubleshoot and maintain, or even limitations in the programming software that depending on the licenses may not have all of these languages available.

The goal of this post is to write a simple Sequential Function Chart (SFC) program, also known as GRAFCET in some countries, in Ladder Logic. Ladder Logic is probably the most common PLC programming language used in the industry and it has become popular for its simplicity. 

This is the basic principle of a SFC: There are Steps with specific Actions and the system moves from one Step to another when the transitions are met. For example in the system below, the System that is currently at Step-010 will move to Step-020 if the condition of the transition is True. The transitions are typically states from the system, such as the value from a digital input, a specific state from the robot, a timer, counter value, etc.  



There are different ways to model the example above in ladder logic. One way is by using the instructions EQU-MOV and another example is using only boolean functions such as XIC, XIO, OTL, OTU. The first can be seen in the previous post and the latter is shown in the example below.


Over the past decades, several companies and institutions such as the Organization for Machine Automation and Control (OMAC) and the International Society of Automation (ISA) joined forces to create a common standard for packaging applications, called ISA-TR88.00.02 and also known as PackML (Packaging Machine Language). It worth reading the documentation provided on the links below to get a deeper understanding of this interesting standard. 

Some of the highlights of this standard are:

  • Standardization of machine states and tags.
  • Clear and well defined sequential flow. 
  • Functional programming of the control system.
  • Modularity that makes it easier to operate, troubleshoot and maintain.
  • Easier to integrate the automated system not depending on specific vendor and OEMs.
  • Horizontal integration with other systems in the production line
  • Vertical integration of the PackML systems with higher level industrial applications such as SCADA, MES and OEE. 
In conclusion, the first part of this post presented a way to program a Sequential Function Chart using Ladder logic. The second part of this post is a brief introduction to the PackML standard. Although this standard has been created for the packaging industry, the framework is really well designed and its standardization in terms of machine state and sequential flow could be successfully integrated in other industrial applications as well, such as robotics. 

Links of references and further readings:

No comments:

Post a Comment