Near field communication method and device, equipment, storage medium and program product

By introducing server screening and sensor detection methods in the near-range communication technology, the waste of resources and security problems caused by mobile devices sending a large number of detection signals is solved, and more efficient and secure close-range communication is achieved.

CN119893482AActive Publication Date: 2025-04-25CHINA UNITED NETWORK COMM GRP CO LTD +1
View PDF 4 Cites 0 Cited by

Patent Information

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

AI Technical Summary

Technical Problem

In existing short-range communication technologies, mobile devices need to send a large number of detection signals to detect matching devices, resulting in waste of resources and reduced communication security.

Method used

By sending a close-range communication request to the server, receiving and filtering device information of the trusted multiple second mobile devices, using sensors to perform device detection processing, determining the target mobile device, and establishing a close-range communication connection with it.

Benefits of technology

Reduces the number of detection signals sent by mobile devices, saves resources, and improves communication security.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119893482A_ABST
    Figure CN119893482A_ABST
Patent Text Reader

Abstract

The invention provides near field communication, a near field communication device, equipment, a storage medium and a program product. Relates to the technical field of computers. The method comprises the steps that a near field communication request is sent to a server, the near field communication request comprises the position of first mobile equipment and a communication purpose, and the communication purpose comprises data transmission and obstacle avoidance; equipment information, sent by the server, of multiple second mobile equipment is received, the distance between the first mobile equipment and the second mobile equipment is smaller than or equal to a preset distance, and the second mobile equipment is equipment passing identity authentication; according to the device information and the communication purpose of the plurality of second mobile devices, carrying out device detection processing through a sensor in the first mobile device so as to detect a target mobile device in the plurality of second mobile devices; according to the invention, the near field communication connection with the target mobile device is established, and the near field communication with the target mobile device is carried out according to the communication purpose, so that resources are saved, and the communication security is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present 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 Art

[0002] With the popularization of mobile devices, short-range communication technology is often used. For example, data can be transmitted between mobile devices through short-range communication technology.

[0003] In the related technology, before conducting short-range communication, the mobile device needs to send a detection signal through a sensor to detect the surrounding matching mobile devices. After receiving the response signal sent by the matching mobile device, the mobile device can establish a short-range communication connection with it, thereby realizing short-range communication.

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

[0005] The present 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, the present application provides a short-range communication method, comprising:

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

[0008] receiving device information of a plurality of 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;

[0009] According to the device information and communication purpose of the plurality of second mobile devices, a device detection process is performed by a sensor in the first mobile device to detect a target mobile device among the plurality of second mobile devices;

[0010] A short-range communication connection is established with the target mobile device, and short-range communication is performed with the target mobile device according to the communication purpose.

[0011] In a possible implementation, according to the device information of the plurality of second mobile devices and the communication purpose, performing device detection processing by a sensor in the first mobile device to detect a target mobile device from the plurality of second mobile devices includes:

[0012] Determining a detection direction according to the communication purpose;

[0013] According to the detection direction, the sensor performs detection processing to obtain detection information, wherein the detection information includes identifiers of multiple detection devices, and the detection devices are mobile devices detected by the first mobile device;

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

[0015] In a possible implementation manner, determining the detection direction according to the communication purpose includes:

[0016] If the communication purpose is the data transmission, determining the detection direction according to the position of each second mobile device in the device information and the position of the first mobile device;

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

[0018] In a possible implementation, determining the detection direction according to the position of each second mobile device in the device information and the position of the first mobile device includes:

[0019] determining a distance between the first mobile device and each second mobile device according to a location of each second mobile device and a location of the first mobile device in the device information;

[0020] Determine second mobile devices corresponding to a plurality of preset directions according to the positions of the second mobile devices;

[0021] The detection direction is determined in the 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, 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 devices corresponding to the detection direction and the first mobile device is less than or equal to the preset distance.

[0022] In a possible implementation, determining the target mobile device from the plurality of second mobile devices according to the device information of the plurality of second mobile devices and the detection information includes:

