A method and system for analyzing the status of a script device, a storage medium, and a computing device

By using the Script script language to analyze the device state, the problem of complex and time-consuming acquisition of device state in the prior art is solved, and the effect of simplifying configuration, improving efficiency and performance is achieved.

CN114356709BActive Publication Date: 2025-05-30XCMG HANYUN TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111671234.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-31
Publication Date
2025-05-30
Estimated Expiration
2041-12-31

AI Technical Summary

Technical Problem

When obtaining the device status, the prior art requires multiple parameter configurations and complex operator operations and logical operations, which leads to a long time, affects the real-timeness of the data, is low in stability, and is high in maintenance costs.

Method used

The device state analysis is performed using the Script script language. By configuring the standard parameters of the device for various states, a standard parameter Script script is generated, real-time parameter packets are dynamically filled, and Script scripts are executed to determine the real-time state of the device.

Benefits of technology

The configuration process is simplified, efficiency is improved, performance is improved, computing process and response time is reduced, maintenance costs are reduced, and the competitiveness of the system is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114356709B_ABST
    Figure CN114356709B_ABST
Patent Text Reader

Abstract

The present invention discloses a method for analyzing the status of a script device: configuring standard parameters for various states of the device; generating a standard parameter script for each state of the device; obtaining a real-time parameter message of the device status, parsing out the message value, and stuffing the message value into the standard parameter script; executing the script with the stuffed message value. If the calculation result is incorrect, then stuff the message value into another standard parameter script of the device and continue to execute; if the calculation result is correct, then determine that the current state is the real-time state of the device. The calculation process is reduced, and there is no longer a need to use complex code for calculation. We only need to generate a standard Script script, dynamically fill parameters into the script, and execute the Script script in the code to return the result we want. It can reduce the response time, reduce latency, and improve the competitiveness of the system in the same field.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of Internet of Things, and particularly relates to a method and system for analyzing the status of script devices, a storage medium, and a computing device. Background Art

[0002] With the rapid development of industrial Internet technology, device networking technology has been widely applied. That is, by using computer hardware, software, network devices, and communication devices, information is collected, transmitted, processed, stored, updated, and maintained to help enterprises manage devices and establish a management system with informatization as the core, which can greatly reduce the data processing burden on management personnel and business personnel and improve device management efficiency.

[0003] The use of the Internet of Things for devices can, in real time, understand the on-site device conditions, production conditions, fault causes, and handling situations through the system screen, and timely control various indicators and performances of production manufacturing devices and products during the production process, which is beneficial to controlling the quality and accuracy of products.

[0004] In the prior art, if one wants to accurately and real-time obtain the device status, multiple parameter configurations, as well as multiple operator operations and logical operations are required. The calculation methods and storage methods are relatively complex. It takes a long time, which to a certain extent affects the real-time nature of the data. Moreover, the stability is also relatively low, and the maintenance cost is relatively high. For the accuracy and rigor of the results, more time is required for testing, which also has a certain impact on the project duration. Therefore, the existing device status calculation methods are very inconvenient.

[0005] Currently, for the status judgment of networked devices, generally, multiple parameters, as well as logical operation relationships and bit operation relationships, need to be set for the devices in advance on the system, and then through layer-by-layer logical processing of the code, the final status of the device can be obtained. Summary of the Invention

[0006] The purpose of the present invention is to overcome the deficiencies in the prior art and provide a method and system for analyzing the status of script devices, a storage medium, and a computing device, which simplifies the configuration, improves the efficiency, is more standardized, has better performance, and has a more flexible implementation method.

[0007] To solve the problems in the prior art, the present invention discloses a method for analyzing the status of script devices:

[0008] Configure the standard parameters of various states of the device;

[0009] Generate a standard parameter script for each state of the device corresponding to the standard parameters;

[0010] Obtain the real-time parameter message of the device status, parse the message value obtained from the real-time parameter message of the device status, and insert the message value into the standard parameter script;

[0011] Execute the script with the inserted message value. If the calculation result is incorrect, insert the message value into another standard parameter script and continue to execute the script; if the calculation result is correct, determine the current status as the real-time status of the device.

[0012] Furthermore, it also includes prioritizing various device statuses.

[0013] Furthermore, if the determination process when the calculation result is correct is as follows: find the currently recorded status of the device, compare the recorded status with the real-time status. If the statuses are the same, it means the device maintains the previous status; if the statuses are different, it means the real-time status of the device has changed, and update the real-time status to the recorded status.

