Short-range communication methods, devices, equipment, storage media and software products

By requesting and receiving device information from the server, and using sensors to detect and process the device, the target mobile device is identified to establish a short-range communication connection. This solves the problems of resource waste and low security, and achieves efficient and secure short-range communication.

CN119893482BActive Publication Date: 2025-10-28CHINA UNITED NETWORK COMM GRP CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411970035.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-30
Publication Date
2025-10-28
Estimated Expiration
2044-12-30

AI Technical Summary

Technical Problem

In short-range communication, mobile devices need to send a large number of probe signals to find matching devices, resulting in wasted resources and reduced communication security.

Method used

By sending a short-range communication request to the server, receiving trusted device information, and using sensors for device detection processing, the target mobile device is identified to establish a communication connection.

Benefits of technology

This reduces the amount of detection signals sent, saves resources, and improves communication security.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119893482B_ABST
    Figure CN119893482B_ABST
Patent Text Reader

Abstract

This application provides a short-range communication device, apparatus, equipment, storage medium, and program product. It relates to the field of computer technology. The method includes: sending a short-range communication request to a server, the short-range communication request including the location and communication purpose of a first mobile device, the communication purpose including: data transmission and obstacle avoidance; receiving device information of multiple second mobile devices sent by the server, the distance between the first and second mobile devices being less than or equal to a preset distance, and the second mobile devices being authenticated devices; based on the device information and communication purpose of the multiple second mobile devices, performing device detection processing through sensors in the first mobile device to detect a target mobile device among the multiple second mobile devices; establishing a short-range communication connection with the target mobile device, and conducting short-range communication with the target mobile device according to the communication purpose, which not only saves resources but also improves communication security.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to a short-range communication method, apparatus, device, storage medium, and program product. Background Technology

[0002] With the widespread use of mobile devices, short-range communication technology is often used. For example, mobile devices can transmit data through short-range communication technology.

[0003] In related technologies, before conducting short-range communication, mobile devices need to send detection signals through sensors to detect nearby compatible mobile devices. Once a response signal is received from a compatible mobile device, the mobile device can establish a short-range communication connection with it, thereby achieving short-range communication.

[0004] However, in the above process, mobile devices may need to send a lot of detection signals to detect matching mobile devices, and there may be illegitimate devices among the matching mobile devices, which not only wastes resources but also reduces the security of communication. Summary of the Invention

[0005] This application provides a short-range communication method, apparatus, device, storage medium, and program product to solve the problem of low communication security.

[0006] In a first aspect, this application provides a short-range communication method, comprising:

[0007] Send a proximity communication request to the server, the proximity communication request including the location of the first mobile device and the communication purpose, the communication purpose including: transmitting data and avoiding obstacles;

[0008] The system receives device information of multiple second mobile devices sent by the server, wherein the distance between the first mobile device and the second mobile devices is less than or equal to a preset distance, and the second mobile devices are devices that have passed identity authentication.

[0009] Based on the device information and communication purpose of the plurality of second mobile devices, device detection processing is performed through the sensors in the first mobile device to detect the target mobile device among the plurality of second mobile devices;

[0010] Establish a short-range communication connection with the target mobile device, and conduct short-range communication with the target mobile device according to the communication purpose.

[0011] In one possible implementation, based on device information of the plurality of second mobile devices and the communication purpose, device detection processing is performed using sensors in the first mobile device to detect the target mobile device among the plurality of second mobile devices, including:

[0012] Determine the detection direction based on the stated communication purpose;

[0013] Based on the detection direction, the sensor performs detection processing to obtain detection information, which includes the identifiers of multiple detection devices, wherein the detection device is the mobile device detected by the first mobile device;

[0014] The target mobile device is determined from among the plurality of second mobile devices based on the device information of the plurality of second mobile devices and the detection information.

[0015] In one possible implementation, determining the detection direction based on the communication purpose includes:

[0016] If the purpose of the communication is to transmit data, then the detection direction is determined based on the positions of each second mobile device in the device information and the position of the first mobile device;

[0017] If the purpose of the communication is to avoid obstacles, then the direction of movement of the first mobile device is determined as the detection direction.

[0018] In one possible implementation, determining the detection direction based on the positions of each second mobile device in the device information and the position of the first mobile device includes:

[0019] Based on the positions of each second mobile device and the position of the first mobile device in the device information, the distance between the first mobile device and each second mobile device is determined;

[0020] Based on the location of each second mobile device, determine the second mobile devices corresponding to multiple preset directions;

[0021] Based on the distance between the first mobile device and each second mobile device, and the second mobile device corresponding to each preset direction, the detection direction is determined among the plurality of preset directions, wherein the number of second mobile devices corresponding to the detection direction is greater than or equal to a preset threshold, and / or the average distance between the second mobile device corresponding to the detection direction and the first mobile device is less than or equal to a preset distance.

[0022] In one possible implementation, determining the target mobile device among the plurality of second mobile devices based on device information of the plurality of second mobile devices and the detection information includes:

[0023] The device identifier of each second mobile device is obtained from the device information, resulting in multiple second device identifiers;

[0024] The device identifiers of each detection device are obtained from the detection information, resulting in multiple detection device identifiers;

[0025] The duplicate device identifiers among the plurality of second device identifiers and the plurality of detection device identifiers are identified as the target device identifier;

[0026] The mobile device corresponding to the target device identifier is identified as the target mobile device.

[0027] In one possible implementation, the device information further includes a key pair; and short-range communication with the target mobile device according to the communication purpose includes:

