[go: up one dir, main page]

CN115408316A - Multi-device identification method and device and computer readable storage medium - Google Patents

Multi-device identification method and device and computer readable storage medium Download PDF

Info

Publication number
CN115408316A
CN115408316A CN202110593879.5A CN202110593879A CN115408316A CN 115408316 A CN115408316 A CN 115408316A CN 202110593879 A CN202110593879 A CN 202110593879A CN 115408316 A CN115408316 A CN 115408316A
Authority
CN
China
Prior art keywords
port
protocol
equipment
protocol packet
device protocol
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
CN202110593879.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.)
Ricoh Co Ltd
Original Assignee
Ricoh 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 Ricoh Co Ltd filed Critical Ricoh Co Ltd
Priority to CN202110593879.5A priority Critical patent/CN115408316A/en
Publication of CN115408316A publication Critical patent/CN115408316A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/40Bus structure
    • G06F13/4063Device-to-bus coupling
    • G06F13/4068Electrical coupling
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/4401Bootstrapping
    • G06F9/4411Configuring for operating with peripheral devices; Loading of device drivers
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/18Multiprotocol handlers, e.g. single devices capable of handling multiple protocols

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Hardware Design (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Communication Control (AREA)

Abstract

本发明提供了一种多设备的识别方法、装置及计算机可读存储介质,所述识别方法包括:针对所述端口列表中的每个端口执行轮询操作,所述轮询操作包括:根据该端口上的设备交互模式,从所述多个设备协议分组中确定一目标设备协议分组;轮询所述目标设备协议分组中的每种设备协议,采用当前轮询到的设备协议,识别该端口上所连接设备。本发明能够提高设备识别效率,另外还能够自动处理设备正常断开和异常断开问题。

Figure 202110593879

The present invention provides a multi-device identification method, device, and computer-readable storage medium. The identification method includes: executing a polling operation for each port in the port list, and the polling operation includes: according to the Device interaction mode on the port, determine a target device protocol group from the plurality of device protocol groups; poll each device protocol in the target device protocol group, and use the currently polled device protocol to identify the port on the connected device. The invention can improve the efficiency of equipment identification, and can also automatically deal with the problems of normal disconnection and abnormal disconnection of equipment.

Figure 202110593879

Description

Multi-device identification method and device and computer readable storage medium
Technical Field
The present invention relates to the field of device identification management technologies, and in particular, to a method and an apparatus for identifying multiple devices, and a computer-readable storage medium.
Background
In systems such as smart home systems, smart building systems, and medical care systems, it is often necessary to collect data of a plurality of devices at the same time. For example, medical big data requires collecting monitoring data of many devices for scientific research and clinical use, and in the data acquisition system of a medical device shown in fig. 1, a Micro Control Unit (MCU) or a microprocessor Unit (MPU) is connected to a plurality of medical devices with serial ports through a Hub (Hub) to collect data of each medical device. However, the data output of different brands or different models of medical device of the same brand may follow different protocols. The variability of protocols greatly increases the difficulty of obtaining data from multiple devices simultaneously. In addition, disconnection, reconnection, or replacement of a device during data acquisition can result in significant data loss.
Most of the current medical collection tools (e.g., philips intellivue and Mindray BeneLink) only support access to their same vendor's equipment, but are not applicable to other vendors' medical equipment. For other tools, such as the video Recorder, the interface configuration is complicated and the technical threshold is high. Therefore, a method for identifying multiple devices, which can improve the device identification efficiency, is needed.
Disclosure of Invention
The invention aims to provide a multi-device identification method, a multi-device identification device and a computer readable storage medium, and can improve the device identification efficiency.
In order to solve the above technical problem, embodiments of the present invention provide the following technical solutions:
acquiring a port list and a device protocol packet list of a target system, wherein the port list comprises at least one port, the device protocol packet list comprises a plurality of device protocol packets corresponding to different device interaction modes, each device protocol packet comprises at least one device protocol supported by the target system on the port, and the device interaction mode is used for indicating whether a device automatically sends data or not;
performing a polling operation for each port in the port list, the polling operation comprising:
determining a target device protocol packet from the plurality of device protocol packets according to the device interaction mode on the port;
and polling each device protocol in the target device protocol packet, and identifying the connected device on the port by adopting the currently polled device protocol.
Preferably, the device protocol packet further includes an existing device list under each device protocol, and all existing devices supporting the device protocol are recorded in the existing device list; the method further comprises the following steps:
sharing a connected device list among all ports in the port list, wherein the connected device list records devices connected to all ports of a target system;
after a binding relationship between a first port and a first device is added in a connected device list, according to a preset device mutual exclusion relationship, determining a first mutual exclusion device which is mutually exclusive with the first device and a first mutual exclusion device protocol adopted by the first mutual exclusion device, wherein the device mutual exclusion relationship is used for indicating devices which cannot be simultaneously connected with a target system, and the mutual exclusion device of any device at least comprises the device;
and deleting the first mutually exclusive device protocol from the device protocol group to which the first mutually exclusive device protocol belongs under the condition that the existing device list under the first mutually exclusive device protocol only comprises the first mutually exclusive device.
Preferably, the method further comprises:
monitoring the equipment connection state of each port in the connected equipment list;
under the condition that the connection state of the second equipment on the second port is disconnected or abnormally connected, closing the second port, and deleting the binding relationship between the second port and the second equipment in the connected equipment list;
according to the mutual exclusion relationship of the equipment, second mutual exclusion equipment which is mutually exclusive with the second equipment and a second mutual exclusion equipment protocol adopted by the second mutual exclusion equipment are determined;
adding the second mutually exclusive device protocol to the device protocol packet to which it belongs, in case the second mutually exclusive device protocol has been deleted from the device protocol packet to which it belongs.
Preferably, the polling each device protocol in the target device protocol packet, using the currently polled device protocol, to identify the device connected to the port specifically includes: if the equipment is successfully identified, the binding relationship between the port and the identified equipment is added in the connected equipment list; and if the equipment cannot be identified, continuously polling the next equipment protocol in the target equipment protocol packet until the equipment is successfully identified or the equipment protocols in the target equipment protocol packet are polled.
Preferably, when all the device protocols in the target device protocol packet have been polled, if a device is still not identified, it is determined that the device is not connected to the port or the connected device is an unknown protocol device.
Preferably, the method further comprises:
after determining that the port is not connected to a device or that the connected device is an unknown protocol device, closing the port.
Preferably, the plurality of device protocol packets include a first device protocol packet and a second device protocol packet, wherein the first device protocol packet corresponds to a first device interaction mode in which the device automatically transmits data, and the second device protocol packet corresponds to a second device interaction mode in which the device transmits data only when receiving a data request;
determining a target device protocol packet from the plurality of device protocol packets according to the device interaction mode on the port, including: and judging whether the port receives data automatically sent by the equipment, if so, determining that the target equipment protocol packet is a first equipment protocol packet, and otherwise, determining that the target equipment protocol packet is a second equipment protocol packet.
Preferably, polling each device protocol in the target device protocol packet to identify the device connected to the port using the currently polled device protocol includes:
under the condition that the target equipment protocol packet is the first equipment protocol packet, analyzing the data received on the port by adopting the currently polled equipment protocol to acquire an equipment identifier; if the equipment identifier cannot be analyzed, sending a request message on the port to request the equipment identifier when the currently polled equipment protocol supports the interactive command;
and under the condition that the target equipment protocol packet is the second equipment protocol packet, adopting the currently polled equipment protocol, and sending a request message on the port to request equipment identification.
Preferably, the device interaction mode is further configured to indicate whether the data automatically sent by the device carries a device identifier when the device automatically sends data on the port;
the multiple device protocol packets comprise a second device protocol packet, a third device protocol packet and a fourth device protocol packet, wherein the second device protocol packet corresponds to a second device interaction mode in which the device sends data only when receiving a data request, the third device protocol packet corresponds to a third device interaction mode in which the device automatically sends data and the data carries a device identifier, and the fourth device protocol packet corresponds to a fourth device interaction mode in which the device automatically sends data and the fourth device protocol packet does not carry the device identifier but supports an interaction command;
determining a target device protocol packet from the plurality of device protocol packets according to the device interaction mode on the port, including: judging whether the port receives data automatically sent by the equipment, if so, determining that the target equipment protocol packet is the third equipment protocol packet or the fourth equipment protocol packet; otherwise, determining the target device protocol packet as the second device protocol packet.
Preferably, the polling of each device protocol in the target device protocol packet to identify the device connected to the port by using the currently polled device protocol includes:
polling each device protocol in the second device protocol packet under the condition that the target device protocol packet is the second device protocol packet, and sending a request message on the port to request a device identifier by adopting the currently polled device protocol;
when the target device protocol packet is the third device protocol packet or the fourth device protocol packet, polling each device protocol in the third device protocol packet, and analyzing data received on the port to acquire a device identifier by adopting the currently polled device protocol; if the equipment identifier is not resolved when the equipment protocol in the third equipment protocol group is polled, continuously polling each equipment protocol in the fourth equipment protocol group, and sending a request message on the port to request the equipment identifier by adopting the currently polled equipment protocol.
Preferably, the determining whether the port receives data automatically sent by the device specifically includes: detecting whether data is received on the port in a first time window Tw1, wherein the length of the first time window Tw1 is: n1 times of a first period, where the first period is a maximum transmission interval at which all existing devices in the third device protocol packet and the fourth device protocol packet automatically transmit data, and N1 is greater than or equal to 1;
in the process of polling each device protocol in the second device protocol packet, if the currently polled second device protocol is adopted, and the device identifier sent by the device is not obtained when the number of times of sending the request message reaches a preset first number of times, or the device identifier sent by the device is not obtained in a second time window Tw2 after the request message is sent, continuing polling the next device protocol in the second device protocol packet, wherein the length of the second time window Tw2 is as follows: n2 times of first waiting time, wherein the first waiting time is the maximum waiting time from the receiving of the request message to the sending of the equipment identifier by the existing equipment in the second equipment protocol, and N2 is greater than or equal to 1;
in the process of polling each device protocol in the third device protocol packet, if the current polled first device protocol is adopted, the times of analyzing the data received by the port but not obtaining the device identification reach a preset second time, continuously polling the next device protocol in the third device protocol packet;
in the process of polling each device protocol in the fourth device protocol packet, if a currently polled third device protocol is adopted, a device identifier sent by a device is not obtained when the number of times of sending a request message reaches a preset third number of times, or a response message sent by the device is not received in a third time window Tw3 after sending the request message, continuously polling a next device protocol in the fourth device protocol packet, where the length of the third time window Tw3 is: n3 times of a second waiting time, where the second waiting time is a maximum waiting time between receipt of the request message and identification of the sending device by all existing devices in the third device protocol, and N3 is greater than or equal to 1.
Preferably, the method further comprises:
acquiring newly opened ports in the port list according to a preset polling cycle TW0, and executing the polling operation aiming at each newly opened port;
wherein the polling period TW0 is the greater of the first time and the second time;
the first time is N4 times of a total polling time for polling all device protocols in the third device protocol packet and the fourth device protocol packet, and N4 is greater than or equal to 1;
the second time is N5 times a sum of the total polling time for polling all device protocols in the second device protocol packet and the first time window Tw1, where N5 is greater than or equal to 1.
Preferably, before obtaining the port list and the device protocol packet list of the target system, the method further includes:
determining all device protocols supported by the port of the target system, and grouping all the device protocols according to the device interaction mode of each device protocol to obtain the device protocol grouping list and the device protocol under each device protocol grouping;
connecting the existing equipment with the port of the target system, acquiring the equipment configuration parameters and the equipment identification when the existing equipment is successfully accessed into the target system, and storing the equipment configuration parameters and the equipment identification under the equipment protocol to which the existing equipment belongs in the equipment protocol packet.
Preferably, when the target device protocol does not define that the device identifier is carried in the data sent by the device, the preset data content in the data sent by the device is designated as the device identifier.
The embodiment of the invention also provides a device for identifying multiple devices, which comprises:
an information obtaining module, configured to obtain a port list and a device protocol packet list of a target system, where the port list includes at least one port, the device protocol packet list includes multiple device protocol packets corresponding to different device interaction modes, each device protocol packet includes at least one device protocol supported by the target system on the port, and the device interaction mode is used to indicate whether a device automatically sends data;
a port polling module, configured to perform a polling operation for each port in the port list, where the polling operation includes: determining a target device protocol packet from the plurality of device protocol packets according to the device interaction mode on the port; and polling each device protocol in the target device protocol packet, and identifying the connected device on the port by adopting the currently polled device protocol.
Preferably, the device protocol packet further includes an existing device list under each device protocol, and the existing device list records device identifiers of all existing devices supporting the device protocol; the identification apparatus further comprises:
the information sharing module is used for sharing the connected equipment list among the ports in the port list, and the connected equipment list records the connected equipment on each port of the target system;
a first information maintenance module, configured to, after a binding relationship between a first port and a first device is added in a connected device list, determine, according to a preset device mutual exclusion relationship, a first mutually exclusive device that is mutually exclusive with the first device and a first mutually exclusive device protocol that is adopted by the first mutually exclusive device, where the device mutual exclusion relationship is used to indicate devices that cannot be simultaneously connected to the target system, and a mutually exclusive device of any device at least includes the device itself; and deleting the first mutually exclusive device protocol from the device protocol group to which the first mutually exclusive device protocol belongs under the condition that the existing device list under the first mutually exclusive device protocol only comprises the first mutually exclusive device.
Preferably, the identification device further comprises:
the port detection module is used for monitoring the equipment connection state of each port in the connected equipment list;
the abnormal processing module is used for closing the second port and deleting the binding relationship between the second port and the second equipment in the connected equipment list under the condition that the equipment connection state of the second equipment on the second port is disconnected or abnormal; according to the mutual exclusion relationship of the devices, determining a second mutual exclusion device which is mutually exclusive with the second device and a second mutual exclusion device protocol adopted by the second mutual exclusion device; adding the second mutually exclusive device protocol to the device protocol packet to which it belongs, in the event that the second mutually exclusive device protocol has been deleted from the device protocol packet to which it belongs.
Preferably, the port polling module is further configured to, in polling each device protocol in the target device protocol packet, identify a device connected to the port by using the currently polled device protocol: if the equipment is successfully identified, the binding relationship between the port and the identified equipment is added in the connected equipment list; and if the equipment cannot be identified, continuously polling the next equipment protocol in the target equipment protocol packet until the equipment is successfully identified or the equipment protocols in the target equipment protocol packet are polled.
Preferably, the port polling module is further configured to determine that the device is not connected to the port or the connected device is an unknown device if the device is still unidentified when all the device protocols in the target device protocol packet are polled.
Preferably, the identification device further comprises:
and the port control module is used for closing the ports of the unconnected equipment or the connected equipment as unknown protocol equipment after the polling operation.
Preferably, the plurality of device protocol packets include a first device protocol packet and a second device protocol packet, wherein the first device protocol packet corresponds to a first device interaction mode in which the device automatically transmits data, and the second device protocol packet corresponds to a second device interaction mode in which the device transmits data only when receiving a data request;
the port polling module comprises:
and the first judging module is used for judging whether the port receives data automatically sent by the equipment, if so, the protocol packet of the target equipment is determined to be a first equipment protocol packet, and if not, the protocol packet of the target equipment is determined to be a second equipment protocol packet.
Preferably, the port polling module further includes:
a first processing module, configured to, when the target device protocol packet is the first device protocol packet, analyze data received on the port to obtain a device identifier by using a device protocol polled currently; if the equipment identifier cannot be analyzed, sending a request message on the port to request the equipment identifier when the currently polled equipment protocol supports an interactive command;
and the second processing module is used for sending a request message on the port to request the equipment identification by adopting the currently polled equipment protocol under the condition that the target equipment protocol packet is the second equipment protocol packet.
Preferably, the device interaction mode is further configured to indicate whether the data automatically sent by the device carries a device identifier when the device automatically sends data on the port;
the multiple device protocol packets comprise a second device protocol packet, a third device protocol packet and a fourth device protocol packet, wherein the second device protocol packet corresponds to a second device interaction mode in which the device sends data only when receiving a data request, the third device protocol packet corresponds to a third device interaction mode in which the device automatically sends data and the data carries a device identifier, and the fourth device protocol packet corresponds to a fourth device interaction mode in which the device automatically sends data and the fourth device protocol packet does not carry the device identifier but supports an interaction command;
the port polling module comprises:
the second judging module is used for judging whether the port receives data automatically sent by the equipment, and if so, determining that the target equipment protocol packet is the third equipment protocol packet or the fourth equipment protocol packet; otherwise, determining that the target device protocol packet is the second device protocol packet.
Preferably, the port polling module further includes:
a third processing module, configured to poll each device protocol in the second device protocol packet when the target device protocol packet is the second device protocol packet, and send a request message to request a device identifier on the port by using the currently polled device protocol;
a fourth processing module, configured to poll each device protocol in the third device protocol packet first when the target device protocol packet is the third device protocol packet or a fourth device protocol packet, and analyze data received on the port to obtain a device identifier by using a currently polled device protocol; if the device identifier is not analyzed after the polling of the device protocol in the third device protocol packet is finished, continuing to poll each device protocol in the fourth device protocol packet, and sending a request message on the port to request the device identifier by adopting the currently polled device protocol.
Preferably, the second determining module is further configured to detect whether data is received at the port in a first time window Tw1, where a length of the first time window Tw1 is: n1 times of a first period, where the first period is a maximum transmission interval in which all existing devices in the third device protocol packet and the fourth device protocol packet automatically transmit data, and N1 is greater than or equal to 1;
the third processing module is further configured to, in the process of polling each device protocol in the second device protocol packet, if the second device protocol that is currently polled is used, and the device identifier that is sent by the device is not obtained when the number of times of sending the request message reaches a preset first number of times, or the device identifier that is sent by the device is not obtained in a second time window Tw2 after sending the request message, continue to poll a next device protocol in the second device protocol packet, where a length of the second time window Tw2 is: n2 times of first waiting time, wherein the first waiting time is the maximum waiting time from the receiving of the request message to the sending of the equipment identifier of the existing equipment in the second equipment protocol, and N2 is greater than or equal to 1;
the fourth processing module is further configured to, in the process of polling each device protocol in the third device protocol packet, if the currently polled first device protocol is adopted, and the number of times that the data received at the port is analyzed but the device identifier is not obtained reaches a preset second number, continue polling a next device protocol in the third device protocol packet; and in the process of polling each device protocol in the fourth device protocol packet, if a currently polled third device protocol is adopted, and a device identifier sent by a device is not obtained when the number of times of sending a request message reaches a preset third number of times, or a response message sent by the device is not received in a third time window Tw3 after the request message is sent, continuing polling a next device protocol in the fourth device protocol packet, wherein the length of the third time window Tw3 is as follows: n3 times of a second waiting time, where the second waiting time is a maximum waiting time between receiving the request message and sending the device identifier by all existing devices in the third device protocol, and N3 is greater than or equal to 1.
Preferably, the identification device further comprises:
the polling control module is used for acquiring newly opened ports in the port list according to a preset polling cycle TW0 and executing the polling operation aiming at each newly opened port; wherein,
wherein the polling period TW0 is the greater of the first time and the second time;
the first time is N4 times of the total polling time for polling all the device protocols in the third device protocol group and the fourth device protocol group, wherein N4 is greater than or equal to 1;
the second time is N5 times a sum of a total polling time for polling all device protocols in the second device protocol packet and the first time window Tw1, where N5 is greater than or equal to 1.
Preferably, the identification device further comprises:
the protocol preprocessing module is used for determining all device protocols supported by the port of the target system, and grouping all the device protocols according to the device interaction mode of each device protocol to obtain the device protocol group list and the device protocol under each device protocol group;
and the information pre-configuration module is used for connecting the existing equipment with a port of the target system, acquiring equipment configuration parameters and equipment identification when the existing equipment is successfully accessed into the target system, and storing the equipment configuration parameters and the equipment identification under an equipment protocol to which the existing equipment belongs in an equipment protocol packet.
Preferably, the protocol preprocessing module is further configured to specify a preset data content in the data sent by the device as the device identifier, when the target device protocol does not define that the device identifier is carried in the data sent by the device.
The embodiment of the invention also provides a device for identifying multiple devices, which comprises:
a processor; and
a memory having computer program instructions stored therein,
wherein the computer program instructions, when executed by the processor, cause the processor to perform the steps of:
acquiring a port list and a device protocol packet list of a target system, wherein the port list comprises at least one port, the device protocol packet list comprises a plurality of device protocol packets corresponding to different device interaction modes, each device protocol packet comprises at least one device protocol supported by the target system on the port, and the device interaction mode is at least used for indicating whether a device automatically sends data;
performing a polling operation for each port in the port list, the polling operation comprising:
determining a target device protocol packet from the plurality of device protocol packets according to the device interaction mode on the port;
and polling each device protocol in the target device protocol packet, and identifying the connected device on the port by adopting the currently polled device protocol.
An embodiment of the present invention further provides a computer-readable storage medium, where a computer program is stored, and when the computer program is executed by a processor, the steps of the multi-device identification method are implemented.
The embodiment of the invention has the following beneficial effects:
the embodiment of the invention can automatically and parallelly identify the equipment connected to each port on the multi-port system, thereby improving the equipment identification efficiency. In addition, the embodiment of the invention can automatically process normal disconnection and abnormal disconnection of the equipment in the equipment connection process, and quickly identify the equipment and complete reconnection after the equipment is reconnected.
Drawings
FIG. 1 is a schematic diagram of a data acquisition system of a medical device of the prior art;
fig. 2 is a schematic view of an application scenario of a method for multi-device identification according to an embodiment of the present invention;
fig. 3 is a schematic flowchart of a method for multi-device identification according to an embodiment of the present invention;
fig. 4 is a schematic workflow diagram of a method for multi-device identification according to an embodiment of the present invention;
FIG. 5 is a schematic diagram illustrating an embodiment of identifying devices;
FIG. 6 is a schematic diagram of the operation of a program during system initialization according to an embodiment of the present invention;
FIG. 7 is a schematic diagram of the workflow of a pre-configuration step of an embodiment of the present invention;
FIG. 8 is a flowchart illustrating the operation of threads bound to a single port according to an embodiment of the present invention;
FIG. 9 is a diagram illustrating the operation of a program to automatically identify devices in each group in an embodiment of the present invention;
FIG. 10 is a diagram illustrating a normal or abnormal disconnection condition of a processing device according to an embodiment of the present invention;
FIG. 11 is a diagram illustrating a polling operation performed periodically in an embodiment of the invention;
fig. 12 is a block diagram of a structure of an identification apparatus of multiple devices according to an embodiment of the present invention;
fig. 13 is another structural block diagram of an identification apparatus of multiple devices according to an embodiment of the present invention.
Detailed Description
Exemplary embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the invention are shown in the drawings, it should be understood that the invention can be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the invention to those skilled in the art.
The terms first, second and the like in the description and in the claims of the present application are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It should be understood that the data so used may be interchanged under appropriate circumstances such that the embodiments of the application described herein may be implemented, for example, in sequences other than those illustrated or described herein. Moreover, the terms "comprises," "comprising," and any other variation 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. In the description and in the claims "and/or" means at least one of the connected objects.
A known multi-device data collection method adopts the following technical means: all supported device protocols are first programmed into the system and then all ports are polled in turn using the stored protocols to automatically implement multi-device identification and connectivity. This method requires polling all protocols on each port until a device on the port is identified, which, due to the large number of protocols polled, results in a long polling time and a large amount of useful time is lost during the polling phase.
The multi-device identification method provided by the embodiment of the invention can identify various devices connected on the port, reduce the polling time and improve the device identification efficiency. In addition, in a scene that the connection is abnormally disconnected due to an abnormal problem, the disconnection message cannot be normally sent when the equipment is disconnected, and the port cannot be automatically released.
Fig. 2 is a schematic diagram illustrating an application scenario of the method for multi-device identification according to an embodiment of the present invention. In the embodiment of the invention, the target system for collecting the data of the multiple devices is provided with a plurality of ports, and the ports can be connected with various devices to collect the data of the devices. For example, the connection between the target system and the device may include, but is not limited to: the device is connected with the device with the serial port through the concentrator, is connected with the device with the network port through the router, is connected with the device with the Bluetooth interface through Bluetooth, and has other connection modes. The target system may be a Micro Control Unit (MCU) or a microprocessor Unit (MPU), and may also be a computer system with computing and processing capabilities.
Prior to collecting data, the target system needs to identify the device connected to the port so that it can communicate with the device using the device protocol employed by the device to collect data. In order to improve the identification efficiency, the embodiment of the present invention determines, in advance, device protocols (including a data resolution protocol and a communication protocol) of various devices that need to be supported by the target system according to the device that needs to perform data collection by the target system. And then, grouping all the device protocols supported by the target system according to the device interaction modes of the device protocols to obtain a device protocol grouping list. Here, the device interaction mode is at least used to indicate whether the device automatically transmits data. In this way, the device protocol packet list obtained by grouping includes a plurality of device protocol packets corresponding to different device interaction modes, and each device protocol packet includes at least one device protocol supported by the target system on a port.
After grouping the device protocols on the ports supported by the target system, the embodiment of the invention can carry out targeted polling on each port according to the device interaction mode on each port, thereby reducing the polling time, improving the polling efficiency and the device identification efficiency of the device protocols, and further reducing the problems of data loss and the like caused by overlong polling time.
As shown in fig. 3, an embodiment of the present invention provides a method for multi-device identification, including:
step 301, a port list and a device protocol packet list of a target system are obtained, where the port list includes at least one port, the device protocol packet list includes multiple device protocol packets corresponding to different device interaction modes, each device protocol packet includes at least one device protocol supported by the target system on the port, and the device interaction mode is used to indicate whether a device automatically sends data.
Step 302, performing a polling operation for each port in the port list, the polling operation including:
determining a target device protocol packet from the plurality of device protocol packets according to the device interaction mode on the port;
and polling each device protocol in the target device protocol packet, and identifying the connected device on the port by adopting the currently polled device protocol.
Here, in the process of identifying the device connected to the port by using the currently polled device protocol, if the device is successfully identified, the binding relationship between the port and the identified device is added to the connected device list; if the equipment cannot be identified, continuously polling the next equipment protocol in the target equipment protocol packet until the equipment is successfully identified or the equipment protocols in the target equipment protocol packet are polled. Here, the connected device list records devices that have been connected to each port of the target system
It can be seen from the above steps that, in the embodiment of the present invention, when polling a device protocol on a port, a target device protocol packet corresponding to the port is determined according to a device interaction mode of the port, and then only a device protocol in the target device protocol packet is polled on the port, so that the problem of long polling time caused by polling all device protocols is avoided.
Before step 301, the embodiment of the present invention may perform a protocol preprocessing step and an information pre-configuration step to group device protocols and configure and store device configuration information.
Specifically, in the protocol preprocessing step, all device protocols supported by the port of the target system are determined, and the device protocols are grouped according to the device interaction mode of each device protocol, so as to obtain the device protocol group list and the device protocol under each device protocol group.
In the information pre-configuration step, connecting (pre-connecting) an existing device with a port of the target system, acquiring device configuration parameters and a device identifier when the existing device successfully accesses the target system, and storing the device configuration parameters and the device identifier in a device protocol packet to which the existing device belongs. Here, the device configuration parameter may be a parameter selected and adopted by the device from a plurality of parameters supported by the protocol, for example, the device protocol defines a plurality of baud rates, and the device adopts one of the baud rates, and in the pre-connection process, the baud rate of the port is configured through debugging processing so as to be consistent with the baud rate adopted by the device, so that the device can be successfully connected with the device, and then the specific baud rate and other parameters are stored in the device protocol. Thus, when the device protocol is polled subsequently, the device configuration parameters under the device protocol are adopted to interact with the device.
In addition, in the protocol preprocessing step, if the target device protocol does not define that the device identifier is carried in the data sent by the device, the embodiment of the present invention may further designate preset data content in the data sent by the device as the device identifier.
The following provides implementations of two device interaction modes.
As a first implementation of the device interaction mode:
the device interaction mode is used for indicating whether the device automatically sends data. That is, different device interaction modes may be determined according to whether a device automatically transmits data on a port of a target system after the device is connected to the port. Thus, the device interaction mode can be divided into 2 types, which are: 1) A first device interaction mode in which the device automatically transmits data; 2) A second device interaction mode in which the device does not automatically send data, but only sends data upon receiving a data request. Correspondingly, the device protocol packet list includes 2 groups, which are: 1) A first device protocol packet corresponding to the first device interaction mode; 2) A second device protocol packet corresponding to the second device interaction mode.
When the device interaction mode adopts the first implementation manner, in step 302, according to the device interaction mode on the port, determining a target device protocol packet from the multiple device protocol packets, specifically: and judging whether the port receives data automatically sent by the equipment, if so, determining that the target equipment protocol packet is a first equipment protocol packet, and otherwise, determining that the target equipment protocol packet is a second equipment protocol packet.
When the device interaction mode adopts the first implementation manner, in the step 302, the device protocol polled currently is used to identify the device connected to the port, which specifically is:
1) Under the condition that the target equipment protocol packet is the first equipment protocol packet, adopting a currently polled equipment protocol, and analyzing data received on the port to obtain an equipment identifier; if the device identifier cannot be resolved, when the current polled device protocol supports the interactive command, the device protocol is adopted to send a request message on the port to request the device identifier. And under the condition of acquiring the equipment identifier of the equipment connected to the port, the equipment connected to the port is considered to be identified.
2) And under the condition that the target device protocol packet is the second device protocol packet, adopting the currently polled device protocol, and sending a request message on the port to request the device identification.
As a second implementation manner of the device interaction mode:
the device interaction mode is used for indicating whether the device automatically sends data or not, and indicating whether the data automatically sent by the device carries a device identifier or not when the device automatically sends data on the port. That is to say, different device interaction modes may be determined according to whether the device automatically sends data on the port after being connected to the port of the target system, and whether the automatically sent data carries the device identifier. Thus, the device interaction pattern can be divided into 3 types, respectively: 1) A second device interaction mode in which the device does not automatically transmit data but transmits data only when receiving a data request; 2) The equipment automatically sends data, and the data carries a third equipment interaction mode of the equipment identifier; 3) And the equipment automatically sends a fourth equipment interaction mode which does not carry the equipment identification in the data but supports the interaction command. Correspondingly, the device protocol packet list includes 3 groups, which are: 1) A second device protocol packet corresponding to the second device interaction mode; 2) A third device protocol packet corresponding to the third device interaction mode; 3) A fourth device protocol packet corresponding to the fourth device interaction mode.
When the device interaction mode adopts the second implementation manner, in step 302, according to the device interaction mode on the port, a target device protocol packet is determined from the multiple device protocol packets, which specifically is: judging whether the port receives data automatically sent by the equipment, if so, determining that the target equipment protocol packet is the third equipment protocol packet or the fourth equipment protocol packet; otherwise, determining that the target device protocol packet is the second device protocol packet.
Here, determining whether a port receives data automatically sent by the device specifically includes: detecting whether data is received on the port in a first time window Tw1, where the length of the first time window Tw1 is: the first period is N1 times the maximum transmission interval of all existing devices in the third device protocol packet and the fourth device protocol packet for automatically transmitting data, and N1 is greater than or equal to 1.
When the device interaction mode adopts the second implementation manner, in the step 302, the device protocol polled currently is used to identify the device connected to the port, which specifically is:
1) And under the condition that the target device protocol packet is the second device protocol packet, polling each device protocol in the second device protocol packet, and sending a request message on the port to request the device identification by adopting the currently polled device protocol.
Here, in the process of polling each device protocol in the second device protocol packet, if the currently polled second device protocol is adopted, the device identifier sent by the device is not obtained when the number of times of sending the request message reaches the preset first number of times, or the device identifier sent by the device is not obtained in a second time window Tw2 after sending the request message, the next device protocol in the second device protocol packet is continuously polled, and the length of the second time window Tw2 is: n2 times a first waiting time, the first waiting time being a maximum waiting time between the existing device in the second device protocol receiving the request message and sending the device identification, N2 being greater than or equal to 1.
2) When the target device protocol packet is the third device protocol packet or the fourth device protocol packet, polling each device protocol in the third device protocol packet, and analyzing data received on the port to obtain a device identifier by adopting the currently polled device protocol; if the device identifier is not resolved when the polling of the device protocol in the third device protocol packet is finished, continuously polling each device protocol in the fourth device protocol packet, and sending a request message on the port to request the device identifier by adopting the currently polled device protocol.
Here, in the process of polling each device protocol in the third device protocol packet, if the currently polled first device protocol is adopted, and the number of times that the data received on the port is analyzed but the device identifier is not obtained reaches a preset second number, continuing polling the next device protocol in the third device protocol packet;
in the process of polling each device protocol in the fourth device protocol packet, if a currently polled third device protocol is adopted, a device identifier sent by a device is not obtained when the number of times of sending a request message reaches a preset third number of times, or a response message sent by the device is not received in a third time window Tw3 after sending the request message, continuously polling a next device protocol in the fourth device protocol packet, where the length of the third time window Tw3 is: n3 times of a second waiting time, where the second waiting time is a maximum waiting time between receipt of the request message and identification of the sending device by all existing devices in the third device protocol, and N3 is greater than or equal to 1.
In step 302, if no device can be identified when all the device protocols in the target device protocol packet have been polled, it is determined that the device is not connected to the port or the connected device is an unknown protocol device. The unknown protocol device is a device adopting a device protocol which is not supported by the target system. In addition, after the polling operation for each port, or after the polling operation for all ports, the ports of the unconnected devices or the connected devices as unknown protocol devices may be closed to save port resources. It should be noted that closing a port is usually performed after polling, and closing a port is not a purpose of polling.
In many application scenarios, the devices to which the target system may be connected are typically known in advance. For example, all devices in a medical facility that require data acquisition using the target system may be connected to a port of the target system. Here, the existing devices are various devices that are determined in advance to be possible to be connected to the target system. No other devices than the existing device are connected to the target system. And, there may be mutual exclusion relationship among various existing devices. Therefore, the embodiment of the invention can establish the mutual exclusion relationship of the equipment by utilizing the information of the existing equipment to further improve the polling and identifying efficiency of the equipment.
Specifically, the device mutual exclusion relationship is used to indicate a device to which the target system is not connected at the same time. For example, if a target system of a medical institution is connected to at most one oximeter, all oximeters are mutually exclusive devices, that is, if one oximeter is connected to a port of the target system, no other oximeters are connected to other ports of the target system. As another example, the repelling devices of any device include at least the device itself, i.e., a device is not connected to different ports of the target system at the same time, i.e., if a port of the target system has an oximeter connected, the oximeter will not appear at other ports of the target system.
In this way, in the embodiment of the present invention, the device protocol packet further includes an existing device list under each device protocol, and the existing device list records device identifiers of all existing devices supporting the device protocol. In addition, the embodiment of the present invention further shares the connected device list among the ports in the port list. In this way, in step 302, after a binding relationship between a port and a device (referred to as a first port and a first device) is added to the connected device list, a first mutually exclusive device mutually exclusive with the first device and a first mutually exclusive device protocol adopted by the first mutually exclusive device are determined according to a preset device mutually exclusive relationship. Then, if the existing device list under the first mutually exclusive device protocol only includes the first mutually exclusive device, the first mutually exclusive device protocol is deleted from the device protocol group to which the first mutually exclusive device protocol belongs, so that the number of the device protocols in the device protocol group can be reduced, and the polling time required for polling each device protocol in the device protocol group is further reduced.
For example, assume that the existing device includes oximeters 1 to 3, wherein oximeter 1 uses device protocol 1, and oximeters 2 to 3 all use device protocol 4; the device protocol packet 1 comprises device protocols 1-3, and the device protocol packet 2 comprises device protocols 4-5; the existing device list under device protocol 1 includes only the device identifier of oximeter 1, and the existing device list under device protocol 4 includes only the device identifiers of oximeters 2-3. The target system is connected with at most one oximeter, so that mutually exclusive devices are arranged among the oximeters. In the case where the target system recognizes that oximeter 1 is connected below port 1 by performing the above-described polling operation, the binding relationship between port 1 and oximeter 1 will be added to the connected device list. Then, according to the mutual exclusion relationship of the devices, it is determined that the mutual exclusion devices of the oximeter 1 are oximeters 1 to 3 (including the oximeter 1 itself), the mutual exclusion device protocols adopted by the mutual exclusion devices include the device protocol 1 and the device protocol 4, and all devices in the existing device lists under the device protocol 1 and the device protocol 4 are the mutual exclusion devices, so that the device protocol 1 can be deleted from the device protocol group 1, and the device protocol 4 can be deleted from the device protocol group 2, so that the updated device protocol group 1 only includes the device protocols 2 to 3, and the updated device protocol group 2 only includes the device protocol 5, so that fewer device protocols can be polled in the subsequent polling of the device protocol group, and the polling efficiency and the device identification efficiency are improved.
In practical applications, an apparatus connected to a certain port may be abnormal for various reasons (for example, an apparatus failure, an apparatus power failure, an apparatus being disconnected manually or an apparatus connected to the port being replaced), and in order to timely discover the abnormal conditions and automatically identify another apparatus newly connected to the port, the embodiment of the present invention may further monitor an apparatus connection status of each port in the connected apparatus list. When the device connection state of a certain device (referred to as a second device on a second port) on a certain port is monitored to be disconnected or abnormally connected, the second port is closed, and the binding relationship between the second port and the second device is deleted in the connected device list. Then, according to the device mutual exclusion relationship, determining a second mutual exclusion device mutually exclusive to the second device and a second mutual exclusion device protocol adopted by the second mutual exclusion device, and adding the second mutual exclusion device protocol to the device protocol packet to which the second mutual exclusion device protocol belongs when the second mutual exclusion device protocol is deleted from the device protocol packet to which the second mutual exclusion device protocol belongs.
Continuing with the above example, in the event of disconnection or an abnormal connection of the device connection status of oximeter 1 at port 1, the embodiment of the present invention will shut down port 1, and at the same time, rejoin device protocol 1 to device protocol packet 1 and rejoin device protocol 4 to device protocol packet 2.
Specifically, when the device interaction mode adopts the second implementation manner, that is, when the device interaction mode includes the second, third, and fourth device interaction modes, detecting whether a device connection state of a certain device (referred to as a second device on the second port) on a certain port is disconnected or abnormal, specifically, the detecting may be:
(1) When the device interaction mode on the second port is a third device interaction mode in which the device automatically sends data and the data carries a device identifier, the disconnection means that the data is not received on the second port in a preset time window TweA, and the connection abnormality means that when the data received on the second port is detected to be mismatched with the device protocol adopted by the second device, the data received on the second port is detected to be mismatched with the device protocol adopted by the second device again after the data of a fourth time T4 is received on the second port.
(2) When the device interaction mode on the second port is a fourth device interaction mode in which the device automatically sends data and the data does not carry a device identifier, the disconnection means that after the data is not received on the second port in a preset time window TweB1, a request message is sent on the second port to request the device identifier, and a response is not received in a waiting time window TweB 2; the connection abnormality is that when it is detected that the data received at the second port does not match the device protocol used by the second device, after the data received at the second port is received for the fifth time T5, and it is detected again that the data received at the second port does not match the device protocol used by the second device, the connection abnormality is that the number of times of receiving erroneous response data reaches the sixth time T6 after a request message is sent at the second port to request a device identifier.
(3) And under the condition that the device interaction mode on the second port is the second device interaction mode that the device does not automatically send data, the disconnection means that after the data is not received on the second port in the preset time window TweC1, a request message is sent on the second port to request the device identifier, and the response data is not received in the time window TweC 2.
Here, the above time windows TweA and TweB1 are generally a first preset multiple of a maximum interval at which the second device automatically transmits data, and the first preset multiple is generally greater than or equal to 1. The time windows TweB2, tweC1, tweC2 are typically a second preset multiple of the maximum interval between the reception of the request message and the transmission of the response message by the second device, which second preset multiple is typically greater than or equal to 1. T4, T5 and T6 are typically integers greater than or equal to 1.
In the device interaction mode, the first implementation manner is adopted to detect whether the device connection state of a certain device on a certain port is disconnected or abnormal, and the detection may also be performed with reference to the specific implementation manner in the second implementation manner, which is not described herein again for saving space.
In the embodiment of the present invention, when the target system is initially operated, all the ports in the port list may be polled by performing the above steps 301 to 302. Here, when the port is a serial port or an internet port, all the ports in the port list refer to ports successfully opened by the target system; when the port is a bluetooth interface, all ports in the port list refer to ports of devices connected to the target system.
Since some ports may be reconnected with new devices during the execution of the method, in order to automatically discover a newly connected device, the polling operation in step 302 is periodically executed in the embodiment of the present invention, specifically, the target system may acquire a newly opened port in the port list according to a preset polling period TW0, and execute the polling operation for each newly opened port. Since the opened port cannot be opened again, the target system opens each port in the port list according to a preset polling period TW0, and takes the successfully opened port as the newly opened port.
Preferably, the polling period TW0 is the greater of the first time and the second time. The first time is N4 times a total polling time for polling all device protocols in the third device protocol packet and the fourth device protocol packet, and N4 is greater than or equal to 1. The second time is N5 times a sum of a total polling time for polling all device protocols in the second device protocol packet and the first time window Tw1, where N5 is greater than or equal to 1.
Through the steps, the embodiment of the invention can automatically process the normal disconnection and abnormal disconnection of the equipment in the equipment connection process, and quickly identify the equipment and complete reconnection after the equipment is reconnected.
To better facilitate understanding of the above aspects, specific embodiments of the above aspects are further described below by way of specific examples in connection with the several figures.
As shown in fig. 4, this example saves the relevant information in the database through pre-processing steps (including protocol pre-processing steps and pre-configuration steps). In the processing step, the method of the embodiment of the invention is used for automatic identification of the equipment. When the method of the embodiment of the invention is used in the target system for the first time, the preprocessing step is executed, and when the method is used again, the preprocessing step is not required to be executed, and the processing step is directly executed.
Specifically, in step 401 of the protocol preprocessing step, according to the device interaction mode, all device protocols supported by the target system and all devices possibly connected to the system are grouped to obtain a plurality of device protocol groups, where each device protocol group includes at least one device protocol. In step 402, for devices whose device protocol does not have an explicit device identification (device ID), the special data content sent by the device is designated as the device ID. The device protocol suite may be stored in a database.
In step 403 of the pre-configuration step, pre-connecting each existing device in a semi-manual and semi-automatic manner, connecting each existing device to a port of the target system, and then enabling the existing device to access the target system and to analyze data sent by the existing device normally by configuring device parameters and debugging the device, so as to obtain a device identifier of the existing device and device configuration parameters when the existing device successfully accesses the target system. Then, the device identifier and the device configuration parameter of the existing device are stored in the database, and may be specifically stored in the device protocol group under the device protocol to which the existing device belongs.
Thus, each device protocol packet is stored in the database, each device protocol packet includes at least one device protocol, and each device protocol includes a device identifier and a device configuration parameter of at least one existing device. Table 1 provides a data structure of the device protocol packets that may be used in this example in the database, and it can be seen that there may be at least one device protocol under each device protocol packet, and a device identifier and device configuration parameters thereof that use the protocol are stored under each device protocol.
Figure BDA0003090480670000211
Figure BDA0003090480670000221
TABLE 1
In the processing step, devices on the port are automatically identified using the method of an embodiment of the present invention. First, a main program is started, and in step 411 of the initialization step, all device protocols supported by the target system stored in advance in the database are loaded, and in step 412, port identification (port ID) information of all ports of the target system is loaded. Then, if the method is used for the first time, all the existing devices that may be connected need to be connected in advance (i.e. by performing step 403, the device identification and its device configuration parameters are obtained). If the method is not used for the first time, the method can automatically identify and access the equipment through periodic polling, and simultaneously solve the problems of abnormal interruption, automatic reconnection and the like in the equipment connection process.
In this example, the device protocols are grouped according to whether the device automatically sends data on the port and whether the data carries the device identifier when the data is automatically sent on the port, so as to obtain a group a, a group B, and a group C. In addition, the port has no device or the device is not recorded in the existing device list supported by the program, and the device list is used as the D group. Thus, the grouping results obtained are shown in table 2. It can be seen that the group a, the group B and the group C are respectively the third, the fourth and the second device protocol packets in the second implementation manner.
Figure BDA0003090480670000222
TABLE 2
Fig. 5 shows a schematic diagram of device identification in a scenario where a target system connects devices through a Hub (Hub). Here:
case1 (Case 1): the existing devices supported in the main program are connected to the port, and the specific steps can be:
case 1.1.1 corresponding to group a: the device automatically sends data to the port and there is a device ID field in the data.
Case 1.1.2 for group B: the device automatically sends data to the port, but there is no ID field in the data. And the main program sends an interaction command to the equipment through the port, and after the interaction command interacts with the equipment, the data containing the equipment ID is obtained.
Case 1.2 corresponding to group C: the device does not automatically send data to the port, the main program sends an interaction command to the device through the port, and the data containing the device ID is acquired after the main program interacts with the device.
Case2 (Case 2): the port is not connected to any device.
Case3 (Case 3): devices that are not supported in the program are connected to the port, e.g., the device is not recorded in the existing device list that the program supports. The correspondence between the above-mentioned various conditions and the protocol packets of the devices is as follows
Shown in table 3.
Figure BDA0003090480670000231
TABLE 3
Fig. 6 illustrates the way the program works during system initialization.
The system information initialization step is divided into two parts, namely a software part and a hardware part. Software initialization will primarily initialize device protocol related content (including data resolution protocols and communication protocols) and pre-configuration information (device configuration information) that is loaded into the program during system initialization. The hardware initialization is to read all port identifiers of the hardware where the program is located.
Fig. 7 shows the workflow of the pre-configuration step. The main purpose of the pre-configuration step is to confirm that the hardware performance is intact, that the connection between the target system and the device to be connected is intact, and that the device is capable of working properly by pre-commissioning the device.
In the pre-configuration step, the user may pre-connect the devices one by one. The user firstly confirms that the equipment is correctly connected to the target system, then selects corresponding equipment from the equipment list, sets serial port configuration information meeting equipment requirements, and then judges whether the equipment and the target system are successfully connected. If the connection is successfully established between the device and the target system, the pre-configured device configuration information is saved to the database and running program, otherwise the user re-checks all settings and physical connections.
Fig. 8 provides a workflow of a thread bound on a single port, and the workflow is described below by taking a serial port (serial port) as an example:
step 801: the main program opens the serial port. Here, for each serial port, if the opening is successful, a thread is bound to the serial port for managing all behaviors behind the serial port.
Step 802: after the serial port successfully binds the thread belonging to the serial port, the thread monitors whether data is input on the serial port, if so, the situation that the serial port belongs to case1.1 or case3 is shown, at this moment, step 803 is executed, and if no data is input in the time window Tw1, the situation that the serial port belongs to case2, case 1.2 or case3.2 is shown, at this moment, step 805 is executed.
Step 803: polling the device protocols of group a. When polling a device protocol, if the device identifier of the device An in the group A is identified in the received data, the device linked on the port is considered as the device An, and the serial port is bound with the device An; if T2 times of data is received, but the A group equipment is still not identified, the next equipment protocol in the A group is polled continuously until the equipment identification is identified or all the equipment protocols in the A group are polled. When all the device protocols in the group a have not recognized the device id after polling, step 804 is executed.
Step 804: and polling the B group of equipment protocols, wherein when one equipment protocol is polled, the thread sends an interactive command to the serial port according to the equipment protocol and waits for a response message of the receiving equipment to acquire an equipment identifier. If the device identifier of the device Bn in the group B is identified in the received data, the device connected to the port is considered as the device Bn, and the serial port is bound to the device Bn. If the interactive command (request message for requesting device identification) is sent for T3 times, the devices in the group B are still not recognized after the response message sent by the receiving device is sent for T1 times, or no response message is received within the time window Tw3 after the request message is sent, the next device protocol in the group B continues to be polled until the device identification is recognized or all device protocols in the group B are polled. And when the device identification is not recognized after all the device protocols in the group B are polled, the device is not considered to be the device type (Dn) supported by the program.
Step 805: polling the group C device protocols. The thread sends an interactive command (a request message requesting the device identification) to the serial port and waits for a response message from the receiving device to obtain the device identification. If the device identifier of the C group of device Cn is identified in the received data, the device connected to the port is considered as the device Cn, and the serial port and the device Cn are bound; if the device in the group C is not recognized after the interactive command for obtaining the device ID is sent T1 times, or no response message is received in the time window Tw2 after the interactive command is sent, continuing to poll the next device protocol in the group C until the device identifier is recognized or all the device protocols in the group C are polled. When all the device protocols in the group C poll and the device identification is not recognized, no device is considered to be connected to the serial port (case 2), or the device is a device type (Dn) which is not supported by the program.
After the device identifier is identified, the thread sends a message of successful identification to the main program and carries the identified device identifier, the main program updates a connected device list in all threads, and the binding relationship between the serial port identifier and the device identifier of the device is recorded in the connected device list.
It should be noted that, the values of T1, T2, and T3 in the above steps 803 to 805 may be the same or different, and may be specifically set according to requirements on the recognition efficiency and the recognition reliability, which is not specifically limited in the embodiment of the present invention.
Fig. 9 shows the operation of the program to automatically identify the devices in each group (illustrated by the example of a serial port).
At the beginning of each polling cycle (Tw 0), the program sends a port-opening command on each port to open all ports (serial ports). For each port, if the port is successfully opened, a thread is bound to the port.
For a device An belonging to the device group a (as An example shown in fig. 9, there is one device An on the port 1), a thread on the port 1 detects that data is received on the port 1, then polls all device protocols of the group a (detects whether there is a qualified device identifier in the received data by using each polled protocol), once the device identifier containing the device An is detected, the thread binds the port with the device An and sends a message to the main program, where the message carries the device identifier of the detected device An, then the main program sends An update message to the thread bound to each port, and updates the connected device list, that is, the binding relationship between the port 1 and the device An is added to the connected device list.
For a device Bn belonging to a device B group (as an example shown in fig. 9, there is a device Bn on a port 2), when a thread on the port 2 detects that data is received on the port 2, the protocols of all the device a groups are polled first, if no device identifier belonging to the device a group is found in T2 times of data received during polling of each protocol, the protocol of the device B group is polled continuously, at this time, the thread bound to the port 2 sequentially sends a command corresponding to each device protocol in the device B group to request a device identifier, and once the device identifier of the device Bn of the device B group is detected in the data that is responded, the port 2 is considered to be connected to the device Bn. Furthermore, the thread on the port 2 establishes a binding relationship between the port 2 and the device Bn, and sends a message of detecting the device Bn to the main program, and then the main program updates the connected device list to each thread.
For a device Cn belonging to device C group (as shown in the example in fig. 9, there is one device Cn on port 3), after the latency window Tw1, the thread on port 3 does not detect any data on port 3. At this time, the device protocols in the device C group are polled, port 3 requests a device identification by sending a command corresponding to each device protocol in the device C group, upon detecting the device ID of device Cn in the responsive data, a binding relationship of port 3 with device Cn is established, and a message that device Cn is detected is sent to the main program, which then updates the connected device list to the respective threads.
For a device Dn belonging to the device D group (one device Dn on port 4 as in the example shown in fig. 9), in Case3.2 (Case 3.2), when no data is detected on port 4 by the thread on port 4 after waiting for time window Tw1, first request a device identification by sending a command corresponding to each device protocol in the device C group, and if for each device protocol no device identification belonging to the device C group is found within time window Tw2 after sending the command, or no device identification is obtained by sending the command T1 times, the device on port 4 is considered as the device Dn. In Case 3.1 (Case 3.1), when a thread on port 4 detects that there is data on port 4, first poll all device protocols of group a, if no device identifier belonging to device group a is found in the received T2 times of data during polling of each protocol, continue polling the protocol of device group B, poll the devices of group B by sending a command corresponding to each device in device group B, and if no device identifier in device group B is obtained when the number of times of sending commands reaches T3 or no device identifier in device group B is obtained in a time window Tw3 after sending a command for each protocol, regard the device on port 4 as device Dn.
For case2 shown on port 5, when all device protocols of group C are polled, no response is received by the thread on port 5, and it is considered that there is no device on port 5.
In the embodiment of the invention, the equipment protocols are grouped according to the equipment interaction mode, then the ports are identified according to the equipment protocol groups, and each serial port polls different equipment protocol groups according to the data state of the serial port by taking the serial port as an example. Once the device identification is recognized, polling is stopped immediately, so that the number of polling protocols is effectively reduced, and the efficiency of device recognition is improved.
In addition, the above example of the present invention improves the device identification efficiency by optimizing the number of times data is transmitted/received and the time window. The parameters in the above examples include:
t1 to T3: the number of times data is received or transmitted is detected. By detecting the data received for multiple times and confirming whether the corresponding equipment identification exists in the data, the problem of identification failure caused by data damage in the data transmission process can be avoided, and meanwhile, the receiving and identifying times are limited, so that the identification efficiency can be ensured. For example, for a certain device protocol, after the first received data is identified as being lost, the data is received again to identify the device identification.
Tw0: the cycle time of the target system polling. The target system acquires the newly opened ports in the port list according to a preset polling cycle TW0, and performs the polling operation in step 302 for each newly opened port. Here, tw0 is the larger of the first time and the second time, for example, the first time may be 2 times the total polling time of the device protocols of the group a and the group B, and the second time may be 2 times the sum of the total polling time of the device protocols of the group C and Tw 1.
Tw1: a time window to wait for data when polling is started. N1 times the maximum transmission interval between two data when automatically transmitting data using the device protocols in group a and group B to ensure that a port can receive data when either a group a or group B device is connected to the port and transmits data to the port. For example, N1 takes the value 2.
Tw2: polling the group C device protocol, and waiting for a time window of data after sending the command. In the group C device protocol, after sending the interaction command, N2 times the maximum latency of the reply is obtained to ensure that the port can receive data when the group C device is connected to the port and sends data to the port.
Tw3: and when polling the B group of equipment, after sending a command, waiting for a time window of data. N3 times the maximum latency of waiting for a reply after sending a command using the group B device protocol to ensure that the port is able to receive data when there are group B devices connected to the port and sending data to the port.
In addition, the embodiment of the invention also avoids polling the mutual exclusion equipment in the equipment protocol polling by setting the mutual exclusion relationship of the equipment, thereby further improving the polling efficiency.
Fig. 10 shows the process of the present invention in the above example to handle normal or abnormal disconnection conditions of devices in each device protocol packet. The thread bound to the port releases port resources when automatically detecting that the device is disconnected, specifically:
for the device An belonging to group a (as shown in fig. 10, there is one device An on port 1), in Case a (Case a), if the thread on port 1 detects that no data is received within time window TweA, the device An is considered to be disconnected, the thread closes port 1 and notifies the main program to release the port resource of port 1, the main process releases the port resource of port 1, and sends An update message to the thread bound to each port, and updates the connected device list. In Case b (Case b), when detecting that the data on the port 1 is not matched with the data of the device An, the thread on the port 1 waits for receiving the T4-time data and then rechecks the data, and once the check result is that the data are not matched all the time, it is determined that the connection is abnormal, that is, the device on the port 1 is not the device An, and the thread closes the port 1 and notifies the main program to release the port resource of the port 1; and the main process releases the port resources of the port 1, sends an updating message to the thread bound by each port and updates the connected equipment list.
For a device Bn belonging to the device B group (as an example shown in fig. 10, there is a device Bn on port 2), in Case a (Case a), when the thread on port 2 detects that the data in the time window TweB1 disappears, it sends a command to port 2 to request a response from device Bn, and after waiting for the time window TweB2 and still not receiving the response, it considers that the device Bn is disconnected, and the thread closes port 2 and notifies the main program to release the port resource of port 2; and the main process releases the port resources of the port 2, sends an updating message to the thread bound by each port and updates the connected equipment list. If the situation is b (Case b), the thread on the port 2 detects that the data on the port 2 is not matched with the data of the device Bn, the thread re-checks the data after waiting for T5 times to receive the data, once the checking result is not matched all the time, the thread sends a command to request response to the device Bn through the port, if the received wrong response data reaches T6 times, the device on the port 2 is not the device Bn, the thread closes the port 2 and informs the main program to release the port resource of the port 2; the main process releases the port resource of the port 2, sends an update message to the thread bound by each port, and updates the connected equipment list.
For a device Cn belonging to device group C (as shown in fig. 10, there is a device Cn on port 3), the thread on port 3 detects that the data disappears within the time window TweC, and sends a command to port 3 to request a response of device Cn, and if the thread does not receive the data after waiting for the time window TweC, the device Cn is considered to be disconnected, and the thread closes port 3 and notifies the main program to release the port resource of port 3; the main process releases the port resources of the port 3, sends an update message to the thread bound by each port, and updates the connected device list.
Fig. 11 shows a schematic diagram of a polling operation performed periodically. The threads on the ports periodically poll the equipment on each port, periodically monitor the connection state of the equipment, and ensure the timely release of the ports and the timely reconnection of the equipment. The polling cycle of the equipment is Tw0, when each polling cycle starts, the thread bound by each port tries to open the port bound by the thread, and if the port is in an open state before, a message of losing the opening is returned; if the port was previously in a closed state, a successful open may be possible and a successful response message returned to the thread, at which point the port participates as a newly opened port in the polling round.
Based on the above identification method for multiple devices, an embodiment of the present invention further provides an identification apparatus for multiple devices, as shown in fig. 12, including:
an information obtaining module 121, configured to obtain a port list and a device protocol packet list of a target system, where the port list includes at least one port, the device protocol packet list includes multiple device protocol packets corresponding to different device interaction modes, each device protocol packet includes at least one device protocol supported by the target system on the port, and the device interaction mode is used to indicate whether a device automatically sends data;
a port polling module 122, configured to perform a polling operation on each port in the port list, where the polling operation includes: determining a target device protocol packet from the plurality of device protocol packets according to the device interaction mode on the port; and polling each device protocol in the target device protocol packet, and identifying the connected device on the port by adopting the currently polled device protocol.
Through the modules, the embodiment of the invention can improve the identification efficiency of the equipment on the port.
Preferably, the port polling module is further configured to, in polling each device protocol in the target device protocol packet, identify a device connected to the port by using the currently polled device protocol: if the equipment is successfully identified, the binding relationship between the port and the identified equipment is added in the connected equipment list; if the equipment cannot be identified, continuously polling the next equipment protocol in the target equipment protocol packet until the equipment is successfully identified or the equipment protocols in the target equipment protocol packet are polled.
Preferably, the port polling module is further configured to determine that the device is not connected to the port or the connected device is an unknown device if the device is still unidentified when all the device protocols in the target device protocol packet are polled.
Preferably, the identification device further comprises:
and the port control module is used for closing the ports of the unconnected equipment or the connected equipment which is the equipment with unknown protocol after the polling operation.
Preferably, the device protocol packet further includes an existing device list under each device protocol, and the existing device list records device identifiers of all existing devices supporting the device protocol; the identification device further comprises:
an information sharing module, configured to share the connected device list among the ports in the port list;
a first information maintenance module, configured to, after a binding relationship between a first port and a first device is added to a connected device list, determine, according to a preset device mutual exclusion relationship, a first mutually exclusive device that is mutually exclusive with the first device and a first mutually exclusive device protocol that is adopted by the first mutually exclusive device, where the device mutual exclusion relationship is used to indicate devices that cannot be simultaneously connected to the target system, and a mutually exclusive device of any device at least includes the device itself; and deleting the first mutually exclusive device protocol from the device protocol group to which the first mutually exclusive device protocol belongs under the condition that the existing device list under the first mutually exclusive device protocol only comprises the first mutually exclusive device.
Preferably, the identification device further comprises:
the port detection module is used for monitoring the equipment connection state of each port in the connected equipment list;
the abnormal processing module is used for closing the second port and deleting the binding relationship between the second port and the second equipment in the connected equipment list under the condition that the equipment connection state of the second equipment on the second port is disconnected or abnormal; according to the mutual exclusion relationship of the devices, determining a second mutual exclusion device mutually exclusive with the second device and a second mutual exclusion device protocol adopted by the second mutual exclusion device; adding the second mutually exclusive device protocol to the device protocol packet to which it belongs, in case the second mutually exclusive device protocol has been deleted from the device protocol packet to which it belongs.
Preferably, the plurality of device protocol packets include a first device protocol packet and a second device protocol packet, wherein the first device protocol packet corresponds to a first device interaction mode in which the device automatically transmits data, and the second device protocol packet corresponds to a second device interaction mode in which the device transmits data only when receiving a data request;
the port polling module comprises:
and the first judging module is used for judging whether the port receives data automatically sent by the equipment, if so, the protocol packet of the target equipment is determined to be a first equipment protocol packet, and if not, the protocol packet of the target equipment is determined to be a second equipment protocol packet.
Preferably, the port polling module further includes:
a first processing module, configured to, when the target device protocol packet is the first device protocol packet, analyze data received on the port to obtain a device identifier by using a device protocol polled currently; if the equipment identifier cannot be analyzed, adopting the currently polled equipment protocol to send a request message on the port to request the equipment identifier when the currently polled equipment protocol supports the interactive command;
and the second processing module is used for sending a request message on the port to request the equipment identification by adopting the currently polled equipment protocol under the condition that the target equipment protocol packet is the second equipment protocol packet.
Preferably, the device interaction mode is further configured to indicate whether the data automatically sent by the device carries a device identifier when the device automatically sends data on the port;
the multiple device protocol packets comprise a second device protocol packet, a third device protocol packet and a fourth device protocol packet, wherein the second device protocol packet corresponds to a second device interaction mode in which the device sends data only when receiving a data request, the third device protocol packet corresponds to a third device interaction mode in which the device automatically sends data and the data carries a device identifier, and the fourth device protocol packet corresponds to a fourth device interaction mode in which the device automatically sends data and the device identifier is not carried but an interaction command is supported;
the port polling module comprises:
the second judging module is used for judging whether the port receives data automatically sent by the equipment, and if so, determining that the target equipment protocol packet is the third equipment protocol packet or the fourth equipment protocol packet; otherwise, determining the target device protocol packet as the second device protocol packet.
Preferably, the port polling module further includes:
a third processing module, configured to poll each device protocol in the second device protocol packet when the target device protocol packet is the second device protocol packet, and send a request message to request a device identifier on the port by using the currently polled device protocol;
a fourth processing module, configured to poll each device protocol in the third device protocol packet first when the target device protocol packet is the third device protocol packet or the fourth device protocol packet, and analyze data received on the port to obtain a device identifier by using a currently polled device protocol; if the device identifier is not resolved when the polling of the device protocol in the third device protocol packet is finished, continuously polling each device protocol in the fourth device protocol packet, and sending a request message on the port to request the device identifier by adopting the currently polled device protocol.
Preferably, the second determining module is further configured to detect whether data is received at the port in a first time window Tw1, where a length of the first time window Tw1 is: n1 times of a first period, where the first period is a maximum transmission interval of automatically transmitting data by all existing devices in the third device protocol packet and the fourth device protocol packet, and N1 is greater than or equal to 1;
the third processing module is further configured to, in the process of polling each device protocol in the second device protocol packet, if the currently polled second device protocol is adopted, the device identifier sent by the device is not obtained when the number of times of sending the request message reaches a preset first number of times, or the device identifier sent by the device is not obtained in a second time window Tw2 after sending the request message, continue polling a next device protocol in the second device protocol packet, where the length of the second time window Tw2 is: n2 times of first waiting time, wherein the first waiting time is the maximum waiting time from the receiving of the request message to the sending of the equipment identifier of the existing equipment in the second equipment protocol, and N2 is greater than or equal to 1;
the fourth processing module is further configured to, in the process of polling each device protocol in the third device protocol packet, if the currently polled first device protocol is adopted, and the number of times that the data received at the port is analyzed but the device identifier is not obtained reaches a preset second number, continue polling a next device protocol in the third device protocol packet; and in the process of polling each device protocol in the fourth device protocol packet, if a currently polled third device protocol is adopted, and a device identifier sent by a device is not obtained when the number of times of sending a request message reaches a preset third number of times, or a response message sent by the device is not received in a third time window Tw3 after the request message is sent, continuing polling a next device protocol in the fourth device protocol packet, wherein the length of the third time window Tw3 is as follows: n3 times of a second waiting time, where the second waiting time is a maximum waiting time between receiving the request message and sending the device identifier by all existing devices in the third device protocol, and N3 is greater than or equal to 1.
Preferably, the identification device further includes:
the polling control module is used for acquiring newly opened ports in the port list according to a preset polling cycle TW0 and executing the polling operation aiming at each newly opened port; wherein,
wherein the polling period TW0 is the greater of the first time and the second time;
the first time is N4 times of a total polling time for polling all device protocols in the third device protocol packet and the fourth device protocol packet, and N4 is greater than or equal to 1;
the second time is N5 times a sum of the total polling time for polling all device protocols in the second device protocol packet and the first time window Tw1, where N5 is greater than or equal to 1.
Preferably, the identification device further comprises:
the protocol preprocessing module is used for determining all device protocols supported by the port of the target system, grouping all the device protocols according to the device interaction mode of each device protocol, and obtaining the device protocol grouping list and the device protocol under each device protocol grouping;
and the information pre-configuration module is used for connecting the existing equipment with a port of the target system, acquiring equipment configuration parameters and equipment identification when the existing equipment is successfully accessed into the target system, and storing the equipment configuration parameters and the equipment identification under an equipment protocol to which the existing equipment belongs in an equipment protocol packet.
Preferably, the protocol preprocessing module is further configured to specify a preset data content in the data sent by the device as the device identifier when the target device protocol does not define that the device identifier is carried in the data sent by the device.
Referring to fig. 13, an embodiment of the present invention further provides a hardware structure block diagram of an apparatus for identifying multiple devices, as shown in fig. 13, an apparatus 1300 for identifying multiple devices includes:
a processor 1302; and
a memory 1304, in which memory 1304 computer program instructions are stored,
wherein the computer program instructions, when executed by the processor, cause the processor 1302 to perform the steps of:
acquiring a port list and a device protocol packet list of a target system, wherein the port list comprises at least one port, the device protocol packet list comprises a plurality of device protocol packets corresponding to different device interaction modes, each device protocol packet comprises at least one device protocol supported by the target system on the port, and the device interaction mode is used for indicating whether a device automatically sends data;
performing a polling operation for each port in the port list, the polling operation comprising:
determining a target device protocol packet from the plurality of device protocol packets according to the device interaction mode on the port;
and polling each device protocol in the target device protocol packet, and identifying the connected device on the port by adopting the currently polled device protocol.
Further, as shown in fig. 13, the multi-device identification apparatus 1300 may further include a network interface 1301, an input device 1303, a hard disk 13013, and a display device 1306.
The various interfaces and devices described above may be interconnected by a bus architecture. The bus architecture may be a bus and bridge including any number of interconnects. One or more processors with computing capabilities, represented in particular by processor 1302, which may include a Central Processing Unit (CPU) and/or a Graphics Processing Unit (GPU), coupled together with various circuitry, represented by memory 1304, one or more memories. The bus architecture may also connect various other circuits such as peripheral devices, voltage regulators, and power management circuits to one another. It will be appreciated that a bus architecture is used to enable connectivity communications between these components. The bus architecture includes a power bus, a control bus, and a status signal bus, in addition to a data bus, all of which are well known in the art and therefore will not be described in detail herein.
The network interface 1301 can be connected to a network (e.g., the internet, a local area network, etc.), receive data (e.g., training data) from the network, and store the received data in the hard disk 13013.
The input device 1303 may receive various instructions input by an operator and send the instructions to the processor 1302 for execution. The input device 1303 may include a keyboard or a pointing device (e.g., a mouse, a trackball, a touch pad, a touch screen, etc.).
The display device 1306 may display a result obtained by the processor 1302 executing an instruction, for example, display a progress of model training and an answer prediction result.
The memory 1304 is used for storing programs and data necessary for operating system operation, and data such as intermediate results in the calculation process of the processor 1302.
It will be appreciated that the memory 1304 in embodiments of the present invention can be either volatile memory or nonvolatile memory, or can include both volatile and nonvolatile memory. The non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory, among others. Volatile memory can be Random Access Memory (RAM), which acts as external cache memory. The memory 1304 of the apparatus and methods described herein is intended to comprise, without being limited to, these and any other suitable types of memory.
In some embodiments, the memory 1304 stores the following elements, executable modules or data structures, or a subset thereof, or an expanded set thereof: an operating system 13041 and application programs 13042.
The operating system 13041 includes various system programs, such as a framework layer, a core library layer, a driver layer, and the like, and is used for implementing various basic services and processing hardware-based tasks. The application programs 13042 include various application programs such as a Browser (Browser) and the like for implementing various application services. Programs that implement methods of embodiments of the present invention can be included in application programs 13042.
The method for identifying multiple devices according to the above embodiments of the present invention may be applied to the processor 1302, or implemented by the processor 1302. The processor 1302 may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the above-described multi-device identification method may be implemented by instructions in the form of hardware integrated logic circuits or software in the processor 1302. The processor 1302 may be a general purpose processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other programmable logic device, discrete gate or transistor logic, or discrete hardware components that implement or perform the methods, steps, and logic blocks disclosed herein. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of the method disclosed in connection with the embodiments of the present invention may be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software module may be located in ram, flash memory, rom, prom, or eprom, registers, among other storage media that are well known in the art. The storage medium is located in the memory 1304, and the processor 1302 reads the information in the memory 1304 and completes the steps of the method in combination with hardware thereof.
It is to be understood that the embodiments described herein may be implemented in hardware, software, firmware, middleware, microcode, or a combination thereof. For a hardware implementation, the processing units may be implemented within one or more Application Specific Integrated Circuits (ASICs), digital Signal Processors (DSPs), digital Signal Processing Devices (DSPDs), programmable Logic Devices (PLDs), field Programmable Gate Arrays (FPGAs), general purpose processors, controllers, micro-controllers, microprocessors, other electronic units designed to perform the functions described herein, or a combination thereof.
For a software implementation, the techniques described herein may be implemented with modules (e.g., procedures, functions, and so on) that perform the functions described herein. The software codes may be stored in a memory and executed by a processor. The memory may be implemented within the processor or external to the processor.
In particular, the computer program, when executed by the processor 1302, may further implement the steps of:
it should be noted that the apparatus in this embodiment is an apparatus corresponding to the method shown in fig. 3, and the implementation manners in the above embodiments are all applicable to the embodiment of the apparatus, and the same technical effects can be achieved. The apparatus provided in the embodiment of the present invention can implement all the method steps implemented by the method embodiment, and can achieve the same technical effects, and detailed descriptions of the same parts and beneficial effects as the method embodiment in this embodiment are omitted here.
In some embodiments of the invention, there is also provided a computer readable storage medium having a program stored thereon, the program when executed by a processor implementing the steps of:
acquiring a port list and a device protocol packet list of a target system, wherein the port list comprises at least one port, the device protocol packet list comprises a plurality of device protocol packets corresponding to different device interaction modes, each device protocol packet comprises at least one device protocol supported by the target system on the port, and the device interaction mode is used for indicating whether a device automatically sends data;
performing a polling operation for each port in the port list, the polling operation comprising:
determining a target device protocol packet from the plurality of device protocol packets according to the device interaction mode on the port;
polling each device protocol in the target device protocol packet to attempt to identify the connected device on the port using the currently polled device protocol.
When executed by the processor, the program can implement all implementation manners in the multi-device identification method, and can achieve the same technical effect, and in order to avoid repetition, the program is not described herein again.
Those of ordinary skill in the art would appreciate that the elements and algorithm steps of the various embodiments described in connection with the embodiments disclosed herein may be implemented as electronic hardware, or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
It can be clearly understood by those skilled in the art that, for convenience and simplicity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one type of logical functional division, and other division manners may be available in actual implementation, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed coupling or direct coupling or communication connection between each other may be through some interfaces, indirect coupling or communication connection between devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment of the present invention.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The functions may be stored in a computer-readable storage medium if they are implemented in the form of software functional units and sold or used as separate products. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the multi-device identification method according to the embodiments of the present invention. And the aforementioned storage medium includes: various media that can store program codes, such as a U disk, a removable hard disk, a ROM, a RAM, a magnetic disk, or an optical disk.
The above description is only for the specific embodiment of the present invention, but the scope of the present invention is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present invention, and all the changes or substitutions should be covered within the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (30)

