A method of a detection device and an electronic device

The antenna pattern and signal strength data are calculated by the cyclic cross-correlation direction-finding algorithm, and combined with the interface prompts, the problems of large detection area and high difficulty of existing equipment are solved, and low-cost and convenient detection of hidden cameras and monitoring devices is achieved.

CN115550986BActive Publication Date: 2025-10-14HUAWEI TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202110738811.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-06-30
Publication Date
2025-10-14
Estimated Expiration
2041-06-30

AI Technical Summary

Technical Problem

Existing electronic equipment to prevent voyeurism and eavesdropping requires large detection areas and is highly difficult. In addition, ordinary equipment is not effective, and professional equipment is expensive, making it unsuitable for daily use.

Method used

The cyclic cross-correlation direction finding algorithm is used to calculate the antenna pattern of the electronic device and the signal strength data of the target device, and the interface is used to prompt the user to find the target device.

Benefits of technology

It effectively reduces the detection area, lowers the difficulty of finding hidden cameras and monitoring devices, reduces costs, and is suitable for use in daily life and work.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115550986B_ABST
    Figure CN115550986B_ABST
Patent Text Reader

Abstract

The embodiment of the present application provides a kind of detection equipment method and electronic equipment.The technical scheme provided in the embodiment of the present application is that the antenna directional diagram of electronic equipment and the first signal strength data of target equipment are calculated by cyclic cross-correlation direction finding algorithm, and algorithm result is obtained;According to the algorithm result, the user is prompted to find the target equipment by interface prompt mode, which can effectively reduce the area of the region that the anti-stealing shot, monitoring electronic equipment needs to detect, and reduce the difficulty of detecting and finding possible existing stealing shot, monitoring equipment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical field

[0001] The present invention relates to the field of computer technology, and in particular to a detection device method and electronic equipment. [Background Technology]

[0002] Most current electronic devices used to prevent surreptitious photography and eavesdropping require users to conduct large-scale, detailed detection within the target area, which is cumbersome and relies on experience. In addition, such electronic devices are of varying quality on the market. Low-priced civilian electronic devices are not very effective, while professional electronic devices are expensive and are not suitable for carrying and using in daily life and work.

[0003] Therefore, the current electronic equipment used to prevent secret photography and eavesdropping needs to detect a large area, and it is difficult to detect and find possible secret photography and eavesdropping devices. [Summary of the invention]

[0004] In view of this, an embodiment of the present invention provides a detection device method and electronic device, which can effectively reduce the area that needs to be detected by electronic devices to prevent sneak photography and eavesdropping, and reduce the difficulty of detecting and finding possible sneak photography and eavesdropping devices.

[0005] In a first aspect, an embodiment of the present invention provides a method for detecting a device, the method comprising:

[0006] Calculating the antenna pattern of the electronic device and the first signal strength data of the target device using a cyclic cross-correlation direction finding algorithm to obtain an algorithm result;

[0007] According to the algorithm result, the user is prompted to search for the target device through an interface prompt.

[0008] In conjunction with the first aspect, in certain implementations of the first aspect, before calculating the antenna pattern of the electronic device and the first signal strength data of the target device using the cyclic cross-correlation direction finding algorithm to obtain the algorithm result, the method further includes:

[0009] Scanning and traversing the first network according to the working mode selected by the user to determine whether the target device exists;

[0010] If it is determined that the target device exists, determining a target channel or a target frequency band where the target device is located;

[0011] selecting, according to the target channel or the target frequency band, the antenna pattern of the electronic device corresponding to the target channel or the target frequency band;

[0012] First signal strength data of the target device is collected.

[0013] In combination with the first aspect, in some implementations of the first aspect, the working mode includes detecting a WiFi network device or detecting a cellular network device.

[0014] In conjunction with the first aspect, in certain implementations of the first aspect, the operating mode includes detecting a WiFi networked device, and the first network includes different WiFi channels around the electronic device;

[0015] The working mode includes detecting a cellular network device, wherein the first network includes different cellular signal frequency bands around the electronic device.

[0016] In conjunction with the first aspect, in certain implementations of the first aspect, when the operating mode includes detecting WiFi networked devices, scanning and traversing the first network according to the operating mode selected by the user to determine whether the target device exists specifically includes:

[0017] Searching for a first device list connected to the same WiFi hotspot as the electronic device;

[0018] determining, according to the target parameter of the first device in the first device list, whether the first device list includes the target device;

[0019] If it is determined that the first device list includes the target device, continuing to perform the step of determining the target channel or target frequency band where the target device is located;

[0020] If it is determined that the target device is not included in the first device list, enabling a sniffer function of a WiFi chip in the electronic device to sniff network transmission information of all surrounding WiFi channels;

[0021] The target features of the sniffed data packets are calculated using a machine learning algorithm to determine whether there is video transmission data.

[0022] If it is determined that there is video transmission data, the target device is searched for according to the video transmission data, and the step of determining the target channel or target frequency band where the target device is located is continued.

[0023] In conjunction with the first aspect, in certain implementations of the first aspect, when the operating mode includes detecting a cellular network device, scanning and traversing the first network according to the operating mode selected by the user to determine whether the target device exists specifically includes:

[0024] Scan and traverse different cellular signal frequency bands according to the working mode selected by the user to determine whether a cellular signal exists.

[0025] In conjunction with the first aspect, in certain implementations of the first aspect, determining the target channel or target frequency band where the target device is located specifically includes:

[0026] Determine the target WiFi channel or target cellular network frequency band where the target device is located.

[0027] In combination with the first aspect, in certain implementations of the first aspect, when the working mode includes detecting a WiFi networked device,

[0028] The selecting, according to the target channel or the target frequency band, the antenna pattern of the electronic device corresponding to the target channel or the target frequency band specifically includes:

[0029] According to the target WiFi channel, selecting WiFi antenna patterns of two WiFi antennas of the electronic device on the target WiFi channel;

[0030] The two WiFi antenna patterns are subtracted to obtain the antenna pattern.

[0031] In combination with the first aspect, in some implementations of the first aspect, when the working mode includes detecting a cellular network device,

[0032] The selecting, according to the target channel or the target frequency band, the antenna pattern of the electronic device corresponding to the target channel or the target frequency band specifically includes:

[0033] According to the target cellular network frequency band, the antenna pattern of the electronic device corresponding to the target cellular network frequency band is selected.

[0034] In conjunction with the first aspect, in certain implementations of the first aspect, collecting the first signal strength data of the target device specifically includes:

[0035] generating a first interface prompt for prompting the user to perform a first operation;

[0036] When the user performs the first operation according to the first interface prompt, first signal strength data of the target device is collected.

[0037] In combination with the first aspect, in certain implementations of the first aspect, when the working mode includes detecting a WiFi networked device, the first operation includes: the user holding the electronic device and rotating it in place;

[0038] When the working mode includes detecting a cellular network device, the first operation includes: the user selecting a holding method corresponding to the target cellular network frequency band, and holding the electronic device and rotating it in place.

[0039] In combination with the first aspect, in some implementations of the first aspect, the target cellular network frequency band includes a low-frequency cellular network, a medium-frequency cellular network, or a high-frequency cellular network.

[0040] In combination with the first aspect, in certain implementations of the first aspect, when the working mode includes detecting a WiFi networked device, the first signal strength data includes a difference in signal strength data of the target device received by the two WiFi antennas.

[0041] In conjunction with the first aspect, in certain implementations of the first aspect, calculating the antenna pattern of the electronic device and the first signal strength data of the target device using a cyclic cross-correlation direction finding algorithm to obtain an algorithm result specifically includes:

[0042] Obtaining first plane pattern data including a specified angle at a first included angle according to the antenna pattern;

[0043] Calculating the first signal strength data and the first plane pattern data using a cyclic cross-correlation calculation formula to obtain a first cross-correlation value between the first signal strength data and the first plane pattern data;

[0044] Recording the angle value of the second angle corresponding to the maximum value of the first cross-correlation value into the first result;

[0045] Adding a preset angle to the first angle yields a third angle;

[0046] Determining whether the third angle is greater than an angle threshold;

[0047] If the third angle is less than or equal to the angle threshold, the third angle is used as the designated angle, and the step of obtaining first plane pattern data including the designated angle at the first angle according to the antenna pattern is continued.

[0048] With reference to the first aspect, in certain implementations of the first aspect, after determining whether the third angle is greater than the angle threshold, the method further includes:

[0049] If the third angle is greater than the angle threshold, calculating the angle value of the second angle in the first result by a data fusion method to obtain the first target azimuth angle;

[0050] Obtaining a rotated antenna pattern by rotating the antenna pattern to the first target azimuth angle;

[0051] Obtaining a confidence level between the first signal strength data and the rotated antenna pattern by calculating the first signal strength data and the rotated antenna pattern;

[0052] Determining whether the confidence level is greater than a coefficient threshold;

[0053] If it is determined that the confidence level is less than or equal to the coefficient threshold, the step of collecting the first signal strength data of the target device is continued.

[0054] In conjunction with the first aspect, in certain implementations of the first aspect, after determining whether the confidence level is greater than the coefficient threshold, the method further includes:

[0055] If it is determined that the confidence level is greater than the coefficient threshold, generating a second interface prompt for prompting the user to perform a second operation according to the first target azimuth angle;

[0056] When the user performs the second operation according to the second interface prompt, collecting second signal strength data of the target device;

[0057] Calculating the second signal strength and the second plane pattern data at the second included angle including the first target azimuth angle using the cyclic cross-correlation calculation formula to obtain a second cross-correlation value between the second signal strength data and the second plane pattern data;

[0058] The angle value of the first angle corresponding to the maximum value of the second cross-correlation value is selected as the second target azimuth angle.

[0059] In conjunction with the first aspect, in certain implementations of the first aspect, prompting the user to search for the target device through an interface prompt based on the algorithm result specifically includes:

[0060] generating a third interface prompt according to the first target azimuth angle and the second target azimuth angle, wherein the third interface prompt includes a direction guide for finding the target device;

[0061] In the process of the user searching for the target device according to the prompt of the third interface, collecting the walking trajectory of the user and the real-time signal strength of the target device;

[0062] According to the walking track and the real-time signal strength, the user's track points are recorded in different colors, and the user is prompted by the degree of urgency of the sound according to the real-time signal strength.

[0063] In combination with the first aspect, in some implementations of the first aspect, the second operation includes: the user holding the electronic device and rotating it to the first target azimuth angle, and swinging the electronic device up and down in the direction of the first target azimuth angle.

[0064] In combination with the first aspect, in some implementations of the first aspect, the preset angle includes 15°.

[0065] In combination with the first aspect, in some implementations of the first aspect, the angle threshold includes 120°.

[0066] In combination with the first aspect, in some implementations of the first aspect, the coefficient threshold includes 0.5.

[0067] In conjunction with the first aspect, in certain implementations of the first aspect, the operating mode includes detecting a WiFi networked device, and the target device includes a camera;

[0068] When the working mode includes detecting a cellular network device, the target device includes a listener.

[0069] In a second aspect, an embodiment of the present invention provides a first electronic device, including a processor and a memory, wherein the memory is used to store a computer program, and the computer program includes program instructions. When the processor executes the program instructions, the electronic device performs the following steps:

