A device discovery method, electronic device, and storage medium

By generating verification and device identification information through a cloud platform, the problem of slow device discovery within a local area network is solved, enabling fast, secure, and lightweight device discovery.

CN121462624BActive Publication Date: 2026-04-24ZHEJIANG DAHUA TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
ZHEJIANG DAHUA TECH CO LTD
Filing Date
2026-01-05
Publication Date
2026-04-24

AI Technical Summary

Technical Problem

The problem of devices on a local area network being unable to quickly discover each other in existing technologies.

Method used

The system generates verification information through the cloud platform, receives device identification information from the terminal, generates first verification information and sends it to the master device, receives feedback information from candidate slave devices, determines slave devices based on the feedback information, generates a device list and sends it back to the terminal.

Benefits of technology

It enables fast, lightweight, and secure discovery of devices within a local area network, reduces the resource consumption of the main device, and is suitable for low-performance devices with limited memory.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121462624B_ABST
    Figure CN121462624B_ABST
Patent Text Reader

Abstract

The application provides a device discovery method, an electronic device and a storage medium, which are applied to a cloud platform. The method comprises the following steps: receiving first device identification information corresponding to a master device issued by a terminal; generating first verification information and sending the first verification information to the master device based on the first device identification information; receiving feedback information reported by a candidate slave device, and determining a slave device corresponding to the master device from the candidate slave device based on the feedback information; wherein the master device and the slave device are in the same local area network. The verification information generated by the cloud platform is used to quickly and lightly discover other slave devices in the local area network through the master device.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of network communication technology, and in particular to a device discovery method, electronic device, and storage medium. Background Technology

[0002] The Internet of Things (IoT) is a system that uses three core technologies—intelligent sensing, communication protocols, and data fusion—to connect physical devices (sensors, actuators, etc.) to a network, forming a digital mapping. Embedded devices can connect to public cloud IoT services, and control terminals can connect to an IoT hub to discover and manage embedded devices, enabling the interconnection of everything.

[0003] However, existing technologies have not solved the problem of devices quickly discovering each other within a local area network. Summary of the Invention

[0004] This application provides a device discovery method, electronic device, and storage medium to solve the problem that devices in a local area network cannot quickly discover each other in the prior art.

[0005] To address the aforementioned technical problems, the first technical solution adopted in this application is: to provide a device discovery method applied to a cloud platform, the device discovery method comprising:

[0006] Receive the first device identification information corresponding to the master device sent by the terminal;

[0007] Generate first verification information and send the first verification information to the master device based on the first device identification information;

[0008] The system receives feedback information reported by candidate slave devices and determines the slave device corresponding to the master device from among the candidate slave devices based on the feedback information; wherein the master device and the slave device are located in the same local area network.

[0009] In one embodiment, determining the slave device corresponding to the master device from candidate slave devices based on the feedback information includes:

[0010] Determine whether the feedback information corresponding to the candidate slave device matches the first verification information;

[0011] In response to a match, the candidate slave device is determined to be the slave device corresponding to the master device.

[0012] In one embodiment, receiving feedback information reported by the candidate slave device further includes:

[0013] Receive the second device identifier information corresponding to the candidate slave device;

[0014] After determining the slave device corresponding to the master device from the candidate slave devices based on the feedback information, the process also includes:

[0015] A device list is generated based on the second device identifier information corresponding to the device;

[0016] The device list is then sent back to the terminal.

[0017] In one embodiment, the device discovery method further includes:

[0018] Receive device management commands from the terminal;

[0019] The authentication information is generated based on the first verification information and the device management command and sent to the slave device; so that the slave device can confirm whether the slave device is legitimate based on the first verification information carried in the authentication information and the first verification information multicast by the master device.

[0020] In one embodiment, determining whether the feedback information corresponding to the candidate slave device matches the first verification information further includes:

[0021] If a mismatch is detected, the following step is returned: Receive the first device identifier information corresponding to the master device sent by the terminal.

[0022] To solve the above-mentioned technical problems, the second technical solution adopted in this application is: to provide a device discovery method, characterized in that it is applied to electronic devices, and the device discovery method includes:

[0023] The main device receives the first verification information from the cloud platform;

[0024] The master device multicasts the first verification information and the first device identification information corresponding to the master device; so that the candidate slave devices that receive the first verification information and the first device identification information report feedback information to the cloud platform, so that the cloud platform determines the slave device corresponding to the master device from the candidate slave devices based on the feedback information.

[0025] In one embodiment, the device discovery method further includes:

[0026] The device receives authentication information, which is generated by the cloud platform based on the first verification information and device management instructions.

[0027] The legitimacy of the slave device is confirmed based on the first verification information carried in the authentication information and the first verification information multicast by the master device.

[0028] In one embodiment, after the master device multicasts the first authentication information and the first device identifier information corresponding to the master device, it further includes:

[0029] The first authentication information for the master device multicast is cached from the device cache.

[0030] To solve the above-mentioned technical problems, the third technical solution adopted in this application is: to provide an electronic device, the electronic device including a memory and a processor coupled to each other, the processor being used to execute program instructions stored in the memory, and the processor being used to execute program data to implement the steps in the device discovery method described above.

[0031] To solve the above-mentioned technical problems, the fourth technical solution adopted in this application is: to provide a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, to implement the steps in the device discovery method described above.

[0032] The beneficial effects of this application are as follows: Unlike existing technologies, this application provides a device discovery method applied to a cloud platform. The method includes: receiving first device identification information corresponding to a master device sent by a terminal; generating first verification information and sending the first verification information to the master device based on the first device identification information; receiving feedback information reported by candidate slave devices, and determining the slave device corresponding to the master device from the candidate slave devices based on the feedback information; wherein the master device and the slave device are located within the same local area network. This application utilizes verification information generated by the cloud platform to quickly and lightweightly discover other slave devices within the local area network through the master device. Attached Figure Description

[0033] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0034] Figure 1 A flowchart illustrating the first embodiment of the device discovery method provided in this application;

[0035] Figure 2 A flowchart illustrating a second embodiment of the device discovery method provided in this application;

[0036] Figure 3 A flowchart illustrating a third embodiment of the device discovery method provided in this application;

[0037] Figure 4 A schematic flowchart of the fourth embodiment of the device discovery method provided in this application;

[0038] Figure 5 A schematic diagram of the framework of the fifth embodiment of the device discovery method provided in this application;

[0039] Figure 6 A timing diagram of the fifth embodiment of the device discovery method provided in this application;

[0040] Figure 7 A schematic diagram of the framework of an embodiment of the electronic device provided in this application;

[0041] Figure 8 A schematic diagram of a framework of an embodiment of the computer-readable storage medium provided in this application. Detailed Implementation

[0042] The embodiments of this application will now be described in detail with reference to the accompanying drawings.

[0043] In the following description, specific details such as particular system architectures, interfaces, and technologies are presented for illustrative purposes rather than for limiting purposes, in order to provide a thorough understanding of this application.

[0044] In this article, the term "and / or" simply describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A alone, A and B simultaneously, or B alone. Additionally, the character " / " generally indicates that the preceding and following related objects have an "or" relationship. Furthermore, "more" in this article means two or more objects.

[0045] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing embodiments of this application only and is not intended to limit this application.

[0046] Before providing a further detailed description of the embodiments of this application, the nouns and terms involved in the embodiments of this application will be explained, and the nouns and terms involved in the embodiments of this application shall be interpreted as follows.

[0047] The device discovery method provided in this application can be implemented collaboratively by a server and a terminal. In some embodiments, the terminal or server can implement the device discovery method provided in this application by running a computer program. For example, the computer program can be a native program or software module in an operating system; it can be a native application (APP), that is, a program that needs to be installed in the operating system to run, such as a client that supports virtual scenes, such as a game APP; it can also be a mini-program, that is, a program that only needs to be downloaded into a browser environment to run; or it can be a mini-program that can be embedded in any APP. In short, the above-mentioned computer program can be any form of application, module or plugin.

[0048] like Figure 1 As shown, Figure 1This is a flowchart illustrating a first embodiment of the device discovery method provided in this application. The device discovery method of this embodiment is applied to a cloud platform, and the device discovery method includes:

[0049] Step S11: Receive the first device identifier information corresponding to the master device sent by the terminal.

[0050] In this embodiment, the terminal can be a mobile phone or a mobile app, used to discover and manage electronic devices through a cloud platform. The cloud platform is a distributed computing service carrier based on the internet, capable of resource pooling, integrating hardware / software resources, and unified scheduling and allocation; it allows remote access, enabling access anytime, anywhere via the network, and supports multi-terminal collaboration; in addition, it has the advantage of high availability, with redundant deployment of multiple nodes to ensure service continuity. It can be understood that in this embodiment, the cloud platform acts as a "bridge," used to collaboratively discover and manage electronic devices. In this embodiment, the electronic device can be, for example, an IPC (IP Camera, network camera), including a master device and slave devices, where the master device is the electronic device that establishes a connection with the terminal through the cloud platform, and the slave devices are other electronic devices within the same local area network as the master device.

[0051] In one embodiment, both the terminal and the main device establish a connection with the cloud platform. Prior to the implementation of the device discovery method in this application, the terminal has already established a connection with the main device through the cloud platform and manages the main device. It should be noted that in the following embodiments of this application, the main device may, for example, be a low-performance device (low performance, limited memory).

[0052] It should be noted that the terminal has established a connection with the main device through the cloud platform and manages the main device. Understandably, the terminal can connect to the local area network connected to the main device, and thus query the primary device identifier information corresponding to the main device by scanning.

[0053] In one embodiment, based on the need to discover other devices within the same local area network as the main device, the terminal sends the first device identification information corresponding to the main device to the cloud platform. The first device identification information corresponding to the main device specifically refers to the main device's SN (Serial Number). The SN is a unique code, usually composed of numbers, letters, or a combination of both. It can be understood as an "ID number" and is used by manufacturers to identify specific products, devices, etc. In this embodiment, it can be used to represent the identity information of the main device and identify the main device.

[0054] Step S12: Generate first verification information and send the first verification information to the master device based on the first device identification information.

[0055] In one embodiment, after receiving the first device identification information (SN number) corresponding to the master device from the terminal, the cloud platform generates first verification information. This first verification information is a unique token generated by the cloud platform, which can be an encrypted numeric string used for device discovery and authentication. In this embodiment, the first verification information can be, for example, a random string of 32 bytes in length. Subsequent steps rely on this first verification information to verify the device identity, reducing the risk of password leakage. After generating the first verification information, the cloud platform locates the master device using its SN number and sends the first verification information to the master device.

[0056] Step S13: Receive feedback information reported by candidate slave devices, and determine the slave device corresponding to the master device from the candidate slave devices based on the feedback information.

[0057] It should be noted that the cloud platform establishes communication connections with both the master device and candidate slave devices via the MQTT (Message Queuing Telemetry Transport) protocol. Subsequent interactions between the devices and the cloud platform are based on this long-lived connection. In other words, the terminal communicates and exchanges messages with the master device and its corresponding slave devices through the cloud platform.

[0058] In one embodiment, all candidate slave devices establish a connection with the cloud platform. A slave device is an electronic device located on the same local area network as the master device. After the cloud platform sends verification information, the candidate slave devices connected to the cloud platform will receive the verification information. Only those that pass the verification are considered slave devices connected to the same local area network as the master device, thus achieving device discovery.

[0059] Specifically, the feedback information received by the cloud platform from candidate slave devices includes: receiving the second device identification information corresponding to the candidate slave device. Based on this, the feedback information received by the cloud platform from the candidate slave devices includes first verification information, first device identification information, and second device identification information. The second device identification information includes some identity information of the candidate slave device, such as IP address, MAC address, device type, etc. After receiving the feedback information from the candidate slave devices, the cloud platform determines the slave device corresponding to the master device from among the candidate slave devices based on the feedback information.

[0060] Determining the slave device corresponding to the master device from candidate slave devices based on feedback information further includes: determining whether the feedback information corresponding to the candidate slave device matches the first verification information. It is understood that the candidate slave device is determined to be the slave device corresponding to the master device by whether the first verification information in the feedback information corresponding to the candidate slave device matches the first verification information generated by the cloud platform.

[0061] In one embodiment, in response to the first verification information in the feedback information corresponding to the candidate slave device matching the first verification information generated by the cloud platform, the candidate slave device corresponding to the feedback information is determined as the slave device corresponding to the master device, and a device list is generated based on the second device identification information corresponding to the slave device; the device list is then fed back to the terminal.

[0062] In another embodiment, in response to a mismatch between the first verification information in the feedback information corresponding to the candidate slave device and the first verification information generated by the cloud platform, the process returns to the step of receiving the first device identifier information corresponding to the master device sent by the terminal. It is understood that since the communication link between the device and the cloud platform is encrypted, the information will not be maliciously tampered with. The first verification information multicast by the master device within the local area network is not encrypted, but because the local area network is in a relatively secure environment compared to the public network, the possibility of information tampering is low. If the first verification information is indeed maliciously tampered with, and the first verification information reported by the candidate slave device to the platform does not match the first verification information generated by the cloud platform, the cloud platform's verification of the first verification information fails, and it cannot discover the candidate slave device with tampered data. However, the cloud platform can trigger the process again to search, thereby avoiding this scenario.

[0063] This embodiment verifies the matching between the feedback information and the first verification information through the cloud platform, avoiding the burden on the main device to process device lists and concurrent messages, thus enabling low-performance devices such as IPCs to efficiently discover devices. This mechanism ensures the security of the device discovery process, prevents interference from unauthorized devices, and transfers data processing responsibility to the cloud platform, significantly reducing the main device's resource consumption, enhancing lightweight characteristics, and making it suitable for low-performance devices with limited memory, achieving faster and more secure LAN device discovery.

[0064] like Figure 2 As shown, Figure 2 This is a flowchart illustrating a second embodiment of the device discovery method provided in this application. Steps S21, S22, and S23 in this embodiment are the same as those described above. Figure 1 Steps S11, S12, and S13 in the embodiment are the same, and this embodiment further includes:

[0065] Step S24: Receive device management instructions from the terminal.

[0066] In one embodiment, in response to the device list fed back to the terminal by the cloud platform, the terminal sends a device management command to the cloud platform.

[0067] Step S25: Generate authentication information based on the first verification information and the device management command, and send it to the slave device; so that the slave device can confirm whether the slave device is legitimate based on the first verification information carried in the authentication information and the first verification information multicast by the master device.

[0068] It should be noted that the authentication information is dynamically generated by the cloud platform based on the first verification information and device management instructions, and includes the data structure required to confirm the legality of the device.

[0069] In one embodiment, the cloud platform sends authentication information to the slave device via a communication connection established using the MQTT protocol. Upon receiving the authentication information, the slave device compares the first verification information carried in the authentication information with the first verification information multicast by the master device. If they match, the slave device confirms its legitimacy. In specific implementations, authentication can be performed using structured information containing device identifier and timestamp fields; alternatively, the first verification information can be used as the implementation carrier of the authentication information, facilitating parsing and verification by the cloud platform.

[0070] This embodiment generates authentication information through a cloud platform and sends it to the slave device. The slave device can compare and confirm the first verification information in the authentication information with the first verification information multicast by the master device. This ensures the legitimacy of the master device managing other slave devices in the same local area network through the cloud platform and further improves the accuracy of the device discovery method.

[0071] like Figure 3 As shown, Figure 3 This is a flowchart illustrating a third embodiment of the device discovery method provided in this application. This embodiment provides a device discovery method applied to electronic devices. The device discovery method includes:

[0072] Step S31: The master device receives the first verification information from the cloud platform.

[0073] In this embodiment of the application, the electronic device includes a master device and a slave device. The slave device is selected from multiple candidate slave devices in the same local area network as the master device. In this embodiment, based on the need to discover other devices in the same local area network as the master device, the terminal sends the first device identification information corresponding to the master device to the cloud platform. After receiving the first device identification information corresponding to the master device sent by the terminal, the cloud platform generates first verification information and sends the first verification information to the master device.

[0074] Step S32: The master device multicasts the first verification information and the first device identification information corresponding to the master device; so that the candidate slave devices that receive the first verification information and the first device identification information report feedback information to the cloud platform, so that the cloud platform determines the slave device corresponding to the master device from the candidate slave devices based on the feedback information.

[0075] In one embodiment, the master device can be a low-performance device such as an IPC. Its multicast operation only requires sending a multicast message containing first authentication information and its own device identification information within the local area network (LAN), without encryption or data caching or processing. Candidate slave devices can be other devices within the LAN, such as IPC2-5. After receiving the multicast message, they directly send a feedback message (i.e., feedback information) to the cloud platform through the communication channel established with the public cloud. The feedback information includes first authentication information, first device identification information, and second device identification information. The second device identification information includes some identity information of the candidate slave device, such as IP address, MAC address, device type, etc. After receiving the feedback information, the cloud platform verifies the validity of the first authentication information to match the first device identification information corresponding to the master device, thereby determining the slave device list. The cloud platform then fills the device list with the second device identification information corresponding to the determined slave devices. The entire process does not require the master device to participate in data processing, which improves the efficiency of device discovery to a certain extent, enabling fast and lightweight discovery of other slave devices within the same LAN as the master device.

[0076] In the device discovery method provided in this embodiment, the master device only needs to perform two message exchanges (one communication with the cloud platform and one LAN multicast), significantly reducing the computational and storage burden on the device. This allows weak-performance devices, such as IPCs, to still achieve efficient device discovery even with limited memory or processing power. Candidate slave devices directly report feedback information to the cloud platform, which uniformly processes the data and verifies the first verification information. This avoids the performance bottleneck of the master device processing concurrent messages or caching device lists, improving the efficiency and applicability of device discovery. Simultaneously, the cloud platform's verification mechanism for the first verification information ensures communication security, effectively preventing device discovery failures caused by tampering with the first verification information. This enhances the system's reliability and robustness, adapting to the lightweight deployment requirements of weak-performance devices in LAN environments.

[0077] In one embodiment, after the master device multicasts the first authentication information and the first device identifier information corresponding to the master device, the process further includes: the slave device caching the first authentication information multicast by the master device. It is understood that the feedback information reported by the slave device includes, in addition to the second device identifier information, the first authentication information multicast by the master device and the first device identifier information corresponding to the master device. Therefore, after receiving the first authentication information multicast by the master device and the first device identifier information corresponding to the master device, the slave device needs to cache them before reporting them.

[0078] like Figure 4 As shown, Figure 4 This is a flowchart illustrating the fourth embodiment of the device discovery method provided in this application. Steps S41 and S42 in this embodiment are the same as those described above. Figure 1 Steps S31 and S32 in the embodiment are the same, and this embodiment further includes:

[0079] Step S43: Receive authentication information from the device. The authentication information is generated by the cloud platform based on the first verification information and the device management instructions.

[0080] Step S44: Confirm the legitimacy of the slave device based on the first verification information carried in the authentication information and the first verification information of the master device multicast.

[0081] In one embodiment, the cloud platform sends authentication information to the slave device via a communication connection established using the MQTT protocol. Upon receiving the authentication information, the slave device compares the first verification information carried in the authentication information with the first verification information multicast by the master device. If they match, the slave device confirms its legitimacy. In specific implementations, authentication can be performed using structured information containing device identifier and timestamp fields; alternatively, the first verification information can be used as the implementation carrier of the authentication information, facilitating parsing and verification by the cloud platform.

[0082] This embodiment generates authentication information through a cloud platform and sends it to the slave device. The slave device can compare and confirm the first verification information in the authentication information with the first verification information multicast by the master device. This ensures the legitimacy of the master device managing other slave devices in the same local area network through the cloud platform and further improves the accuracy of the device discovery method.

[0083] like Figure 5 As shown, Figure 5 This is a schematic diagram of the framework of the fifth embodiment of the device discovery method provided in this application. It should be noted that in this embodiment, the master device can be, for example, a low-performance device IPC. The master device can be any device that establishes a connection with the terminal through a cloud platform and is managed by the terminal through the cloud platform. In the following embodiments, IPC1 is the master device and IPC2-5 are slave devices.

[0084] In this embodiment, the cloud platform 20, the switch 30, and the electronic device 40 form a hierarchical architecture. It can be understood that in this embodiment, the switch 30 is a "network bridge" connecting the electronic device 40 and the cloud platform 20, the cloud platform 20 is a "centralized supply center" for resources and services, and the electronic device 40 is the "end user" of services, working together to achieve distributed computing and resource sharing.

[0085] In one embodiment, see Figure 6Based on the need to discover other devices on the same local area network as the master device IPC1, terminal 10 sends the first device identification information corresponding to the master device IPC1 to cloud platform 20. After receiving the first device identification information corresponding to the master device IPC1, cloud platform 20 generates first verification information, finds the corresponding master device IPC1 through the first device identification information, and sends the first verification information to the master device IPC1. Then, master device IPC1 multicasts the first verification information and its own corresponding first device identification information within the local area network. After receiving the multicast information from IPC1, candidate slave devices cache the first verification information multicast by the master device and report it to cloud platform 20. The cloud platform 20 receives feedback information reported by a candidate slave device, which includes first verification information, first device identification information, and second device identification information. After receiving the feedback information, the cloud platform 20 verifies whether the first verification information in the feedback information matches the first verification information sent to the master device IPC1. If they match, it means that the candidate slave device that sent the feedback information is in the same local area network as the master device IPC1. For example, if the first verification information in the feedback information reported by IPC2-5 matches the first verification information sent to the master device IPC1, it means that IPC2-5 is in the same local area network as the master device IPC1, thus determining that IPC2-5 is the slave device corresponding to the master device IPC1.

[0086] The cloud platform 20 further records the second device representation information from the feedback information reported by IPC2-5 in the device list and sends the device list to the terminal 10. The terminal 10 sends a device management command to the cloud platform 20 through the device list. The cloud platform 20 generates authentication information based on the first verification information and the device management command and sends it to the slave device IPC2-5. The slave device IPC2-5 confirms whether the slave device IPC2-5 is legitimate based on the first verification information carried in the authentication information and the first verification information multicast by the master device IPC1. When the first verification information carried in the authentication information is consistent with the first verification information multicast by the master device IPC1, the operation is considered legitimate, and the authentication result is returned to the cloud platform 20. The cloud platform 20 can manage the slave device IPC2-5 and upload the management results to the terminal. Furthermore, the terminal 10 can manage the slave device IPC2-5 through the cloud platform 20 and perform more configuration operations on the slave device IPC2-5.

[0087] In this embodiment, the master device IPC1 only needs to broadcast the first authentication information and its corresponding first device identification information to the cloud platform within the local area network. After receiving the first authentication information, IPC2-5 directly report the information to the cloud platform without requiring processing by the master device IPC1. Therefore, this embodiment is more lightweight to implement and can still be deployed on some low-performance devices.

[0088] Please see Figure 7 , Figure 7This is a schematic diagram of an embodiment of the electronic device provided in this application. The electronic device 90 includes a memory 91 and a processor 92 coupled to each other. The processor 92 is used to execute program instructions stored in the memory 91 to implement the steps of any of the device discovery method embodiments described above. In a specific implementation scenario, the electronic device 90 may include, but is not limited to, a microcomputer or a server. In addition, the electronic device 90 may also include mobile devices such as laptops and tablets, which are not limited here.

[0089] Specifically, processor 92 controls itself and memory 91 to implement the steps of any of the device discovery method embodiments described above. Processor 92 may also be referred to as a CPU (Central Processing Unit). Processor 92 may be an integrated circuit chip with signal processing capabilities. Processor 92 may also be a general-purpose processor, digital signal processor (DSP), application-specific integrated circuit (ASIC), field-programmable gate array (FPGA), or other programmable logic device, discrete gate or transistor logic device, or discrete hardware component. A general-purpose processor may be a microprocessor or any conventional processor. Furthermore, processor 92 may be implemented using integrated circuit chips.

