CN116339745A - Method, device, equipment and storage medium for analyzing communication data between equipment - Google Patents

Method, device, equipment and storage medium for analyzing communication data between equipment Download PDF

Info

Publication number
CN116339745A
CN116339745A CN202310326786.5A CN202310326786A CN116339745A CN 116339745 A CN116339745 A CN 116339745A CN 202310326786 A CN202310326786 A CN 202310326786A CN 116339745 A CN116339745 A CN 116339745A
Authority
CN
China
Prior art keywords
target
data
equipment
matched
analysis
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310326786.5A
Other languages
Chinese (zh)
Inventor
叶晓宾
王国伟
崔玚
陈甲印
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Honghu Wanlian Jiangsu Technology Development Co ltd
Original Assignee
Honghu Wanlian Jiangsu Technology Development Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Honghu Wanlian Jiangsu Technology Development Co ltd filed Critical Honghu Wanlian Jiangsu Technology Development Co ltd
Priority to CN202310326786.5A priority Critical patent/CN116339745A/en
Publication of CN116339745A publication Critical patent/CN116339745A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/40Transformation of program code
    • G06F8/41Compilation
    • G06F8/42Syntactic analysis
    • G06F8/427Parsing

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer And Data Communications (AREA)

Abstract

The invention discloses a method, a device, equipment and a storage medium for analyzing communication data between equipment. The method comprises the following steps: when detecting that target peripheral equipment triggers execution of target equipment service, acquiring a target analysis request matched with the target equipment service; acquiring target equipment parameters matched with the target peripheral equipment by executing a target analysis file matched with the target analysis request; according to the parameters of the target equipment, a communication port between the target peripheral equipment and the host equipment is obtained, and communication data matched with the service of the target equipment is pre-obtained through the communication port; and analyzing the target data by using a data analysis library matched with the target equipment parameters, and sending an analysis result to a receiver matched with the target equipment service through a communication port. By the technical scheme, direct data communication among devices in various data formats can be realized, and the analysis efficiency of communication data among devices in various data formats is improved.

Description