[0014] Correspondingly, a script device status analysis system:

[0015] Device standard parameter configuration module: used to configure the standard parameters of various device statuses;

[0016] Device real-time parameter receiving module: used to receive the real-time parameter message of the device;

[0017] Script device status analysis model: used to generate a standard parameter script for each device status, parse the message value obtained from the real-time parameter message of the device status, insert the message value into the standard parameter script, execute the script with the inserted message value. If the calculation result is incorrect, insert the message value into another standard parameter script and continue to execute the script; if the calculation result is correct, determine the current status as the real-time status of the device.

[0018] Correspondingly, a computer-readable storage medium storing one or more programs, the one or more programs including instructions that, when executed by a computing device, cause the computing device to execute any of the methods described above.

[0019] Correspondingly, a computing device includes:

[0020] One or more processors, one or more memories, and one or more programs, where the one or more programs are stored in the one or more memories and are configured to be executed by the one or more processors, and the one or more programs include instructions for executing any of the methods described above.

[0021] The beneficial effects of the present invention are:

[0022] The present invention is a device status analysis method based on the Script scripting language, which hands over both operator operations and logical operations to the Script script to achieve. It has a fast operation speed, high accuracy, and better performance. The present invention can optimize system configuration, simplify logical processing, reduce the calculation process, and no longer use complex code to perform calculations. We only need to generate a standard Script script, dynamically fill parameters into the script, and execute the Script script in the code to return the results we want. It can greatly reduce the latency of obtaining the device status, and reducing the response time can improve the competitiveness of the system in the same field. Brief Description of the Drawings

[0023] Figure 1 It is a schematic diagram of the device status analysis process according to an embodiment of the present invention. Detailed Embodiment

[0024] The present invention will be further described below with reference to the drawings. The following embodiments are only used to more clearly illustrate the technical solutions of the present invention and cannot be used to limit the protection scope of the present invention.

[0025] As Figure 1 shown, a script device status analysis method of the present invention:

[0026] Configure standard parameters for various states of the device;

[0027] Generate a standard parameter script corresponding to the standard parameters of each state of the device;

[0028] Obtain the real-time parameter message of the device status, parse the message value obtained from the real-time parameter message of the device status, and insert the message value into the standard parameter script;

[0029] Execute the script with the inserted message value. If the calculation result is incorrect, insert the message value into another standard parameter script and continue to execute the script; if the calculation result is correct, determine the current state as the real-time state of the device.

[0030] The specific process is as follows: Set the parameter standard on the interface of the boundary system. After setting, it will judge in the database whether there is already a script generated for this device and state, that is, whether the parameter standard has been set. If so, first clear the historical configuration, then generate a new Script script and save it to the database (the database type is not limited: such as mysql, oracle, etc.). If it has not been generated before, it will be directly saved.

[0031] Obtain the above-mentioned set parameter standards through a scheduled task or a trial-triggered mode, and encapsulate them into a set. Each state of a device will have and only have one piece of Script script data.

[0032] Obtain the real-time message of the device parameter value, which is generally called through an interface. The interface form is not limited and can be ResultFul, webServices, etc. After obtaining the message, data parsing can be performed. The data format can be the common JSON format, or the rules can be defined by both parties with the interface provider. Finally, the message will be parsed into a key-value pair set of parameter real-time values to provide data filling for the script.

[0033] At the same time, perform a custom sorting on the standard parameter set. The purpose of sorting is to optimize the priority of state judgment and have a certain degree of fault tolerance, and it can also reduce the number of state loops. Multiple state standards may be set for the same device, and the key states that need to be focused on can be placed in the front for priority judgment.

[0034] Traverse the standard parameter set to obtain the Script script for each device state. Insert the parsed key-value pair data of the parameter real-time value into the script (message value), and execute the script in the code to obtain a boolean execution result. If the result is false (error), it means that the current state is not the real-time state of the device, and continue to judge the next state setting standard of the device.

[0035] If the above script calculation result is true (correct), it means that the current state is the real-time state of the device. At this time, go to the database to find the current record status of the device, compare the record status with the real-time state. If the status is the same, it means that the device maintains the previous state, and no record needs to be made at this time, and the process ends. If the status is different, it means that the real-time state of the device has changed. At this time, set the queried record status to closed, and then add a new status record. The status of the record is the status when the script execution is true (correct), and the process ends.

