Networking Fundamentals

Layers and protocol stacks, network levels, topologies, messaging models, speed, latency and determinism.

Why industrial machines are networked

A machine used to be a cabinet of relays with one wire for every signal. Now a PLC talks to drives, remote I/O blocks, meters, barcode readers, HMIs, vision systems, robots and databases, and most of those links are a cable that carries messages rather than a wire that carries one signal. Networking saves wiring, adds diagnostics and lets different brands work together, but it also adds a new class of fault: the machine is mechanically and electrically fine, and still stops because two devices disagree about a baud rate, an address, a register or a byte order.

This guide takes you from the basic ideas on this page, through serial links, Modbus, fieldbuses, industrial Ethernet, IP addressing and the newer OPC UA and MQTT, to cabling, security and troubleshooting. Wherever a number matters (a frame size, a cycle time, a voltage, a cable length) it is computed in the page so you can follow it and reuse the method.

What a network gives youWhat it costs
Less wiring. One cable and a few terminals instead of dozens of wire pairs.The cable and the connectors are now critical parts: a bad crimp stops many signals at once.
Rich data. Parameters, diagnostics, device identity and tag names, not just on/off.Each device needs set-up: addresses, speeds, files, names.
Distributed intelligence. Drives and I/O blocks near the process, PLCs in the cabinet.Timing depends on the network, not only on the program scan.
Integration. The same data reaches SCADA, MES and cloud services.A larger attack surface and more to keep documented and secure.

Network levels

Plants are organized in levels. Each level has its own speed and its own job, and usually its own protocols. Fast, deterministic links connect the controller to the field devices; standard Ethernet joins controllers and supervisory systems; IT-style protocols carry data upwards. The boundaries are not strict (Ethernet protocols now reach down to the sensor) but the idea helps you choose and troubleshoot.

Enterprise and cloudMQTT, HTTPS, OPC UA, SQLtime scale: seconds to minutesPlant: SCADA, MES, historianOPC UA, Modbus TCP, EtherNet/IP, PROFINETtime scale: 100 ms to secondsControl: PLC to PLC, HMIEtherNet/IP, PROFINET, OPC UA, S7, FINStime scale: 10 to 100 msDevice: drives, remote I/O, motionPROFINET, EtherNet/IP, EtherCAT, PROFIBUS, Modbustime scale: 0.1 to 10 msSensor: simple field devicesIO-Link, AS-Interface, HART, 4-20 mA, switchestime scale: 1 to 10 msHigher levels are slower but carry more data; lower levels must be fast and predictable.
Typical protocol families by plant level, with the time scale that matters at each level.
LevelTypical devicesWhat matters mostTypical protocols
SensorProximity switches, valves, simple transmittersCost per point, wiring, remote diagnosticsIO-Link, AS-Interface, HART, 4–20 mA
DeviceDrives, servos, remote I/O, encodersSpeed, determinism, synchronizationPROFINET, EtherNet/IP, EtherCAT, PROFIBUS, CANopen, Modbus
ControlPLCs, HMIs, safety controllersReliability, response in tens of millisecondsEtherNet/IP, PROFINET, S7, FINS, OPC UA
PlantSCADA, historian, MES, engineering stationsData volume, security, integrationOPC UA, Modbus TCP, SQL, MQTT
Enterprise and cloudERP, analytics, dashboardsSecurity, scale, standard IT toolsMQTT, HTTPS, OPC UA, AMQP

Layers and protocol stacks

Communication is divided into layers, each doing one job and relying on the one below. The seven-layer OSI model is the common vocabulary; the TCP/IP stack used on Ethernet networks has four. Serial Modbus uses only the bottom and top. You do not need to memorize the layers, but you do need the habit they teach: if a lower layer is broken, nothing above it can work, so check from the bottom up.