[0070] Calculating the antenna pattern of the electronic device and the first signal strength data of the target device using a cyclic cross-correlation direction finding algorithm to obtain an algorithm result;

[0071] According to the algorithm result, the user is prompted to search for the target device through an interface prompt.

[0072] In conjunction with the second aspect, in certain implementations of the second aspect, when the processor executes the program instructions, the electronic device is caused to perform the following steps:

[0073] Before calculating the antenna pattern of the electronic device and the first signal strength data of the target device using the cyclic cross-correlation direction finding algorithm to obtain the algorithm result, the method further includes:

[0074] Scanning and traversing the first network according to the working mode selected by the user to determine whether the target device exists;

[0075] If it is determined that the target device exists, determining a target channel or a target frequency band where the target device is located;

[0076] Selecting, according to the target channel or the target frequency band, the antenna pattern of the electronic device corresponding to the target channel or the target frequency band;

[0077] Collect first signal strength data of the target device.

[0078] In combination with the second aspect, in some implementations of the second aspect, the working mode includes detecting a WiFi network device or detecting a cellular network device.

[0079] In conjunction with the second aspect, in certain implementations of the second aspect, the operating mode includes detecting a WiFi networked device, and the first network includes different WiFi channels around the electronic device;

[0080] The working mode includes detecting a cellular network device, wherein the first network includes different cellular signal frequency bands around the electronic device.

[0081] In conjunction with the second aspect, in certain implementations of the second aspect, when the processor executes the program instructions, the electronic device is caused to perform the following steps:

[0082] When the working mode includes detecting a WiFi networked device, scanning and traversing the first network according to the working mode selected by the user to determine whether the target device exists specifically includes:

[0083] Searching for a first device list connected to the same WiFi hotspot as the electronic device;

[0084] determining, according to the target parameter of the first device in the first device list, whether the first device list includes the target device;

[0085] If it is determined that the first device list includes the target device, continuing to perform the step of determining the target channel or target frequency band where the target device is located;

[0086] If it is determined that the target device is not included in the first device list, enabling a sniffer function of a WiFi chip in the electronic device to sniff network transmission information of all surrounding WiFi channels;

[0087] The target features of the sniffed data packets are calculated using a machine learning algorithm to determine whether there is video transmission data.

[0088] If it is determined that there is video transmission data, the target device is searched for according to the video transmission data, and the step of determining the target channel or target frequency band where the target device is located is continued.

[0089] In conjunction with the second aspect, in certain implementations of the second aspect, when the processor executes the program instructions, the electronic device is caused to perform the following steps:

[0090] When the working mode includes detecting a cellular network device, scanning and traversing the first network according to the working mode selected by the user to determine whether the target device exists specifically includes:

[0091] Scan and traverse different cellular signal frequency bands according to the working mode selected by the user to determine whether a cellular signal exists.

[0092] In conjunction with the second aspect, in certain implementations of the second aspect, when the processor executes the program instructions, the electronic device is caused to perform the following steps:

[0093] The determining of the target channel or target frequency band where the target device is located specifically includes:

[0094] Determine the target WiFi channel or target cellular network frequency band where the target device is located.

[0095] In conjunction with the second aspect, in certain implementations of the second aspect, when the processor executes the program instructions, the electronic device is caused to perform the following steps:

[0096] When the working mode includes detecting WiFi network devices,

[0097] The selecting, according to the target channel or the target frequency band, the antenna pattern of the electronic device corresponding to the target channel or the target frequency band specifically includes:

[0098] According to the target WiFi channel, selecting WiFi antenna patterns of two WiFi antennas of the electronic device on the target WiFi channel;

[0099] The two WiFi antenna patterns are subtracted to obtain the antenna pattern.

[0100] In conjunction with the second aspect, in certain implementations of the second aspect, when the processor executes the program instructions, the electronic device is caused to perform the following steps:

[0101] When the working mode includes detecting a cellular network device,

[0102] The selecting, according to the target channel or the target frequency band, the antenna pattern of the electronic device corresponding to the target channel or the target frequency band specifically includes:

[0103] According to the target cellular network frequency band, the antenna pattern of the electronic device corresponding to the target cellular network frequency band is selected.

[0104] In conjunction with the second aspect, in certain implementations of the second aspect, when the processor executes the program instructions, the electronic device is caused to perform the following steps:

[0105] The collecting the first signal strength data of the target device specifically includes:

[0106] generating a first interface prompt for prompting the user to perform a first operation;

[0107] When the user performs the first operation according to the first interface prompt, first signal strength data of the target device is collected.

[0108] In conjunction with the second aspect, in certain implementations of the second aspect, when the working mode includes detecting a WiFi networked device, the first operation includes: the user holding the electronic device and rotating it in place;

[0109] When the working mode includes detecting a cellular network device, the first operation includes: the user selecting a holding method corresponding to the target cellular network frequency band, and holding the electronic device and rotating it in place.

[0110] In combination with the second aspect, in some implementations of the second aspect, the target cellular network frequency band includes a low-frequency cellular network, a medium-frequency cellular network, or a high-frequency cellular network.

[0111] In combination with the second aspect, in some implementations of the second aspect, when the working mode includes detecting a WiFi networked device, the first signal strength data includes a difference in signal strength data of the target device received by the two WiFi antennas.

[0112] In conjunction with the second aspect, in certain implementations of the second aspect, when the processor executes the program instructions, the electronic device is caused to perform the following steps:

[0113] The step of calculating the antenna pattern of the electronic device and the first signal strength data of the target device using the cyclic cross-correlation direction finding algorithm to obtain an algorithm result specifically includes:

[0114] Obtaining first plane pattern data including a specified angle at a first included angle according to the antenna pattern;

[0115] Calculating the first signal strength data and the first plane pattern data using a cyclic cross-correlation calculation formula to obtain a first cross-correlation value between the first signal strength data and the first plane pattern data;

[0116] Recording the angle value of the second angle corresponding to the maximum value of the first cross-correlation value into the first result;

[0117] Adding a preset angle to the first angle yields a third angle;

[0118] Determining whether the third angle is greater than an angle threshold;

[0119] If the third angle is less than or equal to the angle threshold, the third angle is used as the designated angle, and the step of obtaining first plane pattern data including the designated angle at the first angle according to the antenna pattern is continued.

[0120] In conjunction with the second aspect, in certain implementations of the second aspect, when the processor executes the program instructions, the electronic device is caused to perform the following steps:

[0121] After determining whether the third angle is greater than the angle threshold, the method further includes:

[0122] If the third angle is greater than the angle threshold, calculating the angle value of the second angle in the first result by a data fusion method to obtain the first target azimuth angle;

[0123] Obtaining a rotated antenna pattern by rotating the antenna pattern to the first target azimuth angle;

[0124] Obtaining a confidence level between the first signal strength data and the rotated antenna pattern by calculating the first signal strength data and the rotated antenna pattern;

[0125] Determining whether the confidence level is greater than a coefficient threshold;

[0126] If it is determined that the confidence level is less than or equal to the coefficient threshold, the step of collecting the first signal strength data of the target device is continued.

[0127] In conjunction with the second aspect, in certain implementations of the second aspect, when the processor executes the program instructions, the electronic device is caused to perform the following steps:

[0128] After determining whether the confidence level is greater than the coefficient threshold, the method further includes:

[0129] If it is determined that the confidence level is greater than the coefficient threshold, generating a second interface prompt for prompting the user to perform a second operation according to the first target azimuth angle;

[0130] When the user performs the second operation according to the second interface prompt, collecting second signal strength data of the target device;

[0131] Calculating the second signal strength and the second plane pattern data at the second included angle including the first target azimuth angle using the cyclic cross-correlation calculation formula to obtain a second cross-correlation value between the second signal strength data and the second plane pattern data;

[0132] The angle value of the first angle corresponding to the maximum value of the second cross-correlation value is selected as the second target azimuth angle.

[0133] In conjunction with the second aspect, in certain implementations of the second aspect, when the processor executes the program instructions, the electronic device is caused to perform the following steps:

[0134] The step of prompting the user to search for the target device through an interface prompt based on the algorithm result specifically includes:

[0135] generating a third interface prompt according to the first target azimuth angle and the second target azimuth angle, wherein the third interface prompt includes a direction guide for finding the target device;

[0136] In the process of the user searching for the target device according to the prompt of the third interface, collecting the walking trajectory of the user and the real-time signal strength of the target device;

[0137] According to the walking track and the real-time signal strength, the user's track points are recorded in different colors, and the user is prompted by the degree of urgency of the sound according to the real-time signal strength.

[0138] In combination with the second aspect, in some implementations of the second aspect, the second operation includes: the user holding the electronic device and rotating it to the first target azimuth angle, and swinging the electronic device up and down in the direction of the first target azimuth angle.

[0139] In combination with the second aspect, in some implementations of the second aspect, the preset angle includes 15°.

[0140] In combination with the second aspect, in some implementations of the second aspect, the angle threshold includes 120°.

[0141] In combination with the second aspect, in certain implementations of the second aspect, the coefficient threshold includes 0.5.

[0142] In conjunction with the second aspect, in certain implementations of the second aspect, the operating mode includes detecting a WiFi networked device, and the target device includes a camera;

[0143] When the working mode includes detecting a cellular network device, the target device includes a listener.

[0144] In a third aspect, an embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, wherein the computer program includes program instructions, and when the program request is run by a computer, the computer is caused to execute the method as described above.

[0145] In the technical solutions of the detection device method and electronic device provided in the embodiments of the present invention, the antenna pattern of the electronic device and the first signal strength data of the target device are calculated by a cyclic cross-correlation direction-finding algorithm to obtain an algorithm result; based on the algorithm result, the user is prompted to search for the target device through an interface prompt, which can effectively reduce the area that needs to be detected by the electronic device for preventing sneak photography and eavesdropping, and reduce the difficulty of detecting and searching for possible sneak photography and eavesdropping devices.

Brief Description of the Drawings

[0146] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0147] Figure 1 A flow chart of a method for detecting equipment provided by an embodiment of the present invention;

[0148] Figure 2 A schematic diagram showing a user selecting to detect a WiFi networked device in the detection interface;

[0149] Figure 3 A schematic diagram showing a user selecting to detect a cellular network device in the detection interface;

[0150] Figure 4 for Figure 1 A specific flow chart of scanning and traversing the first network according to the working mode selected by the user to determine whether a target device exists;

[0151] Figure 5 for Figure 1 A specific flow chart of selecting an antenna pattern of an electronic device corresponding to a target channel or a target frequency band according to a target channel or a target frequency band;

[0152] Figure 6 A schematic diagram of a WiFi antenna in an electronic device;

[0153] Figure 7 is a schematic diagram of a cellular network antenna in an electronic device;

[0154] Figure 8 for Figure 1 A specific flow chart of collecting first signal strength data of a target device;

[0155] Figure 9 is a schematic diagram of the first interface;

[0156] Figure 10 A schematic diagram of a user holding an electronic device with his right hand;

[0157] Figure 11 is a schematic diagram of a holding method corresponding to a medium-frequency cellular network;

[0158] Figure 12 The antenna pattern of the electronic device and the coordinate system to which it belongs;

