Data acquisition method, device, electronic device and non-volatile storage medium

By analyzing and converting the first-digit data packet, using a custom communication protocol to transmit data to the data server, it solves the complex configuration and cross-platform communication problems of the control system when accessing a third-party system, and improves data acquisition efficiency and real-time performance .

CN115412601BActive Publication Date: 2024-11-19SUPCON TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202211033196.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-08-26
Publication Date
2024-11-19
Estimated Expiration
2042-08-26

AI Technical Summary

Technical Problem

In the prior art, the control system needs complex configuration when accessing third-party system data, and cannot realize cross-platform real-time communication, resulting in low efficiency in obtaining third-party data.

Method used

By obtaining the first digit data packet for analysis, using mapping rules to convert the first digit data into the second digit data, and transmitting the data to the data server through a custom communication protocol, realizing the third-party distributed control system data Seamless access.

Benefits of technology

It solves the complex configuration and cross-platform communication problems when the control system accesses third-party system data, improves the efficiency of third-party data acquisition, and realizes seamless access to real-time communication and data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115412601B_ABST
    Figure CN115412601B_ABST
Patent Text Reader

Abstract

The present application discloses a data acquisition method, device, electronic device and non-volatile storage medium. The method includes: obtaining a first bit data packet for parsing to obtain first bit data, wherein the first bit data packet includes encapsulated first bit data, and the first bit data includes: check code, data length, bit name, real-time value; according to the mapping rule and bit name, the first bit data is converted into the corresponding second bit data, wherein the first bit data and the second bit data are bit data in different control systems; the second bit data corresponding to the subscription list is sent to the target terminal for display, wherein the subscription list includes the bit name of the second bit data for which the data subscription request is received. The present application solves the technical problem of low efficiency in acquiring third-party data due to the fact that complex configuration is often required when the current control system accesses third-party system data, and real-time communication cannot be carried out across platforms.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of industrial automation technology, and in particular to a data acquisition method, device, electronic device and non-volatile storage medium. Background Art

[0002] With the rapid development of new technologies such as computer science and industrial control, computer monitoring systems have developed from early centralized monitoring to fully distributed direction. At the same time, with the maturity of object-oriented technology, distributed object technology, and multi-level client / server (Client / Server) technology, computer monitoring system software has also developed from early function-oriented systems to object-oriented computer monitoring systems characterized by being oriented to specific field equipment.

[0003] Data and information are the basis of Distributed Control System (DCS) supervisory control. They come not only from the DCS field control layer, but also from the equipment and software of third-party systems. However, in the existing technology, complex configuration is often required when accessing third-party system data, and cross-platform real-time communication between different systems cannot be achieved. In addition, there is a lot of repetitive work in the parameter configuration process, resulting in low efficiency in obtaining third-party data.

[0004] To address the above-mentioned problems, no effective solution has been proposed yet. Summary of the invention

[0005] The embodiments of the present application provide a data acquisition method, device, electronic device and non-volatile storage medium to at least solve the technical problem of low efficiency in third-party data acquisition caused by the fact that complex configuration is often required when the current control system accesses third-party system data and real-time communication cannot be carried out across platforms.

[0006] According to one aspect of an embodiment of the present application, a data acquisition method is provided, including: acquiring a first bit number data packet for parsing to obtain first bit number data, wherein the first bit number data packet includes encapsulated first bit number data, and the first bit number data includes: a check code, data length, a bit number name, and a real-time value; converting the first bit number data into corresponding second bit number data according to a mapping rule and a bit number name, wherein the mapping rule is used to indicate a correspondence between the first bit number data and the second bit number data, and the first bit number data and the second bit number data are bit number data in different control systems; sending the second bit number data corresponding to a subscription list to a target terminal for display, wherein the subscription list includes the bit number name of the second bit number data for which a data subscription request is received.

[0007] Optionally, converting the first bit number data into corresponding second bit number data based on the mapping rules and the bit number name includes: determining the mapping rules, wherein the mapping rules include: the first bit number name, and the second bit number name corresponding thereto, wherein the first bit number name is used to identify the first bit number data, and the second bit number name is used to identify the second bit number data; matching the first bit number name in the mapping rule that is consistent with the bit number name of the first bit number data to obtain the second bit number name corresponding thereto; converting the first bit number data into corresponding second bit number data based on the second bit number name.