[0023] Acquire a device identifier of each second mobile device from the device information to obtain a plurality of second device identifiers;

[0024] Acquire a device identifier of each detection device in the detection information to obtain multiple detection device identifiers;

[0025] Determine a repeated device identifier among the plurality of second device identifiers and the plurality of detection device identifiers as a target device identifier;

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

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

[0028] Determining target data to be transmitted to the target mobile device according to the communication purpose;

[0029] Encrypting the target data using the public key in the key pair to obtain encrypted data;

[0030] The encrypted data is sent to the target mobile device so that the target mobile device decrypts the encrypted data according to the private key in the key pair; wherein the server is further used to send the key pair to the multiple second mobile devices.

[0031] In a possible implementation manner, determining, according to the communication purpose, target data to be transmitted to the target mobile device includes:

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

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

[0034] In a second aspect, the present application provides a short-range communication device, including: a sending module, a receiving module, a detection module and a communication module, wherein:

[0035] The sending module is used to send a short-distance communication request to the server, wherein the short-distance communication request includes the location of the first mobile device and the communication purpose, and the communication purpose 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, 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 a sensor in the first mobile device according to device information and communication purposes of the plurality of second mobile devices, so as to detect a 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 perform short-range communication with the target mobile device according to the communication purpose.

[0039] In a possible implementation manner, the detection module is specifically used to:

[0040] Determining a detection direction according to the communication purpose;

[0041] According to the detection direction, the sensor performs detection processing to obtain detection information, wherein the detection information includes identifiers of multiple detection devices, and the detection devices are mobile devices detected by the first mobile device;

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

[0043] In a possible implementation manner, the detection module is specifically used to:

[0044] If the communication purpose is the data transmission, determining the detection direction according to the position of each second mobile device in the device information and the position of the first mobile device;

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

[0046] In a possible implementation manner, the detection module is specifically used to:

[0047] determining a distance between the first mobile device and each second mobile device according to a location of each second mobile device and a location of the first mobile device in the device information;

[0048] Determine second mobile devices corresponding to a plurality of preset directions according to the positions of the second mobile devices;

[0049] The detection direction is determined in the 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, 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 devices corresponding to the detection direction and the first mobile device is less than or equal to the preset distance.

[0050] In a possible implementation manner, the detection module is specifically used to:

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

[0052] Acquire a device identifier of each second mobile device from the device information to obtain a plurality of second device identifiers;

[0053] Acquire a device identifier of each detection device in the detection information to obtain multiple detection device identifiers;

[0054] Determine a repeated device identifier among the plurality of second device identifiers and the plurality of detection device identifiers as a target device identifier;

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

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

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

[0058] Determining target data to be transmitted to the target mobile device according to the communication purpose;

[0059] Encrypting the target data using the public key in the key pair to obtain encrypted data;

[0060] The encrypted data is sent to the target mobile device so that the target mobile device decrypts the encrypted data according to the private key in the key pair; wherein the server is further used to send the key pair to the multiple second mobile devices.

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

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

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

[0064] In a third aspect, an embodiment of the present application provides a mobile device, comprising: at least one processor and a memory; the memory stores computer-executable instructions; at least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the short-range communication method involved in the first aspect and any item of the first aspect above.

[0065] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, in which computer execution instructions are stored. When a processor executes the computer execution instructions, the short-range communication method involved in the first aspect and any item of the first aspect is implemented.

[0066] In a fifth aspect, an embodiment of the present application provides a computer program product, including a computer program. When the computer program is executed by a processor, it implements the short-range communication method involved in the first aspect and any item of the first aspect.

[0067] The short-distance communication method, apparatus, device, storage medium and program product provided by the present application, when performing short-distance communication, the first mobile device sends a short-distance communication request to the server, and after receiving the device information of multiple second mobile devices sent by the server, performs device detection processing according to the device information and the purpose of communication, obtains the target mobile device, and establishes a connection with the target mobile device to achieve short-distance communication between mobile devices. In the above process, the server can determine multiple second mobile devices that are close to the first mobile device and are trustworthy, so that the first mobile device can detect the matching mobile device by sending a small amount of detection signals, which not only saves resources but also improves the security of communication. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0069] Figure 1 A schematic diagram of the system architecture provided for an embodiment of the present application;