[0159] Figure 13 is the planar antenna pattern when the first angle θ is equal to 90°;

[0160] Figure 14 for Figure 13 Schematic diagram of one-dimensional antenna pattern data after the planar antenna pattern is expanded;

[0161] Figure 15 for Figure 1 A specific flow chart of calculating the antenna pattern of the electronic device and the first signal strength data of the target device by a cyclic cross-correlation direction finding algorithm to obtain an algorithm result;

[0162] Figure 16 for Figure 1 According to the algorithm results, the user is prompted to find the specific flow chart of the target device through the interface prompt;

[0163] Figure 17 is a schematic diagram of the third interface;

[0164] Figure 18 A schematic structural diagram of an electronic device provided by an embodiment of the present invention. [Specific implementation method]

[0165] In order to better understand the technical solution of the present invention, the embodiments of the present invention are described in detail below with reference to the accompanying drawings.

[0166] It should be understood that the embodiments described are only a portion of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without creative work are within the scope of protection of the present invention.

[0167] The terms used in the embodiments of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. The singular forms "a", "an", "the" and "the" used in the embodiments of the present invention and the appended claims are also intended to include plural forms unless the context clearly indicates otherwise.

[0168] It should be understood that the term "and / or" as used herein simply describes a relationship between associated objects, indicating that three possible relationships exist. For example, "A and / or B" can represent: A alone, A and B together, or B alone. Furthermore, the character " / " in this document generally indicates an "or" relationship between the associated objects.

[0169] In the modern internet world, people are increasingly concerned about personal privacy and business information security. However, with the advancement of electronic device miniaturization, various hidden cameras and eavesdropping devices may be spying on people's lives and work from the shadows in unexpected forms. Examples include: tiny pinhole cameras hidden in electrical sockets, hidden cameras in everyday items (such as alarm clocks and toys), and small GPS tracking devices that can be inserted into SIM cards. Faced with the threat of these increasingly smaller and more concealed malicious cameras and eavesdropping devices, protecting personal privacy and business information from infringement is becoming an area of ​​increasing concern.

[0170] When using these devices, criminals often choose wireless data transmission devices, such as WiFi cameras and small SIM card-compatible monitoring devices, to reduce the possibility of exposing themselves. The following are the current technologies available on the market to prevent these devices:

[0171] Related technology 1: wireless signal detector.

[0172] Wireless signal detectors are currently the most commonly used electronic devices for detecting and locating wireless transmission-based hidden cameras and eavesdropping devices. They primarily utilize a signal detector and an extendable antenna to detect wireless signals within a specific frequency band (e.g., 600MHz to 7GHz). The closer the wireless signal is to the detector, the stronger it detects. Therefore, changes in signal strength can be used to determine the distance between the detector and the target signal source, thereby locating hidden cameras and eavesdropping devices.

[0173] However, because hidden cameras and eavesdropping devices are typically small and often hidden in obscure corners, wireless signal detectors require users to scan every corner of the target area. Furthermore, interference from wireless signals from other electronic devices may occur. Consequently, wireless signal detectors are time-consuming and labor-intensive to use, relying heavily on user experience. They are rarely used in daily life, and their effectiveness is limited.

[0174] Related technology 2: sensor detection method.

[0175] Sensor detection relies on sensors tailored to the specific characteristics of hidden cameras and eavesdropping devices. For example, hidden cameras and eavesdropping devices generate heat when in operation, so thermal imaging can be used to identify devices whose temperatures are significantly higher than the ambient temperature. Camera focus motors contain magnets, so changes in the intensity of magnetic field sensors can be used to detect the presence of cameras.

[0176] The sensor detection method shares similar shortcomings with the wireless signal detectors in Related Art 1. It primarily requires users to utilize the corresponding sensors to traverse and scan the target area to detect hidden cameras and eavesdropping devices. However, in practice, this comprehensive scan is difficult to achieve, making Related Art 2's effectiveness in detecting hidden cameras and eavesdropping devices unreliable. Furthermore, thermal imagers and magnetic field sensors are also susceptible to interference from environmental factors (such as hot objects or other magnetic devices).

[0177] Related technology three: ultrasonic interference method.

[0178] The ultrasonic interference method modulates white noise for interference on ultrasonic waves that are inaudible to the human ear. During normal use, people in the current environment cannot perceive the interfering white noise. However, since most microphones that collect sound signals are nonlinear, the interfering white noise modulated on the ultrasonic waves will be demodulated after being collected by the microphone. Therefore, the sound received by the monitor contains the interfering white noise, which can protect the user's conversation and other voice information from being eavesdropped.

[0179] Ultrasonic waves have strong directionality. To target eavesdroppers hidden in unknown places, ultrasonic jamming methods require deploying ultrasonic jammers in multiple directions, which is generally costly. In order to better interfere with the eavesdropping effect of the eavesdroppers, ultrasonic jammers need to emit stronger ultrasonic waves. Therefore, the electronic devices used in ultrasonic jamming methods are usually large in size, have high power consumption, are not easy to carry, and are difficult to popularize in daily life.

[0180] In summary, among related technologies, specialized electronic devices for preventing surreptitious filming and eavesdropping are currently relatively expensive and rely heavily on user experience. They are typically developed by specialized teams and are rarely used in daily life and work. Ordinary civilian electronic devices, such as wireless signal detectors, are ineffective in practice and are easily affected by environmental interference, making them ineffective in providing effective protection. Consequently, current electronic devices for preventing surreptitious filming and eavesdropping require extensive coverage, and detecting and locating potential surreptitious filming and eavesdropping devices is challenging.

[0181] Based on the technical problems existing in the above-mentioned related technologies, an embodiment of the present invention provides a detection device method and electronic device. By utilizing the ability of electronic devices to receive wireless signals in different frequency bands to detect target devices used for secret photography and eavesdropping, a cyclic cross-correlation direction-finding algorithm based on the antenna pattern of the electronic device is proposed to quickly determine the azimuth angle of the target device hidden in a hidden place relative to the user. This can effectively reduce the scope of the target area that needs to be detected and reduce the difficulty of use. Since the detection device method provided by the embodiment of the present invention is applied to electronic devices, users no longer need to carry additional detection equipment, which can reduce the cost of use and play a role in protecting personal privacy and signal security in daily life and work.

[0182] Figure 1 This is a flow chart of a method for detecting equipment provided by an embodiment of the present invention. Figure 1 As shown, the method includes:

[0183] Step 102: Scan and traverse the first network according to the working mode selected by the user to determine whether the target device exists.

[0184] The application scenario of the embodiment of the present invention includes a target area, for example, a conference room, a classroom, or a bedroom.

[0185] like Figure 2 As shown, before step 102, a detection interface is displayed on the screen of the electronic device. The detection interface includes two selection buttons, one of which is a "Cellular Network" button and the other is a "WiFi Device" button. The detection interface is used to display the detected network device type to the user. The user selects the device network type to be detected by clicking the selection button corresponding to the network device type.

[0186] In the embodiment of the present invention, the working mode includes detecting WiFi network devices or detecting cellular network devices. Figure 2 As shown in FIG, the selection button clicked by the user is the “WiFi device” button, and the working mode selected by the user at this time includes detecting WiFi network devices. Figure 3 As shown, the selection button clicked by the user is the "Cellular Network" button, and the working mode selected by the user at this time includes detecting cellular network devices.

[0187] In an embodiment of the present invention, when the working mode includes detecting a WiFi network device, the first network includes different WiFi channels around the electronic device; when the working mode includes detecting a cellular network device, the first network includes different cellular signal frequency bands around the electronic device.

[0188] In the embodiment of the present invention, when the working mode includes detecting a WiFi network device, the target device includes a camera; when the working mode includes detecting a cellular network device, the target device includes a monitor.

[0189] In the embodiment of the present invention, when the working mode includes detecting WiFi network devices, such as Figure 4 As shown, step 102 specifically includes:

[0190] Step 102a: Search for a list of first devices connected to the same WiFi hotspot as the electronic device.

[0191] In this step, the first device list includes all first devices connected to the same WiFi hotspot as the electronic device. Specifically, the IP address of the first device is discovered through the Internet Control Message Protocol (ICMP), and then the Media Access Control (MAC) address, port number, and other information of the first device corresponding to the Internet Protocol (IP) address is found through the Address Resolution Protocol (ARP).

[0192] Step 102b: Determine whether the first device list includes the target device based on the target parameter of the first device in the first device list; if so, proceed to step 104; if not, proceed to step 102c.

[0193] In the embodiment of the present invention, the target parameters include relevant device information such as the MAC address and port number of the first device.

[0194] Specifically, it is determined whether the first device includes a camera based on relevant device information such as the MAC address and port number of the first device.

[0195] Step 102c: Enable the Sniffer function of the WiFi chip in the electronic device to sniff network transmission information of all surrounding WiFi channels.

[0196] In this step, if the first device connected to the same WiFi hotspot as the electronic device does not include a camera, the Sniffer function of the WiFi chip in the electronic device is turned on to sniff network transmission information of all surrounding WiFi channels.

[0197] Step 102d: Calculate the target features of the sniffed data packet through a machine learning algorithm to determine whether there is video transmission data.

[0198] Among them, the target characteristics include the size, interval, rate and other characteristics of the data packet.

[0199] Step 102e: If it is determined that there is video transmission data, search for the target device according to the video transmission data, and continue to step 104.

[0200] In this step, if it is determined that there is video transmission data, it indicates that there is a camera in the detected target area. Then, the corresponding camera is searched according to the video transmission data, and step 104 is continued.

[0201] In the embodiment of the present invention, when the working mode includes detecting a cellular network device, step 102 specifically includes: scanning and traversing different cellular signal frequency bands according to the working mode selected by the user to determine whether a cellular signal exists.

[0202] It should be noted that, when the working mode includes detecting cellular network devices, before step 102 , other known cellular network devices need to be turned off and the airplane mode needs to be turned on.

[0203] In an embodiment of the present invention, an electronic device (such as a mobile phone) has a cellular signal channel, which is mainly used to self-test the electronic device's ability to receive cellular signals. Generally, the electronic device transmits a signal itself and then uses the cellular signal channel to detect the strength of the transmitted signal. The embodiment of the present invention reuses this function, and when the cellular signal channel is turned on to detect cellular signals, the electronic device itself no longer transmits a signal, so it can be used to detect cellular network devices in the external environment. The embodiment of the present invention requires the user to actively turn off known cellular network devices, so the cellular signal channel function of the electronic device can be used to detect cellular network monitors.

[0204] Specifically, for a monitor that turns on real-time voice monitoring, it directly scans cellular network signals of different frequency bands. If a cellular signal is found, the frequency band to which the cellular signal belongs is recorded.

[0205] Specifically, for a monitor that starts recording and uploading voice signals at a scheduled time, the electronic device actively emits sound signals at regular intervals to trigger the possible monitor, while scanning cellular network signals in different frequency bands. If a cellular signal is found, the frequency band to which the cellular signal belongs is recorded.

[0206] Step 104: If it is determined that the target device exists, determine the target channel or target frequency band where the target device is located.