[0008] Optionally, obtaining the first number data packet for parsing to obtain the first number data includes: verifying the check code and data length of the first number data encapsulated in the first number data packet; when the check code and data length meet the preset check rules, parsing to obtain the first number data in the first number data packet; when the check code and data length do not meet the preset check rules, deleting the first number data encapsulated in the first number data packet.

[0009] Optionally, obtaining the first numbered data packet for parsing also includes: in the case where there are multiple first numbered data packets, detecting whether the Internet Protocol address of the first numbered data packet is consistent with the Internet Protocol address sent when sending the request to obtain the first numbered data packet; in the case where the Internet Protocol address of the first numbered data packet is consistent with the Internet Protocol address sent when sending the request to obtain the first numbered data packet, detecting the sequence number of the first numbered data packet, and in the case where there are multiple first numbered data packets with the same sequence number, retaining one first numbered data packet with the same sequence number and deleting the remaining first numbered data packets with the same sequence number, wherein the sequence number is used to identify the first numbered data packet; in the case where the Internet Protocol address of the first numbered data packet is inconsistent with the Internet Protocol address sent when sending the request to obtain the first numbered data packet, deleting the first numbered data packet.

[0010] Optionally, sending the second-numbered data corresponding to the subscription list to the target terminal for display includes: receiving a data subscription request sent by the target terminal, determining a subscription list, the subscription list including the second-numbered name of the second-numbered data received in the data subscription request, wherein the second-numbered name is used to identify the second-numbered data; based on the second-numbered name in the subscription list, extracting the corresponding second-numbered data, and updating the second-numbered data to the target terminal for display.

[0011] Optionally, after converting the first bit number data into the corresponding second bit number data according to the mapping rules and the bit number name, it also includes: performing data processing on the second bit number data according to a preset processing rule, and judging whether the operating status of the field equipment corresponding to the second bit number data is normal based on the processed second bit number data, wherein the data processing includes: arithmetic operations and logical operations, and the field equipment corresponding to the second bit number data is the equipment in the production site that provides the first bit number data converted into the second bit number data.

[0012] Optionally, the preset processing rules include a preset threshold range, and the second bit number data is processed according to the preset processing rules, and based on the processed second bit number data, it is judged whether the operating status of the on-site equipment corresponding to the second bit number data is normal, including: when the second bit number data exceeds the preset threshold range, it is judged that the operating status of the on-site equipment corresponding to the second bit number data is abnormal, and an alarm message is sent.

[0013] According to another aspect of the embodiment of the present application, a data acquisition device is also provided, including: a data sampling module, used to acquire a first bit number data packet for parsing to obtain a first bit number data, wherein the first bit number data packet includes encapsulated first bit number data, and each encapsulated first bit number data in the first bit number data packet includes: a check code, data length, bit number name, and real-time value; a data conversion module, used to convert the first bit number data into corresponding second bit number data according to a mapping rule and a bit number name, wherein the mapping rule is used to indicate the correspondence between the first bit number data and the second bit number data, and the first bit number data and the second bit number data are bit number data in different control systems; a data sending module, used to send the second bit number data corresponding to a subscription list to a target terminal for display, wherein the subscription list includes the bit number name of the second bit number data for which a data subscription request is received.

[0014] According to another aspect of the embodiments of the present application, an electronic device is provided. The electronic device includes a processor, and the processor is used to run a program, wherein the data acquisition method is executed when the program is run.

[0015] According to another aspect of the embodiments of the present application, a non-volatile storage medium is provided. The non-volatile storage medium includes a stored program, wherein when the program is running, a device where the non-volatile storage medium is located is controlled to execute a data acquisition method.

[0016] In an embodiment of the present application, a first bit number data packet is obtained for parsing to obtain first bit number data, wherein the first bit number data packet includes encapsulated first bit number data, and the first bit number data includes: a check code, data length, a bit number name, and a real-time value; according to a mapping rule and a bit number name, the first bit number data is converted into corresponding second bit number data, wherein the mapping rule is used to represent the correspondence between the first bit number data and the second bit number data, and the first bit number data and the second bit number data are bit number data in different control systems; the second bit number data corresponding to the subscription list is sent to the target terminal for display, wherein the subscription list includes the bit number name of the second bit number data for which the data subscription request is received, by obtaining data from a third-party system and using a custom communication protocol to transmit the data to a data server for data parsing and conversion, the purpose of seamless access to data of a third-party distributed control system is achieved, thereby solving the technical problem of low efficiency in acquiring third-party data due to the fact that complex configuration is often required when the current control system accesses third-party system data, and real-time communication cannot be performed across platforms. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:

