Join us September 22-23 for CamundaCon - a virtual conference dedicated to process automation

Icon Close REGISTER FOR FREE
Overview of our smart factory setup with components from Fischertechnik

Controlling Processes in a Smart Factory with the Camunda Platform

The Fourth Industrial Revolution is in full progress. An increasing number of manufacturing companies are using information technology to digitize their products and services by integrating production machines and production processes with enterprise information systems and digital processes. These interconnected smart machines, products, and processes build the Industrial Internet of Things (IIoT).

However, if we want to integrate the functionality and data provided by the production machines and resources with information systems such as Enterprise Resource Planning (ERP) systems and business process management systems (BPMS), several interoperability, abstraction, and interaction issues must be addressed: machines have different non-standardized programming interfaces; are programmed in low-level programming languages (e.g., G code); are very complex; and operate mostly in isolation. Nevertheless, this bi-directional integration of the IIoT devices with information systems shows a lot of potential and benefits for both areas. On the one hand, live status data about production machines and processes can be fed directly into the ERP systems, e.g., to optimize the production plans or adapt the production plans in case of machine failures or downtimes. On the other hand, the BPMS can monitor, analyze, and control production processes, e.g., to adapt or reconfigure the production processes in case of exceptions on the shop floor. Realizing these flexible and dynamic processes and production lines is among the main goals of Industry 4.0 developments.

In this blog post, we present a novel software stack to reduce the gap between the production shop floor and enterprise-level management systems. First, we discuss how to abstract and integrate production machines via web services that can be called from BPMS. Then, we showcase this software stack by using the Camunda Modeler and Camunda Platform to automate and execute exemplary production processes in our own smart factory. 

Part I: Software Abstraction Stack — From Production Machines to Web Services

The figure below shows the software abstraction stack. Going from bottom to top, we start with the actual hardware of a production machine, which can usually be accessed at a very fine grained low level of retrieving the status of single sensors (e.g., light barriers, switches) and activating individual actuators (e.g., motors, valves) via machine-specific, proprietary drivers that are used by embedded controllers (e.g., Programmable Logic Controllers-PLCs).

The PLCs offer interfaces to be called from external software applications (e.g., via network sockets), which is where our developments start. Accessing individual sensors and actuators in a very fine-grained manner from a business process is not feasible. Therefore, we decided to raise the level of abstraction of these components and aggregate them at the level of Production Machines that offer specific functionalities. These production machines are represented as domain classes in an object-oriented programming model, their functionalities and data are encapsulated as methods and attributes of these classes. We used Python to implement the corresponding object-oriented application for smart factories. The figure below shows an excerpt of the class model for our smart factory.

The active–actuation–methods of the production machines can only be called via a Transaction Manager, which ensures that concurrent and conflicting invocations of the smart factory’s resources are handled. Data from the production machines is streamed continuously in a publish-subscribe manner via Kafka and MQTT. Finally, the functionality of the production machines as defined in the domain classes is exposed 1-to-1 by a Web Service that we developed in Python using the Flask framework [1]. Now BPMS such as the Camunda Platform can be used to call the methods of the Web Service via BPMN 2.0 Service Tasks. These calls go to the Web Service and to the Transaction Manager via synchronous RPC, which then calls the methods of the domain objects. Additionally, we use the Siddhi Complex Event Processing (CEP) Platform for evaluating sensor data from multiple streaming sources and triggering higher level events in the business processes, e.g., for quality checks or detecting errors during the execution of a production step.  

Part II: Using Camunda to Model and Execute Processes in a Smart Factory

With having an implementation of the software stack including the Web Service to be called from Camunda ready, we can now start modeling and executing processes in our own smart factory. The following figure shows an overview of our smart factory setup with components from Fischertechnik [2].

By using BPMN 2.0 Service Tasks, we can model and execute production processes in our smart factory with the help of the Camunda Platform. The service tasks are configured to call methods of the Flask Web Service via HTTP Get to activate the specific functionality of the production machines. Depending on the selected method to call, parameters specifying the concrete machine, durations or product configurations are passed with the HTTP call. The Transaction Manager receives the call, invokes the specific method of the domain object, and responds back to the web service and then Camunda when the production activity is finished. The following figure shows a screenshot of the Camunda Modeler with a simple production process modeled in BPMN 2.0 and configured to be executed. The first service task is used to let Vacuum Gripper Robot 1 pick up a workpiece from the start and move it to Oven 1. The second (selected) service task instructs Oven 1 to burn the workpiece for a certain duration. The third service task invokes the Vacuum Gripper Robot 1 to pick up the workpiece from Oven 1 and move it to Milling Machine 1.