[0207] In the embodiment of the present invention, step 104 specifically includes: determining a target WiFi channel or a target cellular network frequency band where the target device is located.

[0208] Step 106: According to the target channel or the target frequency band, select the antenna pattern of the electronic device corresponding to the target channel or the target frequency band.

[0209] In the embodiment of the present invention, when the working mode includes detecting WiFi network devices, such as Figure 5 As shown, step 106 specifically includes:

[0210] Step 1062: Select the WiFi antenna patterns of the two WiFi antennas of the electronic device in the target WiFi channel according to the target WiFi channel.

[0211] In the embodiment of the present invention, the electronic device (such as a mobile phone) generally has two WiFi antennas. Figure 6 As shown in the figure, 2.4G WiFi has two antennas, T1 and T2; 5G WiFi has two antennas, T3 and T4). If the target WiFi channel includes a 2.4G WiFi channel, select the WiFi antenna pattern of the T1 and T2 WiFi antennas in the 2.4G WiFi channel; if the target WiFi channel includes a 5G WiFi channel, select the WiFi antenna pattern of the T3 and T4 WiFi antennas in the 5G WiFi channel.

[0212] Step 1064: Subtract the two WiFi antenna patterns to obtain an antenna pattern.

[0213] In the embodiment of the present invention, by subtracting the directional patterns of two WiFi antennas, the two WiFi antennas can be virtually transformed into one antenna with better directivity.

[0214] In the embodiment of the present invention, when the working mode includes detecting a cellular network device, step 106 specifically includes: selecting an antenna pattern of an electronic device corresponding to the target cellular network frequency band according to the target cellular network frequency band.

[0215] In the embodiment of the present invention, Figure 7 As shown, the cellular network antenna of the electronic device includes a low-frequency cellular antenna, a medium-frequency cellular antenna and a high-frequency cellular antenna. Correspondingly, the target cellular network frequency band includes a low-frequency cellular network, a medium-frequency cellular network or a high-frequency cellular network.

[0216] It should be noted that, regardless of the working mode, the antenna pattern in the embodiment of the present invention is the actual antenna pattern after considering the influence of the human body (mainly the torso and hands) on the electronic device, so as to better reflect the signal strength received by the electronic device during actual use. The antenna pattern that takes into account the influence of the human body is also related to the way of holding the electronic device. The antenna pattern of the same electronic device will be different for different holding methods. In actual use, the user mainly holds it with the right hand. For this holding method, the antenna pattern data when holding the electronic device with the right hand can be simulated by software or actually collected.

[0217] Step 108: Collect first signal strength data of the target device.

[0218] In an embodiment of the present invention, when the working mode includes detecting a WiFi networked device, the target device includes a camera. The electronic device selects an appropriate method for collecting signal strength according to the camera's discovery method.

[0219] The embodiment of the present invention does not limit the method for the electronic device to collect signal strength. For example, the method for the electronic device to collect signal strength includes establishing a Transmission Control Protocol (TCP) connection or establishing a User Datagram Protocol (UDP) connection.

[0220] Taking TCP connection as an example, if the camera and the electronic device are in the same WiFi hotspot, based on the IP address and port number of the camera, the electronic device can periodically (for example, every 20ms) try to establish a Transmission Control Protocol (TCP) connection with the camera. Regardless of whether the TCP connection is successful or not, the electronic device will receive a feedback frame in response to the TCP connection from the camera. By parsing the feedback frame, the signal strength of the camera can be obtained.

[0221] Specifically, if the camera and the electronic device are not in the same WiFi hotspot, the Sniffer function of the electronic device's WiFi chip can capture and parse the data frame of the MAC address according to the camera's MAC address to obtain the signal strength of the camera.

[0222] In the embodiment of the present invention, Figure 8 As shown, step 108 specifically includes:

[0223] Step 1082: Generate a first interface prompt for prompting the user to perform a first operation.

[0224] In an embodiment of the present invention, when the working mode includes detecting a WiFi network device, after detecting a camera and selecting an antenna pattern, the electronic device generates a first interface, which includes a first interface prompt for prompting the user to perform a first operation. Specifically, Figure 9 As shown, the first interface also includes a compass and direction guidance.

[0225] In an embodiment of the present invention, when the working mode includes detecting a WiFi networked device, the first operation includes: the user holding the electronic device and rotating it in place.

[0226] In the embodiment of the present invention, the user can use the left hand, right hand or both hands to hold the electronic device. Figure 10 As shown, the user holds the electronic device with his right hand.

[0227] For example, the first operation is that the user holds the electronic device with his right hand and rotates it in a circle. It should be noted that "one circle" here is just an overview. Depending on the speed of the user's rotation, the user may need to rotate in a certain direction multiple times to collect signal strength data for the entire circle. Figure 9 As shown, some of the arcs in the circle at the bottom of the first interface are thick solid lines, indicating that the signal strength data collection in the corresponding direction has been completed; in actual use, the user may still not collect signal strength data in some directions after rotating one circle, in which case the arcs in the corresponding directions will not have thick solid lines.

[0228] In an embodiment of the present invention, when the working mode includes detecting a cellular network device, the first operation includes: the user selecting a holding method corresponding to the target cellular network frequency band and holding the electronic device to rotate it in place.

[0229] Specifically, different target cellular network frequency bands use different holding methods to reduce the interference of hands and body on the received cellular signal. Figure 7 As shown, the low-frequency cellular antenna is located at the top of the electronic device, the medium-frequency cellular antenna is located in the middle of the electronic device, and the high-frequency cellular antenna is located at the bottom of the electronic device. When the target cellular network frequency band includes the low-frequency cellular network, the corresponding holding method is that the user uses the right hand to hold the area from the middle to the bottom of the electronic device, and the low-frequency cellular antenna faces outward to enable the low-frequency cellular antenna to better receive cellular signals; when the target cellular network frequency band includes the medium-frequency cellular network, such as Figure 11As shown, the corresponding holding method is that the user holds the top and bottom areas of the electronic device with both hands respectively, and the medium-frequency cellular antenna faces outward, so that the medium-frequency cellular antenna can better receive cellular signals; when the target cellular network frequency band includes a high-frequency cellular network, the corresponding holding method is that the user holds the area from the bottom to the middle of the electronic device with the right hand, and the high-frequency cellular antenna faces outward, so that the high-frequency cellular antenna can better receive cellular signals.

[0230] Step 1084: When the user performs the first operation according to the prompt of the first interface, first signal strength data of the target device is collected.

[0231] In the embodiment of the present invention, the first signal strength data is the signal strength of the target device from different angles collected by the electronic device when the user rotates the electronic device in place. Therefore, the first signal strength data can also be called full-circle signal strength data.

[0232] It should be noted that when the operating mode includes detecting Wi-Fi connected devices, the first signal strength data includes the difference in signal strength data from the target device received by the two Wi-Fi antennas. Since electronic devices typically have two Wi-Fi antennas, for ease of calculation, the difference in signal strength data collected by the two Wi-Fi antennas is used as the first signal strength data.

[0233] Step 110: Calculate the antenna pattern of the electronic device and the first signal strength data of the target device using a cyclic cross-correlation direction finding algorithm to obtain an algorithm result.

[0234] The principle of the cyclic cross-correlation direction finding algorithm of the embodiment of the present invention is to use the antenna pattern to characterize the ability of the antenna of the electronic device to radiate signals in all directions, and also the ability to receive signals. Taking the WiFi antenna of the electronic device as an example, Figure 12 The antenna pattern of the electronic device and the coordinate system to which it belongs are shown. The X-axis is to the right when the electronic device is held upright, the Y-axis is forward, and the Z-axis is vertically upward. The X-axis and the Y-axis form a second angle φ, which has a value range of 0-360 degrees. The angle with the Z-axis is the first angle θ, which has a value range of 0-180 degrees.

[0235] In order to make the azimuth information of the target device relative to the electronic device more accurate, an embodiment of the present invention cuts the antenna pattern of the electronic device into planar antenna patterns corresponding to multiple different first angles θ, and performs cross-correlation calculations with the collected first signal strength data respectively. After confirming the first target azimuth angle of the target device relative to the electronic device corresponding to the second angle φ, the electronic device is rotated up and down in the direction of the second angle φ to re-collect the signal strength, and the signal strength data is cross-correlated with the planar antenna pattern data corresponding to the second angle φ, so that the second target azimuth angle of the target device relative to the electronic device corresponding to the first angle θ can be obtained.

[0236] The algorithm result includes the first target azimuth angle and the second target azimuth angle.

[0237] For example, when the first angle θ is equal to 90°, that is, it coincides with the plane where the mobile phone screen is located, the planar antenna pattern is as follows: Figure 13 As shown, Figure 13 The one-dimensional antenna pattern data after the planar antenna pattern is expanded is as follows Figure 14 shown.

[0238] It should be noted that before collecting the first signal strength data, it is necessary to record the current azimuth of the electronic device as an initial azimuth, and use the initial azimuth as a reference angle for the algorithm result.

[0239] In the embodiment of the present invention, Figure 15 As shown, step 110 specifically includes:

[0240] Step 110a: Obtain first plane pattern data including a specified angle at a first included angle according to the antenna pattern.

[0241] In the embodiment of the present invention, the designated angle can be set according to actual conditions. For example, the designated angle is set to 60°.

[0242] Step 110b: Calculate the first signal strength data and the first plane pattern data using a cyclic cross-correlation calculation formula to obtain a first cross-correlation value between the first signal strength data and the first plane pattern data.

[0243] To facilitate the explanation of the cyclic cross-correlation calculation formula, assume that the first plane pattern data is represented by f(θ, φ) and the first signal strength data is represented by S(φ), where the first angle θ = 0, 5, ..., 180; the second angle φ = 0, 5, ..., 360. For example, the plane antenna pattern data with a first angle θ = 90° is selected as the first plane pattern data f(90, φ). The first signal strength data S(φ) and the first plane pattern data f(90, φ) are calculated using the cyclic cross-correlation calculation formula as follows:

[0244] X(0)=S(0)f(90,0)+S(5)f(90,5)+…+S(360)f(90,360)

[0245] X(5)=S(0)f(90,5)+S(5)f(90,10)+…+S(360)f(90,0)

[0246] …

[0247]

[0248] …

[0249] X(360)=S(0)f(90,360)+S(5)f(90,0)+…+S(360)f(90,355)

[0250] Res=argmax X(k)

[0251] Wherein, k corresponds to the second angle φ and represents the angle value of the second angle φ, k=0, 5, ..., 360, and X(k) is the first cross-correlation value between the first signal strength data S(φ) and the first plane pattern data f(90, φ).

[0252] The above formula is a first cross-correlation value calculated for a planar antenna pattern with a first angle θ = 90°. Similarly, for other angle values ​​of the first angle θ, the corresponding first cross-correlation value can also be calculated based on the above principle.

[0253] Step 110c: Record the angle value of the second angle corresponding to the maximum value of the first mutual correlation value into the first result.

[0254] In the embodiment of the present invention, the first result is represented by Res, where Res=argmax X(k).

[0255] Step 110d: Add the first angle to the preset angle to obtain a third angle.

[0256] In the embodiment of the present invention, the preset angle can be set according to actual conditions. For example, the preset angle is set to 15°.

