The smart factory as an architecture

A smart factory continuously collects data from machines, processes and quality checks and makes it available to the systems and people who decide on maintenance, scheduling and improvement. Production line digitalization is not achieved by buying a single software product; it is a set of layers that have to be designed together.

A good industrial IoT architecture has three properties: each layer has a clear responsibility, the interfaces between layers are standardized, and adding a new machine or application does not require redesigning the whole system. The sections below walk through the layers, the role of the main protocols, brownfield integration, security and the data model.

The architecture layers

Field layer: sensors, actuators and PLCs

At the bottom are sensors (temperature, pressure, vibration, current, counters) and actuators, usually controlled by PLCs. The PLC is responsible for deterministic, safe process control and should not carry analytical data processing. A key principle: reading data from a PLC must not interfere with its control logic. Read-only access, rate limits and coordination with the automation team are essential.

Edge layer: gateways and local processing

Edge gateways collect data from PLCs, meters and sensors, translate protocols, filter and aggregate values, and buffer data when the uplink is interrupted. Processing that needs fast response, such as threshold detection or pre-processing of high-frequency vibration data, belongs here. The edge is also the natural boundary between the production network and everything above it.

Connectivity and protocol layer

Three protocols appear in most projects:

  • Modbus (RTU/TCP): old, simple and still very common in meters, drives and legacy equipment. It has no data model, so the meaning of each register must be documented.
  • OPC UA: a vendor-independent standard with a rich information model, built-in security and support in many current PLCs. Well suited for structured access to machine data.
  • MQTT: a lightweight publish/subscribe protocol for moving data from the edge to the platform and distributing it to multiple consumers.

Platform layer

The IIoT platform, for example ThingsBoard, manages devices, stores time-series data, executes alarm rules and provides dashboards. Whether it runs on-premise or in the cloud depends on security requirements, internet connectivity and company policy. Many manufacturers prefer on-premise or hybrid setups for production data.

Application layer: MES, ERP and maintenance

At the top are the systems that consume data: MES for orders, production steps and traceability; ERP for resource planning, purchasing and accounting; and a maintenance system (CMMS) for work orders. Real value appears when, for example, a vibration alarm on a motor automatically creates a maintenance work order, or when actual machine counts flow back into order progress.

Protocol comparison

AspectModbusOPC UAMQTT
Typical positionField and legacy devicesMachine and controllerEdge to platform
Communication modelRequest/responseClient/server and pub/subPub/sub via broker
Data modelNone (registers only)Rich, modelableFree; payload format must be defined
SecurityNone in the base protocolBuilt-in (certificates, encryption)Via TLS and authentication
Best forReading meters and drivesStructured PLC accessDistributing data to many consumers

Brownfield integration and retrofit

Most factories are not greenfield sites. Machines from several generations run side by side, and some have no data interface at all. Common approaches to legacy equipment retrofit:

  • Reading the existing PLC via native protocols or OPC UA, where access and permission exist.
  • Add-on sensors such as current clamps, vibration or temperature sensors, installed without touching machine control.
  • Protocol-converting gateways that translate Modbus or proprietary protocols into MQTT or OPC UA.
  • Reading legacy displays and meters with a camera and image recognition when no digital output exists.

The choice between retrofit and replacement depends on remaining service life, spare parts availability and the value of the data needed. Retrofit often provides visibility quickly and helps build the business case for later investment decisions.

IT/OT segmentation and security

Connecting the production network to the office network and the internet increases the attack surface. Basic principles:

  • Divide the network into zones with controlled conduits between them, following the concepts of the IEC 62443 series.
  • Place an industrial DMZ between OT and IT; there should be no direct connection from the office network to a PLC.
  • Let the edge initiate outbound connections instead of opening inbound ports into the production network.
  • Use encryption (TLS), device authentication and proper certificate management.
  • Maintain an up-to-date asset and configuration inventory; automating network configuration reduces manual errors.

Data model and roadmap

Without a shared data model, every machine becomes an island. Consistent asset naming (site, hall, line, machine), defined units, reliable timestamps and a clear definition of machine states (running, planned stop, breakdown) are prerequisites for any trustworthy dashboard or analysis. Standards such as ISA-95 provide a useful hierarchical structure for this.

Common pitfalls

  • Collecting everything: recording every available tag at maximum rate fills storage without answering a question. Start from the decisions the data should support.
  • Dashboards without owners: a dashboard nobody is responsible for reviewing quickly becomes decoration. Define who reacts to which alarm.
  • Point-to-point integrations: connecting each machine directly to each application creates a fragile web. A central broker or platform with a defined data model keeps interfaces manageable.
  • Ignoring time synchronization: without consistent clocks across PLCs, gateways and servers, correlating events between machines becomes unreliable.

A practical sequence for introducing this architecture:

  1. Assess: list machines, interfaces, networks and the main production problems.
  2. Prioritize: pick one line or one concrete problem, such as unrecorded stoppages or energy consumption.
  3. Design the target architecture: layers, protocols, network segmentation and data model.
  4. Pilot: connect the selected line and build dashboards for real users.
  5. Integrate: link to maintenance, MES or ERP.
  6. Scale: add further lines on the same architecture.

Conclusion

A smart factory is the result of a coherent layered architecture, not a collection of disconnected tools. Brownfield integration, security from the start and a shared data model decide whether the system can grow. The approach is described on the pages for smart factory, industrial IoT (IIoT) consulting and legacy equipment retrofit. To discuss your plant, use the contact page.

Frequently asked questions

Do I need new machines to build a smart factory?

Usually not. Many existing machines can be connected with add-on sensors, by reading data from the PLC or through protocol-converting gateways. Replacement makes sense only when equipment has reached the end of its technical or economic life.

OPC UA or MQTT?

They serve different roles. OPC UA suits structured access to controller and machine data; MQTT suits lightweight transport from the edge to a platform and many consumers. Many factories use both.

What is the role of MES next to an IIoT platform?

The IIoT platform collects and monitors technical data. MES manages orders, production steps, quality and traceability. They complement each other and should be linked through a shared data model.

Ali Porkareh

IT and network infrastructure professional with a focus on industrial IoT, smart mining and smart solutions.