A numerical value and script linkage method and system based on HMI

By using preset scripts and threshold trigger labels in the data interaction between HMI and PLC, the flexibility issues of data interaction and control logic between HMI and PLC are solved, enabling the system to respond quickly and control accurately, and improving the intelligence and stability of equipment status reflection and control.

CN118981183BActive Publication Date: 2026-05-15HARBIN YULONG AUTOMATION
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
HARBIN YULONG AUTOMATION
Filing Date
2024-08-06
Publication Date
2026-05-15

AI Technical Summary

Technical Problem

The existing data interaction and control logic between HMI and PLC lacks flexibility and adaptability, which requires manual modification when equipment status changes or control strategies are adjusted. This is time-consuming, labor-intensive, and prone to errors.

Method used

By acquiring the data read by the HMI from the PLC controller, using a preset script to associate the read data with the HMI elements, triggering annotations based on preset thresholds, and realizing the initial and cumulative linkage control interface updates, the system determines whether to perform a re-update by calculating the update quality value.

Benefits of technology

It enables the system to respond quickly and handle changes on site accurately, improves the system's intelligence and flexibility, reduces the risk of human intervention and misoperation, and provides more accurate equipment status reflection and control logic.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118981183B_ABST
    Figure CN118981183B_ABST
Patent Text Reader

Abstract

The application provides a numerical value and script linkage method and system based on HMI, relates to the numerical value and script linkage technical field of HMI, obtains reading data of an HMI to a PLC controller, associates preset scripts with the reading data and elements of the HMI respectively, carries out one-level trigger annotation on the reading data according to a preset running threshold, triggers the preset scripts, and obtains an initial linkage control interface; cumulative monitoring is carried out on the reading data, the obtained cumulative monitoring data is associated with the preset scripts, cumulative trigger annotation is carried out on the reading data according to a preset cumulative threshold, cumulative trigger is carried out on the preset scripts, a cumulative linkage control interface is obtained, and then an updated interface is obtained; the updated quality value of the updated interface is calculated, and it is judged whether the updated interface is subjected to re-updating, the preset scripts and a dynamic data monitoring mechanism are introduced, flexible data interaction between the HMI and the PLC and dynamic adjustment of control logic are realized, and the adaptability and reliability of an automatic system are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention proposes a numerical and script linkage method and system based on HMI, which relates to the field of numerical and script linkage technology of HMI. Background Technology

[0002] In the field of industrial automation, the integrated application of Human-Machine Interfaces (HMIs) and Programmable Logic Controllers (PLCs) is quite common. The HMI, as the window through which users interact with automated equipment, can display the equipment's operating status in real time and provide operation and control functions. The PLC, as the core controller of the automation system, is responsible for receiving instructions from the HMI and controlling the equipment according to preset logic programs. However, in existing technologies, the data interaction and control logic between the HMI and PLC are often relatively fixed, lacking sufficient flexibility and adaptability. When the equipment's operating status changes or the control strategy needs adjustment, it usually requires professionals to manually modify the HMI interface and the PLC program, which is time-consuming, labor-intensive, and prone to errors. Summary of the Invention

[0003] This invention provides a method and system for numerical and script-based linkage based on HMI, addressing the shortcomings of existing technologies where data interaction and control logic between HMI and PLC are often relatively fixed, lacking sufficient flexibility and adaptability. When equipment operating status changes or control strategies need adjustment, it typically requires manual modification of the HMI interface and PLC program by professionals, which is time-consuming, labor-intensive, and prone to errors.

[0004] This invention proposes a method and system for linking numerical data with scripts based on HMI, the method comprising:

[0005] S1. Obtain the data read by the HMI from the PLC controller, associate the preset script with the data read and the elements of the HMI respectively, mark the data read with a first-level trigger according to the preset running threshold, trigger the preset script, and obtain the initial linkage control interface.

[0006] S2. Perform cumulative monitoring of changes in the read data, associate the acquired cumulative monitoring data with the preset script, perform cumulative triggering annotation on the read data according to the preset cumulative threshold, perform cumulative triggering on the preset script, obtain the cumulative linkage control interface, and then obtain the update interface.

[0007] S3. Calculate the update quality value of the updated interface and determine whether to re-update the updated interface.

[0008] Further, S1 includes:

[0009] Connect the HMI to the PLC controller to obtain the group of linked devices;

[0010] The real-time data of the PLC controller is read through the linked equipment group to obtain the read data;

[0011] The read data is preprocessed to obtain preprocessed read data;

[0012] The preprocessed read data is classified according to data type to obtain multiple types of read data;

[0013] The various types of read data are associated with preset scripts respectively to obtain data associations;

[0014] Associate the preset scripts with the elements of the HMI separately to obtain multiple element associations;

[0015] By setting a preset running threshold, the multiple types of read data are marked with a first-level trigger, and a preset script is triggered.

[0016] Furthermore, the step of using a preset running threshold to perform first-level trigger annotation on the multiple types of read data, and triggering a preset script, includes:

[0017] The data read for each category is compared with the corresponding category's running threshold in the preset running threshold.

[0018] When the read data exceeds the corresponding running threshold in the preset running threshold, the read data is marked with a first-level trigger.

[0019] When the read data does not exceed the corresponding running threshold in the preset running threshold, no first-level trigger label is applied to the read data;

[0020] The preset script corresponding to the read data in the data association is triggered according to the first-level trigger label. The preset script is executed according to the read data to form the initial linkage control interface.

[0021] Further, the step of triggering a preset script corresponding to the read data in the data association based on the first-level trigger label, wherein the preset script executes the script based on the read data to form an initial linkage control interface, includes:

[0022] When the PLC controller recognizes a level 1 trigger label, it triggers the preset script corresponding to the level 1 trigger label.