[0070] Figure 2 A schematic diagram of a flow chart of a short-distance communication method provided in an embodiment of the present application;

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

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

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

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

[0075] Figure 7 A schematic diagram of the structure of a mobile device provided in an embodiment of the present application.

[0076] The above drawings have shown clear embodiments of the present application, which will be described in more detail later. These drawings and text descriptions are not intended to limit the scope of the present application in any way, but to illustrate the concept of the present application to those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION

[0077] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present application. Instead, they are merely examples of devices and methods consistent with some aspects of the present 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, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards, and provide corresponding operation entrances for users to choose to authorize or refuse.

[0079] It should be noted that in the embodiments of the present application, certain software, components, models and other existing solutions in the industry may be mentioned, and they should be regarded as exemplary. Their purpose is only to illustrate the feasibility of implementing the technical solution of the present application, but it does not mean that the applicant has or will necessarily use the solution.

[0080] For ease of understanding, the following Figure 1 , the system architecture applicable to the embodiments of the present application is described.

[0081] Figure 1 This is a schematic diagram of the system architecture provided by the embodiment of this application. Figure 1, 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 may perform short distance communication.

[0083] In actual application, there are multiple mobile devices around the first mobile device 101. The server 104 can determine multiple second mobile devices 102 that are close to the first mobile device 101 and are trustworthy based on the device information of the multiple mobile devices, and then send the device information of each second mobile device 102 to the first mobile device 101 through the wireless communication base station 103. The first mobile device 101 determines the target mobile device among the second mobile devices 102 based on the device information of each second mobile device 102, and performs short-range communication with the target mobile device.

[0084] Among them, the first mobile device includes: a location module, a communication module, a sensor module and an interaction module, and 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 obtain information such as the device location, the communication module can be used to send and receive data, the sensor module can be used for device detection processing, and the interaction module can be used for short-range communication.

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

[0087] In the related art, before short-range communication is performed, the mobile device needs to send a detection signal through a sensor to detect the surrounding mobile devices that can be matched. After receiving the response signal sent by the matching mobile device, the mobile device can establish a short-range communication connection with it, thereby achieving short-range communication. However, in the above process, the mobile device may need to send more detection signals to detect the matching mobile device, and there may be illegal devices among the matching mobile devices, which not only leads to a waste of resources, but also reduces the security of communication.

[0088] In view of the above technical problems, in an embodiment of the present application, when short-distance communication is required, the first mobile device first sends a short-distance communication request to the server, and the short-distance communication request includes the location of the first mobile device and the purpose of communication. After receiving the device information of multiple second mobile devices sent by the server, the first mobile device detects the target mobile device through a sensor according to the purpose of communication and the device information, and completes the short-distance communication by establishing a short-distance communication connection with the target mobile device. In the above process, the server can determine multiple second mobile devices that are close to the first mobile device and are trustworthy. In this way, the first mobile device can detect matching mobile devices by sending a small amount of detection signals, which not only saves resources but also improves the security of communication.

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

[0090] Figure 2 A flowchart of a short-distance communication method provided in an embodiment of the present application. Figure 2 As shown, the method may include the following steps:

[0091] S201. Send a short distance communication request to a server.

[0092] The execution subject of the embodiment of the present application may be the first mobile device, or may be a short-distance communication device arranged in the first mobile device. The short-distance communication device may be implemented by software, or may be implemented by a combination of software and hardware.

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

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

[0095] S202: Receive device information of multiple second mobile devices sent by a 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] The device information may include a device identification and a location of the second mobile device.

[0098] A device ID is a unique identifier assigned to a device.

