
Průmyslová automatizace: PLC a HMI
PLC a HMI jsou mozek a oči moderní průmyslové automatizace — nahrazují tisíce relé jedním programovatelným zařízením.
Připravil jsem ti kompletní přehled na téma „Průmyslová automatizace: PLC a HMI".

PLC a HMI jsou mozek a oči moderní průmyslové automatizace — nahrazují tisíce relé jedním programovatelným zařízením.
DATE: 2026-02-22
Welcome to another installment of the kWiki series on industrial drives and controls. Having explored the muscles of automation—Induction Motors, Servo Motors, and PM Motors—and the ways we control them with VFDs and Softstarters, it's time to delve into the brain that orchestrates it all: the world of industrial automation, with a special focus on Programmable Logic Controllers (PLCs) and Human-Machine Interfaces (HMIs).
This article is designed for beginners. If you're an apprentice technician, a mechanical engineer curious about controls, or a student taking your first steps into this field, you're in the right place. We will demystify the core concepts, stick to the fundamentals, and provide practical, real-world context using European standards and terminology.
A Note on Scope: Industrial automation is a vast topic that could fill a library. Our goal here is not to make you an expert overnight. Instead, we will build a solid foundation, focusing on the 80% of concepts you'll encounter daily. We will deliberately skip deep dives into robotics, complex SCADA architectures, and safety systems, touching on them only to provide context.
Let's begin the journey from raw electricity to intelligent, automated action.
To understand why PLCs are so important, we must first appreciate the world that existed before them.
Imagine a factory in the 1960s. The control system for a machine, perhaps a large press or a conveyor line, was housed in massive steel cabinets. Inside, you wouldn't find a single microchip. Instead, you'd see hundreds, sometimes thousands, of electromechanical relays, timers, and counters, all interconnected by a dizzying web of wires.
This was relay logic. Each relay is a simple switch operated by an electromagnet. By wiring them in series or parallel, engineers could create basic logic functions (AND, OR, NOT). A simple task like "If Sensor A AND Sensor B are active, THEN start Motor C, but only if the Emergency Stop is NOT pressed" would require multiple relays wired together.
These systems worked, but they had significant drawbacks: * Size: The control panels were enormous and heavy. * Inflexibility: If the machine's logic needed to change, even slightly, an electrician had to spend hours or days physically rewiring the panel. * Troubleshooting: Finding a fault was a nightmare. A single failed relay or a loose wire could take a skilled technician hours to locate with a multimeter. * Cost: The sheer amount of labour required for design, assembly, and modification was immense. * Wear and Tear: Being mechanical, relays have a finite lifespan and would eventually wear out and fail.
The automotive industry, with its annual model changes, felt this pain most acutely. In 1968, General Motors' Hydramatic division issued a challenge to the industry: design an electronic replacement for relay panels that was flexible, reliable, and easy to program.
A small company from Bedford, Massachusetts, called Bedford Associates, answered the call. Led by the legendary engineer Richard "Dick" Morley, they developed a device they called the "Programmable Controller." The first successful model, sold to GM, was the Modicon 084 (named for the 84th project at Bedford Associates).
This was the world's first Programmable Logic Controller (PLC). It was a revolutionary concept: the physical wiring was replaced by software. The logic was no longer in the wires but in a program stored in the controller's memory. Changing the machine's operation was now a matter of reprogramming the unit, not rewiring it.
The Modicon 084 was just the beginning. The evolution of the PLC mirrored the explosion of microprocessor technology: * 1970s: PLCs grew in popularity, but were still large and expensive. Programming was done with dedicated, clunky terminals. * 1980s: The advent of the microprocessor made PLCs smaller, cheaper, and more powerful. Communication capabilities emerged, allowing PLCs to talk to each other. * 1990s: PLCs became even more compact. PC-based software replaced dedicated programmers, making development easier. IEC 61131-3 was established, standardizing PLC programming languages. * 2000s-Today: Modern PLCs are incredibly powerful. They are compact, feature-rich controllers with advanced capabilities in motion control, process control, and networking. They form the backbone of modern automation, from small standalone machines to entire factory floors.
As the PLC became the brain, the Human-Machine Interface (HMI) evolved to become its face. Early "interfaces" were just rows of indicator lamps and push-buttons. In the 1980s, simple text-based panels emerged, allowing operators to read basic messages. The real game-changer was the graphical touchscreen in the 1990s, which allowed for rich, intuitive visualization and control of the machine, paving the way for the advanced panels we use today.
At its core, industrial automation is the use of control systems—like computers or PLCs—to operate industrial machinery and processes, reducing the need for human intervention.
The fundamental principle of any automation system can be broken down into a simple, continuous loop: Sense → Decide → Act.
This loop then repeats, often hundreds of times per second.
You interact with this "Sense, Decide, Act" loop all the time:
An industrial automation system is just a more powerful, more flexible, and more robust version of these everyday examples.
Companies invest heavily in automation for several key reasons:
The Programmable Logic Controller (PLC) is the heart of most modern automation systems. While a standard desktop PC could technically perform the "Decide" function, a PLC is purpose-built for the industrial environment.
A PLC is an industrial-grade computer, designed from the ground up to be: * Rugged: It can withstand the harsh conditions of a factory floor: vibration, extreme temperatures, electrical noise, and humidity. * Real-Time: It executes its program in a very predictable and repeatable timeframe. When you need a response in a few thousandths of a second, a PLC delivers; a standard PC operating system like Windows cannot make that guarantee. * Easy to Interface: It has built-in inputs and outputs (I/O) that are designed to connect directly to industrial sensors and actuators. The standard control voltage in Europe is 24V DC, and PLCs are designed to work with this natively.
A PLC doesn't run its program like a normal computer. Instead, it operates on a continuous, repetitive loop called the scan cycle. This cycle is the fundamental concept of PLC operation.
This entire cycle happens incredibly fast, typically in 1 to 50 milliseconds (0.001 to 0.050 seconds). This means the PLC can react to changes in the real world almost instantaneously.
Every PLC, regardless of size, has three main parts: * CPU (Central Processing Unit): This is the brain. It's a microprocessor that runs the program, performs the logic, and manages all other functions. * Memory: This is where the user's program is stored, along with the status of the I/O and other data values. * I/O (Input/Output) Modules: These are the PLC's senses and hands. Input modules are the connection points for sensors and switches. Output modules are the connection points for actuators like motors and lights.
PLCs come in two main physical formats:
The choice between compact and modular depends entirely on the size and complexity of the application.
In the early days, every PLC manufacturer had its own proprietary programming language. This made it difficult for programmers to switch between brands. To solve this, the IEC 61131-3 standard was created. It defines a suite of five standard programming languages, giving programmers a common framework.
While the standard defines five, three of them are used in the vast majority of applications. We will focus on those, as our goal is a high-level overview, not a detailed tutorial.
Ladder Logic, also known as Ladder Diagram (LD), is by far the most popular PLC programming language in the world, especially in North America. Its design is based on the electrical relay logic schematics that it replaced.
A very simple rung might look like this in text form: |--[ Start_Button ]--[ Stop_Button_NC ]--( Motor_Contactor )--| This means: "If the Start_Button is pressed AND the Stop_Button is NOT pressed, THEN energize the Motor_Contactor."
Function Block Diagram is a graphical language that connects "blocks" of code together. Each block has inputs and outputs and performs a specific function.
Structured Text is a high-level, text-based programming language. If Ladder Logic is for electricians, Structured Text is for computer programmers.
A simple example in ST:
IF Start_Button AND NOT Stop_Button THEN Motor_Contactor := TRUE; ELSE Motor_Contactor := FALSE; END_IF;
The IEC standard also includes: * Instruction List (IL): A low-level, text-based language similar to assembly. It's less common today. * Sequential Function Chart (SFC): A graphical language for structuring the overall program flow. It's used to manage different states or steps in a machine's sequence, with each step containing its own logic written in LD, FBD, or ST.
Most modern PLC programs are a hybrid, using the best language for the job. For example, an engineer might use SFC to structure the main machine sequence, Ladder Logic for most of the discrete I/O logic, and a Structured Text block for a complex calculation.
The PLC market is dominated by a few major players, each with its own hardware platforms, software suites, and loyal following. In Europe, the landscape is particularly competitive. When a factory chooses a primary PLC vendor, they are not just buying a piece of hardware; they are investing in an entire ecosystem.
Several other brands hold significant market share and are known for specific strengths: * Omron: A Japanese company strong in smaller PLCs and components like sensors and vision systems. * ABB: A Swiss-Swedish company with a strong foothold in robotics and large-scale process control (DCS). * Beckhoff: A German innovator known for pioneering PC-based control, where a powerful industrial PC running a real-time operating system acts as the PLC.
PLC pricing varies wildly based on performance, I/O count, and software licenses. The hardware is often just the starting point.
If the PLC is the brain, the HMI is the face and voice of the machine. The Human-Machine Interface is the device an operator uses to monitor, control, and interact with the automated process. It's the bridge between the human user and the PLC's logic.
An HMI's purpose is to translate complex process variables into usable, graphical information. It takes raw data from the PLC—like temperatures, pressures, motor speeds, and fault codes—and displays it in an intuitive way. It also takes input from the operator via buttons, sliders, or data entry fields on the screen and sends those commands back to the PLC.
HMIs range from very simple to highly sophisticated:
Regardless of its size or cost, nearly every HMI provides these essential functions:
The terms HMI and SCADA are often used interchangeably, but they are not the same.
Sensors are the eyes and ears of the automation system. They are the "Sense" part of our "Sense, Decide, Act" loop. They convert a physical property (like position, temperature, or pressure) into an electrical signal that the PLC's input module can understand.
We can group inputs into two main categories: digital and analog.
Digital inputs are the simplest. They are either ON or OFF, representing a binary state (1 or 0). The standard signal voltage for these in Europe is 24V DC. When the PLC's input terminal receives 24V, it reads a "1"; when it sees 0V, it reads a "0".
Common digital sensors include: * Push Buttons & Switches: The most basic operator inputs (e.g., Start, Stop, Auto/Manual). * Proximity Sensors: Detect the presence of an object without physical contact. Inductive sensors detect metal, while capacitive sensors can detect almost any material. * Photoelectric Sensors: Use a beam of light to detect objects. When an object breaks the beam, the sensor's output changes state. * Limit Switches: A mechanical switch with an arm that is physically actuated when an object makes contact with it.
Analog inputs provide a variable signal that represents a range of values. This allows the PLC to measure things, not just detect their presence.
The two most common analog signal standards in industry are: * 4-20mA: A current loop signal. 4mA represents the minimum value of the sensor's range (e.g., 0°C), and 20mA represents the maximum value (e.g., 100°C). This is the most common standard because it is highly resistant to electrical noise over long cable distances and allows for simple fault detection (if the signal is 0mA, it means the wire is broken). * 0-10V: A voltage signal. 0V represents the minimum value, and 10V represents the maximum. It's simpler but more susceptible to voltage drops and noise over long distances.
Common analog sensors include: * Temperature Sensors (RTDs, Thermocouples): Measure process temperature. They are almost always connected to a transmitter that converts their reading into a standard 4-20mA or 0-10V signal. * Pressure Transducers: Measure liquid or gas pressure. * Flow Meters: Measure the rate of fluid flow in a pipe. * Level Sensors: Measure the level of liquid in a tank.
Actuators are the hands and feet of the automation system. They are the "Act" part of the loop. They take an electrical command from the PLC's output module and convert it into a physical action, like starting a motor or opening a valve.
Like inputs, outputs can be digital or analog.
Digital outputs from a PLC simply turn a device ON or OFF. The PLC output module acts as a switch (typically a transistor or a small relay) that provides a 24V DC signal to energize the actuator's control circuit.
Common digital actuators include: * Indicator Lights & Sounders: Provide visual or audible feedback to the operator. * Relays: A PLC output can't directly power a large motor. Instead, the PLC's 24V DC output energizes a small relay, which in turn switches a higher power circuit. * Contactors: A heavy-duty version of a relay, used to switch the high-voltage (400V AC in Europe) power required to start and stop large induction motors. * Solenoid Valves: An electrically operated valve used to control the flow of air (pneumatics) or liquid (hydraulics).
Analog outputs provide a variable 4-20mA or 0-10V signal to control devices that can operate at different levels, not just on or off.
The most common use for an analog output is controlling motor speed: * Variable Frequency Drive (VFD) Speed Control: This is a perfect example of system integration. The PLC sends a 0-10V signal to the VFD. The VFD interprets this signal as a speed command (e.g., 0V = 0 Hz, 10V = 50 Hz). This allows the PLC to precisely control the speed of a motor for the process. For a complete guide on how VFDs work, see our dedicated VFD article. * Proportional Valves: These are sophisticated valves that can be opened to any position (e.g., 0%, 25%, 100%) based on the analog signal they receive, allowing for precise control of flow or pressure.
By combining these inputs and outputs, a PLC can orchestrate the complex dance of a modern machine, linking sensors like those in our Electric Drives for Dummies guide to the motors detailed in our Induction Motors article.
In a modern factory, no device is an island. The PLC needs to talk to the HMI, the VFDs, other PLCs, and supervisory systems. This is achieved using industrial communication protocols, which are like the languages that automation devices use to speak to each other.
There are dozens of protocols, but a few dominate the market.
The choice of protocol is often dictated by the choice of PLC vendor (e.g., a Siemens PLC will speak Profinet natively), but Modbus and OPC UA serve as excellent vendor-neutral options.
Let's bring all these concepts together with a simple, practical example. We need to automate a small conveyor belt that moves boxes from one point to another.
Requirements: 1. An operator must be able to start and stop the conveyor using push buttons. 2. A green light should indicate when the conveyor motor is running. 3. A mushroom-head Emergency Stop (E-Stop) button must immediately stop the conveyor if pressed. 4. The motor is a standard 400V AC induction motor, controlled by a contactor.
I/O List:
First, we define what signals need to go into and out of our PLC. We'll use a small compact PLC, like a Siemens S7-1200.
Basic Ladder Logic Diagram
The core of this program is a classic "start/stop latch" circuit. Here is a text representation of the two rungs of logic required:
Rung 1: Motor Control
|--[ Start_PB ]--+--[ Motor_On ]--|--[ Stop_PB_NC ]--|--[ E-Stop_NC ]--|--( Motor_Contactor )--| | | | | +----------------+
Rung 2: Indicator Light
|--[ Motor_On ]----------------------------------------------------( Green_Light )--|
HMI Screen Mockup
We'll add a small, basic touchscreen HMI (e.g., a 4-inch Siemens Basic Panel) to make it more user-friendly. The screen would be very simple:
The HMI buttons don't replace the physical buttons; they work in parallel with them, providing an alternative control point.
Simple Cost Breakdown
This is a rough estimate for a simple, robust control panel for this conveyor, built to European standards:
This doesn't include the cost of the motor, gearbox, or the conveyor itself. It also doesn't include the significant labor cost for design, assembly, programming, and testing.
Building a reliable automation system requires more than just programming. Here are some common pitfalls for beginners:
1. What's the real difference between a PLC and a regular PC? A PLC is a specialized industrial computer. Key differences are its rugged hardware built for factory environments, its real-time operating system (RTOS) that guarantees a predictable scan time, and its built-in I/O designed for industrial voltages like 24V DC. A PC running Windows is non-deterministic and not built to survive on a factory floor.
2. Can I learn PLC programming at home? Absolutely. Most major vendors (Siemens, Rockwell, etc.) offer free versions of their software for training purposes. These often include a PLC simulator, so you can write and test programs on your PC without buying any hardware. There are also many affordable starter kits available.
3. How much does a small automation system cost? As shown in our conveyor example, the material cost for a very simple system with a PLC and HMI is typically in the €1,000 - €2,000 range. The cost scales up quickly with complexity, I/O count, and performance requirements.
4. Is Ladder Logic the only language I need to know? While Ladder Logic is the most common, learning the basics of Structured Text (ST) is highly recommended. ST is far better for math, data handling, and complex logic, and most modern programs use a mix of languages.
5. What is the difference between a sensor and an actuator? A sensor is an input device that "senses" the world and sends a signal to the PLC (e.g., a proximity sensor). An actuator is an output device that "acts" on the world based on a command from the PLC (e.g., a motor contactor).
6. Do I always need a PLC? For very simple tasks with just a few logic functions, a full PLC might be overkill. A "smart relay" (like a Siemens LOGO! or Schneider Zelio) can be a more cost-effective solution. These are simple, programmable devices that bridge the gap between individual relays and a true PLC.
7. What does the "IP rating" on an enclosure mean? IP stands for Ingress Protection. It's a two-digit code defined in the IEC 60529 standard. The first digit rates protection against solids (dust), and the second digit rates protection against liquids (water). For example, IP65 means "Dust Tight" and "Protected against water jets."
8. What is CE marking? CE stands for "Conformité Européenne" (French for "European Conformity"). It's a mandatory marking for products sold within the European Economic Area. By affixing the CE mark, the manufacturer declares that the product meets all relevant EU health, safety, and environmental protection requirements.
9. Should I learn Siemens or Allen-Bradley? This is the classic question. The answer depends on your location and industry. In Europe, Siemens is dominant. In North America, Allen-Bradley is the leader. The best advice is to look at job postings in your area to see what companies are using. The fundamental concepts you learn on one platform are 90% transferable to the other.
10. What is the next step after learning PLC basics? Once you're comfortable with basic PLC programming, good next steps include HMI design (learning to create effective and intuitive screens), industrial networking (understanding how to set up Modbus or Profinet), and motion control (controlling servo motors for precise positioning tasks).