[0018] Figure 1 It is a schematic diagram of a method flow for data acquisition provided according to an embodiment of the present application;

[0019] Figure 2 It is a schematic diagram of a third-party control system data access method process provided according to an embodiment of the present application;

[0020] Figure 3 is a structural schematic diagram of a data acquisition device provided according to an embodiment of the present invention;

[0021] Figure 4 It is a hardware structure block diagram of a computer terminal (or electronic device) for implementing a method for data acquisition provided in an embodiment of the present application. DETAILED DESCRIPTION

[0022] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present application.

[0023] In order to facilitate those skilled in the art to better understand the embodiments of the present application, some technical terms or nouns involved in the embodiments of the present application are explained as follows:

[0024] Distributed Control System (DCS): Distributed control system is a new generation of instrument control system based on microprocessors, which adopts the design principles of decentralized control functions, centralized display operations, and taking into account both division and autonomy and comprehensive coordination.

[0025] OLE for Process Control (OPC): is an interoperability standard for secure data exchange in the automation industry and other industries.

[0026] Transmission Control Protocol (TCP): a connection-oriented, reliable, byte-stream-based transport layer communication protocol.

[0027] Microsoft Distributed Component Object Model (DCOM): is a series of Microsoft concepts and program interfaces.

[0028] Application Programming Interface (API): It is the agreement for connecting different components of a software system.

[0029] Internet Protocol (IP): It is the network layer protocol in the TCP / IP system.

[0030] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0031] Example 1

[0032] In the prior art, when the control system accesses third-party system data, OPC can only transmit partial attribute data of the bit number and the efficiency is low. It cannot meet the needs of real-time communication, and the data does not support redundant switching; complex DCOM-related configuration is required, and cross-platform communication cannot be supported.

[0033] In order to solve the above problems, according to an embodiment of the present application, a method embodiment of data acquisition is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0034] Figure 1 is a schematic diagram of a data acquisition method flow according to an embodiment of the present application, such as Figure 1 As shown, the method comprises the following steps:

[0035] Step S102, obtaining the first number data packet and parsing it to obtain the first number data, wherein the first number data packet includes the encapsulated first number data, and the first number data includes: a check code, a data length, a bit number name, and a real-time value;

[0036] In some embodiments of the present application, obtaining the first number data packet for parsing to obtain the first number data includes: verifying the check code and data length of the first number data encapsulated in the first number data packet; when the check code and the data length meet the preset check rules, parsing to obtain the first number data in the first number data packet; when the check code and the data length do not meet the preset check rules, deleting the first number data encapsulated in the first number data packet.

[0037] In this embodiment, the first bit number data is the IA bit number, wherein the IA bit number is the bit number data in the distributed control system of the first company. The first bit number data packet is a data packet obtained by encapsulating the IA bit number data through a custom TCP communication protocol.

[0038] Specifically, IA data is sent to the data server through a custom protocol, and the length of the data packet is specified, and the length of each data packet does not exceed 1024 bytes; the data protocol mainly consists of check code, length, bit number name, real-time value, data type, status code, time and other information.

[0039] In some embodiments of the present application, obtaining the first numbered data packet for parsing also includes: in the case where there are multiple first numbered data packets, detecting whether the Internet Protocol address of the first numbered data packet is consistent with the Internet Protocol address sent when the request to obtain the first numbered data packet is sent; in the case where the Internet Protocol address of the first numbered data packet is consistent with the Internet Protocol address sent when the request to obtain the first numbered data packet is sent, detecting the sequence number of the first numbered data packet, and in the case where there are multiple first numbered data packets with the same sequence number, retaining one first numbered data packet with the same sequence number and deleting the remaining first numbered data packets with the same sequence number, wherein the sequence number is used to identify the first numbered data packet; in the case where the Internet Protocol address of the first numbered data packet is inconsistent with the Internet Protocol address sent when the request to obtain the first numbered data packet is sent, deleting the first numbered data packet.

[0040] In this embodiment, the Internet Protocol address is an IP address.