OSI layerUsed by Ethernet protocolsUsed by serial ModbusTypical question7 ApplicationModbus, CIP, OPC UA, S7Modbus function codesIs the address right?6 PresentationData types, byte order, TLSRegister formatsWord order?5 SessionTCP connection, OPC UA session(none)Connection open?4 TransportTCP 502 / 44818, UDP 2222(none)Port blocked?3 NetworkIP address, routing(none)Subnet, gateway?2 Data linkEthernet frame, MAC addressRTU frame, CRC, addressCRC errors, duplicates?1 PhysicalCat5e / M12, 100BASE-TXRS-485 pair, RS-232Cable, polarity, termination?Troubleshoot from layer 1 upwards: nothing at a higher layer works until the layers below do.
The OSI layers, what Ethernet and serial protocols put at each, and the typical question to ask at each layer.
LayerJobIndustrial examples
1 PhysicalMove raw bits as voltages, light or radio over a mediumRS-232, RS-485, 100BASE-TX, fiber, 4–20 mA, M12 connectors
2 Data linkFrame the bits, address devices on one segment, detect errorsEthernet frames and MAC addresses, Modbus RTU framing with CRC, CAN frames, PROFIBUS telegrams
3 NetworkRoute packets between networksIP addresses, routers, VLAN routing
4 TransportDeliver data between programs, with or without guaranteesTCP (reliable, connection), UDP (fast, no guarantee)
5 Session, 6 Presentation, 7 ApplicationMeaning of the data: commands, data types, securityModbus function codes, CIP, S7 communication, OPC UA, MQTT

How a message is wrapped

On an Ethernet network each layer wraps the data from the layer above with its own header. A Modbus TCP read of ten registers is only 5 bytes of Modbus (function code, start address, quantity) but travels in a frame of 70 bytes.

Ethernet14 BMAC addressesIP20 BIP addressesTCP20 Bport 502MBAP7 Bunit, lengthModbus PDU2 to 253 Bfunction + dataFCS4 Bframe checkOne Modbus TCP frame on the wire (a read request has a 5-byte PDU: function, start address, quantity)switch readsrouter readsfirewall rule(port 502)the device and the gateway read thisEach layer adds its own header. A sniffer shows all of them; a gateway rewrites some of them.
A Modbus TCP frame: Ethernet, IP, TCP, MBAP header, then the Modbus function and data.

Worked example: how big is a Modbus TCP read?

  • Request: Ethernet header 14 + IP 20 + TCP 20 + MBAP 7 + Modbus PDU 5 (function 1, start address 2, quantity 2) + frame check 4 = 70 bytes.
  • Response to a read of 10 holding registers: the PDU is function 1 + byte count 1 + 20 data bytes = 22 bytes, so the frame is 14 + 20 + 20 + 7 + 22 + 4 = 87 bytes. The 20 bytes you wanted are in a frame of 87.
  • On a serial Modbus RTU line the same exchange is only 33 bytes (8 request + 25 response), because there are no Ethernet, IP and TCP headers. Ethernet is far faster per bit, so it still wins: 33 bytes at 9 600 baud take about 34.4 ms on the wire, and 157 bytes at 100 Mbit/s take about 15.8 microseconds.

The header overhead is why protocols that send many small values (MQTT, EtherNet/IP cyclic I/O) group them into one message rather than one message per value.

Topologies

Topology is the shape of the cabling. It decides how many cables fail together and how easy the network is to extend and diagnose.

Bus (RS-485, PROFIBUS, CAN)One cable, short stubs, terminated ends.A break splits the bus in two.Star (switched Ethernet)SwitchEasy to diagnose; a break isolates one device.Line (daisy chain)Devices with two ports (PROFINET, EtherCAT).Saves cable; a break cuts offeverything beyond it.Ring (media redundancy)One link is blocked by the ringmanager (dashed). If another linkbreaks, the blocked one opens inmilliseconds (MRP, RSTP, HSR).Tree (star of stars)CoreSwitchSwitchSwitchTypical plant: a core switch and machine switches.
Bus, star, line, ring and tree, and what a single cable break does in each.
TopologyUsed byStrengthsWeaknesses
BusRS-485, PROFIBUS, CAN, DeviceNetLittle cable; devices are added along the runNeeds terminators and short stubs; a break or a short can take down the whole bus; hard to find faults
StarSwitched Ethernet, IO-LinkEasy to see and test; a fault isolates one branch; scales wellMore cable; the switch is a single point of failure
Line (daisy chain)PROFINET and EtherCAT devices with two ports, AS-InterfaceShort cable runs along a machine, no external switchesA break cuts off everything beyond it; every device in line adds a little delay
RingMRP, RSTP, HSR rings; EtherCAT with cable redundancySurvives one cable breakNeeds managed devices and testing; two breaks still split it
TreeLarge plantsA core and machine switches fit the plant layoutUplinks can become bottlenecks; plan the bandwidth

Messaging models