[0028] Based on the stated communication purpose, determine the target data to be transmitted to the target mobile device;

[0029] The target data is encrypted using the public key in the key pair to obtain encrypted data.

[0030] The server sends the encrypted data to the target mobile device so that the target mobile device can decrypt the encrypted data using the private key in the key pair; wherein, the server is also used to send the key pair to the plurality of second mobile devices.

[0031] In one possible implementation, determining the target data to be transmitted to the target mobile device based on the communication purpose includes:

[0032] If the purpose of the communication is to transmit data, then the target data includes: the location of the first mobile device, the identifier of the first mobile device, and the data to be transmitted by the first mobile device;

[0033] If the purpose of the communication is to avoid the obstacle, then the target data includes: the location of the first mobile device, the identifier of the first mobile device, and the movement route of the first mobile device in a future time period.

[0034] Secondly, this application provides a short-range communication device, comprising: a transmitting module, a receiving module, a detection module, and a communication module, wherein,

[0035] The sending module is used to send a near-field communication request to the server. The near-field communication request includes the location of the first mobile device and the communication purpose, which includes: transmitting data and avoiding obstacles.

[0036] The receiving module is used to receive device information of multiple second mobile devices sent by the server, wherein the distance between the first mobile device and the second mobile device is less than or equal to a preset distance, and the second mobile device is a device that has passed identity authentication;

[0037] The detection module is used to perform device detection processing through sensors in the first mobile device based on the device information and communication purpose of the plurality of second mobile devices, so as to detect the target mobile device among the plurality of second mobile devices;

[0038] The communication module is used to establish a short-range communication connection with the target mobile device and to conduct short-range communication with the target mobile device according to the communication purpose.

[0039] In one possible implementation, the detection module is specifically used for:

[0040] Determine the detection direction based on the stated communication purpose;

[0041] Based on the detection direction, the sensor performs detection processing to obtain detection information, which includes the identifiers of multiple detection devices, wherein the detection device is the mobile device detected by the first mobile device;

[0042] The target mobile device is determined from among the plurality of second mobile devices based on the device information of the plurality of second mobile devices and the detection information.

[0043] In one possible implementation, the detection module is specifically used for:

[0044] If the purpose of the communication is to transmit data, then the detection direction is determined based on the positions of each second mobile device in the device information and the position of the first mobile device;

[0045] If the purpose of the communication is to avoid obstacles, then the direction of movement of the first mobile device is determined as the detection direction.

[0046] In one possible implementation, the detection module is specifically used for:

[0047] Based on the positions of each second mobile device and the position of the first mobile device in the device information, the distance between the first mobile device and each second mobile device is determined;

[0048] Based on the location of each second mobile device, determine the second mobile devices corresponding to multiple preset directions;

[0049] Based on the distance between the first mobile device and each second mobile device, and the second mobile device corresponding to each preset direction, the detection direction is determined among the plurality of preset directions, wherein the number of second mobile devices corresponding to the detection direction is greater than or equal to a preset threshold, and / or the average distance between the second mobile device corresponding to the detection direction and the first mobile device is less than or equal to a preset distance.

[0050] In one possible implementation, the detection module is specifically used for:

[0051] Determining the target mobile device from among the plurality of second mobile devices based on the device information of the plurality of second mobile devices and the detection information includes:

[0052] The device identifier of each second mobile device is obtained from the device information, resulting in multiple second device identifiers;

[0053] The device identifiers of each detection device are obtained from the detection information, resulting in multiple detection device identifiers;

[0054] The duplicate device identifiers among the plurality of second device identifiers and the plurality of detection device identifiers are identified as the target device identifier;

[0055] The mobile device corresponding to the target device identifier is identified as the target mobile device.

[0056] In one possible implementation, the communication module is specifically used for:

[0057] The device information also includes a key pair;

[0058] Based on the stated communication purpose, determine the target data to be transmitted to the target mobile device;

[0059] The target data is encrypted using the public key in the key pair to obtain encrypted data.

[0060] The server sends the encrypted data to the target mobile device so that the target mobile device can decrypt the encrypted data using the private key in the key pair; wherein, the server is also used to send the key pair to the plurality of second mobile devices.

[0061] In one possible implementation, the communication module is specifically used for:

[0062] If the purpose of the communication is to transmit data, then the target data includes: the location of the first mobile device, the identifier of the first mobile device, and the data to be transmitted by the first mobile device;

[0063] If the purpose of the communication is to avoid the obstacle, then the target data includes: the location of the first mobile device, the identifier of the first mobile device, and the movement route of the first mobile device in a future time period.

[0064] Thirdly, embodiments of this application provide a mobile device, including: at least one processor and a memory; the memory stores computer-executable instructions; the at least one processor executes the computer-executable instructions stored in the memory, causing the at least one processor to perform the short-range communication method as described in the first aspect above and any one of the first aspects.

[0065] Fourthly, embodiments of this application provide a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, implement the short-range communication method described in the first aspect above and any one of the first aspects.

[0066] Fifthly, embodiments of this application provide a computer program product, including a computer program, which, when executed by a processor, implements the short-range communication method as described in the first aspect and any one of the first aspects.

[0067] The short-range communication method, apparatus, device, storage medium, and program product provided in this application, when conducting short-range communication, involve a first mobile device sending a short-range communication request to a server. After receiving device information from multiple second mobile devices sent by the server, the server performs device detection processing based on the device information and communication purpose to obtain the target mobile device. A connection is then established with the target mobile device to achieve short-range communication between the mobile devices. In this process, the server can identify multiple trustworthy second mobile devices that are close to the first mobile device. Thus, the first mobile device can detect a matching mobile device by sending only a small number of detection signals, saving resources and improving communication security. Attached Figure Description