[0041] Specifically, since the data collector itself and the network are redundant, the IA data driver will receive multiple copies of the same data; first, determine whether the IP address of the data source is consistent with the IP address to be processed. If not, discard the entire data packet; then remove the identical data based on whether the sequence numbers in the data packets are the same, ensuring that only one copy of the data is processed, which not only ensures data reliability but also improves data processing efficiency.

[0042] Step S104, converting the first bit data into corresponding second bit data according to a mapping rule and a bit name, wherein the mapping rule is used to indicate a corresponding relationship between the first bit data and the second bit data, and the first bit data and the second bit data are bit data in different control systems;

[0043] In some embodiments of the present application, converting a first bit number data into corresponding second bit number data based on a mapping rule and a bit number name includes: determining a mapping rule, wherein the mapping rule includes: a first bit number name, and a second bit number name corresponding thereto, wherein the first bit number name is used to identify the first bit number data, and the second bit number name is used to identify the second bit number data; matching the first bit number name in the mapping rule that is consistent with the bit number name of the first bit number data to obtain the second bit number name corresponding thereto; converting the first bit number data into corresponding second bit number data based on the second bit number name.

[0044] In this embodiment, the second bit number data is VF bit number data, wherein the VF bit number is bit number data in the distributed control system of the second company, and the mapping rule is an association mapping table.

[0045] In some embodiments of the present application, after converting the first bit number data into the corresponding second bit number data according to the mapping rules and the bit number name, it also includes: performing data processing on the second bit number data according to a preset processing rule, and judging whether the operating status of the field equipment corresponding to the second bit number data is normal based on the processed second bit number data, wherein the data processing includes: arithmetic operations and logical operations, and the field equipment corresponding to the second bit number data is the equipment in the production site that provides the first bit number data converted into the second bit number data.

[0046] In some embodiments of the present application, the preset processing rules include a preset threshold range, and the second bit number data is processed according to the preset processing rules, and based on the processed second bit number data, it is judged whether the operating status of the field equipment corresponding to the second bit number data is normal, including: when the second bit number data exceeds the preset threshold range, it is judged that the operating status of the field equipment corresponding to the second bit number data is abnormal, and an alarm message is sent.

[0047] Specifically, the converted data is subjected to numerical comparison operation according to the pre-set alarm limit (i.e. the preset threshold range mentioned above) to generate a corresponding alarm. The specific limit or range may exist, depending on the configuration, and the subsequent logical operation is numerical comparison. For complex operations requiring the participation of multiple bit numbers, arithmetic and logical operations are performed through the function block library encapsulated in the performance calculation service (i.e. the preset processing rules mentioned above). Sometimes, data of multiple bit numbers are required as input conditions, and logical operations of AND or NOT are performed to obtain a result.

[0048] Step S106, sending the second bit number data corresponding to the subscription list to the target terminal for display, wherein the subscription list includes the bit number name of the second bit number data for which the data subscription request is received.

[0049] In some embodiments of the present application, sending second-number data corresponding to a subscription list to a target terminal for display includes: receiving a data subscription request sent by the target terminal, determining a subscription list, the subscription list including the second-number name of the second-number data received in the data subscription request, wherein the second-number name is used to identify the second-number data; based on the second-number name in the subscription list, extracting the corresponding second-number data, and updating the second-number data to the target terminal for display.

[0050] The data acquisition method in steps S102 to S106 of the embodiment of the present application is further introduced below.

[0051] Figure 2 is a schematic diagram of a third-party control system data access method process provided according to an embodiment of the present application, such as Figure 2 As shown, the method comprises the following steps:

[0052] Step S202, determine the mapping configuration and establish a connection.

[0053] Specifically, an association mapping configuration between the IA bit number and the domain variable bit number (ie, the VF bit number) is constructed; the VF client establishes a connection with the VF data server to obtain the domain variable bit number information from the server; and subscribes to the domain variable bit number data from the data server.

[0054] Step S204: collect IA data and send it to a data server.

[0055] Specifically, the data collector loads configuration information to build an association mapping table between IA bit numbers and VF bit numbers; uses the original API interface to obtain IA bit number data. In this embodiment, data is collected once every 500m by default, and the data sampling period can be adjusted as needed;

[0056] The data collector sends IA data to the data server through a custom protocol, specifying the length of the data packet, and each data packet length does not exceed 1024 bytes; the data protocol mainly consists of check code, length, bit number name, real-time value, data type, status code, time and other information;