[0099] The server may determine the multiple second mobile devices in the following manner: the server obtains the locations of the multiple mobile devices (the multiple mobile devices periodically report their locations to the server), and determines a mobile device to be selected from the multiple mobile devices according to the location of each mobile device and the location of the first mobile device, wherein the distance between the mobile device to be selected and the first mobile device is less than or equal to the preset distance. The server may also perform identity authentication processing on each mobile device to be selected, obtain an identity authentication result for each mobile device to be selected, and determine the mobile device to be selected whose identity authentication result is that the mobile device passed the identity authentication as the second mobile device.

[0100] For example, assuming that the preset distance is 200 meters, the distance between the device and the first mobile device is 150 meters, and the identity authentication result of the device is passed, the device can be determined as the second mobile device.

[0101] Optionally, the device may be authenticated using a preset model. For example, the device information currently acquired may be input into a preset model to obtain an authentication result corresponding to the device information.

[0102] The preset model can be obtained in the following way: obtaining authentication information of multiple devices in a historical period, the authentication information including device information and identity authentication results; preprocessing the authentication information, which may include cleaning, missing value filling, outlier processing, etc.; using a feature extraction algorithm (for example, principal component analysis) to extract relevant features from the authentication information, and inputting them into a deep learning model (for example, SiamRPN++ model) for training to obtain the preset model.

[0103] For example, assuming that there are 4 mobile devices around, namely, device 1, device 2, device 3 and device 4, and the preset distance is 80 meters, wherein 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 identity authentication result of device 1 is failed, the identity authentication result of device 2 is failed, the identity authentication result of device 3 is passed, and the identity authentication result of device 4 is passed. Then, the distances and identity authentication results between device 1, device 2, device 3, 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 identity authentication result of device 4 is passed, device 4 can be confirmed as the second mobile device.

[0107] S203: Perform device detection processing through a sensor in the first mobile device according to device information and communication purposes of the plurality of second mobile devices, so as to detect and obtain a target mobile device among the plurality of second mobile devices.

[0108] The detection signal can be sent by the sensor to perform device detection processing. The sensor can be an infrared sensor, an ultrasonic sensor, a lidar sensor, etc.

[0109] The target mobile device can be detected in the following manner: determine the detection direction according to the communication purpose; perform detection processing through a sensor according to the detection direction to obtain detection information, wherein the detection information includes identifications of multiple detection devices, and the detection device is a mobile device detected by a first mobile device; determine the target mobile device among multiple second mobile devices according to device information of multiple second mobile devices and the detection information.

[0110] Optionally, if the purpose of communication is to transmit data, the detection direction is determined according to the position of each second mobile device in the device information and the position of the first mobile device; if the purpose of communication is to avoid obstacles, the moving direction of the first mobile device is determined as the detection direction.

[0111] After determining the detection direction, the target mobile device can be determined in the following manner: obtain the device identification of each second mobile device in the device information to obtain multiple second device identifications; obtain the device identification of each detection device in the detection information to obtain multiple detection device identifications; determine the repeated device identification among the multiple second device identifications and the multiple detection device identifications as the target device identification; determine the mobile device corresponding to the target device identification as the target mobile device.

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

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

[0114] In actual application, the first mobile device may send a short distance communication connection request to the target mobile device, and establish a short distance communication connection with the target mobile device according to the short distance communication connection request.

[0115] The device information also includes a key pair. The server is also used to send the key pair to multiple second mobile devices.

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

[0117] Close range communication with a target mobile device can be performed in the following manner: according to the purpose of communication, target data to be transmitted to the target mobile device is determined; the target data is encrypted using the public key in the key pair to obtain encrypted data; the encrypted data is sent to the target mobile device so that the target mobile device decrypts the encrypted data using the private key in the key pair.

[0118] If the purpose of communication is to transmit data, the target data is determined to include: the location of the first mobile device, the identification 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 is determined to include: the location of the first mobile device, the identification of the first mobile device, and the movement route of the first mobile device in the future time period.