[0023] The preset script executes the control of the corresponding element in the element association to obtain the control interface of the first-level trigger label for each category;

[0024] Multiple types of primary trigger labels form the initial linkage control interface.

[0025] Further, S2 includes:

[0026] For each type of data read, cumulative changes are monitored to obtain cumulative monitoring data;

[0027] The cumulative monitoring data is preprocessed to obtain preprocessed cumulative monitoring data of multiple types of read data;

[0028] The cumulative monitoring data of the multiple types of read data are associated with preset scripts respectively to obtain cumulative data association;

[0029] By using a preset cumulative threshold, the cumulative monitoring data of the multiple types of read data is cumulatively triggered to obtain cumulative trigger labels.

[0030] Further, the step of cumulatively triggering the cumulative monitoring data of the multiple types of read data by using a preset cumulative threshold to obtain a cumulative trigger label includes:

[0031] The cumulative monitoring data for each category is compared with the cumulative threshold for the corresponding category in the preset cumulative threshold.

[0032] When the cumulative monitoring data of the read data exceeds the cumulative threshold of the corresponding category in the preset cumulative threshold, the cumulative monitoring data of the read data is cumulatively triggered and labeled.

[0033] When the read data does not exceed the cumulative threshold of its corresponding category in the preset cumulative threshold, the read data will not be cumulatively triggered and labeled.

[0034] The preset script corresponding to the read data in the data association is triggered cumulatively according to the cumulative trigger annotation. The preset script is executed according to the cumulative monitoring data of the read data to obtain the cumulative linkage control interface, and then obtain the update interface.

[0035] Further, the step of cumulatively triggering a preset script corresponding to the read data in the data association based on the cumulative trigger annotation, wherein the preset script is executed based on the cumulative monitoring data of the read data to obtain a cumulative linkage control interface, and then to obtain an update interface, includes:

[0036] When the PLC controller recognizes the cumulative trigger mark, it triggers the preset script corresponding to the cumulative trigger mark;

[0037] The preset script executes the control of the corresponding element in the element association to obtain the control interface of the cumulative trigger annotation for each type;

[0038] The control interfaces for multiple types of cumulative trigger labels form a cumulative linkage control interface;

[0039] The initial linkage control interface is updated by using the cumulative linkage control interface to obtain the updated interface.

[0040] Further, S3 includes:

[0041] Calculate the update quality value of the updated interface and compare the update quality value with a preset quality threshold;

[0042] When the updated quality value is greater than the preset quality threshold, the update of the interface is stopped.

[0043] When the updated quality value is less than or equal to a preset quality threshold, the updated interface is re-updated until the updated quality value is greater than the preset quality threshold.

[0044] Furthermore, the updated quality value includes:

[0045] The formula for calculating the updated quality value is:

[0046]

[0047] Among them, f gz To update the quality value, L represents the type of data read, and Δe dhi For the cumulative monitoring data of the i-th type of data reading after the update, Δe yi Let Δe be the cumulative threshold for the i-th type of data read. dQi For the cumulative monitoring data of the i-th type of data reading before the update, c dhi For the updated i-th type of data read, c yi Let c be the operating threshold for the i-th type of data reading. dQi This refers to the i-th type of data read before the update.

[0048] Furthermore, the system includes:

[0049] The initial trigger linkage module is used to acquire the data read by the HMI from the PLC controller, associate the preset script with the data read and the elements of the HMI respectively, mark the data read with a first-level trigger according to the preset running threshold, trigger the preset script, and obtain the initial linkage control interface.

[0050] The cumulative trigger linkage module is used to monitor changes in the read data, associate the acquired cumulative monitoring data with a preset script, mark the read data for cumulative triggering according to a preset cumulative threshold, trigger the preset script cumulatively, obtain the cumulative linkage control interface, and then obtain the update interface.

[0051] The update judgment module is used to calculate the update quality value of the updated interface and determine whether to re-update the interface.

[0052] The beneficial effects of this invention are as follows: By reading data from equipment or sensors in real time through a PLC controller and triggering preset scripts based on this data, the system can reflect the status of field equipment in real time and accurately execute corresponding control operations. This ensures the system's rapid response and accurate handling of changes in the field. Through the association between preset scripts and read data, the system achieves automated data processing and control functions. Simultaneously, the system can trigger judgments based on preset thresholds, executing corresponding operations without manual intervention, thus improving the system's intelligence level. The HMI provides a visual linkage control interface, intuitively displaying the system's operating status and control situation. Through the element display and operation on the interface, operators can easily monitor and control the system, improving work efficiency and convenience. The system not only focuses on real-time data changes but also processes the cumulative effect of data through cumulative monitoring. This allows the system to more comprehensively reflect the long-term operating status and cumulative effects of the equipment, providing a more accurate basis for equipment maintenance and management. The system calculates the update quality value of the updated interface and triggers a re-update process as needed, ensuring that the interface display and control logic are always in optimal condition. This dynamic update capability enables the system to adapt to different working environments and changing needs, improving the system's flexibility and adaptability. By triggering and executing pre-set scripts, the system can automatically handle abnormal situations and take corresponding measures, thereby improving the system's stability and reliability. Simultaneously, the system can also make intelligent decisions and controls based on real-time data and cumulative effects, reducing the risk of human intervention and misoperation. Attached Figure Description

[0053] Figure 1 This is a schematic diagram of a numerical and script linkage method based on HMI. Detailed Implementation

[0054] The preferred embodiments of the present invention will be described below with reference to the accompanying drawings. It should be understood that the preferred embodiments described herein are for illustration and explanation only and are not intended to limit the present invention.