[0036] The logic processing of the present invention is mainly based on the Script scripting language, with fast processing speed, standard, safe and good performance, and more flexible processing calculation formulas and logical relationships. We only need to generate the standard Script scripting language, and the configuration method is not limited. Data can be substituted into variables in the Script to return the final result.

[0037] The above are only the preferred embodiments of the present invention. It should be noted that for those of ordinary skill in the art in this technical field, without departing from the technical principle of the present invention, several improvements and deformations can be made, and these improvements and deformations should also be regarded as the protection scope of the present invention.

[0038] A computer-readable storage medium storing one or more programs, the one or more programs including instructions that, when executed by a computing device, cause the computing device to perform a script device state analysis method.

[0039] A computing device includes one or more processors, one or more memories, and one or more programs, where the one or more programs are stored in the one or more memories and configured to be executed by the one or more processors, and the one or more programs include instructions for performing a script device state analysis method.

[0040] Those skilled in the art will understand that the embodiments of the present invention can be provided as a method, a system, or a computer program product. Therefore, the present invention can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present invention can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk memories, CD-ROMs, optical memories, etc.) containing computer-usable program code.

[0041] The present invention is described with reference to the flowcharts and / or block diagrams of methods, apparatuses (systems), and computer program products according to embodiments of the present invention. It should be understood that each flow and / or block in the flowcharts and / or block diagrams, and the combination of flows and / or blocks in the flowcharts and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing devices to produce a machine, such that the instructions executed by the processor of the computer or other programmable data processing devices produce means for implementing the functions specified in Figure 1 one flow or multiple flows and / or blocks Figure 1 one block or multiple blocks.

[0042] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to work in a specific manner, such that the instructions stored in the computer-readable memory produce a manufactured article including instruction means that implement the functions specified in Figure 1 one flow or multiple flows and / or blocks Figure 1 one block or multiple blocks.

[0043] These computer program instructions can also be loaded onto a computer or other programmable data processing apparatus, so that a series of operation steps are executed on the computer or other programmable apparatus to produce a computer-implemented process, thereby providing instructions for implementing the steps specified in one process or a plurality of processes and / or blocks Figure 1 one process or a plurality of processes and / or blocks Figure 1 in one block or a plurality of blocks.

[0044] The above are only embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present invention are included within the scope of the claims of the present invention pending approval of the application.

Claims

1. A method for analyzing the state of a script device, characterized in that: Configure the standard parameters of various states of the device; Generate a standard parameter script for each state of the device corresponding to the standard parameters; Obtain the real-time parameter message of the device state, parse the message value obtained from the real-time parameter message of the device state, and insert the message value into the standard parameter script; Execute the script with the message value inserted. If the calculation result is incorrect, insert the message value into another standard parameter script and continue to execute the script; if the calculation result is correct, determine the current state as the real-time state of the device.

2. A method for analyzing the state of a script device according to claim 1, characterized in that: It also includes sorting the priorities of various states of the device.

3. A method for analyzing the state of a script device according to claim 1, characterized in that: If the determination process when the calculation result is correct is: find the currently recorded state of the device, compare the recorded state with the real-time state. If the states are the same, it means the device maintains the previous state; if the states are different, it means the real-time state of the device has changed, and update the real-time state to the recorded state.

4. A system for analyzing the state of a script device, characterized in that: Device standard parameter configuration module: used to configure the standard parameters of various states of the device; Device real-time parameter receiving module: used to receive the real-time parameter message of the device; Script device state analysis model: used to generate a standard parameter script for each state of the device corresponding to the standard parameters, parse the message value obtained from the real-time parameter message of the device state, insert the message value into the standard parameter script, execute the script with the message value inserted. If the calculation result is incorrect, insert the message value into another standard parameter script and continue to execute the script; if the calculation result is correct, determine the current state as the real-time state of the device.

5. A computer-readable storage medium storing one or more programs, characterized in that: The one or more programs include instructions that, when executed by a computing device, cause the computing device to execute any one of the methods according to claims 1 to 3.

6. A computing device, characterized in that, including: One or more processors, one or more memories, and one or more programs, where the one or more programs are stored in the one or more memories and are configured to be executed by the one or more processors. The one or more programs include instructions for executing any one of the methods according to claims 1 to 3.

Citation Information

Patent Citations

  • Method for monitoring state of sas card hard disk of linux server

    CN105141478A

  • Assessment method of health state of distribution primary device

    CN108009937A