[0119] In the embodiment of the present application, the first mobile device first sends a short-distance communication request to the server, and the short-distance communication request includes the location and communication purpose of the first mobile device. After receiving the device information of multiple second mobile devices sent by the server, the device detection process is performed according to the communication purpose and the device information to obtain the target mobile device, and then a short-distance communication connection is established with the target mobile device to achieve short-distance communication between mobile devices. In the above process, the server can determine multiple second mobile devices that are close to the first mobile device and are trustworthy. In this way, the first mobile device can detect matching mobile devices by sending a small amount of detection signals, which not only saves resources but also improves the security of communication.

[0120] Figure 3 Schematic diagram of the process of determining the target mobile device provided in the embodiment of the present application. Figure 3 , the method may include the following steps:

[0121] S301: Acquire the location and communication purpose of a first mobile device, and device information of a plurality of second mobile devices.

[0122] Among them, the communication purposes include: transmitting data and avoiding obstacles.

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

[0124] S302: Determine a detection direction according to the position of each second mobile device and the position of the first mobile device in the device information.

[0125] The detection direction can be determined in the following manner: determine the distance between the first mobile device and each second mobile device based on the position of each second mobile device and the position of the first mobile device in the device information; determine the second mobile devices corresponding to multiple preset directions based on the positions of each second mobile device; determine the detection direction among 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.

[0126] The number of the 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 devices corresponding to the detection direction and the first mobile devices is less than or equal to a preset distance.

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

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

[0129] For example, assuming that 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, the distance between the first mobile device and the second mobile device 3 is 150 meters, and 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 may be as shown in Table 2:

[0130] Table 2

[0131]

[0132] According to Table 2, it can be obtained that 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 the 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, S304 is executed.

[0134] S303: Determine the moving direction of the first mobile device as the detection direction.

[0135] The moving direction of the first mobile device may be acquired through a sensor.

[0136] S304: Perform detection processing through sensors according to the detection direction to obtain detection information.

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

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

[0139] S306: Obtain a device identification of each detection device from the detection information to obtain multiple detection device identifications.

[0140] S307: Determine a repeated device identifier among the multiple second device identifiers and the multiple detection device identifiers as a target device identifier.

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

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

[0143] In the embodiment of the present application, after obtaining the communication purpose of the first mobile device and the device information of multiple second mobile devices, the detection direction can be determined according to the communication purpose (transmitting data and avoiding obstacles), and the device detection processing can be performed according to the detection direction to obtain the detection information, which includes multiple detection device identifiers. Then, the second device identifier in the device information is compared with the detection device identifier in the detection information, and the repeated device identifier is determined as the target device identifier, and the mobile device corresponding to the target device identifier is determined as the target mobile device. In the above process, when the communication purpose is to transmit data, the detection direction can be determined according to the number of second mobile devices corresponding to the detection direction and the distance between them and the first mobile device, that is, a direction with more mobile devices and a shorter distance from the first mobile device is selected for detection, so as to avoid detection in unnecessary directions and save resources. Furthermore, the time for device detection is greatly reduced, and the detection efficiency is improved.

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

[0145] Figure 4Schematic diagram of the interaction process between the first mobile device, the second mobile device and the server provided in the embodiment of the present application. Figure 4 , the method may include:

[0146] S401: A first mobile device sends a short distance communication request to a server.

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

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

[0149] After S402 , S403 and S404 may 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, S405 is executed; if the purpose of communication is to avoid obstacles, S406 is executed.

[0154] S405: Determine a detection direction according to the position of each second mobile device in the device information and the position of the first mobile device.

[0155] After S405, S407 is executed.

[0156] S406: Determine the moving direction of the first mobile device as the detection direction.

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

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

[0159] S408: Determine a target mobile device among the multiple second mobile devices according to the device information of the multiple second mobile devices and the detection information.