[0055] In one embodiment of the present invention, a method and system for linking numerical values ​​and scripts based on HMI are proposed, the method comprising:

[0056] S1. Obtain the data read by the HMI from the PLC controller, associate the preset script with the data read and the elements of the HMI respectively, mark the data read with a first-level trigger according to the preset running threshold, trigger the preset script, and obtain the initial linkage control interface.

[0057] S2. Perform cumulative monitoring of changes in the read data, associate the acquired cumulative monitoring data with the preset script, perform cumulative triggering annotation on the read data according to the preset cumulative threshold, perform cumulative triggering on the preset script, obtain the cumulative linkage control interface, and then obtain the update interface.

[0058] S3. Calculate the update quality value of the updated interface and determine whether to re-update the updated interface.

[0059] The working principle of the above technical solution is as follows: The PLC controller collects data from field devices or sensors in real time and sends this data to the HMI. A preset script (programming logic, function, or algorithm) is associated with the read data and HMI elements (such as buttons, indicator lights, etc.). Elements on the HMI interface will display or operate accordingly based on the data sent by the PLC. The system judges the read data based on preset operating thresholds. If the data exceeds or falls below these thresholds, the system will trigger the preset script to execute an operation or change the display of the HMI interface. After the above processing, the HMI interface will be updated according to the read data and the triggered script, forming an initial linkage control interface corresponding to the current system state. The system continuously monitors the data sent by the PLC and records the amount of data change or the cumulative value of change. In addition to the real-time operating thresholds, the system also has preset cumulative thresholds. When the cumulative change of the data reaches or exceeds these thresholds, the system will trigger the preset script again. Similar to the first-level trigger, but this trigger is based on the cumulative change of the data rather than the instantaneous value. This triggering method can be used to handle situations that require cumulative effects for judgment, such as the total operating time of the equipment, total output, etc. Based on cumulative triggering, the HMI interface will update again, forming a cumulative linkage control interface reflecting the long-term state or cumulative effect of the system. Ultimately, through the processing of S1 and S2, the system obtains an updated interface that integrates real-time state and cumulative effect. The system calculates the update quality value of the updated interface based on certain algorithms or standards (such as data accuracy, interface response speed, user feedback, etc.). If the update quality value is lower than the preset standard, the system may consider that the current interface needs further optimization or correction. At this time, the system will trigger a re-update process, which may involve rereading data, recalculating, or re-triggering scripts. If the system decides to re-update, it will return to steps S1 or S2 and regenerate the linkage control interface based on the new data or conditions. This process forms a closed-loop control system that can reflect the system's state in real time and automatically adjust as needed.

[0060] The technical effects of the above solution are as follows: By reading data from equipment or sensors in real time through the PLC controller and triggering preset scripts based on this data, the system can reflect the status of field equipment in real time and accurately execute corresponding control operations. This ensures the system's rapid response and accurate handling of changes in the field. Through the association between preset scripts and read data, the system achieves automated data processing and control functions. Simultaneously, the system can trigger judgments based on preset thresholds, executing corresponding operations without manual intervention, thus improving the system's intelligence level. The HMI provides a visual linkage control interface, intuitively displaying the system's operating status and control situation. Through the element display and operation on the interface, operators can easily monitor and control the system, improving work efficiency and convenience. The system not only focuses on real-time data changes but also processes the cumulative effect of data through cumulative monitoring. This allows the system to more comprehensively reflect the long-term operating status and cumulative effects of the equipment, providing a more accurate basis for equipment maintenance and management. The system calculates the update quality value of the updated interface and triggers a re-update process as needed, ensuring that the interface display and control logic are always in optimal condition. This dynamic update capability enables the system to adapt to different working environments and changing needs, improving the system's flexibility and adaptability. By triggering and executing pre-set scripts, the system can automatically handle abnormal situations and take corresponding measures, thereby improving the system's stability and reliability. Simultaneously, the system can also make intelligent decisions and controls based on real-time data and cumulative effects, reducing the risk of human intervention and misoperation.

[0061] In one embodiment of the present invention, S1 includes:

[0062] Connect the HMI to the PLC controller to obtain the group of linked devices;

[0063] The real-time data of the PLC controller is read through the linked equipment group to obtain the read data;

[0064] The read data is preprocessed to obtain preprocessed read data;

[0065] The preprocessed read data is classified according to data type to obtain multiple types of read data;

[0066] The various types of read data are associated with preset scripts respectively to obtain data associations;

[0067] Associate the preset scripts with the elements of the HMI separately to obtain multiple element associations;

[0068] By setting a preset running threshold, the multiple types of read data are marked with a first-level trigger, and a preset script is triggered.

[0069] The working principle of the above technical solution is as follows: A communication connection is established between the HMI (Human Machine Interface) and the PLC (Programmable Logic Controller), typically using communication protocols such as Ethernet or serial ports to ensure accurate and fast data transmission. After the communication connection between the HMI and the PLC is established, the system identifies and configures the linked device group associated with the PLC. Through the PLC's communication interface, the HMI system reads real-time data from the PLC controller. This data includes device status, sensor readings, control parameters, etc. The read real-time PLC data is preprocessed, including data cleaning (noise removal, outlier removal), data conversion (unit conversion, data type conversion), etc., to ensure data quality and accuracy. The preprocessed data is classified according to its type, such as temperature data, pressure data, flow data, etc. Multiple types of read data are associated with preset scripts. These scripts may contain specific logic, algorithms, or control strategies to respond to data changes or trigger specific operations. The preset scripts are associated with elements on the HMI interface (such as buttons, indicator lights, text boxes, etc.). When a script is triggered, the corresponding element on the HMI interface will be updated or operated. The system assesses various types of read data based on preset operating thresholds. If the data exceeds or falls below these thresholds, the system triggers preset scripts associated with that data. The execution of these scripts will alter the HMI interface display or perform corresponding control operations.