[0057] In this embodiment, the data sampling frequency can be set according to different requirements. The use of a custom protocol can support the transmission of more information. At the same time, the method is simple to arrange and can perform data communication without passing through a platform. It saves costs and has higher economic benefits.

[0058] Step S206, parsing the IA data and converting it into VF data.

[0059] Specifically, the data server receives and parses IA data by loading the IA data driver; the IA data driver performs a validity check on the length and check code of the data packet, and removes the illegal data when the data length is inconsistent with the length in the data packet or the check code is inconsistent.

[0060] In this embodiment, the data collector itself and the network are redundant, and the IA data driver will receive multiple copies of the same data. First, it is determined whether the IP address of the data source is consistent with the IP address to be processed. If not, the entire data packet is discarded. Then, the same data is removed based on whether the sequence numbers in the data packets are the same, ensuring that only one copy of the data is processed, which not only ensures data reliability but also improves data processing efficiency.

[0061] Specifically, the IA driver converts the IA bit number data into the VF bit number data according to the bit number name and data type in the data packet through the association mapping table between the IA bit number and the VF bit number;

[0062] In addition, the converted data is compared with the preset alarm limit value to generate the corresponding alarm. The specific limit value or range may exist, depending on the configuration. The subsequent logic operation is to compare the value. For complex operations that require multiple bit numbers to participate, arithmetic and logic operations are performed through the function block library encapsulated in the performance calculation service. Sometimes, data of multiple bit numbers are required as input conditions to perform AND or NOT logic operations to obtain a result.

[0063] In this embodiment, the data server synchronizes the changed data to the client in real time according to the subscription list, maintaining the consistency of the data in the entire system; at the same time, to enhance the stability of the system, the data servers in the VF system are redundant. When one of them fails, the domain name server will notify the client to connect to another server, ensuring that the system can still work normally when a single server fails.

[0064] Through the above steps, data from the third-party system is obtained, and the custom communication protocol is used to transmit the data to the data server for data analysis and conversion, thereby achieving the purpose of seamless access to third-party distributed control system data, thereby solving the technical problem of low efficiency in third-party data acquisition caused by the fact that the current control system often needs to perform complex configuration when accessing third-party system data and cannot communicate in real time across platforms.

[0065] Example 2

[0066] According to an embodiment of the present invention, an embodiment of a data acquisition device is also provided. Figure 3 is a schematic diagram of the structure of a data acquisition device provided according to an embodiment of the present invention. Figure 3 As shown, the device comprises:

[0067] The data sampling module 30 is used to obtain the first number data packet for parsing to obtain the first number data, wherein the first number data packet includes the encapsulated first number data, and each encapsulated first number data in the first number data packet includes: a check code, a data length, a bit number name, and a real-time value;

[0068] The data conversion module 32 is used to convert the first bit data into the corresponding second bit data according to the mapping rule and the bit name, wherein the mapping rule is used to indicate the corresponding relationship between the first bit data and the second bit data, and the first bit data and the second bit data are bit data in different control systems;

[0069] The data sending module 34 is used to send the second bit number data corresponding to the subscription list to the target terminal for display, wherein the subscription list includes the bit number name of the second bit number data for which the data subscription request is received.

[0070] It should be noted that the data acquisition device provided in this embodiment can be used to execute Figure 1 The data acquisition method shown, therefore, the relevant explanations and instructions on the above data acquisition method are also applicable to the embodiments of the present application and will not be repeated here.

[0071] According to an embodiment of the present invention, an embodiment of a computer terminal for implementing the method for acquiring data is also provided. Figure 4 FIG. 1 is a hardware structure block diagram of a computer terminal (or electronic device) for implementing a method for acquiring data according to an embodiment of the present invention. Figure 4 As shown, the computer terminal 40 (or electronic device 40) may include one or more (402a, 402b, ..., 402n are used to illustrate) processors (the processor may include but is not limited to a processing device such as a microprocessor MCU or a programmable logic device FPGA), a memory 404 for storing data, and a transmission module 406 for communication functions. In addition, it may also include: a display, an input / output interface (I / O interface), a universal serial bus (USB) port (which may be included as one of the ports of the I / O interface), a network interface, a power supply and / or a camera. It can be understood by those skilled in the art that Figure 4 The structure shown is only for illustration and does not limit the structure of the above electronic device. Figure 4 More or fewer components as shown, or with Figure 4 Different configurations are shown.