Method, device, equipment and storage medium for analyzing communication data between equipment
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a method, an apparatus, a device, and a medium for analyzing communication data between devices.
Background
With the continuous development of the prior art, more and more types of peripheral devices are provided with a function of connecting with a terminal or a server and realizing data interaction. In the data communication process, it is often necessary to parse communication data between an external device and an attached host device.
In the prior art, an open source hong Monte Carlo system is generally used for realizing the analysis of communication data between devices, when a new peripheral device is accessed to host equipment in a new service scene to carry out data communication, the open source hong Monte Carlo system monitors a data communication event, judges codes, services and a data analysis library conforming to the event, and writes codes to generate new codes for analyzing the communication data.
The inventors have found that the following problems exist in the prior art in the process of implementing the present invention: on one hand, the data analysis library, the service and monitoring mixed analysis of various service scenes are not strong in reusability, each service scene needs to be rewritten with codes, and the quality of the codes of the peripheral system layer cannot be effectively ensured; on the other hand, if development and modification are required for each business scenario, the workload of software development is increased, resulting in degradation of development quality and degradation of the parsing efficiency of communication data between devices.
Disclosure of Invention
The invention provides a method, a device, equipment and a medium for analyzing communication data among devices, which can solve the problem of lower analysis efficiency of the communication data among the devices in the prior art.
In a first aspect, the present invention provides a method for parsing communication data between devices, which is executed by a host device connected to a peripheral device, the method comprising:
when detecting that target peripheral equipment triggers execution of target equipment service, acquiring a target analysis request matched with the target equipment service;
acquiring target equipment parameters matched with the target peripheral equipment by executing a target analysis file matched with the target analysis request;
according to the target equipment parameters, a communication port between target peripheral equipment and the host equipment is obtained, and communication data matched with the target equipment service is pre-obtained through the communication port;
and analyzing the target data by using a data analysis library matched with the target equipment parameters, and sending an analysis result to a receiver matched with the target equipment service through the communication port.
In a second aspect, the present invention provides an apparatus for analyzing communication data between devices, which is executed by a host device to which a peripheral device is connected, the apparatus comprising:
the target analysis request acquisition module is used for acquiring a target analysis request matched with the target equipment service when the target peripheral equipment is detected to trigger the execution of the target equipment service;
the target equipment parameter acquisition module is used for acquiring target equipment parameters matched with the target peripheral equipment by executing a target analysis file matched with the target analysis request;
the communication data monitoring module is used for acquiring a communication port between the target peripheral equipment and the host equipment according to the target equipment parameters, and pre-acquiring communication data matched with the target equipment service through the communication port;
and the analysis result sending module is used for analyzing the target data by using a data analysis library matched with the target equipment parameters and sending the analysis result to a receiver matched with the target equipment service through the communication port.
In a third aspect, the present invention provides an electronic device, including:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,,
the memory stores a computer program executable by the at least one processor to enable the at least one processor to perform the method for parsing inter-device communication data according to any of the embodiments of the present invention.
In a fourth aspect, the present invention provides a computer readable storage medium, where computer instructions are stored, where the computer instructions are configured to cause a processor to implement a method for parsing inter-device communication data according to any embodiment of the present invention when executed.
According to the technical scheme, when the target peripheral equipment is detected to trigger execution of target equipment service, a target analysis request matched with the target equipment service is acquired, then target equipment parameters matched with the target peripheral equipment are acquired through execution of a target analysis file matched with the target analysis request, a communication port between the target peripheral equipment and host equipment is acquired according to the target equipment parameters, communication data matched with the target equipment service is pre-acquired through the communication port, the target data is analyzed through a data analysis library matched with the target equipment parameters, and finally an analysis result is sent to a receiver matched with the target equipment service through the communication port, so that the problem of low analysis efficiency of the communication data among equipment in the prior art is solved, direct data communication among equipment in various data formats is realized, and the analysis efficiency of the communication data among the equipment in various data formats is improved.
It should be understood that the description in this section is not intended to identify key or critical features of the embodiments of the invention or to delineate the scope of the invention. Other features of the present invention will become apparent from the description that follows.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for the description of the embodiments will be briefly described below, and it is apparent that the drawings in the following description are only some embodiments of the present invention, and other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a flowchart of a method for parsing communication data between devices according to a first embodiment of the present invention;
fig. 2 is a flowchart of a method for parsing communication data between devices according to a second embodiment of the present invention;
fig. 3 is a schematic structural diagram of an apparatus for analyzing inter-device communication data according to a third embodiment of the present invention;
fig. 4 is a schematic structural diagram of an electronic device implementing a method for analyzing data of inter-device communication according to an embodiment of the present invention.
Detailed Description
In order that those skilled in the art will better understand the present invention, a technical solution in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in which it is apparent that the described embodiments are only some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present invention without making any inventive effort, shall fall within the scope of the present invention.
It should be noted that the terms "first," "second," and the like in the description and the claims of the present invention and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the invention described herein may be implemented in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
Example 1
Fig. 1 is a flowchart of a method for analyzing inter-device communication data according to an embodiment of the present invention, where the method may be applicable to a case where a host device accesses a peripheral device and the host device performs analysis of the inter-device communication data, and the method may be performed by an inter-device communication data analysis device, and the inter-device communication data analysis device may be implemented in the form of hardware and/or software, and the inter-device communication data analysis device may be configured in the host device accessed with the peripheral device, where the host device may be a terminal or a server having an OpenHarmony framework and having an inter-device communication data analysis function.
Accordingly, as shown in fig. 1, the method includes:
s110, when the target peripheral equipment is detected to trigger the execution of the target equipment service, a target analysis request matched with the target equipment service is acquired.
Wherein the peripheral device comprises: the hardware peripheral equipment has an information exchange function and can establish communication connection with the host equipment with an OpenHarmony framework, and the peripheral hardware equipment can be a mobile hard disk provided with a USB interface, an electronic book or a handle provided with a serial port, a display and the like by way of example.
In this embodiment, the target device service is a service function of the target peripheral device; for example, if the main body of the target peripheral device is a mobile hard disk, the service function that the target peripheral device can provide may be a data storage function and a data transmission function, and the target device service may be a data storage service and a data transmission service; correspondingly, if the main body of the target peripheral equipment is a display, the service function which can be provided by the target peripheral equipment can be a display function, and the target equipment service can be a digital display service.
The target analysis request is a code request matched with the target equipment service and used for carrying out information exchange on the host equipment; if the main body of the target peripheral device is a mobile hard disk and the currently acquired target device service is a data transmission service, the host device sends a data transmission command to the target peripheral device as an analysis request to command the target peripheral device to complete a data transmission function.
S120, acquiring target equipment parameters matched with the target peripheral equipment by executing the target analysis file matched with the target analysis request.
Specifically, after the target analysis request is obtained, the host device may directly match a target analysis file matched with the current target analysis request according to the format of the target analysis request and the included information, and the target analysis file may be, for example, a file with a format suffix of (ini.) and obtain a target device parameter in the target analysis file by executing the target analysis file; wherein the target device parameters include: and the host equipment performs data communication with the target peripheral equipment, and performs configuration information and the like matched with the target analysis request configuration on the port.
In this embodiment, before obtaining the target device parameter matched with the target peripheral device by executing the target resolution file matched with the target resolution request, the method further includes: in the target analysis request, analyzing to obtain a file identifier of a target analysis file; and acquiring the target analysis file matched with the target analysis request according to the file identification.
The file identification is an identification statement with a specific format suffix (ini.) in the target analysis file; further, after the file identifier is obtained, a target analysis file with a corresponding format suffix (ini.) can be obtained according to the file identifier, namely, a target analysis file matched with the target analysis request.
S130, according to the target equipment parameters, a communication port between the target peripheral equipment and the host equipment is obtained, and communication data matched with the target equipment service is pre-obtained through the communication port.
The communication port is a port position where the host equipment and the target peripheral equipment exchange data; if the target peripheral device is a mobile hard disk a, the target peripheral device is connected to the port 1 of the host device through the USB and the host device, and the communication port of the target peripheral device is a port 1-mobile hard disk a port.
In this embodiment, taking the mobile hard disk a as an example, since the data formats between the host device and the mobile hard disk are different, the data cannot be directly transmitted, but the host device needs to parse the original data into the data matched with the mobile hard disk for transmission, when the host device receives the target parsing request for data transmission between the port 1-the mobile hard disk a port and the mobile hard disk a, the host device requests the mobile hard disk a to perform data transmission through the communication port, at this time, the mobile hard disk a calls the original data to be transmitted through the communication port, then the host device monitors that the communication port has data flow, at this time, the host device intercepts all the unresolved original data flowing through the communication port, and caches the data in the transfer cache area, namely, pre-acquires the communication data matched with the target device service through the communication port.
And S140, analyzing the target data by using a data analysis library matched with the target equipment parameters, and sending an analysis result to a receiver matched with the target equipment service through the communication port.
The data analysis library is used for analyzing the target data into analysis result data matched with a receiver format matched with the target equipment service.
The receiver may be a host device or a peripheral device connected to the host device, which is specifically determined by the content served by the target device; if the current target device service is to store data into the mobile hard disk a, the current receiver is a mobile hard disk; correspondingly, if the current target device service is to take out data from the mobile hard disk a to the host device, the current receiver is the host device.
In this embodiment, before the target data is parsed by using the data parsing library matched with the target device parameters, the method further includes: matching in a data analysis library set according to the target equipment parameters to obtain a data analysis library matched with the target equipment parameters; and the data analysis library set stores data analysis libraries respectively corresponding to different types of peripheral equipment.
The data analysis library set can be manually preset and adjusted.
According to the technical scheme, when the target peripheral equipment is detected to trigger execution of target equipment service, a target analysis request matched with the target equipment service is acquired, then target equipment parameters matched with the target peripheral equipment are acquired through execution of a target analysis file matched with the target analysis request, a communication port between the target peripheral equipment and host equipment is acquired according to the target equipment parameters, communication data matched with the target equipment service is pre-acquired through the communication port, the target data is analyzed by using a data analysis library matched with the target equipment parameters, and finally an analysis result is sent to a receiver matched with the target equipment service through the communication port, so that direct data communication between equipment in various data formats is realized, and the analysis efficiency of the communication data between the equipment in various data formats is improved.
Example two
Fig. 2 is a flowchart of a method for analyzing communication data between devices according to a second embodiment of the present invention, which is based on the foregoing embodiment, and in this embodiment, the method for sending an analysis result to a receiver matching with a target device service through a communication port and the method for pre-acquiring communication data matching with the target device service through the communication port may specifically include:
as shown in fig. 2, the method includes:
s210, when the target peripheral equipment is detected to trigger execution of target equipment service, a target analysis request matched with the target equipment service is acquired.
S220, acquiring target equipment parameters matched with the target peripheral equipment by executing the target analysis file matched with the target analysis request.
Before the target device parameters matched with the target peripheral device are acquired by executing the target analysis file matched with the target analysis request, the method further comprises the following steps: in the target analysis request, analyzing to obtain a file identifier of a target analysis file; and acquiring the target analysis file matched with the target analysis request according to the file identification.
S230, according to the target equipment parameters, a communication port between the target peripheral equipment and the host equipment is obtained.
S240, carrying out port calling test on the communication port and judging whether the communication port is successfully called or not;
if yes, executing S250;
if not, S260 is performed.
In this embodiment, since the current host device having an openhard framework and having an inter-device communication data analysis function has a hot plug function of a peripheral device, there may be a case where the call of the communication interface fails; if the current peripheral device is a mobile hard disk, the current mobile hard disk is connected with the host device, and the host device generates a target analysis request for the mobile hard disk, at this time, the host device executes a target analysis file matched with the target analysis request, acquires target device parameters matched with the target peripheral device, and acquires a communication port between the target peripheral device and the host device according to the target device parameters, if the mobile hard disk is directly pulled out manually without being unloaded in the process of acquiring the communication port by the host device, at this time, the data port of the port-mobile hard disk finally acquired by the host device is disconnected, and is in a disconnection state, namely, the port call fails.
S250, pre-acquiring communication data matched with the target equipment service through the communication port, and executing S270.
Specifically, pre-acquiring communication data matched with the target equipment service through the communication port includes: and segmented communication data matched with the target equipment service are obtained in a segmented mode through the communication port, and the segmented communication data are cached in a transit storage area.
In the prior art, for data transmission, a segmented form is generally used, and larger data is segmented into smaller data streams for transmission, that is, communication data which is monitored by the current host device and is acquired in advance is also communication data in a segmented form; further, the communication data of each segment may be pre-cached in a transit storage area of the host device; the transit storage area may be a storage area with a cache function, which is included in the host device.
S260, after a preset waiting time period, returning to the step S240.
The preset waiting time length can be adjusted manually, such as 5 s.
And S270, sequentially carrying out segmentation analysis on the target data according to the pre-acquired time sequence to obtain each segmentation analysis result matched with the target data, and executing S280.
In this embodiment, each piece of target data is subjected to the segmentation analysis by using a data analysis library matched with the current target data format according to the time sequence of the acquisition, and it is easy to understand that the target data of each segment has a segmentation analysis result matched with the target data of each segment because the target data of each segment are independently subjected to the data analysis; and the format of the segmentation analysis result is matched with the format supported by the receiver matched with the target equipment service.
Specifically, after obtaining each segment analysis result matched with the target data, the method further comprises the following steps:
and assembling the segmented analysis results to obtain the analysis results, and sending the analysis results to a receiver matched with the target equipment service.
In this embodiment, the analysis result may be a section of stored data, or may be command data of the receiving party; further, if the analysis result is command data, the receiver executes a command sent by the sender to the receiver based on the command data; the content of the command data should be matched with the target parsing request, that is, the command data can enable the receiver to execute the target device service.
And S280, sending the analysis result to a receiver matched with the target equipment service through the communication port.
According to the technical scheme, when the target peripheral equipment is detected to trigger execution of target equipment service, a target analysis request matched with the target equipment service is acquired, then target equipment parameters matched with the target peripheral equipment are acquired through execution of a target analysis file matched with the target analysis request, a communication port between the target peripheral equipment and host equipment is acquired according to the target equipment parameters, then the communication port performs port calling test, if the port calling test is successful, communication data matched with the target equipment service is pre-acquired through the communication port, if the port calling fails, after a preset waiting time is set, the operation of performing the port calling test on the communication port is returned to be executed until the end of iteration conditions is met, the target data is analyzed by using a data analysis library matched with the target equipment parameters, and finally an analysis result is sent to a receiver matched with the target equipment service through the communication port, so that direct data communication between equipment in various data formats is realized, and the analysis efficiency of the communication data between equipment in various data formats is improved.
Example III
Fig. 3 is a schematic structural diagram of an apparatus for analyzing communication data between devices according to a third embodiment of the present invention.
As shown in fig. 3, the apparatus includes:
a target resolution request obtaining module 310, configured to obtain a target resolution request matched with a target device service when detecting that the target peripheral device triggers to execute the target device service;
a target device parameter obtaining module 320, configured to obtain a target device parameter matched with the target peripheral device by executing a target resolution file matched with the target resolution request;
the communication data monitoring module 330 is configured to obtain a communication port between a target peripheral device and the host device according to the target device parameter, and pre-obtain communication data matched with the target device service through the communication port;
and the analysis result sending module 340 is configured to analyze the target data by using a data analysis library matched with the target device parameter, and send the analysis result to a receiver matched with the target device service through the communication port.
According to the technical scheme, when the target peripheral equipment is detected to trigger execution of target equipment service, a target analysis request matched with the target equipment service is acquired, then target equipment parameters matched with the target peripheral equipment are acquired through execution of a target analysis file matched with the target analysis request, a communication port between the target peripheral equipment and host equipment is acquired according to the target equipment parameters, communication data matched with the target equipment service is pre-acquired through the communication port, the target data is analyzed by using a data analysis library matched with the target equipment parameters, and finally an analysis result is sent to a receiver matched with the target equipment service through the communication port, so that direct data communication between equipment in various data formats is realized, and the analysis efficiency of the communication data between the equipment in various data formats is improved.
On the basis of the above embodiments, the method further comprises: the target analysis file acquisition module is used for: before acquiring target equipment parameters matched with the target peripheral equipment by executing a target analysis file matched with the target analysis request, analyzing in the target analysis request to obtain a file identification of the target analysis file; and acquiring the target analysis file matched with the target analysis request according to the file identification.
Based on the above embodiments, the communication data listening module 330 specifically includes:
the test unit is used for carrying out port calling test on the communication port;
a communication data acquisition unit, configured to pre-acquire communication data matched with the target device service through the communication port;
and the return execution unit is used for returning to execute the operation of carrying out port call test on the communication port after a preset waiting time interval until the end iteration condition is met.
On the basis of the above embodiments, the communication data acquisition unit is further configured to:
and segmented communication data matched with the target equipment service are obtained in a segmented mode through the communication port, and the segmented communication data are cached in a transit storage area.
Based on the above embodiments, the analysis result sending module 340 is specifically configured to:
and sequentially carrying out segmentation analysis on the target data according to the pre-acquired time sequence to obtain each segmentation analysis result matched with the target data.
On the basis of the foregoing embodiment, the apparatus may further include an analysis result sending module, configured to:
and after obtaining each segment analysis result matched with the target data, assembling each segment analysis result to obtain the analysis result, and sending the analysis result to a receiver matched with the target equipment service.
Based on the above embodiments, the method may further include a data parsing library matching module, configured to:
before analyzing the target data by using a data analysis library matched with the target equipment parameters, matching in a data analysis library set according to the target equipment parameters to obtain a data analysis library matched with the target equipment parameters; and the data analysis library set stores data analysis libraries respectively corresponding to different types of peripheral equipment.
The device for analyzing the communication data among the devices provided by the embodiment of the invention can execute the method for analyzing the communication data among the devices provided by any embodiment of the invention, and has the corresponding functional modules and beneficial effects of the execution method.
Example IV
Fig. 4 shows a schematic diagram of the structure of an electronic device 10 that may be used to implement an embodiment of the invention. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. Electronic equipment may also represent various forms of mobile devices, such as personal digital processing, cellular telephones, smartphones, wearable devices (e.g., helmets, glasses, watches, etc.), and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be exemplary only, and are not meant to limit implementations of the inventions described and/or claimed herein.
As shown in fig. 4, the electronic device 10 includes at least one processor 11, and a memory, such as a Read Only Memory (ROM) 12, a Random Access Memory (RAM) 13, etc., communicatively connected to the at least one processor 11, in which the memory stores a computer program executable by the at least one processor, and the processor 11 may perform various appropriate actions and processes according to the computer program stored in the Read Only Memory (ROM) 12 or the computer program loaded from the storage unit 18 into the Random Access Memory (RAM) 13. In the RAM 13, various programs and data required for the operation of the electronic device 10 may also be stored. The processor 11, the ROM 12 and the RAM 13 are connected to each other via a bus 14. An input/output (I/O) interface 15 is also connected to bus 14.
Various components in the electronic device 10 are connected to the I/O interface 15, including: an input unit 16 such as a keyboard, a mouse, etc.; an output unit 17 such as various types of displays, speakers, and the like; a storage unit 18 such as a magnetic disk, an optical disk, or the like; and a communication unit 19 such as a network card, modem, wireless communication transceiver, etc. The communication unit 19 allows the electronic device 10 to exchange information/data with other devices via a computer network, such as the internet, and/or various telecommunication networks.
The processor 11 may be a variety of general and/or special purpose processing components having processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various specialized Artificial Intelligence (AI) computing chips, various processors running machine learning model algorithms, digital Signal Processors (DSPs), and any suitable processor, controller, microcontroller, etc. The processor 11 performs the various methods and processes described above, such as the parsing method of the inter-device communication data.
Accordingly, the method comprises the following steps:
when detecting that target peripheral equipment triggers execution of target equipment service, acquiring a target analysis request matched with the target equipment service;
acquiring target equipment parameters matched with the target peripheral equipment by executing a target analysis file matched with the target analysis request;
according to the target equipment parameters, a communication port between target peripheral equipment and the host equipment is obtained, and communication data matched with the target equipment service is pre-obtained through the communication port;
and analyzing the target data by using a data analysis library matched with the target equipment parameters, and sending an analysis result to a receiver matched with the target equipment service through the communication port.
In some embodiments, the method of parsing the inter-device communication data may be implemented as a computer program tangibly embodied on a computer-readable storage medium, such as the storage unit 18. In some embodiments, part or all of the computer program may be loaded and/or installed onto the electronic device 10 via the ROM 12 and/or the communication unit 19. When the computer program is loaded into RAM 13 and executed by processor 11, one or more steps of the method of parsing inter-device communication data described above may be performed. Alternatively, in other embodiments, the processor 11 may be configured to perform the method of parsing the inter-device communication data in any other suitable manner (e.g., by means of firmware).
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuit systems, field Programmable Gate Arrays (FPGAs), application Specific Integrated Circuits (ASICs), application Specific Standard Products (ASSPs), systems On Chip (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs, the one or more computer programs may be executed and/or interpreted on a programmable system including at least one programmable processor, which may be a special purpose or general-purpose programmable processor, that may receive data and instructions from, and transmit data and instructions to, a storage system, at least one input device, and at least one output device.
A computer program for carrying out methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the computer programs, when executed by the processor, cause the functions/acts specified in the flowchart and/or block diagram block or blocks to be implemented. The computer program may execute entirely on the machine, partly on the machine, as a stand-alone software package, partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of the present invention, a computer-readable storage medium may be a tangible medium that can contain, or store a computer program for use by or in connection with an instruction execution system, apparatus, or device. The computer readable storage medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. Alternatively, the computer readable storage medium may be a machine readable signal medium. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
To provide for interaction with a user, the systems and techniques described here can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) through which a user can provide input to the electronic device. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic input, speech input, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a background component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such background, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), wide Area Networks (WANs), blockchain networks, and the internet.
The computing system may include clients and servers. The client and server are typically remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The server can be a cloud server, also called a cloud computing server or a cloud host, and is a host product in a cloud computing service system, so that the defects of high management difficulty and weak service expansibility in the traditional physical hosts and VPS service are overcome.
It should be appreciated that various forms of the flows shown above may be used to reorder, add, or delete steps. For example, the steps described in the present invention may be performed in parallel, sequentially, or in a different order, so long as the desired results of the technical solution of the present invention are achieved, and the present invention is not limited herein.