[0257] Step 110e: Determine whether the third angle is greater than the angle threshold; if not, execute step 110f; if so, execute step 110g.

[0258] In the embodiment of the present invention, the angle threshold can be set according to actual conditions. For example, the angle threshold can be set to 120°.

[0259] Step 110f: Use the third angle as the designated angle and continue with step 110a.

[0260] For example, if the above-mentioned designated angle is 60°, the above-mentioned first angle is also the designated angle of 60°, and the third angle is obtained by adding the preset angle 15° to the first angle. The third angle is 75°. Since 75° is less than the angle threshold of 120°, the third angle 75° is used as the designated angle. When continuing to execute step 110a, the designated angle should be 75°.

[0261] Step 110g: Calculate the angle value of the second angle in the first result by a data fusion method to obtain the first target azimuth angle.

[0262] In the embodiment of the present invention, the data fusion method includes taking an average value, a weighted average value, or a maximum Pearson correlation coefficient.

[0263] Step 110h: rotating the antenna pattern to a first target azimuth angle to obtain a rotated antenna pattern;

[0264] Step 110i: Calculate the first signal strength data and the rotated antenna pattern to obtain a confidence level between the first signal strength data and the rotated antenna pattern.

[0265] For example, by calculating the Pearson correlation coefficient, complexity or Spedarman correlation coefficient between the first signal strength data and the rotated antenna pattern, the Pearson correlation coefficient, complexity or Spedarman correlation coefficient is used as the confidence between the first signal strength data and the rotated antenna pattern.

[0266] Step 110j: Determine whether the confidence level is greater than the coefficient threshold. If not, proceed to step 108; if so, proceed to step 110k.

[0267] In the embodiment of the present invention, the confidence level is used to determine the validity of the first signal strength data collected this time. If the calculated confidence level is greater than the coefficient threshold, the result is determined to be valid; otherwise, the user is prompted to collect the first signal strength data again.

[0268] In the embodiment of the present invention, the coefficient threshold can be set according to actual conditions. For example, the coefficient threshold can be set to 0.5.

[0269] Step 110k: Generate a second interface prompt for prompting the user to perform a second operation according to the first target azimuth angle.

[0270] In the embodiment of the present invention, the second operation includes: the user holds the electronic device and rotates it to a first target azimuth angle, and swings the electronic device up and down in the direction of the first target azimuth angle.

[0271] Step 110l, collecting second signal strength data of the target device when the user performs the second operation according to the second interface prompt;

[0272] Step 110m, calculating the second signal strength and the second plane pattern data including the first target azimuth angle at the second included angle by a loop cross-correlation calculation formula to obtain a second cross-correlation value between the second signal strength data and the second plane pattern data;

[0273] Step 110n, selecting an angle value of the first included angle corresponding to a maximum value of the second cross-correlation value as the second target azimuth angle.

[0274] Step 112, prompting the user to find the target device through an interface prompt mode according to the algorithm result.

[0275] In the embodiment of the application, as shown in the figure, Figure 16 Step 112 specifically includes:

[0276] Step 112a, generating a third interface prompt according to the first target azimuth angle and the second target azimuth angle, the third interface prompt including a direction guide for finding the target device.

[0277] In this step, the target direction, i.e., the second target azimuth angle, is given through the third interface prompt mode according to the first target azimuth angle and the second target azimuth angle in the algorithm result, guiding the user to find the target device in the target direction, as shown in the figure. Figure 17

[0278] Step 112b, collecting a walking track of the user and real-time signal strength of the target device in the process that the user finds the target device according to the third interface prompt.

[0279] Step 112c, recording the track points of the user in different colors according to the walking track and the real-time signal strength, and prompting the user through the degree of urgency of the sound according to the real-time signal strength.

[0280] As shown in the figure, Figure 17 The third interface includes a current area map, which is used to record the walking track of the user and mark the track points in colors according to the real-time signal strength received by the electronic device at the current position, the stronger the signal strength, the deeper the color; meanwhile, the user is prompted about the distance to the target device through the sound, the stronger the signal strength, the louder the sound.

[0281] ​The present invention provides a method for detecting an electronic device's antenna pattern. This method divides the electronic device's three-dimensional antenna pattern into multiple planar antenna pattern data. A cyclic cross-correlation direction-finding algorithm is then used to perform cyclic cross-correlation calculations on the wireless signal strength of a target device received by rotating the electronic device one circle. This algorithmic structure includes azimuth angle information about the target device relative to the electronic device's position. Based on the algorithmic result, the user searches for the target device by directional detection of the signal strength in that area. This eliminates the need to inspect all areas, effectively reducing the area requiring inspection and making it easier to detect and locate potential hidden cameras and eavesdropping devices.

[0282] The embodiment of the present invention virtualizes two WiFi antennas into one antenna with better directivity, so as to improve the accuracy of the cyclic cross-correlation direction finding algorithm based on antenna patterns.

[0283] The embodiment of the present invention can confirm the azimuth angle information of the detected target device, fixedly detect the wireless signal of the target device, and is not easily interfered by other wireless signals in the environment.

[0284] In the technical solution of the detection device method provided in an embodiment of the present invention, the antenna pattern of the electronic device and the first signal strength data of the target device are calculated through a cyclic cross-correlation direction-finding algorithm to obtain an algorithm result; based on the algorithm result, the user is prompted to find the target device through an interface prompt, which can effectively reduce the area that needs to be detected by the electronic device to prevent sneak photography and eavesdropping, and reduce the difficulty of detecting and finding possible sneak photography and eavesdropping devices.

[0285] Combined with the above Figures 1 to 17 , describes in detail the detection device method provided by the embodiment of the present invention, and will be combined with Figure 18 , describes the device embodiments of the present invention in detail. It should be understood that the electronic devices in the embodiments of the present invention can execute the various methods of the aforementioned embodiments of the present invention, that is, the specific working processes of the following various products can refer to the corresponding processes in the aforementioned method embodiments.

[0286] An embodiment of the present invention provides an electronic device, which may be a terminal device or a circuit device built into the terminal device. The electronic device may be used to perform the functions / steps of the above method embodiment.

[0287] Figure 18This is a schematic diagram of the structure of an electronic device 300 provided in an embodiment of the present invention. The electronic device 300 may include a processor 310, an external memory interface 320, an internal memory 321, a universal serial bus (USB) interface 330, a charging management module 340, a power management module 341, a battery 342, an antenna 1, an antenna 2, a mobile communication module 350, a wireless communication module 360, an audio module 370, a speaker 370A, a receiver 370B, a microphone 370C, an earphone interface 370D, a sensor module 380, a button 390, a motor 391, an indicator 392, a camera 393, a display 394, and a subscriber identification module (SIM) card interface 395. The sensor module 380 may include a pressure sensor 380A, a gyroscope sensor 380B, an air pressure sensor 380C, a magnetic sensor 380D, an acceleration sensor 380E, a distance sensor 380F, a proximity light sensor 380G, a fingerprint sensor 380H, a temperature sensor 380J, a touch sensor 380K, an ambient light sensor 380L, a bone conduction sensor 380M, etc.

[0288] It should be understood that the structure illustrated in the embodiment of the present invention does not constitute a specific limitation on the electronic device 300. In other embodiments of the present invention, the electronic device 300 may include more or fewer components than shown, or may combine or separate certain components, or arrange the components differently. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.

[0289] The processor 310 may include one or more processing units. For example, the processor 310 may include an application processor (AP), a modem processor, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU). The different processing units may be independent devices or integrated into one or more processors.

[0290] The controller can generate operation control signals according to the instruction operation code and timing signal to complete the control of instruction fetching and execution.

[0291] Processor 310 may also include a memory for storing instructions and data. In some embodiments, the memory in processor 310 is a cache memory. This memory can store instructions or data that have just been used or are being recycled by processor 310. If processor 310 needs to use the same instruction or data again, it can directly access the memory. This avoids duplicate accesses, reduces processor 310 latency, and thus improves system efficiency.

[0292] In some embodiments, the processor 310 may include one or more interfaces. The interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface.

[0293] The I2C interface is a bidirectional synchronous serial bus that includes a serial data line (SDA) and a serial clock line (SCL). In some embodiments, the processor 310 may include multiple I2C busses. The processor 310 may be coupled to the touch sensor 380K, the charger, the flash, the camera 393, and the like via different I2C bus interfaces. For example, the processor 310 may be coupled to the touch sensor 380K via the I2C interface, enabling communication between the processor 310 and the touch sensor 380K via the I2C bus interface, thereby enabling the touch function of the electronic device 300.

[0294] The I2S interface can be used for audio communication. In some embodiments, the processor 310 can include multiple I2S buses. The processor 310 can be coupled to the audio module 370 via the I2S bus to enable communication between the processor 310 and the audio module 370. In some embodiments, the audio module 370 can transmit audio signals to the wireless communication module 360 ​​via the I2S interface, enabling the function of answering calls through a Bluetooth headset.

[0295] The PCM interface can also be used for audio communication, sampling, quantizing, and encoding analog signals. In some embodiments, the audio module 370 and the wireless communication module 360 ​​can be coupled via a PCM bus interface. In some embodiments, the audio module 370 can also transmit audio signals to the wireless communication module 360 ​​via the PCM interface, enabling the function of answering calls via a Bluetooth headset. Both the I2S interface and the PCM interface can be used for audio communication.

[0296] The UART interface is a universal serial data bus used for asynchronous communication. This bus can be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, the UART interface is typically used to connect the processor 310 and the wireless communication module 360. For example, the processor 310 communicates with the Bluetooth module in the wireless communication module 360 ​​via the UART interface to implement Bluetooth functionality. In some embodiments, the audio module 370 can transmit audio signals to the wireless communication module 360 ​​via the UART interface, enabling the function of playing music through Bluetooth headphones.

[0297] The MIPI interface can be used to connect the processor 310 to peripheral devices such as the display screen 394 and the camera 393. MIPI interfaces include the camera serial interface (CSI) and the display serial interface (DSI). In some embodiments, the processor 310 and the camera 393 communicate via the CSI interface to implement the camera function of the electronic device 300. The processor 310 and the display screen 394 communicate via the DSI interface to implement the display function of the electronic device 300.

[0298] The GPIO interface can be configured through software. The GPIO interface can be configured as a control signal or a data signal. In some embodiments, the GPIO interface can be used to connect the processor 310 to the camera 393, the display 394, the wireless communication module 360, the audio module 370, the sensor module 380, etc. The GPIO interface can also be configured as an I2C interface, an I2S interface, a UART interface, a MIPI interface, etc.

[0299] USB interface 330 is an interface that complies with USB standards and specifications, and may be a Mini USB interface, a Micro USB interface, a USB Type-C interface, or the like. USB interface 330 can be used to connect a charger to charge electronic device 300, or to transfer data between electronic device 300 and peripheral devices. It can also be used to connect headphones to play audio. This interface can also be used to connect other electronic devices, such as AR devices.

[0300] It is understood that the interface connection relationship between the modules illustrated in the embodiment of the present invention is merely an illustrative illustration and does not constitute a structural limitation on the electronic device 300. In other embodiments of the present invention, the electronic device 300 may also adopt a different interface connection method from the above embodiment, or a combination of multiple interface connection methods.

