In the process of industrial production, a large amount of sequential control of switch quantities is carried out according to logical conditions, and interlocking protection actions are controlled according to logical relationships, along with the collection of a large amount of discrete data. Traditionally, these functions were realized through pneumatic or electrical control systems. In 1968, General Motors in the United States proposed the need to replace relay control devices. The following year, Digital Equipment Corporation developed a control device based on integrated circuits and electronic technology, using programmatic methods for electrical control for the first time. This was the first generation of programmable controllers, called Programmable Controllers (PC). With the development of personal computers (also abbreviated as PC), for convenience and to reflect the functional characteristics of programmable controllers, programmable controllers were named Programmable Logic Controllers (PLC).
From the 1980s to the mid-1990s, PLCs experienced the fastest growth period, with an annual growth rate consistently maintained at 30-40%. During this period, PLCs saw significant improvements in handling analog quantities, digital computing capabilities, human-machine interface capabilities, and network capabilities. PLCs gradually entered the field of process control, in some applications replacing the DCS systems that dominated the field of process control. PLCs are characterized by strong generality, ease of use, wide adaptability, high reliability, strong anti-interference ability, and simple programming. The status of PLCs in industrial automation control, especially in sequential control, is irreplaceable in the foreseeable future.
PLC can be divided into two types from the structural aspect: fixed and modular (or combinational). Fixed PLCs include CPU boards, I/O boards, display panels, memory blocks, power supplies, etc., combined into an indivisible whole. Modular PLCs include CPU modules, I/O modules, memory, power modules, and baseplates or racks, which can be combined according to certain rules.
CPU Composition
The CPU is the core of the PLC, acting as the central nervous system. Each PLC system has at least one CPU. It receives and stores user programs and data as per the PLC system’s program, collects status or data sent by field input devices through scanning, and stores them in designated registers. At the same time, it diagnoses the working status of the power supply and PLC internal circuits, as well as syntax errors during the programming process. During operation, it reads instructions from the user program memory one by one, analyzes them, and generates corresponding control signals according to the tasks specified by the instructions to command the relevant control circuits. Users do not need to analyze the internal circuits of the CPU in detail but should have a sufficient understanding of the working mechanisms of its parts. The CPU’s controller controls the CPU’s work, reading, interpreting, and executing instructions, with its working rhythm controlled by oscillation signals. The arithmetic unit performs digital or logical operations under the controller’s command. Registers participate in operations and store intermediate results of operations, also under the controller’s command. The CPU speed and memory capacity are crucial parameters for PLCs, determining the PLC’s working speed, the number of I/O points, and software capacity, thus limiting the scale of control.
I/O Modules
The interface between the PLC and electrical circuits is completed through the input-output (I/O) part. I/O modules integrate the I/O circuits of the PLC, with the input buffer reflecting the state of input signals and the output points reflecting the state of the output latch. The input module converts electrical signals into digital signals for the PLC system, while the output module does the opposite. I/O is divided into digital input (DI), digital output (DO), analog input (AI), and analog output (AO) modules. Common I/O classifications are as follows:
– Digital quantities: Classified by voltage levels, there are 220VAC, 110VAC, 24VDC; classified by isolation methods, there are relay isolation and transistor isolation.
– Analog quantities: Classified by signal types, there are current types (4-20mA, 0-20mA) and voltage types (0-10V, 0-5V, -10-10V), and classified by accuracy, there are 12bit, 14bit, 16bit.
In addition to the above general I/O, there are special I/O modules such as RTD, thermocouple, pulse modules, etc. The specification and number of modules are determined by the number of I/O points, which can be more or less, but the maximum number is limited by the basic configuration capability the CPU can manage, i.e., the maximum number of slots on the baseplate or rack.
Power Modules
PLC power supplies provide working power to the integrated circuits of the PLC modules. Some also provide 24V working power to the input circuits. Power input types include AC power (220VAC or 110VAC) and DC power (commonly 24VDC).
Baseplate or Rack
Most modular PLCs use baseplates or racks. Their role is to electrically connect the modules, allowing the CPU to access all modules on the baseplate, and mechanically connect the modules to form a unified whole.
Other Equipment in PLC Systems
Programming Equipment: Programmers are indispensable for PLC development, application, monitoring operation, and maintenance, used for programming, system settings, and monitoring the working status of PLCs and the systems they control, but they do not directly participate in field control operations. Small PLC programmers are generally handheld, but nowadays, computers (running programming software) usually act as programmers, also serving as our system’s upper computer.
Human-Machine Interface: The simplest human-machine interface is indicator lights and buttons. Currently, integrated operator terminals with LCD (or touch screens) are increasingly widely used, and computers (running configuration software) acting as human-machine interfaces are very common.
PLC Communication and Networking
Relying on advanced industrial network technology, production and management data can be quickly and effectively collected and transmitted. Therefore, the importance of networks in automation system integration projects is becoming increasingly significant, with some even proposing the viewpoint that “the network is the controller.” PLCs have communication and networking functions, allowing them to exchange information with other PLCs, upper computers, and other intelligent devices, forming a unified whole to achieve decentralized and centralized control. Most PLCs have RS-232 interfaces, and some have built-in interfaces supporting their respective communication protocols. Currently, PLC communication mainly uses multipoint interface (MPI) data communication, PROFIBUS, or industrial Ethernet for networking.
Basic Principles of PLC Control System Design
1. Maximize the control requirements of the controlled object.
2. On the premise of meeting control requirements, strive to make the control system simple, economical, and easy to use and maintain.
3. Ensure the safety and reliability of the control system.
4. Consider the development of production and improvement of processes, and appropriately leave some capacity when choosing PLC capacity.
PLC Software System and Common Programming Languages
PLC software systems consist of system programs and user programs. System programs include monitoring programs, compilation programs, diagnostic programs, etc., mainly used for overall management, translating program languages into machine languages, and diagnosing machine faults. System software is provided by PLC manufacturers and solidified in EPROM, which cannot be directly accessed or interfered with.
User programs are application programs compiled by users according to field control requirements using PLC programming languages (i.e., logic control) to achieve various controls. STEP7 is a standard software package used for configuring and programming SIMATIC programmable logic controllers, i.e., user programs. We use STEP7 for hardware configuration, logic program compilation, and online monitoring of logic program execution results.
Standard Languages: Ladder diagram language is the most commonly used language, characterized by:
– It is a graphical language that uses relay contacts, coils, series, and other terms and some graphical symbols from traditional control diagrams. The vertical lines on the left and right are called left and right bus bars.
– In the ladder diagram, contacts (points) are either normally open or normally closed, and contacts can be switches connected to PLC input points or PLC internal relay contacts, internal registers, counters, etc.
– Contacts in the ladder diagram can be connected in series or parallel, but coils can only be connected in parallel, not in series. Internal relays, counters, registers, etc., cannot directly control external loads and are used for intermediate results for internal CPU use.
– PLCs execute instructions in a cyclic scanning manner, executing in the order of the ladder diagram. The results of the same scan cycle remain in the output status buffer, so the values of output points can be used as conditions in the user program.