CN117177227A - Device discovery method, device, electronic device and storage medium - Google Patents

Device discovery method, device, electronic device and storage medium Download PDF

Info

Publication number
CN117177227A
CN117177227A CN202311218394.3A CN202311218394A CN117177227A CN 117177227 A CN117177227 A CN 117177227A CN 202311218394 A CN202311218394 A CN 202311218394A CN 117177227 A CN117177227 A CN 117177227A
Authority
CN
China
Prior art keywords
wifi
wifi information
information list
information
hot spot
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
CN202311218394.3A
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.)
China Telecom Technology Innovation Center
China Telecom Corp Ltd
Original Assignee
China Telecom Technology Innovation Center
China Telecom Corp 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 China Telecom Technology Innovation Center, China Telecom Corp Ltd filed Critical China Telecom Technology Innovation Center
Priority to CN202311218394.3A priority Critical patent/CN117177227A/en
Publication of CN117177227A publication Critical patent/CN117177227A/en
Pending legal-status Critical Current

Links

Abstract

The application discloses a device discovery method, a device, an electronic device and a storage medium, and belongs to the technical field of communication.

Description

Device discovery method, device, electronic device and storage medium
Technical Field
The present application relates to the field of communications technologies, and in particular, to a device discovery method, a device, an electronic device, and a storage medium.
Background
At present, a multi-hop network can be built between devices based on a wireless fidelity (Wireless Fidelity, wiFi) Direct connection (Direct) technology, so that the devices with weak cellular signals can realize internet access through the relay devices with strong cellular signals, the wireless coverage range of a cellular network operator is effectively enhanced, and the user internet surfing experience is improved.
Generally, before a multi-hop network is built, a device serving as an accessor needs to search and find a device of a WiFi Direct sharer (GO) in a near domain range, and then access the near domain network (or called a hotspot) shared by the device. The broadcasting and finding of the service information (or called hot spot access information) of the existing WiFi Direct GO is realized based on the service finding (Service Discovery protocol) of the WiFi Direct, but when the equipment of the sharer is in a screen-off state, an operating system of the equipment automatically sleeps for the service broadcasting of the WiFi Direct, so that the equipment of the accessor cannot search for the hot spot access information broadcasted by the equipment of the sharer, and the access is affected.
Disclosure of Invention
The embodiment of the application provides a device discovery method, a device, electronic equipment and a storage medium, which are used for solving the problems that in the WiFi Direct technology, when a sharer device is in a screen, an operating system of the device automatically sleeps for service broadcasting of the WiFi Direct, so that the device of a connector cannot search for the service broadcasting and cannot access.
In a first aspect, an embodiment of the present application provides a device discovery method, including:
the cloud server receives a device discovery request of a first device, wherein the device discovery request comprises a first WiFi information list of the periphery of the first device scanned by the first device;
Comparing the first WiFi information list with a stored second WiFi information list of each second device, wherein after a hotspot of a WiFi direct connection group is created by each second device, hotspot access information and the second WiFi information list around the cloud server are sent to each second device;
determining whether target equipment meeting WiFi direct connection discovery conditions exists in each second equipment or not based on whether WiFi information in the first WiFi information list is contained in each second WiFi information or not;
and if the target equipment is determined to exist, the stored hot spot access information of the target equipment is sent to the first equipment.
In some embodiments, determining whether a target device satisfying a WiFi direct discovery condition exists in each second device based on whether WiFi information in the first WiFi information list is included in each second WiFi information, includes:
if any one of the WiFi information in the first WiFi information list is contained in any one of the second WiFi information list, determining a second device corresponding to the second WiFi information list as a target device;
and if each WiFi information in the first WiFi information list is not contained in each second WiFi information list, determining that the target equipment does not exist.
In some embodiments, each second device periodically sends hotspot access information and a second WiFi information list to the cloud server, and further includes:
if any one of the WiFi information in the first WiFi information list is contained in any one of the second WiFi information lists, extracting an update time stamp of the second WiFi information list;
determining whether the second WiFi information list is aged based on the update time stamp and an update interval of the second WiFi information list;
and if the second WiFi information list is not aged, determining the second equipment as target equipment.
In a second aspect, an embodiment of the present application provides a device discovery method, including:
the first equipment scans WiFi information around the first equipment to obtain a first WiFi information list;
scanning and finding hot spot access information of the WiFi direct connection group on a WiFi direct connection broadcast channel; and is combined with
A device discovery request is sent to a cloud server, wherein the device discovery request comprises the first WiFi information list, the cloud server compares the first WiFi information list with stored second WiFi information lists of second devices, and after a hotspot of a WiFi direct connection group is created, each second device sends hotspot access information and the traced second WiFi information list around the second device to the cloud server; determining whether target equipment meeting WiFi direct connection discovery conditions exists in each second equipment or not based on whether WiFi information in the first WiFi information list is contained in each second WiFi information or not;
And receiving and storing hot spot access information of the target equipment, which is sent by the cloud server, wherein the hot spot access information is sent by the cloud server after the existence of the target equipment is determined.
In some embodiments, after storing the hotspot access information of the target device sent by the cloud server, the method further includes:
sending an access request to the target equipment, wherein the access request contains the hot spot access information;
and receiving successful access information sent by the target equipment.
In some embodiments, further comprising:
if the hot spot access information of the WiFi direct connection group is found by scanning on the WiFi direct connection broadcast channel, updating the stored hot spot access information by using the hot spot access information;
and if the hot spot access information sent by the cloud server is received again, updating the stored hot spot access information by using the hot spot access information.
In a third aspect, an embodiment of the present application provides a device discovery method, including:
the second equipment scans WiFi information around the second equipment to obtain a second WiFi information list;
after creating the hot spot of the WiFi direct connection group, broadcasting the hot spot access information of the WiFi direct connection group through the WiFi direct connection path; and is combined with
The hot spot access information and the second WiFi information list are sent to a cloud server for storage, and after a device discovery request of a first device is received by the cloud server, the first WiFi information list around the first device, which is scanned by the first device and is contained in the device discovery request, is compared with the stored second WiFi information list; and determining whether the second device is a target device meeting a WiFi direct connection discovery condition based on whether the WiFi information in the first WiFi information list is contained in the second WiFi information list.
In some embodiments, if the second device is a target device, further comprising:
receiving an access request sent by the first device, wherein the access request comprises the hot spot access information;
accessing the first equipment to the hot spot based on the hot spot access information;
and sending successful access information to the first equipment.
In some embodiments, wiFi information surrounding itself is periodically scanned to update the second WiFi information list; and
and periodically sending the hotspot access information of the hotspots and the latest second WiFi information list to a cloud server for storage.
In a fourth aspect, an embodiment of the present application provides a device discovery apparatus, where the device discovery apparatus is applied to a cloud server, and includes:
the device discovery module is used for receiving a device discovery request of a first device, wherein the device discovery request comprises a first WiFi information list of the periphery of the first device scanned by the first device;
the comparison module is used for comparing the first WiFi information list with the stored second WiFi information lists of the second devices, wherein after a hotspot of the WiFi direct connection group is created by each second device, hotspot access information and the second WiFi information list around the cloud server are sent to the cloud server;
the determining module is used for determining whether target equipment meeting WiFi direct connection discovery conditions exists in each second equipment or not based on whether WiFi information in the first WiFi information list is contained in each second WiFi information or not;
and the sending module is used for sending the stored hot spot access information of the target equipment to the first equipment if the target equipment is determined to exist.
In some embodiments, the determining module is specifically configured to:
if any one of the WiFi information in the first WiFi information list is contained in any one of the second WiFi information list, determining a second device corresponding to the second WiFi information list as a target device;
And if each WiFi information in the first WiFi information list is not contained in each second WiFi information list, determining that the target equipment does not exist.
In some embodiments, each second device periodically sends hotspot access information and a second WiFi information list to the cloud server, and further includes:
the aging judging module is used for extracting an update time stamp of the second WiFi information list if any WiFi information in the first WiFi information list is contained in any second WiFi information list; determining whether the second WiFi information list is aged based on the update time stamp and an update interval of the second WiFi information list;
and the determining module is further configured to determine the second device as a target device if it is determined that the second WiFi information list is not aged.
In a fifth aspect, an embodiment of the present application provides a device discovery apparatus, which is applied to a first device, including:
the WiFi scanning module is used for scanning the WiFi information around the WiFi scanning module to obtain a first WiFi information list;
the hotspot scanning module is used for scanning and finding hotspot access information of the WiFi direct connection group on a WiFi direct connection broadcast channel;
the device discovery module is used for sending a device discovery request to a cloud server, wherein the device discovery request comprises the first WiFi information list, the cloud server compares the first WiFi information list with the stored second WiFi information lists of all second devices, and each second device sends hot spot access information and the drawn second WiFi information list around the cloud server after creating a hot spot of a WiFi direct connection group; determining whether target equipment meeting WiFi direct connection discovery conditions exists in each second equipment or not based on whether WiFi information in the first WiFi information list is contained in each second WiFi information or not;
The receiving module is used for receiving and storing the hot spot access information of the target device, which is sent by the cloud server, wherein the hot spot access information is sent by the cloud server after the existence of the target device is determined.
In some embodiments, the system further comprises an access module for:
after storing the hot spot access information of the target equipment sent by the cloud server, sending an access request to the target equipment, wherein the access request contains the hot spot access information;
and receiving successful access information sent by the target equipment.
In some embodiments, the system further comprises an update module for:
if the hot spot access information of the WiFi direct connection group is found by scanning on the WiFi direct connection broadcast channel, updating the stored hot spot access information by using the hot spot access information;
and if the hot spot access information sent by the cloud server is received again, updating the stored hot spot access information by using the hot spot access information.
In a sixth aspect, an embodiment of the present application provides a device discovery apparatus, which is applied to a second device, including:
the scanning module is used for scanning the WiFi information around the scanning module to obtain a second WiFi information list;
The broadcast module is used for broadcasting the hot spot access information of the broadcast module through the WiFi direct connection path after the hot spot of the WiFi direct connection group is created;
the sending module is used for sending the hot spot access information and the second WiFi information list to the cloud server for storage, and the cloud server compares the first WiFi information list around the first equipment scanned by the first equipment contained in the equipment discovery request with the stored second WiFi information list after receiving the equipment discovery request of the first equipment; and determining whether the second device is a target device meeting a WiFi direct connection discovery condition based on whether the WiFi information in the first WiFi information list is contained in the second WiFi information list.
In some embodiments, if the second device is a target device, the method further includes an access module configured to:
receiving an access request sent by the first device, wherein the access request comprises the hot spot access information;
accessing the first equipment to the hot spot based on the hot spot access information;
and sending successful access information to the first equipment.
In some embodiments, wiFi information surrounding itself is periodically scanned to update the second WiFi information list; and
And periodically sending the hotspot access information of the hotspots and the latest second WiFi information list to a cloud server for storage.
In a seventh aspect, an embodiment of the present application provides a device discovery system, including:
each second device is used for scanning the WiFi information around the second device to obtain a second WiFi information list, and broadcasting the hotspot access information of the second device through a WiFi direct connection path after creating the hotspot of the WiFi direct connection group; the hot spot access information and the second WiFi information list are sent to a cloud server;
the first equipment is used for scanning WiFi information around the first equipment to obtain a first WiFi information list, and scanning and finding hot spot access information of the WiFi direct connection group on a WiFi direct connection broadcast channel; sending a device discovery request to the cloud server, wherein the device discovery request comprises the first WiFi information list;
the cloud server is configured to store the hotspot access information and the second WiFi information lists sent by each second device, compare the first WiFi information list with each second WiFi information list after receiving the device discovery request, and determine whether a target device satisfying a WiFi direct connection discovery condition exists in each second device based on whether WiFi information in the first WiFi information list is included in each second WiFi information; and if the target equipment is determined to exist, the stored hot spot access information of the target equipment is sent to the first equipment.
In an eighth aspect, an embodiment of the present application provides an electronic device, including: at least one processor, and a memory communicatively coupled to the at least one processor, wherein:
the memory stores a computer program executable by at least one processor to enable the at least one processor to perform the device discovery method described above.
In a ninth aspect, an embodiment of the present application provides a storage medium, which when executed by a processor of an electronic device, is capable of performing the above-described device discovery method.
In the embodiment of the application, the cloud server stores the hot spot access information of each second device serving as a sharer and the WiFi information obtained by scanning the periphery, and subsequently, when the first device requests to discover the device, the first device selects the target device meeting the discovery condition from each second device based on the WiFi information obtained by scanning the periphery of the first device and the WiFi information of each second device, and sends the stored hot spot access information of the target device to the first device.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this specification, illustrate embodiments of the application and together with the description serve to explain the application and do not constitute a limitation on the application. In the drawings:
fig. 1 is a schematic application scenario diagram of a device discovery method according to an embodiment of the present application;
fig. 2 is an interaction flow chart of a device discovery method according to an embodiment of the present application;
fig. 3 is a schematic diagram of a device discovery process according to an embodiment of the present application;
fig. 4 is a flowchart of a device discovery method according to an embodiment of the present application;
fig. 5 is a flowchart of another device discovery method according to an embodiment of the present application;
FIG. 6 is a flowchart of another method for device discovery according to an embodiment of the application;
fig. 7 is a schematic structural diagram of a device discovery apparatus according to an embodiment of the present application;
fig. 8 is a schematic structural diagram of another device discovery apparatus according to an embodiment of the present application;
fig. 9 is a schematic structural diagram of yet another device discovery apparatus according to an embodiment of the application;
fig. 10 is a schematic hardware structure of an electronic device for implementing a device discovery method according to an embodiment of the present application.
Detailed Description
In order to solve the problems that in the WiFi Direct technology, when a sharer's equipment is on screen, an operating system of the equipment automatically sleeps for service broadcasting of the WiFi Direct, so that the equipment of a connector cannot search for the service broadcasting and cannot be accessed, the embodiment of the application provides an equipment discovery method, an equipment discovery device, electronic equipment and a storage medium.
The preferred embodiments of the present application will be described below with reference to the accompanying drawings of the specification, it being understood that the preferred embodiments described herein are for illustration and explanation only, and not for limitation of the present application, and embodiments of the present application and features of the embodiments may be combined with each other without conflict.
In order to facilitate understanding of the present application, the present application relates to the technical terms:
WiFi Direct refers to a technology allowing devices in a WiFi wireless network to be connected with each other without a WiFi wireless router, and similar to Bluetooth technology, wiFi Direct allows WiFi wireless devices to be connected in a point-to-point mode, and the transmission speed and the transmission distance are greatly improved compared with Bluetooth.
LC (liquid crystal): legacy clients refer to conventional WiFi clients.
GC: group Client, meaning Client of WiFi Direct Group, i.e., the accessor of the WiFi Direct Group.
GO: group Owner, owner for WiFi Direct Group, i.e., creator of the WiFi Direct Group.
Service discovery (Service Discovery, SD), is a pre-association service discovery that WiFi Direct API is enhanced in Android 4.1 to support in the WiFi p2 pManager. This allows surrounding devices to be discovered and screened through a Service (Service) using WiFi Direct prior to connection.
Service set identifier (Service Set Identifier, SSID), which is the name of a WiFi wireless local area network, is a case-specific text string, and has a maximum length of not more than 32 characters.
A media access control (Media Access Control Address, MAC) Address, also known as Physical Address (Physical Address), is an Address on a network device (e.g., computer, router, switch, etc.) that is used to identify a network interface. Each network interface has a unique MAC address, typically consisting of 12 hexadecimal digits (0-9 and a-F), separated by a colon or dash.
The advanced encryption standard (Advanced Encryption Standard, AES), also known in cryptography as Rijndael encryption, is a block encryption standard.
The Base64 algorithm, a method of representing binary data using 64 printable characters.
And the unique identifier of the Android device is a 64-bit hexadecimal character string generated by the system.
Javascript object notation (JavaScript Object Notation, json), a lightweight data interchange format. The data is stored and represented in a text format that is completely independent of the programming language. The simple and clear hierarchical structure enables the JSON to be an ideal data exchange language, is easy to read and write by people, is easy to analyze and generate by machines, and can effectively improve the network transmission efficiency.
The application provides a cloud auxiliary discovery method for near-field network sharing equipment based on third-party WiFi information. The access device is newly added with cloud auxiliary discovery means on the basis of acquiring the broadcast ciphertext of the sharing device by scanning the WiFi Direct broadcast channel. Specifically, the access device sends the searched peripheral third-party WiFi information (SSID and Mac address) to the cloud server, requests to obtain the broadcast ciphertext of the sharing device with the same third-party WiFi information, decrypts the WiFi SSID and the access password of the sharing device from the broadcast ciphertext, and achieves WiFi access in the same near-field space, so that the problem that the access device cannot search the sharing device because the operating system stops broadcasting service information of WiFi Direct outwards due to a dormancy strategy when the sharing device is in a screen-off state is solved.
Referring to fig. 1, fig. 1 is a schematic diagram of a device discovery system according to an embodiment of the present application, including a cloud server 100, a first device 200 (an access device), and two second devices 300 (sharing devices). The first device 200 and the cloud server 100 may communicate with each other by using a wired communication technology, for example, communication is performed through a connection network cable or a serial port cable; the communication may also be performed by a wireless communication technology, for example, by a bluetooth or WIFI technology, which is not particularly limited. Each second device 300 may also communicate with the cloud server 100 by using a wired communication technology, for example, communication is performed through a connection network cable or a serial port cable; the communication may also be performed by a wireless communication technology, for example, by a bluetooth or WIFI technology, which is not particularly limited. The first device 200 and the second device 300 meeting the conditions can communicate through WIFI direct technology.
The device discovery system provided by the embodiment of the application comprises:
each second device is used for scanning the WiFi information around the second device to obtain a second WiFi information list, and broadcasting the hotspot access information of the second device through a WiFi direct connection path after creating the hotspot of the WiFi direct connection group; the hot spot access information and the second WiFi information list are sent to a cloud server;
The first equipment is used for scanning WiFi information around the first equipment to obtain a first WiFi information list, and scanning and finding hot spot access information of the WiFi direct connection group on a WiFi direct connection broadcast channel; sending a device discovery request to a cloud server, wherein the device discovery request comprises the first WiFi information list;
the cloud server is used for storing the hot spot access information and the second WiFi information list sent by each second device, comparing the first WiFi information list with each second WiFi information list after receiving the device discovery request, and determining whether target devices meeting WiFi direct connection discovery conditions exist in each second device based on whether WiFi information in the first WiFi information list is contained in each second WiFi information; and if the target equipment is determined to exist, the stored hot spot access information of the target equipment is sent to the first equipment.
The device discovery scheme provided by the embodiment of the application is that a cloud-assisted path is newly added to forward the same service broadcast information on the basis of the original scheme, so that the problem of broadcast interruption during the screen-off period of the device of the sharer is solved, and the access success rate can be effectively improved.
The device discovery method provided by the embodiment of the application is described below with reference to fig. 1. Referring to fig. 2, fig. 2 is an interaction flow chart of a device discovery method according to an embodiment of the present application, including the following steps:
In step 201, each second device scans WiFi information around itself to obtain a second WiFi information list.
In step 202, after creating the hotspots of the WiFi direct group, each second device broadcasts its own hotspot access information through the WiFi direct path, and sends the hotspot access information and the second WiFi information list to the cloud server.
In step 203, the first device scans WiFi information around itself to obtain a first WiFi information list.
In step 204, the first device scans and discovers hot spot access information of the WiFi direct group on a broadcast channel of the WiFi direct; and sending a device discovery request to the cloud server, wherein the device discovery request comprises a first WiFi information list.
That is, the first device acting as an accessor may enable both device discovery modes to discover hotspot access information.
In step 205, the cloud server compares the first WiFi information list with the stored second WiFi information lists of the second devices.
In step 206, the cloud server determines whether a target device satisfying the WiFi direct connection discovery condition exists in each second device based on whether the WiFi information in the first WiFi information list is included in each second WiFi information.
For example, if any one WiFi information in the first WiFi information list is included in any one second WiFi information list, it is indicated that the second devices corresponding to the first device and the second WiFi information list search for the same WiFi router and are in the same near-domain space, and then the corresponding second devices can be determined as target devices; if each piece of WiFi information in the first WiFi information list is not contained in each piece of second WiFi information list, the first equipment and any piece of second equipment are not located in the same near-field space, namely, no target equipment exists.
In fact, when the first device and a second device are in the same near-domain space, the second device may still share the hot spot and may already close the hot spot, so that in order to further improve the access success rate, the second device may also periodically scan WiFi information around itself, and periodically send the hot spot access information and the second WiFi information list to the cloud server. Subsequently, after determining that any WiFi information in the first WiFi information list is included in any second WiFi information list, an update time stamp of the second WiFi information list may also be extracted, then, based on the update time stamp and an update interval of the second WiFi information list, whether the second WiFi information list is aged is determined, and after determining that the second WiFi information list is not aged, the second device is determined to be the target device.
If the sum exceeds the current time, determining that the second WiFi information list is aged, which indicates that the corresponding second device may have finished sharing; and if the second WiFi information list does not exceed the current moment, determining that the second WiFi information list is not aged, and the corresponding second equipment is sharing the hot spot.
The period of scanning the WiFi information around each second device may be the same or different from the period of sending the hotspot access information and the second WiFi information list to the cloud server.
In step 207, if the cloud server determines that the target device exists, the cloud server sends the stored hotspot access information of the target device to the first device.
In step 208, the first device stores hotspot access information for the target device.
It should be noted that, if the first device scans and discovers the hotspot access information of the WiFi direct connection group on the WiFi direct connection broadcast channel, the first device may further update the stored hotspot access information by using the hotspot access information, and if the first device receives the hotspot access information sent by the cloud server again, the first device may also update the stored hotspot access information by using the hotspot access information. That is, the first device may discover the hot spot access information of the device by using both device discovery methods, and the latest discovered hot spot access information stores the hot spot access information.
In step 209, the first device sends an access request to the target device, where the access request includes hotspot access information.
In step 210, the target device accesses the first device to the hotspot based on the hotspot access information.
Namely, the target device establishes a WiFi direct connection with the first device.
In step 211, the target device sends successful access information to the first device.
The scheme provided by the embodiment of the application is that a cloud-assisted path is newly added to forward the same service broadcast information on the basis of the original scheme, so that the problem of broadcast interruption during the screen-off period of the equipment of the sharer is solved. The improvement is that when the space-time intersection of the sharer and the device of the connector is sought, once the intersection occurs, the server can broadcast a message to the device of the connector, and the device of the connector can implement subsequent connection operation.
In the implementation, the cloud server may store the device identifier of the second device, the broadcast ciphertext, and the second WiFi information list in a local or database. The data structure at the time of storage is first described below.
The meaning of the fields involved is as follows:
DeviceID, string type, variable length, is the unique identification of the device;
CipherServiceInfo, string type, variable length, AES encrypted and Base64 encoded broadcast service information string (WiFi SSID and password with second device);
the NearbyWiFiList, the character string type, the variable length, the third party WiFi information list around the device searched, and the Json format character string;
UpdateTime, long integer type, update timestamp, and updates this field each time an upload message is received by the second device.
The device discovery scheme provided by the embodiment of the present application is described below with reference to the above fields and the schematic device discovery process shown in fig. 3.
(1) Before the second device creates the WiFi Direct GO hot spot, the second device can scan and collect WiFi signals around the second device to obtain a second WiFi information list, and before the first device is accessed, the first device can scan and collect WiFi signals around the second device to obtain a first WiFi information list.
As shown in fig. 3, assume that there are N WiFi routers: wiFi router 1 (SSID: AAAA, mac address: 1111), wiFi router 2 (SSID: BBBB, mac address: 2222), … … WiFi router N (SSID: ZZZZ, mac address: 9999), N being a positive integer.
And assuming that the second device scans the obtained second WiFi information list as { (SSID: AAAA, mac address: 1111), (SSID: BBBB, mac address: 2222) }, the first device scans the obtained first WiFi information list as { (SSID: BBBB, mac address: 2222), (SSID: ZZZZ, mac address: 9999)).
(2) And the second device creates a WiFi Direct GO hotspot.
Suppose the hotspot access information is SSID: P-RAN, password: password.
(3) After the second device creates the WiFi Direct GO hotspot, the second device uses the original WiFi Direct path to broadcast the ciphertext of the WiFi SSID and the password, and uploads the broadcast ciphertext and the second WiFi information list to the cloud server.
For example, the Json format of the upload message is as follows:
(4) the first device scans and receives a broadcast ciphertext on a broadcast channel of the WiFi Direct, and sends a device discovery request to the cloud server to request acquisition of surrounding broadcast ciphertext, wherein parameters carried in the request are a first WiFi information list.
For example, the Json format of the information in the request is as follows:
(5) after receiving the device discovery request of the first device, the cloud server extracts a first WiFi information list in the request, matches the first WiFi information list with a second WiFi information list of the stored second device, and if at least one WiFi information in the first WiFi information list and any one WiFi information list is the same (namely SSID and Mac addresses are the same), the first device and the second device are indicated to search the same WiFi router, and the first device and the second device are located in the same near-domain space and can be connected.
In addition, when the second device periodically scans the WiFi information around itself, the second device may also periodically send the second WiFi information list obtained by scanning and the hotspot access information of the hotspot to the cloud server, so that after determining that the first device and the second device are in the same near-domain space, the cloud server may further extract an update timestamp of the second WiFi information list corresponding to the second device, if the sum of the update timestamp and the timeout threshold exceeds the current time, it is indicated that the second device may have finished sharing, and if the sum of the update timestamp and the timeout threshold exceeds the current time, it is indicated that the second device is still sharing the network, that is, the first device and the second device have both a space intersection and a time intersection, and the two may be connected.
(6) And the cloud server returns the stored ciphertext of the broadcast service information corresponding to the second device to the first device.
Wherein the broadcast service information is WiFi SSID and password.
For example, the Json format of the return message is as follows:
/>
(7) the first device decrypts the broadcast service information of the second device from the broadcast ciphertext.
(8) The first device uses the broadcast service information to access the GO hotspot of the second device.
In the embodiment of the application, the sharer and the device of the connector both provide the peripheral third-party WiFi information searched by the sharer and the device of the connector as the auxiliary reference information of the cloud server, once the cloud server determines that the reference information provided by the sharer and the device of the connector have the intersection, the sharer and the device of the connector can be determined to be in the same near-domain space, and then the sharer and the device of the connector can be determined to be in the same time period by comparing the time stamps, so that the spatial-temporal intersection of the sharer and the device of the connector is determined by the auxiliary cloud discovery means, and the broadcast information of the near-domain network is transmitted by the wide-area network, so that a redundant transmission path of the wide-area network is newly added for the service broadcast message which only works in the near-domain network originally, the robustness of the system is improved, and the broadcast of the WiFi Direct can be influenced by the device screen, but the method of the cloud auxiliary broadcast can work always by means of keeping alive by a plurality of processes, is not influenced by the screen extinction, and is not influenced by the broadcast period and channel congestion of the WiFi Direct.
Fig. 4 is a flowchart of a device discovery method according to an embodiment of the present application, where the method is applied to the cloud server of fig. 1, and the method includes the following steps.
In step 401, a device discovery request of a first device is received, where the device discovery request includes a first WiFi information list of a periphery of the first device scanned by the first device.
In step 402, the first WiFi information list is compared with the stored second WiFi information lists of the second devices, where after creating a hotspot of the WiFi direct group, each second device sends hotspot access information and the traced second WiFi information list around itself to the cloud server.
Here, the first WiFi information list may be compared with the stored second WiFi information list of each second device.
In step 403, it is determined whether a target device satisfying the WiFi direct discovery condition exists in each second device based on whether the WiFi information in the first WiFi information list is included in each second WiFi information.
For example, if any one of the WiFi information in the first WiFi information list is included in any one of the second WiFi information list, determining a second device corresponding to the second WiFi information list as the target device; and if each WiFi information in the first WiFi information list is not contained in each second WiFi information list, determining that the target equipment does not exist.
In addition, in some embodiments, each second device may periodically send the hotspot access information and the second WiFi information list to the cloud server, where if any WiFi information in the first WiFi information list is included in any second WiFi information list, an update timestamp of the second WiFi information list may also be extracted, and based on the update timestamp and an update interval of the second WiFi information list, whether the second WiFi information list is aged or not is determined, if it is determined that the second WiFi information list is not aged, the second device may be determined to be the target device, and if it is determined that the second WiFi information list is aged, the second device may not be determined to be the target device.
The manner in which the second WiFi information list is determined to be aged is illustrated below.
Assuming that the update interval of the second WiFi information list is 30 seconds, a sum of the update timestamp and a timeout threshold (e.g., 60 seconds) may be calculated, if the sum exceeds the current time, it is indicated that the second device corresponding to the second WiFi information list may have stopped sharing the hot spot, so as to determine that the second WiFi information list is aged, and if the sum does not exceed the current time, it is indicated that the second device corresponding to the second WiFi information list is still active, so as to determine that the second WiFi information list is not aged.
It should be noted that the number of target devices finally determined may be zero, or may be one, two or more.
In step 404, if it is determined that the target device exists, the stored hotspot access information of the target device is sent to the first device.
In addition, if it is determined that the target device does not exist, an empty result may be returned to the first device, so as to inform the first device that the device capable of WiFi direct connection with the first device is not found.
Fig. 5 is a flowchart of another device discovery method according to an embodiment of the present application, where the method is applied to the first device of fig. 1, and the method includes the following steps.
In step 501, wiFi information around the device is scanned to obtain a first WiFi information list.
In step 502, hotspot access information of the WiFi direct group is found by scanning on a broadcast channel of the WiFi direct.
In step 503, a device discovery request is sent to a cloud server, where the device discovery request includes a first WiFi information list, and the cloud server compares the first WiFi information list with a stored second WiFi information list of each second device, where each second device sends hotspot access information and a traced second WiFi information list around itself to the cloud server after creating a hotspot of a WiFi direct group; and determining whether target equipment meeting the WiFi direct connection discovery condition exists in each second equipment or not based on whether the WiFi information in the first WiFi information list is contained in each second WiFi information.
In step 504, hotspot access information of the target device sent by the cloud server is received and stored, where the hotspot access information is sent by the cloud server after determining that the target device exists.
In addition, if the first device scans and discovers the hot spot access information of the WiFi direct connection group on the WiFi direct connection broadcast channel, the first device can update the stored hot spot access information by using the hot spot access information, and if the hot spot access information sent by the cloud server is received again, the first device can update the stored hot spot access information by using the hot spot access information. That is, the first device may discover the hot spot access information of the device by using both device discovery methods, and the latest discovered hot spot access information stores the hot spot access information.
In step 505, an access request is sent to a target device, where the access request includes hotspot access information.
In step 506, successful access information sent by the target device is received.
It should be noted that, in the above-mentioned flow, steps 502 and 503 are executed in parallel.
Fig. 6 is a flowchart of another device discovery method according to an embodiment of the present application, where the method is applied to the second device of fig. 1, and the method includes the following steps.
In step 601, the WiFi information around the WiFi information is scanned, so as to obtain a second WiFi information list.
In some embodiments, the WiFi information surrounding itself may be periodically scanned to update the second WiFi information list.
In step 602, after creating the hotspots of the WiFi-direct group, the hotspot access information of the hotspot access information is broadcast through the WiFi-direct path.
In step 603, the hotspot access information and the second WiFi information list are sent to the cloud server for storage, and after receiving the device discovery request of the first device, the cloud server compares the first WiFi information list around itself, which is scanned by the first device and included in the device discovery request, with the stored second WiFi information list; and determining whether the second device is a target device meeting the WiFi direct connection discovery condition based on whether the WiFi information in the first WiFi information list is contained in the second WiFi information list.
In some embodiments, the hotspot access information and the latest second WiFi information list may be periodically sent to the cloud server for storage. Therefore, the cloud server can timely acquire the hot spot access information of the second device and the latest second WiFi information list, and can also acquire whether the second device still shares the hot spot.
In step 604, if the second device is the target device, an access request sent by the first device is received, where the access request includes hot spot access information.
In step 605, the first device is accessed to a hotspot shared by itself based on the hotspot access information.
In step 606, successful access information is sent to the first device.
It should be noted that, in the above-mentioned flow, steps 602 and 603 are executed in parallel.
Based on the same technical concept, the embodiment of the application further provides three device discovery apparatuses, and the principle of solving the problem by the device discovery apparatuses is similar to that of the device discovery method, so that the implementation of the device discovery apparatuses can refer to the implementation of the device discovery method, and the repetition is omitted.
Fig. 7 is a schematic structural diagram of an apparatus discovery device according to an embodiment of the present application, where the apparatus discovery device is applied to a cloud server, and includes a receiving module 701, a comparing module 702, a determining module 703, and a sending module 704.
A receiving module 701, configured to receive a device discovery request of a first device, where the device discovery request includes a first WiFi information list of a periphery of the first device scanned by the first device;
the comparison module 702 is configured to compare the first WiFi information list with a stored second WiFi information list of each second device, where after creating a hotspot of a WiFi direct group, each second device sends hotspot access information and a second WiFi information list of the periphery of the second device to the cloud server;
a determining module 703, configured to determine, based on whether WiFi information in the first WiFi information list is included in each second WiFi information, whether a target device that meets a WiFi direct connection discovery condition exists in each second device;
and the sending module 704 is configured to send the stored hotspot access information of the target device to the first device if it is determined that the target device exists.
In some embodiments, the determining module 703 is specifically configured to:
if any one of the WiFi information in the first WiFi information list is contained in any one of the second WiFi information list, determining a second device corresponding to the second WiFi information list as a target device;
And if each WiFi information in the first WiFi information list is not contained in each second WiFi information list, determining that the target equipment does not exist.
In some embodiments, each second device periodically sends hotspot access information and a second WiFi information list to the cloud server, and further includes:
the aging determining module 705 is configured to extract an update timestamp of a second WiFi information list if any WiFi information in the first WiFi information list is included in any second WiFi information list; determining whether the second WiFi information list is aged based on the update time stamp and an update interval of the second WiFi information list;
the determining module 703 is further configured to determine the second device as a target device if it is determined that the second WiFi information list is not aged.
Fig. 8 is a schematic structural diagram of another device discovery apparatus according to an embodiment of the present application, where the device discovery apparatus is applied to a first device, and includes a WiFi scanning module 801, a hotspot scanning module 802, a sending module 803, and a receiving module 804.
The WiFi scanning module 801 is configured to scan WiFi information around itself to obtain a first WiFi information list;
the hotspot scanning module 802 is configured to scan and discover hotspot access information of the WiFi direct group on a WiFi direct broadcast channel;
A sending module 803, configured to send a device discovery request to a cloud server, where the device discovery request includes the first WiFi information list, and the cloud server compares the first WiFi information list with stored second WiFi information lists of second devices, where each second device sends, after creating a hotspot of a WiFi direct group, hotspot access information and the traced second WiFi information list around itself to the cloud server; determining whether target equipment meeting WiFi direct connection discovery conditions exists in each second equipment or not based on whether WiFi information in the first WiFi information list is contained in each second WiFi information or not;
the receiving module 804 is configured to receive and store hot spot access information of the target device sent by the cloud server, where the hot spot access information is sent by the cloud server after determining that the target device exists.
In some embodiments, further comprising an access module 805 for:
after storing the hot spot access information of the target equipment sent by the cloud server, sending an access request to the target equipment, wherein the access request contains the hot spot access information;
And receiving successful access information sent by the target equipment.
In some embodiments, an update module 806 is also included for:
if the hot spot access information of the WiFi direct connection group is found by scanning on the WiFi direct connection broadcast channel, updating the stored hot spot access information by using the hot spot access information;
and if the hot spot access information sent by the cloud server is received again, updating the stored hot spot access information by using the hot spot access information.
Fig. 9 is a schematic structural diagram of another device discovery apparatus according to an embodiment of the present application, where the apparatus is applied to a second device, and includes a scanning module 901, a broadcasting module 902, and a sending module 903.
The scanning module 901 is configured to scan WiFi information around itself to obtain a second WiFi information list;
the broadcasting module 902 is configured to broadcast, after creating a hotspot of the WiFi direct connection group, hotspot access information of the hotspot through a WiFi direct connection path;
the sending module 903 is configured to send the hotspot access information and the second WiFi information list to a cloud server for storage, where after receiving a device discovery request of a first device, the cloud server compares a first WiFi information list around itself, which is scanned by the first device and included in the device discovery request, with the stored second WiFi information list; and determining whether the second device is a target device meeting a WiFi direct connection discovery condition based on whether the WiFi information in the first WiFi information list is contained in the second WiFi information list.
In some embodiments, if the second device is a target device, the method further includes an access module 904 for:
receiving an access request sent by the first device, wherein the access request comprises the hot spot access information;
accessing the first equipment to the hot spot based on the hot spot access information;
and sending successful access information to the first equipment.
In some embodiments, wiFi information surrounding itself is periodically scanned to update the second WiFi information list; and
and periodically sending the hotspot access information of the hotspots and the latest second WiFi information list to a cloud server for storage.
The division of the modules in the embodiments of the present application is schematically only one logic function division, and there may be another division manner in actual implementation, and in addition, each functional module in each embodiment of the present application may be integrated in one processor, or may exist separately and physically, or two or more modules may be integrated in one module. The coupling of the individual modules to each other may be achieved by means of interfaces which are typically electrical communication interfaces, but it is not excluded that they may be mechanical interfaces or other forms of interfaces. Thus, the modules illustrated as separate components may or may not be physically separate, may be located in one place, or may be distributed in different locations on the same or different devices. The integrated modules may be implemented in hardware or in software functional modules.
Having described the device discovery method and apparatus of an exemplary embodiment of the present application, next, an electronic device according to another exemplary embodiment of the present application is described.
An electronic device 130 implemented according to such an embodiment of the present application is described below with reference to fig. 10. The electronic device 130 shown in fig. 10 is merely an example and should not be construed as limiting the functionality and scope of use of embodiments of the present application.
As shown in fig. 10, the electronic device 130 is embodied in the form of a general-purpose electronic device. Components of electronic device 130 may include, but are not limited to: the at least one processor 131, the at least one memory 132, and a bus 133 connecting the various system components, including the memory 132 and the processor 131.
Bus 133 represents one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, a processor, and a local bus using any of a variety of bus architectures.
Memory 132 may include readable media in the form of volatile memory such as Random Access Memory (RAM) 1321 and/or cache memory 1322, and may further include Read Only Memory (ROM) 1323.
Memory 132 may also include a program/utility 1325 having a set (at least one) of program modules 1324, such program modules 1324 include, but are not limited to: an operating system, one or more application programs, other program modules, and program data, each or some combination of which may include an implementation of a network environment.
The electronic device 130 may also communicate with one or more external devices 134 (e.g., keyboard, pointing device, etc.), one or more devices that enable a user to interact with the electronic device 130, and/or any device (e.g., router, modem, etc.) that enables the electronic device 130 to communicate with one or more other electronic devices. Such communication may occur through an input/output (I/O) interface 135. Also, electronic device 130 may communicate with one or more networks such as a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public network, such as the Internet, through network adapter 136. As shown, network adapter 136 communicates with other modules for electronic device 130 over bus 133. It should be appreciated that although not shown, other hardware and/or software modules may be used in connection with electronic device 130, including, but not limited to: microcode, device drivers, redundant processors, external disk drive arrays, RAID systems, tape drives, data backup storage systems, and the like.
In an exemplary embodiment, a storage medium is also provided, which when a computer program in the storage medium is executed by a processor of an electronic device, the electronic device is capable of performing any of the device discovery methods described above. Alternatively, the storage medium may be a non-transitory computer readable storage medium, which may be, for example, ROM, random Access Memory (RAM), CD-ROM, magnetic tape, floppy disk, optical data storage device, and the like.
In an exemplary embodiment, the electronic device of the present application may include at least one processor, and a memory communicatively coupled to the at least one processor, where the memory stores a computer program executable by the at least one processor, and the computer program when executed by the at least one processor causes the at least one processor to perform the steps of any of the device discovery methods provided by the embodiments of the present application.
In an exemplary embodiment, a computer program product is also provided, which, when executed by an electronic device, is capable of carrying out any one of the exemplary methods provided by the application.
Also, a computer program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium can be, for example, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium would include the following: an electrical connection having one or more wires, a portable disk, a hard disk, a RAM, a ROM, an erasable programmable read-Only Memory (EPROM), flash Memory, optical fiber, compact disc read-Only Memory (Compact Disk Read Only Memory, CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
The program product for device discovery in embodiments of the application may take the form of a CD-ROM and include program code that can run on a computing device. However, the program product of the present application is not limited thereto, and in this document, a readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
The readable signal medium may include a data signal propagated in baseband or as part of a carrier wave with readable program code embodied therein. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination of the foregoing. A readable signal medium may also be any readable medium that is not a readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
Program code embodied on a readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, radio Frequency (RF), etc., or any suitable combination of the foregoing.
Program code for carrying out operations of the present application may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, C++ or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computing device, partly on the user's device, as a stand-alone software package, partly on the user's computing device, partly on a remote computing device, or entirely on the remote computing device or server. In cases involving remote computing devices, the remote computing device may be connected to the user computing device through any kind of network, such as a local area network (Local Area Network, LAN) or wide area network (Wide Area Network, WAN), or may be connected to an external computing device (e.g., connected over the internet using an internet service provider).
It should be noted that although several units or sub-units of the apparatus are mentioned in the above detailed description, such a division is merely exemplary and not mandatory. Indeed, the features and functions of two or more of the elements described above may be embodied in one element in accordance with embodiments of the present application. Conversely, the features and functions of one unit described above may be further divided into a plurality of units to be embodied.
Furthermore, although the operations of the methods of the present application are depicted in the drawings in a particular order, this is not required to either imply that the operations must be performed in that particular order or that all of the illustrated operations be performed to achieve desirable results. Additionally or alternatively, certain steps may be omitted, multiple steps combined into one step to perform, and/or one step decomposed into multiple steps to perform.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While preferred embodiments of the present application have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. It is therefore intended that the following claims be interpreted as including the preferred embodiments and all such alterations and modifications as fall within the scope of the application.
It will be apparent to those skilled in the art that various modifications and variations can be made to the present application without departing from the spirit or scope of the application. Thus, the present application also includes such modifications and variations provided they come within the scope of the claims and their equivalents.

Claims (15)

1. A device discovery method, comprising:
the cloud server receives a device discovery request of a first device, wherein the device discovery request comprises a first WiFi information list of the periphery of the first device scanned by the first device;
comparing the first WiFi information list with a stored second WiFi information list of each second device, wherein after a hotspot of a WiFi direct connection group is created by each second device, hotspot access information and the second WiFi information list around the cloud server are sent to each second device;
determining whether target equipment meeting WiFi direct connection discovery conditions exists in each second equipment or not based on whether WiFi information in the first WiFi information list is contained in each second WiFi information or not;
and if the target equipment is determined to exist, the stored hot spot access information of the target equipment is sent to the first equipment.
2. The method of claim 1, wherein determining whether a target device satisfying WiFi direct discovery conditions exists in each second device based on whether WiFi information in the first WiFi information list is included in each second WiFi information, comprises:
if any one of the WiFi information in the first WiFi information list is contained in any one of the second WiFi information list, determining a second device corresponding to the second WiFi information list as a target device;
and if each WiFi information in the first WiFi information list is not contained in each second WiFi information list, determining that the target equipment does not exist.
3. The method of claim 2, wherein each second device periodically sends hotspot access information and a second WiFi information list to the cloud server, further comprising:
if any one of the WiFi information in the first WiFi information list is contained in any one of the second WiFi information lists, extracting an update time stamp of the second WiFi information list;
determining whether the second WiFi information list is aged based on the update time stamp and an update interval of the second WiFi information list;
and if the second WiFi information list is not aged, determining the second equipment as target equipment.
4. A device discovery method, comprising:
the first equipment scans WiFi information around the first equipment to obtain a first WiFi information list;
scanning and finding hot spot access information of the WiFi direct connection group on a WiFi direct connection broadcast channel; and is combined with
A device discovery request is sent to a cloud server, wherein the device discovery request comprises the first WiFi information list, the cloud server compares the first WiFi information list with stored second WiFi information lists of second devices, and after a hotspot of a WiFi direct connection group is created, each second device sends hotspot access information and the traced second WiFi information list around the second device to the cloud server; determining whether target equipment meeting WiFi direct connection discovery conditions exists in each second equipment or not based on whether WiFi information in the first WiFi information list is contained in each second WiFi information or not;
and receiving and storing hot spot access information of the target equipment, which is sent by the cloud server, wherein the hot spot access information is sent by the cloud server after the existence of the target equipment is determined.
5. The method of claim 4, further comprising, after storing the hotspot access information of the target device sent by the cloud server:
Sending an access request to the target equipment, wherein the access request contains the hot spot access information;
and receiving successful access information sent by the target equipment.
6. The method of claim 4 or 5, further comprising:
if the hot spot access information of the WiFi direct connection group is found by scanning on the WiFi direct connection broadcast channel, updating the stored hot spot access information by using the hot spot access information;
and if the hot spot access information sent by the cloud server is received again, updating the stored hot spot access information by using the hot spot access information.
7. A device discovery method, comprising:
the second equipment scans WiFi information around the second equipment to obtain a second WiFi information list;
after creating the hot spot of the WiFi direct connection group, broadcasting the hot spot access information of the WiFi direct connection group through the WiFi direct connection path; and is combined with
The hot spot access information and the second WiFi information list are sent to a cloud server for storage, and after a device discovery request of a first device is received by the cloud server, the first WiFi information list around the first device, which is scanned by the first device and is contained in the device discovery request, is compared with the stored second WiFi information list; and determining whether the second device is a target device meeting a WiFi direct connection discovery condition based on whether the WiFi information in the first WiFi information list is contained in the second WiFi information list.
8. The method of claim 7, further comprising, if the second device is a target device:
receiving an access request sent by the first device, wherein the access request comprises the hot spot access information;
accessing the first equipment to the hot spot based on the hot spot access information;
and sending successful access information to the first equipment.
9. The method of claim 7 or 8, wherein,
periodically scanning WiFi information around the wireless local area network to update a second WiFi information list; and
and periodically sending the hotspot access information of the hotspots and the latest second WiFi information list to a cloud server for storage.
10. A device discovery apparatus, applied to a cloud server, comprising:
the device discovery module is used for receiving a device discovery request of a first device, wherein the device discovery request comprises a first WiFi information list of the periphery of the first device scanned by the first device;
the comparison module is used for comparing the first WiFi information list with the stored second WiFi information lists of the second devices, wherein after a hotspot of the WiFi direct connection group is created by each second device, hotspot access information and the second WiFi information list around the cloud server are sent to the cloud server;
The determining module is used for determining whether target equipment meeting WiFi direct connection discovery conditions exists in each second equipment or not based on whether WiFi information in the first WiFi information list is contained in each second WiFi information or not;
and the sending module is used for sending the stored hot spot access information of the target equipment to the first equipment if the target equipment is determined to exist.
11. A device discovery apparatus, for use with a first device, comprising:
the WiFi scanning module is used for scanning the WiFi information around the WiFi scanning module to obtain a first WiFi information list;
the hotspot scanning module is used for scanning and finding hotspot access information of the WiFi direct connection group on a WiFi direct connection broadcast channel;
the device discovery module is used for sending a device discovery request to a cloud server, wherein the device discovery request comprises the first WiFi information list, the cloud server compares the first WiFi information list with the stored second WiFi information lists of all second devices, and each second device sends hot spot access information and the drawn second WiFi information list around the cloud server after creating a hot spot of a WiFi direct connection group; determining whether target equipment meeting WiFi direct connection discovery conditions exists in each second equipment or not based on whether WiFi information in the first WiFi information list is contained in each second WiFi information or not;
The receiving module is used for receiving and storing the hot spot access information of the target device, which is sent by the cloud server, wherein the hot spot access information is sent by the cloud server after the existence of the target device is determined.
12. A device discovery apparatus, for use with a second device, comprising:
the scanning module is used for scanning the WiFi information around the scanning module to obtain a second WiFi information list;
the broadcast module is used for broadcasting the hot spot access information of the broadcast module through the WiFi direct connection path after the hot spot of the WiFi direct connection group is created;
the sending module is used for sending the hot spot access information and the second WiFi information list to the cloud server for storage, and the cloud server compares the first WiFi information list around the first equipment scanned by the first equipment contained in the equipment discovery request with the stored second WiFi information list after receiving the equipment discovery request of the first equipment; and determining whether the second device is a target device meeting a WiFi direct connection discovery condition based on whether the WiFi information in the first WiFi information list is contained in the second WiFi information list.
13. A device discovery system, comprising:
Each second device is used for scanning the WiFi information around the second device to obtain a second WiFi information list, and broadcasting the hotspot access information of the second device through a WiFi direct connection path after creating the hotspot of the WiFi direct connection group; the hot spot access information and the second WiFi information list are sent to a cloud server;
the first equipment is used for scanning WiFi information around the first equipment to obtain a first WiFi information list, and scanning and finding hot spot access information of the WiFi direct connection group on a WiFi direct connection broadcast channel; sending a device discovery request to the cloud server, wherein the device discovery request comprises the first WiFi information list;
the cloud server is configured to store the hotspot access information and the second WiFi information lists sent by each second device, compare the first WiFi information list with each second WiFi information list after receiving the device discovery request, and determine whether a target device satisfying a WiFi direct connection discovery condition exists in each second device based on whether WiFi information in the first WiFi information list is included in each second WiFi information; and if the target equipment is determined to exist, the stored hot spot access information of the target equipment is sent to the first equipment.
14. An electronic device, comprising: at least one processor, and a memory communicatively coupled to the at least one processor, wherein:
the memory stores a computer program executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-9.
15. A storage medium, characterized in that a computer program in the storage medium, when executed by a processor of an electronic device, is capable of performing the method of any of claims 1-9.
CN202311218394.3A 2023-09-20 2023-09-20 Device discovery method, device, electronic device and storage medium Pending CN117177227A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311218394.3A CN117177227A (en) 2023-09-20 2023-09-20 Device discovery method, device, electronic device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311218394.3A CN117177227A (en) 2023-09-20 2023-09-20 Device discovery method, device, electronic device and storage medium

Publications (1)

Publication Number Publication Date
CN117177227A true CN117177227A (en) 2023-12-05

Family

ID=88937230

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311218394.3A Pending CN117177227A (en) 2023-09-20 2023-09-20 Device discovery method, device, electronic device and storage medium

Country Status (1)

Country Link
CN (1) CN117177227A (en)

Similar Documents

Publication Publication Date Title
CN104967596A (en) Method and apparatus for realizing binding and communication between user terminal and Internet of things device
CN113453175B (en) 5G message processing method and device, computer equipment and storage medium
WO2023000940A1 (en) Data processing method and apparatus, and network element device, storage medium and program product
WO2019134595A1 (en) Configuration system, client device, embedded device configuration method, and storage medium
US20190089648A1 (en) Resource subscription method, resource subscription apparatus, and resource subscription system
US9535638B2 (en) Directly transferring data between devices
CN103229478A (en) Method and device for virtual-machine drift determination
CN104619040A (en) Method and system for quickly connecting WIFI equipment
EP4246936A1 (en) Data processing method, function device and readable storage medium
US11516302B2 (en) Network service discovery
CN107079271B (en) Method and system for broadcasting content to smart devices using a dedicated gateway box
US10268532B2 (en) Application message processing system, method, and application device
CN105340238A (en) System and method of ANQP querying using common ANQP group version
CN116782345A (en) Communication method, communication device, storage medium, and electronic apparatus
CN117177227A (en) Device discovery method, device, electronic device and storage medium
CN102790722A (en) DHCP (dynamic host configuration protocol) message forwarding method and wireless access control equipment
CN112153599B (en) Message transmission method and device, internet of vehicles equipment and management node
CN113067844A (en) Service discovery method and device and HNRF
WO2020119824A1 (en) Device control method and apparatus, control node, network device, and data center
CN107529166B (en) Portal authentication method and wireless access controller
CN117177172A (en) Device determination method, device, electronic device and storage medium
CN111885157B (en) Internet of things inter-network device communication method and system and edge node
US20220217131A1 (en) Networking method for household appliance, household appliance, and terminal device
CN111030781B (en) Response instruction processing method, device, system, equipment and storage medium
WO2023082668A1 (en) Emergency communication method and apparatus for snpn, and device and storage medium

Legal Events

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