[0301] The charging management module 340 is configured to receive charging input from a charger. The charger can be either a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 340 can receive charging input from the wired charger via the USB interface 330. In some wireless charging embodiments, the charging management module 340 can receive wireless charging input via the wireless charging coil of the electronic device 300. While charging the battery 342, the charging management module 340 can also provide power to the electronic device via the power management module 341.

[0302] The power management module 341 is used to connect the battery 342, the charging management module 340, and the processor 310. The power management module 341 receives input from the battery 342 and / or the charging management module 340 and provides power to the processor 310, the internal memory 321, the display 394, the camera 393, and the wireless communication module 360. The power management module 341 can also be used to monitor parameters such as battery capacity, battery cycle count, and battery health status (leakage, impedance). In some other embodiments, the power management module 341 can also be set in the processor 310. In other embodiments, the power management module 341 and the charging management module 340 can also be set in the same device.

[0303] The wireless communication function of the electronic device 300 can be implemented through the antenna 1, the antenna 2, the mobile communication module 350, the wireless communication module 360, the modem processor and the baseband processor.

[0304] Antenna 1 and Antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in electronic device 300 can be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve antenna utilization. For example, antenna 1 can be reused as a diversity antenna for a wireless local area network. In other embodiments, the antennas can be used in conjunction with a tuning switch.

[0305] The mobile communication module 350 can provide solutions for wireless communications including 2G / 3G / 4G / 5G applied to the electronic device 300. The mobile communication module 350 may include at least one filter, a switch, a power amplifier, a low noise amplifier (LNA), etc. The mobile communication module 350 can receive electromagnetic waves from the antenna 1, and filter, amplify, and process the received electromagnetic waves, and transmit them to the modulation and demodulation processor for demodulation. The mobile communication module 350 can also amplify the signal modulated by the modulation and demodulation processor, and convert it into electromagnetic waves for radiation through the antenna 1. In some embodiments, at least some of the functional modules of the mobile communication module 350 can be set in the processor 310. In some embodiments, at least some of the functional modules of the mobile communication module 350 can be set in the same device as at least some of the modules of the processor 310.

[0306] The modem processor may include a modulator and a demodulator. The modulator is used to modulate the low-frequency baseband signal to be transmitted into a medium-high frequency signal. The demodulator is used to demodulate the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After being processed by the baseband processor, the low-frequency baseband signal is passed to the application processor. The application processor outputs a sound signal through an audio device (not limited to the speaker 370A, the receiver 370B, etc.) or displays an image or video through the display screen 394. In some embodiments, the modem processor may be an independent device. In other embodiments, the modem processor may be independent of the processor 310 and be provided in the same device as the mobile communication module 350 or other functional modules.

[0307] The wireless communication module 360 ​​can provide wireless communication solutions for application on the electronic device 300, including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication technology (NFC), infrared technology (IR), etc.

[0308] The wireless communication module 360 ​​may be one or more devices integrated with at least one communication processing module. The wireless communication module 360 ​​receives electromagnetic waves via the antenna 2, modulates and filters the electromagnetic wave signals, and sends the processed signals to the processor 310.

[0309] The wireless communication module 360 ​​can also receive the signal to be sent from the processor 310, frequency-modulate the signal, amplify the signal, and convert it into electromagnetic waves for radiation through the antenna 2.

[0310] In some embodiments, antenna 1 of electronic device 300 is coupled to mobile communication module 350, and antenna 2 is coupled to wireless communication module 360, so that electronic device 300 can communicate with a network and other devices via wireless communication technology. The wireless communication technology may include global system for mobile communications (GSM), general packet radio service (GPRS), code division multiple access (CDMA), wideband code division multiple access (WCDMA), time-division code division multiple access (TD-SCDMA), long term evolution (LTE), BT, GNSS, WLAN, NFC, FM, and / or IR technology. The GNSS may include a global positioning system (GPS), a global navigation satellite system (GLONASS), a Beidou navigation satellite system (BDS), a quasi-zenith satellite system (QZSS) and / or a satellite based augmentation system (SBAS).

[0311] Electronic device 300 implements display functionality through a GPU, display screen 394, and an application processor. A GPU is a microprocessor for image processing that connects display screen 394 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. Processor 310 may include one or more GPUs that execute program instructions to generate or modify display information.

[0312] Display screen 394 is used to display images, videos, etc. Display screen 394 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), a MiniLED, a MicroLED, a Micro-oLed, or a quantum dot light-emitting diode (QLED). In some embodiments, electronic device 300 may include one or N display screens 394, where N is a positive integer greater than one.

[0313] The electronic device 300 can realize the shooting function through the ISP, camera 393, video codec, GPU, display screen 394 and application processor.

[0314] The ISP processes data fed back by camera 393. For example, when taking a photo, the shutter is opened, and light is transmitted through the lens to the camera's photosensitive element. The light signal is converted into an electrical signal, which is then passed to the ISP for processing and converted into a visible image. The ISP can also perform algorithmic optimization on image noise, brightness, and skin tone. The ISP can also optimize parameters such as exposure and color temperature of the captured scene. In some embodiments, the ISP can be located within camera 393.

[0315] The camera 393 is used to capture still images or videos. The object generates an optical image through the lens and projects it onto the photosensitive element. The photosensitive element can be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the light signal into an electrical signal, and then passes the electrical signal to the ISP to be converted into a digital image signal. The ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into an image signal in a standard RGB, YUV or other format. In some embodiments, the electronic device 300 may include 1 or N cameras 393, where N is a positive integer greater than 1.

[0316] The digital signal processor is used to process digital signals, in addition to being able to process digital image signals, it can also process other digital signals. For example, when the electronic device 300 is in frequency point selection, the digital signal processor is used to perform Fourier transform on the frequency point energy, etc.

[0317] The video codec is used to compress or decompress digital video. The electronic device 300 can support one or more video codecs. In this way, the electronic device 300 can play or record videos in multiple encoding formats, such as: moving picture experts group (MPEG) 1, MPEG 2, MPEG 3, MPEG 4, etc.

[0318] The NPU is a neural-network (NN) calculation processor, which can quickly process input information by drawing on the structure of a biological neural network, such as drawing on the transmission mode between human brain neurons, and can also constantly self-learn. Through the NPU, the electronic device 300 can realize intelligent cognition applications such as image recognition, face recognition, voice recognition, text understanding, etc.

[0319] The external memory interface 320 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 300. The external memory card communicates with the processor 310 through the external memory interface 320 to realize data storage functions. For example, music, video, etc. Files are saved in the external memory card.

[0320] The internal memory 321 can be used to store computer executable program codes, which include instructions. The internal memory 321 can include a program storage area and a data storage area. The program storage area can store an operating system, at least one application program required by a function (such as a sound playing function, an image playing function, etc.), etc. The data storage area can store data created during the use of the electronic device 300 (such as audio data, a phonebook, etc.), etc. In addition, the internal memory 321 can include a high-speed random access memory, and can also include a non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, a universal flash storage (UFS), etc. The processor 310 executes various function applications and data processing of the electronic device 300 by running instructions stored in the internal memory 321 and / or instructions stored in the memory provided in the processor.

[0321] The electronic device 300 can realize audio functions through the audio module 370, the speaker 370A, the receiver 370B, the microphone 370C, the earphone interface 370D, and the application processor, etc. For example, music playing, recording, etc.

[0322] The audio module 370 is configured to convert digital audio information into an analog audio signal output, and to convert an analog audio input into a digital audio signal. The audio module 370 can also be configured to encode and decode audio signals. In some embodiments, the audio module 370 can be disposed in the processor 310, or some functional modules of the audio module 370 can be disposed in the processor 310.

[0323] The speaker 370A, also referred to as a "loudspeaker", is configured to convert an audio electrical signal into a sound signal. The electronic device 300 can listen to music or listen to a hands-free call through the speaker 370A.

[0324] The receiver 370B, also referred to as a "earpiece", is configured to convert an audio electrical signal into a sound signal. When the electronic device 300 receives a call or a voice message, the receiver 370B can be held close to a human ear to listen to the voice.

[0325] The microphone 370C, also referred to as a "microphone", "transducer", is configured to convert a sound signal into an electrical signal. When making a call or sending a voice message, a user can speak into the microphone 370C close to the human mouth to input a sound signal into the microphone 370C. The electronic device 300 can be provided with at least one microphone 370C. In other embodiments, the electronic device 300 can be provided with two microphones 370C, in addition to collecting sound signals, noise reduction functions can also be achieved. In other embodiments, the electronic device 300 can also be provided with three, four or more microphones 370C, in addition to collecting sound signals, noise reduction, and can also identify the source of the sound, and achieve directional recording functions, etc.

[0326] The earphone interface 370D is configured to connect a wired earphone. The earphone interface 370D can be a USB interface 330, or a 3.5mm open mobile terminal platform (OMTP) standard interface, a cellular telecommunications industry association of the USA (CTIA) standard interface.

[0327] The pressure sensor 380A is configured to sense a pressure signal, and can convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 380A can be disposed on the display screen 394.

[0328] There are many types of pressure sensors 380A, such as resistive pressure sensors, inductive pressure sensors, capacitive pressure sensors, etc. A capacitive pressure sensor may include at least two parallel plates with conductive material. When a force acts on the pressure sensor 380A, the capacitance between the electrodes changes. The electronic device 300 determines the intensity of the pressure based on the change in capacitance. When a touch operation acts on the display screen 394, the electronic device 300 detects the intensity of the touch operation based on the pressure sensor 380A. The electronic device 300 can also calculate the position of the touch based on the detection signal of the pressure sensor 380A. In some embodiments, touch operations acting on the same touch position but with different touch operation intensities may correspond to different operation instructions. For example: when a touch operation with a touch operation intensity less than the first pressure threshold acts on the short message application icon, an instruction to view the short message is executed. When a touch operation with a touch operation intensity greater than or equal to the first pressure threshold acts on the short message application icon, an instruction to create a new short message is executed.

[0329] The gyroscope sensor 380B can be used to determine the motion posture of the electronic device 300. In some embodiments, the angular velocity of the electronic device 300 around three axes (i.e., x, y, and z axes) can be determined by the gyroscope sensor 380B. The gyroscope sensor 380B can be used for anti-shake shooting. For example, when the shutter is pressed, the gyroscope sensor 380B detects the angle of the electronic device 300 shaking, calculates the distance that the lens module needs to compensate based on the angle, and allows the lens to offset the shaking of the electronic device 300 through reverse movement to achieve anti-shake. The gyroscope sensor 380B can also be used for navigation and somatosensory game scenes.

[0330] The air pressure sensor 380C is used to measure air pressure. In some embodiments, the electronic device 300 calculates the altitude using the air pressure value measured by the air pressure sensor 380C to assist in positioning and navigation.

[0331] The magnetic sensor 380D includes a Hall sensor. The electronic device 300 can use the magnetic sensor 380D to detect the opening and closing of the flip cover. In some embodiments, when the electronic device 300 is a flip phone, the electronic device 300 can detect the opening and closing of the flip cover using the magnetic sensor 380D. Based on the detected opening and closing status of the leather case or flip cover, features such as automatic unlocking of the flip cover can be configured.