1. A method of multi-device identification, comprising:
acquiring a port list and a device protocol packet list of a target system, wherein the port list comprises at least one port, the device protocol packet list comprises a plurality of device protocol packets corresponding to different device interaction modes, each device protocol packet comprises at least one device protocol supported by the target system on the port, and the device interaction mode is used for indicating whether a device automatically sends data;
performing a polling operation for each port in the port list, the polling operation comprising:
determining a target device protocol packet from the plurality of device protocol packets according to the device interaction mode on the port;
and polling each device protocol in the target device protocol packet, and identifying the connected device on the port by adopting the currently polled device protocol.
2. The method according to claim 1, wherein the device protocol packet further includes an existing device list under each device protocol, and all existing devices supporting the device protocol are recorded in the existing device list; the method further comprises the following steps:
sharing a connected device list among all ports in the port list, wherein the connected device list records connected devices on all ports of a target system;
after a binding relationship between a first port and a first device is added in a connected device list, according to a preset device mutual exclusion relationship, determining a first mutual exclusion device which is mutually exclusive with the first device and a first mutual exclusion device protocol adopted by the first mutual exclusion device, wherein the device mutual exclusion relationship is used for indicating devices which cannot be simultaneously connected with a target system, and the mutual exclusion device of any device at least comprises the device;
and deleting the first mutual exclusion device protocol from the device protocol group to which the first mutual exclusion device protocol belongs under the condition that the existing device list under the first mutual exclusion device protocol only comprises the first mutual exclusion device.
3. The method of claim 2, further comprising:
monitoring the equipment connection state of each port in the connected equipment list;
under the condition that the connection disconnection or abnormal connection of the equipment connection state of the second equipment on the second port is monitored, closing the second port, and deleting the binding relationship between the second port and the second equipment in the connected equipment list;
according to the mutual exclusion relationship of the equipment, second mutual exclusion equipment which is mutually exclusive with the second equipment and a second mutual exclusion equipment protocol adopted by the second mutual exclusion equipment are determined;
adding the second mutually exclusive device protocol to the device protocol packet to which it belongs, in the event that the second mutually exclusive device protocol has been deleted from the device protocol packet to which it belongs.
4. The method according to claim 2, wherein the polling each device protocol in the target device protocol packet, using the currently polled device protocol, identifies the device connected to the port, and specifically includes: if the equipment is successfully identified, the binding relationship between the port and the identified equipment is added in the connected equipment list; if the equipment cannot be identified, continuously polling the next equipment protocol in the target equipment protocol packet until the equipment is successfully identified or the equipment protocols in the target equipment protocol packet are polled.
5. The method of claim 4, wherein when all device protocols in the target device protocol packet have been polled, if a device is still not identified, it is determined that the port is not connected to a device or the connected device is an unknown protocol device.
6. The method of claim 5, wherein after the polling operation, the method further comprises:
closing the ports of the unconnected device or the connected device as an unknown protocol device.
7. The method according to any one of claims 1 to 6,
the plurality of device protocol packets include a first device protocol packet corresponding to a first device interaction mode in which the device automatically transmits data and a second device protocol packet corresponding to a second device interaction mode in which the device transmits data only when receiving a data request;
determining a target device protocol packet from the plurality of device protocol packets according to the device interaction mode on the port, including: and judging whether the port receives data automatically sent by the equipment, if so, determining that the target equipment protocol packet is a first equipment protocol packet, and otherwise, determining that the target equipment protocol packet is a second equipment protocol packet.
8. The method of claim 7,
the polling each device protocol in the target device protocol packet, using the currently polled device protocol, to identify the device connected to the port, includes:
under the condition that the target equipment protocol packet is the first equipment protocol packet, adopting the currently polled equipment protocol to analyze the data received on the port to obtain an equipment identifier; if the equipment identifier cannot be analyzed, sending a request message on the port to request the equipment identifier when the currently polled equipment protocol supports an interactive command;
and under the condition that the target equipment protocol packet is the second equipment protocol packet, adopting the currently polled equipment protocol, and sending a request message on the port to request equipment identification.
9. The method according to any one of claims 1 to 6, wherein the device interaction mode is further configured to indicate whether a device identifier is carried in data automatically sent by a device when the device automatically sends the data on a port;
the multiple device protocol packets comprise a second device protocol packet, a third device protocol packet and a fourth device protocol packet, wherein the second device protocol packet corresponds to a second device interaction mode in which the device sends data only when receiving a data request, the third device protocol packet corresponds to a third device interaction mode in which the device automatically sends data and the data carries a device identifier, and the fourth device protocol packet corresponds to a fourth device interaction mode in which the device automatically sends data and the fourth device protocol packet does not carry the device identifier but supports an interaction command;
determining a target device protocol packet from the plurality of device protocol packets according to the device interaction mode on the port, including: judging whether the port receives data automatically sent by the equipment, if so, determining that the target equipment protocol packet is the third equipment protocol packet or the fourth equipment protocol packet; otherwise, determining the target device protocol packet as the second device protocol packet.
10. The method of claim 9, wherein said polling each device protocol in the target device protocol packet to identify the device connected to the port using the currently polled device protocol comprises:
polling each device protocol in the second device protocol packet under the condition that the target device protocol packet is the second device protocol packet, and sending a request message on the port to request a device identifier by adopting the currently polled device protocol;
when the target device protocol packet is the third device protocol packet or the fourth device protocol packet, polling each device protocol in the third device protocol packet, and analyzing data received on the port to acquire a device identifier by adopting the currently polled device protocol; if the device identifier is not resolved when the polling of the device protocol in the third device protocol packet is finished, continuously polling each device protocol in the fourth device protocol packet, and sending a request message on the port to request the device identifier by adopting the currently polled device protocol.
11. The method of claim 10,
judging whether the port receives data automatically sent by the equipment, specifically: detecting whether data is received on the port in a first time window Tw1, wherein the length of the first time window Tw1 is: n1 times of a first period, where the first period is a maximum transmission interval at which all existing devices in the third device protocol packet and the fourth device protocol packet automatically transmit data, and N1 is greater than or equal to 1;
in the process of polling each device protocol in the second device protocol packet, if the currently polled second device protocol is adopted, and the device identifier sent by the device is not obtained when the number of times of sending the request message reaches a preset first number of times, or the device identifier sent by the device is not obtained in a second time window Tw2 after sending the request message, continuing to poll the next device protocol in the second device protocol packet, where the length of the second time window Tw2 is: n2 times of first waiting time, wherein the first waiting time is the maximum waiting time from the reception of a request message to the transmission of an equipment identifier by the existing equipment in the second equipment protocol, and N2 is greater than or equal to 1;
in the process of polling each device protocol in the third device protocol packet, if the current polled first device protocol is adopted, the times of analyzing the data received by the port but not obtaining the device identification reach a preset second time, continuously polling the next device protocol in the third device protocol packet;
in the process of polling each device protocol in the fourth device protocol packet, if a currently polled third device protocol is adopted, a device identifier sent by a device is not obtained when the number of times of sending a request message reaches a preset third number of times, or a response message sent by the device is not received in a third time window Tw3 after the request message is sent, continuously polling a next device protocol in the fourth device protocol packet, where the length of the third time window Tw3 is: and N3 times of a second waiting time, wherein the second waiting time is the maximum waiting time between the reception of the request message and the transmission of the device identifier by all the existing devices in the third device protocol, and N3 is greater than or equal to 1.
12. The method of claim 11, further comprising:
acquiring newly opened ports in the port list according to a preset polling period TW0, and executing the polling operation aiming at each newly opened port;
wherein the polling period TW0 is the greater of the first time and the second time;
the first time is N4 times of a total polling time for polling all device protocols in the third device protocol packet and the fourth device protocol packet, and N4 is greater than or equal to 1;
the second time is N5 times a sum of the total polling time for polling all device protocols in the second device protocol packet and the first time window Tw1, where N5 is greater than or equal to 1.
13. The method of claim 2, wherein prior to obtaining the list of ports and the list of device protocol packets for the target system, the method further comprises:
determining all device protocols supported by the port of the target system, and grouping all the device protocols according to the device interaction mode of each device protocol to obtain the device protocol grouping list and the device protocol under each device protocol grouping;
connecting the existing equipment with the port of the target system, acquiring the equipment configuration parameters and the equipment identification when the existing equipment is successfully accessed into the target system, and storing the equipment configuration parameters and the equipment identification under the equipment protocol to which the existing equipment belongs in the equipment protocol packet.
14. The method according to claim 13, wherein in a case that the target device protocol does not define that the device identifier is carried in the data sent by the device, the preset data content in the data sent by the device is designated as the device identifier.
15. An apparatus for identifying multiple devices, comprising:
an information obtaining module, configured to obtain a port list and a device protocol packet list of a target system, where the port list includes at least one port, the device protocol packet list includes multiple device protocol packets corresponding to different device interaction modes, each device protocol packet includes at least one device protocol supported by the target system on the port, and the device interaction mode is used to indicate whether a device automatically sends data;
a port polling module, configured to perform a polling operation for each port in the port list, where the polling operation includes: determining a target device protocol packet from the plurality of device protocol packets according to the device interaction mode on the port; and polling each device protocol in the target device protocol packet, and identifying the connected device on the port by adopting the currently polled device protocol.
16. The apparatus according to claim 15, wherein the device protocol packet further includes an existing device list under each device protocol, and the existing device list records device identifiers of all existing devices supporting the device protocol; the identification device further comprises:
the information sharing module is used for sharing a connected device list among the ports in the port list, and the connected device list records connected devices on the ports of the target system;
a first information maintenance module, configured to, after a binding relationship between a first port and a first device is added in a connected device list, determine, according to a preset device mutual exclusion relationship, a first mutually exclusive device that is mutually exclusive with the first device and a first mutually exclusive device protocol that is adopted by the first mutually exclusive device, where the device mutual exclusion relationship is used to indicate devices that the target system cannot be connected at the same time, and a mutually exclusive device of any device at least includes the device itself; and deleting the first mutual exclusion device protocol from the device protocol group to which the first mutual exclusion device protocol belongs under the condition that the existing device list under the first mutual exclusion device protocol only comprises the first mutual exclusion device.
17. The identification device of claim 16, further comprising:
the port detection module is used for monitoring the equipment connection state of each port in the connected equipment list;
the exception handling module is used for closing the second port and deleting the binding relationship between the second port and the second equipment in the connected equipment list under the condition that the disconnection or abnormal connection of the equipment connection state of the second equipment on the second port is monitored; according to the mutual exclusion relationship of the devices, determining a second mutual exclusion device mutually exclusive with the second device and a second mutual exclusion device protocol adopted by the second mutual exclusion device; adding the second mutually exclusive device protocol to the device protocol packet to which it belongs, in case the second mutually exclusive device protocol has been deleted from the device protocol packet to which it belongs.
18. Identification means according to claim 16,
the port polling module is further configured to, in the process of polling each device protocol in the target device protocol packet, identifying a device connected to the port by using the currently polled device protocol: if the equipment is successfully identified, the binding relationship between the port and the identified equipment is added in the connected equipment list; and if the equipment cannot be identified, continuously polling the next equipment protocol in the target equipment protocol packet until the equipment is successfully identified or the equipment protocols in the target equipment protocol packet are polled.
19. Identification device according to claim 18,
the port polling module is further configured to determine that the port is not connected with a device or the connected device is an unknown device if the device protocol in the target device protocol packet is polled completely and the device is still not identified.
20. The identification device of claim 19, further comprising:
and the port control module is used for closing the ports of the unconnected equipment or the connected equipment as unknown protocol equipment after the polling operation.
21. Identification means according to any of claims 15 to 20,
the plurality of device protocol packets includes a first device protocol packet corresponding to a first device interaction mode in which the device automatically transmits data and a second device protocol packet corresponding to a second device interaction mode in which the device transmits data only when receiving a data request;
the port polling module comprises:
and the first judging module is used for judging whether the port receives data automatically sent by the equipment, if so, the protocol packet of the target equipment is determined to be a first equipment protocol packet, and if not, the protocol packet of the target equipment is determined to be a second equipment protocol packet.
22. Identification device according to claim 21,
the port polling module further comprises:
a first processing module, configured to, when the target device protocol packet is the first device protocol packet, analyze data received on the port by using a currently polled device protocol to obtain a device identifier; if the equipment identifier cannot be analyzed, sending a request message on the port to request the equipment identifier when the currently polled equipment protocol supports the interactive command;
and the second processing module is used for sending a request message on the port to request the equipment identification by adopting the currently polled equipment protocol under the condition that the target equipment protocol packet is the second equipment protocol packet.
23. The identification device according to any one of claims 15 to 20, wherein the device interaction mode is further configured to indicate whether a device identifier is carried in data automatically sent by a device when the device automatically sends data on a port;
the multiple device protocol packets comprise a second device protocol packet, a third device protocol packet and a fourth device protocol packet, wherein the second device protocol packet corresponds to a second device interaction mode in which the device sends data only when receiving a data request, the third device protocol packet corresponds to a third device interaction mode in which the device automatically sends data and the data carries a device identifier, and the fourth device protocol packet corresponds to a fourth device interaction mode in which the device automatically sends data and the fourth device protocol packet does not carry the device identifier but supports an interaction command;
the port polling module comprises:
the second judging module is used for judging whether the port receives data automatically sent by the equipment, and if so, determining that the target equipment protocol packet is the third equipment protocol packet or the fourth equipment protocol packet; otherwise, determining the target device protocol packet as the second device protocol packet.
24. Identification device according to claim 23,
the port polling module further includes:
a third processing module, configured to poll each device protocol in the second device protocol packet when the target device protocol packet is the second device protocol packet, and send a request message to request a device identifier on the port by using the currently polled device protocol;
a fourth processing module, configured to poll each device protocol in the third device protocol packet first when the target device protocol packet is the third device protocol packet or the fourth device protocol packet, and analyze data received on the port to obtain a device identifier by using a currently polled device protocol; if the device identifier is not resolved when the polling of the device protocol in the third device protocol packet is finished, continuously polling each device protocol in the fourth device protocol packet, and sending a request message on the port to request the device identifier by adopting the currently polled device protocol.
25. Identification means according to claim 24,
the second determining module is further configured to detect whether data is received at the port within a first time window Tw1, where a length of the first time window Tw1 is: n1 times of a first period, where the first period is a maximum transmission interval during which all existing devices in the third device protocol packet and the fourth device protocol packet automatically transmit data, and N1 is greater than or equal to 1;
the third processing module is further configured to, in the process of polling each device protocol in the second device protocol packet, if the currently polled second device protocol is used, the device identifier sent by the device is not obtained when the number of times of sending the request message reaches a preset first number of times, or the device identifier sent by the device is not obtained in a second time window Tw2 after the request message is sent, continue polling a next device protocol in the second device protocol packet, where the length of the second time window Tw2 is: n2 times of first waiting time, wherein the first waiting time is the maximum waiting time from the receiving of the request message to the sending of the equipment identifier by the existing equipment in the second equipment protocol, and N2 is greater than or equal to 1;
the fourth processing module is further configured to, in the process of polling each device protocol in the third device protocol packet, if the currently polled first device protocol is adopted, and the number of times that the data received at the port is analyzed but the device identifier is not obtained reaches a preset second number, continue polling a next device protocol in the third device protocol packet; and in the process of polling each device protocol in the fourth device protocol packet, if a currently polled third device protocol is adopted, and a device identifier sent by a device is not obtained when the number of times of sending the request message reaches a preset third number of times, or a response message sent by the device is not received in a third time window Tw3 after the request message is sent, continuing to poll the next device protocol in the fourth device protocol packet, where the length of the third time window Tw3 is: n3 times of a second waiting time, where the second waiting time is a maximum waiting time between receiving the request message and sending the device identifier by all existing devices in the third device protocol, and N3 is greater than or equal to 1.
26. The identification device of claim 25, further comprising:
the polling control module is used for acquiring newly opened ports in the port list according to a preset polling cycle TW0 and executing the polling operation aiming at each newly opened port; wherein,
wherein the polling period TW0 is the greater of the first time and the second time;
the first time is N4 times of a total polling time for polling all device protocols in the third device protocol packet and the fourth device protocol packet, and N4 is greater than or equal to 1;
the second time is N5 times a sum of a total polling time for polling all device protocols in the second device protocol packet and the first time window Tw1, where N5 is greater than or equal to 1.
27. The identification device of claim 16, further comprising:
the protocol preprocessing module is used for determining all device protocols supported by the port of the target system, and grouping all the device protocols according to the device interaction mode of each device protocol to obtain the device protocol grouping list and the device protocol under each device protocol grouping;
and the information pre-configuration module is used for connecting the existing equipment with a port of the target system, acquiring equipment configuration parameters and equipment identification when the existing equipment is successfully accessed into the target system, and storing the equipment configuration parameters and the equipment identification under an equipment protocol to which the existing equipment belongs in an equipment protocol packet.
28. Identification device according to claim 27,
the protocol preprocessing module is further configured to designate preset data content in the data sent by the device as the device identifier when the target device protocol does not define that the device identifier is carried in the data sent by the device.
29. An apparatus for identifying multiple devices, comprising:
a processor; and
a memory having computer program instructions stored therein,
wherein the computer program instructions, when executed by the processor, cause the processor to perform the steps of:
acquiring a port list and a device protocol packet list of a target system, wherein the port list comprises at least one port, the device protocol packet list comprises a plurality of device protocol packets corresponding to different device interaction modes, each device protocol packet comprises at least one device protocol supported by the target system on the port, and the device interaction mode is at least used for indicating whether a device automatically sends data;
performing a polling operation for each port in the port list, the polling operation comprising:
determining a target device protocol packet from the plurality of device protocol packets according to the device interaction mode on the port;
and polling each device protocol in the target device protocol packet, and identifying the connected device on the port by adopting the currently polled device protocol.
30. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the steps of a method for identification of a multiple device according to any one of claims 1 to 14.
CN202110593879.5A 2021-05-28 2021-05-28 Multi-device identification method and device and computer readable storage medium Pending CN115408316A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110593879.5A CN115408316A (en) 2021-05-28 2021-05-28 Multi-device identification method and device and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110593879.5A CN115408316A (en) 2021-05-28 2021-05-28 Multi-device identification method and device and computer readable storage medium

