Open Source meets PLC The MatPLC Project

This material is the complete text of ''Open Source meets PLC: The MatPLC Project'', found in the July 2002 Control Engineering cover article, ''Embedded Control: Heart of the System.''Click here to read the complete cover article.


This material is the complete text of ''Open Source meets PLC: The MatPLC Project'', found in the July 2002 Control Engineering cover article, ''Embedded Control: Heart of the System.'' Click here to read the complete cover article.

MatPLC is an open source solution to the closed, proprietary world of PC-based controls. It is released under the GNU General Public License (GPL), which means that it is freely available to the public. It is our intention that this be a publicly owned project, and that the public is free to use, modify, extend, and do whatever it is that they want with the system. Anyone who feels able to contribute to the project is more than welcome to join in. There are no contracts, secret agree-ments, licensing, or other constraints found in most of the competing systems. The problem with existing packages is that they tie you to a single vendor, force upgrades to keep tech support, and are, with a few exceptions, strictly Microsoft Windows-based.

One advantage of Linux is that it can be custom-tooled by removing components that are not necessary for performing the task at hand. It is possible to get a Linux system trimmed down to fit onto a floppy disk. This customizability means that you can get excellent hardware performance by eliminating anything that is not needed to perform your control task. If this is not sufficient, the MatPLC is designed to be POSIX compliant, so it will be portable to other Unix variations, including ones that support hard real time such as QNX, RTLinux, etc.

By releasing the MatPLC under the same GNU General Public License (GPL) that Linux is released under, we can guarantee that integrators and users will be able to apply , update, and support their system in perpetuity, if they desire. Unlike current solutions, that stop providing support for their system once a new version is released, the GPL ensures that nobody will be forced to make drastic changes to their system just to continue to be allowed to use it. Anyone who has gone through the process of migrating a HMI or PC control system from Microsoft Win-dows 95 to Windows NT, or even from one version of the HMI [human-machine interface] to the next, knows the problems involved. But the only compelling reason to do this in the first place is because the vendor no longer supports the original system. This is what we are trying to correct with the MatPLC. By using the GPL, anyone can continue to use whatever version they like.

One of the design decisions that was made early in the project's life was to keep the entire system as modular as possible. In this way, a project will consist of only those modules required to perform the desired operation.

The PLC core includes a shared memory manager that controls access to the common data ta-ble. I/O modules, analog signals, integer and floating point variables, etc., are all accessed through this memory manager. By controlling when each module synchronizes its data to the central table, we can ensure that each process is working from a consistent data-set, and updates are precisely predictable.

Synchronization is also maintained through the PLC core. Modules can be configured to sim-ply run one after the other in lock-stepped scan fashion, or complex relationships can be config-ured with modules running independent of each other, using a modified petri-net control design.

Today, the MatPLC is approaching Beta-testing stages. We have some I/O modules, most re-cently a Modbus master. We also have support for Hilscher cards (, which in-clude DeviceNet, AS-i, Profibus support, and many other industrial networks. We have the sys-tem core, including the shared memory manager. A system configurator is in development, and we also have an operational instruction list logic engine, and an HMI that is well underway. We are in the process of absorbing a ladder-logic editor/solver into the project, and merging with a sister project. This is one of the most powerful aspects of open source development. There are other projects worked on by other people. When we can get together with them, the ability to tie both of our projects together into one makes for a very powerful development method. Rather than hiding from others, and trying to keep what we are doing a secret, we can pool our resources, and everyone wins.

Because of the design of the PC, the I/O control is best done using a fieldbus network. One of our biggest challenges has been to convince the parties that control the fieldbus standards that they should allow us to support their protocols. Many of them simply do not wish to allow their networks to be used in an open-system environment, but want to keep them locked away from broad support. We have gotten around this problem somewhat by using hardware that implements the protocols in firmware, which lets us use the license from the hardware vendor to make our use legal, but it would be far better for the end-user if we could implement these protocols natively.

Our hope is that once we release a truly open system using Modbus, and I/O modules from other vendors that have helped us, some of the remaining networks will come on board with us. We are also working with a supplier of a rack-based PC system that lives in a PLC-style chassis. This is a system on the market today, and we are trying to get Linux to operate on that platform. That would open up a wide array of I/O options, plus give us a semi-standard hardware platform to back it up.

available on micro PLCs today. SixNet has promised us a library that will allow us to communicate to its I/O devices. The library will be GPL-compliant. This is no small step for a system vendor. We hope that others will see the positive results of this move, and come on board as well.

Joe Jansen Anderson, S.C.
Contributing Programmer and Tester to the MatPLC Project

For more information, see the descriptive slides at*checkout*/mat/doc/talks/rtl-2001/rtl-2001.htm

No comments
The Engineers' Choice Awards highlight some of the best new control, instrumentation and automation products as chosen by...
The System Integrator Giants program lists the top 100 system integrators among companies listed in CFE Media's Global System Integrator Database.
The Engineering Leaders Under 40 program identifies and gives recognition to young engineers who...
This eGuide illustrates solutions, applications and benefits of machine vision systems.
Learn how to increase device reliability in harsh environments and decrease unplanned system downtime.
This eGuide contains a series of articles and videos that considers theoretical and practical; immediate needs and a look into the future.
Motor specification guidelines; Understanding multivariable control; Improving a safety instrumented system; 2017 Engineers' Choice Award Winners
Selecting the best controller from several viewpoints; System integrator advice for the IIoT; TSN and real-time Ethernet; Questions to ask when selecting a VFD; Action items for an aging PLC/DCS
Robot advances in connectivity, collaboration, and programming; Advanced process control; Industrial wireless developments; Multiplatform system integration
Motion control advances and solutions can help with machine control, automated control on assembly lines, integration of robotics and automation, and machine safety.
This article collection contains several articles on the Industrial Internet of Things (IIoT) and how it is transforming manufacturing.

Find and connect with the most suitable service provider for your unique application. Start searching the Global System Integrator Database Now!

Future of oil and gas projects; Reservoir models; The importance of SCADA to oil and gas
Big Data and bigger solutions; Tablet technologies; SCADA developments
SCADA at the junction, Managing risk through maintenance, Moving at the speed of data
Automation Engineer; Wood Group
System Integrator; Cross Integrated Systems Group
Jose S. Vasquez, Jr.
Fire & Life Safety Engineer; Technip USA Inc.
click me