[0332] Accelerometer 380E can detect the magnitude of acceleration of electronic device 300 in all directions (generally three axes). When electronic device 300 is stationary, it can detect the magnitude and direction of gravity. It can also be used to identify the electronic device's posture, enabling applications such as switching between landscape and portrait modes and pedometers.

[0333] The distance sensor 380F is used to measure distance. The electronic device 300 can measure distance using infrared or laser. In some embodiments, when shooting a scene, the electronic device 300 can use the distance sensor 380F to measure distance to achieve fast focusing.

[0334] The proximity light sensor 380G may include, for example, a light emitting diode (LED) and a light detector, such as a photodiode. The light emitting diode may be an infrared light emitting diode. The electronic device 300 emits infrared light outward through the light emitting diode. The electronic device 300 uses a photodiode to detect infrared reflected light from nearby objects. When sufficient reflected light is detected, it can be determined that there is an object near the electronic device 300. When insufficient reflected light is detected, the electronic device 300 can determine that there is no object near the electronic device 300. The electronic device 300 can use the proximity light sensor 380G to detect when the user holds the electronic device 300 close to the ear to talk, so as to automatically turn off the screen to save power. The proximity light sensor 380G can also be used in leather case mode and pocket mode to automatically unlock and lock the screen.

[0335] Ambient light sensor 380L is used to sense ambient light brightness. Electronic device 300 can adaptively adjust the brightness of display screen 394 based on the perceived ambient light. Ambient light sensor 380L can also be used to automatically adjust white balance when taking photos. Ambient light sensor 380L can also work with proximity light sensor 380G to detect whether electronic device 300 is in a pocket to prevent accidental touches.

[0336] The fingerprint sensor 380H is used to collect fingerprints. The electronic device 300 can use the collected fingerprint characteristics to achieve fingerprint unlocking, access application locks, fingerprint photography, fingerprint answering calls, etc.

[0337] The temperature sensor 380J is used to detect temperature. In some embodiments, the electronic device 300 uses the temperature detected by the temperature sensor 380J to implement a temperature processing strategy. For example, when the temperature reported by the temperature sensor 380J exceeds a threshold, the electronic device 300 reduces the performance of the processor located near the temperature sensor 380J to reduce power consumption and implement thermal protection. In other embodiments, when the temperature is lower than another threshold, the electronic device 300 heats the battery 342 to prevent the electronic device 300 from shutting down abnormally due to low temperature. In other embodiments, when the temperature is lower than another threshold, the electronic device 300 boosts the output voltage of the battery 342 to prevent abnormal shutdown due to low temperature.

[0338] The touch sensor 380K is also referred to as a "touch-sensitive device." The touch sensor 380K can be disposed on the display screen 394. The touch sensor 380K and the display screen 394 form a touch screen, also referred to as a "touch screen." The touch sensor 380K is used to detect touch operations applied thereto or in the vicinity thereof. The touch sensor can transmit the detected touch operations to the application processor to determine the type of touch event. Visual output related to the touch operations can be provided via the display screen 394. In other embodiments, the touch sensor 380K can also be disposed on the surface of the electronic device 300, at a location different from that of the display screen 394.

[0339] The bone conduction sensor 380M can acquire vibration signals. In some embodiments, the bone conduction sensor 380M can acquire vibration signals from the vibrating bones of the human body's vocal cords. The bone conduction sensor 380M can also contact the human pulse to receive blood pressure signals. In some embodiments, the bone conduction sensor 380M can also be set in headphones to form bone conduction headphones. The audio module 370 can parse out voice signals based on the vibration signals of the vibrating bones of the vocal cords acquired by the bone conduction sensor 380M to implement voice functions. The application processor can parse heart rate information based on the blood pressure signals acquired by the bone conduction sensor 380M to implement heart rate detection functions.

[0340] The buttons 390 include a power button, a volume button, and the like. The buttons 390 may be mechanical buttons or touch buttons. The electronic device 300 may receive key inputs and generate key signal inputs related to user settings and function control of the electronic device 300.

[0341] Motor 391 can generate vibration prompts. Motor 391 can be used for incoming call vibration prompts, and can also be used for touch vibration feedback. For example, touch operations acting on different applications (such as taking pictures, audio playback, etc.) can correspond to different vibration feedback effects. For touch operations acting on different areas of the display screen 394, motor 391 can also correspond to different vibration feedback effects. Different application scenarios (for example: time reminders, receiving messages, alarm clocks, games, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect can also support customization.

[0342] Indicator 392 can be an indicator light, which can be used to indicate charging status, power changes, messages, missed calls, notifications, etc.

[0343] The SIM card interface 395 is used to connect a SIM card. The SIM card can be connected to and disconnected from the electronic device 300 by inserting it into or removing it from the SIM card interface 395. The electronic device 300 can support 1 or N SIM card interfaces, where N is a positive integer greater than 1. The SIM card interface 395 can support Nano SIM cards, Micro SIM cards, SIM cards, and the like. Multiple cards can be inserted into the same SIM card interface 395 at the same time. The types of the multiple cards can be the same or different. The SIM card interface 395 can also be compatible with different types of SIM cards. The SIM card interface 395 can also be compatible with external memory cards. The electronic device 300 interacts with the network through the SIM card to implement functions such as calls and data communications. In some embodiments, the electronic device 300 uses an eSIM, i.e., an embedded SIM card. The eSIM card can be embedded in the electronic device 300 and cannot be separated from the electronic device 300.

[0344] An embodiment of the present invention provides a computer-readable storage medium having instructions stored therein. When the instructions are executed on a terminal device, the terminal device executes the functions / steps in the above-mentioned method embodiment.

[0345] An embodiment of the present invention further provides a computer program product comprising instructions, which, when executed on a computer or at least one processor, enables the computer to execute the functions / steps in the above method embodiments.

[0346] In the embodiment of the present invention, "at least one" refers to one or more, and "more" refers to two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent the existence of A alone, the existence of A and B at the same time, and the existence of B alone. Among them, A and B can be singular or plural. The character " / " generally indicates that the previous and subsequent associated objects are in an "or" relationship. "At least one of the following" and similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one of a, b and c can be represented by: a, b, c, ab, ac, bc, or abc, where a, b, c can be single or multiple.

[0347] Those skilled in the art will appreciate that the various units and algorithm steps described in the embodiments disclosed herein can be implemented using a combination of electronic hardware, computer software, and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the present invention.

[0348] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0349] In the several embodiments provided by the present invention, if any function is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling an electronic device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0350] The above description is merely a specific embodiment of the present invention. Any modifications or substitutions that may be readily conceived by a person skilled in the art within the technical scope disclosed herein are intended to be encompassed within the scope of protection of the present invention. The scope of protection of the present invention shall be determined by the scope of protection of the claims.

Claims

1. A method for detecting equipment, characterized in that: The method comprises: Calculating the antenna pattern of the electronic device and the first signal strength data of the target device using a cyclic cross-correlation direction finding algorithm to obtain an algorithm result; According to the algorithm result, prompting the user to find the target device through an interface prompt; The step of calculating the antenna pattern of the electronic device and the first signal strength data of the target device using the cyclic cross-correlation direction finding algorithm to obtain an algorithm result specifically includes: Obtaining first plane pattern data including a specified angle at a first included angle according to the antenna pattern; Calculating the first signal strength data and the first plane pattern data using a cyclic cross-correlation calculation formula to obtain a first cross-correlation value between the first signal strength data and the first plane pattern data; Recording the angle value of the second angle corresponding to the maximum value of the first cross-correlation value into the first result; Adding a preset angle to the first angle yields a third angle; Determining whether the third angle is greater than an angle threshold; If the third angle is less than or equal to the angle threshold, the third angle is used as the designated angle, and the step of obtaining first plane pattern data including the designated angle at the first angle according to the antenna pattern is continued.

2. The method according to claim 1, characterized in that Before calculating the antenna pattern of the electronic device and the first signal strength data of the target device using the cyclic cross-correlation direction finding algorithm to obtain the algorithm result, the method further includes: Scanning and traversing the first network according to the working mode selected by the user to determine whether the target device exists; If it is determined that the target device exists, determining a target channel or a target frequency band where the target device is located; Selecting, according to the target channel or the target frequency band, the antenna pattern of the electronic device corresponding to the target channel or the target frequency band; Collect first signal strength data of the target device.

3. The method according to claim 2, characterized in that The working mode includes detecting WiFi network devices or detecting cellular network devices.

4. The method according to claim 3, characterized in that The working mode includes detecting a WiFi networked device, wherein the first network includes different WiFi channels around the electronic device; The working mode includes detecting a cellular network device, wherein the first network includes different cellular signal frequency bands around the electronic device.

5. The method according to claim 4, characterized in that When the working mode includes detecting a WiFi networked device, scanning and traversing the first network according to the working mode selected by the user to determine whether the target device exists specifically includes: Searching for a first device list connected to the same WiFi hotspot as the electronic device; determining, according to the target parameter of the first device in the first device list, whether the first device list includes the target device; If it is determined that the first device list includes the target device, continuing to perform the step of determining the target channel or target frequency band where the target device is located; If it is determined that the target device is not included in the first device list, enabling a sniffer function of a WiFi chip in the electronic device to sniff network transmission information of all surrounding WiFi channels; The target features of the sniffed data packets are calculated using a machine learning algorithm to determine whether there is video transmission data. If it is determined that there is video transmission data, the target device is searched for according to the video transmission data, and the step of determining the target channel or target frequency band where the target device is located is continued.

6. The method according to claim 4, characterized in that When the working mode includes detecting a cellular network device, scanning and traversing the first network according to the working mode selected by the user to determine whether the target device exists specifically includes: Scan and traverse different cellular signal frequency bands according to the working mode selected by the user to determine whether a cellular signal exists.

7. The method according to claim 2, characterized in that The determining of the target channel or target frequency band where the target device is located specifically includes: Determine the target WiFi channel or target cellular network frequency band where the target device is located.

8. The method according to claim 7, characterized in that When the working mode includes detecting WiFi networked devices, The selecting, according to the target channel or the target frequency band, the antenna pattern of the electronic device corresponding to the target channel or the target frequency band specifically includes: According to the target WiFi channel, selecting WiFi antenna patterns of two WiFi antennas of the electronic device on the target WiFi channel; The two WiFi antenna patterns are subtracted to obtain the antenna pattern.

9. The method according to claim 7, characterized in that When the operating mode includes detecting cellular network devices, The selecting, according to the target channel or the target frequency band, the antenna pattern of the electronic device corresponding to the target channel or the target frequency band specifically includes: According to the target cellular network frequency band, the antenna pattern of the electronic device corresponding to the target cellular network frequency band is selected.

10. The method according to claim 2, characterized in that The collecting the first signal strength data of the target device specifically includes: generating a first interface prompt for prompting the user to perform a first operation; When the user performs the first operation according to the first interface prompt, first signal strength data of the target device is collected.

11. The method according to claim 10, characterized in that When the working mode includes detecting a WiFi networked device, the first operation includes: the user holding the electronic device and rotating it in place; When the working mode includes detecting a cellular network device, the first operation includes: the user selecting a holding method corresponding to a target cellular network frequency band, and holding the electronic device and rotating it in place.

