Siemens S7 in the Unified Namespace (UNS): Interface Overview

Content

Siemens S7, also known as SIMATIC S7, is one of the most widely used control platforms in industrial automation. Whether compact PLCs for simple machines or powerful controllers for complex production systems – the S7 family can be found in almost every production hall. However, anyone who wants to integrate a Siemens S7 in the Unified Namespace (UNS) is faced with the question: Which interfaces and protocols are suitable for bidirectional connection? The following article provides an overview of the most important options with their respective advantages and disadvantages.

 

S7 Controllers – Overview

The Siemens S7 is a modular control platform that is used worldwide. It forms the backbone of numerous machines and systems – from simple handling systems to highly complex production lines. The control system is characterized by reliability, flexibility and a high level of functionality. It is precisely these advantages that make the controller a popular choice for the control and automation of manufacturing processes. The controllers are usually programmed using special software, such as STEP 7 (Siemens Totally Integrated Automation Portal). Other reasons for the popularity of the PLC are:

  1. Variety of control systems: Siemens S7 offers a wide range of control systems, from small and compact PLCs (programmable logic controllers) to powerful industrial controllers. These are designed to handle various tasks in automation technology.
  2. Flexibility: The control platform is extremely flexible and can be adapted to the requirements of different industries and applications. This also includes the ability to add extension modules to provide additional functionality.
  3. Reliability and robustness: Siemens S7 controllers are designed for use in industrial environments and are characterized by their high reliability and robustness. They are designed to work continuously even under demanding conditions.
  4. Highly complex tasks: S7 controllers are capable of handling highly complex tasks. This includes the control of machines, processes and production facilities.

 

Siemens S7 in the Unified Namespace (UNS)

The integration of a Siemens S7 into a Unified Namespace (UNS) is a central step on the way to an end-to-end networked production architecture. The aim of the UNS is to bring together all relevant data sources – from the control level to the cloud – in a common, structured data space. This data space is usually based on MQTT (further information can be found here). In order for the S7 to act as part of this digital ecosystem, it must be connected bidirectionally to the UNS via suitable interfaces.

Siemens S7 in the Unified Namespace (UNS)

As the communication capability varies greatly depending on the S7 model, the choice of the right interface depends on the specific application. Factors such as real-time requirements, data volume, security requirements and system compatibility are decisive. The following section presents the most important integration options and compares their respective strengths and weaknesses.

 

Integration Options and Interface Comparison

Depending on the model and implementation, Siemens S7 controllers offer various integration options for bidirectional connection to the Unified Namespace (UNS). The choice of the optimum S7 interface depends mainly on the capability of the control system. The specific use case requirements are also relevant, such as the degree of data granularity, the security requirements and the existing system architecture. The availability of S7 programmers also plays a role in the selection process.

 

1st Option: MQTT via LMQTT library

MQTT can be integrated directly into Siemens S7 controllers using the LMQTT library. This library makes it possible to implement MQTT communication completely within the PLC, without external gateways. Communication takes place via standard communication blocks such as TCON, TSEND_C and TRCV_C, while the MQTT-specific logic (e.g. connection establishment, topic management, QoS control) is mapped via blocks in the library. This allows process data from the controller to be published directly to an MQTT broker or subscribed to from there – a direct path to the Unified Namespace (UNS).

Pros:

    1. Direct UNS integration: The PLC can participate directly in an MQTT-based unified namespace without any intermediate systems.
    2. Control on the controller side: MQTT messages and topics can be controlled specifically from the PLC logic, which allows maximum flexibility in data provision.
    3. Event-based communication: The library supports publish/subscribe according to the MQTT standard and is therefore suitable for efficient, state-oriented data transmission.

Cons:

  1. Resource requirements on the controller: Processing MQTT messages requires memory and computing time on the controller.
  2. Increased engineering effort: The correct configuration of connections, topics, QoS levels and error handling must be implemented in the PLC program.
  3. No native MQTT support: The library is a user-defined solution. Maintenance, updates and compatibility must be checked on a project-specific basis.

 

2nd Option: OPC UA (Unified Architecture)

OPC UA is a vendor-neutral communication protocol for secure, model-based data exchange in industrial automation. In contrast to low-level protocols such as TCP, OPC UA offers semantic data models, integrated security mechanisms and a service-oriented architecture. These features make it ideal for direct integration in a Unified Namespace (UNS). Siemens S7 controllers support OPC UA either natively (e.g. with newer S7-1500 CPUs with corresponding firmware) or via additional communication processors or software components.

