Software, IT, OT & cybersecurity
Machine learning seamlessly integrated into control systems

Running a new product on a production line currently requires parameters to be adjusted. During the first run, some further fine-tuning will be needed to achieve a perfect result. Machine learning is essential if such product changeovers are to be fully automated. Beckhoff demonstrated at Hannover Messe how it can be seamlessly integrated into a TwinCAT 3 environment in real time. This gives machine manufacturers an optimal basis for improving machine performance.
The basic idea behind machine learning is that solutions are no longer developed through conventional engineering, but using algorithms. Algorithms can be trained on process example data to build efficient models and create better-performing solutions. This opens up new possibilities and optimisation potential for automation technology in areas such as predictive maintenance and process control, anomaly detection, cobots, automated quality inspection and machine optimisation. Patrick Gielis, general manager of Beckhoff Automation Belgium, believes machine learning could well be the future of automation. “That is precisely because it offers an answer to the challenges machine builders face today. We have already taught machines to see, listen and talk. Teaching them to think and make decisions autonomously is the next step. Machine learning can create considerable added value for end users, making it a unique selling point for machine builders who have embarked on this path.”

With TwinCAT 3, the new possibilities offered by machine learning and deep learning are available to automation engineers in the familiar environment they already use.
Everything in one environment
At Hannover Messe, Beckhoff Automation demonstrated that it had done its homework on machine learning, even though the technology is still in its infancy. Machine learning models can be trained using standard frameworks such as MatLAB or TensorFlow. They can then be integrated directly into the TwinCAT Runtime using ONNX (Open Neural Network Exchange), a standardised exchange format for describing trained models. “The main advantage is that everything is in the PLC. As a programmer, you don’t need another device: it can all be done in one environment, making the process more efficient. In addition, TwinCAT’s multicore support makes it possible to run different tasks synchronously and in real time. This will be necessary, because machines have to make the right adjustments in a fraction of a second. Our demo showed how a machine can become more energy efficient by limiting acceleration and deceleration as much as possible, based on what it has learned from practical experience. But the same approach can also improve quality, increase productivity …”

No threat to people
Two new functions have been integrated into TwinCAT Runtime to enable machine learning. TwinCAT 3 Machine Learning Inference Engine handles conventional machine learning algorithms. TwinCAT 3 Neural Network Inference Engine is responsible for deep learning and neural networks. The TwinCAT 3 Inference Engine can be accessed from different task contexts without them interfering with one another. Full access to all fieldbus interfaces and data in TwinCAT is also maintained. This means that the ML solution can use a huge amount of data, while real-time interfaces with actuators are also available. “People need not feel threatened by these developments at all. What we are really introducing now are methods that allow the machine to learn for itself. It is not yet thinking entirely independently. But the fact that artificial intelligence was such a major topic at Hannover Messe proves that it will soon be here.” Beckhoff has a fully integrated approach ready.
Question about this story? Ask your question
Keep following this
Get an email when a new story is published. No account needed.
- ThemeSmarter measurement and inspection
- SubjectSoftware, IT, OT & cybersecurity



