The figure below shows a more complex manufacturing process in BPMN 2.0 created using the Camunda Modeler. To support the user with modeling processes here, we provide Element Templates that can be used for creating the service tasks. For configuring the “Burn” task in this example, the user can choose from the template between Oven 1 or Oven 2 and specify what the output should be, e.g., a medium-sized thick workpiece. The process execution can be directly started in the Camunda Platform via the Modeler.

The presented software stack and with that the ability to use BPMS for modeling, automation, and mining of production processes, lays the foundation for our research on flexible and adaptive processes in the context of Industry 4.0 [2]. The following video shows one of our research prototypes [3]. Here we use the Camunda Platform to execute a production process in our smart factory based on the presented software stack. The currently executing process steps in the smart factory are highlighted in the BPMN 2.0 model shown at the bottom. During execution, we use computer vision and machine learning to detect the workpieces moving around in the production line. Our machine learning model is able to detect if workpieces are wrongly positioned or have fallen off the production line, which may then trigger an adaptation of the production process. 

Conclusion

On the journey towards “Automate Any Process, Anywhere”, we have shown how the Camunda Platform can be used to model and execute production processes in a smart factory. As Internet of Things devices are becoming increasingly sophisticated and open to be used in external software applications, it is relatively easy to wrap the devices’ functionalities and data in a Web Service to be called from a Business Process Management System. Our presented software abstraction stack discusses the software components necessary for achieving this business process-oriented control and automation for a smart factory. Of course, things in real world production environments are not so simple because requirements for safety and real-time behavior are much stricter than in our smart factory setup. However, with our blog post we wanted to show that it is actually worth to discuss and think about applying BPM technologies in the context of Industrial IoT. A bi-directional coupling of the shop floor with enterprise-level information systems for process modeling, automation, and mining makes sense at various points. For our own research, the software stack and with that the ability to completely control and monitor processes of a smart factory, not only is a pretty cool demo, but also lays the foundation for more advanced cutting edge research that contributes to the Fourth Industrial Revolution.

We encourage all interested readers to take a closer look at our scientific publications referenced below. Feel free to get in touch with us and to join the Camunda Forum. We are happy to discuss our approach, to show you parts of the software stack, and to arrange a small demo session where you will be able to model production processes with your own instance of the Camunda Modeler and execute them remotely in our smart factory. For more information visit: https://iot.uni-trier.de

About the Authors

Lukas Malburg is a PhD student at the Department of Artificial Intelligence and Intelligent Information Systems at the University of Trier and since May 2021 a member of the German Research Center for Artificial Intelligence (DFKI). In his research, he examines the use of Artificial Intelligence methods in Cyber-Physical Production Systems and the Internet of Things combined with Business Process Management techniques. 

Get in touch at: malburgl@uni-trier.de

Ronny Seiger is a post-doctoral researcher at the Chair for Software Systems Programming and Development at the University of St.Gallen in Switzerland. His research is focused on software engineering and business process technologies in the context of Internet of Things and Cyber-Physical Systems.

Get in touch at: ronny.seiger@unisg.ch 

References


[1] Malburg, L., Klein, P., Bergmann, R.: Semantic Web Services for AI-Research with Physical Factory Simulation Models in Industry 4.0. In: Panetto, H., Madani, K., Smirnov, A. (eds.) Proceedings of the International Conference on Innovative Intelligent Industrial Production and Logistics, pp. 32–43. SCITEPRESS – Science and Technology Publications (2020) https://doi.org/10.5220/0010135900320043

[2] Malburg, L., Seiger, R., Bergmann, R., Weber, B.: Using Physical Factory Simulation Models for Business Process Management Research. In: Del Río Ortega, A., Leopold, H., Santoro, F.M. (eds.) Business Process Management Workshops, 397, pp. 95–107. Springer (2020) https://link.springer.com/chapter/10.1007/978-3-030-66498-5_8

[3] Malburg, L., Rieder, M.-P., Seiger, R., Klein, P., Bergmann, R.: Object Detection for Smart Factory Processes by Machine Learning. Procedia Computer Science 184, 581–588 (2021) https://doi.org/10.1016/j.procs.2021.04.009