[0072] It should be noted that the one or more processors and / or other data processing circuits described above may generally be referred to herein as "data processing circuits". The data processing circuits may be embodied in whole or in part as software, hardware, firmware, or any other combination thereof. In addition, the data processing circuit may be a single independent processing module, or may be incorporated in whole or in part into any of the other components in the computer terminal 40 (or electronic device). As involved in the embodiments of the present application, the data processing circuit acts as a processor control (e.g., selection of a variable resistor terminal path connected to an interface).

[0073] The memory 404 can be used to store software programs and modules of application software, such as program instructions / data storage devices corresponding to the method for data acquisition in the embodiment of the present application. The processor executes various functional applications and data processing by running the software programs and modules stored in the memory 404, that is, realizing the above-mentioned method for data acquisition. The memory 404 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 404 may further include a memory remotely arranged relative to the processor, and these remote memories may be connected to the computer terminal 40 via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0074] The transmission module 406 is used to receive or send data via a network. The specific example of the above network may include a wireless network provided by a communication provider of the computer terminal 40. In one example, the transmission device 406 includes a network adapter (Network Interface Controller, NIC), which can be connected to other network devices through a base station so as to communicate with the Internet. In one example, the transmission device 406 can be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.

[0075] The display may be, for example, a touch screen liquid crystal display (LCD) that enables a user to interact with a user interface of the computer terminal 40 (or electronic device).

[0076] It should be noted that, in some optional embodiments, the above Figure 4 The computer device (or electronic device) shown may include hardware elements (including circuits), software elements (including computer code stored on a computer-readable medium), or a combination of hardware elements and software elements. It should be noted that Figure 4 This is merely one example of a particular embodiment and is intended to illustrate the types of components that may be present in the above-described computer device (or electronic device).

[0077] It should be noted that Figure 4 The data acquisition electronic device shown is used to perform Figure 1 The method for data acquisition shown in the figure, therefore the relevant explanations in the above data acquisition method are also applicable to the electronic device for data acquisition, and will not be repeated here.

[0078] According to an embodiment of the present application, an embodiment of a non-volatile storage medium is also provided, and the non-volatile storage medium includes a stored program, wherein when the program is running, the device where the non-volatile storage medium is located is controlled to execute the following data acquisition method: obtain a first bit number data packet for parsing to obtain a first bit number data, wherein the first bit number data packet includes the encapsulated first bit number data, and the first bit number data includes: a check code, a data length, a bit number name, and a real-time value; according to a mapping rule and a bit number name, the first bit number data is converted into corresponding second bit number data, wherein the mapping rule is used to indicate the correspondence between the first bit number data and the second bit number data, and the first bit number data and the second bit number data are bit number data in different control systems; the second bit number data corresponding to the subscription list is sent to the target terminal for display, wherein the subscription list includes the bit number name of the second bit number data for which the data subscription request is received.

[0079] The serial numbers of the above-mentioned embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.

[0080] In the above embodiments of the present application, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, please refer to the relevant description of other embodiments.

[0081] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the units can be a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.

[0082] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple units. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.

[0083] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0084] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, in essence, or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, disk or optical disk and other media that can store program codes.

[0085] The above is only a preferred implementation of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.

Claims

1. A data acquisition method, characterized in that: include: Obtain a first bit number data packet for parsing to obtain first bit number data, wherein the first bit number data packet includes the encapsulated first bit number data, and the first bit number data includes: a check code, a data length, a bit number name, and a real-time value; In the case where there are multiple data packets with the first bit number, detecting whether the Internet Protocol address of the data packet with the first bit number is consistent with the Internet Protocol address sent when sending the request for obtaining the data packet with the first bit number; In the case where the Internet Protocol address of the first numbered data packet is consistent with the Internet Protocol address sent when sending the request to obtain the first numbered data packet, detecting the sequence number of the first numbered data packet, and in the case where there are multiple first numbered data packets with the same sequence number, retaining one first numbered data packet with the same sequence number, and deleting the other first numbered data packets with the same sequence number, wherein the sequence number is used to identify the first numbered data packet; In the case where the Internet Protocol address of the first bit data packet is inconsistent with the Internet Protocol address sent when sending the request to obtain the first bit data packet, deleting the first bit data packet; converting the first bit data into corresponding second bit data according to a mapping rule and the bit name, wherein the mapping rule is used to indicate the corresponding relationship between the first bit data and the second bit data, and the first bit data and the second bit data are bit data in different control systems; The second bit number data corresponding to the subscription list is sent to the target terminal for display, wherein the subscription list includes the bit number name of the second bit number data for which the data subscription request is received.