[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, S410 is executed; if the purpose of communication is to avoid obstacles, S411 is executed.

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

[0163] After S410 , S412 is executed.

[0164] S411. Determine that the target data includes: a location of the first mobile device, an identifier of the first mobile device, and a moving route of the first mobile device in a future period.

[0165] S412: The first mobile equipment 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 (second mobile device).

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

[0168] A short-range communication method provided in an embodiment of the present application can execute the technical solution shown in the above method embodiment, and its implementation principle and beneficial effects are similar, which will not be repeated here.

[0169] Next, combine Figure 5 , the interaction process between the first mobile device, the second mobile device and the server is described.

[0170] Figure 5 Another schematic diagram of the interaction process between the first mobile device, the second mobile device and the server provided in the embodiment of the present application. Figure 5 The first mobile device includes: a location module, a communication module, a sensor module and an interaction module, and the server includes a location module, a preprocessing module, a model training module and an identity authentication module, wherein the location module can be used to obtain information such as the device location.

[0171] After acquiring 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 purpose of communication. For example, the communication purpose may include transmitting data and avoiding obstacles.

[0172] After acquiring the device information of the plurality of second mobile devices, the server sends the device information to the communication module of the first mobile device. Wherein, if the distance between the first mobile device and the second mobile device is less than or equal to the preset distance, and the second mobile device is a device that has passed the identity authentication, the server can pre-process the authentication information of the mobile device and perform model training through the pre-processing module and the model training module, generate a preset model, and obtain the identity authentication result corresponding to the mobile device through the identity authentication module.

[0173] The first mobile device performs device detection processing through the sensor module based on the device information and communication purpose received from multiple second mobile devices, and can obtain 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 device, the target mobile device is obtained from the multiple second mobile devices.

[0174] After obtaining the target mobile device, the first mobile device may establish a short-range communication connection with the target mobile device and perform short-range communication in the interaction module. For example, the short-range communication may be data required for transmitting data or avoiding obstacles.

[0175] Figure 6 This is a schematic diagram of the structure of a short-range communication device provided in an embodiment of the present application. Figure 6 The remote testing device 10 includes: a sending 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 short-distance communication request to the server, wherein the short-distance communication request includes the location of the first mobile device and the communication purpose, and the communication purpose 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, 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 sensor in the first mobile device according to the device information and communication purpose of the plurality of second mobile devices, so as to detect a 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 perform short-range communication with the target mobile device according to the communication purpose.

[0180] In a possible implementation manner, the detection module 13 is specifically used to:

[0181] Determining a detection direction according to the communication purpose;

[0182] According to the detection direction, the sensor performs detection processing to obtain detection information, wherein the detection information includes identifiers of multiple detection devices, and the detection devices are mobile devices detected by the first mobile device;

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

[0184] In a possible implementation manner, the detection module 13 is specifically used to:

[0185] If the communication purpose is the data transmission, determining the detection direction according to the position of each second mobile device in the device information and the position of the first mobile device;

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

[0187] In a possible implementation manner, the detection module 13 is specifically used to:

[0188] determining a distance between the first mobile device and each second mobile device according to a location of each second mobile device and a location of the first mobile device in the device information;

[0189] Determine second mobile devices corresponding to a plurality of preset directions according to the positions of the second mobile devices;

[0190] The detection direction is determined in the 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, 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 devices corresponding to the detection direction and the first mobile device is less than or equal to the preset distance.

[0191] In a possible implementation manner, the detection module 13 is specifically used to:

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

[0193] Acquire a device identifier of each second mobile device from the device information to obtain a plurality of second device identifiers;

[0194] Acquire a device identifier of each detection device in the detection information to obtain multiple detection device identifiers;

[0195] Determine a repeated device identifier among the plurality of second device identifiers and the plurality of detection device identifiers as a target device identifier;

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

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

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

[0199] Determining target data to be transmitted to the target mobile device according to the communication purpose;

[0200] Encrypting the target data using the public key in the key pair to obtain encrypted data;

[0201] The encrypted data is sent to the target mobile device so that the target mobile device decrypts the encrypted data according to the private key in the key pair; wherein the server is further used to send the key pair to the multiple second mobile devices.

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

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

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

[0205] The short-range communication device provided in the embodiment of the present application can execute the method shown in the above method embodiment, and its implementation principle and beneficial effects are similar, which will not be repeated here.

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

[0207] The processor 22 executes the computer execution instructions stored in the memory, so that the processor 22 executes the scheme in the above embodiment. The 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 gates or transistor logic devices, discrete hardware components.

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

[0209] The transceiver 21 may be used to obtain tasks to be executed and configuration information of the tasks to be executed.

[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 an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus. The transceiver is used to realize the communication between the database access device and other computers (such as clients, read-write libraries, and read-only libraries). The memory may include random access memory (RAM) and may also include non-volatile memory.

[0211] An embodiment of the present application also provides a chip for running instructions, which is used to execute the technical solution of the short-distance communication method in the above embodiment.

[0212] An embodiment of the present application further provides a computer-readable storage medium, in which computer instructions are stored. When the computer instructions are executed on a computer, the computer executes the technical solution of the short-range communication method in the above embodiment.

[0213] An embodiment of the present 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. When at least one processor executes the computer program, the technical solution of the short-range communication method in the above embodiment can be implemented.

[0214] It should be noted that, for the aforementioned method embodiments, for the sake of simplicity, they are all expressed as a series of action combinations, but those skilled in the art should be aware that the present application is not limited by the described order of actions, because according to the present application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all optional embodiments, and the actions and modules involved are not necessarily required by the present application.

[0215] It should be further noted that, although the various steps in the flowchart are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless there is a clear description in this article, the execution of these steps is not strictly limited in order, and these steps can be executed in other orders. Moreover, at least a portion of the steps in the flowchart may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these sub-steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a portion of the sub-steps or stages of other steps.

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

[0217] In addition, unless otherwise specified, each functional unit / module in each embodiment of the present application may be integrated into one unit / module, each unit / module may exist physically separately, or two or more units / modules may be integrated together. The above-mentioned integrated unit / module may be implemented in the form of hardware or in the form of a software program module.

[0218] If the integrated unit / module is implemented in the form of hardware, the hardware may be a digital circuit, an analog circuit, etc. The physical implementation of the hardware structure includes but is not limited to transistors, memristors, etc. Unless otherwise specified, the processor may be any appropriate hardware processor, such as a CPU, a GPU, an FPGA, a DSP, an ASIC, etc. Unless otherwise specified, the storage unit may be any appropriate magnetic storage medium or magneto-optical storage medium, such as a resistive random access memory (RRAM), a dynamic random access memory (DRAM), a static random access memory (SRAM), an enhanced dynamic random access memory (EDRAM), a high-bandwidth memory (HBM), a hybrid memory cube (HMC), etc.

[0219] If the integrated unit / module is implemented in the form of a software program module and sold or used as an independent product, it can be stored in a computer-readable memory. Based on this understanding, the technical solution of the present application, 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. The computer software product is stored in a memory, including a number of instructions to enable a computer device (which can be a personal computer, server or network device, etc.) to execute all or part of the steps of the various embodiments of the present application. The aforementioned memory includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, disk or optical disk and other media that can store program codes.

[0220] In the above embodiments, the description of each embodiment has its own emphasis. For the part not described in detail in a certain embodiment, please refer to the relevant description of other embodiments. The technical features of the above embodiments can be combined arbitrarily. In order to make the description concise, all possible combinations of the technical features in the above embodiments are not described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0221] Those skilled in the art will readily appreciate other embodiments of the present application after considering the specification and practicing the invention disclosed herein. The present application is intended to cover any modification, use or adaptation of the present application, which follows the general principles of the present application and includes common knowledge or customary techniques in the art that are not disclosed in the present application. The specification and examples are intended to be exemplary only, and the true scope and spirit of the present application are indicated by the following claims.

[0222] It should be understood that the present application is not limited to the precise structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present application is limited only by the appended claims.

Claims

1. A short distance communication method, characterized in that: Applied to a first mobile device, the method comprises: Sending a short-range communication request to a server, the short-range communication request including the location of the first mobile device and a communication purpose, the communication purpose including: transmitting data and avoiding obstacles; receiving device information of a plurality of 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; According to the device information and communication purpose of the plurality of second mobile devices, a device detection process is performed by a sensor in the first mobile device to detect a target mobile device among the plurality of second mobile devices; A short-range communication connection is established with the target mobile device, and short-range communication is performed with the target mobile device according to the communication purpose.

2. The method according to claim 1, characterized in that According to the device information of the plurality of second mobile devices and the communication purpose, a device detection process is performed by a sensor in the first mobile device to detect a target mobile device from the plurality of second mobile devices, including: Determining a detection direction according to the communication purpose; According to the detection direction, the sensor performs detection processing to obtain detection information, wherein the detection information includes identifiers of multiple detection devices, and the detection devices are mobile devices detected by the first mobile device; The target mobile device is determined from among the plurality of second mobile devices according to the device information of the plurality of second mobile devices and the detection information.

3. The method according to claim 2, characterized in that Determining a detection direction according to the communication purpose includes: If the communication purpose is the data transmission, determining the detection direction according to the position of each second mobile device in the device information and the position of the first mobile device; If the communication purpose is to avoid the obstacle, the moving direction of the first mobile device is determined as the detection direction.

4. The method according to claim 3, characterized in that Determining the detection direction according to the position of each second mobile device in the device information and the position of the first mobile device includes: determining a distance between the first mobile device and each second mobile device according to a location of each second mobile device and a location of the first mobile device in the device information; Determine second mobile devices corresponding to a plurality of preset directions according to the positions of the second mobile devices; The detection direction is determined in the 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, 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 devices corresponding to the detection direction and the first mobile device is less than or equal to the preset distance.

5. The method according to claim 2 or 3, characterized in that: Determining the target mobile device from among the plurality of second mobile devices according to the device information of the plurality of second mobile devices and the detection information includes: Acquire a device identifier of each second mobile device from the device information to obtain a plurality of second device identifiers; Acquire a device identifier of each detection device from the detection information to obtain multiple detection device identifiers; Determine a repeated device identifier among the plurality of second device identifiers and the plurality of detection device identifiers as a target device identifier; The mobile device corresponding to the target device identifier is determined as the target mobile device.

6. The method according to any one of claims 1 to 5, characterized in that: The device information also includes a key pair; performing close range communication with the target mobile device according to the communication purpose, including: Determining target data to be transmitted to the target mobile device according to the communication purpose; Encrypting the target data using the public key in the key pair to obtain encrypted data; The encrypted data is sent to the target mobile device so that the target mobile device decrypts the encrypted data according to the private key in the key pair; wherein the server is further used to send the key pair to the multiple second mobile devices.

7. The method according to claim 6, characterized in that Determining target data to be transmitted to the target mobile device according to the communication purpose includes: If the communication purpose is the transmission of data, determining the target data includes: the location of the first mobile device, the identification of the first mobile device, and the data to be transmitted by the first mobile device; If the communication purpose is to avoid the obstacle, then determining the target data includes: the location of the first mobile device, the identification of the first mobile device, and the movement route of the first mobile device in the future period.

8. A short-range communication device, characterized in that: include: A sending module, a receiving module, a detection module and a communication module, wherein: The sending module is used to send a short-distance communication request to the server, wherein the short-distance communication request includes the location of the first mobile device and the communication purpose, and the communication purpose includes: transmitting data and avoiding obstacles; The receiving module is used to receive device information of multiple second mobile devices sent by the server, 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 a sensor in the first mobile device according to device information and communication purposes of the plurality of second mobile devices, so as to detect a 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 perform short-range communication with the target mobile device according to the communication purpose.

9. A mobile device, characterized in that: include: A processor, and a memory communicatively connected to the processor; The memory stores computer-executable instructions; The processor executes the computer-executable instructions stored in the memory to implement the method according to any one of claims 1 to 7.

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

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

  • User interfaces for location tracking

    US20220335807A1

  • Detection method, detection device, detection system, and radar

    WO2022140889A1