Who starts a conversation, and who may speak, is the next idea. Three models cover most industrial protocols.

Master / slave (polling)Masterasks, then waitsSlave 1Slave 2Slave 3Slave 4Only the master starts a conversation.Modbus RTU, DF1, PROFIBUS DP.Client / serverClientHMI, SCADAServerPLC, driverequestreplySeveral clients can ask one server.Modbus TCP, OPC UA, S7, FINS,EtherNet/IP explicit messages.Producer / consumerProducersends on a timerConsumerConsumerConsumerOne message reaches many receivers.EtherNet/IP I/O, PROFINET RT,MQTT (through a broker).
Master/slave polling, client/server, and producer/consumer.
ModelHow it worksGood forWatch for
Master / slaveOne master asks each slave in turn and waits for the reply; slaves never speak firstSerial buses; simple and predictableSlow for many devices; a dead slave costs a timeout; no alarms from a slave until polled
Client / serverAny client opens a connection, asks, and receives a replyHMI and SCADA reading controllers; OPC UA; Modbus TCPPolling loads the server; too many clients exhaust its connections
Producer / consumerA device sends its data on a timer or on change; interested devices receive itCyclic I/O (EtherNet/IP, PROFINET), MQTTNeeds multicast control; a consumer that missed packets must detect it
TermMeaning
Cyclic dataProcess data exchanged automatically at a fixed rate, such as I/O values
Acyclic dataOn-demand data: parameters, diagnostics, configuration
PollingAsking repeatedly for a value, whether or not it has changed
Report by exceptionSending a value only when it changes by more than a deadband
Unicast, multicast, broadcastTo one device, to a group that asked, or to every device on the segment

Speed, bandwidth, latency and determinism

These four words are often mixed up. Bandwidth is how many bits per second the link can carry. Latency is how long one message takes to arrive. Jitter is how much that time varies. Determinism is the guarantee that a message arrives within a known time, every time. For a control loop or a servo axis, a predictable 1 ms beats an average of 0.2 ms with occasional 20 ms delays.

0.1 ms1 ms10 ms100 ms1000 msEtherCATPROFINET IRTPROFINET RTEtherNet/IP I/OPROFIBUS DPModbus TCPModbus RTU, 9600Typical cycle or update time (bars show the usual range; log scale)
Typical update times of common industrial protocols on a log scale.

Worked example: where does the time go on a 100 Mbit/s link?

  • Putting the frame on the wire. The smallest Ethernet frame is 64 bytes, and the preamble and the gap between frames take another 20 bytes of time, so 84 bytes = 672 bits. At 100 Mbit/s that is 6.72 µs; at 1 Gbit/s it is 0.67 µs. A full 1518-byte frame takes 123.0 µs at 100 Mbit/s.
  • Travel. A signal moves at about 200 meters per microsecond in cable, so 100 m of cable adds about 0.50 µs.
  • Switches. A store-and-forward switch receives the whole frame before sending it on, so each switch adds at least one frame time plus some processing: roughly 5 to 20 µs at 100 Mbit/s. Ten switches in a line add 50 to 200 µs, which is why long daisy chains matter for fast motion.
  • The queue. If a 1518-byte frame from another device is already being sent, yours waits up to 123.0 µs. Priority (QoS) and real-time protocols exist to avoid this.
  • The software. The device must read the frame, run its stack and update its outputs: often the biggest part, from tens of microseconds in hardware-assisted devices to milliseconds in a PLC task.
  • Compare serial: one character at 9 600 baud takes 1.04 ms, a thousand times longer than a whole minimum Ethernet frame.
  • Cycle time versus scan time. A network cycle and a PLC scan are independent unless the system synchronizes them. Data may be one scan plus one cycle old when the program uses it.
  • Plan with margin. Keep link load under about 30 to 50 percent on a control network. Bursts and retries need headroom.
  • Measure, do not assume. The diagnostics of a switch, a drive or a PLC show the real update times and error counts.

Numbers, bytes and byte order

Industrial data is shown in several number systems, and you will switch between them all the time. A bit is 0 or 1; a byte is 8 bits (two hexadecimal digits); a word is usually 16 bits (a Modbus register) and a double word 32 bits.

