A positioning method, communication system and electronic device
By analyzing the signal strength and noise levels of high-frequency and low-frequency acoustic signals using detection equipment, and flexibly selecting frequency bands as detection signals, the accuracy and user experience issues of acoustic positioning in existing technologies are solved, enabling efficient positioning in different environments.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HUAWEI TECH CO LTD
- Filing Date
- 2025-01-10
- Publication Date
- 2026-07-10
AI Technical Summary
Existing sound wave-based positioning technology struggles to balance detection accuracy, effective measurement range, and user experience, especially when there are obstructions, resulting in inaccurate measurement results and a poor auditory experience for users.
The detection equipment analyzes the signal strength and noise level of high-frequency and low-frequency acoustic signals, and flexibly selects the appropriate frequency band as the detection signal to optimize the positioning method, improve detection accuracy and user experience.
In different noise environments, the detection equipment can find the best balance between detection accuracy, user auditory experience and effective detection distance, thereby improving the accuracy of positioning results and user experience.
Smart Images

Figure CN122362285A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of terminal technology, and in particular to a positioning method, a communication system, and an electronic device. Background Technology
[0002] When using sound waves to measure direction, the frequency band of the sound wave used as the detection signal is highly correlated with the detection effect and user experience. Specifically, higher frequency sound waves have less impact on human hearing, resulting in a better auditory experience. Conversely, lower frequency sound waves have a greater impact on human hearing, resulting in a worse auditory experience. Higher frequency sound waves have a smaller effective range for measuring direction, while lower frequency sound waves have a larger effective range. In the presence of obstructions, higher frequency sound waves attenuate more severely, thus reducing the effective range for measuring direction.
[0003] Therefore, when using sound waves for precise location, if the sound wave frequency is low, it is easily affected by environmental noise, leading to inaccurate detection results; if the sound wave frequency is high, the effective range of the measurement orientation is limited. In other words, sound wave-based location measurement schemes struggle to balance detection accuracy and effective measurement range. Furthermore, since current sound wave-based precise location technologies use frequency-sweeping signals as detection signals, low-frequency sound waves can cause unpleasant, harsh buzzing noises from the device, resulting in a poor auditory experience for the user. Summary of the Invention
[0004] This application provides a positioning method, a communication system, and an electronic device. The positioning method utilizes sound waves to determine the relative position of a device and is applied to a communication system containing a detection device and a device under test. Specifically, after establishing a wireless communication connection between the detection device and the device under test, the detection device can notify the device under test to send high-frequency and low-frequency sound wave signals based on this connection. Subsequently, the detection device analyzes multiple factors, including the signal strength of the high-frequency sound wave signal, the signal strength of the low-frequency sound wave signal, the magnitude of high-frequency noise, and the magnitude of low-frequency noise, to determine which frequency band is more suitable for precise location, i.e., the frequency band to be used as the detection signal. In this way, the detection device can find the optimal balance between detection accuracy, user auditory experience, and effective detection distance, thereby improving the user experience of using the precise location function.
[0005] In a first aspect, this application provides a positioning method applied to a first electronic device in a communication system, the communication system further comprising a second electronic device. The method includes: establishing a wireless communication connection between the first electronic device and the second electronic device; the first electronic device notifying the second electronic device to transmit a high-frequency acoustic signal and a low-frequency acoustic signal based on the wireless communication connection; the first electronic device receiving the high-frequency acoustic signal and the low-frequency acoustic signal transmitted by the second electronic device; when the high-frequency noise is greater than a first noise threshold and the low-frequency noise is less than or equal to a second noise threshold, the first electronic device determining and outputting the relative position between the first electronic device and the second electronic device based on the received low-frequency acoustic signal; when the low-frequency noise is greater than the second noise threshold and the high-frequency noise is less than or equal to the first noise threshold, the first electronic device determining and outputting the relative position between the first electronic device and the second electronic device based on the received high-frequency acoustic signal; when the low-frequency noise is greater than the second noise threshold and the high-frequency noise is greater than the first noise threshold, the first electronic device not outputting the relative position between the first electronic device and the second electronic device.
[0006] Implementing the method provided in the first aspect, after the user activates the precise search function, the device under test (i.e., the second electronic device) can emit acoustic wave signals in two frequency bands. After receiving the two acoustic wave signals, the detection device (i.e., the first electronic device) can determine which frequency band to use as the detection signal based on the magnitude of low-frequency and high-frequency noise in the environment. Thus, the detection device can flexibly select the appropriate acoustic wave frequency band for detection under different noise environments, thereby improving detection accuracy and reliability.
[0007] In conjunction with the first aspect, in some embodiments, the method further includes: when the signal strength of the high-frequency acoustic signal is less than a first signal strength threshold and the signal strength of the low-frequency acoustic signal is greater than or equal to a second signal strength threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received low-frequency acoustic signal; when the signal strength of the high-frequency acoustic signal is greater than or equal to the first signal strength threshold and the signal strength of the low-frequency acoustic signal is less than the second signal strength threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received high-frequency acoustic signal.
[0008] By implementing the method provided in the above embodiments, the detection device can also determine whether to switch the detection signal based on the signal strength of the received high-frequency acoustic signal, thereby optimizing the implementation effect of the positioning method.
[0009] In conjunction with the first aspect, in some embodiments, the method further includes: when the signal strength of the high-frequency acoustic signal is less than the first signal strength threshold and the low-frequency noise is less than or equal to the second noise threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received low-frequency acoustic signal; when the signal strength of the low-frequency acoustic signal is less than the second signal strength threshold and the high-frequency noise is less than or equal to the first noise threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received high-frequency acoustic signal.
[0010] By implementing the method provided in the above embodiments, the detection device can flexibly determine whether to switch the detection signal by combining the signal strength of the sound wave and the magnitude of the noise, thereby optimizing the implementation effect of the positioning method.
[0011] In conjunction with the first aspect, in some embodiments, the method further includes: when the high-frequency noise is greater than the first noise threshold and the low-frequency sound wave signal intensity is greater than or equal to the second signal intensity threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received low-frequency sound wave signal; when the low-frequency noise is greater than the second noise threshold and the high-frequency sound wave signal intensity is greater than or equal to the first signal intensity threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received high-frequency sound wave signal.
[0012] By implementing the method provided in the above embodiments, the detection device can flexibly determine whether to switch the detection signal by combining the signal strength of the sound wave and the magnitude of the noise, thereby optimizing the implementation effect of the positioning method.
[0013] In conjunction with the first aspect, in some embodiments, the method further includes: an initial stage in which the first electronic device first determines the relative position between the first electronic device and the second electronic device based on the high-frequency acoustic signal; after the initial stage, the first electronic device switches to determining and outputting the relative position between the first electronic device and the second electronic device based on the low-frequency acoustic signal; after the switch, the first electronic device continues to determine and output the relative position between the first electronic device and the second electronic device based on the low-frequency acoustic signal until the deviation between two adjacent measurements of the relative position is greater than a first deviation threshold or the low-frequency noise is greater than a second noise threshold.
[0014] By implementing the method provided in the above embodiments, the detection device can initially use a high-frequency acoustic signal as the detection signal. When the high-frequency acoustic signal is unsuitable, it switches to using a low-frequency acoustic signal as the detection signal. After switching, the low-frequency acoustic signal is continuously used as the detection signal until it also becomes unsuitable. The conditions under which the low-frequency acoustic signal is unsuitable include the detection device detecting a relative position deviation (i.e., the deviation between two adjacent measurements of the relative position) greater than a first deviation threshold or low-frequency noise greater than a second noise threshold. Therefore, the detection device can use a low-frequency acoustic signal as a supplementary detection signal when the high-frequency acoustic signal is unavailable, and reduce the power consumption of the detection device by conditionally and continuously using the low-frequency acoustic signal as the detection signal.
[0015] In conjunction with the first aspect, in some embodiments, the method further includes: if the deviation between two adjacent measurements of the relative position is greater than a first deviation threshold or the low-frequency noise is greater than a second noise threshold, the first electronic device recovers and outputs the relative position between the first electronic device and the second electronic device based on the high-frequency acoustic signal.
[0016] By implementing the method provided in the above embodiments, when the detection device finds that the switched low-frequency acoustic signal is also unsuitable, the detection device can reset the detection signal and re-determine which acoustic signal to use as the detection signal, thereby improving the accuracy of the positioning results.
[0017] In conjunction with the first aspect, in some embodiments, the method further includes: an initial stage in which the first electronic device determines the relative position between the first electronic device and the second electronic device based on the low-frequency acoustic signal; after the initial stage, the first electronic device switches to determining and outputting the relative position between the first electronic device and the second electronic device based on the high-frequency acoustic signal; after the switch, the first electronic device continues to determine and output the relative position between the first electronic device and the second electronic device based on the high-frequency acoustic signal until the deviation between two adjacent measurements of the relative position is greater than a first deviation threshold or the high-frequency noise is greater than the first noise threshold.
[0018] By implementing the method provided in the above embodiments, the detection device can initially use a low-frequency acoustic wave signal as the detection signal. When the low-frequency acoustic wave signal is not applicable, it switches to using a high-frequency acoustic wave signal as the detection signal. Furthermore, after the switch, the high-frequency acoustic wave signal is continuously used as the detection signal until it is also unsuitable. Therefore, the detection device does not need to repeatedly determine which acoustic wave signal to select as the detection signal, thus reducing the power consumption of the detection device.
[0019] In conjunction with the first aspect, in some embodiments, the method further includes: if the deviation between two adjacent measurements of the relative position is greater than a first deviation threshold or the high-frequency noise is greater than the first noise threshold, the first electronic device recovers and outputs the relative position between the first electronic device and the second electronic device based on the low-frequency sound wave signal.
[0020] By implementing the method provided in the above embodiments, when the detection device finds that the switched high-frequency acoustic signal is also unsuitable, the detection device can reset the detection signal and re-determine which acoustic signal to use as the detection signal, thereby improving the accuracy of the positioning results.
[0021] In conjunction with the first aspect, in some embodiments, when the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device by receiving the low-frequency acoustic signal, the method further includes: the first electronic device notifying the second electronic device to stop transmitting the high-frequency acoustic signal.
[0022] By implementing the method provided in the above embodiments, the detection device can notify the device under test to stop sending non-detection signals, thereby reducing the power consumption of the device under test.
[0023] In conjunction with the first aspect, in some embodiments, before the first electronic device resumes determining and outputting the relative position between the first electronic device and the second electronic device via the received high-frequency acoustic signal, the method further includes: the first electronic device notifying the second electronic device to resume transmitting the high-frequency acoustic signal.
[0024] Implementing the method provided in the above embodiments, if the device under test previously stopped emitting one type of acoustic signal, the detection device needs to notify the device under test to resume transmitting acoustic signals of both different frequency bands during reset. This ensures the accuracy of the detection device's judgment in the next round.
[0025] In conjunction with the first aspect, in some embodiments, when the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device through the received high-frequency acoustic signal, the method further includes: the first electronic device notifying the second electronic device to stop transmitting the low-frequency acoustic signal.
[0026] By implementing the method provided in the above embodiments, the detection device can notify the device under test to stop sending non-detection signals, thereby reducing the power consumption of the device under test.
[0027] In conjunction with the first aspect, in some embodiments, before the first electronic device resumes determining and outputting the relative position between the first electronic device and the second electronic device via the received low-frequency acoustic signal, the method further includes: the first electronic device notifying the second electronic device to resume transmitting the low-frequency acoustic signal.
[0028] Implementing the method provided in the above embodiments, if the device under test previously stopped emitting one type of acoustic signal, the detection device needs to notify the device under test to resume transmitting acoustic signals of both different frequency bands during reset. This ensures the accuracy of the detection device's judgment in the next round.
[0029] In conjunction with the first aspect, in some embodiments, the method further includes: when the high-frequency noise is greater than the first noise threshold and the low-frequency noise is less than or equal to the second noise threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device by receiving the low-frequency sound wave signal; the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device by receiving the high-frequency sound wave signal in the following situations: the high-frequency noise is less than or equal to the first noise threshold, the high-frequency noise is greater than the first noise threshold, and the low-frequency noise is greater than the second noise threshold.
[0030] By implementing the method provided in the above embodiments, the detection device can determine which frequency band of signal to select as the detection signal based on environmental noise (including high-frequency noise and low-frequency noise). In the above embodiments, the detection device can preferentially use high-frequency sound wave signals as the detection signal, thereby increasing the anti-interference capability of positioning and improving the accuracy of the precise search results.
[0031] In conjunction with the first aspect, in some embodiments, the method further includes: when the signal strength of the high-frequency acoustic signal is less than a first signal strength threshold and the signal strength of the low-frequency acoustic signal is greater than or equal to a second signal strength threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received low-frequency acoustic signal; the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received high-frequency acoustic signal in any of the following situations: the signal strength of the high-frequency acoustic signal is greater than or equal to the first signal strength threshold, the signal strength of the high-frequency acoustic signal is less than the first signal strength threshold, and the signal strength of the low-frequency acoustic signal is less than the second signal strength threshold.
[0032] By implementing the method provided in the above embodiments, the detection device can determine which frequency band to select as the detection signal based on the signal strength of the acoustic signal (including high-frequency acoustic signals and low-frequency acoustic signals). In the above embodiments, the detection device can preferentially use high-frequency acoustic signals as the detection signal, thereby increasing the anti-interference capability of the positioning and improving the accuracy of the precise search results.
[0033] In conjunction with the first aspect, in some embodiments, the method further includes: when the signal strength of the high-frequency acoustic signal is less than a first signal strength threshold and the low-frequency noise is less than or equal to a second noise threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received low-frequency acoustic signal; the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received high-frequency acoustic signal in any of the following situations: the signal strength of the high-frequency acoustic signal is greater than or equal to the first signal strength threshold, the signal strength of the high-frequency acoustic signal is less than the first signal strength threshold, and the low-frequency noise is greater than the second noise threshold.
[0034] By implementing the method provided in the above embodiments, the detection device can determine which frequency band to select as the detection signal by combining the signal strength of noise and acoustic wave signals (here, high-frequency acoustic wave signals). In the above embodiments, the detection device can preferentially use high-frequency acoustic wave signals as detection signals, thereby increasing the anti-interference capability of positioning and improving the accuracy of the precise search results.
[0035] In conjunction with the first aspect, in some embodiments, the method further includes: when the high-frequency noise is greater than the first noise threshold and the low-frequency sound wave signal strength is greater than or equal to the second signal strength threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received low-frequency sound wave signal; the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received high-frequency sound wave signal in any of the following situations: the high-frequency noise is less than or equal to the first noise threshold, the high-frequency noise is greater than or equal to the first noise threshold and the fixed-frequency sound wave signal strength is less than the second signal strength threshold.
[0036] By implementing the method provided in the above embodiments, the detection device can determine which frequency band to select as the detection signal by combining the signal strength of noise and acoustic wave signals (in this case, low-frequency acoustic wave signals). In the above embodiments, the detection device can preferentially use high-frequency acoustic wave signals as the detection signal, thereby increasing the anti-interference capability of the positioning and improving the accuracy of the precise search results.
[0037] Secondly, embodiments of this application provide a positioning method applied to a second electronic device in a communication system, the communication system further including a first electronic device, the method comprising: establishing a wireless communication connection with the first electronic device; receiving a notification from the first electronic device indicating, based on the wireless communication connection, to transmit a high-frequency acoustic signal and a low-frequency acoustic signal; and transmitting the high-frequency acoustic signal and the low-frequency acoustic signal.
[0038] By implementing the method provided in the second aspect, the device under test (i.e., the second electronic device) can receive instructions from the detection device based on private commands in the wireless communication protocol and stably transmit two different frequency bands of acoustic signals, so that the device under test does not need to frequently switch acoustic frequency bands.
[0039] Thirdly, embodiments of this application provide a positioning method applied to a communication system, the communication system including a first electronic device and a second electronic device. The method includes: establishing a wireless communication connection between the first electronic device and the second electronic device; the first electronic device notifying the second electronic device to transmit a high-frequency acoustic signal and a low-frequency acoustic signal based on the wireless communication connection; the second electronic device transmitting the high-frequency acoustic signal and the low-frequency acoustic signal; the first electronic device receiving the high-frequency acoustic signal and the low-frequency acoustic signal transmitted by the second electronic device; when the high-frequency noise is greater than a first noise threshold and the low-frequency noise is less than or equal to a second noise threshold, the first electronic device determining and outputting the relative position between the first electronic device and the second electronic device based on the received low-frequency acoustic signal; when the low-frequency noise is greater than the second noise threshold and the high-frequency noise is less than or equal to the first noise threshold, the first electronic device determining and outputting the relative position between the first electronic device and the second electronic device based on the received high-frequency acoustic signal; when the low-frequency noise is greater than the second noise threshold and the high-frequency noise is greater than the first noise threshold, the first electronic device not outputting the relative position between the first electronic device and the second electronic device.
[0040] Implementing the method provided in the third aspect, after the user activates the precise search function, the device under test (i.e., the second electronic device) can emit acoustic signals in two frequency bands. After receiving the two acoustic signals, the detection device (i.e., the first electronic device) can determine which frequency band to use as the detection signal based on the magnitude of low-frequency and high-frequency noise in the environment. Thus, the detection device can flexibly select the appropriate acoustic frequency band for detection under different noise environments, thereby improving detection accuracy and reliability.
[0041] Fourthly, this application provides an electronic device, including a memory, a processor, and a computer program stored in the memory; the processor executes the computer program to implement the method described in the first aspect and any possible implementation thereof or the second aspect and any possible implementation thereof.
[0042] Fifthly, this application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the method described in the first aspect and any possible implementation thereof.
[0043] In a sixth aspect, this application provides a computer program product, including a computer program that, when executed by a processor, implements the method described in the first aspect and any possible implementation thereof.
[0044] Understandably, the electronic device provided in the fourth aspect, the computer storage medium provided in the fifth aspect, and the computer program product provided in the sixth aspect are all used to execute the method provided in this application. Therefore, the beneficial effects they can achieve can be referred to the beneficial effects in the corresponding methods, and will not be repeated here. Attached Figure Description
[0045] Figure 1 This is a schematic diagram of a precise search technique provided in an embodiment of this application;
[0046] Figure 2 This is an architectural diagram of a testing device provided in an embodiment of this application;
[0047] Figure 3 This is an architecture diagram of a device under test provided in an embodiment of this application;
[0048] Figure 4 This is a flowchart illustrating a positioning method provided in an embodiment of this application;
[0049] Figure 5 This is a flowchart illustrating another positioning method provided in an embodiment of this application;
[0050] Figure 6 This is a flowchart illustrating another positioning method provided in an embodiment of this application;
[0051] Figure 7 This is a flowchart illustrating another positioning method provided in an embodiment of this application;
[0052] Figure 8 This is a schematic diagram of the structure of a detection device provided in an embodiment of this application;
[0053] Figure 9 This is a schematic diagram of the structure of a device under test provided in an embodiment of this application. Detailed Implementation
[0054] The terminology used in the embodiments of this application is for the purpose of describing particular embodiments only and is not intended to be a limitation of this application.
[0055] As the number of devices owned by users continues to increase, the risk of device loss also rises. To address this challenge, device location functions have emerged, with precise location functionality being particularly crucial. This precise location function is a device positioning technology that, through wireless communication technology, provides centimeter-level positioning accuracy, helping users quickly and accurately locate lost devices or items. The optimization and introduction of this precise location function greatly improves the success rate of device retrieval, providing users with a more convenient and reliable device management experience.
[0056] Figure 1 This is a schematic diagram of a precise search technique provided in an embodiment of this application.
[0057] like Figure 1 As shown, the aforementioned precise location technology can involve two electronic devices: a detection device and a device under test, which is also the target device in the precise location. Specifically, the detection device can utilize various wireless communication technologies, including sound waves, ultra-wide bandwidth (UWB), wireless fidelity (Wi-Fi), Bluetooth Low Energy (BLE), and satellite imagery, to achieve precise positioning of the target device within a short to medium distance range. For example, when the distance between the detection device and the target device is within the range of 3 to 30 meters, the detection device can display the distance and angle of the target device relative to the detection device on the screen; if the distance between the detection device and the target device is less than 3 meters, the detection device can also instruct the target device to ring, thereby further facilitating the user's search for the target device.
[0058] When using sound waves to measure direction, the frequency band of the sound wave used as the detection signal is highly correlated with the detection effect and user experience. Specifically, the higher the frequency of the sound wave, the less impact it has on human hearing, and the better the auditory experience. Conversely, the lower the frequency of the sound wave, the greater its impact on human hearing, and the worse the auditory experience. The higher the frequency of the sound wave, the smaller the effective distance for measuring direction; conversely, the lower the frequency of the sound wave, the larger the effective distance for measuring direction. In the presence of obstructions, higher frequency sound waves attenuate more severely, resulting in a smaller effective distance for measuring direction. For example, using sound waves from 14 kHz to 18 kHz to measure direction, the effective distance can reach 20 meters in an unobstructed environment, but in an obstructed environment such as when the terminal device is placed in a cloth bag, the effective distance for measuring direction is less than 2 meters.
[0059] Therefore, when using sound waves for precise location, if the sound wave frequency is low, it is easily affected by environmental noise, leading to inaccurate detection results; if the sound wave frequency is high, the effective range of the measurement orientation is limited. In other words, sound wave-based location measurement schemes struggle to balance detection accuracy and effective measurement range. Furthermore, since current sound wave-based precise location technologies use frequency-sweeping signals as detection signals, low-frequency sound waves can cause unpleasant, harsh buzzing noises from the device, resulting in a poor auditory experience for the user.
[0060] In view of this, embodiments of this application provide a positioning method that uses sound waves to determine the relative position of a device. This positioning method can be applied to a communication system comprising a detection device and a device under test. The detection device is also referred to as a first electronic device, and the device under test is also referred to as a second electronic device. Specifically, after establishing a wireless communication connection between the detection device and the device under test, the detection device can, based on this wireless communication connection, notify the device under test to send high-frequency and low-frequency sound wave signals. Subsequently, the detection device analyzes multiple factors, including the signal strength of the high-frequency sound wave signal, the signal strength of the low-frequency sound wave signal, the magnitude of high-frequency noise, and the magnitude of low-frequency noise, to determine which frequency band is more suitable for precise location, i.e., the frequency band to be used as the detection signal. In this way, the detection device can flexibly switch the frequency band of the detection signal, thereby finding a balance between detection accuracy, user auditory experience, and effective detection distance, thus improving the user experience of using the precise location function.
[0061] Figure 2 This is an architectural diagram of a detection device provided in an embodiment of this application. Figure 2 As shown, the above-mentioned detection device may include an audio processing module and a radio frequency processing unit (such as...). Figure 2 The middle part contains a Bluetooth module and a microcontroller unit (MCU).
[0062] The aforementioned radio frequency processing module is used to establish a short-range communication connection between the detection device and the device under test. This is not limited to, for example... Figure 2 The Bluetooth protocol shown above can also be implemented using other short-range wireless communication technologies such as Wi-Fi and Wi-Fi. This application does not specify which short-range wireless communication technology is used for the implementation of the RF processing module. The MCU can be used to detect the device's attitude information, such as tilt angle and rotation direction, and then output the correct direction and position of the device in subsequent precise searches, thereby improving the accuracy and efficiency of the search. It is not limited to, for example... Figure 3 The MCU shown can also be replaced by a micro-electro-mechanical system (MEMS). This application embodiment does not impose any special restrictions on which module is specifically used to implement the MCU's functions in the detection device. The audio processing module is used to process sound wave signals. This audio processing module may include a microphone, a processor, and a memory. The microphone, as a receiver of sound wave signals, can be used to receive sound wave signals emitted by the device under test. The memory is used to store instructions, audio files, etc. The processor is used to call the instructions and audio files stored in the processor, thereby causing the detection device to execute the positioning method provided in this application embodiment.
[0063] Understandable. Figure 3 The above-described audio processing unit is merely an illustrative example and does not imply that the audio processing unit of the detection device may only include one microphone, one processor, or one memory. Optionally, the audio processing unit of the detection device may also include one or more speakers for emitting sound wave signals. It is understood that when the device under test is in a low-power or sleep state, the detection device can activate or wake up the device under test by emitting sound wave signals of a specific frequency, enabling it to enter a working state and thus respond to subsequent positioning or communication requests. Not limited to the above functions, the embodiments of this application do not specifically limit the specific function of the speakers emitting sound wave signals in the audio processing module of the detection device.
[0064] Figure 3 This is an architecture diagram of a device under test provided in an embodiment of this application. For example... Figure 3 As shown, the device under test may include an audio processing module and a radio frequency processing module (such as...). Figure 3 (The middle part is the Bluetooth module).
[0065] Understandably, the RF processing module in the device under test (DUT) works in conjunction with the RF processing module in the testing device to establish a short-range communication connection between the two. Therefore, the RF processing module in the DUT should support at least one of the same short-range wireless communication technologies as the RF processing module in the testing device. For example, in Figure 2 and Figure 3 In this embodiment, the aforementioned radio frequency processing modules are all Bluetooth modules. The audio processing module in the device under test is also used to process sound wave signals. This audio processing module may include a speaker, a processor, and a memory. The speaker, as a transmitter of sound wave signals, can be used to transmit sound wave signals. In this embodiment, the speaker can be used to transmit both high-frequency and low-frequency sound wave signals.
[0066] Understandable, Figure 2 and Figure 3 In the communication system shown, the detection device can be an electronic device with display function, such as a mobile phone or tablet computer, and the target device can be any device with such... Figure 3 The illustrated electronic device has a specific architecture. The display function of the detection device is used to display the positioning result of the device, i.e., the relative position of the target device and the detection device. The relative position may include the distance and angle between the target device and the detection device. This application does not specifically limit the specific types of the detection device and the target device.
[0067] Figure 4 This is a flowchart illustrating a positioning method provided in an embodiment of this application.
[0068] S101. Establish a wireless communication connection between the testing equipment and the device under test.
[0069] Understandably, since the aforementioned detection device needs to notify the device under test to emit an acoustic signal, it needs to send a first notification to the device under test. This first notification instructs the device under test to emit an acoustic signal, thereby triggering the aforementioned positioning method. Therefore, at the beginning of executing the positioning method provided in this embodiment, the detection device needs to establish a wireless communication connection with the device under test before it can send the aforementioned first notification.
[0070] Understandably, in the environment where the aforementioned testing device is located, there may be one or more electronic devices with wireless communication connections to the testing device, but the user only needs to locate one of these electronic devices. Therefore, after establishing a wireless communication connection between the testing device and the device under test (DUT), the testing device can store the unique identification information of the DUT. In subsequent communications, the testing device can accurately identify the DUT from among the one or more devices with which it has established a wireless communication connection, and then send the aforementioned first notification to the DUT to trigger the method for locating the DUT. The unique identification information of the DUT includes, but is not limited to, the DUT's media access control address (MAC address) and identity resolving key (IRK).
[0071] S102. The testing equipment, based on the wireless communication connection, notifies the device under test to transmit high-frequency acoustic signals and low-frequency acoustic signals.
[0072] Specifically, the testing device can instruct the device under test to transmit high-frequency and low-frequency acoustic signals based on private commands in the wireless communication protocol. In other words, the first notification mentioned above can be a private command in the aforementioned wireless communication protocol.
[0073] Taking the aforementioned wireless communication connection as a Bluetooth connection as an example, the aforementioned detection device and the aforementioned device under test can define a private command data packet format in the Bluetooth protocol. For example, in the Bluetooth protocol, electronic devices can use a specific universally unique identifier (UUID) to identify the private command.
[0074] Optionally, the aforementioned private command can be used to instruct the device under test (DUT) to emit acoustic waves. This means that the DUT can be configured by default to simultaneously transmit both the high-frequency and low-frequency acoustic signals. Therefore, the private command can include an instruction message without specifying frequency band requirements.
[0075] Optionally, the aforementioned private command can be used to instruct the device under test (DUT) to transmit the aforementioned high-frequency and low-frequency acoustic signals. This means that the DUT can be set to transmit the aforementioned high-frequency or low-frequency acoustic signals by default, or even transmit acoustic signals in other frequency bands by default; when the DUT receives the aforementioned private command, it can switch to transmitting the aforementioned high-frequency and low-frequency acoustic signals. Compared to the above situation, this private command that explicitly instructs the DUT to send high-frequency and low-frequency acoustic signals can also include more data. For example, the private command also includes indication information of the frequency band of the acoustic signal transmitted by the detection device to the DUT.
[0076] Taking the MAC address as the unique identifier of the device under test (DUT) as an example, after the detection device establishes a Bluetooth connection with the DUT, when the user enables the precise search function, the detection device can send the aforementioned private command to the DUT based on the MAC address of the DUT stored in step S101, to notify the DUT to emit high-frequency and low-frequency acoustic signals. The MAC address of the DUT can be obtained by the detection device from all the MAC addresses stored in step S101 based on the user's selection of the DUT. In some embodiments, when only one electronic device in the environment of the detection device has established a Bluetooth connection with the detection device and supports the precise search function, the detection device can directly determine that the electronic device is the DUT and directly retrieve the MAC address of the electronic device from its memory.
[0077] Understandably, the aforementioned IRK can be used to generate a resolvable private address (RPA); the aforementioned detection device can also use this RPA to send the aforementioned private commands to the device under test. For the specific implementation details of this scheme, please refer to the relevant description in the scheme where the unique identifier of the device under test is the MAC address, which will not be repeated here.
[0078] S103. The testing equipment receives the high-frequency acoustic wave signal and low-frequency acoustic wave signal emitted by the device under test.
[0079] Understandably, in this article, the aforementioned high-frequency sound wave signal can refer to a sound wave signal less than 12kHz, and the aforementioned low-frequency sound wave signal can refer to a sound wave signal greater than 14kHz.
[0080] Optionally, the device under test (DUT) can emit the high-frequency and low-frequency acoustic signals using two different speakers. Alternatively, the DUT can emit the high-frequency and low-frequency acoustic signals using a single speaker. Specifically, the DUT can employ time-division multiplexing or frequency-division multiplexing to emit both frequency bands of acoustic signals using a single speaker. Therefore, it is understood that the detection device receiving the high-frequency and low-frequency acoustic signals emitted by the DUT is only used to emphasize that the DUT will emit two different frequency bands of acoustic signals when performing the positioning method provided in this application embodiment, and is not intended to indicate that the detection device can necessarily receive both the high-frequency and low-frequency acoustic signals emitted by the DUT simultaneously.
[0081] Understandably, taking high-frequency sound signals as an example, the fact that the detection device receives the high-frequency sound signal emitted by the device under test as described above does not equate to the detection device recognizing the high-frequency sound signal emitted by the device under test. When the high-frequency noise in the environment where the detection device is located increases, the detection device can still receive the high-frequency sound signal emitted by the device under test; however, the high-frequency sound signal will be submerged in the high-frequency noise, making it impossible for the detection device to recognize the high-frequency sound signal from the sound waves received by the microphone.
[0082] S104. The detection equipment defaults to using high-frequency acoustic wave signals as the detection signal.
[0083] In this embodiment, in the initial stage, the detection device can pre-determine the relative position between the detection device and the device under test based on the high-frequency acoustic signal. The aforementioned detection device using the high-frequency acoustic signal as the detection signal means that although the detection device receives acoustic signals from two frequency bands, it still calculates the relative position between the detection device and the device under test based on the received high-frequency acoustic signal. It can be understood that when executing step S104, the detection device uses the high-frequency acoustic signal as a preset detection signal frequency band, and then calculates the relative position between the detection device and the device under test based on this high-frequency acoustic signal. In step S104, the detection device essentially assigns an initial value to the variable "detection signal," but does not output the relative relationship between the detection device and the device under test calculated based on the high-frequency acoustic signal.
[0084] It is understood that the aforementioned initial stage is relative to step S106 and subsequent steps; that is, in the initial stage, the detection device has not yet determined which acoustic signal will ultimately be used as the detection signal. Optionally, the aforementioned initial stage can be a period of time after the positioning function is activated. Optionally, the aforementioned initial stage can be a period of time after receiving the aforementioned high-frequency acoustic signal and low-frequency acoustic signal. This application embodiment does not impose any special limitations on this.
[0085] S105. The detection equipment collects high-frequency noise and low-frequency noise.
[0086] The aforementioned high-frequency noise refers to the environmental noise in the frequency band where the high-frequency sound wave signal is located, and correspondingly, the aforementioned low-frequency noise refers to the environmental noise in the frequency band where the low-frequency sound wave signal is located. It can be understood that during the precise location process using sound waves, environmental noise refers to the interference from non-target sound wave signals from the surrounding environment when the detection equipment receives the sound wave signals (i.e., the aforementioned high-frequency and low-frequency sound wave signals) emitted by the device under test.
[0087] During the precise location process using sound waves, the detection device can receive all sound wave signals through a microphone, including high-frequency noise, low-frequency noise, high-frequency sound wave signals, and low-frequency sound wave signals. Taking the high-frequency band as an example, the sound wave signals received by the detection device through the microphone mainly fall into two categories: one is containing only high-frequency noise; the other is containing a superposition of high-frequency noise and high-frequency sound wave signals. When the detection device successfully identifies the high-frequency sound wave signal from the received sound wave signal, since the transmission duration of this signal is fixed, the detection device can remove the superposition of high-frequency noise and high-frequency sound wave signals from the received sound wave signal, retaining only the portion containing high-frequency noise. In a single acquisition process, high-frequency noise can be considered relatively stable and will not undergo abrupt changes. Therefore, the detection device can accurately determine the magnitude of high-frequency noise in the environment in which the detection device is located based on the retained portion containing only high-frequency noise. The magnitude of the low-frequency noise mentioned above can also be obtained in the same way; please refer to the relevant description of high-frequency noise acquisition for details, which will not be repeated here.
[0088] S106. The detection equipment determines whether there is high-frequency noise greater than the first noise threshold and low-frequency noise less than or equal to the second noise threshold.
[0089] Understandably, when the aforementioned high-frequency noise exceeds the first noise threshold, the high-frequency sound signal may be affected by the high-frequency noise, causing the detection device to be unable to identify the high-frequency sound signal from the sound signal received by the microphone. Conversely, when the high-frequency noise in the environment is less than or equal to the first noise threshold, the detection device can identify the high-frequency sound signal from the sound signal received by the microphone. Similarly, when the aforementioned low-frequency noise exceeds the second noise threshold, the detection device cannot identify the low-frequency sound signal from the sound signal received by the microphone; when the aforementioned low-frequency noise is less than or equal to the second noise threshold, the detection device can identify the low-frequency sound signal from the sound signal received by the microphone. The first noise threshold and the second noise threshold can be predetermined by the researchers and stored in the detection device.
[0090] Therefore, it can be seen that the high-frequency noise being greater than the first noise threshold and the low-frequency noise being less than or equal to the second noise threshold indicates that under the current environment, the detection device cannot identify the high-frequency sound wave signal from the received sound wave signal, but can identify the low-frequency sound wave signal.
[0091] S107. When the high-frequency noise is greater than the first noise threshold and the low-frequency noise is less than or equal to the second noise threshold, the detection device switches the low-frequency sound wave signal as the detection signal; otherwise, the detection device still uses the high-frequency sound wave signal as the detection signal.
[0092] S108. The detection equipment determines and outputs the relative position between the detection equipment and the device under test based on the above detection signal.
[0093] Specifically, when the high-frequency noise is greater than a first noise threshold and the low-frequency noise is less than or equal to a second noise threshold, the detection device outputs the relative distance between the detection device and the device under test based on the received low-frequency acoustic wave signal. Otherwise, the detection device outputs the relative distance between the detection device and the device under test based on the received high-frequency acoustic wave signal.
[0094] The following example, using high-frequency acoustic signals, illustrates how a detection device outputs the relative position between itself and the device under test based on the detection signal. For precise location functions, the relative position output by the detection device includes the distance and angle between the detection device and the device under test.
[0095] Specifically, the detection device can calculate the distance between the detection device and the device under test (DUT) using the flight time and speed of sound of the aforementioned high-frequency acoustic signal. Understandably, before the DUT transmits the high-frequency and low-frequency acoustic signals, the detection device and DUT can perform time alignment based on a Bluetooth communication connection. Specifically, after the Bluetooth connection is established, the detection device and DUT can exchange their respective local time information. Subsequently, the DUT can adjust its local clock to align with the time reference of the detection device. Based on this time alignment, the detection device can instruct the DUT to transmit the high-frequency and low-frequency acoustic signals at a specific time. For example, the detection device can send a timestamp, instructing the DUT to begin transmitting the two different frequency band acoustic signals at the time corresponding to that timestamp. Thus, the detection device can determine the transmission time of the high-frequency acoustic signal, and based on the reception time of the high-frequency acoustic signal in step S103, the detection device can calculate the flight time of the high-frequency acoustic signal, and then calculate the distance S between the detection device and the DUT using the formula S = v × t. Where v represents the speed of sound, and t represents the flight time of the aforementioned high-frequency sound wave signal.
[0096] The detection equipment can also calculate the relative position of the device using the time-of-arrival (TOA) method, which measures the time difference between the arrival of a sound wave signal at different microphones. Specifically, after the high-frequency sound wave signal is emitted from the device under test (DUT), it arrives at multiple microphones on the detection equipment sequentially. Since the distance between the microphones is known, by measuring the time difference between the arrival of the high-frequency sound wave signal at each microphone, the distance difference between the sound source and the microphone can be calculated, thereby determining the angle between the DUT and the detection equipment. It is understandable that the TOA method is applicable to detection equipment equipped with microphone arrays. It is also understandable that in the process of calculating the angle between the detection equipment and the DUT, the device's attitude information detected by the MCU in the detection equipment can serve as a reference for the positioning calculation, helping to more accurately determine the direction of the sound source. For example, when the device tilts or rotates, the attitude information can correct the relative position of the microphone array, thereby improving positioning accuracy.
[0097] Similarly, the process and implementation details of the detection device outputting the relative position between the detection device and the device under test based on low-frequency acoustic wave signals can be found in the relevant description above, and will not be repeated here. Not limited to the above methods, this application embodiment does not impose any special restrictions on how the detection device specifically determines the distance and angle between the detection device and the device under test through acoustic wave signals.
[0098] After calculating the relative position between the detection device and the device under test based on the detection signal, the detection device can output and display the relative position between the detection device and the device under test on the display screen, thereby providing an indication for the user to find the device under test.
[0099] Understandably, during the use of the aforementioned precise search function, the user continuously moves the detection device to locate the device under test. Therefore, the detection device needs to continuously update the relative position between the detection device and the device under test and output the updated result. That is, the detection device needs to repeatedly perform the steps of determining which frequency band of acoustic signal to use as the detection signal and outputting the relative position between the detection device and the device under test based on the detection signal.
[0100] In some embodiments, the detection device may repeat steps S104 to S108 every time it is necessary to output the relative position between the detection device and the device under test.
[0101] In some embodiments, the detection device can maintain the current frequency band acoustic signal as the detection signal when a detection signal is available, and then directly output the relative position between the detection device and the device under test. Specifically, the detection device can execute step S109 after step S108.
[0102] S109. The detection equipment determines whether there is a deviation between two adjacent measurements of relative position that is greater than the first deviation threshold and / or whether the noise in the frequency band of the current detection signal is higher than the noise threshold of that frequency band.
[0103] If the detection device switches to a low-frequency acoustic signal as the detection signal in step S107, then the noise in the frequency band of the current detection signal being higher than the noise threshold of that frequency band means that the low-frequency noise is higher than the second noise threshold. If the detection device does not switch to a low-frequency acoustic signal as the detection signal in step S107, but continues to use a high-frequency acoustic signal as the detection signal, then the noise in the frequency band of the current detection signal being higher than the noise threshold of that frequency band means that the high-frequency noise is higher than the first noise threshold. It is understandable that the noise in the frequency band of the current detection signal being higher than the noise threshold of that frequency band indicates that the noise in the frequency band of the detection signal in the current environment is too high. The detection device may not be able to identify the detection signal from the sound waves received by the microphone, thus preventing the detection device from outputting the relative position between the detection device and the device under test based on the detection signal.
[0104] The deviation between two adjacent measurements of the relative position is also called the relative position deviation.
[0105] Taking low-frequency noise as an example, the greater the low-frequency noise in the environment, the more difficult it is for the detection device to identify the low-frequency sound wave signal from the sound waves received by the microphone. If the detection device fails to identify the aforementioned low-frequency sound wave signal, the receiving time of the low-frequency sound wave signal will be incorrect, leading to errors in the calculated distance or angle between the detection device and the device under test. This error can be reflected by the aforementioned relative position deviation. It is understood that the aforementioned relative position deviation may include one or more of the following: distance deviation, angle deviation; therefore, correspondingly, the aforementioned first deviation threshold may also include a distance deviation threshold and / or an angle deviation threshold. The aforementioned first deviation threshold can be predetermined by the researchers and stored in the aforementioned detection device.
[0106] If the relative position deviation is greater than the first deviation threshold and / or the noise in the frequency band where the current detection signal is located is higher than the noise threshold of that frequency band, the detection device can recover the relative position between the detection device and the device under test based on the high-frequency sound wave signal. That is, if the judgment result of step S109 is yes, the detection device can continue to execute the above step S104.
[0107] If there is no situation where the relative position deviation is greater than the first deviation threshold and / or the noise in the frequency band where the current detection signal is located is higher than the noise threshold of that frequency band, the detection device can maintain the currently used detection signal and continue to execute the above step S108 until the situation where the relative position deviation is greater than the first deviation threshold or the noise in the frequency band where the current detection signal is located is higher than the noise threshold of that frequency band occurs.
[0108] Figure 5 This is a flowchart illustrating another positioning method provided in an embodiment of this application. Figure 5 Steps S201 to S203 and Figure 4 Steps S101 to S103 are the same, steps S205 and S105 are the same, and steps S208 to S209 are the same as steps S108 to S109. It can be seen that, compared to... Figure 4 The flow of the positioning method shown is as follows: Figure 5 In the described process, the detection device can default to using a low-frequency acoustic wave signal as the detection signal (i.e., step S204) to output the relative position between the detection device and the device under test. Correspondingly, in step S206, the detection device needs to determine whether there is a situation where the low-frequency noise is greater than a second noise threshold and the high-frequency noise is less than or equal to a first noise threshold. This indicates that in this situation, the detection device is less likely to identify the low-frequency acoustic wave signal but more likely to identify the high-frequency acoustic wave signal. Therefore, the detection device can execute step S207: if the low-frequency noise is greater than the second noise threshold and the high-frequency noise is less than or equal to the first noise threshold, the detection device switches to using the high-frequency acoustic wave signal as the detection signal; otherwise, the detection device continues to use the low-frequency acoustic wave signal as the detection signal. For specific implementation details, please refer to [link to relevant documentation]. Figure 4 The process of the positioning method shown will not be repeated here.
[0109] In some embodiments, the detection device can further determine the frequency band of the detection signal through multiple judgments. Figure 6 This is a flowchart illustrating another positioning method provided in an embodiment of this application.
[0110] exist Figure 6 In the middle, steps S301 to S303 and Figure 4 Steps S101 to S103 are the same, steps S305 and S105 are the same, and steps S309 to S310 are the same as steps S108 to S109. Figure 6 In the illustrated method flow, in step S304, the detection device can default to using high-frequency acoustic signals and / or low-frequency acoustic signals as the detection signals. This is understandable. Figure 6 The illustrated method primarily relies on subsequent judgment steps S306-S308 to determine the frequency band of the detection signal. However, in step S304, although the detection device has a default detection signal, it does not output the relative position between the detection device and the device under test based on this default detection signal. Therefore, in step S304, the detection device can use acoustic signals from one or more frequency bands as the detection signal. Compared to... Figure 4 and Figure 5The aforementioned positioning method flow, Figure 6 The method described herein includes two judgment steps: S306 and S307. In step S306, the detection device determines whether there is low-frequency noise greater than a second noise threshold and high-frequency noise less than or equal to a first noise threshold. In step S307, the detection device determines whether there is high-frequency noise greater than the first noise threshold and low-frequency noise less than or equal to the second noise threshold.
[0111] Understandable, in such Figure 6 In the illustrated positioning method, when the high-frequency noise is greater than a first noise threshold and the low-frequency noise is less than or equal to a second noise threshold, i.e., when the detection device determines the result in step S307 as yes, the detection device can output the relative position between the detection device and the device under test through the received low-frequency ultrasonic signal. Otherwise, the detection device outputs the relative position between the detection device and the device under test through the received high-frequency ultrasonic signal in any of the following situations: the high-frequency noise is less than or equal to the first noise threshold, the high-frequency noise is greater than the first noise threshold, and the low-frequency noise is greater than the second noise threshold.
[0112] As can be seen from the above explanation, in cases such as Figure 6 In the positioning method process shown, the detection device can preferentially apply high-frequency sound wave signals, thereby improving the user's auditory experience when using the positioning method provided in the embodiments of this application.
[0113] In some embodiments, when the detection device uses an acoustic signal of one frequency band as the detection signal, the detection device can notify the device under test to stop transmitting acoustic signals of another frequency band. For example... Figure 7 As shown, compared to Figure 6 In the illustrated method flow, after step S308, the detection device can execute step S311 to notify the device under test to stop transmitting low-frequency acoustic signals, or execute step S312 to notify the device under test to stop transmitting high-frequency acoustic signals. It is understood that the above notification can also be implemented using proprietary commands in a wireless communication protocol between the detection device and the device under test.
[0114] Understandably, if the detection device performs the above steps S311 or S312, when the detection device resumes calculating the relative position between the detection device and the device under test based on the high-frequency acoustic signal and / or low-frequency acoustic signal (i.e., when step S304 is executed after step S310), the detection device can also execute step S313 to notify the device under test to resume transmitting the switched-off high-frequency acoustic signal or low-frequency acoustic signal, so that the detection device can execute step S303 and then execute the subsequent steps.
[0115] In the above method flow, steps S311 and S312 are not limited to, for example, Figure 7 If the detection device performs step S310 as shown, it can notify the device under test to stop transmitting another frequency band of acoustic wave signal after maintaining the detection signal in use. This avoids the need to constantly notify the device under test to transmit or not transmit another frequency band of acoustic wave signal when frequently switching detection signals.
[0116] Not limited to, such as Figure 7 In the illustrated process, after determining which frequency band to use as the detection signal, the detection equipment can also... Figure 4 Step S107 or Figure 5 After step S207, the device under test is notified to stop transmitting acoustic signals in another frequency band. Correspondingly, when resetting the detection signal, the detection device also needs to execute the method shown in step S313 to notify the device under test to resume transmitting the high-frequency or low-frequency acoustic signals that were turned off.
[0117] Understandable, regardless of the above Figures 4-7 In any of the technical solutions illustrated, the device under test (DUT) involves emitting both high-frequency and low-frequency acoustic signals during the execution of the method. For the detection device, when noise in one frequency band is excessive, it can automatically switch to using an acoustic signal from another frequency band as the detection signal, thereby outputting the relative position between the detection device and the DUT, achieving positioning and precise location. Specifically, when the high-frequency noise is greater than a first noise threshold and the low-frequency noise is less than or equal to a second noise threshold, the detection device determines and outputs the relative position between the detection device and the DUT using the received low-frequency acoustic signal; when the low-frequency noise is greater than the second noise threshold and the high-frequency noise is less than or equal to the first noise threshold, the detection device determines and outputs the relative position between the detection device and the DUT using the received high-frequency acoustic signal; when the low-frequency noise is greater than the second noise threshold and the high-frequency noise is greater than the first noise threshold, the detection device does not determine and outputs the relative position between the detection device and the DUT.
[0118] Therefore, it is possible to record and observe whether the device under test (DUT) simultaneously emits low-frequency and high-frequency sound wave signals using professional recording equipment. When the DUT emits two different frequency bands of sound wave signals, the user can sequentially generate full-frequency noise, high-frequency noise, and low-frequency noise around the device. Understandably, the magnitude of the full-frequency noise can be gradually increased. When the full-frequency noise reaches a certain threshold (such as a third noise threshold), the detection device will be unable to identify the sound wave signals of each frequency band, and thus will be unable to output the relative position between the detection device and the DUT. Subsequently, the user can adjust the high-frequency and low-frequency noise to the aforementioned third noise threshold. Since low-frequency noise only interferes with the identification of low-frequency sound wave signals, and high-frequency noise interferes with the identification of high-frequency sound wave signals, if the detection device can output the relative position between the detection device and the DUT when both high-frequency and low-frequency noise are at the third noise threshold, it indicates that the detection device is performing a detection signal based on switching between high-frequency and / or low-frequency noise during the positioning process. Furthermore, users can add a verification device next to the testing device. This verification device is used to check whether the high-frequency acoustic wave signal and / or low-frequency acoustic wave signal emitted by the device under test can be received at the location of the testing device, thereby further clarifying that the testing device outputs the relative position between the testing device and the device under test through the aforementioned high-frequency acoustic wave signal and / or low-frequency acoustic wave signal.
[0119] In the above Figures 4-7 In the method flow, the detection device can determine the frequency band of the received acoustic signal by using high-frequency and low-frequency noise to output the relative position between the detection device and the device under test, and switch the detection signal frequency band accordingly when needed. Not limited to the above judgment criteria, the detection device can also use other criteria (such as the signal strength of the acoustic wave) to determine which frequency band of the received acoustic signal to determine and output the relative position between the detection device and the device under test. The signal strength of both the high-frequency and low-frequency acoustic signals can be represented by the received signal strength indication (RSSI). Not limited to RSSI, other indicators that can be used to measure the intensity of acoustic signals can be used here, and this application embodiment does not impose any special limitations on this.
[0120] In some embodiments, when the signal strength of the high-frequency acoustic signal is less than a first signal strength threshold and the signal strength of the low-frequency acoustic signal is greater than or equal to a second signal strength threshold, the detection device determines and outputs the relative position between the detection device and the device under test based on the received low-frequency acoustic signal; when the signal strength of the high-frequency acoustic signal is greater than or equal to the first signal strength threshold and the signal strength of the low-frequency acoustic signal is less than the second signal strength threshold, the detection device determines and outputs the relative position between the detection device and the device under test based on the received high-frequency acoustic signal.
[0121] In some embodiments, when the signal strength of the high-frequency acoustic signal is less than a first signal strength threshold and the low-frequency noise is less than or equal to a second noise threshold, the detection device determines and outputs the relative position between the detection device and the device under test based on the received low-frequency acoustic signal; when the signal strength of the low-frequency acoustic signal is less than the second signal strength threshold and the high-frequency noise is less than or equal to the first noise threshold, the detection device determines and outputs the relative position between the detection device and the device under test based on the received high-frequency acoustic signal.
[0122] In some embodiments, when the high-frequency noise is greater than a first noise threshold and the low-frequency acoustic signal strength is greater than or equal to a second signal strength threshold, the detection device determines and outputs the relative position between the detection device and the device under test based on the received low-frequency acoustic signal; when the low-frequency noise is greater than the second noise threshold and the high-frequency acoustic signal strength is greater than or equal to the first signal strength threshold, the detection device determines and outputs the relative position between the detection device and the device under test based on the received high-frequency acoustic signal.
[0123] Understandably, if in the above embodiments, different standards are used to determine which frequency band of acoustic signal is received to determine and output the relative position between the detection device and the device under test, then in Figures 4-7 In the illustrated process, steps S106, S206, S306, and S307 all require corresponding modifications. Subsequently, the detection device can switch the corresponding detection signals according to the above logic. For example, Figure 4 Step S106 can be modified to have the detection device determine whether there is a situation where the signal strength of the high-frequency sound wave signal is less than the first signal strength threshold and the low-frequency noise is less than or equal to the second noise threshold. If such a situation exists, in step S107, the detection device switches to the low-frequency sound wave signal as the detection signal; if not, in step S107, the detection device still uses the high-frequency sound wave signal as the detection signal. Modifications to other embodiments can be found in the description and examples above, and will not be repeated here.
[0124] Understandably, in existing solutions, detection equipment typically uses a single low-frequency sweep signal during detection. This signal has a distinct peak, allowing the detection equipment to easily identify noise in the environment. However, this sweep signal may interfere with other electronic devices, affecting the user's auditory experience and causing them to hear harsh noises.
[0125] In the above scheme, since the device under test (DUT) can simultaneously emit both high-frequency and low-frequency sound signals, to alleviate the aforementioned problems, the low-frequency sound signal emitted by the DUT can be replaced with a single-frequency ringtone signal instead of the aforementioned low-frequency swept-frequency signal. Understandably, this single-frequency ringtone signal has no obvious peak, reducing interference to other devices and preventing users from hearing unpleasant buzzing sounds, thus improving the user's auditory experience. Furthermore, the single-frequency ringtone signal can be designed to include features of the swept-frequency signal for easier identification by the testing device. For example, a signal rise phase can be designed between two single-frequency signals, thus preserving the identification characteristics of the swept-frequency signal while avoiding its potential negative impacts. In this way, the DUT can provide a more user-friendly auditory experience without sacrificing testing accuracy.
[0126] Figure 8 This is a schematic diagram of the structure of a detection device provided in an embodiment of this application.
[0127] like Figure 8 As shown, the detection device may include components such as a processor 211, a memory 212, a wireless communication processing module 213, a power switch 214, a display screen 215, an audio module 216, and a microphone. The components in the detection device are connected to each other via a bus and communicate based on the bus.
[0128] Processor 211 may include one or more processing units, such as: application processor (AP), modem processor, graphics processing unit (GPU), image signal processor (ISP), controller, video codec, digital signal processor (DSP), baseband processor, and / or neural network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors. The controller can generate operation control signals based on instruction opcodes and timing signals to control instruction fetching and execution. In this embodiment, the processor 211 may be... Figure 2 The MCU shown.
[0129] Memory 212 is coupled to processor 211 and is used to store various software programs and / or multiple sets of instructions. Memory 212 can be used to store computer executable program code, which includes instructions. Processor 211 executes various functional applications and data processing of the electronic device by running the instructions stored in memory 212. Memory may also be provided in processor 211 for storing instructions and data.
[0130] The memory 212 may include one or more random access memory (RAM) and one or more non-volatile memory (NVM). The RAM can be directly read and written by the processor 211. The RAM can be used to store executable programs (e.g., machine instructions) of the operating system or other running programs, as well as user and application data. The NVM can also store executable programs and user and application data. Executable programs, i.e., user data, stored in the NVM can be pre-loaded into the RAM for direct reading and writing by the processor 211.
[0131] Executable program code and data (including but not limited to various voice data) used to implement the positioning method provided in the embodiments of this application can be stored in non-volatile memory. During the implementation of the above positioning method, the electronic device can load the non-volatile memory executable program code and user data into random access memory, thereby enabling the detection device to automatically switch detection signals between two frequency bands of acoustic signals when the environment changes, thus providing users with a stable, usable, and accurate search function, and improving the user experience.
[0132] The wireless communication processing module 213 can provide wireless communication solutions including WLAN, such as Wi-Fi, Bluetooth communication, ZigBee communication, NFC communication, infrared communication, and UWB communication.
[0133] In this embodiment of the application, the detection device can establish a wireless communication connection with the device under test through the wireless communication processing module 213, and then the detection device can notify the device under test to start transmitting two different frequency bands of sound wave signals or stop transmitting one of the frequency bands of sound wave signals.
[0134] The power switch 214 can be used to control the power supply to electronic devices, thereby supplying power to the processor 211, memory 212, wireless communication processing module 213, display screen 215, audio module 216, microphone, etc.
[0135] Display screen 215 can be used to display the interface of an application. Display screen 215 includes a display panel. A touch sensor can be installed in display screen 215. The touch sensor is used to detect touch operations applied to or near it. The touch sensor can transmit the detected touch operation to the application processor to determine the type of touch event. Then, the electronic device can provide visual output related to the touch operation through display screen 215. The electronic device can implement display functions through GPU, display screen 215, touch sensor, and application processor, etc. In the embodiments of this application, the detection device can use the display functions provided by GPU, display screen 215, and application processor, etc., to display the precise search results to the user, that is, determine and output the relative position between the detection device and the device under test, thereby providing an indication for the user to find the device under test (i.e., the target device).
[0136] The audio module 216 can be used to convert digital audio signals into analog audio signals for output, and can also be used to convert analog audio input into digital audio signals. In this embodiment, the audio module 216 further includes a microphone for converting sound signals into electrical signals. Specifically, the detection device receives high-frequency and low-frequency sound wave signals emitted by the device under test through the microphone. In some embodiments, the detection device may also include a speaker for converting the audio signals transmitted by the audio module into sound signals. The detection device can realize the sound wave emission function through the audio module 216, speaker, etc., and the sound wave emission function can be used to assist in locating the device under test.
[0137] Figure 9 This is a schematic diagram of the structure of a device under test (DUT) provided in an embodiment of this application. Compared to a testing device, the DUT may include fewer hardware components. For example... Figure 9 As shown, the device under test may include components such as a processor 311, a memory 312, a wireless communication processing module 313, a power switch 314, an audio module 315, and a speaker. The components in the device under test are connected to each other via a bus and communicate based on the bus.
[0138] The processor 311 may include one or more processing units, wherein different processing units may be independent devices or integrated into one or more processors. The controller may generate operation control signals according to the instruction opcode and timing signals to control the instruction fetching and execution.
[0139] Memory 312 is coupled to processor 311 and is used to store various software programs and / or multiple sets of instructions. Memory 312 can be used to store computer executable program code, which includes instructions. Processor 311 executes various functional applications and data processing of the electronic device by running the instructions stored in memory 312. Memory may also be provided in processor 311 for storing instructions and data.
[0140] The memory 312 may include one or more random access memory (RAM) and one or more non-volatile memory (NVM). The RAM can be directly read and written by the processor 311. The RAM can be used to store executable programs (e.g., machine instructions) of the operating system or other running programs, as well as user and application data. The NVM can also store executable programs and user and application data. Executable programs, i.e., user data, stored in the NVM can be pre-loaded into the RAM for direct read and write operations by the processor 311.
[0141] The executable program code and data (including but not limited to various voice data) used to implement the positioning method provided in the embodiments of this application can be stored in non-volatile memory. During the implementation of the above positioning method, the device under test can load the executable program code and user data from the non-volatile memory into random access memory, so that the device under test can transmit high-frequency sound wave signals and low-frequency sound wave signals after receiving a notification of a private command.
[0142] The wireless communication processing module 313 can provide wireless communication solutions including WLAN (such as Wi-Fi), Bluetooth communication, ZigBee communication, NFC communication, infrared communication, and UWB communication. In this embodiment, the wireless communication processing module 313 is used to cooperate with the wireless communication processing module 213 in the testing device, and both the wireless communication processing module 313 and the wireless communication processing module 213 support at least one of the same wireless communication technologies. The device under test receives notifications sent by the testing device through the wireless communication processing module 313.
[0143] The power switch 314 can be used to control the power supply to electronic devices, thereby supplying power to the processor 311, memory 312, wireless communication processing module 313, audio module 315, speaker, etc.
[0144] The audio module 315 can be used to convert digital audio signals into analog audio signals for output, and can also be used to convert analog audio input into digital audio signals. The speaker can be used to convert the audio signals transmitted by the audio module into sound signals. In this embodiment, the detection device can realize sound wave transmission function through the audio module 315, speaker, etc., so that the device under test can emit high-frequency sound wave signals and low-frequency sound wave signals.
[0145] It is understood that the structures illustrated in the embodiments of this application do not constitute a specific limitation on the electronic device (including the detection device and the device under test). In other embodiments of this application, the electronic device may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. Components may be implemented in hardware, software, or a combination of software and hardware.
[0146] Those skilled in the art will recognize that the functions described in the embodiments of this application in one or more of the above examples can be implemented using hardware, software, firmware, or any combination thereof. When implemented using software, these functions can be stored in a computer-readable medium or transmitted as one or more instructions or code on a computer-readable medium. Computer-readable media include computer storage media and communication media, wherein communication media include any medium that facilitates the transmission of a computer program from one place to another. Storage media can be any available medium accessible to a general-purpose or special-purpose computer. Embodiments of this application also provide a computer program product, including a computer program that, when run on a processor, implements the steps in the various method embodiments described above.
[0147] The above detailed embodiments further illustrate the purpose, technical solution, and beneficial effects of the embodiments of this application. It should be understood that the above are merely specific embodiments of the embodiments of this application and are not intended to limit the protection scope of the embodiments of this application. Any modifications, equivalent substitutions, improvements, etc., made on the basis of the technical solutions of the embodiments of this application should be included within the protection scope of the embodiments of this application.
Claims
1. A positioning method, characterized in that, A first electronic device applied in a communication system, the communication system further comprising a second electronic device, the method comprising: A wireless communication connection is established between the first electronic device and the second electronic device; The first electronic device notifies the second electronic device to transmit high-frequency sound wave signals and low-frequency sound wave signals based on the wireless communication connection; The first electronic device receives the high-frequency acoustic signal and the low-frequency acoustic signal emitted by the second electronic device; When the high-frequency noise is greater than a first noise threshold and the low-frequency noise is less than or equal to a second noise threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device by receiving the low-frequency sound wave signal. When the low-frequency noise is greater than the second noise threshold and the high-frequency noise is less than or equal to the first noise threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device by receiving the high-frequency sound wave signal. When the low-frequency noise is greater than the second noise threshold and the high-frequency noise is greater than the first noise threshold, the first electronic device does not output the relative position between the first electronic device and the second electronic device.
2. The method according to claim 1, characterized in that, The method further includes: When the signal strength of the high-frequency sound wave signal is less than a first signal strength threshold and the signal strength of the low-frequency sound wave signal is greater than or equal to a second signal strength threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device by receiving the low-frequency sound wave signal. When the signal strength of the high-frequency acoustic signal is greater than or equal to the first signal strength threshold and the signal strength of the low-frequency acoustic signal is less than the second signal strength threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received high-frequency acoustic signal.
3. The method according to claim 2, characterized in that, The method further includes: When the signal strength of the high-frequency sound wave signal is less than the first signal strength threshold and the low-frequency noise is less than or equal to the second noise threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device by receiving the low-frequency sound wave signal. When the signal strength of the low-frequency acoustic signal is less than the second signal strength threshold and the high-frequency noise is less than or equal to the first noise threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received high-frequency acoustic signal.
4. The method according to claim 3, characterized in that, The method further includes: When the high-frequency noise is greater than the first noise threshold and the low-frequency sound wave signal strength is greater than or equal to the second signal strength threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device by receiving the low-frequency sound wave signal. When the low-frequency noise is greater than the second noise threshold and the high-frequency sound wave signal strength is greater than or equal to the first signal strength threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received high-frequency sound wave signal.
5. The method according to claim 4, characterized in that, The method further includes: In the initial stage, the first electronic device first determines the relative position between the first electronic device and the second electronic device based on the high-frequency sound wave signal; After the initial phase, the first electronic device switches to determining and outputting the relative position between the first electronic device and the second electronic device based on the low-frequency acoustic signal. After the switch, the first electronic device maintains the relative position between the first electronic device and the second electronic device determined by the low-frequency sound wave signal until the deviation between two adjacent measurements of the relative position is greater than a first deviation threshold or the low-frequency noise is greater than a second noise threshold.
6. The method according to claim 5, characterized in that, The method further includes: If the deviation between two adjacent measurements of the relative position is greater than a first deviation threshold or the low-frequency noise is greater than a second noise threshold, the first electronic device recovers and outputs the relative position between the first electronic device and the second electronic device based on the high-frequency sound wave signal.
7. The method according to claim 4, characterized in that, The method further includes: In the initial stage, the first electronic device determines the relative position between itself and the second electronic device based on the low-frequency sound wave signal; After the initial phase, the first electronic device switches to determining and outputting the relative position between the first electronic device and the second electronic device based on the high-frequency acoustic signal. After the switch, the first electronic device continues to determine and output the relative position between the first electronic device and the second electronic device through the high-frequency acoustic signal until the deviation between two adjacent measurements of the relative position is greater than a first deviation threshold or the high-frequency noise is greater than the first noise threshold.
8. The method according to claim 7, characterized in that, The method further includes: If the deviation between two adjacent measurements of the relative position is greater than a first deviation threshold or the high-frequency noise is greater than the first noise threshold, the first electronic device recovers and outputs the relative position between the first electronic device and the second electronic device based on the low-frequency sound wave signal.
9. The method according to any one of claims 1-8, characterized in that, When the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device through the received low-frequency acoustic signal, the method further includes: The first electronic device notifies the second electronic device to stop transmitting the high-frequency sound wave signal.
10. The method according to claim 9, characterized in that, Before the first electronic device recovers and determines and outputs the relative position between the first electronic device and the second electronic device through the received high-frequency acoustic signal, the method further includes: The first electronic device notifies the second electronic device to resume transmitting the high-frequency acoustic signal.
11. The method according to any one of claims 1-10, characterized in that, When the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device through the received high-frequency acoustic signal, the method further includes: The first electronic device notifies the second electronic device to stop transmitting the low-frequency sound wave signal.
12. The method according to claim 11, characterized in that, Before the first electronic device recovers and determines and outputs the relative position between the first electronic device and the second electronic device via the received low-frequency acoustic signal, the method further includes: The first electronic device notifies the second electronic device to resume transmitting the low-frequency sound wave signal.
13. The method according to any one of claims 1-12, characterized in that, The method further includes: When the high-frequency noise is greater than the first noise threshold and the low-frequency noise is less than or equal to the second noise threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device by receiving the low-frequency sound wave signal. The first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received high-frequency acoustic signal under the following conditions: the high-frequency noise is less than or equal to the first noise threshold, the high-frequency noise is greater than the first noise threshold, and the low-frequency noise is greater than the second noise threshold.
14. The method according to any one of claims 1-13, characterized in that, The method further includes: When the signal strength of the high-frequency sound wave signal is less than a first signal strength threshold and the signal strength of the low-frequency sound wave signal is greater than or equal to a second signal strength threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device by receiving the low-frequency sound wave signal. The first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received high-frequency acoustic signal in any of the following situations: the signal strength of the high-frequency acoustic signal is greater than or equal to the first signal strength threshold, the signal strength of the high-frequency acoustic signal is less than the first signal strength threshold, and the signal strength of the low-frequency acoustic signal is less than the second signal strength threshold.
15. The method according to any one of claims 1-14, characterized in that, The method further includes: When the signal strength of the high-frequency sound wave signal is less than the first signal strength threshold and the low-frequency noise is less than or equal to the second noise threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device by receiving the low-frequency sound wave signal. The first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received high-frequency acoustic signal in any of the following situations: the signal strength of the high-frequency acoustic signal is greater than or equal to the first signal strength threshold, the signal strength of the high-frequency acoustic signal is less than the first signal strength threshold, and the low-frequency noise is greater than the second noise threshold.
16. The method according to any one of claims 1-15, characterized in that, The method further includes: When the high-frequency noise is greater than the first noise threshold and the low-frequency sound wave signal strength is greater than or equal to the second signal strength threshold, the first electronic device determines and outputs the relative position between the first electronic device and the second electronic device by receiving the low-frequency sound wave signal. The first electronic device determines and outputs the relative position between the first electronic device and the second electronic device based on the received high-frequency acoustic signal in any of the following situations: the high-frequency noise is less than or equal to the first noise threshold, the high-frequency noise is greater than or equal to the first noise threshold, and the intensity of the fixed-frequency acoustic signal is less than the second signal intensity threshold.
17. An electronic device, characterized in that, The method includes one or more processors and one or more memories; wherein the one or more memories are coupled to the one or more processors, and the one or more memories are used to store computer program code, the computer program code including computer instructions, which, when executed by the one or more processors, cause the method of any one of claims 1-16 to be performed.
18. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is run on an electronic device, it causes the method as described in any one of claims 1-16 to be performed.
19. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the method as described in any one of claims 1-16.