MES

Manufacturing Execution System · Industry and Manufacturing

Role

MES (Manufacturing Execution System) is positioned between ERP and the underlying PLC/devices. It is responsible for breaking down production plans into work orders, tracking work-in-progress, collecting equipment and quality data, and enabling batch traceability. With the widespread adoption of connected devices, machine tools, robots, and inspection instruments write their status to the MES via industrial Ethernet or cellular gateways, supporting OEE analysis and lean improvements.

Using communication modules

When legacy equipment lacks Ethernet, an external 4G gateway can bridge serial/fieldbus data to MES middleware. It is necessary to unify clock, data model, and offline caching strategies to avoid losing counts during production line fluctuations. In terms of division of work with SCADA, SCADA is focused on real-time control, while MES is focused on production management and traceability.

Key points for implementation

Standardized interfaces (such as OPC UA) can reduce the access cost of heterogeneous devices; barcode/RFID interaction with MES enables full-process traceability. Launching needs to coordinate planning with existing APS and WMS systems.

Production modeling and data governance

The core of MES lies in work orders, process routes, equipment status, and WIP tracking. The data dictionary should be consistent with ERP material and process codes. Real-time collection and station scanning must prevent missed scans, duplicate scans, and skipped stations; exceptions must be closed-loop back to quality and processes. When uploading through a cellular gateway, timestamps and production line numbers should be included to facilitate cross-factory comparisons. Reports and dashboard metrics (OEE, first-pass yield) should be documented in writing to avoid inconsistent definitions across departments.

Collaboration with edge computing and the cloud

High-frequency vibration and visual data are suitable for edge preprocessing, with only feature values and alarms uploaded; MES-side records and traceability chains can be uploaded to the blockchain or stored in an audit database. In case of network disconnection, edges need to cache work order progress and quality inspection results; after recovery, conflict merging must follow rules. When interacting with WMS, issuing complete sets of materials and deducing inventory at line-side warehouses must be atomic to prevent discrepancies between books and actual stock.

Engineering Practice Supplement

Regarding the implementation of "MES" in IoT and cellular module projects, it is recommended to write network constraints (target market frequency bands and withdrawal plans, APN and private network strategies, roaming and fees, PSM/eDRX and other power-saving modes) and terminal constraints (antenna and RF layout, power ripple and surge, thermal design and derating, EMC/safety compliance) into verifiable acceptance items at the project initiation stage. During R&D, boundary faults should be reproduced using weak network simulations, high/low temperature, and voltage deviation, retaining logs and waveforms. In mass production, batches and calibration traceability should be established, and component substitutions should go through change reviews. After launch, connection success rate, reconnection count, latency, and power consumption should be included in the operations dashboard, with exceptions traceable to versions and batches.

The work-order state machine and station-pass events

A manufacturing execution system splits an order from the planning layer into work orders that can be executed, then binds each work order to an operation, a machine, and the work in process. A station pass is not a log line. It is one legal transition on a state machine. An operation may start only when the previous operation is complete, the material kit is complete, and the machine is in a state that allows production. On completion it records quantity, operator, and time. Quality judgment, rework, and scrap are side states. Skipping the main chain makes the work-in-process count disagree with the parts on the floor. A communication module or gateway delivers machine state and barcode events to that state machine. It does not decide whether an operation may be skipped.

The connection is worth making only when operation codes, machine IDs, and material codes already match the planning layer, the scan points cover the stations that change state, and clock error is small enough that a later operation is not timestamped before an earlier one. Older machines that have only a serial port can be converted by a gateway, but a replay after loss must carry the original timestamp and an event sequence number. Collecting data only to fill a large screen, with no state-machine constraint, degenerates into a pile that cannot be traced.

A replay that scrambles operation order

While cellular is down, the gateway caches station passes locally. After the link returns it pours them in arrival order. If the platform does not reorder by event sequence number, a later operation closes before an earlier one. Scanning the same barcode twice with no idempotency adds the output twice. A skipped station that is silently allowed makes a rework part look finished. Machine state reported as free text instead of an agreed enumeration cannot be rolled up into downtime reasons. The edge makes one pass-fail judgment, the server judges again against the raw threshold, and two conclusions exist together. At a shift change the operator ID is not switched, and the whole shift’s trace points at the previous person.

Conflict handling should say that a newer sequence number overwrites an older state, but a replay must not turn work in process that has already been scrapped back into work in process. Warehouse deduction should be considered in the same business transaction as the station pass. Location rules are covered in WMS. When vibration and images are reduced to features on site before upload, keep an index of the original file rather than a second definition. The boundary of work done at the edge is covered in edge computing.

A station-pass event carries a sequence number and the original time. After a replay arrives, reorder by sequence number. Do not close an operation in the order the events entered the server. Count one barcode only once if it is scanned again. Skipped stations and scrap use explicit states. Do not turn a rework part into a pass by adding a completion record. Report machine state with an agreed enumeration. The edge judgment and the server judgment share one set of thresholds, so there are not two conclusions. Switch the operator identity at a shift change. If progress cached on the gateway during an outage conflicts with scrap the server has already confirmed, the confirmed scrap stands.

Work orders, operations, and machine IDs use the same codes as the planning layer. A missed scan and a repeated scan should be visible at the station, not discovered at month end when output does not add up. When a cached replay conflicts with a record that is already scrap, keep the scrap. Maintain one copy of the quality thresholds, and have both the edge and the server refer to it.

Related Terms

Return communication modules terminology