[0070] The technical effects of the above solution are as follows: Through real-time communication between the HMI and PLC, the system can quickly respond to changes in field equipment and update the HMI interface in a timely manner. This improves the system's real-time performance and responsiveness. The use of preset scripts enables the system to automatically process data and control equipment, reducing the need for manual intervention. Simultaneously, through data classification and association, the system can intelligently respond to different data changes, improving the system's intelligence level. Data preprocessing and classification improve data accuracy and reliability, reducing the impact of noise and outliers on the system. This helps ensure that the system makes decisions and controls based on accurate data. The HMI interface, through the association of elements and scripts, allows operators to intuitively understand the system's status and perform operations. This improves the interface's user-friendliness and ease of use, reducing operational difficulty and error rates. Through the association of preset scripts and HMI elements, the system can flexibly adapt to different control requirements. Furthermore, the system can easily add new equipment, data, and scripts to achieve functional expansion and upgrades. Through mechanisms such as data preprocessing and threshold judgment, the system can ensure correct response and control in abnormal situations, improving system safety and stability. At the same time, the system's modular design and the selection of a good communication protocol also contribute to improving system stability.

[0071] In one embodiment of the present invention, the step of performing first-level trigger annotation on the multiple types of read data through a preset running threshold, and triggering a preset script, includes:

[0072] The data read for each category is compared with the corresponding running threshold of the category in the preset running threshold; the preset running threshold includes running thresholds for multiple categories.

[0073] When the read data exceeds the corresponding running threshold in the preset running threshold, the read data is marked with a first-level trigger.

[0074] When the read data does not exceed the corresponding running threshold in the preset running threshold, no first-level trigger label is applied to the read data;

[0075] The preset script corresponding to the read data in the data association is triggered according to the first-level trigger label. The preset script is executed according to the read data to form the initial linkage control interface.

[0076] The working principle of the above technical solution is as follows: First, it integrates cumulative monitoring data and cumulative script execution data. A cumulative linkage control interface is then generated using this data. This interface includes various charts, indicator lights, buttons, and other elements to display the device's cumulative operating status, script execution status, and any related warnings or notifications. Over time, the cumulative monitoring data and cumulative script execution data are continuously updated. The system updates the cumulative linkage control interface in real time based on these updated data, ensuring that the operator always sees the latest information. The cumulative linkage control interface typically also includes user interaction elements, such as buttons or sliders, allowing the operator to control or adjust the system as needed.

[0077] The technical effects of the above solution are as follows: The cumulative linkage control interface can comprehensively display the cumulative operating status of the equipment and the execution status of the scripts, enabling operators to gain a deeper understanding of the overall system status. The real-time update function of the interface ensures that operators can always obtain the latest system information, allowing for timely responses or adjustments. Cumulative data and script execution data provide valuable decision support information for management, helping them to formulate more effective maintenance plans and optimize resource allocation. By promptly detecting and handling anomalies, the cumulative linkage control interface helps improve the stability and reliability of the system. The intuitive interface design and user interaction functions make it easier for operators to use the system, thereby improving user experience and work efficiency.

[0078] In one embodiment of the present invention, the step of triggering a preset script corresponding to the read data in the data association according to the first-level trigger label, wherein the preset script executes the script according to the read data to form an initial linkage control interface, includes:

[0079] When the PLC controller recognizes a first-level trigger label, it triggers the preset script corresponding to the first-level trigger label.

[0080] The preset script executes the control of the corresponding element in the element association to obtain the control interface of the first-level trigger label for each category;

[0081] Multiple types of primary trigger labels form the initial linkage control interface.

[0082] The working principle of the above technical solution is as follows: The PLC controller continuously monitors the data read by each sensor and determines whether the data exceeds the limit based on preset operating thresholds. When the read data exceeds the preset threshold, the PLC generates a first-level trigger label. After recognizing the first-level trigger label, the PLC controller searches for the preset script associated with that label. These scripts are pre-written programs used to handle control logic under specific conditions. The preset scripts contain information about element associations, that is, which control elements (such as valves, motors, indicator lights, etc.) the script is associated with. When a script is triggered, the PLC operates on these associated control elements according to the instructions in the script, such as opening a valve, starting a motor, or lighting an indicator light. For each type of first-level trigger label, the PLC controller generates a corresponding control interface. This interface displays the status and operation options of the control elements associated with that label. When multiple types of first-level trigger labels are recognized and triggered, the PLC controller generates multiple control interfaces. These interfaces are interconnected through a linkage mechanism, forming an initial linkage control interface. This interface displays the operating status of the entire system and the available control options, enabling the operator to fully understand and control the system.

[0083] The technical effects of the above solution are as follows: When the system malfunctions or requires intervention, the PLC controller can quickly identify the primary trigger marker and trigger the corresponding preset script, achieving a rapid response. This helps avoid potential risks and losses. The initial linkage control interface integrates multiple control interfaces, improving work efficiency and ease of operation. The control interface graphically displays the system's operating status and control options, allowing operators to intuitively understand the system's condition and perform operations. Preset scripts and element associations can be configured and modified as needed to adapt to different control requirements. This gives the system high flexibility and scalability. Through the triggering of preset scripts and the generation of the linkage control interface, the system can automatically take corresponding measures in abnormal situations, reducing the need for human intervention and the risk of misoperation, thereby improving the system's reliability and stability.

[0084] In one embodiment of the present invention, S2 includes:

[0085] For each type of read data, cumulative changes are monitored to obtain cumulative monitoring data;

[0086] The cumulative monitoring data is preprocessed to obtain preprocessed cumulative monitoring data of multiple types of read data;

