Your PLC knows what a valve is doing this millisecond. Your ERP knows what the company sold last quarter. Between them is a canyon โ and the bridge is the MES: the system that turns "make 500 donuts" into dispatched work, live OEE, and a birth certificate for every unit. This is the speed-run from "what's an MES?" to running a shift and reading its scorecard.
Industry stacks a factory into levels (the ISA-95 / Purdue model). The bottom reacts in milliseconds; the top plans in months. MES is Level 3 โ the translator that takes a business order from above and turns it into executed, measured production below. Tap a level to see who lives there and what it cares about.
๐ณ๏ธ The gap is real. ERP says "production order #4471, due Friday." The PLC says "output Q2.3 is TRUE." Neither knows the other's language. MES is the only layer that speaks both orders and I/O.
๐ Without MES that translation happens on a clipboard, a whiteboard, and a spreadsheet someone updates at 5pm. MES makes it live, accurate, and automatic.
Here's the acronym that trips up everyone who just learned "MES". MOM โ Manufacturing Operations Management โ is the proper name for the whole of Level 3, not a rival to MES. ISA-95 Part 3 defines it as the activities that coordinate personnel, equipment and material in manufacturing, and splits it into four domains. MES is the production one. That's the entire relationship: MOM is the scope; MES is the room you already toured.
โ the same eight activities โ re-read in production language
๐ช The trick worth keeping: all four rooms have identical furniture. Define โ resource โ schedule โ dispatch โ execute โ collect โ track โ analyse. Learn that loop once and you can read a maintenance system, a lab system or a warehouse system on sight โ it's the production loop wearing different nouns. That symmetry is deliberate, and it's the most useful thing in the whole standard.
โ ๏ธ Now the genuinely nasty part โ "MOM" means two different things, and nobody warns you:
Which one is meant? Look at what's next to it. Beside ERP and MES โ the house. Beside production, quality and inventory โ the maintenance room. To avoid the whole mess, many people write the four domains as POM ยท QOM ยท MOM ยท IOM and keep "MOM" for the house only.
And the question everyone actually asks โ so is MES just MOM with a new sticker? Three honest answers, all in circulation:
๐ค "Same thing"
In everyday shop-floor talk they're used interchangeably, and you will rarely be corrected. Fine in a corridor conversation โ not fine in a specification.
๐ "MOM is wider" โ the standard's view
MOM is the architectural scope of Level 3; MES is the production-execution slice of it. This is the reading ISA-95 and MESA back, and the one to use in writing.
๐ท๏ธ "It's a rebrand"
Partly true! What the market called "MES" kept growing into quality, maintenance and warehouse work, so suites were renamed MOM to match what they'd already become.
So much for the shape of it. What does a MOM platform actually do all day? Four capabilities โ and note how each one is only possible because the four domains share one data model instead of sitting in separate silos:
๐๏ธ Real-time visibility
Machine health, material supply and workforce productivity โ live, via IoT sensors and digital twins. Not "the 5pm spreadsheet": the floor as it is this minute.
๐ Process standardisation
Digital workflows and e-signatures replace paper batch records โ the operator physically cannot skip a step. Compliance stops depending on somebody remembering.
๐ง Advanced analytics
AI over the pooled history: predictive maintenance (fix the bearing before it fails), dynamic scheduling, cost optimisation. Needs maintenance + production data together โ hence one platform.
๐ช Vertical integration
Physical resources wired straight to business applications โ an unbroken path from sensor to boardroom. This is the digital thread, and MOM is the layer that makes it continuous.
๐ The thread running through all four: killing data silos. A bolt-on MES + a separate CMMS + a separate LIMS can each be excellent and still can't answer โdoes the fryer make more scrap in the week before a bearing fails?โ โ because no single system holds both halves. That question is the entire argument for MOM.
๐ง Why a PLC programmer should care. All four rooms want data from the same interface block you build in section 10 โ and once you see that, you stop under-scoping it. Your GoodCount feeds Production. Your FaultCode feeds Maintenance (that's MTBF). A measurement you log feeds Quality (that's SPC). Your CurrentLot consumption feeds Inventory. One tidy contract, four customers.
๐งญ One-liner: MOM is everything that happens on Level 3 โ production, quality, maintenance, inventory. MES is the room where the order gets made. Same floor, different amount of it.
MES drowns you in three-letter words on day one. Here's the whole vocabulary โ tap any card to flip it from jargon to plain English. Come back here whenever a term trips you up later in the lesson.
Strip away the jargon and an MES exists to answer five questions the PLC and ERP can't, all day, automatically:
OEE โ Overall Equipment Effectiveness โ is the headline metric MES produces. It's three honest fractions multiplied together: Availability ร Performance ร Quality. Because they multiply, a "pretty good" 90% on each collapses to a mediocre 73% overall. Drag the sliders and watch where the losses go.
World-class is widely cited as ~85% (โ 90% availability ร 95% performance ร 99.9% quality). Most plants that have never measured discover they're nearer 40โ60% โ the "hidden factory" you already own.
Here's the whole thing working. A work order drops in: make 600 glazed donuts. MES dispatches it to the line, watches the three machines, counts good and scrapped units, computes OEE live, and writes a traceable record. Press Start shift โ then sabotage it: inject a breakdown, a slow-down, or a bad batch and watch each one bite a different part of OEE. This is what a clipboard can never do.
Every line in that black log is data MES captured automatically: a timestamp, a reason code, a lot number. At shift end it becomes the OEE scorecard and the traceability record โ no clipboard, no "I think it was around 2pm."
Traceability (a.k.a. genealogy) is MES's quiet superpower: for any finished unit, it can tell you every material lot, machine, operator, setting and timestamp that touched it โ and run that backwards or forwards.
โฌ ๏ธ Backward trace
"This boxed donut failed a customer test โ what flour lot, fryer, and operator made it?" One query, seconds. The recall scope shrinks from a whole month to one 40-minute batch.
โก๏ธ Forward trace
"Flour lot #L-2291 is contaminated โ which finished pallets contain it, and where did they ship?" MES lists exactly the affected units. Recall only those, not everything.
๐ Why it's law
In food, pharma, auto and aerospace, genealogy isn't optional โ regulators (FDA, etc.) require you to prove what went into each unit. MES is how you prove it without a warehouse of paper.
The three get confused constantly. The clean split is time horizon and question asked:
| SCADA / HMI | MES | ERP | |
|---|---|---|---|
| ISA-95 level | Level 2 | Level 3 | Level 4 |
| Question | "What is the process doing now?" | "How is the order running, and prove it?" | "What did the business do, and what's next?" |
| Time horizon | Millisecondsโseconds | Secondsโshift | Daysโmonths |
| Cares about | Tags, alarms, trends, control | Orders, OEE, genealogy, dispatch, WIP | Finance, inventory, planning, customers |
| If it goes down | You lose live view/control | You lose tracking & traceability (line may run) | You can't invoice or plan |
| Donut line | "Fryer temp 178 ยฐC, motor on" | "Order #71: 412/600 made, OEE 68%, lot L-2291" | "Ship 600 to Acme Fri; bill โฌ900" |
๐งญ One-liner: SCADA watches the machine, ERP runs the business, MES runs the order โ and is the only one that can prove what actually happened on the floor. (Widen MES to all four Level-3 domains and you've got MOM.)
MES is useless in isolation โ its value is being wired to both neighbours. Two standards do the heavy lifting:
โฌ๏ธ Up to ERP โ ISA-95 / B2MML
ISA-95 is the model for MESโERP integration; B2MML (Business To Manufacturing Markup Language) is its XML implementation โ a shared vocabulary for production orders, schedules, material and results, so SAP and the MES agree on what "an order" is.
โฌ๏ธ Down to the floor โ OPC UA & MQTT
OPC UA (often with Sparkplug B over MQTT) is how MES reads PLC/SCADA tags securely and vendor-neutrally โ self-describing data so the MES can subscribe to "good count" or "fault reason" without a custom driver per machine.
๐งต The buzzword tying it together: the digital thread โ one connected data trail from customer order (ERP) โ executed work & genealogy (MES) โ live signals (SCADA/PLC) and back. MES is the spool that thread winds onto.
"MES reads the PLC" sounds magic until it's your job. It isn't magic โ it's a tidy, deliberate handful of steps. You never let the MES poke random memory addresses; you build it a clean, named interface and publish exactly that. Here's the real recipe, in order.
1 ยท Build a dedicated MES interface block. In the PLC, make one well-named structure/DB โ e.g. stMES_Interface โ holding only what MES needs: OrderID, TargetQty, GoodCount, RejectCount, MachineState, FaultCode, CurrentLot, Heartbeat. Never expose your whole tag database. This contract is the only thing MES sees.
2 ยท Maintain the data in logic. Increment GoodCount/RejectCount on each part, latch FaultCode with a reason code when you stop, set MachineState (run/idle/down), and toggle a Heartbeat bit every cycle so MES can tell "value is 0" from "PLC is dead." Timestamp matters โ keep the PLC clock synced (NTP).
3 ยท Turn on a server and publish those symbols. Enable the controller's OPC UA server and mark only the interface block's members as accessible/published. (Or publish them as an MQTT Sparkplug B edge node.) Set access rights โ counts read-only, order fields writable by MES.
4 ยท Design a handshake for orders coming down. MES writes OrderID + TargetQty, then sets OrderReady. The PLC reads them, loads the job, and sets OrderAck. MES clears OrderReady; the PLC clears OrderAck. That four-step "ready/ack" dance prevents half-written orders and race conditions.
5 ยท Test it with a client before MES connects. Point an OPC UA test client (UaExpert) at the server, browse the address space, confirm you see GoodCount ticking and can write a test OrderID. Prove the interface works in isolation โ then hand the endpoint + credentials to the MES integrator.
6 ยท Lock it down. OPC UA with certificates + a named user (not anonymous), read-only wherever possible, and the MES/historian on a segmented network โ not a flat line with the internet. (See the IT/OT Security lesson.)
// The MES interface block โ the ONLY thing you publish TYPE stMES_Interface : STRUCT OrderID : STRING; // โ written by MES TargetQty : DINT; // โ written by MES OrderReady : BOOL; // โ MES: "new order is valid" OrderAck : BOOL; // โ PLC: "got it, loaded" GoodCount : DINT; // โ read-only to MES RejectCount : DINT; // โ read-only MachineState : INT; // โ 0=idle 1=run 2=down FaultCode : INT; // โ the downtime reason code CurrentLot : STRING; // โ for genealogy Heartbeat : BOOL; // โ toggles every scan = "I'm alive" END_STRUCT END_TYPE
๐งฐ Which tool, on which platform
| Platform | Expose the data withโฆ | Common bridge / middleware |
|---|---|---|
| Beckhoff TwinCAT 3 | TF6100 OPC UA Server (mark symbols), or TF6701 IoT for MQTT; ADS underneath | UaExpert to test |
| Siemens S7-1500 / TIA Portal | Built-in OPC UA server โ flag tags "accessible from OPC UA" | UaExpert; SIMATIC tag tables |
| Rockwell Logix | Logix tags over EtherNet/IP (CIP) | KEPServerEX / FactoryTalk Linx as the OPC bridge; FactoryTalk Transaction Manager โ DB |
| CODESYS-based | CODESYS OPC UA Server + symbol configuration | UaExpert |
| Any / mixed fleet | โ | Kepware, Ignition (OPC UA + MQTT/Sparkplug + UNS), Node-RED for prototyping, an MQTT broker for the Unified Namespace |
๐งญ Two valid paths: PLC โ OPC UA โ MES directly, or PLC โ SCADA (Ignition / WinCC / FactoryTalk View) โ MES, where SCADA already holds the tags and a historian. The PLC programmer's job is the same either way: publish a clean, named interface โ not raw addresses.
Tape this above the desk. If you remember nothing else about MES, remember these.