DecimalBinaryHexNote
00000 000000
100000 10100AThe value in register 0 of the Modbus examples
2551111 1111FFLargest unsigned byte; also the Modbus coil ON value (FF 00)
2580000 0001 0000 001001 02High byte 01, low byte 02
32 7670111 1111 1111 11117FFFLargest signed 16-bit integer
65 5351111 1111 1111 1111FFFFLargest unsigned 16-bit integer; as signed it is −1
−11111 1111 1111 1111FFFFTwo’s complement 16-bit

Byte order (endianness) says which byte comes first. Network protocols such as Modbus send the high byte first (big-endian). Some devices and tools differ for 32-bit values: the two registers can arrive with the high word first or the low word first. The Modbus page shows a worked example, and the same issue appears in EtherNet/IP data and in files exchanged with PCs. When a number reads as nonsense but the link is healthy, suspect byte or word order first.

The site’s bitwise and register calculator converts between these systems, and the Modbus Frame and CRC Calculator builds and decodes real frames.

Choosing a network

SituationReasonable choiceWhy
Read values from a power meter, VFD or temperature controllerModbus RTU (RS-485) or Modbus TCPAlmost every device supports it; free documentation; simple to test
Siemens PLC with remote I/O and drivesPROFINETNative to the platform; strong tools
Rockwell Automation / Allen-Bradley PLCEtherNet/IPNative to the platform
Synchronized multi-axis motionEtherCAT or PROFINET IRTDeterministic, very short cycles
Smart sensors that need remote setup and diagnosticsIO-LinkParameter storage and device replacement without a laptop
Many simple switches and valves on a machineAS-Interface or remote I/O blocksCuts wiring: one cable per branch
Mixed brands and supervisory dataOPC UAVendor-neutral, secure, self-describing
Data to a cloud dashboardMQTT through a gatewayEfficient over slow or unreliable links
Existing plant on PROFIBUSKeep PROFIBUS; add gateways to EthernetReplacing a working bus rarely pays

Choose first for what your controller and key devices support natively, then for the speed and determinism you need. A gateway can translate between protocols when you must mix them, but each adds cost, delay and a place for faults.

Glossary

TermMeaning
Baud rateSymbols per second on the line; on a simple serial line the same as bits per second
CRCCyclic redundancy check: a number computed from the data to detect transmission errors
Frame, packet, telegramOne complete message on the wire
GatewayA device that translates between two networks or protocols; also the router address in IP settings
MAC addressThe fixed 48-bit hardware address of a network port, written like 00:1B:1B:12:34:56
Node, station, deviceAny addressable participant on a network
PayloadThe useful data inside a frame, excluding headers
TerminatorA resistor at the end of a bus that stops signal reflections
ThroughputThe useful data actually delivered per second, always less than the bandwidth
TTL, RPI, timeoutHow long a device waits, or how often it sends, before it decides the other end is gone

Related

FAQ

What is the difference between a protocol and a network?

A protocol is the set of rules for the messages (their format, order and meaning). A network is the cabling and devices that carry them. One Ethernet network can carry several protocols at once.

Why can I ping a device but not read its data?

Ping proves the lower layers (cable, IP address, subnet). The data uses a higher layer (a port, a protocol, an address inside the device): check the port, the protocol settings and any firewall.

Is Ethernet fast enough for control?

Standard TCP/IP traffic is not deterministic, but the real-time industrial Ethernet protocols (EtherNet/IP I/O, PROFINET RT and IRT, EtherCAT) give cycles from a few milliseconds down to well below a millisecond on the same style of cable.

Do I need to learn all of the protocols?

No. Learn the ones your controllers and key devices use, and the general rules (physical layer first, matching settings, unique addresses). The same habits carry across.

What is the single most common cause of communication faults?

A mismatch of settings between the two ends, followed by wiring (polarity, termination, connectors). Both are found by working from the bottom up.

References

  • IEC 7498-1 / ISO/IEC 7498-1, Open Systems Interconnection: Basic Reference Model.
  • IEEE 802.3, Ethernet; IEC 61158 and IEC 61784, Industrial communication networks: fieldbus specifications and profiles.
  • Mackay, S. et al., Industrial Data Communications, ISA; Wilamowski, B. and Irwin, J. D., Industrial Communication Systems, CRC Press.
  • Modbus Organization, MODBUS Application Protocol Specification V1.1b3 (Modbus TCP frame structure).

Last reviewed: October 2026. Speeds, lengths, node counts and menu names are typical: confirm against the specification and the manufacturer’s documentation for the devices you use.