[0087] The cumulative monitoring data of the multiple types of read data are associated with preset scripts respectively to obtain cumulative data association;

[0088] By using a preset cumulative threshold, the cumulative monitoring data of the multiple types of read data is cumulatively triggered to obtain cumulative trigger labels.

[0089] The working principle of the above technical solution is as follows: Preprocessed read data is categorized according to its type, ensuring that each type of data matches its corresponding preset operating threshold. The preset operating thresholds include multiple categories, each with a corresponding threshold range. The system compares the read data of each category with its corresponding threshold within the preset operating thresholds. This step determines whether the read data meets the criteria for triggering a corresponding operation. If the read data exceeds its corresponding operating threshold within the preset operating thresholds, the system will mark this data with a first-level trigger label. A first-level trigger label is an identifier or marker used to indicate that the system needs to execute preset scripts related to this data. If the read data does not exceed its corresponding operating threshold within the preset operating thresholds, the system will not mark this data with a first-level trigger label, meaning that no preset scripts related to this data need to be executed at this time. Based on the first-level trigger labels, the system will find the preset scripts corresponding to these labels in the data association and execute these scripts. The execution of these scripts will be based on the read data and will change or update the HMI (Human Machine Interface) display content as needed, thus forming the initial linkage control interface. The linkage control interface displays the system status and control options based on real-time data.

[0090] The technical effects of the above solution are as follows: By accurately comparing the read data with preset operating thresholds, the system can accurately determine when to trigger the preset script, thereby achieving precise control. This helps improve the system's control accuracy and efficiency. When the read data exceeds the preset threshold, the system can immediately perform first-level trigger annotation and script execution, forming the initial linkage control interface. This real-time response capability allows the system to quickly respond to changes in the field, ensuring system stability and safety. The preset operating thresholds and scripts can be configured and modified as needed to adapt to different control requirements. Simultaneously, the system can easily add new data types, thresholds, and scripts to expand and upgrade its functionality. The initial linkage control interface is generated based on real-time data and preset scripts, intuitively displaying the system's status and control options. This allows operators to easily understand the system's status and perform corresponding operations, improving the system's user-friendliness. Through accurate data comparison and trigger judgment, the system can avoid unnecessary script execution and misoperation, thereby improving system reliability and stability. Furthermore, the system's modular design and the selection of a suitable communication protocol also contribute to improving system reliability.

[0091] In one embodiment of the present invention, the step of cumulatively triggering the cumulative monitoring data of the multiple types of read data by means of a preset cumulative threshold to obtain a cumulative trigger label includes:

[0092] The cumulative monitoring data of each type of read data is compared with the cumulative threshold of the corresponding type in the preset cumulative threshold; the preset cumulative threshold includes the cumulative threshold of multiple cumulative stages for multiple types.

[0093] When the cumulative monitoring data of the read data exceeds the cumulative threshold of the corresponding category in the preset cumulative threshold, the cumulative monitoring data of the read data is cumulatively triggered and labeled.

[0094] When the read data does not exceed the cumulative threshold of its corresponding category in the preset cumulative threshold, the read data will not be cumulatively triggered and labeled.

[0095] The preset script corresponding to the read data in the data association is triggered cumulatively according to the cumulative trigger annotation. The preset script is executed according to the cumulative monitoring data of the read data to obtain the cumulative linkage control interface, and then obtain the update interface.

[0096] The working principle of the above technical solution is as follows: Accumulated monitoring data is collected for each type of read data. This accumulated data includes the total data over a certain time period. The system compares the accumulated monitoring data with the accumulated thresholds of multiple cumulative stages for the corresponding type within a preset accumulated threshold. The preset accumulated threshold may include multiple stages, each corresponding to a specific accumulated threshold. If the accumulated monitoring data of the read data exceeds the accumulated threshold of a certain cumulative stage for its corresponding type within the preset accumulated threshold, the system will mark the accumulated monitoring data as cumulatively triggered. This mark will serve as the condition for triggering a preset script. If the accumulated monitoring data of the read data does not exceed the accumulated threshold of any cumulative stage for its corresponding type within the preset accumulated threshold, the system will not mark the read data as cumulatively triggered. Based on the accumulated trigger marks, the system will trigger the preset scripts corresponding to these marks. These scripts will be executed based on the accumulated monitoring data of the read data and may include operations such as data analysis, control command sending, and alarm notification.

[0097] The technical effects of the above solution are as follows: By processing and analyzing the accumulated monitoring data, the system can capture long-term trends and changes in the data. When the accumulated monitoring data exceeds a preset threshold, the system can immediately trigger a corresponding preset script for early warning or preventative maintenance. This helps avoid potential equipment failures and improves equipment reliability and lifespan. Through the analysis of accumulated data, the system can predict equipment maintenance needs, energy consumption, and other resource consumption, thereby optimizing resource allocation and planning. This helps reduce maintenance costs and improve resource utilization efficiency. Through accumulated triggering and script execution, the system can automatically handle abnormal situations and take corresponding measures, thereby improving system reliability and stability. This reduces the need for human intervention and the risk of misoperation. Through the analysis of this data, management can understand the overall operating status of the system, performance bottlenecks, and improvement directions, thus making more informed decisions.

[0098] In one embodiment of the present invention, the preset script corresponding to the read data in the data association is cumulatively triggered according to the cumulative trigger annotation. The preset script is executed according to the cumulative monitoring data of the read data to obtain a cumulative linkage control interface, and then to obtain an update interface, including:

[0099] When the PLC controller recognizes the cumulative trigger mark, it triggers the preset script corresponding to the cumulative trigger mark;

