PLC controller function module data processing method and system
By classifying and adapting the control task information and functional module information of the PLC controller, establishing a data processing chain, and performing outlier processing, the problems of inefficiency and poor stability in the existing technology are solved, and efficient Improved data processing and system stability.
Patent Information
- Application Number
- CN202411063469.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-05
- Publication Date
- 2024-11-19
- Estimated Expiration
- 2044-08-05
AI Technical Summary
In the existing PLC control system, the lack of clear classification and management of control task information and functional module information, resulting in low efficiency of control task allocation and functional module call, high error rate, lack of unified standards for data processing order and outlier processing, which reduces the System reliability and stability.
By classifying the control task information and functional module information of the PLC controller, calculating the control adaptability of the control task group and functional module group, establishing a data processing chain, performing data processing sequence annotation, and calculating data processing outliers to perform annotation. and reprocess judgment to ensure that each control task is processed by the most suitable functional module, improving resource utilization efficiency and system stability.
It realizes intelligent classification and correlation between control tasks and functional modules, improves data processing efficiency, reduces waiting time and data transmission delay, enhances the stability and reliability of the system, provides more accurate decision support information, and improves the system. level of intelligence.
Smart Images

Figure CN118981182A_ABST
Abstract
Description
Technical Field
[0001] The invention proposes a PLC controller function module data processing method and system, and relates to the technical field of function module data processing. Background Art
[0002] With the rapid development of industrial automation and intelligence, programmable logic controllers (PLCs) play an increasingly important role in industrial automation control systems. PLC controllers receive control task information, control various functional module groups to process data, and realize automated control of industrial automation production. However, in practical applications, how to efficiently process and control a large amount of control task information, and how to effectively associate control tasks with functional module groups, are still important issues facing PLC control systems. In existing PLC control systems, control task information and functional module information are usually not clearly classified and managed, making it difficult to perform real-time data processing, resulting in low efficiency and high error rates in control task allocation and functional module calls. In addition, there is a lack of unified standards and effective means for the data processing order of functional module groups and the processing of data processing abnormalities, which further reduces the reliability and stability of the system. Summary of the invention
[0003] The present invention provides a method and system for processing data of a PLC controller function module, which is used to solve the problem that in the existing PLC control system, the control task information and the function module information are usually not clearly classified and managed, resulting in low efficiency and high error rate in the control task allocation and function module call. In addition, there is a lack of unified standards and effective means for the data processing sequence of the function module group and the processing of data processing abnormal values, which further reduces the reliability and stability of the system.
[0004] The present invention proposes a method and system for processing data of a PLC controller function module, the method comprising:
[0005] Classifying the control task information and the function module information of the PLC controller, calculating the control fitness of the control task group and the function module group obtained by the classification, and associating the control task group and the function module group according to the control fitness to obtain a control association group;
[0006] A data processing chain of a functional module group is established according to the control task information, and a serial number of a data processing sequence is marked on the functional module group. The functional module group processes data according to the associated control task information, obtains processing data of each functional module, and then obtains final processing data, which is sent to the central processing unit;
[0007] Calculate the data processing anomaly value of each functional module, compare the data processing anomaly value with the preset anomaly threshold, annotate the data processing of the functional module according to the comparison result, obtain the data processing annotation information, and then determine whether to reprocess the data.
[0008] Furthermore, the classification of the control task information and the function module information of the PLC controller includes:
[0009] Acquire control task information of a PLC controller, preprocess the control task information to obtain the preprocessed control task information, classify the control task information according to the control task type, and obtain a plurality of control task groups;
[0010] A plurality of function modules of a PLC controller are obtained, and the plurality of function modules are classified according to function types to obtain a plurality of types of function module groups.
[0011] Furthermore, the calculation of the control adaptability of the control task group and the function module group obtained by classification includes:
[0012] Calculate the control adaptability of the control task group and the function module group according to the control task information of the multiple control task groups and the function information of the function module group;
[0013] The calculation formula of the control adaptability is:
[0014]
[0015] Among them, SP is the control matching degree, Y c is the average required output data of the control task group, Y r The average required input data for the control task group, S c is the average actual output data of the functional module group, S r It is the average actual input data of the function module group.
[0016] Furthermore, associating the control task group and the function module group according to the control adaptability to obtain a control association group includes:
[0017] Obtaining a preset fitness threshold, comparing the control fitness with the preset fitness threshold, and when the control fitness is greater than the preset fitness threshold, associating the corresponding control task group and the functional module group to obtain a corresponding control association group;
[0018] When the control adaptability is less than or equal to a preset adaptability threshold, the corresponding control task group and function module group are not associated.
[0019] Furthermore, the data processing chain of the functional module group is established according to the control task information, and the functional module group is marked with serial numbers of the data processing sequence, including:
[0020] According to the control task information corresponding to the multiple function module groups in the control association group, the multiple function module groups are connected in control order to obtain a data processing chain;
[0021] Each functional module group of the data processing chain is labeled with a serial number of the data processing sequence to obtain functional module labeling information. Further, the functional module group processes data according to the associated control task information to obtain processing data of each functional module, and then obtains final processing data and sends it to the central processing unit, including:
[0022] Assuming that there are n function module groups in total, the nth function module group performs data processing of corresponding functions according to the control task information of the control task group associated with it, and obtains the processed data of the nth function module group;
[0023] Sending the processed data of the nth functional module group to the n-1th functional module group;
[0024] Obtain the processing data of all functional modules in the order of the data processing chain and send it to the central processing unit.
[0025] Furthermore, the processing data of all functional modules are acquired in sequence according to the data processing chain, and sent to the central processing unit, including:
[0026] The n-1th function module group performs data processing of the corresponding function according to the control task information of the control task group associated with it, and obtains the processed data of the n-1th function module group, until all function module groups complete data processing, and obtain the processed data of all function modules. The processed data of the last function module that performs data processing is the final processed data, and the processed data of all function modules and the final processed data are sent to the central processing unit.
[0027] Furthermore, the data processing anomaly value of each functional module is calculated, the data processing anomaly value is compared with a preset anomaly threshold, and data processing annotation is performed on the functional module according to the comparison result to obtain data processing annotation information, including:
[0028] The central processing unit calculates the data processing abnormal value of each functional module according to the acquired processing data of each functional module;
[0029] Compare the data processing abnormal value with a preset abnormal threshold value to obtain a comparison result;
[0030] The calculation formula of the data processing outlier value is:
[0031]
[0032] Among them, CY is the data processing outlier, L is the total number of data processing types, SC i is the actual output data of the functional module for the i-th data processing, YC i Preset output data for the function module of the i-th data processing, SR i is the actual input data of the functional module for the i-th data processing, YR i Preset input data for the i-th data processing function module;
[0033] When the data processing abnormal value is greater than the preset abnormal threshold, the function module corresponding to the data processing abnormal value is marked for abnormal processing;
[0034] When the data processing abnormal value is less than or equal to the preset abnormal threshold, the function module corresponding to the data processing abnormal value is marked for normal processing, and the abnormal processing mark and the normal processing mark are the data processing mark information.
[0035] Furthermore, obtaining the data processing annotation information and then determining whether to perform data reprocessing includes:
[0036] When the data processing mark information indicates normal processing, the central processing unit processes the final processing data according to a preset procedure;
[0037] When the data processing marking information is abnormal processing, the central processing unit generates a control instruction to control the data processing chain to reprocess the data.
[0038] Furthermore, the system comprises:
[0039] A control function association module is used to classify the control task information and function module information of the PLC controller, calculate the control fitness of the control task group and the function module group obtained by the classification, and associate the control task group and the function module group according to the control fitness to obtain a control association group;
[0040] The functional data processing module is used to establish a data processing chain of the functional module group according to the control task information, mark the sequence of data processing for the functional module group, and the functional module group performs data processing according to the associated control task information to obtain the processing data of each functional module, and then obtain the final processing data and send it to the central processing unit;
[0041] The abnormal labeling judgment module is used to calculate the data processing abnormal value of each functional module, compare the data processing abnormal value with the preset abnormal threshold, label the data processing of the functional module according to the comparison result, obtain the data processing labeling information, and then determine whether to reprocess the data.
[0042] Beneficial effects of the present invention: Through the intelligent classification and association of control tasks and functional modules, the system can ensure that each control task is processed by the most suitable functional module, thereby improving the efficiency of resource utilization. The establishment and execution of the data processing chain can ensure the efficient transmission and processing of data between functional modules, reduce unnecessary waiting time and data transmission delays, and improve overall processing efficiency. Through the anomaly detection and processing mechanism, the system can promptly detect and handle abnormal situations in the data processing process, avoid problems such as data errors or system crashes, and enhance the stability and reliability of the system. The final processed data can provide important decision support information for the central processing unit, help the system make more accurate decisions and control actions, and improve the intelligence level of the system. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] Figure 1 The present invention is a schematic diagram of a method for processing data of a functional module of a PLC controller. DETAILED DESCRIPTION
[0044] The preferred embodiments of the present invention are described below in conjunction with the accompanying drawings. It should be understood that the preferred embodiments described herein are only used to illustrate and explain the present invention, and are not used to limit the present invention.
[0045] In one embodiment of the present invention, a method and system for processing data of a PLC controller function module is provided, and the method comprises:
[0046] S1, classifying the control task information and the function module information of the PLC controller, calculating the control fitness of the control task group and the function module group obtained by the classification, and associating the control task group and the function module group according to the control fitness to obtain a control association group;
[0047] S2. Establish a data processing chain of the function module group according to the control task information, mark the function module group with the serial number of the data processing sequence, and the function module group processes the data according to the associated control task information to obtain the processing data of each function module, and then obtain the final processing data and send it to the central processing unit;
[0048] S3. Calculate the data processing anomaly value of each functional module, compare the data processing anomaly value with the preset anomaly threshold, and mark the data processing of the functional module according to the comparison result to obtain data processing marking information, and then determine whether to reprocess the data.
[0049] The working principle of the above technical solution is as follows: the system first classifies the control task information and function module information of the PLC controller. The classification is based on factors such as the task control type and the function type of the function module. The control adaptability of the control task group and the function module group obtained by classification is calculated. According to the control adaptability, the system associates the control task group with the function module group to form a control association group. The purpose of association is to ensure that each control task can be processed by the most suitable function module. According to the control task information, the system establishes a data processing chain of the function module group for each control association group. The data processing chain defines the data processing sequence between the function modules. The system assigns a sequence number to each function module to identify its position in the data processing chain. The function module group processes the data according to the associated control task information and the predetermined data processing sequence. After each function module processes the data, it passes the result to the next module until the final processed data is obtained. The final processed data is sent to the central processing unit. The system calculates the abnormal value of each function module during the data processing process. The calculated data processing abnormal value is compared with the preset abnormal threshold. If the abnormal value exceeds the threshold, it is considered that the data processing is abnormal. Based on the comparison results, the system annotates the function modules for data processing and generates data processing annotation information. The system determines whether the data needs to be reprocessed based on the annotation information. If reprocessing is required, the system may reselect the function modules, adjust the processing order, or take other measures to ensure the accuracy and reliability of data processing.
[0050] The technical effect of the above technical solution is: through the intelligent classification and association of control tasks and functional modules, the system can ensure that each control task is processed by the most suitable functional module, thereby improving the utilization efficiency of resources. The establishment and execution of the data processing chain can ensure the efficient transmission and processing of data between functional modules, reduce unnecessary waiting time and data transmission delays, and improve the overall processing efficiency. Through the anomaly detection and processing mechanism, the system can promptly detect and handle abnormal situations in the data processing process, avoid problems such as data errors or system crashes, and enhance the stability and reliability of the system. The final processed data can provide important decision support information for the central processing unit, help the system make more accurate decisions and control actions, and improve the intelligence level of the system.
[0051] In one embodiment of the present invention, the classifying of the control task information and the function module information of the PLC controller includes:
[0052] Acquire control task information of a PLC controller, preprocess the control task information to obtain the preprocessed control task information, classify the control task information according to the control task type, and obtain a plurality of control task groups;
[0053] A plurality of function modules of a PLC controller are obtained, and the plurality of function modules are classified according to function types to obtain a plurality of types of function module groups.
[0054] The working principle of the above technical solution is: obtain the control task information of the PLC controller, pre-process the control task information, obtain the pre-processed control task information, classify the control task information according to the type of control task, and obtain multiple control task groups; the control task includes control data acquisition, control data communication, control data storage and control data pre-processing, data processing according to preset logical rules, etc.
[0055] Acquire multiple functional modules of the PLC controller, classify the multiple functional modules according to functional types, and obtain multiple types of functional module groups. The functional modules include data acquisition functional modules, data and processing functional modules, data communication functional modules, data logic operation functional modules, etc., which are used to realize corresponding data processing functions.
[0056] The technical effect of the above technical solution is: by preprocessing and classifying the control task information, different types of control tasks, such as data acquisition, data communication, data storage, etc., can be clearly identified. This helps the system to process these tasks more efficiently and avoids processing delays or resource waste caused by mixed tasks. Classifying the functional modules of the PLC controller according to the functional type can ensure that each functional module is assigned to the task that best suits it. This helps to optimize the configuration of system resources, improve resource utilization, and reduce unnecessary resource waste. Classifying and managing the control task information and functional modules can make the structure of the system clearer and easier for maintenance personnel to understand and operate. When the system fails or needs to be upgraded, maintenance personnel can quickly locate the problem and take corresponding solutions to reduce the impact of the failure on the normal operation of the system. By classifying the functional modules according to the functional type, functional modules can be easily added, deleted or modified to meet different control task requirements. This enhances the flexibility of the system and enables it to cope with various complex and changeable control scenarios. Unified management and classification of control task information and functional modules helps to achieve data standardization. Standardized data formats and interfaces can improve the efficiency and accuracy of data exchange and reduce the risk of data errors. By classifying and managing control task information and functional modules, data access and transmission permissions can be controlled more accurately. This helps prevent unauthorized access and data leakage, and improves system security.
[0057] In one embodiment of the present invention, the calculating of the control adaptability of the control task group and the function module group obtained by classification includes:
[0058] Calculate the control adaptability of the control task group and the function module group according to the control task information of the multiple control task groups and the function information of the function module group;
[0059] The calculation formula of the control adaptability is:
[0060]
[0061] Among them, SP is the control matching degree, Y c is the average required output data of the control task group, Y r The average required input data for the control task group, S c is the average actual output data of the functional module group, S r It is the average actual input data of the function module group.
[0062] The working principle of the above technical solution is as follows: according to the steps mentioned above, the control tasks of the PLC controller are divided into multiple control task groups, and the functional modules are also divided into multiple functional module groups. Each control task group contains one or several similar control tasks, and each functional module group contains modules that can perform specific functions. In order to determine which functional module groups are most suitable for executing which control task groups, it is necessary to calculate the control fitness between them. This usually involves comparing and evaluating the requirements of the task group with the capabilities of the functional module group. The higher the fitness value, the more suitable the functional module group is for executing the control task group. Based on these fitness values, the system can decide how to allocate functional modules to perform control tasks.
[0063] The technical effect of the above technical solution is: by calculating the control adaptability, the system can more accurately determine which functional modules are most suitable for performing which control tasks. This helps to optimize resource allocation and ensure that each functional module is used to perform the task it is best at. Functional module groups with high adaptability can perform corresponding control tasks more effectively, thereby reducing resource waste and task execution time. This helps to improve the efficiency of the entire PLC control system. By matching the most suitable functional modules to perform control tasks, the risk of system failure due to insufficient resources or module mismatch can be reduced. This helps to improve the reliability and stability of the system. Through a clear adaptability calculation and allocation process, system design and maintenance become simpler and more intuitive. Maintenance personnel can more easily understand the structure and function of the system and quickly locate and solve potential problems.
[0064] In one embodiment of the present invention, associating the control task group and the function module group according to the control adaptability to obtain the control association group includes:
[0065] Obtaining a preset fitness threshold, comparing the control fitness with the preset fitness threshold, and when the control fitness is greater than the preset fitness threshold, associating the corresponding control task group and the functional module group to obtain a corresponding control association group;
[0066] When the control adaptability is less than or equal to a preset adaptability threshold, the corresponding control task group and function module group are not associated.
[0067] The working principle of the above technical solution is as follows: the system will obtain a fitness threshold from the preset parameters or configurations, and this threshold is usually set according to the actual needs, performance and stability requirements of the system. The system will compare the control fitness calculated previously with the preset fitness threshold. The control fitness is calculated by evaluating the degree of match between the needs of the control task group and the capabilities of the function module group. If the control fitness of a control task group and a function module group is greater than the preset fitness threshold, the system will consider that the function module group can well meet the needs of the control task group, so they will be associated to form a control association group. This association group represents a matching relationship between a task and a resource, that is, the function module group will be used to execute the control task group. On the contrary, if the control fitness of a control task group and a function module group is less than or equal to the preset fitness threshold, the system will consider that the function module group cannot meet the needs of the control task group, or the degree of satisfaction is not high enough. In this case, the system will not associate them, but will continue to look for other more suitable function module groups, or consider optimizing the demand description of the control task group to improve the fitness.
[0068] The technical effect of the above technical solution is: by matching tasks and resources according to the degree of adaptability, it is possible to ensure that system resources are used more reasonably. An association group with high adaptability means that resources are used efficiently, while tasks with low adaptability will not be allocated resources, thereby avoiding waste of resources. An association group with high adaptability means that the degree of match between tasks and resources is high, which can complete tasks faster and improve the execution efficiency of the system. At the same time, it avoids delays or failures in task execution due to resource mismatch. By reasonably matching tasks with resources, the risk of failure of the system due to insufficient resources or task overload can be reduced. This helps to enhance the stability and reliability of the system. This method allows the system to dynamically adjust the matching relationship between tasks and resources according to actual needs. When system requirements change, the new requirements can be adapted by adjusting the adaptability threshold or optimizing the task requirement description to maintain the flexibility and scalability of the system. By managing tasks and resources in association, the management and maintenance of the system can be simplified.
[0069] In one embodiment of the present invention, the step of establishing a data processing chain of a functional module group according to the control task information and marking the sequence of data processing of the functional module group includes:
[0070] According to the control task information corresponding to the multiple function module groups in the control association group, the multiple function module groups are connected in control order to obtain a data processing chain;
[0071] Each functional module group of the data processing chain is labeled with a serial number of the data processing sequence to obtain functional module labeling information.
[0072] The working principle of the above technical solution is as follows: the system determines the control task information corresponding to each functional module group according to the control association group formed in the previous steps. These control task information describe the specific tasks and data processing requirements that the functional module group needs to perform. The system determines the execution order between the functional module groups according to the dependencies and logical order between the control tasks. This order is based on the logical flow of the task and the requirements of the data flow. According to the determined execution order, the system connects the functional module groups to form a complete data processing chain. This chain represents the entire processing flow from data input to output. In the data processing chain, the system assigns a unique serial number to each functional module group to indicate its position and order in the data processing flow. This serial number is usually based on the actual position of the functional module group in the chain. The system associates the serial number with the information of the functional module group to generate the functional module annotation information. This annotation information contains key information such as the unique identification, serial number, and data type processed of the functional module group.
[0073] The technical effect of the above technical solution is: by forming a data processing chain and generating function module annotation information, the system can clearly display the relationship and order between each function module group in the data processing process. By optimizing the connection order and data processing process between function module groups, the system can process data more efficiently. This helps to reduce data processing delays and errors and improve the overall performance of the system. Function module annotation information facilitates the maintenance and management of the system. A specific function module group can be quickly located and its related processing order and data type can be viewed. This helps to simplify the maintenance process and improve management efficiency. When the system needs to add new function modules or modify existing functions, it can adapt to new requirements by adjusting the data processing chain and updating the function module annotation information. This flexibility enables the system to cope with changing business needs and technical environments. Through annotation information, the system can realize real-time monitoring and tracking of the data processing process. Administrators can view the status and processing progress of each function module group in real time, and promptly discover and solve problems. This helps to improve the stability and reliability of the system.
[0074] In one embodiment of the present invention, the functional module group performs data processing according to the associated control task information to obtain the processed data of each functional module, and then obtains the final processed data and sends it to the central processing unit, including:
[0075] Assuming that there are n function module groups in total, the nth function module group performs data processing of corresponding functions according to the control task information of the control task group associated with it, and obtains the processed data of the nth function module group;
[0076] Sending the processed data of the nth functional module group to the n-1th functional module group;
[0077] Obtain the processing data of all functional modules in the order of the data processing chain and send it to the central processing unit.
[0078] The working principle of the above technical solution is as follows: according to the control task information, the nth function module group (here n is the number of function module groups, and it is assumed that they have been numbered in the processing order) starts to process the data of the corresponding function. This processing includes data acquisition, conversion, storage, communication or logical operation, etc. After completing the data processing of the corresponding function, the nth function module group generates processed data. These data may be intermediate results, status information or raw data that need further processing. The processed data of the nth function module group is sent to the previous function module group in the data processing chain, that is, the n-1th function module group. This ensures that the data is transmitted between the function module groups in the correct order and logic. After receiving the data, each function module group performs corresponding data processing according to its own function and control task information, and continues to send the processed data to the previous function module group in the data processing chain until the data reaches the first function module group. After completing its data processing, the first function module group sends the final processed data to the central processing unit (CPU). The CPU is responsible for the control and data processing of the entire system. It receives the final processed data of all function module groups and performs further processing or decision-making as needed.
[0079] The technical effect of the above technical solution is: by performing data processing and data transmission in the order of the data processing chain, the orderliness and correctness of the data are ensured. Each functional module group processes data at its appropriate location and time, thereby improving the accuracy and efficiency of data processing. The modular design allows parallel processing and pipeline operation, reducing the total time of data processing. At the same time, since each functional module group only processes its specific task, its internal algorithm and hardware design can be optimized to further improve the processing efficiency. By associating the functional module group with the control task group, the system can flexibly adjust the data processing flow to adapt to different control task requirements. In addition, when it is necessary to add new functions or modify existing functions, only the relevant functional module group can be modified without redesigning the entire system. The modular design makes system maintenance simpler and more intuitive. The administrator can test and debug each functional module group separately, making it easier to locate and solve potential problems. In addition, since the interfaces between the functional module groups are standardized, the functional module groups can be easily replaced or upgraded. By allocating data processing tasks to multiple functional module groups, the system can process multiple tasks in parallel, thereby improving the throughput and reliability of the system. In addition, since each functional module group is independent, the failure of one functional module group will not affect the operation of the entire system.
[0080] In one embodiment of the present invention, the step of acquiring the processing data of all functional modules in a data processing chain sequence and sending the data to the central processing unit includes:
[0081] The n-1th function module group performs data processing of the corresponding function according to the control task information of the control task group associated with it, and obtains the processed data of the n-1th function module group, until all function module groups complete data processing, and obtain the processed data of all function modules. The processed data of the last function module that performs data processing is the final processed data, and the processed data of all function modules and the final processed data are sent to the central processing unit.
[0082] The working principle of the above technical solution is as follows: when the system receives the instruction of the control task group, the nth functional module group in the data processing chain starts to process the data of the corresponding function according to its associated control task information. After the nth functional module group completes the processing, it passes the processed data to the next functional module group, that is, the n-1th functional module group. After the n-1th functional module group receives the data, it processes the data according to its own control task information and continues to pass the processed data downward. This process continues until the first functional module group completes its data processing task. The data generated by the last functional module group that performs data processing (that is, the first functional module group) is regarded as the final processed data of the entire data processing flow. The system summarizes the processed data of each functional module group and the final processed data, and sends these data to the central processing unit (CPU).
[0083] The technical effect of the above technical solution is: the system processes data in accordance with the preset data processing chain sequence, ensuring that data flows in an orderly manner between functional module groups, avoiding data confusion and errors. Each functional module group focuses on performing its specific tasks, making data processing more efficient. At the same time, since the data processing process is serial, the integrity of the data at each stage can be ensured. By assigning data processing tasks to multiple functional module groups, the system can process multiple tasks in parallel, improving the overall throughput and reliability. In addition, since each functional module group is independent, the failure of one functional module group will not immediately affect the operation of the entire system. Since the system saves the processing data of each functional module group, data traceability and auditing can be easily performed. This is very helpful for troubleshooting, system optimization and compliance checking. Modular design makes system maintenance easier. Administrators can test, debug and upgrade each functional module group separately without making changes to the entire system. In addition, since the interfaces between functional module groups are standardized, new functional module groups can be easily replaced or added. The system can adjust the association and control task information between functional module groups as needed to adapt to different application scenarios and demand changes. This flexibility makes the system highly configurable and scalable.
[0084] In one embodiment of the present invention, the data processing anomaly value of each functional module is calculated, the data processing anomaly value is compared with a preset anomaly threshold, and data processing annotation information is obtained for the functional module according to the comparison result, including:
[0085] The central processing unit calculates the data processing abnormal value of each functional module according to the acquired processing data of each functional module;
[0086] Compare the data processing abnormal value with a preset abnormal threshold value to obtain a comparison result;
[0087] The calculation formula of the data processing outlier value is:
[0088]
[0089] Among them, CY is the data processing outlier, L is the total number of data processing types, SC i is the actual output data of the functional module for the i-th data processing, YC i Preset output data for the function module of the i-th data processing, SR i is the actual input data of the functional module for the i-th data processing, YR i Preset input data for the i-th data processing function module;
[0090] When the data processing abnormal value is greater than the preset abnormal threshold, the function module corresponding to the data processing abnormal value is marked for abnormal processing;
[0091] When the data processing abnormal value is less than or equal to the preset abnormal threshold, the function module corresponding to the data processing abnormal value is marked for normal processing, and the abnormal processing mark and the normal processing mark are the data processing mark information.
[0092] The working principle of the above technical solution is as follows: after receiving the processing data of all functional module groups, the central processing unit (CPU) will analyze and calculate the processing data of each functional module according to the data processing abnormal value calculation formula to obtain the data processing abnormal value of each functional module. The calculated data processing abnormal value will be compared with the preset abnormal threshold. This abnormal threshold is set according to system requirements and historical data, and is used to determine whether the data processing of the functional module is abnormal. If the data processing abnormal value of a functional module is greater than the preset abnormal threshold, the system will mark the functional module as an abnormal processing state and generate a corresponding abnormal processing annotation. If the data processing abnormal value is less than or equal to the preset abnormal threshold, the system will mark the functional module as a normal processing state and generate a normal processing annotation.
[0093] The technical effect of the above technical solution is: by calculating the data processing anomaly value of the functional module and comparing it with the abnormal threshold, the system can monitor the operating status of the functional module in real time, and promptly discover and warn of potential abnormal situations. This helps administrators or maintenance personnel to respond quickly and avoid the expansion of problems. Through abnormal processing annotations, the system can accurately locate the functional module where the problem occurs, reducing the time and cost of troubleshooting. By promptly discovering and handling abnormal situations in functional modules, the system can ensure the continuity and stability of services and reduce the impact of system failures or service interruptions on user experience. Data processing anomaly values and annotation information can serve as an important basis for system performance evaluation, fault analysis, and optimization decisions. By collecting and analyzing these data, administrators can formulate system maintenance and improvement strategies more scientifically and improve the overall operation and maintenance level of the system.
[0094] In one embodiment of the present invention, obtaining data processing annotation information and then determining whether to perform data reprocessing includes:
[0095] When the data processing mark information indicates normal processing, the central processing unit processes the final processing data according to a preset procedure;
[0096] When the data processing marking information is abnormal processing, the central processing unit generates a control instruction to control the data processing chain to reprocess the data.
[0097] The working principle of the above technical solution is as follows: when the central processing unit (CPU) receives the data processing annotation information of all functional modules and confirms that all the annotation information is processed normally, it will start to further process the final processed data according to the preset program. If the central processing unit finds any abnormal processing annotation when checking the data processing annotation information, it will generate a control instruction. This control instruction will be sent to the relevant functional module group in the data processing chain, instructing to reprocess the data. Data reprocessing may involve recollecting data, recalculating or performing other necessary steps to ensure the accuracy and completeness of the data. After the data reprocessing is completed, the relevant functional module group will generate the processed data again and update its data processing annotation information. The central processing unit will then re-evaluate the data processing annotation information of all functional modules and re-execute normal processing or continue the data reprocessing cycle as needed.
[0098] The technical effect of the above technical solution is: through the exception handling and data reprocessing mechanism, the system can ensure the accuracy and integrity of the data. When data processing anomalies are found, the system can automatically trigger the data reprocessing process, correct the error in time, and reduce decision-making errors or business losses caused by data errors. The central processing unit can automatically judge the normality or abnormality of data processing according to the data processing annotation information, and take corresponding processing measures. This automated and intelligent processing method can significantly improve the response speed and processing efficiency of the system, reduce the need for manual intervention, and reduce operation and maintenance costs. The system has a strong fault recovery capability. When a data processing anomaly occurs in a functional module, the system can quickly identify and trigger the data reprocessing process, thereby ensuring the stability and reliability of the entire data processing chain. This fault recovery capability is crucial to ensure the continuous operation of the system and the continuity of business. Through data processing annotation information and exception handling mechanism, the system can provide administrators with detailed error information and processing suggestions. This helps administrators quickly locate problems, analyze the causes of problems, and take appropriate solutions. At the same time, the system can also record historical processing data and annotation information to provide strong support for subsequent troubleshooting and performance optimization. By ensuring data accuracy and system stability, the system can provide users with more reliable and high-quality services. When a system failure or data anomaly occurs, the system can quickly recover and continue to provide services.
[0099] In one embodiment of the present invention, the system comprises:
[0100] A control function association module is used to classify the control task information and function module information of the PLC controller, calculate the control fitness of the control task group and the function module group obtained by the classification, and associate the control task group and the function module group according to the control fitness to obtain a control association group;
[0101] The functional data processing module is used to establish a data processing chain of the functional module group according to the control task information, mark the sequence of data processing for the functional module group, and the functional module group performs data processing according to the associated control task information to obtain the processing data of each functional module, and then obtain the final processing data and send it to the central processing unit;
[0102] The abnormal labeling judgment module is used to calculate the data processing abnormal value of each functional module, compare the data processing abnormal value with the preset abnormal threshold, label the data processing of the functional module according to the comparison result, obtain the data processing labeling information, and then determine whether to reprocess the data.
[0103] The working principle of the above technical solution is as follows: the system first classifies the control task information and function module information of the PLC controller. The classification is based on factors such as the task control type and the function type of the function module. The control adaptability of the control task group and the function module group obtained by classification is calculated. According to the control adaptability, the system associates the control task group with the function module group to form a control association group. The purpose of association is to ensure that each control task can be processed by the most suitable function module. According to the control task information, the system establishes a data processing chain of the function module group for each control association group. The data processing chain defines the data processing sequence between the function modules. The system assigns a sequence number to each function module to identify its position in the data processing chain. The function module group processes the data according to the associated control task information and the predetermined data processing sequence. After each function module processes the data, it passes the result to the next module until the final processed data is obtained. The final processed data is sent to the central processing unit. The system calculates the abnormal value of each function module during the data processing process. The calculated data processing abnormal value is compared with the preset abnormal threshold. If the abnormal value exceeds the threshold, it is considered that the data processing is abnormal. Based on the comparison results, the system annotates the function modules for data processing and generates data processing annotation information. The system determines whether the data needs to be reprocessed based on the annotation information. If reprocessing is required, the system may reselect the function modules, adjust the processing order, or take other measures to ensure the accuracy and reliability of data processing.
[0104] The technical effect of the above technical solution is: through the intelligent classification and association of control tasks and functional modules, the system can ensure that each control task is processed by the most suitable functional module, thereby improving the utilization efficiency of resources. The establishment and execution of the data processing chain can ensure the efficient transmission and processing of data between functional modules, reduce unnecessary waiting time and data transmission delays, and improve the overall processing efficiency. Through the anomaly detection and processing mechanism, the system can promptly detect and handle abnormal situations in the data processing process, avoid problems such as data errors or system crashes, and enhance the stability and reliability of the system. The final processed data can provide important decision support information for the central processing unit, help the system make more accurate decisions and control actions, and improve the intelligence level of the system.
[0105] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.
Claims
1. A method for processing data of a PLC controller function module, characterized in that: The method comprises: Classifying the control task information and the function module information of the PLC controller, calculating the control fitness of the control task group and the function module group obtained by the classification, and associating the control task group and the function module group according to the control fitness to obtain a control association group; A data processing chain of a functional module group is established according to the control task information, and a serial number of a data processing sequence is marked on the functional module group. The functional module group processes data according to the associated control task information, obtains processing data of each functional module, and then obtains final processing data, which is sent to the central processing unit; Calculate the data processing anomaly value of each functional module, compare the data processing anomaly value with the preset anomaly threshold, annotate the data processing of the functional module according to the comparison result, obtain the data processing annotation information, and then determine whether to reprocess the data.
2. A PLC controller function module data processing method according to claim 1, characterized in that: The classification of the control task information and function module information of the PLC controller includes: Acquire control task information of a PLC controller, preprocess the control task information to obtain the preprocessed control task information, classify the control task information according to the control task type, and obtain a plurality of control task groups; A plurality of function modules of a PLC controller are obtained, and the plurality of function modules are classified according to function types to obtain a plurality of types of function module groups.
3. A PLC controller function module data processing method according to claim 1, characterized in that: The calculating of the control adaptability of the control task group and the function module group obtained by classification includes: Calculate the control adaptability of the control task group and the function module group according to the control task information of the multiple control task groups and the function information of the function module group; The calculation formula of the control adaptability is: Among them, SP is the control matching degree, Y c is the average required output data of the control task group, Y r The average required input data for the control task group, S c is the average actual output data of the functional module group, S r It is the average actual input data of the function module group.
4. A PLC controller function module data processing method according to claim 1, characterized in that: The step of associating the control task group and the function module group according to the control adaptability to obtain a control association group includes: Obtaining a preset fitness threshold, comparing the control fitness with the preset fitness threshold, and when the control fitness is greater than the preset fitness threshold, associating the corresponding control task group and the functional module group to obtain a corresponding control association group; When the control adaptability is less than or equal to a preset adaptability threshold, the corresponding control task group and function module group are not associated.
5. A PLC controller function module data processing method according to claim 1, characterized in that: The step of establishing a data processing chain of the functional module group according to the control task information and marking the sequence of data processing of the functional module group includes: According to the control task information corresponding to the multiple function module groups in the control association group, the multiple function module groups are connected in control order to obtain a data processing chain; Each functional module group of the data processing chain is labeled with a serial number of the data processing sequence to obtain functional module labeling information.
6. A method for processing data of a PLC controller function module according to claim 1, characterized in that: The functional module group performs data processing according to the associated control task information to obtain the processed data of each functional module, and then obtains the final processed data and sends it to the central processing unit, including: Assuming that there are n function module groups in total, the nth function module group performs data processing of corresponding functions according to the control task information of the control task group associated with it, and obtains the processed data of the nth function module group; Sending the processed data of the nth functional module group to the n-1th functional module group; Obtain the processing data of all functional modules in the order of the data processing chain and send it to the central processing unit.
7. A PLC controller function module data processing method according to claim 6, characterized in that: The process of obtaining the processing data of all functional modules in the order of the data processing chain and sending the processing data to the central processing unit includes: The n-1th function module group performs data processing of the corresponding function according to the control task information of the control task group associated with it, and obtains the processed data of the n-1th function module group, until all function module groups complete data processing, and obtain the processed data of all function modules. The processed data of the last function module that performs data processing is the final processed data, and the processed data of all function modules and the final processed data are sent to the central processing unit.
8. A method for processing data of a PLC controller function module according to claim 1, characterized in that: The step of calculating the data processing abnormal value of each functional module, comparing the data processing abnormal value with a preset abnormal threshold, and marking the data processing of the functional module according to the comparison result to obtain the data processing marking information includes: The central processing unit calculates the data processing abnormal value of each functional module according to the acquired processing data of each functional module; Compare the data processing abnormal value with a preset abnormal threshold value to obtain a comparison result; The calculation formula of the data processing outlier value is: Among them, CY is the data processing outlier, L is the total number of data processing types, SC i is the actual output data of the functional module for the i-th data processing, YC i Preset output data for the function module of the i-th data processing, SR i is the actual input data of the functional module for the i-th data processing, YR i Preset input data for the i-th data processing function module; When the data processing abnormal value is greater than the preset abnormal threshold, the function module corresponding to the data processing abnormal value is marked for abnormal processing; When the data processing abnormal value is less than or equal to the preset abnormal threshold, the function module corresponding to the data processing abnormal value is marked for normal processing, and the abnormal processing mark and the normal processing mark are the data processing mark information.
9. A method for processing data of a PLC controller function module according to claim 1, characterized in that: The obtaining of data processing annotation information and then determining whether to perform data reprocessing includes: When the data processing mark information indicates normal processing, the central processing unit processes the final processing data according to a preset procedure; When the data processing marking information is abnormal processing, the central processing unit generates a control instruction to control the data processing chain to reprocess the data.
10. A PLC controller function module data processing method and system, characterized in that: The system comprises: A control function association module is used to classify the control task information and function module information of the PLC controller, calculate the control fitness of the control task group and the function module group obtained by the classification, and associate the control task group and the function module group according to the control fitness to obtain a control association group; The functional data processing module is used to establish a data processing chain of the functional module group according to the control task information, mark the sequence of data processing for the functional module group, and the functional module group performs data processing according to the associated control task information to obtain the processing data of each functional module, and then obtain the final processing data and send it to the central processing unit; The abnormal labeling judgment module is used to calculate the data processing abnormal value of each functional module, compare the data processing abnormal value with the preset abnormal threshold, label the data processing of the functional module according to the comparison result, obtain the data processing labeling information, and then determine whether to reprocess the data.
Citation Information
Patent Citations
Industrial personal computer control method and system based on vehicle-mounted application
CN114518896A
Process and production line matching degree calculation method, optimization method and device
CN115935196A
Fire fighting system input and output module arrangement method, device and equipment and storage medium
CN117874899A
PLC function requirement adaptation control method and system
CN118393984A
Operation management device, operation management method, and operation management program
US20110161743A1
Cited By
Multi-terminal series data transmission interaction system and method based on communication network
CN119603126A
Multi-terminal serial data transmission interactive system and method based on communication network
CN119603126B