Publications (1)

Publication Number Publication Date
CN115408316A true CN115408316A (en) 2022-11-29

Family

ID=84155139

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110593879.5A Pending CN115408316A (en) 2021-05-28 2021-05-28 Multi-device identification method and device and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN115408316A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116170249A (en) * 2023-02-28 2023-05-26 上海致景信息科技有限公司 Universal bus type serial port communication method, system, equipment and storage medium

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030040897A1 (en) * 1996-04-03 2003-02-27 Murphy Thomas Andrew Man machine interface for power management control systems
US20060200571A1 (en) * 2005-03-07 2006-09-07 Microsoft Corporation Method and system for discovery via tribal knowledge
US20080172514A1 (en) * 2007-01-15 2008-07-17 Nec Corporation Packet communication device which selects an appropriate operation mode
CN105519071A (en) * 2013-05-21 2016-04-20 三星电子株式会社 Electronic device using logical channels for communication
EP3182295A1 (en) * 2015-12-18 2017-06-21 ViewMove Technologies Inc. Communication system with serial ports for automatically identifying device types and communication protocols and method thereof
CN110069439A (en) * 2018-01-24 2019-07-30 英特尔公司 Equipment certification
CN110213212A (en) * 2018-05-24 2019-09-06 腾讯科技(深圳)有限公司 A kind of classification method and device of equipment
US10602342B1 (en) * 2018-12-26 2020-03-24 T-Mobile Usa, Inc. SIM over-the-air update for non-IP devices
CN111193323A (en) * 2020-01-06 2020-05-22 山东电工电气集团新能科技有限公司 CAN bus-based power distribution network downlink equipment management device and method

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030040897A1 (en) * 1996-04-03 2003-02-27 Murphy Thomas Andrew Man machine interface for power management control systems
US20060200571A1 (en) * 2005-03-07 2006-09-07 Microsoft Corporation Method and system for discovery via tribal knowledge
US20080172514A1 (en) * 2007-01-15 2008-07-17 Nec Corporation Packet communication device which selects an appropriate operation mode
CN105519071A (en) * 2013-05-21 2016-04-20 三星电子株式会社 Electronic device using logical channels for communication
EP3182295A1 (en) * 2015-12-18 2017-06-21 ViewMove Technologies Inc. Communication system with serial ports for automatically identifying device types and communication protocols and method thereof
CN110069439A (en) * 2018-01-24 2019-07-30 英特尔公司 Equipment certification
CN110213212A (en) * 2018-05-24 2019-09-06 腾讯科技(深圳)有限公司 A kind of classification method and device of equipment
US10602342B1 (en) * 2018-12-26 2020-03-24 T-Mobile Usa, Inc. SIM over-the-air update for non-IP devices
CN111193323A (en) * 2020-01-06 2020-05-22 山东电工电气集团新能科技有限公司 CAN bus-based power distribution network downlink equipment management device and method

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116170249A (en) * 2023-02-28 2023-05-26 上海致景信息科技有限公司 Universal bus type serial port communication method, system, equipment and storage medium