[0100] The preset script executes the control of the corresponding element in the element association to obtain the control interface of the cumulative trigger annotation for each type;

[0101] The control interfaces for multiple types of cumulative trigger labels form a cumulative linkage control interface;

[0102] The initial linkage control interface is updated by using the cumulative linkage control interface to obtain the updated interface.

[0103] The working principle of the above technical solution is as follows: The PLC controller periodically or in real-time collects cumulative monitoring data of various types of read data and compares it with a preset cumulative threshold. When the cumulative monitoring data exceeds the preset cumulative threshold, the PLC generates a cumulative trigger label. Once the PLC recognizes the cumulative trigger label, it searches for and triggers the associated preset script based on the information in the label. These scripts typically contain control logic for specific cumulative trigger conditions. The preset script contains information about the associated elements, i.e., which control elements (such as valves, motors, indicator lights, etc.) the script is associated with. After the script is triggered, the PLC executes control operations on the associated elements according to the instructions in the script. For each type of cumulative trigger label, the PLC generates a corresponding control interface. These interfaces display the status, operation options, and cumulative data of the control elements associated with the label. When multiple types of cumulative trigger labels are recognized and triggered, the PLC generates multiple control interfaces. These interfaces are interconnected through a linkage mechanism, forming a cumulative linkage control interface. This interface provides a comprehensive display and control of the cumulative status of the entire system. Through the cumulative linkage control interface, the PLC can update the initial linkage control interface. This includes updating the status of control elements based on accumulated data and script execution results, adding new control options, or modifying existing control logic. Ultimately, the PLC generates an updated linkage control interface to reflect the latest system status and control requirements.

[0104] The technical effects of the above solution are as follows: Through cumulative trigger annotation and cumulative linkage control interface, the system can continuously monitor various types of cumulative data and automatically trigger corresponding control logic when a preset threshold is reached. This helps to promptly identify potential problems or changes in long-term trends and take corresponding control measures. The cumulative linkage control interface integrates multiple control interfaces, allowing operators to centrally view and control the cumulative status of the entire system on a single interface. This improves work efficiency and ease of operation. The system can dynamically update the linkage control interface based on cumulative data and script execution results to reflect the latest system status and control requirements. This dynamic adaptability makes the system more flexible and scalable, capable of coping with complex and ever-changing control environments. Through the triggering of preset scripts and the updating of the linkage control interface, the system can automatically take corresponding measures in abnormal situations, reducing the need for human intervention and the risk of misoperation, thereby improving the reliability and stability of the system. Cumulative data and script execution results can provide valuable decision support information for management. By analyzing and interpreting this information, management can make more informed decisions, such as optimizing maintenance plans and adjusting resource allocation.

[0105] In one embodiment of the present invention, S3 includes:

[0106] Calculate the update quality value of the updated interface and compare the update quality value with a preset quality threshold;

[0107] When the updated quality value is greater than the preset quality threshold, the update of the interface is stopped.

[0108] When the updated quality value is less than or equal to a preset quality threshold, the updated interface is re-updated until the updated quality value is greater than the preset quality threshold.

[0109] The formula for calculating the updated quality value is:

[0110]

[0111] Among them, f gz To update the quality value, L represents the type of data read, and Δe dhi For the cumulative monitoring data of the i-th type of data reading after the update, Δe yi Let Δe be the cumulative threshold for the i-th type of data read. dQi For the cumulative monitoring data of the i-th type of data reading before the update, c dhi For the updated i-th type of data read, c yi Let c be the operating threshold for the i-th type of data reading. dQi This refers to the i-th type of data read before the update.

[0112] The working principle of the above technical solution is as follows: In an automation system, the quality of the updated interface is crucial for the operator, as it directly affects the operator's understanding of the system's current state and the control operations that can be performed. To ensure the strength and effectiveness of the updated interface, the system needs to calculate the updated interface's quality value and compare it with a preset quality threshold. The system obtains the cumulative monitoring data of various types of read data by reading data from the HMI to the PLC controller. Then, according to a preset script, the system processes this data and generates the updated interface. After generating the updated interface, the system begins to calculate the updated quality value. This calculation formula considers the type of read data (L), the cumulative monitoring data of various types of data before and after the update (sum), the cumulative threshold of various types of data (), and the real-time read values ​​of various types of data before and after the update (sum). The calculated updated quality value is then compared with the preset quality threshold. If the updated quality value is greater than the preset quality threshold, it indicates that the quality of the updated interface is high and can accurately reflect the current state of the system, so the system stops further updating the updated interface. If the updated quality value is less than or equal to the preset quality threshold, it indicates that the quality of the updated interface is low and may not accurately reflect the current state of the system or that other problems exist. In this situation, the system will re-update the interface. The re-update process may include rereading data, re-executing the preset script, and recalculating the update quality value. This process will repeat until the update quality value exceeds the preset quality threshold.

[0113] The technical effects of the above solution are as follows: By calculating the update quality value and comparing it with a preset threshold, the system can accurately determine whether the quality of the updated interface meets the requirements. If the quality does not meet the requirements, the system will re-update until the requirements are met, thus ensuring that the interface seen by the operator is always accurate and reliable. When the quality of the updated interface is high, the system stops updating the interface, avoiding unnecessary update operations and reducing the consumption of system resources. Because the system monitors and evaluates the quality of the updated interface in real time, it can promptly repair and adjust when problems are discovered, thereby improving the stability and reliability of the system. By providing an accurate and reliable updated interface, the system can help operators better understand and control the system, improving user experience and work efficiency.

[0114] According to one embodiment of the present invention, the system includes:

[0115] The initial trigger linkage module is used to acquire the data read by the HMI from the PLC controller, associate the preset script with the data read and the elements of the HMI respectively, mark the data read with a first-level trigger according to the preset running threshold, trigger the preset script, and obtain the initial linkage control interface.

[0116] The cumulative trigger linkage module is used to monitor changes in the read data, associate the acquired cumulative monitoring data with a preset script, mark the read data for cumulative triggering according to a preset cumulative threshold, trigger the preset script cumulatively, obtain the cumulative linkage control interface, and then obtain the update interface.

[0117] The update judgment module is used to calculate the update quality value of the updated interface and determine whether to re-update the interface.

[0118] The working principle of the above technical solution is as follows: The PLC controller collects data from field devices or sensors in real time and sends this data to the HMI. A preset script (programming logic, function, or algorithm) is associated with the read data and HMI elements (such as buttons, indicator lights, etc.). Elements on the HMI interface will display or operate accordingly based on the data sent by the PLC. The system judges the read data based on preset operating thresholds. If the data exceeds or falls below these thresholds, the system will trigger the preset script to execute an operation or change the display of the HMI interface. After the above processing, the HMI interface will be updated according to the read data and the triggered script, forming an initial linkage control interface corresponding to the current system state. The system continuously monitors the data sent by the PLC and records the amount of data change or the cumulative value of change. In addition to the real-time operating thresholds, the system also has preset cumulative thresholds. When the cumulative change of the data reaches or exceeds these thresholds, the system will trigger the preset script again. Similar to the first-level trigger, but this trigger is based on the cumulative change of the data rather than the instantaneous value. This triggering method can be used to handle situations that require cumulative effects for judgment, such as the total operating time of the equipment, total output, etc. Based on cumulative triggering, the HMI interface will update again, forming a cumulative linkage control interface reflecting the long-term state or cumulative effect of the system. Ultimately, through the processing of the initial trigger linkage module and the cumulative trigger linkage module, the system obtains an updated interface that integrates real-time state and cumulative effect. The system calculates the update quality value of the updated interface based on certain algorithms or standards (such as data accuracy, interface response speed, user feedback, etc.). If the update quality value is lower than the preset standard, the system may consider that the current interface needs further optimization or correction. At this time, the system will trigger a re-update process, which may involve rereading data, recalculating, or re-triggering scripts. If the system decides to re-update, it will return to step S1 or S2 and regenerate the linkage control interface based on the new data or conditions. This process forms a closed-loop control system that can reflect the system's state in real time and automatically adjust as needed.

[0119] The technical effects of the above solution are as follows: The initial trigger linkage module reads data from equipment or sensors in real time through the PLC controller and triggers preset scripts based on this data. The system can reflect the status of field equipment in real time and accurately execute corresponding control operations. This ensures the system's rapid response and accurate handling of changes in the field. Through the association between preset scripts and read data, the system achieves automated data processing and control functions. Simultaneously, the system can trigger judgments based on preset thresholds, executing corresponding operations without manual intervention, thus improving the system's intelligence level. The HMI provides a visual linkage control interface, intuitively displaying the system's operating status and control situation. Through the element display and operation on the interface, operators can easily monitor and control the system, improving work efficiency and convenience. The cumulative trigger linkage module focuses on changes in real-time data and also processes the cumulative effect of data through cumulative monitoring. This allows the system to more comprehensively reflect the long-term operating status and cumulative effects of the equipment, providing a more accurate basis for equipment maintenance and management. The calculation update judgment module calculates the update quality value of the update interface and triggers a re-update process as needed, ensuring that the interface display and control logic are always in optimal condition. This dynamic update capability allows the system to adapt to different working environments and changing needs, improving the system's flexibility and adaptability. By triggering and executing pre-set scripts, the system can automatically handle abnormal situations and take corresponding measures, thereby improving the system's stability and reliability. Simultaneously, the system can also make intelligent decisions and controls based on real-time data and cumulative effects, reducing the risk of human intervention and misoperation.

[0120] Obviously, those skilled in the art can make various modifications and variations to this invention without departing from its spirit and scope. Therefore, if these modifications and variations fall within the scope of the claims of this invention and their equivalents, this invention also intends to include these modifications and variations.

Claims

1. A method for linking numerical values ​​and scripts based on HMI, characterized in that, The method includes: S1. Obtain the data read by the HMI from the PLC controller, associate the preset script with the data read and the elements of the HMI respectively, mark the data read with a first-level trigger according to the preset running threshold, trigger the preset script, and obtain the initial linkage control interface. S2. Perform cumulative monitoring of changes in the read data, associate the acquired cumulative monitoring data with the preset script, perform cumulative triggering annotation on the read data according to the preset cumulative threshold, perform cumulative triggering on the preset script, obtain the cumulative linkage control interface, and then obtain the update interface. S3. Calculate the update quality value of the updated interface and determine whether to re-update the updated interface. Wherein, S2 includes: For each type of read data, cumulative changes are monitored to obtain cumulative monitoring data; The cumulative monitoring data is preprocessed to obtain cumulative monitoring data for multiple types of read data; the cumulative monitoring data for multiple types of read data is then associated with preset scripts to obtain cumulative data associations. By using a preset cumulative threshold, the cumulative monitoring data of the multiple types of read data is cumulatively triggered to obtain cumulative trigger labels; The step of cumulatively triggering the cumulative monitoring data of the multiple types of read data by using a preset cumulative threshold to obtain a cumulative trigger label includes: The cumulative monitoring data for each category is compared with the cumulative threshold for the corresponding category in the preset cumulative threshold. When the cumulative monitoring data of the read data exceeds the cumulative threshold of the corresponding category in the preset cumulative threshold, the cumulative monitoring data of the read data is cumulatively triggered and labeled. When the read data does not exceed the cumulative threshold of its corresponding category in the preset cumulative threshold, the read data will not be cumulatively triggered and labeled. The preset script corresponding to the read data in the data association is triggered cumulatively according to the cumulative trigger annotation. The preset script is executed according to the cumulative monitoring data of the read data to obtain the cumulative linkage control interface, and then obtain the update interface.

2. The method for linking numerical values ​​and scripts based on HMI according to claim 1, characterized in that, S1 includes: Connect the HMI to the PLC controller to obtain the group of linked devices; The real-time data of the PLC controller is read through the linked equipment group to obtain the read data; The read data is preprocessed to obtain preprocessed read data; The preprocessed read data is classified according to data type to obtain multiple types of read data; The various types of read data are associated with preset scripts respectively to obtain data associations; Associate the preset scripts with the elements of the HMI separately to obtain multiple element associations; By setting a preset running threshold, the multiple types of read data are marked with a first-level trigger, and a preset script is triggered.

3. The method for linking numerical values ​​and scripts based on HMI according to claim 2, characterized in that, The step of marking multiple types of read data with primary triggers based on preset operating thresholds, and triggering preset scripts, includes: The data read for each category is compared with the corresponding category's running threshold in the preset running threshold. When the read data exceeds the corresponding running threshold in the preset running threshold, the read data is marked with a first-level trigger. When the read data does not exceed the corresponding running threshold in the preset running threshold, no first-level trigger label is applied to the read data; The preset script corresponding to the read data in the data association is triggered according to the first-level trigger label. The preset script is executed according to the read data to form the initial linkage control interface.

4. The method for linking numerical values ​​and scripts based on HMI according to claim 3, characterized in that, The step of triggering a preset script corresponding to the read data in the data association based on the first-level trigger label, and executing the preset script according to the read data to form an initial linkage control interface, includes: When the PLC controller recognizes a first-level trigger label, it triggers the preset script corresponding to the first-level trigger label. The preset script executes the control of the corresponding element in the element association to obtain the control interface of the first-level trigger label for each category; Multiple types of primary trigger labels form the initial linkage control interface.

5. The method for linking numerical values ​​and scripts based on HMI according to claim 4, characterized in that, The step involves cumulatively triggering a preset script corresponding to the read data in the data association based on the cumulative trigger annotation. The preset script is executed based on the cumulative monitoring data of the read data to obtain a cumulative linkage control interface, and then to obtain an update interface, including: When the PLC controller recognizes the cumulative trigger mark, it triggers the preset script corresponding to the cumulative trigger mark; The preset script executes the control of the corresponding element in the element association to obtain the control interface of the cumulative trigger annotation for each type; The control interfaces for multiple types of cumulative trigger labels form a cumulative linkage control interface; The initial linkage control interface is updated by using the cumulative linkage control interface to obtain the updated interface.

6. The method for linking numerical values ​​and scripts based on HMI according to claim 1, characterized in that, S3 includes: Calculate the update quality value of the updated interface and compare the update quality value with a preset quality threshold; When the updated quality value is greater than the preset quality threshold, the update of the interface is stopped. When the updated quality value is less than or equal to a preset quality threshold, the updated interface is re-updated until the updated quality value is greater than the preset quality threshold.

7. The method for linking numerical values ​​and scripts based on HMI according to claim 6, characterized in that, The updated quality values ​​include: The formula for calculating the updated quality value is: Among them, f gz To update the quality value, L represents the type of data read, and Δe dhi For the cumulative monitoring data of the i-th type of data reading after the update, Δe yi Let Δe be the cumulative threshold for the i-th type of data read. dQi For the cumulative monitoring data of the i-th type of data reading before the update, c dhi For the updated i-th type of data read, c yi Let c be the operating threshold for the i-th type of data reading. dQi This refers to the i-th type of data read before the update.

8. A numerical and script linkage system based on HMI, characterized in that, The system includes: The initial trigger linkage module is used to acquire the data read by the HMI from the PLC controller, associate the preset script with the data read and the elements of the HMI respectively, mark the data read with a first-level trigger according to the preset running threshold, trigger the preset script, and obtain the initial linkage control interface. The cumulative trigger linkage module is used to monitor changes in the read data, associate the acquired cumulative monitoring data with a preset script, mark the read data for cumulative triggering according to a preset cumulative threshold, trigger the preset script cumulatively, obtain the cumulative linkage control interface, and then obtain the update interface. The update judgment module is used to calculate the update quality value of the updated interface and determine whether to re-update the updated interface. The cumulative trigger linkage module includes: For each type of read data, cumulative changes are monitored to obtain cumulative monitoring data; The cumulative monitoring data is preprocessed to obtain preprocessed cumulative monitoring data of multiple types of read data; The cumulative monitoring data of the multiple types of read data are associated with preset scripts respectively to obtain cumulative data association; By using a preset cumulative threshold, the cumulative monitoring data of the multiple types of read data is cumulatively triggered to obtain cumulative trigger labels; The step of cumulatively triggering the cumulative monitoring data of the multiple types of read data by using a preset cumulative threshold to obtain a cumulative trigger label includes: The cumulative monitoring data for each category is compared with the cumulative threshold for the corresponding category in the preset cumulative threshold. When the cumulative monitoring data of the read data exceeds the cumulative threshold of the corresponding category in the preset cumulative threshold, the cumulative monitoring data of the read data is cumulatively triggered and labeled. When the read data does not exceed the cumulative threshold of its corresponding category in the preset cumulative threshold, the read data will not be cumulatively triggered and labeled. The preset script corresponding to the read data in the data association is triggered cumulatively according to the cumulative trigger annotation. The preset script is executed according to the cumulative monitoring data of the read data to obtain the cumulative linkage control interface, and then obtain the update interface.