Pros:

    1. Browsable namespace: The entire address space can be explored at runtime via OPC UA clients, including data blocks, variables, type definitions and structures. This facilitates the integration of relevant data in the UNS.
    2. Model-based access: OPC UA supports structured, object-oriented data models with unique semantics, ideal for integration into modeled data spaces in the UNS.
    3. Integrated security functions: Native support for encryption, authentication and access control ensures secure communication.

Cons:

  1. Configuration effort: Implementing an OPC UA server on the controller usually requires additional engineering work, especially for older S7 models without native support.
  2. Additional components: In many cases, a communication processor or a runtime license is required, which can lead to additional procurement and integration costs.

 

3rd Option: TCP (Transmission Control Protocol)

TCP is a proven protocol for connection-oriented communication between controllers and network components. In the Siemens S7 world, TCP can be used directly via communication blocks such as TCON, TSEND_C and TRCV_C to implement user-defined communication protocols between controllers and the Unified Namespace (UNS). It is usually used when no standardized protocols such as OPC UA or RFC 1006 are available, or when maximum efficiency and control over the data format and the transmission process is required.

Pros:

    1. Direct access at transport level: Enables high-performance, low-latency communication with low overhead, as no additional protocol layer is used.
    2. High flexibility: User-defined protocols and data structures can be implemented individually, which is particularly advantageous for specialized applications.
    3. Maximum control: The entire communication flow, including connection management, error handling and data processing, is completely in the hands of the developer.

Cons:

  1. High implementation effort: Functions such as connection handling, repetition mechanisms, data modeling or status management must be developed manually on the control side and the opposite side.
  2. No semantic abstraction: TCP offers no support for structured or typed data. Modeling in the sense of a unified namespace is only possible with additional logic, e.g. in the i-flow Edge.
  3. Lack of security mechanisms: TCP itself has no integrated encryption or authentication.

 

4th Option: RFC 1006 (Remote Function Call over TCP)

RFC 1006 is a Siemens-specific communication standard that is based on the TCP protocol and was developed for accessing S7 controllers. It is an implementation of the ISO-on-TCP stack (ISO 8073) and forms the basis for S7 communication services such as PG/OP access or HMI connections. In the context of integration into a Unified Namespace (UNS), RFC 1006 is often used to read or write control data directly via standardized drivers.

Pros:

    1. Native support in Siemens S7: RFC 1006 is deeply integrated into the Siemens communication architecture and usually requires no additional libraries or adaptations on the controller.
    2. Direct access to process data: Read and write access to data blocks, flags, inputs and outputs is possible – frequently used for SCADA, HMI or UNS integrations.

Cons:

  1. Implementation effort: S7 programmers must manually create relevant data in dedicated (DBs) and assign fixed address ranges.
  2. No semantic data structure: Access is purely address-based without data modeling – context information or logical assignments must be maintained externally.
  3. No integrated security: Unlike OPC UA, RFC 1006 has no native encryption, authentication or access control mechanisms

 

Integrate Siemens S7 in the Unified Namespace (UNS) with i-flow Edge

With i-flow Edge, Siemens S7 controllers can be flexibly and efficiently connected to the Unified Namespace (UNS) – regardless of whether communication takes place via MQTT, OPC UA, RFC 1006 or TCP. i-flow not only handles the connection to the controllers, but also the conversion and standardization of the data into an UNS-compatible format. Detailed information on mapping Siemens S7 address spaces to MQTT-based UNS address spaces can be found here.

About i-flow: i-flow is an industrial software company based in southern Germany. We offer manufacturers the world’s most intuitive software to connect factories at scale. Over 400 million data operations daily in production-critical environments not only demonstrate the scalability of the software, but also the deep trust our customers place in i-flow. Our success is based on close collaboration with customers and partners worldwide, including renowned Fortune 500 companies and industry leaders like Bosch.

Try it out now - free trial version

Experience the unlimited possibilities that i-flow offers by taking a test for yourself. Test now for 30 days free of charge on your systems.

Your question has not been answered? Contact us.

Your Contact:

Marieke Severiens (i-flow GmbH)
content@i-flow.io