[0090] Please see Figure 8 , Figure 8 This is a schematic diagram of an embodiment of a computer-readable storage medium provided in this application. The computer-readable storage medium 100 stores program instructions 1001 that can be executed by a processor. The program instructions 1001 are used to implement the steps of any of the above-described device discovery method embodiments.

[0091] In some embodiments, the functions or modules of the apparatus provided in this disclosure can be used to perform the methods described in the above method embodiments. The specific implementation can be referred to the description of the above method embodiments, and for the sake of brevity, it will not be repeated here.

[0092] The description of the various embodiments above tends to emphasize the differences between the various embodiments. The similarities or similarities between them can be referred to, and for the sake of brevity, they will not be repeated here.

[0093] In the several embodiments provided in this application, it should be understood that the disclosed methods and apparatus can be implemented in other ways. For example, the apparatus implementations described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection of devices or units may be electrical, mechanical, or other forms.

[0094] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0095] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) or processor to execute all or part of the steps of the methods of various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0096] The above are merely embodiments of this application and do not limit the scope of patent protection of this application. Any equivalent structural or procedural changes made using the content of this application’s specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the scope of patent protection of this application.

Claims

1. A device discovery method, characterized in that, Applied to a cloud platform, the method includes: receiving first device identification information corresponding to the master device sent by the terminal; Generate first verification information and send the first verification information to the master device based on the first device identification information; The system receives feedback information reported by candidate slave devices and determines the slave device corresponding to the master device from the candidate slave devices based on the feedback information; wherein the master device and the slave device are located in the same local area network; wherein the feedback information includes the first verification information, the first device identification information, and the second device identification information. Determining the slave device corresponding to the master device from the candidate slave devices based on the feedback information includes: determining whether the feedback information corresponding to the candidate slave device matches the first verification information; In response to a match, the candidate slave device is determined to be the slave device corresponding to the master device; Receive device management commands from the terminal; Based on the first verification information and the device management command, authentication information is generated and sent to the slave device; This enables the slave device to confirm its legitimacy based on the first verification information carried in the authentication information and the first verification information multicast by the master device.

2. The device discovery method according to claim 1, characterized in that, After determining the slave device corresponding to the master device from the candidate slave devices based on the feedback information, the method further includes: A device list is generated based on the second device identifier information corresponding to the slave device; The device list is then sent back to the terminal.

3. The device discovery method according to claim 1, characterized in that, Determining whether the feedback information corresponding to the candidate slave device matches the first verification information further includes: in response to a mismatch, returning to the step of receiving the first device identifier information corresponding to the master device sent by the terminal.

4. A device discovery method, characterized in that, Applied to electronic devices, the method includes: a main device receiving first verification information from a cloud platform; The master device multicasts the first verification information and the first device identification information corresponding to the master device. This enables the candidate slave device that receives the first verification information and the first device identification information to report feedback information to the cloud platform, so that the cloud platform can determine the slave device corresponding to the master device from the candidate slave devices based on the feedback information; The feedback information includes the first verification information, the first device identification information, and the second device identification information; if the feedback information corresponding to the candidate slave device matches the first verification information, the cloud platform determines that the candidate slave device is the slave device corresponding to the master device. The method further includes: receiving authentication information from the device, wherein the authentication information is generated by the cloud platform based on the first verification information and the device management instructions; The legitimacy of the slave device is confirmed based on the first verification information carried in the authentication information and the first verification information multicast by the master device.

5. The device discovery method according to claim 4, characterized in that, After the master device multicasts the first verification information and the first device identifier information corresponding to the master device, the process further includes: the slave device caching the first verification information multicast by the master device.

6. An electronic device, characterized in that, The electronic device includes a memory and a processor coupled to each other, the processor being configured to execute program instructions stored in the memory to implement the steps of the device discovery method as described in any one of claims 1 to 5.

7. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the steps of the device discovery method as described in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Communication method and device of passive NFC (Near Field Communication) equipment, electronic equipment and readable storage medium

    CN117202145A

  • Terminal equipment, server and multi-equipment collaborative login method

    CN117652134A