2. The data acquisition method according to claim 1, characterized in that: According to the mapping rule and the bit number name, converting the first bit number data into corresponding second bit number data includes: Determine the mapping rule, wherein the mapping rule includes: a first bit name and a second bit name corresponding thereto, wherein the first bit name is used to identify the first bit data, and the second bit name is used to identify the second bit data; Match the first bit number name in the mapping rule that is consistent with the bit number name of the first bit number data to obtain the second bit number name corresponding thereto; According to the second bit number name, the first bit number data is converted into the corresponding second bit number data.

3. The data acquisition method according to claim 1, characterized in that: Get the first number data packet for parsing, and get the first number data including: Verify the check code and the data length of the first-numbered data encapsulated in the first-numbered data packet; When the check code and the data length meet the preset check rule, parse and obtain the first bit number data in the first bit number data packet; When the check code and the data length do not conform to a preset check rule, the encapsulated first bit number data in the first bit number data packet is deleted.

4. The data acquisition method according to claim 1, characterized in that: Sending the second number data corresponding to the subscription list to the target terminal for display includes: receiving a data subscription request sent by the target terminal, and determining the subscription list, wherein the subscription list includes a second bit number name of the second bit number data for which the data subscription request is received, wherein the second bit number name is used to identify the second bit number data; According to the second bit number name in the subscription list, the corresponding second bit number data is extracted, and the second bit number data is updated to the target terminal for display.

5. The data acquisition method according to claim 1, characterized in that: After converting the first bit number data into corresponding second bit number data according to the mapping rule and the bit number name, the method further includes: According to preset processing rules, the second bit number data is processed, and based on the processed second bit number data, it is judged whether the operating status of the field equipment corresponding to the second bit number data is normal, wherein the data processing includes: arithmetic operations and logical operations, and the field equipment corresponding to the second bit number data is the equipment in the production site that provides the first bit number data converted into the second bit number data.

6. The data acquisition method according to claim 5, characterized in that: The preset processing rule includes a preset threshold range, and according to the preset processing rule, the second bit number data is processed, and according to the processed second bit number data, whether the operation state of the field device corresponding to the second bit number data is normal is determined, including: When the second bit number data exceeds the preset threshold range, it is determined that the operating state of the field device corresponding to the second bit number data is abnormal, and an alarm message is sent.

7. A data sampling device, characterized in that: include: A data sampling module is used to obtain a first bit number data packet for parsing to obtain first bit number data, wherein the first bit number data packet includes the first bit number data after encapsulation, and each piece of the first bit number data after encapsulation in the first bit number data packet includes: a check code, a data length, a bit number name, and a real-time value; In the case where there are multiple data packets with the first bit number, detecting whether the Internet Protocol address of the data packet with the first bit number is consistent with the Internet Protocol address sent when sending the request for obtaining the data packet with the first bit number; In the case where the Internet Protocol address of the first numbered data packet is consistent with the Internet Protocol address sent when sending the request to obtain the first numbered data packet, detecting the sequence number of the first numbered data packet, and in the case where there are multiple first numbered data packets with the same sequence number, retaining one first numbered data packet with the same sequence number, and deleting the other first numbered data packets with the same sequence number, wherein the sequence number is used to identify the first numbered data packet; In the case where the Internet Protocol address of the first numbered data packet is inconsistent with the Internet Protocol address sent when sending the request to obtain the first numbered data packet, deleting the first numbered data packet; A data conversion module, used for converting the first bit number data into corresponding second bit number data according to a mapping rule and the bit number name, wherein the mapping rule is used to indicate a corresponding relationship between the first bit number data and the second bit number data, and the first bit number data and the second bit number data are bit number data in different control systems; The data sending module is used to send the second bit number data corresponding to the subscription list to the target terminal for display, wherein the subscription list includes the bit number name of the second bit number data for which the data subscription request is received.

8. An electronic device, comprising a processor, characterized in that: The processor is used to run a program, wherein the program executes the data acquisition method according to any one of claims 1 to 6 when running.

9. A non-volatile storage medium, characterized in that: The non-volatile storage medium includes a stored program, wherein when the program is executed, the device where the non-volatile storage medium is located is controlled to execute the data acquisition method according to any one of claims 1 to 6.