Abstract: To improve the efficiency and reliability of old-style bar rolling lines in steel rolling mills, a control system based on the PAC system platform is proposed. This system fully leverages the advantages of industrial PAC systems, such as high integration, low cost, and high reliability, and utilizes various measurable mechanical signals to achieve automatic control, online monitoring, and fault diagnosis of the rolling line. The hardware composition and software structure of the system are discussed in detail, and the composition of the monitoring and control module and the fault diagnosis module are introduced. Keywords: continuous rod rolling line; programmable logic controller (PLC); monitoring and control; fault diagnosis Abstract: To improve the efficiency and reliability of the continuous rod rolling line in a rolling mill, a control system based on a PAC platform is proposed. This system not only takes full advantage of industrial PAC but also uses various mechanical signals to realize the auto-control, online monitoring, and fault diagnosis of the rolling line. A detailed discussion of the system's hardware and software is then presented, especially its architectural aspects. Key words: continuous rod rolling line; PAC; monitor and control; fault diagnosis Introduction In recent years, many steel rolling mills' continuous rod rolling lines have become aging and structurally complex, easily affected by external factors such as track temperature and speed, making them difficult to control and frequently resulting in faults that impact production efficiency. Previously, technicians used a semi-structured approach to handle faults and problems. This involved collecting a large amount of data on-site, performing calculations and estimations, and relying on their accumulated experience and knowledge to answer the questions. This manual method is slow, and if the discovery and processing of relevant data are not timely, it can lead to system malfunctions and affect production. Given this, it is necessary to create a unified control system to monitor and process data online, provide optimal control of the binding line, and promptly provide fault causes and operational guidance, thereby enabling the system to return to normal as quickly as possible and ensuring smooth production. 1. Hardware Structure: The control system has two main tasks: first, to perform online monitoring and control, including acquiring sensor output signals and preprocessing sensor data. Based on these signals, the system issues corresponding control commands to control the operation of the entire binding line and monitors the operation of each part of the binding line, providing early warning information at any time; second, to perform fault diagnosis. This control system is structurally divided into two parts: a data acquisition unit and a central processing unit. The data acquisition unit is responsible for data acquisition and signal processing, then sends these signals to the central processing unit; the central processing unit is responsible for data analysis and diagnosis, realizing monitoring, control, and fault diagnosis functions, and transmitting the data to a server in a remote data center via Ethernet. The system hardware structure diagram is shown in Figure 1. [align=center]Figure 1: System Hardware Structure Diagram[/align] 1.1 Data Acquisition Unit The data acquisition unit is directly installed and fixed on the main parts of the engineering machinery to complete sensor calibration and adjustment, acquisition of working parameters, and feature extraction of signals. The data acquisition unit mainly consists of sensors, signal conditioning, and AD conversion. The primary task in developing a control system is to select appropriate working parameters. Appropriate means that the measured signals can quickly and accurately reflect changes in the system's working state and can reflect a variety of characteristic information of the engineering machinery's operating state. Selecting appropriate measurement parameters is very important. This system takes the bar binding line as the controlled object and selects parameters such as the speed and action time of the brake plate, separation plate, and cooling bed motor, the binding line track speed, temperature, and binding diameter as detection signals. Through automatic monitoring and analysis of these parameters, the system performs monitoring control and fault diagnosis of the binding line. 1.2 The initial design of the central processing unit considered a traditional PLC + industrial computer approach. The PLC would handle signal acquisition, logic processing, and output control, while the industrial computer would implement algorithms and handle human-machine interaction. This approach faced two main challenges: stability, as the general-purpose operating system of a PC typically cannot provide sufficient stability for control; and reliability, as PCs contain rotating magnetic hard drives and non-industrially robust components such as power supplies, making them more prone to failure. Considering the harsh environment and limited console space, a PAC (Programmable Automation Controller) approach was chosen as the development environment. Since its inception, the PAC has become one of the most important development trends in the automation industry in recent years, attracting widespread attention from the automation industry and end-users. As a new generation of industrial controllers, the Programmable Automation Controller (PAC) combines the advantages of a PC's processor, RAM, and software with the inherent reliability, robustness, and distributed nature of a PLC. As a multifunctional control platform, users can combine and match relevant technologies and products to achieve specific functionalities according to system needs. Because it is developed based on the same development platform, the PAC system ensures the unity of all functional modules of the control system, rather than being a collection of completely unrelated parts. The central processing unit of this system uses the BECKHOFF CX1000 PAC. The BECKHOFF CX1000 control system is designed for medium-scale control tasks. It combines the best features of an industrial PC and a hardware PLC, and is a modular control system that can be installed on a C-rail. Various system components can be plugged in and out according to user needs to complete various complex control tasks. This product series is designed for customers who need the features and computing power of an industrial PC but do not intend to purchase a complete industrial PC due to budget constraints. The CX1000 series system modules are connected via a standard PC104 bus (16-bit). Its basic unit includes a CPU module and a power supply module, and the system can use either the Windows CE.NET operating system or an embedded Windows XP operating system. Ideal visualization and real-time continuous control can be provided in this single system. 2. System Software Structure The operating platform for the software system is Microsoft Windows CE, and the development tool is Embedded VC++ 4.0. The software adopts a modular design, mainly including a monitoring database, a monitoring and control module, and a fault diagnosis module. The overall structure of the software system is shown in Figure 2. The monitoring database is mainly used to store the operating condition data parameters of each signal acquisition unit. Through the database management interface, functions such as selection, import, and export of detection data can be realized. The monitoring and control module judges the production status based on the monitoring data and issues appropriate control commands to each part of the binding wire. The fault diagnosis module performs fault diagnosis based on the detection data and user manual input, and provides diagnostic conclusions, operation, and maintenance measures. The system software structure is shown in Figure 2. [align=center] Figure 2: System Software Structure Diagram[/align] 2.1 Monitoring and Control Module The monitoring and control module performs online monitoring of the data entering the CX1000 system, provides early warning information for the operation of each device at any time, and performs control calculations based on this data to obtain control commands for automatic control of the entire binding wire. This module is mainly divided into three parts: motor time detection part; multiple length steel online detection part; and multiple length optimized shearing guidance part. The motor time detection section measures the time it takes for the motor to fall from a high position to a low position using a motor action time measuring device. Based on this time data, a weighted average filtering algorithm with self-learning function is used to predict the precise time of the next motor action, using median filtering as a foundation. This algorithm stipulates that each data point in the data sequence contains certain information; the newest data contains more effective information, while older data contains less. Therefore, when predicting the next motor action time, the newest set of data is used in the calculation, and different data points are assigned different weights. For ease of algorithm design, an equal-dimensional information method is used, i.e., keeping the number of data points involved in the calculation constant, adding newly collected data each time, and removing the oldest data. The algorithm formula is described as: ; where is the predicted value, and represents the first 2k measurement times involved in the calculation. The online detection section for multiple-length steel uses an encoder and a high-precision counter, combined with the closing signal of the flying shear blade, to calculate the online length of the multiple-length steel. The length optimization shearing guidance section uses matrix transformation of indeterminate equations to find the most suitable shearing scheme based on the length data of the bundled parts collected on site. This scheme is then sent to the flying shear controller to guide the flying shear to perform optimal shearing, thereby improving production efficiency. 2.2 Fault Diagnosis Module The core of the fault diagnosis module is the fault diagnosis expert system. This system involves the computer collecting information about the object being diagnosed, comprehensively applying various rules (expert experience), and performing a series of inferences. It can also call various applications at any time, requesting necessary information from the user during operation to quickly find the final or most likely fault, which is then verified by the user. The fault diagnosis method of the expert system consists of a database, knowledge base, human-computer interface, and inference engine. The composition of the knowledge base and inference engine is discussed in detail here. 2.2.1 Construction of the Knowledge Base The knowledge representation method used in this system is production rules. The system adopts the general form of production rules: IF A THEN B CF(B,A), i.e., A→B, CF(B,A). Here, A is the premise, condition, or evidence of the rule. A can be a condition in the form of a single proposition, or a condition generated by logically combining simple propositions. A may support more than one rule; for example, A= is a composite condition, and B is evidence that A leads to the conclusion. In reasoning, the imprecision of each condition brings certain difficulties to diagnosis. To solve this problem, a degree of occurrence, or credibility, is assigned to each premise, i.e., a CF value. For example, a premise with strong credibility has a corresponding CF value of 1.00; one with moderate credibility has a corresponding CF value of 0.5. CF(B,A) represents the strength or credibility of the rule, indicating the degree of uncertainty of the rule, usually given by experts, 0≤CF(B,A)<1. In addition to describing all rules in the above form, the system also specifies credibility for all knowledge, including A and B, i.e., premises and conclusions. The credibility of premise A is denoted as CF(A), representing the credibility value of condition A under the problem-solving state, where 0 represents the credibility. In this system, fault diagnosis generally involves inferring a fault cause from several fault phenomena. In reality, the "importance" of each sub-premise within the premise of a reasoning rule varies. The importance of a premise refers to the importance of each fact within the condition, i.e., the weighted coefficient of each fact, Ki. For example, in the rule "If the sky is overcast and windy, it will likely rain for most of the day," clearly, "overcast" is the most important, while "windy" is less important. Therefore, in this system, each condition has different levels of importance when making judgments. When assigning weights to the conditions of each rule, we can assign values based on practical experience, ensuring that ∑Ki = 1. Besides estimating weights based on experience, we can also categorize them according to their importance: most important, very important, generally important, and optional, corresponding to 1, 2, 3, and 4 respectively. For example: IF A1 (most important = 4) A2 (generally important = 2) A3 (optional = 1) THEN B1 The weight of A1 is 4/(4+2+1) = 0.57; the weight of A2 is 2/(4+2+1) = 0.29; the weight of A3 is 1/(4+2+1) = 0.14. The sum of the three weights equals 1. 2.2.2 Construction of the Inference Engine The most important aspect of building an inference engine is establishing its control strategy and inference algorithm. The inference strategy used in this system is a combination of forward inference control strategy and conflict resolution strategy. Based on the fault phenomenon set input by the user or the field data monitored by sensors, premise matching is performed in the knowledge base. Knowledge is selected through the conflict resolution strategy. The conflict resolution strategy here is a rule summarized from years of experience by wire-connecting control technicians. Rule matching is performed in this order. If the matching is successful, the fault corresponding to the fault phenomenon set is obtained, and thus its solution is obtained. There are four inference algorithms for imprecise reasoning: the deterministic theory method, the subjective Bayes method, the probability theory method, and the evidence theory method. This system adopts the deterministic theory method. The deterministic theory method calculates the credibility of the conclusion based on the credibility of the premises, their weights, and the credibility of the rules. The knowledge representation considering weights is: IFTHEN B CF(B,A). In the above formula, the values of the weighting factors are given by domain experts, and the credibility of the combined conditions is calculated by the formula: CF(A) = ∑Ki × CF(Ai); The credibility of the conclusion is calculated by the following formula: CF(B) = CF(B,A) & CF(A); where & can be a multiplication operation, a minimum value operation, or other suitable operations. For example: IF A1 weight k1 A2 weight k2 A3 weight k3 THEN B Then CF(B) = MIN[CF(B,A), CF(A1) ×K1 + CF(A2) ×K2 + CF(A3) ×K3)] Based on the reliability of the predicted conclusions, early warning information and fault causes can be given. 3. Operation Status Through extensive research, we determined the hardware and software support platform and conducted experimental research on the feasibility of this solution in the field of actual excavator fault diagnosis. It was put into operation in a steel rolling mill in Guizhou in March 2006. The operation results show that the control system operates well, has stable performance, correct conclusions, and fast response time, providing great convenience for technicians. 4 Conclusion The control system proposed in this paper is designed for the old bar rolling line of the steel rolling mill. This system adopts the PAC system as the operating platform, which can meet the high processing capacity and high data capacity required for online monitoring, automatic control and diagnosis, and is suitable for the special working environment of the steel rolling mill. According to the characteristics of the fault of the old bar rolling line, an expert system diagnosis scheme is proposed, which plays a good role in improving the old bar rolling line, so that it can play the maximum role and improve production efficiency. References [1] Wang Dongmei et al., Design of expert system for railway locomotive fault diagnosis, Microcomputer Information, Vol. 22, No. 10-1, 2006 [2] Guo Dian, Chen Qiangen et al., Online status monitoring and fault diagnosis of engineering machinery based on embedded system, Engineering Machinery, No. 1, 2006 [3] Ye Han, Research on expert system for bag dust collector in coal-fired power plant, Wuhan Safety and Environmental Protection Research Institute, Master of Engineering Thesis, Class of 2003