Select Page

We're building a machine – and integrating the IoT right into it!

Joking aside – how can IoT methods be used effectively in mechanical engineering?

Author: Robert Schachner, RST Industrie Automation GmbH or Embedded4You eV.

Contribution – Embedded Software Engineering Congress 2016

IoT – the „Internet of Things“ and „Industry 4.0“: These two buzzwords are currently haunting events and trade fairs everywhere. What's said often sounds promising; the ultimate goal, the great success, is announced. However, it usually remains just a collection of buzzwords whose deeper meaning remains elusive. This presentation clarifies what lies behind these concepts and uses a machine as an example to demonstrate how these technologies can be implemented effectively.

 Forms of communication

1. The process data model

The image (PDFThe diagram shows the communication model found in every PLC controller. A global memory – the process data model – serves as a storage location for all process parameters (process variables or flags). Electrical signals are cyclically input and output via various I/O functions.

A control program accesses these process variables, processes the data, and writes process variables back into the process data model.

Since this method overwrites the "old" value in each update phase, only the most up-to-date process variables are always available. Real-time control, as well as real-time regulation, can thus be implemented universally and easily. However, this simple and elegant approach becomes a disadvantage when multiple values or status messages (e.g., commands or error messages) are written to a process variable faster than they can be read from the remote system.

Important information is lost because it is overwritten too quickly. In such situations, the model fails.

2. Message-based communication

This type of communication is almost always behind the "IoT" discussion. At first glance, both communication methods sound very similar. However, upon closer examination, it becomes clear that the two methods differ fundamentally in their impact. In the message-based communication model, messages are serialized, and as in the example above (PDF) distributed to other clients via a central intermediary, the so-called broker. In contrast to the process data model, the focus here is on reliable delivery. all Information – overwriting values that have not yet been retrieved is no longer possible. The system offers advantages and disadvantages; for example, implementing controllers is extremely difficult.

Besides the usual addressing, where the sender specifies the recipient (request/response), there is the publish/subscribe mechanism, which is something entirely new in the embedded world. The sender (publisher) no longer addresses their message to a specific recipient, but simply makes it available under a unique topic. Any recipient (subscriber) can then subscribe to this topic as needed and will subsequently receive all relevant information from the broker until they unsubscribe. Thus, sender and recipient are no longer directly connected; this enables the distribution of information as needed.

To return to the IoT terminology, this has essentially created a "cloud"—a universal storage location for data that can be made available to any number of participants. Contrary to popular belief, this cloud doesn't have to be located on the internet; it can also function as a so-called "private cloud" within a machine control system. This ensures data security.

Application in machine control

With this knowledge, we now want to develop strategies for modern machine control. The reference architecture model RAMI4.0, proposed by the VDI and ZVEI, can also be considered in this context.

With the process data model already described, we again rely on the methodology currently used to implement control in almost every machine. Whether a high-level language, structured text, function block diagram, or a model-based approach is used as the programming method is independent of the communication model and depends primarily on the programmer's skills. When using PLC technology, the only requirement is that the hardware is integrated into an open operating system. With middleware platforms like Gamma V, the integrated process data model can be used with virtually any embedded hardware on a Linux or Windows operating system.

It is also advantageous to reuse existing I/O concepts. Up to this point, our considerations have remained within the standard environment. Now, we want to demonstrate how effectively and elegantly broker architectures can enhance traditional control systems. We will present two examples to illustrate this.

Example 1: Error Management

In traditional control systems, this issue is implemented very differently. Often, only process variables are used for temporarily storing error values. However, if two error messages are generated in quick succession, the older one can be overwritten if it is not read quickly enough; frequently, only the most recent error message reaches the application. As a workaround, flags can be created; however, in the worst case, this leads to hundreds of flags, each assigned an error number. Thus, one dilemma is avoided by creating another.

This can be solved much more elegantly using message-based communication methods.

The control systems (Control 1 – Control 3, PDFThese correspond to the previously described classic architecture, but each has been extended to include a messaging client. This client allows error messages to be sent via the Client RPC API. These messages can contain various details via properties, such as error number, error class, date and time, etc. Within the communication model, each controller now acts as a so-called publisher, making its error messages available via a topic (for example, "ERROR").

The broker can run either on a dedicated computer or – in a multi-broker concept – distributed as a separate instance on each participating computer. It then distributes the data received from publishers on the "ERROR" topic to the various subscribers.

This data is then received and processed by services registered as subscribers on the network. Thanks to the previously described separation between senders and receivers, any service can be connected to process the error data. These services communicate exclusively with the topic "ERROR," completely independent of the publishers and other subscribers. As illustrated, a wide variety of applications can be programmed to perform universal tasks such as archiving or, for example, to send emails or SMS messages to service technicians in case of an error. The architecture even allows for any number of error visualizations to run on the machine or on remote terminals, all of which can be operated independently.

This creates a cross-computer fault management system whose flexibility and simplicity are unmatched by any other technology. Entire machines with their dedicated controllers can now be networked without further configuration, and their services can be used centrally. Thus, in an entire machine hall, only a single central UMTS interface is needed to notify the service technician.

Example 2: Ad-hoc networking of machine parts

Machines are now mostly networked via fieldbuses. Depending on the number of connections, networking can involve considerable configuration effort and a corresponding potential for errors.

The publish/subscribe mechanism also offers a highly elegant alternative here. As shown in Figure 4 (PDFAs shown in the diagram, application A, for example, generates a part number and the corresponding status signal "PartReady" via the docked RFID reader. As a publisher, this information is made available on the network. Other machine parts connected to the network can then subscribe to this and any other information as subscribers. In this example, system 2, as a subscriber, receives the information about which part (PartNumber) is ready for pickup and when (PartReady).

This creates a private cloud through which individual machine components exchange information. Machine components can now automatically assemble themselves into a networked machine – solely via the relevant topics. Since a complex overall system may require managing a large number of topics, it is important to structure the topic names uniformly within a topology or even an ontology.

Message-based communication offers many more possibilities for making control systems more effective. Therefore, in addition to the points briefly summarized here, the presentation will also highlight strategies for networking with production networks and, as a practical example, discuss a successfully implemented machine control system in detail.

Download the article as a PDF


IoT / Industry 4.0 – our training courses & coaching

Do you want to bring yourself up to date with the latest technology?

Then find out more here MircoConsult offers training courses/seminars/workshops and individual coaching on the topics of IoT/Industry 4.0/system and hardware development.

Training & coaching on the other topics in our portfolio can be found here. here.


IoT / Industry 4.0 – Expertise

Valuable expertise in IoT/Industry 4.0/system and hardware development is available. here Available for you to download free of charge.

To the specialist information

You can find expertise on other topics in our portfolio here. here.

MicroConsult Newsletter

With the MicroConsult newsletter, you'll stay on the pulse of the embedded world. Look forward to proven practical knowledge, real professional tips, and current events – directly from our experts for your project success.

Subscribe now!

Published by

weissblau media

weissblau media