Claims (10)

1. A method for parsing communication data between devices, which is executed by a host device connected to a peripheral device, comprising:
when detecting that target peripheral equipment triggers execution of target equipment service, acquiring a target analysis request matched with the target equipment service;
acquiring target equipment parameters matched with the target peripheral equipment by executing a target analysis file matched with the target analysis request;
according to the target equipment parameters, a communication port between target peripheral equipment and the host equipment is obtained, and communication data matched with the target equipment service is pre-obtained through the communication port;
and analyzing the target data by using a data analysis library matched with the target equipment parameters, and sending an analysis result to a receiver matched with the target equipment service through the communication port.
2. The method of claim 1, further comprising, prior to obtaining the target device parameters matching the target peripheral device by executing the target resolution file matching the target resolution request:
in the target analysis request, analyzing to obtain a file identifier of a target analysis file;
and acquiring the target analysis file matched with the target analysis request according to the file identification.
3. The method of claim 1, wherein pre-fetching communication data matching the target device service through the communication port comprises:
port calling test is carried out on the communication port;
if the port call test is successful, pre-acquiring communication data matched with the target equipment service through the communication port;
and if the port call fails, after a preset waiting time is set, returning to execute the operation of carrying out the port call test on the communication port until the iteration ending condition is met.
4. The method of claim 3, wherein pre-fetching communication data matching the target device service through the communication port comprises:
and segmented communication data matched with the target equipment service are obtained in a segmented mode through the communication port, and the segmented communication data are cached in a transit storage area.
5. The method of claim 1, wherein parsing the target data using a data parsing library that matches the target device parameters comprises:
and sequentially carrying out segmentation analysis on the target data according to the pre-acquired time sequence to obtain each segmentation analysis result matched with the target data.
6. The method of claim 5, further comprising, after obtaining each segment parsing result that matches the target data:
and assembling the segmented analysis results to obtain the analysis results, and sending the analysis results to a receiver matched with the target equipment service.
7. The method of claim 1, further comprising, prior to parsing the target data using a data parsing library that matches the target device parameters:
matching in a data analysis library set according to the target equipment parameters to obtain a data analysis library matched with the target equipment parameters;
and the data analysis library set stores data analysis libraries respectively corresponding to different types of peripheral equipment.
8. An apparatus for analyzing communication data between devices, which is executed by a host device to which a peripheral device is connected, comprising:
the target analysis request acquisition module is used for acquiring a target analysis request matched with the target equipment service when the target peripheral equipment is detected to trigger the execution of the target equipment service;
the target equipment parameter acquisition module is used for acquiring target equipment parameters matched with the target peripheral equipment by executing a target analysis file matched with the target analysis request;
the communication data monitoring module is used for acquiring a communication port between the target peripheral equipment and the host equipment according to the target equipment parameters, and pre-acquiring communication data matched with the target equipment service through the communication port;
and the analysis result sending module is used for analyzing the target data by using a data analysis library matched with the target equipment parameters and sending the analysis result to a receiver matched with the target equipment service through the communication port.
9. An electronic device, the electronic device comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,,
the memory stores a computer program executable by the at least one processor to enable the at least one processor to perform the method of parsing inter-device communication data of any one of claims 1-7.
10. A computer readable storage medium storing computer instructions for causing a processor to perform the method of parsing inter-device communication data according to any one of claims 1-7.
CN202310326786.5A 2023-03-30 2023-03-30 Method, device, equipment and storage medium for analyzing communication data between equipment Pending CN116339745A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310326786.5A CN116339745A (en) 2023-03-30 2023-03-30 Method, device, equipment and storage medium for analyzing communication data between equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310326786.5A CN116339745A (en) 2023-03-30 2023-03-30 Method, device, equipment and storage medium for analyzing communication data between equipment