12. The method according to claim 11, characterized in that The target cellular network frequency band includes a low-frequency cellular network, a medium-frequency cellular network, or a high-frequency cellular network.

13. The method according to claim 8, characterized in that When the working mode includes detecting a WiFi networked device, the first signal strength data includes a difference in signal strength data of the target device received by the two WiFi antennas.

14. The method according to claim 2, characterized in that After determining whether the third angle is greater than the angle threshold, the method further includes: If the third angle is greater than the angle threshold, calculating the angle value of the second angle in the first result by a data fusion method to obtain a first target azimuth angle; Obtaining a rotated antenna pattern by rotating the antenna pattern to the first target azimuth angle; Obtaining a confidence level between the first signal strength data and the rotated antenna pattern by calculating the first signal strength data and the rotated antenna pattern; Determining whether the confidence level is greater than a coefficient threshold; If it is determined that the confidence level is less than or equal to the coefficient threshold, the step of collecting the first signal strength data of the target device is continued.

15. The method according to claim 14, characterized in that After determining whether the confidence level is greater than the coefficient threshold, the method further includes: If it is determined that the confidence level is greater than the coefficient threshold, generating a second interface prompt for prompting the user to perform a second operation according to the first target azimuth angle; When the user performs the second operation according to the second interface prompt, collecting second signal strength data of the target device; Calculating the second signal strength and the second plane pattern data at the second included angle including the first target azimuth angle using the cyclic cross-correlation calculation formula to obtain a second cross-correlation value between the second signal strength data and the second plane pattern data; The angle value of the first angle corresponding to the maximum value of the second cross-correlation value is selected as the second target azimuth angle.

16. The method according to claim 15, characterized in that The step of prompting the user to search for the target device through an interface prompt based on the algorithm result specifically includes: generating a third interface prompt according to the first target azimuth angle and the second target azimuth angle, wherein the third interface prompt includes a direction guide for finding the target device; In the process of the user searching for the target device according to the prompt of the third interface, collecting the walking trajectory of the user and the real-time signal strength of the target device; According to the walking track and the real-time signal strength, the user's track points are recorded in different colors, and the user is prompted by the degree of urgency of the sound according to the real-time signal strength.

17. The method according to claim 15, characterized in that The second operation includes: the user holding the electronic device and rotating it to the first target azimuth angle, and swinging the electronic device up and down in the direction of the first target azimuth angle.

18. The method according to claim 1, wherein The preset angle includes 15°.

19. The method according to claim 1, wherein The angle threshold comprises 120°.

20. The method according to claim 14, wherein The coefficient threshold includes 0.

5.

21. The method according to claim 3, characterized in that When the working mode includes detecting a WiFi networked device, the target device includes a camera; When the working mode includes detecting a cellular network device, the target device includes a listener.

22. An electronic device, characterized in that: The electronic device includes a processor and a memory, wherein the memory is used to store a computer program, and the computer program includes program instructions. When the processor runs the program instructions, the electronic device performs the following steps: Calculating the antenna pattern of the electronic device and the first signal strength data of the target device using a cyclic cross-correlation direction finding algorithm to obtain an algorithm result; According to the algorithm result, prompting the user to find the target device through an interface prompt; The step of calculating the antenna pattern of the electronic device and the first signal strength data of the target device using the cyclic cross-correlation direction finding algorithm to obtain an algorithm result specifically includes: Obtaining first plane pattern data including a specified angle at a first included angle according to the antenna pattern; Calculating the first signal strength data and the first plane pattern data using a cyclic cross-correlation calculation formula to obtain a first cross-correlation value between the first signal strength data and the first plane pattern data; Recording the angle value of the second angle corresponding to the maximum value of the first cross-correlation value into the first result; Adding a preset angle to the first angle yields a third angle; Determining whether the third angle is greater than an angle threshold; If the third angle is less than or equal to the angle threshold, the third angle is used as the designated angle, and the step of obtaining first plane pattern data including the designated angle at the first angle according to the antenna pattern is continued.

23. The electronic device according to claim 22, wherein: When the processor executes the program instructions, the electronic device performs the following steps: Before calculating the antenna pattern of the electronic device and the first signal strength data of the target device using the cyclic cross-correlation direction finding algorithm to obtain the algorithm result, the method further includes: Scanning and traversing the first network according to the working mode selected by the user to determine whether the target device exists; If it is determined that the target device exists, determining a target channel or a target frequency band where the target device is located; Selecting, according to the target channel or the target frequency band, the antenna pattern of the electronic device corresponding to the target channel or the target frequency band; Collect first signal strength data of the target device.

24. The electronic device according to claim 23, wherein: The working mode includes detecting WiFi network devices or detecting cellular network devices.

25. The electronic device according to claim 24, characterized in that The working mode includes detecting a WiFi networked device, wherein the first network includes different WiFi channels around the electronic device; The working mode includes detecting a cellular network device, wherein the first network includes different cellular signal frequency bands around the electronic device.

26. The electronic device according to claim 25, characterized in that When the processor executes the program instructions, the electronic device performs the following steps: When the working mode includes detecting a WiFi networked device, scanning and traversing the first network according to the working mode selected by the user to determine whether the target device exists specifically includes: Searching for a first device list connected to the same WiFi hotspot as the electronic device; determining, according to the target parameter of the first device in the first device list, whether the first device list includes the target device; If it is determined that the first device list includes the target device, continuing to perform the step of determining the target channel or target frequency band where the target device is located; If it is determined that the target device is not included in the first device list, enabling a sniffer function of a WiFi chip in the electronic device to sniff network transmission information of all surrounding WiFi channels; The target features of the sniffed data packets are calculated using a machine learning algorithm to determine whether there is video transmission data. If it is determined that there is video transmission data, the target device is searched for according to the video transmission data, and the step of determining the target channel or target frequency band where the target device is located is continued.

27. The electronic device according to claim 25, characterized in that When the processor executes the program instructions, the electronic device performs the following steps: When the working mode includes detecting a cellular network device, scanning and traversing the first network according to the working mode selected by the user to determine whether the target device exists specifically includes: Scan and traverse different cellular signal frequency bands according to the working mode selected by the user to determine whether a cellular signal exists.

28. The electronic device according to claim 23, wherein: When the processor executes the program instructions, the electronic device performs the following steps: The determining of the target channel or target frequency band where the target device is located specifically includes: Determine the target WiFi channel or target cellular network frequency band where the target device is located.

29. The electronic device according to claim 28, wherein When the processor executes the program instructions, the electronic device performs the following steps: When the working mode includes detecting WiFi networked devices, The selecting, according to the target channel or the target frequency band, the antenna pattern of the electronic device corresponding to the target channel or the target frequency band specifically includes: According to the target WiFi channel, selecting WiFi antenna patterns of two WiFi antennas of the electronic device on the target WiFi channel; The two WiFi antenna patterns are subtracted to obtain the antenna pattern.

30. The electronic device according to claim 28, wherein When the processor executes the program instructions, the electronic device performs the following steps: When the operating mode includes detecting cellular network devices, The selecting, according to the target channel or the target frequency band, the antenna pattern of the electronic device corresponding to the target channel or the target frequency band specifically includes: According to the target cellular network frequency band, the antenna pattern of the electronic device corresponding to the target cellular network frequency band is selected.

31. The electronic device according to claim 23, wherein When the processor executes the program instructions, the electronic device performs the following steps: The collecting the first signal strength data of the target device specifically includes: generating a first interface prompt for prompting the user to perform a first operation; When the user performs the first operation according to the first interface prompt, first signal strength data of the target device is collected.

32. The electronic device according to claim 31, wherein: When the working mode includes detecting a WiFi networked device, the first operation includes: the user holding the electronic device and rotating it in place; When the working mode includes detecting a cellular network device, the first operation includes: the user selecting a holding method corresponding to a target cellular network frequency band, and holding the electronic device and rotating it in place.

33. The electronic device according to claim 32, characterized in that The target cellular network frequency band includes a low-frequency cellular network, a medium-frequency cellular network, or a high-frequency cellular network.

34. The electronic device according to claim 29, wherein When the working mode includes detecting a WiFi networked device, the first signal strength data includes a difference in signal strength data of the target device received by the two WiFi antennas.

35. The electronic device according to claim 23, wherein When the processor executes the program instructions, the electronic device performs the following steps: After determining whether the third angle is greater than the angle threshold, the method further includes: If the third angle is greater than the angle threshold, calculating the angle value of the second angle in the first result by a data fusion method to obtain a first target azimuth angle; Obtaining a rotated antenna pattern by rotating the antenna pattern to the first target azimuth angle; Obtaining a confidence level between the first signal strength data and the rotated antenna pattern by calculating the first signal strength data and the rotated antenna pattern; Determining whether the confidence level is greater than a coefficient threshold; If it is determined that the confidence level is less than or equal to the coefficient threshold, the step of collecting the first signal strength data of the target device is continued.

36. The electronic device according to claim 35, characterized in that When the processor executes the program instructions, the electronic device performs the following steps: After determining whether the confidence level is greater than the coefficient threshold, the method further includes: If it is determined that the confidence level is greater than the coefficient threshold, generating a second interface prompt for prompting the user to perform a second operation according to the first target azimuth angle; When the user performs the second operation according to the second interface prompt, collecting second signal strength data of the target device; Calculating the second signal strength and the second plane pattern data at the second included angle including the first target azimuth angle using the cyclic cross-correlation calculation formula to obtain a second cross-correlation value between the second signal strength data and the second plane pattern data; The angle value of the first angle corresponding to the maximum value of the second cross-correlation value is selected as the second target azimuth angle.

37. The electronic device according to claim 36, wherein: When the processor executes the program instructions, the electronic device performs the following steps: The step of prompting the user to search for the target device through an interface prompt based on the algorithm result specifically includes: generating a third interface prompt according to the first target azimuth angle and the second target azimuth angle, wherein the third interface prompt includes a direction guide for finding the target device; In the process of the user searching for the target device according to the prompt of the third interface, collecting the walking trajectory of the user and the real-time signal strength of the target device; According to the walking track and the real-time signal strength, the user's track points are recorded in different colors, and the user is prompted by the degree of urgency of the sound according to the real-time signal strength.

38. The electronic device according to claim 36, wherein: The second operation includes: the user holding the electronic device and rotating it to the first target azimuth angle, and swinging the electronic device up and down in the direction of the first target azimuth angle.

39. The electronic device according to claim 22, wherein The preset angle includes 15°.

40. The electronic device according to claim 22, wherein The angle threshold comprises 120°.

41. The electronic device according to claim 35, wherein When the coefficient threshold is included 0.

5.

42. The electronic device according to claim 24, wherein: When the working mode includes detecting a WiFi networked device, the target device includes a camera; When the working mode includes detecting a cellular network device, the target device includes a listener.

43. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, wherein the computer program includes program instructions. When the program request is executed by a computer, the computer is enabled to execute the method according to any one of claims 1 to 21.

Citation Information

Patent Citations

  • Method and device for positioning terminal

    CN107526057A

  • Radio positioning method based on DOA (Direction of Arrival) estimation

    CN108120953A