Similar Documents

Publication Publication Date Title
CN111769978B (en) Method, device, terminal and system for offline information reporting of IoT devices
CN106445755A (en) Method for automatically testing integral cabinet servers
CN119473744B (en) Link test method, electronic device, storage medium, product and computing device
CN110134447A (en) The system and method for BMC immediate updating hard disk information based on operating system
WO2019010778A1 (en) Backup method and system for internet of things repeater
CN111858199A (en) A self-adaptive hard disk log collection method, system, terminal and storage medium
US20060224723A1 (en) Data updating system and method
CN115408316A (en) Multi-device identification method and device and computer readable storage medium
CN104995615A (en) Reservation and execution image writing of native computing devices
US20100180021A1 (en) Method and system for remote node debugging using an embedded node controller
TWI704460B (en) A method of maintaining memory sharing in clustered system
CN104598202A (en) Command line management device and method
US9003068B2 (en) Service channel for connecting a host computer to peripheral devices
US20140229602A1 (en) Management of node membership in a distributed system
US20210042093A1 (en) System and method that support production management
CN119402446A (en) A network card automatic binding method, device, equipment, medium and program product
CN118965367A (en) BIOS startup method and device, storage medium and electronic device
CN116719563A (en) Memory information acquisition method, device, equipment and storage medium
CN117056154A (en) A method, system, device and medium for detecting the network port function of a smart network card
CN115640181A (en) A testing system and method for an image processing device
US20240283720A1 (en) Abnormal recording system and the method for network gateway
CN109728924A (en) The method and apparatus for obtaining the configuration information of host
CN115811480B (en) File transfer performance testing method and device, electronic device, and storage medium
CN113128297A (en) Equipment docking method and device, electronic equipment and storage medium
CN111526043A (en) Embedded equipment, embedded system and maintenance method thereof

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