[0068] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.

[0069] Figure 1 This is a schematic diagram of the system architecture provided for an embodiment of this application;

[0070] Figure 2 A flowchart illustrating a short-range communication method provided in an embodiment of this application;

[0071] Figure 3 A schematic diagram illustrating the process of determining the target mobile device provided in an embodiment of this application;

[0072] Figure 4 A schematic diagram illustrating the interaction process between the first mobile device, the second mobile device, and the server provided in an embodiment of this application;

[0073] Figure 5 A schematic diagram illustrating another interaction process between a first mobile device, a second mobile device, and a server, provided for an embodiment of this application;

[0074] Figure 6 This is a schematic diagram of the structure of a short-range communication device provided in an embodiment of this application;

[0075] Figure 7 This is a schematic diagram of the structure of a mobile device provided in an embodiment of this application.

[0076] The accompanying drawings illustrate specific embodiments of this application, which will be described in more detail below. These drawings and descriptions are not intended to limit the scope of the concept in any way, but rather to illustrate the concept of this application to those skilled in the art through reference to particular embodiments. Detailed Implementation

[0077] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.

[0078] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties. Furthermore, the collection, use and processing of the relevant data must comply with relevant laws, regulations and standards, and corresponding operation entry points are provided for users to choose to authorize or refuse.

[0079] It should be noted that in the embodiments of this application, certain software, components, models and other existing solutions in the industry may be mentioned. These should be regarded as exemplary and are only intended to illustrate the feasibility of implementing the technical solution of this application. However, it does not mean that the applicant has used or necessarily used the solution.

[0080] To facilitate understanding, the following will be combined with... Figure 1 The system architecture applicable to the embodiments of this application will be described.

[0081] Figure 1 This is a schematic diagram of the system architecture provided for an embodiment of this application. Please refer to [link / reference]. Figure 1It includes a first mobile device 101, a second mobile device 102, a wireless communication base station 103, and a server 104.

[0082] The first mobile device 101 and the second mobile device 102 can communicate at close range.

[0083] In practical applications, multiple mobile devices exist around the first mobile device 101. The server 104 can determine multiple trusted second mobile devices 102 that are close to the first mobile device 101 based on the device information of these multiple mobile devices. Then, the server 104 sends the device information of each second mobile device 102 to the first mobile device 101 via the wireless communication base station 103. Based on the device information of each second mobile device 102, the first mobile device 101 identifies the target mobile device among the second mobile devices 102 and establishes short-range communication with the target mobile device.

[0084] The first mobile device includes a location module, a communication module, a sensor module, and an interaction module, while the server includes a location module, a preprocessing module, a model training module, and an identity authentication module.

[0085] In the first mobile device, the location module can be used to acquire information such as the device's location, the communication module can be used to send and receive data, the sensor module can be used for device detection and processing, and the interaction module can be used for short-range communication.

[0086] In the server, the location module can be used to obtain device information of each mobile device, the preprocessing module can be used to preprocess the authentication information of the mobile devices, the model training module can be used to generate a preset model, and the authentication module can obtain the authentication result of the mobile device through the preset model.

[0087] In related technologies, before establishing short-range communication, mobile devices need to send detection signals via sensors to detect nearby compatible mobile devices. Upon receiving a response signal from a compatible mobile device, the mobile device can establish a short-range communication connection, thus achieving short-range communication. However, in this process, the mobile device may need to send numerous detection signals to detect compatible mobile devices, and some of these compatible devices may be illegitimate, leading to wasted resources and reduced communication security.

[0088] To address the aforementioned technical problems, in this embodiment, when short-range communication is required, the first mobile device first sends a short-range communication request to the server. This request includes the location of the first mobile device and the communication purpose. After receiving device information from multiple second mobile devices sent by the server, the first mobile device, based on the communication purpose and this device information, detects the target mobile device using sensors and establishes a short-range communication connection with it to complete the short-range communication. During this process, the server can identify multiple trustworthy second mobile devices that are close to the first mobile device. Thus, the first mobile device can detect matching mobile devices by sending only a small number of detection signals, saving resources and improving communication security.

[0089] The technical solution of this application and how the technical solution of this application solves the above-mentioned technical problems are described in detail below with specific embodiments. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments. The embodiments of this application will now be described with reference to the accompanying drawings.

[0090] Figure 2 This is a flowchart illustrating a short-range communication method provided in an embodiment of this application. Please refer to... Figure 2 As shown, the method may include the following steps:

[0091] S201, Send a short-range communication request to the server.

[0092] The execution subject of this application embodiment can be a first mobile device or a near-field communication device installed in the first mobile device. The near-field communication device can be implemented by software or by a combination of software and hardware.

[0093] The near-field communication request includes the location of the first mobile device and the communication purpose, which includes: transmitting data and avoiding obstacles.

[0094] The location of the first mobile device can be obtained through the Global Positioning System (GPS).

[0095] S202, Receive device information of multiple second mobile devices sent by the server.

[0096] The distance between the first mobile device and the second mobile device is less than or equal to a preset distance, and the second mobile device is a device that has passed identity authentication.

[0097] Device information may include the device identifier and location of the second mobile device.

[0098] Equipment identification refers to the unique identifier assigned to equipment.

[0099] The server can determine multiple second mobile devices in the following way: The server obtains the locations of multiple mobile devices (which periodically report their locations to the server), and based on the location of each mobile device and the location of the first mobile device, determines candidate mobile devices from among these multiple mobile devices. The distance between the candidate mobile devices and the first mobile device is less than or equal to a preset distance. The server can also perform identity authentication processing on each candidate mobile device, obtain the identity authentication result of each candidate mobile device, and determine the candidate mobile device whose identity authentication result is successful as the second mobile device.

[0100] For example, assuming the preset distance is 200 meters, the distance between the device and the first mobile device is 150 meters, and the device's authentication result is successful, then the device can be identified as the second mobile device.

[0101] Optionally, device authentication can be performed using a preset model. For example, by inputting the device information obtained at the current moment into the preset model, the authentication result corresponding to that device information can be obtained.

[0102] The preset model can be obtained as follows: acquire authentication information of multiple devices within a historical period, including device information and identity authentication results; preprocess the authentication information, which may include cleaning, missing value imputation, outlier handling, etc.; use a feature extraction algorithm (e.g., principal component analysis) to extract relevant features from the authentication information and input them into a deep learning model (e.g., SiamRPN++ model) for training to obtain the preset model.

[0103] For example, suppose there are four mobile devices in the vicinity: Device 1, Device 2, Device 3, and Device 4. The preset distance is 80 meters. Specifically, the distance between Device 1 and the first mobile device is 60 meters, the distance between Device 2 and the first mobile device is 120 meters, the distance between Device 3 and the first mobile device is 100 meters, and the distance between Device 4 and the first mobile device is 50 meters. The authentication result of Device 1 is unsuccessful, the authentication result of Device 2 is unsuccessful, the authentication result of Device 3 is successful, and the authentication result of Device 4 is successful. Then, the distances and authentication results between Device 1, Device 2, Device 3, and Device 4 and the first mobile device can be shown in Table 1.

[0104] Table 1

[0105]

[0106] According to Table 1, if the distance between device 4 and the first mobile device (50 meters) is less than the preset distance (80 meters) and the authentication result of device 4 is passed, then device 4 can be identified as the second mobile device.

[0107] S203. Based on the device information and communication purpose of the multiple second mobile devices, device detection processing is performed using sensors in the first mobile device to detect the target mobile device among the multiple second mobile devices.

[0108] Sensors can send detection signals for device detection and processing. These sensors can be infrared sensors, ultrasonic sensors, and lidar sensors, among others.

[0109] The target mobile device can be detected in the following way: determine the detection direction based on the communication purpose; based on the detection direction, perform detection processing through sensors to obtain detection information, which includes the identifiers of multiple detection devices, and the detection devices are the mobile devices detected by the first mobile device; based on the device information of multiple second mobile devices and the detection information, determine the target mobile device among the multiple second mobile devices.

[0110] Optionally, if the purpose of communication is to transmit data, the detection direction is determined based on the positions of the second mobile devices and the first mobile device in the device information; if the purpose of communication is to avoid obstacles, the movement direction of the first mobile device is determined as the detection direction.

[0111] After determining the detection direction, the target mobile device can be identified as follows: obtain the device identifier of each second mobile device from the device information to obtain multiple second device identifiers; obtain the device identifier of each detection device from the detection information to obtain multiple detection device identifiers; identify the duplicate device identifiers among the multiple second device identifiers and multiple detection device identifiers as the target device identifier; identify the mobile device corresponding to the target device identifier as the target mobile device.

[0112] For example, assuming there are 5 second device identifiers in the device information and 10 detection device identifiers in the detection information, and there are 3 duplicate device identifiers among the second device identifiers and detection device identifiers, then the 3 duplicate device identifiers can be identified as target device identifiers, and the second mobile devices corresponding to these 3 target device identifiers can be identified as target mobile devices.

[0113] S204. Establish a short-range communication connection with the target mobile device and conduct short-range communication with the target mobile device according to the communication purpose.

[0114] In practical applications, the first mobile device can send a short-range communication connection request to the target mobile device and establish a short-range communication connection with the target mobile device based on the short-range communication connection request.

[0115] The device information also includes key pairs. The server is also used to send key pairs to multiple secondary mobile devices.

[0116] Optionally, the server may send the key pair to the second mobile device when sending device information to the first mobile device. For example, the server may send the identifier of the first mobile device and the key pair together to the second mobile device.

[0117] Short-range communication with a target mobile device can be achieved as follows: Based on the purpose of communication, determine the target data to be transmitted to the target mobile device; encrypt the target data using the public key in the key pair to obtain encrypted data; send the encrypted data to the target mobile device so that the target mobile device can decrypt the encrypted data using the private key in the key pair.

[0118] If the purpose of communication is to transmit data, the target data includes: the location of the first mobile device, the identifier of the first mobile device, and the data to be transmitted by the first mobile device; if the purpose of communication is to avoid obstacles, the target data includes: the location of the first mobile device, the identifier of the first mobile device, and the movement route of the first mobile device in the future.

[0119] In this embodiment, the first mobile device first sends a proximity communication request to the server. This request includes the location and communication purpose of the first mobile device. After receiving device information from multiple second mobile devices sent by the server, the server performs device detection processing based on the communication purpose and this device information to obtain the target mobile device. Then, a proximity communication connection is established with the target mobile device, enabling proximity communication between the mobile devices. In this process, the server can identify multiple trustworthy second mobile devices that are close to the first mobile device. Thus, the first mobile device can detect matching mobile devices by sending only a small number of detection signals, saving resources and improving communication security.

[0120] Figure 3 This is a schematic diagram illustrating the process of determining the target mobile device as provided in an embodiment of this application. Please refer to... Figure 3 The method may include the following steps:

[0121] S301. Obtain the location and communication purpose of the first mobile device, as well as device information of multiple second mobile devices.

[0122] The purposes of communication include: transmitting data and avoiding obstacles.

[0123] After S301, if the purpose of communication is to transmit data, then S302 is executed; if the purpose of communication is to avoid obstacles, then S303 is executed.

[0124] S302. Determine the detection direction based on the positions of each second mobile device and the first mobile device in the device information.

[0125] The detection direction can be determined as follows: based on the positions of each second mobile device and the first mobile device in the device information, determine the distance between the first mobile device and each second mobile device; based on the positions of each second mobile device, determine the second mobile devices corresponding to multiple preset directions; based on the distance between the first mobile device and each second mobile device, and the second mobile device corresponding to each preset direction, determine the detection direction among the multiple preset directions.

[0126] Among them, the number of second mobile devices corresponding to the detection direction is greater than or equal to a preset threshold, and / or the average distance between the second mobile device corresponding to the detection direction and the first mobile device is less than or equal to a preset distance.

[0127] The preset direction refers to the direction of the connection between the first mobile device and the second mobile device.

[0128] Average distance refers to the average distance between each second mobile device and the first mobile device in the same detection direction.

[0129] For example, assuming the preset threshold is 1, the preset distance is 200 meters, the distance between the first mobile device and the second mobile device 1 is 100 meters, the preset direction is preset direction 1, the distance between the first mobile device and the second mobile device 2 is 200 meters, the preset direction is preset direction 1, and the distance between the first mobile device and the second mobile device 3 is 150 meters, the preset direction is preset direction 2, then the distances and preset directions of the second mobile device 1, the second mobile device 2, and the second mobile device 3 can be shown in Table 2:

[0130] Table 2

[0131]

[0132] According to Table 2, the second mobile device 1 and the second mobile device 2 are in the same preset direction (preset direction 1). That is, the number of second mobile devices corresponding to preset direction 1 is 2, which is greater than the preset threshold (1). And / or, the average distance between the first mobile device and the second mobile device 1 and the second mobile device 2 (150 meters) is less than the preset distance (200 meters). Then the preset direction 1 can be determined as the detection direction.

[0133] After S302, execute S304.

[0134] S303. The direction of movement of the first mobile device is determined as the detection direction.

[0135] The direction of movement of the first mobile device can be obtained through sensors.

[0136] S304. Based on the detection direction, the sensor performs detection processing to obtain detection information.

[0137] The detection information includes the identifiers of multiple detection devices, which are mobile devices detected by the first mobile device.

[0138] S305. Obtain the device identifier of each second mobile device from the device information to obtain multiple second device identifiers.

[0139] S306. Obtain the device identifier of each detection device from the detection information to obtain multiple detection device identifiers.

[0140] S307. Among multiple second device identifiers and multiple detection device identifiers, the duplicate device identifiers are identified as the target device identifier.

[0141] S308. Identify the mobile device corresponding to the target device identifier as the target mobile device.

[0142] It should be noted that the execution process of S305-S308 above can be found in S203, and will not be repeated here.

[0143] In this embodiment, after obtaining the communication purpose of the first mobile device and the device information of multiple second mobile devices, a detection direction can be determined based on the communication purpose (data transmission and obstacle avoidance). Device detection processing is then performed based on the detection direction to obtain detection information, which includes multiple detection device identifiers. The second device identifiers in the device information are then compared with the detection device identifiers in the detection information. Duplicate device identifiers are identified as target device identifiers, and the mobile device corresponding to the target device identifier is identified as the target mobile device. In this process, when the communication purpose is data transmission, the detection direction can be determined based on the number of second mobile devices corresponding to the detection direction and their distance from the first mobile device. That is, a direction with many mobile devices and a short distance from the first mobile device is selected for detection, avoiding unnecessary detection in other directions, saving resources, and significantly reducing device detection time, thus improving detection efficiency.

[0144] Based on any of the above embodiments, the following, in conjunction with Figure 4 The interaction process between the first mobile device, the second mobile device, and the server is described in detail.

[0145] Figure 4This is a schematic diagram illustrating the interaction process between the first mobile device, the second mobile device, and the server, as provided in an embodiment of this application. Please refer to... Figure 4 The method may include:

[0146] S401, The first mobile device sends a near-field communication request to the server.

[0147] The near-field communication request includes the location of the first mobile device and the communication purpose, which includes: transmitting data and avoiding obstacles.

[0148] S402, The second mobile device sends device information to the server.

[0149] After S402, S403 and S404 can be executed in parallel.

[0150] S403, The server sends device information of multiple second mobile devices to the first mobile device.

[0151] The distance between the first mobile device and the second mobile device is less than or equal to a preset distance. The second mobile device is a device that has passed identity authentication, and the device information includes a key pair.

[0152] S404, The server sends a key pair to the second mobile device.

[0153] After S403 and S404, if the purpose of communication is to transmit data, then execute S405; if the purpose of communication is to avoid obstacles, then execute S406.

[0154] S405. Determine the detection direction based on the positions of each second mobile device and the position of the first mobile device in the device information.

[0155] After S405, execute S407.

[0156] S406. The direction of movement of the first mobile device is determined as the detection direction.

[0157] S407. The first mobile device performs detection processing through sensors according to the detection direction to obtain detection information.

[0158] The detection information includes the identifiers of multiple detection devices, which are mobile devices detected by the first mobile device.

[0159] S408. Based on the device information of multiple second mobile devices and the detection information, determine the target mobile device among the multiple second mobile devices.

[0160] S409. The first mobile device establishes a short-range communication connection with the target mobile device (second mobile device).

[0161] After S409, if the purpose of communication is to transmit data, then S410 is executed; if the purpose of communication is to avoid obstacles, then S411 is executed.

[0162] S410, The target data includes: the location of the first mobile device, the identifier of the first mobile device, and the data to be transmitted by the first mobile device.

[0163] After S410, execute S412.

[0164] S411. The target data includes: the location of the first mobile device, the identifier of the first mobile device, and the movement route of the first mobile device in the future.

[0165] S412. The first mobile device encrypts the target data using the public key in the key pair to obtain encrypted data.

[0166] S413, The first mobile device sends encrypted data to the target mobile device (the second mobile device).

[0167] S414. The target mobile device (second mobile device) decrypts the encrypted data using the private key in the key pair to obtain the target data.

[0168] The short-range communication method provided in this application embodiment can execute the technical solution shown in the above method embodiment. Its implementation principle and beneficial effects are similar, and will not be repeated here.

[0169] Below, in conjunction with Figure 5 The interaction process between the first mobile device, the second mobile device, and the server is explained.

[0170] Figure 5 This is a schematic diagram illustrating another interaction process between a first mobile device, a second mobile device, and a server, provided as an embodiment of this application. Please refer to... Figure 5 The first mobile device includes a location module, a communication module, a sensor module, and an interaction module. The server includes a location module, a preprocessing module, a model training module, and an identity authentication module. The location module can be used to obtain information such as the device's location.

[0171] After obtaining the location, the first mobile device can send the location to the communication module. After receiving the location of the first mobile device, the communication module sends a short-range communication request to the server. The short-range communication request includes the location of the first mobile device and the communication purpose, such as transmitting data and avoiding obstacles.

[0172] After obtaining device information from multiple second mobile devices, the server sends this information to the communication module of the first mobile device. The distance between the first and second mobile devices is less than or equal to a preset distance, and the second mobile devices are authenticated devices. The server can preprocess the authentication information of the mobile devices and train a model using a preprocessing module and a model training module to generate a preset model, and then obtain the authentication result corresponding to the mobile device through the authentication module.

[0173] The first mobile device, based on the device information and communication purpose received from multiple second mobile devices, performs device detection processing through a sensor module to obtain the detection information sent by multiple mobile devices in the detection direction. Then, based on the detection information and the device information of the second mobile devices, the target mobile device is obtained from among the multiple second mobile devices.

[0174] After obtaining the target mobile device, the first mobile device can establish a short-range communication connection with the target mobile device and conduct short-range communication in the interaction module. For example, short-range communication can be for transmitting data or data needed to avoid obstacles.

[0175] Figure 6 This is a schematic diagram of a short-range communication device provided in an embodiment of this application. Please refer to... Figure 6 The remote testing device 10 includes: a transmitting module 11, a receiving module 12, a detection module 13, and a communication module 14, wherein...

[0176] The sending module 11 is used to send a near-field communication request to the server. The near-field communication request includes the location of the first mobile device and the communication purpose, which includes: transmitting data and avoiding obstacles.

[0177] The receiving module 12 is used to receive device information of multiple second mobile devices sent by the server, wherein the distance between the first mobile device and the second mobile device is less than or equal to a preset distance, and the second mobile device is a device that has passed identity authentication;

[0178] The detection module 13 is used to perform device detection processing through the sensors in the first mobile device based on the device information and communication purpose of the plurality of second mobile devices, so as to detect the target mobile device among the plurality of second mobile devices;

[0179] The communication module 14 is used to establish a short-range communication connection with the target mobile device and to conduct short-range communication with the target mobile device according to the communication purpose.

[0180] In one possible implementation, the detection module 13 is specifically used for:

[0181] Determine the detection direction based on the stated communication purpose;

[0182] Based on the detection direction, the sensor performs detection processing to obtain detection information, which includes the identifiers of multiple detection devices, wherein the detection device is the mobile device detected by the first mobile device;

[0183] The target mobile device is determined from among the plurality of second mobile devices based on the device information of the plurality of second mobile devices and the detection information.

[0184] In one possible implementation, the detection module 13 is specifically used for:

[0185] If the purpose of the communication is to transmit data, then the detection direction is determined based on the positions of each second mobile device in the device information and the position of the first mobile device;

[0186] If the purpose of the communication is to avoid obstacles, then the direction of movement of the first mobile device is determined as the detection direction.

[0187] In one possible implementation, the detection module 13 is specifically used for:

[0188] Based on the positions of each second mobile device and the position of the first mobile device in the device information, the distance between the first mobile device and each second mobile device is determined;

[0189] Based on the location of each second mobile device, determine the second mobile devices corresponding to multiple preset directions;

[0190] Based on the distance between the first mobile device and each second mobile device, and the second mobile device corresponding to each preset direction, the detection direction is determined among the plurality of preset directions, wherein the number of second mobile devices corresponding to the detection direction is greater than or equal to a preset threshold, and / or the average distance between the second mobile device corresponding to the detection direction and the first mobile device is less than or equal to a preset distance.

[0191] In one possible implementation, the detection module 13 is specifically used for:

[0192] Determining the target mobile device from among the plurality of second mobile devices based on the device information of the plurality of second mobile devices and the detection information includes:

[0193] The device identifier of each second mobile device is obtained from the device information, resulting in multiple second device identifiers;

[0194] The device identifiers of each detection device are obtained from the detection information, resulting in multiple detection device identifiers;

[0195] The duplicate device identifiers among the plurality of second device identifiers and the plurality of detection device identifiers are identified as the target device identifier;

[0196] The mobile device corresponding to the target device identifier is identified as the target mobile device.

[0197] In one possible implementation, the communication module 14 is specifically used for:

[0198] The device information also includes a key pair;

[0199] Based on the stated communication purpose, determine the target data to be transmitted to the target mobile device;

[0200] The target data is encrypted using the public key in the key pair to obtain encrypted data.

[0201] The server sends the encrypted data to the target mobile device so that the target mobile device can decrypt the encrypted data using the private key in the key pair; wherein, the server is also used to send the key pair to the plurality of second mobile devices.

[0202] In one possible implementation, the communication module 14 is specifically used for:

[0203] If the purpose of the communication is to transmit data, then the target data includes: the location of the first mobile device, the identifier of the first mobile device, and the data to be transmitted by the first mobile device;

[0204] If the purpose of the communication is to avoid the obstacle, then the target data includes: the location of the first mobile device, the identifier of the first mobile device, and the movement route of the first mobile device in a future time period.

[0205] The short-range communication device provided in this application embodiment can execute the method shown in the above method embodiment. Its implementation principle and beneficial effects are similar, and will not be described again here.

[0206] Figure 7 This is a schematic diagram of the structure of a mobile device provided in an embodiment of this application. Figure 7 As shown, the mobile device 20 may include: a transceiver 21, a processor 22, and a memory 23.

[0207] Processor 22 executes computer execution instructions stored in memory, causing processor 22 to perform the scheme in the above embodiments. Processor 22 can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.

[0208] The memory 23 is connected to the processor 22 via the system bus and completes communication between them. The memory 23 is used to store computer program instructions.

[0209] Transceiver 21 can be used to obtain the task to be run and the configuration information of the task to be run.

[0210] The system bus can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The system bus can be divided into address bus, data bus, control bus, etc. For ease of representation, only one thick line is used in the diagram, but this does not indicate that there is only one bus or one type of bus. Transceivers are used to enable communication between database access devices and other computers (e.g., clients, read-write libraries, and read-only libraries). Memory may include random access memory (RAM) and may also include non-volatile memory.

[0211] This application also provides a chip for executing instructions, which is used to execute the technical solution of the short-range communication method described in the above embodiments.

[0212] This application also provides a computer-readable storage medium storing computer instructions that, when executed on a computer, cause the computer to perform the technical solution of the short-range communication method described in the above embodiments.

[0213] This application also provides a computer program product, which includes a computer program stored in a computer-readable storage medium. At least one processor can read the computer program from the computer-readable storage medium, and when the at least one processor executes the computer program, it can implement the technical solution of the short-range communication method described in the above embodiments.

[0214] It should be noted that, for the sake of simplicity, the foregoing method embodiments are all described as a series of actions. However, those skilled in the art should understand that this application is not limited to the described order of actions, as some steps may be performed in other orders or simultaneously according to this application. Furthermore, those skilled in the art should also understand that the embodiments described in the specification are all optional embodiments, and the actions and modules involved are not necessarily essential to this application.

[0215] It should be further noted that although the steps in the flowchart are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowchart may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the sub-steps or stages of other steps.

[0216] It should be understood that the above-described device embodiments are merely illustrative, and the device of this application can also be implemented in other ways. For example, the division of units / modules in the above embodiments is only a logical functional division, and there may be other division methods in actual implementation. For example, multiple units, modules, or components may be combined, or integrated into another system, or some features may be ignored or not executed.

[0217] Furthermore, unless otherwise specified, the functional units / modules in the various embodiments of this application can be integrated into one unit / module, or each unit / module can exist physically separately, or two or more units / modules can be integrated together. The integrated units / modules described above can be implemented in hardware or as software program modules.

[0218] When integrated units / modules are implemented in hardware, the hardware can be digital circuits, analog circuits, etc. The physical implementation of the hardware structure includes, but is not limited to, transistors, memristors, etc. Unless otherwise specified, the processor can be any suitable hardware processor, such as a CPU, GPU, FPGA, DSP, and ASIC, etc. Unless otherwise specified, the storage unit can be any suitable magnetic or magneto-optical storage medium, such as Resistive Random Access Memory (RRAM), Dynamic Random Access Memory (DRAM), Static Random Access Memory (SRAM), Enhanced Dynamic Random Access Memory (EDRAM), High-Bandwidth Memory (HBM), Hybrid Memory Cube (HMC), etc.

[0219] If the integrated unit / module is implemented as a software program module and sold or used as an independent product, it can be stored in a computer-readable storage device (CMD). 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 memory and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned memory includes various media capable of storing program code, such as a USB flash drive, read-only memory (ROM), random access memory (RAM), portable hard drive, magnetic disk, or optical disk.

[0220] In the above embodiments, the descriptions of each embodiment have their own emphasis. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments. The technical features of the above embodiments can be combined arbitrarily. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as the combination of these technical features does not contradict each other, it should be considered within the scope of this specification.

[0221] Other embodiments of this application will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this application that follow the general principles of this application and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only, and the true scope and spirit of this application are indicated by the following claims.

[0222] It should be understood that this application is not limited to the precise structure described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this application is limited only by the appended claims.

Claims

1. A short-range communication method, characterized in that, Applied to a first mobile device, the method includes: Send a proximity communication request to the server, the proximity communication request including the location of the first mobile device and the communication purpose, the communication purpose including: transmitting data and avoiding obstacles; The system receives device information of multiple second mobile devices sent by the server, wherein the distance between the first mobile device and the second mobile devices is less than or equal to a preset distance, and the second mobile devices are devices that have passed identity authentication. Based on the device information and communication purpose of the plurality of second mobile devices, device detection processing is performed through the sensors in the first mobile device to detect the target mobile device among the plurality of second mobile devices; Establish a short-range communication connection with the target mobile device, and conduct short-range communication with the target mobile device according to the communication purpose; The step of detecting the target mobile device among the plurality of second mobile devices by performing device detection processing through sensors in the first mobile device based on device information and communication purpose of the plurality of second mobile devices includes: If the purpose of the communication is to transmit data, the distance between the first mobile device and each second mobile device is determined based on the location of each second mobile device and the location of the first mobile device in the device information; based on the location of each second mobile device, a plurality of second mobile devices corresponding to preset directions are determined; based on the distance between the first mobile device and each second mobile device, and the second mobile device corresponding to each preset direction, a detection direction is determined among the plurality of preset directions, wherein the number of second mobile devices corresponding to the detection direction is greater than or equal to a preset threshold, and / or, the average distance between the second mobile device corresponding to the detection direction and the first mobile device is less than or equal to a preset distance; If the purpose of the communication is to avoid obstacles, then the direction of movement of the first mobile device is determined as the detection direction; Based on the detection direction, the sensor performs detection processing to obtain detection information, which includes the identifiers of multiple detection devices, wherein the detection device is the mobile device detected by the first mobile device; The target mobile device is determined from among the plurality of second mobile devices based on the device information of the plurality of second mobile devices and the detection information.

2. The method according to claim 1, characterized in that, Determining the target mobile device from among the plurality of second mobile devices based on the device information of the plurality of second mobile devices and the detection information includes: The device identifier of each second mobile device is obtained from the device information, resulting in multiple second device identifiers; The device identifiers of each detection device are obtained from the detection information, resulting in multiple detection device identifiers; The duplicate device identifiers among the plurality of second device identifiers and the plurality of detection device identifiers are identified as the target device identifier; The mobile device corresponding to the target device identifier is identified as the target mobile device.

3. The method according to claim 1 or 2, characterized in that, The device information also includes a key pair; and close-range communication with the target mobile device according to the communication purpose includes: Based on the stated communication purpose, determine the target data to be transmitted to the target mobile device; The target data is encrypted using the public key in the key pair to obtain encrypted data. The server sends the encrypted data to the target mobile device so that the target mobile device can decrypt the encrypted data using the private key in the key pair; wherein, the server is also used to send the key pair to the plurality of second mobile devices.

4. The method according to claim 3, characterized in that, Based on the stated communication purpose, the target data to be transmitted to the target mobile device is determined, including: If the purpose of the communication is to transmit data, then the target data includes: the location of the first mobile device, the identifier of the first mobile device, and the data to be transmitted by the first mobile device; If the purpose of the communication is to avoid the obstacle, then the target data includes: the location of the first mobile device, the identifier of the first mobile device, and the movement route of the first mobile device in a future time period.

5. A short-range communication device, characterized in that, include: The module consists of a transmitting module, a receiving module, a detection module, and a communication module, among which: The sending module is used to send a near-field communication request to the server. The near-field communication request includes the location of the first mobile device and the communication purpose, which includes: transmitting data and avoiding obstacles. The receiving module is used to receive device information of multiple second mobile devices sent by the server, wherein the distance between the first mobile device and the second mobile device is less than or equal to a preset distance, and the second mobile device is a device that has passed identity authentication; The detection module is used to perform device detection processing through sensors in the first mobile device based on the device information and communication purpose of the plurality of second mobile devices, so as to detect the target mobile device among the plurality of second mobile devices; The communication module is used to establish a short-range communication connection with the target mobile device and to conduct short-range communication with the target mobile device according to the communication purpose; The step of detecting the target mobile device among the plurality of second mobile devices by performing device detection processing through sensors in the first mobile device based on device information and communication purpose of the plurality of second mobile devices includes: If the purpose of the communication is to transmit data, the distance between the first mobile device and each second mobile device is determined based on the location of each second mobile device and the location of the first mobile device in the device information; based on the location of each second mobile device, a plurality of second mobile devices corresponding to preset directions are determined; based on the distance between the first mobile device and each second mobile device, and the second mobile device corresponding to each preset direction, a detection direction is determined among the plurality of preset directions, wherein the number of second mobile devices corresponding to the detection direction is greater than or equal to a preset threshold, and / or, the average distance between the second mobile device corresponding to the detection direction and the first mobile device is less than or equal to a preset distance; If the purpose of the communication is to avoid obstacles, then the direction of movement of the first mobile device is determined as the detection direction; Based on the detection direction, the sensor performs detection processing to obtain detection information, which includes the identifiers of multiple detection devices, wherein the detection device is the mobile device detected by the first mobile device; The target mobile device is determined from among the plurality of second mobile devices based on the device information of the plurality of second mobile devices and the detection information.

6. A mobile device, characterized in that, include: A processor, and a memory communicatively connected to the processor; The memory stores computer-executed instructions; The processor executes computer execution instructions stored in the memory to implement the method as described in any one of claims 1-4.

7. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions, which, when executed by a processor, are used to implement the method as described in any one of claims 1-4.

Citation Information

Patent Citations

  • Obstacle stopping control method, device and equipment of mobile robot and storage medium

    CN114779761A

  • Data transmisson system, data transmission method and mobile electronic device

    US20140120956A1