Publications (1)

Publication Number Publication Date
CN116339745A true CN116339745A (en) 2023-06-27

Family

ID=86887557

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310326786.5A Pending CN116339745A (en) 2023-03-30 2023-03-30 Method, device, equipment and storage medium for analyzing communication data between equipment

Country Status (1)

Country Link
CN (1) CN116339745A (en)

Similar Documents

Publication Publication Date Title
CN112540806B (en) Method and device for rendering small program page, electronic equipment and storage medium
CN116701168A (en) Peripheral interface testing method, device, equipment and storage medium
CN113778644B (en) Task processing method, device, equipment and storage medium
CN112948081B (en) Method, device, equipment and storage medium for processing tasks in delayed mode
CN115883647B (en) Service log recording method, system, device, terminal, server and medium
CN117040799A (en) Page interception rule generation and page access control method and device and electronic equipment
CN115865734A (en) Fault detection method, data generation method, device, equipment and medium
CN116339745A (en) Method, device, equipment and storage medium for analyzing communication data between equipment
CN114237752B (en) Push page display method and device, electronic equipment and storage medium
CN114095758B (en) Cloud image intercepting method and related device
CN115840604B (en) Data processing method, device, electronic equipment and computer readable storage medium
CN114416414B (en) Fault information positioning method, device, equipment and storage medium
CN117670236A (en) Mobile-terminal-based to-be-handled flow approval method, device, equipment and medium
CN117632545A (en) Data sharing method and device of business system and electronic equipment
CN117556116A (en) Method and device for processing request information, electronic equipment and storage medium
CN117272151A (en) Data processing method, device, equipment and storage medium
CN116166253A (en) Inter-vehicle domain communication method, data gateway, device and storage medium
CN113778969A (en) Log processing method and device
CN117539719A (en) Application operation monitoring method, device, equipment and medium
CN118055068A (en) Message processing method, device, equipment and medium based on DPDK
CN116132523A (en) Message processing method, device, electronic equipment and storage medium
CN117032712A (en) Pipeline compiling and constructing method and device, electronic equipment and storage medium
CN116400962A (en) Instruction processing method, apparatus and computer program product
CN117395211A (en) Data forwarding method, device, switch and medium
CN117741574A (en) Radar message processing method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination