Scene recognition method, electronic device, storage medium and chip

By calculating the amplitude difference and phase difference of the antenna reflection coefficient, combined with the preset threshold range and mapping relationship, the problem of low scene detection accuracy in the existing technology is solved, and accurate identification of complex scenes and differentiation of medium types are achieved.

CN116743912BActive Publication Date: 2025-09-12HUAWEI TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210200012.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-01
Publication Date
2025-09-12
Estimated Expiration
2042-03-01

AI Technical Summary

Technical Problem

In the prior art, when the scene in which the electronic device is located is detected by the amplitude in the antenna parameters, the accuracy is low and complex scenes cannot be effectively identified.

Method used

By obtaining the reflection coefficient of the first antenna at the first operating frequency, calculating the amplitude difference and phase difference, and determining the medium type or antenna status based on the preset threshold range and mapping relationship, the accuracy of scene detection is improved.

Benefits of technology

It achieves accurate detection of complex scenes, can identify the medium type and antenna disconnection status, and improves the accuracy of detection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116743912B_ABST
    Figure CN116743912B_ABST
Patent Text Reader

Abstract

An embodiment of the present application provides a scene recognition method and electronic device, relating to the field of terminal technology. The method includes: utilizing the amplitude difference and phase difference of the antenna's reflection coefficient relative to a preset reflection coefficient to distinguish the medium type, or whether the antenna is disconnected. This method can distinguish complex scenes and improve the accuracy of scene detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the technical field of terminal devices, and in particular to a scene recognition method and electronic device. Background Art

[0002] With the development of communication technology, the functions of electronic devices are becoming more and more abundant.

[0003] The electronic device can detect the medium close to the electronic device. When determining the medium type of the medium near the mobile phone, it is mainly based on the amplitude in the antenna parameter.

[0004] However, when the scene where the electronic device is located is detected by the amplitude in the antenna parameters, the accuracy is low and it is impossible to detect complex scenes. Summary of the Invention

[0005] To address the above technical issues, this application provides a scene recognition method and electronic device. In this method, the amplitude difference and phase difference between two reflection coefficients can be used to distinguish between different media types or whether the antenna is disconnected. This method can distinguish complex scenes and improve the accuracy of scene detection.

[0006] In a first aspect, an embodiment of the present application provides a scene recognition method, which is applied to an electronic device, wherein the electronic device includes a first antenna, and the method includes: obtaining at least one first reflection coefficient of the first antenna at a first operating frequency, wherein the first reflection coefficient includes an amplitude and a phase; determining a first amplitude difference and a first phase difference based on the first reflection coefficient and a first preset reflection coefficient; determining a first medium type of the first medium based on a first amplitude threshold range of the first amplitude difference and a first phase threshold range of the first phase difference, or determining whether the first antenna is in a disconnected state.

[0007] For example, the first preset reflection coefficient is also called a “reference point”. The first reflection coefficient is also called a “sampling point”. Similarly, the second reflection coefficient and the third reflection coefficient described below can also be called “sampling points”.

[0008] The reference point may be a reflection coefficient of the first antenna at a certain moment, a certain state (eg, a stable state such as an FS state or a holding state), or at a certain operating frequency.

[0009] The first reflection coefficient and the reference point are reflection coefficients collected at the same operating frequency of the first antenna.

[0010] For example, the reflection coefficient (S11) is a complex number, which may include a real part and an imaginary part. The electronic device may obtain the amplitude and phase of the reflection coefficient by performing operations on the real part and the imaginary part.

[0011] When calculating the difference between two reflection coefficients, the electronic device calculates the difference between the real parts of the two reflection coefficients and the imaginary parts of the two reflection coefficients. Therefore, the difference between the two reflection coefficients is also a complex number, including real and imaginary parts. The electronic device can then determine a first amplitude difference (also called "amplitude change") and a first phase difference (also called "phase change") based on the real and imaginary parts of the difference between the two reflection coefficients.

[0012] Exemplarily, the amplitude-phase change includes the amplitude change and the phase change.

[0013] Exemplarily, the amplitude-phase threshold range may include the amplitude threshold range and the phase threshold range.

[0014] Exemplarily, the electronic device may be configured with a mapping relationship between the medium type and the amplitude threshold range and the phase threshold range, and a mapping relationship between the antenna disconnection state and the amplitude threshold range and the phase threshold range.

[0015] When detecting a medium type or an antenna disconnect scenario, the electronic device can determine the first amplitude threshold range within which the first amplitude difference falls, and the first phase threshold range within which the first phase difference falls, based on the two mapping relationships described above. Furthermore, the electronic device can determine the target medium type or antenna disconnect status corresponding to both the first amplitude threshold range and the first phase threshold range in the two mapping relationships. This can thereby determine the target medium type or whether the first antenna of the electronic device is disconnected.

[0016] Optionally, the type of medium near the phone can be determined, and "near" can represent a preset distance range. For example, the preset distance range is 0 mm to 10 mm. This application does not limit the specific distance threshold of the preset distance range, and it can be flexibly configured according to actual needs.

[0017] Optionally, when performing the above scene detection, the electronic device may determine the scene in which the electronic device is located based on a first reflection coefficient, an amplitude change, and a phase change relative to a reference point.

[0018] Optionally, when performing the above scene detection, the electronic device may determine the scene in which the electronic device is located based on the amplitude change and phase change of the multiple first reflection coefficients relative to a reference point.

[0019] The multiple first reflection coefficients are multiple reflection coefficients of the first antenna collected by the mobile phone (also called "multiple sampling points").

[0020] Similar to the principle of scene detection based on a first reflection coefficient, the mobile phone can determine candidate scenes based on the amplitude and phase changes of multiple sampling points relative to a reference point. This generates multiple candidate scenes in chronological order of sampling, and based on these multiple candidate scenes, the target scene of the electronic device can be determined.

[0021] For example, the candidate scene that appears first may be used as the target scene.

[0022] For example, other candidate scenes that are exclusive with the detected candidate scene (eg, the candidate scene determined by using the first sampling point and the reference point) may be filtered out, and at least two candidate scenes that are compatible with the detected scene may be used as target scenes.

[0023] Exemplarily, the electronic device is a mobile phone.

[0024] In an embodiment of the present application, when the medium is near the mobile phone or the mobile phone antenna is disconnected, the reflection coefficient of the mobile phone antenna is monotonic in terms of amplitude and phase changes relative to the preset reflection coefficient. The mobile phone can then use the amplitude and phase threshold range of the amplitude and phase changes to distinguish different media types or antenna disconnection scenarios. It can use phase changes to distinguish different scenarios with similar amplitude changes, thereby improving the accuracy of scene detection and enabling detection of complex scenes.

[0025] According to the first aspect, the method further includes: determining a first distance range matching the first amplitude difference as the distance range between the first medium and the electronic device based on a first mapping relationship between distance ranges and amplitude threshold ranges.

[0026] Exemplarily, the distance range in the first mapping relationship is the distance range between the medium and the first antenna.

[0027] In an embodiment of the present application, the distance range between the first antenna of the mobile phone and the medium can be determined based on the amplitude change of the sampling point relative to the reference point and the amplitude threshold range in which it is located, so that the mobile phone can be controlled according to the distance range and the type of the first medium, including but not limited to reducing the transmission power of the first antenna, prompting to wear a mobile phone case, prompting to charge, etc.

[0028] According to the first aspect, or any implementation of the first aspect above, the method further includes: determining a second amplitude threshold range that matches the first amplitude difference and a second phase threshold range that matches the first phase difference based on a second mapping relationship between the relative position and the amplitude-phase threshold range, wherein the amplitude-phase threshold range includes an amplitude threshold range and a phase threshold range; based on the second mapping relationship, determining the target relative position that matches both the second amplitude threshold range and the second phase threshold range as the relative position relationship between the first medium and the electronic device.

[0029] The relative position is the relative position between the medium and the electronic device.

[0030] For example, a mobile phone may include multiple surfaces, and the relative position between the medium and the mobile phone may include but is not limited to which surface of the mobile phone the medium is located near. The explanation of "near" can refer to the first aspect above.

[0031] For example, a mobile phone can detect the relative position of a medium within 10 mm of the mobile phone.

[0032] For example, the above relative positions may include but are not limited to: the medium faces within 10 mm of the front of the mobile phone, the medium faces within 10 mm of the back of the mobile phone, the medium faces within 10 mm of the side of the mobile phone, etc.

[0033] Combined with the embodiment of determining the distance range between the medium and the mobile phone, this embodiment can not only determine the relative position between the medium and the mobile phone, but also determine the distance range between the medium and the mobile phone, for example, within 5 mm.

[0034] In an embodiment of the present application, the relative position between the medium and the mobile phone can be determined based on the amplitude change of the sampling point relative to the reference point, and the threshold range of the phase change, thereby enabling the detection of the orientation between the medium and the mobile phone.

[0035] According to the first aspect, or any implementation manner of the first aspect above, the number of the at least one first reflection coefficient is multiple; after the target relative position that matches both the second amplitude threshold range and the second phase threshold range is determined as the relative position relationship between the first medium and the electronic device based on the second mapping relationship, the method further includes: detecting that the target relative positions corresponding to multiple first reflection coefficients are the same, and determining that the first medium is approaching or moving away from the electronic device from the target relative position.

[0036] Exemplarily, the multiple first reflection coefficients here are at least two reflection coefficients.

[0037] In an embodiment of the present application, the relative position between the medium and the mobile phone corresponding to each sampling point can be determined based on the amplitude change of each sampling point relative to a reference point, as well as the threshold range of the phase change. If the relative positions corresponding to at least two consecutive sampling points within a period of time are the same, it can be determined that the medium is approaching or moving away from the mobile phone from this relative position, and multiple sampling points can be used to detect dynamic scenes.

[0038] According to the first aspect, or any implementation manner of the first aspect above, the method further includes: the method further includes: obtaining multiple second reflection coefficients of the first antenna at the first operating frequency, wherein each second reflection coefficient includes an amplitude and a phase; determining multiple second amplitude differences and multiple second phase differences based on each second reflection coefficient and a second preset reflection coefficient; detecting that the changing trends of the multiple second amplitude differences are the same, and / or detecting that the changing trends of the multiple second phase differences are the same, determining that there is a medium close to the electronic device.

[0039] The second preset reflection coefficient of this embodiment may be the same as or different from the first preset reflection coefficient.

[0040] The second preset reflection coefficient is also a reflection coefficient of the first antenna at the first operating frequency.

[0041] In addition, the second preset reflection coefficient and the second reflection coefficient are both at the first operating frequency.

[0042] The multiple second reflection coefficients may be the same as or different from the first reflection coefficient, and this application does not impose any limitation on this.

[0043] The principles of the specific steps of determining the second amplitude difference and the second phase difference in this embodiment are similar to those in the first aspect and will not be repeated here.

[0044] When a medium approaches the phone from a distance away from the phone antenna (for example, the distance between the medium and the antenna exceeds 10mm), the reflection coefficient of the antenna changes slightly, but the short-term change trend of the reflection coefficient is stable. In this case, the phone of this embodiment can use the change trend of the amplitude and phase difference values ​​(including amplitude difference and / or phase difference) of multiple sampling points relative to the reference point to determine whether there is a medium approaching the phone. If the change trend of the amplitude and phase difference values ​​is the same, it means that there is a medium approaching the phone. The phone of the embodiment of the present application has a high recognition accuracy when used to detect such a scenario where the medium is weakly approaching.

[0045] According to the first aspect, or any implementation manner of the first aspect above, the detecting that the changing trends of the multiple second amplitude differences are the same, and / or the detecting that the changing trends of the multiple second phase differences are the same, and determining that there is a medium approaching the electronic device, includes: detecting that the multiple second amplitude differences are all greater than a first amplitude threshold, and the multiple second phase differences are all greater than a first phase threshold, and determining that there is a medium approaching the electronic device.

[0046] In an embodiment of the present application, if the amplitude change of each sampling point relative to a reference point is greater than a certain amplitude threshold, and the phase change is greater than a certain phase threshold, then it can be indicated that the amplitude and phase change trends of the multiple second reflection coefficients relative to the second preset reflection coefficient are the same, thereby determining that a medium is approaching the mobile phone. The approach of the medium can be identified when the medium is far away from the mobile phone. For example, when a human body is detected approaching the mobile phone, power backoff can be performed in a timely manner when it is determined that the transmit power of the first antenna needs to be reduced.

[0047] According to the first aspect, or any implementation manner of the first aspect above, the detection that the multiple second amplitude difference values ​​have the same changing trend, and / or the detection that the multiple second phase difference values ​​have the same changing trend, determines that there is a medium approaching the electronic device, including: detecting the multiple second amplitude difference values, which continuously increase or continuously decrease in the sampling time sequence, and determining that the multiple second amplitude difference values ​​have the same changing trend; detecting the multiple second phase difference values, which continuously increase or continuously decrease in the sampling time sequence, and determining that the multiple second phase difference values ​​have the same changing trend; detecting the multiple second amplitude difference values, which have the same changing trend, and detecting the multiple second phase difference values, which have the same changing trend, determines that there is a medium approaching the electronic device.

[0048] In an embodiment of the present application, when a mobile phone detects that the amplitude and phase changes at multiple sampling points relative to a reference point continuously decrease or increase over time, it can determine that the amplitude and phase changes at the multiple sampling points relative to the reference point have the same changing trend, thereby determining that a medium is approaching the mobile phone. This allows the mobile phone to detect the medium's approach when the medium is relatively far away. For example, when a person is detected approaching the mobile phone, power backoff can be performed in a timely manner when it is determined that the transmit power of the first antenna needs to be reduced.

[0049] According to the first aspect, or any implementation of the first aspect above, the detecting that the changing trends of the multiple second amplitude differences are the same, and / or the detecting that the changing trends of the multiple second phase differences are the same, determines that there is a medium approaching the electronic device, including: determining the derivatives of the multiple second amplitude differences with respect to the sampling times of the multiple second reflection coefficients; and detecting that the derivative is greater than zero, determines that there is a medium approaching the electronic device.

[0050] For example, when a medium is close to a mobile phone, the reflection coefficient of the mobile phone antenna (also known as the sampling point) may change over time. Therefore, the sampled reflection coefficient can be considered a function that changes with time t. The amplitude change at the sampling point relative to the reference point (also known as the "relative amplitude" or amplitude difference) is also a function that changes with time t.

[0051] When the medium approaches the phone from a distance, the antenna's reflection coefficient changes slightly, and so does the relative amplitude. However, the time derivative of the relative amplitude (i.e., |Δ|), d|Δ| / dt, changes significantly over time. The phone can then determine that the medium is approaching the phone's antenna by detecting that d|Δ| / dt > 0 at a certain moment t. Alternatively, if d|Δ| / dt < 0, the medium is moving away from the phone's antenna. This allows the identification of the medium's approach and retreat even when the medium is at a considerable distance from the phone.

[0052] According to the first aspect, or any implementation manner of the first aspect above, the method further includes: obtaining multiple third reflection coefficients of the first antenna at the first operating frequency, wherein each of the third reflection coefficients includes an amplitude and a phase; determining multiple third amplitude differences and multiple third phase differences based on each of the third reflection coefficients and a third preset reflection coefficient; detecting that the fluctuation information of the multiple third amplitude differences and the fluctuation information of the multiple third phase differences meet preset conditions, and determining that there is a medium close to the electronic device.

[0053] The third preset reflection coefficient of this embodiment may be the same as or different from the first preset reflection coefficient.

[0054] The multiple third reflection coefficients may be the same as or different from the first reflection coefficient, and this application does not impose any limitation on this.

[0055] The third preset reflection coefficient and the third reflection coefficient are both at the same first operating frequency.

[0056] The principles of the specific steps of determining the third amplitude difference and the third phase difference in this embodiment are similar to those in the first aspect and will not be repeated here.

[0057] When a medium approaches the phone from a distance away from the phone antenna (for example, the distance between the medium and the antenna exceeds 10mm), the reflection coefficient of the antenna changes slightly, but the fluctuation of the amplitude and phase change of the reflection coefficient relative to the reference point is obvious. In this case, the method of this embodiment can detect whether the fluctuation of the amplitude and phase change of multiple sampling points relative to the reference point meets the preset conditions to determine whether there is a medium approaching the phone. Among them, if the fluctuation of the amplitude and phase change of multiple sampling points relative to the reference point meets the preset conditions, it means that there is a medium approaching the phone. When the mobile phone of the embodiment of the present application is used to detect such a scene where the medium is weakly approaching, the recognition accuracy is relatively high.

[0058] According to the first aspect, or any implementation method of the first aspect above, the fluctuation information of the multiple third amplitude difference values ​​and the fluctuation information of the multiple third phase difference values ​​are detected to meet the preset conditions, and it is determined that there is a medium approaching the electronic device, including: detecting that the variance of the multiple third amplitude difference values ​​is greater than a first preset variance threshold, and / or detecting that the standard deviation of the multiple third amplitude difference values ​​is greater than a first preset standard deviation threshold, and / or detecting that the variance of the multiple third phase difference values ​​is greater than a second preset variance threshold, and / or detecting that the standard deviation of the multiple third phase difference values ​​is greater than a second preset standard deviation threshold, and determining that there is a medium approaching the electronic device.

[0059] For example, the variance or standard deviation of the amplitude difference can reflect the fluctuation of the reflection coefficient over a period of time. The larger the variance and / or standard deviation, the more obvious the fluctuation of the reflection coefficient. Therefore, a variance threshold and a standard deviation threshold can be set. These two thresholds can be empirical values.

[0060] Exemplarily, the preset variance threshold may be the variance of amplitude changes of multiple sampling points of the first antenna of the mobile phone relative to a reference point when the reflection coefficient of the antenna is in a stable state, and / or the variance of phase changes.

[0061] Exemplarily, the preset standard deviation threshold may be the variance of amplitude changes of multiple sampling points of the first antenna of the mobile phone relative to a reference point when the reflection coefficient of the antenna is in a stable state, and / or the standard deviation of phase changes.

[0062] Exemplarily, the stable state here may include but is not limited to: FS state, mobile phone holding state, a stable state in which the medium is close to the mobile phone antenna so that the reflection coefficient of the antenna changes steadily (for example, a scenario in which the medium is within 10 mm close to the mobile phone), etc.

[0063] When the variance of the amplitude difference exceeds a preset variance threshold and / or the standard deviation of the amplitude difference exceeds a preset standard deviation threshold, it indicates that the reflection coefficient has slightly fluctuated. This fluctuation in the reflection coefficient exceeds the fluctuation in the reflection coefficient when the reflection coefficient is in a stable state, indicating that a medium is approaching the phone. The phone can detect the medium's approach even when the medium is at a relatively large distance from the phone.

[0064] According to the first aspect, or any implementation of the first aspect above, the first medium type includes at least one of the following: human body, metal, plastic, and magnetic material.

[0065] The mobile phone of the embodiment of the present application can detect the medium type of any dielectric constant, thereby determining the medium type, and then performing corresponding reminder processing or power reduction operations based on the medium type.

[0066] In a second aspect, embodiments of the present application provide an electronic device. The electronic device includes: at least one antenna, the at least one antenna including a first antenna; the electronic device also includes a memory and a processor, the memory and the processor being coupled; the memory storing program instructions, which, when executed by the processor, cause the electronic device to perform instructions of the method according to the first aspect or any possible implementation of the first aspect.

[0067] In a third aspect, an embodiment of the present application provides a computer-readable medium for storing a computer program, wherein the computer program includes instructions for executing the method in the first aspect or any possible implementation of the first aspect.

[0068] In a fourth aspect, an embodiment of the present application provides a computer program comprising instructions for executing the method in the first aspect or any possible implementation of the first aspect.

[0069] In a fifth aspect, embodiments of the present application provide a chip comprising a processing circuit and transceiver pins. The transceiver pins and the processing circuit communicate with each other via an internal connection path, and the processing circuit executes the method of the first aspect or any possible implementation of the first aspect to control the receive pin to receive a signal and to control the transmit pin to send a signal. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0071] Figure 1is one of the structural diagrams of an electronic device shown as an example;

[0072] Figure 2 is a schematic diagram of the software structure of an electronic device shown as an example;

[0073] Figure 3a is a schematic diagram of the hardware structure of an electronic device shown as an example;

[0074] Figure 3b An exemplary hardware link diagram of an electronic device;

[0075] Figure 4a This is a schematic diagram of a flow chart of an exemplary electronic device detecting scenario;

[0076] Figure 4b This is a schematic diagram of a flow chart of an exemplary electronic device detecting scenario;

[0077] Figure 4c A process for refreshing a reference point for an illustrative electronic device;

[0078] Figure 4d This is a schematic diagram of a flow chart of an exemplary electronic device detecting scenario;

[0079] Figure 5 Schematic diagram of the time-varying trajectory of the reflection coefficient shown as an example;

[0080] Figure 6 is a schematic diagram of an exemplary application scenario;

[0081] Figure 7 is a schematic diagram illustrating an exemplary application scenario and a time-varying trajectory of a reflection coefficient;

[0082] Figure 8 is a schematic diagram illustrating an exemplary application scenario and a time-varying trajectory of a reflection coefficient;

[0083] Figure 9 is a schematic diagram illustrating an exemplary application scenario and a time-varying trajectory of a reflection coefficient;

[0084] Figure 10 is a schematic diagram showing an exemplary change in the amplitude and phase of the reflection coefficient;

[0085] Figure 11 is a schematic diagram showing an exemplary change in the amplitude of the reflection coefficient;

[0086] Figure 12 is a schematic diagram of an exemplary application scenario;

[0087] Figure 13 A schematic diagram of the structure of the device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0088] The following will be combined with the drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are part of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.

[0089] The term "and / or" in this article is merely a description of the association relationship between associated objects, indicating that three relationships may exist. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone.

[0090] In the description and claims of the embodiments of this application, the terms "first" and "second" are used to distinguish different objects, rather than to describe a specific order of objects. For example, the terms "first target object" and "second target object" are used to distinguish different objects, rather than to describe a specific order of objects.

[0091] In the embodiments of this application, words such as "exemplary" or "for example" are used to indicate examples, illustrations, or descriptions. Any embodiment or design described as "exemplary" or "for example" in the embodiments of this application should not be interpreted as being preferred or advantageous over other embodiments or designs. Rather, the use of words such as "exemplary" or "for example" is intended to present the relevant concepts in a concrete manner.

[0092] In the description of the embodiments of this application, unless otherwise specified, "multiple" means two or more. For example, "multiple processing units" means two or more processing units; "multiple systems" means two or more systems.

[0093] Figure 1 1 shows a schematic diagram of the structure of the electronic device 100. It should be understood that, Figure 1 The electronic device 100 shown is merely an example of an electronic device. Alternatively, the electronic device 100 may be a terminal, also referred to as a terminal device. The terminal may be a cellular phone, a tablet, a wearable device, an IoT device, or any other device with an antenna, and this application does not limit this. It should be noted that the electronic device 100 may have more or fewer components than shown in the figure, may combine two or more components, or may have a different component configuration. Figure 1 The various components shown in the drawings may be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and / or application specific integrated circuits.

[0094] The electronic device 100 may include: a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.

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

[0096] The controller may be the nerve center and command center of the electronic device 100. The controller may generate an operation control signal according to the instruction operation code and the timing signal to complete the control of fetching and executing instructions.

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

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

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

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

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

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

[0103] The MIPI interface can be used to connect the processor 110 to peripheral devices such as the display 194 and the camera 193. MIPI interfaces include the camera serial interface (CSI) and the display serial interface (DSI). In some embodiments, the processor 110 and the camera 193 communicate via the CSI interface to implement the camera function of the electronic device 100. The processor 110 and the display 194 communicate via the DSI interface to implement the display function of the electronic device 100.

[0104] The GPIO interface can be configured via software. It can be configured as either a control signal or a data signal. In some embodiments, the GPIO interface can be used to connect the processor 110 to the camera 193, display 194, wireless communication module 160, audio module 170, sensor module 180, and the like. The GPIO interface can also be configured as an I2C interface, an I2S interface, a UART interface, a MIPI interface, and the like.

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

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

[0107] The charging management module 140 is configured to receive charging input from a charger. The charger can be either a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 can receive charging input from the wired charger via the USB interface 130. In some wireless charging embodiments, the charging management module 140 can receive wireless charging input via the wireless charging coil of the electronic device 100. While charging the battery 142, the charging management module 140 can also provide power to the electronic device via the power management module 141.

[0108] The power management module 141 is used to connect the battery 142, the charging management module 140, and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140 and provides power to the processor 110, the internal memory 121, the external memory, the display 194, the camera 193, and the wireless communication module 160. The power management module 141 can also be used to monitor parameters such as battery capacity, battery cycle count, and battery health status (leakage, impedance). In some other embodiments, the power management module 141 can also be provided in the processor 110. In other embodiments, the power management module 141 and the charging management module 140 can also be provided in the same device.

[0109] The wireless communication function of the electronic device 100 can be implemented through the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modem processor and the baseband processor.

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

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

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

[0113] The wireless communication module 160 can provide wireless communication solutions including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared (IR), etc., which are applied to the electronic device 100. The wireless communication module 160 can be one or more devices that integrate at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2, frequency modulates and filters the electromagnetic wave signals, and sends the processed signals to the processor 110. The wireless communication module 160 can also receive the signal to be sent from the processor 110, frequency modulate it, amplify it, and convert it into electromagnetic waves for radiation through the antenna 2.

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

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

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

[0117] The electronic device 100 can implement a shooting function through an ISP, a camera 193, a video codec, a GPU, a display screen 194, and an application processor.

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

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

[0120] The digital signal processor is used to process digital signals. In addition to processing digital image signals, it can also process other digital signals. For example, when the electronic device 100 selects a frequency point, the digital signal processor is used to perform Fourier transform on the frequency point energy.

[0121] Video codecs are used to compress or decompress digital video. Electronic device 100 may support one or more video codecs. This allows electronic device 100 to play or record videos in various encoding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, and MPEG4.

[0122] The NPU is a neural network (NN) computing processor. Drawing on the structure of biological neural networks, such as the transmission patterns between neurons in the human brain, it rapidly processes input information and can continuously self-learn. The NPU can enable intelligent cognitive applications in electronic device 100, such as image recognition, face recognition, speech recognition, and text comprehension.

[0123] The external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100. The external memory card communicates with the processor 110 via the external memory interface 120 to implement data storage functions. For example, files such as music and videos can be stored on the external memory card.

[0124] The internal memory 121 can be used to store computer executable program codes, which include instructions. The processor 110 executes various functional applications and data processing of the electronic device 100 by running the instructions stored in the internal memory 121. The internal memory 121 may include a program storage area and a data storage area. Among them, the program storage area can store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc. The data storage area can store data created during the use of the electronic device 100 (such as audio data, a phone book, etc.), etc. In addition, the internal memory 121 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, a universal flash storage (UFS), etc.

[0125] The electronic device 100 can implement audio functions such as music playback and recording through the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the headphone jack 170D, and the application processor.

[0126] The audio module 170 is used to convert digital audio information into analog audio signal output, and is also used to convert analog audio input into digital audio signals. The audio module 170 can also be used to encode and decode audio signals. In some embodiments, the audio module 170 can be provided in the processor 110, or some functional modules of the audio module 170 can be provided in the processor 110.

[0127] The speaker 170A, also called a "speaker", is used to convert audio electrical signals into sound signals. The electronic device 100 can listen to music or listen to hands-free calls through the speaker 170A.

[0128] The receiver 170B, also called a "handset", is used to convert audio electrical signals into sound signals. When the electronic device 100 receives a call or a voice message, the user can place the receiver 170B close to the ear to hear the voice.

[0129] Microphone 170C, also known as "microphone" or "microphone", is used to convert sound signals into electrical signals. When making a call or sending a voice message, the user can speak by putting their mouth close to the microphone 170C to input the sound signal into the microphone 170C. The electronic device 100 can be provided with at least one microphone 170C. In other embodiments, the electronic device 100 can be provided with two microphones 170C, which can not only collect sound signals but also realize noise reduction function. In other embodiments, the electronic device 100 can also be provided with three, four or more microphones 170C to realize sound signal collection, noise reduction, and identification of sound sources, and realize directional recording function, etc.

[0130] The headphone jack 170D is used to connect a wired headphone and can be the USB interface 130 or a 3.5mm open mobile terminal platform (OMTP) standard interface or a cellular telecommunications industry association of the USA (CTIA) standard interface.

[0131] Pressure sensor 180A is used to sense pressure signals and convert them into electrical signals. In some embodiments, pressure sensor 180A can be located on display screen 194. There are many types of pressure sensors 180A, such as resistive, inductive, and capacitive. A capacitive pressure sensor can include at least two parallel plates made of conductive material. When force acts on pressure sensor 180A, the capacitance between the electrodes changes. Electronic device 100 determines the intensity of the pressure based on this change in capacitance. When a touch operation is applied to display screen 194, electronic device 100 detects the touch intensity based on pressure sensor 180A. Electronic device 100 can also calculate the touch location based on the detection signal from pressure sensor 180A. In some embodiments, touch operations applied to the same touch location but with different touch intensities can correspond to different operation instructions. For example, when a touch operation with an intensity less than a first pressure threshold is applied to a short message application icon, a command to view short messages is executed. When a touch operation with an intensity greater than or equal to the first pressure threshold is applied to a short message application icon, a command to create a new short message is executed.

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

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

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

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

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

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

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

[0139] The fingerprint sensor 180H is used to collect fingerprints. The electronic device 100 can use the collected fingerprint characteristics to implement fingerprint unlocking, access application locks, fingerprint photography, fingerprint call answering, etc.

[0140] Temperature sensor 180J is used to detect temperature. In some embodiments, electronic device 100 uses the temperature detected by temperature sensor 180J to implement a temperature management strategy. For example, when the temperature reported by temperature sensor 180J exceeds a threshold, electronic device 100 reduces the performance of a processor located near temperature sensor 180J to reduce power consumption and implement thermal protection. In other embodiments, when the temperature falls below another threshold, electronic device 100 heats battery 142 to prevent abnormal shutdown of electronic device 100 due to low temperature. In other embodiments, when the temperature falls below yet another threshold, electronic device 100 boosts the output voltage of battery 142 to prevent abnormal shutdown due to low temperature.

[0141] The touch sensor 180K is also called a "touch panel." The touch sensor 180K can be disposed on the display screen 194. The touch sensor 180K and the display screen 194 form a touch screen, also called a "touch screen." The touch sensor 180K is used to detect touch operations applied thereto or in the vicinity thereof. The touch sensor can transmit the detected touch operations to the application processor to determine the type of touch event. Visual output related to the touch operations can be provided via the display screen 194. In other embodiments, the touch sensor 180K can also be disposed on the surface of the electronic device 100, in a location different from that of the display screen 194.

[0142] The bone conduction sensor 180M can obtain vibration signals. In some embodiments, the bone conduction sensor 180M can obtain vibration signals from the vibrating bones of the human body. The bone conduction sensor 180M can also contact the human pulse to receive blood pressure pulse signals. In some embodiments, the bone conduction sensor 180M can also be set in headphones to form bone conduction headphones. The audio module 170 can parse out voice signals based on the vibration signals of the vibrating bones of the human body obtained by the bone conduction sensor 180M to implement voice functions. The application processor can parse heart rate information based on the blood pressure pulse signals obtained by the bone conduction sensor 180M to implement heart rate detection functions.

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

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

[0145] The indicator 192 may be an indicator light, which may be used to indicate the charging status, power level changes, messages, missed calls, notifications, etc.

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

[0147] The software system of the electronic device 100 can adopt a layered architecture, an event-driven architecture, a micro-kernel architecture, a micro-service architecture, or a cloud architecture. In the embodiment of the present application, the Android system with a layered architecture is used as an example to illustrate the software structure of the electronic device 100.

[0148] Figure 2 It is a software structure block diagram of the electronic device 100 according to an embodiment of the present application.

[0149] The layered architecture of electronic device 100 divides the software into several layers, each with a clear role and division of labor. Layers communicate with each other via software interfaces. In some embodiments, the Android system is divided into four layers: from top to bottom, the application layer, the application framework layer, the Android runtime and system libraries, and the kernel layer.

[0150] The application layer can include a series of application packages.

[0151] like Figure 2 As shown, the application package may include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, short message, etc.

[0152] The application framework layer provides an application programming interface (API) and programming framework for the applications in the application layer. The application framework layer includes some predefined functions.

[0153] like Figure 2 As shown, the application framework layer may include a window manager, a content provider, a view system, a phone manager, a resource manager, a notification manager, and the like.

[0154] The window manager is used to manage window programs. The window manager can obtain the display size, determine whether there is a status bar, lock the screen, take screenshots, etc.

[0155] Content providers are used to store and retrieve data and make it accessible to applications. The data may include videos, images, audio, calls made and received, browsing history and bookmarks, phone books, etc.

[0156] The view system includes visual controls, such as those for displaying text and images. The view system is used to build applications. A display interface can consist of one or more views. For example, a display interface containing a text notification icon might include a view for displaying text and a view for displaying images.

[0157] The phone manager is used to provide communication functions of the electronic device 100, such as management of call status (including answering, hanging up, etc.).

[0158] The resource manager provides various resources for applications, such as localized strings, icons, images, layout files, video files, and so on.

[0159] The Notification Manager allows applications to display notifications in the status bar. These messages can be displayed briefly and then disappear automatically without user interaction. For example, the Notification Manager is used to notify users of completed downloads and message reminders. The Notification Manager can also display notifications in the top status bar of the system as icons or scrolling text, such as notifications from background applications, or as dialog windows on the screen. Examples include text messages in the status bar, beeps, vibrations on electronic devices, and flashing indicator lights.

[0160] The system library and runtime layer include the system library and the Android runtime. The system library can include multiple functional modules, such as the surface manager, media libraries, 3D graphics processing libraries (such as OpenGL ES), and 2D graphics engines (such as SGL). The 3D graphics library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing. The Android runtime includes the core library and the virtual machine. The Android runtime is responsible for scheduling and management of the Android system. The core library consists of two parts: one part contains the function calls required by the Java language, and the other part is the Android core library. The application layer and application framework layer run in the virtual machine. The virtual machine executes the Java files of the application layer and application framework layer as binary files. The virtual machine is responsible for performing functions such as object lifecycle management, stack management, thread management, security and exception management, and garbage collection.

[0161] The surface manager is used to manage the display subsystem and provide fusion of 2D and 3D layers for multiple applications.

[0162] The media library supports playback and recording of a variety of common audio and video formats, as well as static image files. The media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.

[0163] The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.

[0164] A 2D graphics engine is a drawing engine for 2D drawings.

[0165] The kernel layer is the layer between hardware and software. The kernel layer includes at least display driver, camera driver, audio driver, and sensor driver.

[0166] It is understandable that Figure 2 The components included in the illustrated system framework layer, system library, and runtime layer do not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may include more or fewer components than shown, or may combine or split certain components, or arrange the components differently.

[0167] Currently, electronic devices are becoming increasingly intelligent. To enhance user experience or meet user functional requirements, electronic devices may provide scene detection functions. In related technologies, electronic devices primarily perform scene detection based on the amplitude of the antenna's reflection coefficient.

[0168] For example, taking the electronic device as a mobile phone, the mobile phone can collect the reflection coefficient of the mobile phone antenna at a certain moment, and calculate the difference between the reflection coefficient amplitude at that moment and the reflection coefficient amplitude of the same mobile phone antenna in a certain state (for example, FS (freespace) state); then, the scene judgment is performed based on the difference.

[0169] This solution uses only the amplitude difference of the reflection coefficient for scene determination. With a single detection parameter, different scenarios with the same amplitude difference may be identified as the same. For example, a disconnected antenna scenario and a metal-closed phone scenario have similar amplitude differences. Therefore, scene determination based solely on amplitude difference is limited in the number of scenarios that can be determined.

[0170] For example, the phone can also calculate an average of the reflection coefficient in the FS state and the reflection coefficient in the handheld state. The phone then determines whether the phone is in the FS state or the handheld state based on whether the detected reflection coefficient is greater than the average. The reflection coefficient here is the amplitude of the return loss (i.e., the reflection coefficient is a scalar quantity). Therefore, the average value is the mean of the amplitudes of the return loss in the FS state and the handheld state.

[0171] This solution distinguishes scenarios by comparing return loss parameters in two test scenarios: FS state and handheld phone state. This limits the scenarios that the phone can detect. This not only suffers from a non-monotonic reflection coefficient problem (i.e., the reflection coefficient decreases and then increases non-monotonically when the medium approaches the phone antenna), but also makes it impossible to detect complex scenarios (such as the type of media near the phone).

[0172] To this end, an embodiment of the present application provides a method and an electronic device that can implement scene detection based on the amplitude and phase of the reflection coefficient and according to the amplitude and phase changes of the detected reflection coefficient relative to a preset reflection coefficient (i.e., the reference point described later).

[0173] For example, as a medium approaches a mobile phone antenna, the antenna's near field changes, causing the antenna's reflection coefficient to change. Consequently, the amplitude and phase changes between the reflection coefficient detected by the electronic device and the preset reflection coefficient will also change over time. Furthermore, these amplitude and phase changes are monotonic over time. Therefore, the mobile phone can detect the medium's proximity to the mobile phone antenna by tracking these amplitude and phase changes over time.

[0174] In an application scenario, the electronic device of an embodiment of the present application, taking a mobile phone as an example, is provided with an antenna. The mobile phone can detect the medium type (such as human body, metal, plastic, magnetic material, folding screen material, etc.) of the medium near the mobile phone, can detect the relative position of the medium and the mobile phone antenna, can detect from which side of the mobile phone the medium approaches / moves away from the mobile phone, can detect the distance or distance range between the medium and the mobile phone, can detect whether the medium is approaching or moving away from the mobile phone, and can detect whether the mobile phone antenna is disconnected, etc.

[0175] In another application scenario, the electronic device of the embodiment of the present application (taking a mobile phone as an example) can determine whether the mobile phone is wearing a case and the material of the case based on the detected distance between the mobile phone and the medium and the type of medium near the mobile phone.

[0176] It should be noted that the media types that can be detected by this application are not limited to the above examples, and may also include other media types not listed. Different media types can be distinguished by different dielectric constants.

[0177] For example, the dielectric constant may be different due to differences in concentration and ratio of constituent elements.

[0178] In actual applications, relevant laws and regulations have clear provisions on SAR (specific absorption rate, radio frequency energy absorption ratio). When a human body is close to the antenna of an electronic device, the electronic device needs to be properly powered down in accordance with the regulations. Then the electronic device of the embodiment of the present application determines the medium type of the medium located near the electronic device and the distance between the medium and the electronic device. When it is determined that the medium located near the electronic device is a human body, the electronic device can determine whether to perform power backoff based on the distance between the human body and the electronic device and the current power of the antenna of the electronic device. When power backoff is required, the electronic device can perform appropriate power backoff based on the distance to meet the regulatory requirements for SAR.

[0179] Furthermore, currently, various types of electronic device cases (e.g., metal cases, magnetic cases) can affect antenna performance, which in turn affects the user experience of the electronic device. The electronic device of the present application embodiment can detect whether the electronic device is wearing a case and the material of the case, thereby flexibly reminding the user based on the material of the case, thereby improving the user experience of the electronic device.

[0180] The following is a detailed description of the specific solution for implementing scene detection in the electronic device of this application: Figure 3a The figure is a schematic diagram showing the hardware structure of an electronic device according to an embodiment of the present application.

[0181] Please refer to Figure 3a The electronic device may include a sensing unit, a detection unit, a radio frequency unit, a processing unit, and an execution unit. The following description uses a mobile phone as an example. When the electronic device is other terminal devices, the method is similar and will not be described in detail. The sensing unit can be used to transmit and receive antenna signals.

[0182] For example, the sensing unit may be an antenna, and the implementation of the sensing unit in this application is not limited to an antenna. The detection unit may be configured to detect the coupled signal and send the detected coupled signal to the processing unit.

[0183] Exemplarily, the detection unit may be a bidirectional coupler. Of course, the detection unit may also be other electronic components that can detect and express the current antenna state, and this application does not impose any limitation on this.

[0184] The processing unit can be used to process the coupled signal to determine the antenna parameters and detect the current scenario of the mobile phone based on the antenna parameters. For example, it can detect the medium type of the medium near the mobile phone, the relative position of the medium and the mobile phone antenna, the side of the mobile phone from which the medium approaches / moves away from the mobile phone, the distance range between the medium and the mobile phone, whether the medium is approaching or moving away from the mobile phone, whether the mobile phone antenna is disconnected, whether the mobile phone is in a case, and the material of the case.

[0185] For example, when a medium approaches the antenna, the near field of the sensing unit (such as the antenna) may change, thereby causing the antenna parameters to change. Then the coupled signal detected by the coupler will change. In this way, the processing unit can determine the change in the antenna parameters based on the change in the coupled signal, thereby detecting the scene in which the mobile phone is located.

[0186] Exemplarily, the antenna parameter may be a reflection coefficient S11, etc., and S11 may include information of amplitude and phase.

[0187] It should be noted that the antenna parameter is not limited to the reflection coefficient S11, and the antenna parameter may be any parameter that reflects the current antenna state.

[0188] The processing unit can also be used to control the execution unit to perform control operations such as reminders / power reduction / reference point refresh for the corresponding scene based on the detected scene in which the mobile phone is currently located. Among them, the control operations performed by the execution unit may also be different according to the needs depending on the scenes detected by the processing unit.

[0189] Exemplarily, the processing unit may be a processor, and this application does not limit the implementation of the processing unit.

[0190] For example, when a mobile phone detects that a human body is close to the mobile phone, and when it is determined according to demand that the transmission power of the mobile phone's antenna needs to be reduced, the processing unit can be used to send control information representing the antenna transmission power to the execution unit, such as the transmission power gear, so that the execution unit can retract the antenna transmission power according to the control information.

[0191] Exemplarily, the execution unit may include a radio frequency unit.

[0192] The radio frequency unit can be used to transmit / receive signals and perform processing such as amplification and filtering on the signals.

[0193] Exemplarily, the radio frequency unit may include but is not limited to: a radio frequency transceiver chip, a filter, a power amplifier, etc.

[0194] Optionally, when the processing unit detects a scenario other than a human body approaching the mobile phone, the processing unit may also send control information to the execution unit to perform corresponding control operations.

[0195] For example, based on the difference in scenes detected by the processing unit, the control operations that the mobile phone needs to execute may be different, and the execution units may also be different.

[0196] For example, the processing unit detects that the mobile phone has a plastic shell, and the execution unit can Figure 1 For example, when a mobile phone is charging with its case on, and considering that charging with the case on is not conducive to heat dissipation, the processing unit may send control information to the charging management module 140. This control information may be used to indicate a reduction in charging speed or charging current to reduce heating of the mobile phone. Of course, depending on the control requirements, the control information is not limited to the above-mentioned information on reducing charging speed or charging current. The specific control information can be flexibly set according to requirements, and this application does not impose any restrictions on this.

[0197] For example, if the processing unit detects that the mobile phone has a magnetic shell or a metal shell, then the magnetic shell and the metal shell have a certain impact on the transmission and reception of antenna signals. The execution unit may include Figure 1 The processing unit can send control information indicating that the magnetic case affects the mobile phone signal to the indicator 192 to remind the user to avoid using magnetic or metal cases as much as possible. Of course, depending on the control requirements, the control information is not limited to the above examples and can also be control information for indicating other control operations such as increasing or not decreasing the power. The specific control information can be flexibly set according to the requirements, and this application does not impose any restrictions on this.

[0198] Optionally, the execution unit may be configured to feed back a response result after executing the control information to the processing unit.

[0199] Considering that the processing unit detects a large number of scenarios, the execution unit will not be given examples one by one here. It should be understood that the execution unit can be any electronic component used to execute the control information, and this application does not impose any restrictions on this.

[0200] It is understandable that Figure 3a The components included in the electronic device shown do not constitute a specific limitation on the electronic device. In other embodiments of the present application, the electronic device may include Figure 3a More or fewer components may be shown, or some components may be combined or separated, or the components may be arranged differently.

[0201] based on Figure 3a Hardware structure diagram of electronic equipment, Figure 3b The hardware link diagram of an electronic device according to an embodiment of the present application is exemplarily shown.

[0202] like Figure 3b As shown, taking a mobile phone as an example, the mobile phone may include n antennas, where n is a positive integer.

[0203] Exemplarily, the mobile phone antenna can be arranged at any position on the mobile phone, including but not limited to: any position on the side of the mobile phone, and / or any position on the back of the mobile phone (the side opposite to the front of the mobile phone), and any position on the front of the mobile phone (the side opposite to the back of the mobile phone). The side of the mobile phone is used to represent the area connecting the front and back of the mobile phone, the front of the mobile phone can be used to represent the side including the display screen, and the back of the mobile phone can be used to represent the side opposite to the display screen. This application does not impose any restrictions on the number of mobile phone antennas or the layout of the antennas.

[0204] exist Figure 3b In the figure, an antenna for transmitting signals connected to the TX (transmit, transmitting port) of the radio frequency link and an antenna for receiving signals connected to the RX (receive, receiving port) of the radio frequency link are shown.

[0205] It should be noted that the mobile phone may include an antenna for transmitting signals and / or an antenna for receiving signals, and this application does not impose any restrictions on this.

[0206] exist Figure 3b In FIG, a bidirectional coupler is shown, optionally connected to an antenna via a switching unit.

[0207] It should be noted that the electronic device may also include multiple bidirectional couplers, for example, each antenna is configured with a bidirectional coupler connected thereto via a switch unit. This application does not limit the number of bidirectional couplers or the connection relationship between the antenna and the bidirectional coupler.

[0208] like Figure 3bAs shown, when the antenna transmits a signal, the bidirectional coupler can obtain the coupled signal and send it to the processor through the MRX (measure receive, feedback channel) of the RF link. The processor processes the coupled signal to obtain antenna parameters, such as the reflection coefficient S11 including amplitude and phase.

[0209] By processing the reflection coefficient S11, the processor can detect the scene in which the mobile phone is located. When the processor determines that the transmit power of the antenna needs to be adjusted, the processor can send a control signal to the RF link to adjust the transmit power of the antenna. Exemplarily, the control signal can be a signal indicating the transmit power value (e.g., a signal for the transmit power gear). This application does not limit the control signal.

[0210] For example, if the processor detects a person approaching the phone, it can determine whether power backoff is necessary based on the current power status of antenna 1. If the processor determines that power backoff is necessary for antenna 1, it can send a control signal to the RF link to reduce the transmit power of antenna 1 (here, the transmitting antenna).

[0211] For example, when the current power of the antenna transmitting the signal is less than the preset power, no power backoff is required. When the current power of the antenna is greater than or equal to the preset power, the power backoff amount can be determined based on the distance between the human body and the antenna.

[0212] Optionally, the radio frequency link may include but is not limited to a radio frequency transceiver chip (eg, a baseband) and a radio frequency front end connected in a signal transmission direction.

[0213] The RF transceiver chip can modulate and demodulate the input signal and send the processed signal to the RF front end.

[0214] The RF front end can filter, amplify and process the input signal and output it.

[0215] Exemplarily, the RF front end may include but is not limited to a filter, a power amplifier (PA), a low noise amplifier, a switch, and the like.

[0216] It is understandable that Figure 3b The components included in the mobile phone shown in FIG. 1 do not constitute a specific limitation on the mobile phone. In other embodiments of the present application, the mobile phone may include Figure 3b More or fewer components may be shown, or some components may be combined or separated, or the components may be arranged differently.

[0217] Figure 4a The following is a flow chart of an electronic device detecting scenario according to an embodiment of the present application, with reference to FIG3a and FIG3b. Figure 3b right Figure 4a Make an introduction.

[0218] S101: The processor obtains a reference point.

[0219] For example, in this Figure 4a When the process is first executed, the reference point may be an initially set reference point.

[0220] For example, the processor may Figure 3b For example, the reflection coefficient of antenna 1 in FIG. 1 at a certain moment, a certain state (such as the FS state or a stable state such as a human body close to the mobile phone), or a certain operating frequency is used as the reference point refrence_fs.

[0221] The reflection coefficient here includes information of amplitude and phase.

[0222] For example, for an initially set reference point (eg, a reference point set when the mobile phone leaves the factory), the processor may use the reflection coefficient (eg, S11) of antenna 1 at a certain moment when the mobile phone is not in a case and is in the FS state as refrence_fs.

[0223] For example, after the mobile phone is equipped with a case, the reflection coefficient of the antenna will change compared to the reflection coefficient when the mobile phone is not equipped with a case. The reference point obtained by the processor can be the updated reflection coefficient, such as a reflection coefficient of the mobile phone antenna 1 when the mobile phone is equipped with a case.

[0224] For example, the processor may periodically refresh the reference points, thereby obtaining the refreshed reference points for scene detection.

[0225] S103: The processor obtains at least one sampling point.

[0226] Optionally, the processor may obtain a reflection coefficient of the antenna 1 at an operating frequency to obtain a sampling point.

[0227] Optionally, the processor may obtain multiple reflection coefficients of the antenna 1 at the same operating frequency at different times to obtain multiple sampling points.

[0228] Optionally, the time length for the processor to acquire one sampling point is 50 ms, and the processor can acquire 10 sampling points within 500 ms.

[0229] The at least one sampling point and the reference point are at the same operating frequency of the antenna 1 .

[0230] The present application does not limit the execution order between S101 and S103.

[0231] S105: The processor determines the scene in which the mobile phone is located according to the amplitude and phase changes of the at least one sampling point relative to the reference point.

[0232] Among them, amplitude and phase are one-dimensional parameters, and amplitude and phase (including amplitude and phase) are two-dimensional parameters. The change of amplitude and phase represents the change of amplitude and phase, so the change of amplitude and phase is also a two-dimensional parameter. A sampling point can be regarded as a two-dimensional point (for example Figure 5 a point in the Smith chart shown).

[0233] Exemplarily, the processor of the mobile phone may determine the medium type of the medium near the mobile phone, or whether the antenna is in a disconnected state, etc., based on the threshold range of the amplitude and phase change of the at least one sampling point relative to the reference point.

[0234] Optionally, after determining the medium type, the mobile phone processor may further determine the distance or distance range between the medium and the mobile phone.

[0235] For example, each sampling point may change with time over a period of time, and each sampling point may form a time-varying trajectory relative to a reference point in the Smith chart. The time-varying trajectory may be different when the mobile phone is in different scenarios.

[0236] Figure 5 Schematic diagram showing the time-varying trajectory of the reflection coefficient of antenna 1 in different scenarios.

[0237] in, Figure 5 In the coordinate system shown, the horizontal axis represents the real part of the reflection coefficient (Real Part of Gammal), and the vertical axis represents the imaginary part of the reflection coefficient (Imag Part of Gammal).

[0238] Among them, the amplitude is abs(S11), which is the modulus of the reflection coefficient S11 (the square root of the sum of the square of the real part and the square of the imaginary part), and the phase is angle(S11), in radians. Then Figure 5 A point in the coordinate system (also called a sampling point) can express a reflection coefficient.

[0239] For example, to facilitate understanding, the amplitude and phase changes (including amplitude changes and phase changes) of a sampling point relative to a reference point may be described as a position Δ relative to the reference point.

[0240] Wherein, Δ=f(S11(ti))-refrence_fs;

[0241] Among them, f(S11(ti)) represents the reflection coefficient or its related expressions (including amplitude and phase) collected at the i-th moment ti, that is, the i-th sampling point among at least one sampling point; refrence_fs represents the reference point.

[0242] Exemplarily, the amplitude change of the sampling point relative to the reference point (which can be simply referred to as "relative amplitude") is the modulus of Δ (i.e., |Δ|), and the phase change of the sampling point relative to the reference point is the phase of Δ.

[0243] Exemplarily, the amplitude-phase threshold range in which the amplitude-phase change of the sampling point relative to the reference point is located can be manifested as the difference in the area or offset direction where the sampling point is located relative to the reference point in the Smith chart.

[0244] Please refer to Figure 5 , Figure 5 Exemplarily, it shows the sampling curves of antenna 1 in different scenarios under the same operating frequency band.

[0245] The scenario represented by the reference curve 201 (which is also a sampling curve): The mobile phone is not in a case and is in the FS state;

[0246] The scenario represented by the sampling curve 202: The mobile phone is not in a case and there is a human body nearby, and the distance between the human body and the antenna is d2;

[0247] The scenario represented by the sampling curve 203: The mobile phone is not in a case and there is a human body nearby, and the distance between the human body and the antenna is d1;

[0248] The scenario represented by the sampling curve 601: The mobile phone is in a plastic case and is in free space, that is, the distance between the plastic medium and the antenna is 0 mm;

[0249] The scenario represented by the sampling curve 602: The mobile phone is in a plastic case and there is a human body nearby, and the distance between the human body and the antenna is d2;

[0250] The scenario represented by the sampling curve 603: The mobile phone is in a plastic case and there is a human body nearby, and the distance between the human body and the antenna is d1;

[0251] The scenario represented by the sampling curve 701: The mobile phone is in a metal case and is in free space, that is, the distance between the metal medium and the antenna is 0 mm;

[0252] The scenario represented by the sampling curve 801: The state where antenna 1 of the mobile phone is disconnected.

[0253] Among them, d1 < d2, for example, d1 = 1 mm and d2 = 10 mm. It should be noted that the present application does not limit the values of d1 and d2 here.

[0254] Each sampling curve (including the reference curve 201 ) may include multiple sampling points, and the multiple sampling points in the same sampling curve are reflection coefficients of the antenna 1 at different frequency points in the above-mentioned working frequency band.

[0255] For example, Figure 5 As shown, sampling curve 603 may include sampling point 6031, sampling point 6032, sampling point 6033, sampling point 6034, and sampling point 6035. The five sampling points in sampling curve 603 can be used to represent the five reflection coefficients of antenna 1 at different operating frequencies in the above operating frequency band in a scenario where the mobile phone has a plastic case and the distance between the human body and the antenna is d1.

[0256] Similarly, Figure 5 The multiple points shown in the reference curve 201, sampling curve 202, sampling curve 203, sampling curve 601, sampling curve 602, sampling curve 701, and sampling curve 801 are also used to represent the sampling points of the antenna 1 at different operating frequencies in the above-mentioned operating frequency band.

[0257] It should be noted that this application does not limit the number of operating frequencies of the antenna, nor does it limit the operating frequency band of the antenna.

[0258] Optionally, combined Figure 4a , this application provides Example 1:

[0259] The mobile phone can determine the medium type of the medium near the mobile phone antenna or whether the antenna is disconnected based on the amplitude and phase threshold range within which the amplitude and phase changes of at least one sampling point relative to a reference point fall. The amplitude and phase threshold range includes an amplitude threshold range and a phase threshold range.

[0260] Exemplarily, at least one sampling point and the reference point are at the same operating frequency of the antenna 1. The reference point may be a reflection coefficient of the antenna 1 in the FS state.

[0261] Here, “near” the mobile phone antenna is used to indicate a preset distance range.

[0262] Optionally, when the distance between the medium and the mobile phone antenna 1 is within a preset distance range (eg, 0 to 10 mm, including 0 mm and 10 mm), the mobile phone can implement the above-mentioned scenario detection of the medium type or whether the antenna is disconnected.

[0263] For example, in scenarios where the media near the mobile phone are of different types or the antenna is disconnected, the amplitude and phase changes at the sampling point relative to the reference point may differ. The mobile phone can perform multiple tests to determine the amplitude and phase changes at the sampling point relative to the reference point for each of these scenarios, thereby determining the amplitude and phase threshold ranges for each scenario. In other words, the amplitude and phase threshold ranges for each scenario can be empirical values ​​obtained through multiple tests.

[0264] For example, when the processor performs scene determination based on the amplitude change and phase change of the sampling point relative to the reference point, the processor can read the amplitude and phase threshold ranges for various scenarios (such as scenarios where the medium near the mobile phone is of different media types or the antenna is disconnected) from the internal memory 121, thereby determining the target amplitude threshold range for the amplitude change of the current sampling point relative to the reference point, and the target phase threshold range for the phase change of the current sampling point relative to the reference point. The processor can then determine the scene corresponding to both the target amplitude threshold range and the target phase threshold range based on the mapping relationship between the aforementioned scenarios and the amplitude and phase threshold ranges, and use this scene as the detected scene.

[0265] Optionally, the processor may also update the amplitude and phase threshold ranges and their mapping relationships with scenes in the memory as needed.

[0266] Table 1 shows an example of Figure 5 Amplitude and phase changes of antenna 1 at the sampling point of operating frequency 1 relative to the reference point in each scenario.

[0267] In some embodiments, Table 1 may be an a priori table stored in the mobile phone memory.

[0268] In some embodiments, for scenes that need to be detected, the mobile phone can collect recorded data similar to Table 1 multiple times, so as to obtain the amplitude and phase threshold ranges for each scene, and store the obtained amplitude and phase threshold ranges for each scene as a priori tables in the mobile phone memory.

[0269] Taking the human body as an example, it should be understood that the range of "near" in the embodiments of the present application is related to the operating frequency band of the mobile phone antenna. For example, in the B3 frequency band (1.85GHz-1.91GHz), the range of "near" the mobile phone antenna refers to the range of 10mm from the mobile phone antenna. When the distance is less than or equal to 10mm, the medium will affect the reflection coefficient of the antenna. When the distance is greater than 10mm, the effect of the medium on the reflection coefficient of the antenna is very weak and can be ignored.

[0270]

[0271]

[0272] Table 1

[0273] For example, from records 6 and 7 in Table 1, it can be seen that when the medium is metal or the antenna is disconnected, the amplitude changes of the sampling point relative to the reference point are 0.65 and 0.89, respectively. Compared with the scenarios shown in records 1 to 5 where the medium is plastic and / or human body, the amplitude changes of the sampling point relative to the reference point are greater in the scenarios where the medium is metal or the antenna is disconnected. Then, the amplitude threshold range of the amplitude change of the sampling point relative to the reference point can be used to distinguish whether the medium near the mobile phone belongs to the scenario of plastic and / or human body, or to the scenario of metal or antenna disconnection. Furthermore, since the phase changes of the sampling points corresponding to records 6 and 7 relative to the reference point are different, it can be determined which scenario between records 6 and 7 it is based on the phase threshold range of the phase change.

[0274] For example, records 1 and 2 represent scenarios where the human body is at different distances from the mobile phone antenna 1 when the mobile phone is not in a case, and records 4 and 5 represent scenarios where the human body is at different distances from the mobile phone antenna 1 when the mobile phone is in a plastic case.

[0275] For example, for the scenes corresponding to record 1 and record 2, Figure 6 A schematic diagram of the scenario is shown. In addition, Figure 5 The sampling curve 202 and the sampling curve 203 in the figure represent the sampling data under the scenes corresponding to record 2 and record 1 respectively. Figure 5 、 Figure 6 and records 1 and 2 in Table 1.

[0276] Please refer to Figure 6 , taking the electronic device as a mobile phone as an example. For example, a side 100 of the mobile phone with buttons includes an antenna 103, for example, the antenna 103 is the antenna 1 described herein. The side 100 may include one or more buttons, such as Figure 6 The buttons shown on the side 100 include but are not limited to: a volume button 101 and a button 102 for locking the screen and shutting down the device. Figure 6 The mobile phone in the embodiment may include four sides. Here, the antenna 103 arranged on the side 100 is taken as an example for explanation. For example, the current operating frequency of the antenna 103 is Figure 5 Each sampling curve shown corresponds to operating frequency point 1 in the operating frequency band.

[0277] In addition, the side 100 may be provided with one or more antennas. The antenna layout is not limited to surrounding the above-mentioned buttons 101 and 102. The antennas may be arranged at any position within the side 100. This application does not impose any restrictions on this. In addition, the back side and the front side 301 of the mobile phone may be provided with one or more antennas. This application does not impose any restrictions on this. Figure 6 (1) The side opposite to the front side 301 of the mobile phone shown.

[0278] exist Figure 6 In (1), the distance between the human body (e.g., the user's hand) 104 and the antenna 103 is d2 as shown by the dotted line. Figure 5 As shown, when the phone is not in a case and the distance between the hand and the phone antenna is d2, the phone processor obtains Figure 6 (1) A sampling point in the sampling curve 202 corresponding to the working frequency point 1. Record 2 in Table 1 shows Figure 5 The amplitude change and phase change of a sampling point corresponding to operating frequency 1 in sampling curve 202 relative to the reference point. As shown in record 2 in Table 1, when the phone is not in a case and the distance between the hand and antenna 1 is d2, the amplitude change of the sampling point relative to the reference point is 0.13, and the phase change of the sampling point relative to the reference point is -1.2.

[0279] from Figure 6 (1) to Figure 6 (2), hand 104 from Figure 6 (1) The distance d2 from the antenna 103 is indicated by the black arrow (eg, the direction perpendicular to the side 100) and the hand 104 moves closer to the antenna 103, so that the distance between the hand 104 and the antenna 103 changes from Figure 6 The d2 shown in (1) changes to Figure 6 (2) d1 shown. Combined Figure 5 ,exist Figure 6 When the distance between the hand 104 and the antenna 103 shown in (2) is d1, the mobile phone processor collects a sampling point corresponding to the working frequency point 1 in the sampling curve 203. Record 1 in Table 1 shows Figure 5 The amplitude change and phase change of a sampling point corresponding to operating frequency 1 in sampling curve 203 relative to the reference point are shown in record 1 in Table 1. When the phone is not in a case and the distance between the hand and antenna 1 is d1, the amplitude change of the sampling point relative to the reference point is 0.56, and the phase change of the sampling point relative to the reference point is -1.3.

[0280] For example, as described above, for example, d1 is 1 mm and d2 is 10 mm. The present application does not limit the specific values ​​of d1 and d2.

[0281] It should be noted that Figure 5 The sampling curves 202, 203, 602 and 603 are based on the user's palm perpendicular to the side antenna (eg Figure 6 In the scenario where the medium approaches the direction of the antenna 103 in the embodiment, the processor samples the reflection coefficient of the antenna 103. However, this application does not limit the way in which the medium approaches the antenna.

[0282] As shown in records 1, 2, 4, and 5 in Table 1, when a person appears in the medium near the phone antenna, the phase change at the sampling point relative to the reference point is around -1, regardless of whether the phone is in a case or in a plastic case. As shown in record 3, when the phone is in a plastic case but in free space (no person nearby), the phase change at the sampling point relative to the reference point is around 0.05.

[0283] Although in the scenario where the medium near the mobile phone is plastic and / or human body, the amplitude change of the sampling point relative to the reference point (all small, for example, the amplitude change is less than 0.6) cannot effectively distinguish the medium type, the mobile phone can further combine the phase threshold range of the phase change of the sampling point relative to the reference point to effectively distinguish whether the medium is plastic or human body. For example, the mobile phone can determine that the medium near the mobile phone includes a human body by determining that the phase change of the collected reflection coefficient relative to the reference point is near -1 (scenarios include record 1, record 2, record 4, and record 5), thereby achieving Figure 6 In the scenario shown, the type of medium near the phone is detected, including the effect of a human body. Furthermore, the phone can also determine that the medium near the phone is plastic, but there is no human body nearby, by determining that the phase change of the collected reflection coefficient relative to the reference point is around 0.05 (scenario includes record 3).

[0284] Similarly, in scenarios where the medium is metal (for example, in scenario 6, the phone has a metal case but is in free space, meaning there are no people near the phone antenna. It should be understood that the range referred to by "near" is related to the operating frequency band of the phone antenna. For example, in the B3 frequency band (1.85 GHz-1.91 GHz), "near" the phone antenna refers to within 10 mm of the phone antenna) or when the antenna is disconnected, the amplitude change relative to the reference point is relatively large (for example, an amplitude change greater than 0.6). As shown in records 6 and 7, the amplitude change in the antenna disconnect state is 0.89, compared to the amplitude change of 0.65 when the medium is metal. The amplitude change at the sampling point relative to the reference point is greater. The phone can determine that the phone is in a metal case or the antenna is disconnected based on the threshold range of the amplitude change (for example, an amplitude change greater than 0.6). Furthermore, as shown in record 7, in the antenna disconnected state, the phase change at the sampling point relative to the reference point is approximately 2. As shown in Record 6, in the metal medium scenario, the phase change at the sampling point relative to the reference point is around -1.5. The phone can then use the phase threshold range of the sampling point relative to the reference point to effectively distinguish between metal medium scenarios and scenarios where the phone antenna is disconnected.

[0285] Exemplarily, the antenna disconnection state in the above record 7 may include: when the mobile phone is not in a case and there is no medium near the mobile phone, the antenna 1 is in a disconnected state; it may also include a scenario where the mobile phone has a metal case or a plastic case and there is a medium near the mobile phone and the antenna 1 is in a disconnected state.

[0286] In an embodiment of the present application, the mobile phone can configure different amplitude threshold ranges and different phase threshold ranges for two scenarios: different media types near the mobile phone antenna and the mobile phone antenna being in a disconnected state. Then, the mobile phone can determine the type of medium near the mobile phone or whether the antenna is disconnected based on the amplitude threshold range of the amplitude change of at least one sampling point relative to the reference point, and the phase threshold range of the phase change. Exemplarily, the mobile phone can distinguish the medium type or the antenna disconnection state by the amplitude threshold range of the amplitude change of the sampling point relative to the reference point. When complex scenes cannot be effectively distinguished by amplitude changes, the mobile phone can further effectively determine the medium type of the medium near the mobile phone and whether the antenna is in a disconnected state by the phase threshold range of the phase change of the sampling point relative to the reference point, thereby effectively distinguishing complex scenes.

[0287] Optionally, when the mobile phone determines that the medium near the mobile phone antenna 1 includes a human body, the transmission power of the antenna 1 may be reduced when the current transmission power of the antenna 1 is greater than a preset power.

[0288] It should be noted that the scenarios recorded in Table 1 can be flexibly set according to the scenarios that need to be detected in actual applications, and this application does not impose any restrictions on this.

[0289] Optionally, combined Figure 4a , this application provides Example 2;

[0290] The mobile phone may determine a distance range between the medium and the mobile phone based on an amplitude threshold range within which an amplitude change of at least one sampling point relative to a reference point falls.

[0291] Optionally, after determining the medium type of the medium located near the mobile phone, the mobile phone may further determine a distance range between the medium and the mobile phone.

[0292] Exemplarily, at least one sampling point and the reference point are at the same operating frequency of the antenna 1. The reference point may be a reflection coefficient of the antenna 1 in the FS state.

[0293] For example, in scenarios where the distance between the medium of the same medium type and the mobile phone antenna is different, there is a difference in the amplitude change of the sampling point relative to the reference point (for example, record 1 and record 2 in Table 1). Then, the mobile phone can obtain empirical values ​​of the amplitude change of the sampling point relative to the reference point in scenarios where the distance between the medium of the same medium type and the mobile phone antenna is different through multiple experiments, so as to determine the amplitude threshold range when the distance between the medium of the same medium type and the mobile phone antenna is different.

[0294] For example, after the mobile phone processor determines the type of medium near the mobile phone, it can further determine the distance range between the mobile phone antenna and the medium based on the amplitude threshold range within which the amplitude change at the sampling point relative to the reference point falls. The processor can read the mapping relationship between the distance between the medium type and the mobile phone antenna and the amplitude threshold range from internal memory 121 to determine the target amplitude threshold range within which the amplitude change at the current sampling point relative to the reference point falls, and further determine the distance range corresponding to the target amplitude threshold range. This allows the distance range between a medium of a known medium type and the mobile phone antenna to be detected.

[0295] Optionally, the processor may also update the mapping relationship between the amplitude threshold range and the distance in each medium type scenario in the memory as needed.

[0296] Optionally, the mobile phone configures a mapping relationship between distance and amplitude threshold range for any of the aforementioned media types, and this mapping relationship may include a predetermined number of distances for detection purposes. When using this mapping relationship to identify the distance range between the medium and the mobile phone, the distance range between the medium and the mobile phone can be determined based on whether the amplitude change at the sampling point relative to the reference point exceeds a maximum amplitude threshold corresponding to a certain distance, or whether it is less than a minimum amplitude threshold corresponding to a certain distance.

[0297] For example, referring to Table 1, Records 1, 2, 4, and 5 depict a scene where a person is near a mobile phone antenna. Records 1 and 4 show that when the distance between the person and the mobile phone antenna is d1, the amplitude change at the sampling point relative to the reference point is approximately 0.5. Records 2 and 5 show that when the distance between the person and the mobile phone antenna is d2, the amplitude change at the sampling point relative to the reference point is approximately 0.13. The amplitude threshold range within which the amplitude change at the sampling point relative to the reference point falls can then be used to further determine the distance range between the currently determined medium and the mobile phone antenna.

[0298] For example, refer to Figure 6 The scene, in Figure 6 In (1), the distance between the hand 104 and the antenna 103 is d2. In this scenario, as shown in record 2 of Table 1, the amplitude change of the sampling point relative to the reference point is 0.13.

[0299] exist Figure 6 In (2), the distance between the hand 104 and the antenna 103 is d1. In this scenario, as shown in record 1 of Table 1, the amplitude change of the sampling point relative to the reference point is 0.56, where d1 = 1 mm and d2 = 10 mm.

[0300] The mobile phone can be pre-configured with a mapping relationship in which, when the medium type is the human body, the amplitude threshold corresponding to the distance d1 is 0.5, and the amplitude threshold corresponding to the distance d2 is 0.1. Then, after the mobile phone has determined that the medium near the mobile phone is the human body, when the amplitude change of the sampling point relative to the reference point is detected to be greater than 0.5, it can be determined that the distance between the human body and the antenna is less than 1 mm; then, when the mobile phone detects that the amplitude change of the sampling point relative to the reference point is less than 0.1, it can be determined that the distance between the human body and the antenna is greater than 10 mm; then, when the mobile phone detects that the amplitude change of the sampling point relative to the reference point is 0.4, it can be determined that the distance between the human body and the antenna is within the range of 1 mm to 10 mm.

[0301] For example, if the medium near the mobile phone is determined to be a human body, the phone can determine whether the current antenna power exceeds a preset power. If so, the phone can determine whether the antenna's transmit power needs to be reduced based on the distance range between the human body and the phone's antenna. When the phone determines that power reduction is necessary, it can determine the amount of antenna transmit power reduction based on the distance range. The farther the distance between the human body and the phone's antenna, the smaller the power reduction; the closer the distance, the greater the power reduction.

[0302] For example, considering that the distance between the medium and the mobile phone exceeds a certain threshold (for example, 10 mm), the reflection coefficient of the mobile phone antenna no longer changes significantly, then the scenes where the distance between the human body and the mobile phone is 10 mm or more can be processed according to the processing method of the scene where the distance between the human body and the mobile phone is 10 mm.

[0303] For example, the mobile phone can configure the amplitude threshold range of the amplitude change of the sampling point relative to the reference point and the mapping relationship between the distance (the distance between the antenna and the medium) for various types of media, and determine the distance corresponding to the amplitude change of the currently detected sampling point relative to the reference point based on the mapping relationship.

[0304] For example, referring to Table 1, according to record 6, it can be determined that when the distance between the metal medium and the mobile phone is 0 mm, the amplitude change of the sampling point relative to the reference point is 0.65. Therefore, when it is determined that the medium is metal, based on the amplitude threshold range within which the amplitude change of the sampling point relative to the reference point lies, it can be determined whether the distance between the metal and the medium is 0 mm, thereby determining whether the mobile phone has a metal case.

[0305] For example, referring to Table 1, according to record 3, it can be determined that when the distance between the plastic medium and the mobile phone is 0 mm, the amplitude change of the sampling point relative to the reference point is 0.14. Therefore, when determining that the medium is plastic, based on the threshold range of the amplitude change of the sampling point relative to the reference point, it can be determined whether the distance between the plastic and the medium is 0 mm, thereby determining whether the mobile phone has a plastic case.

[0306] It should be noted that Figure 5 Table 1 and Table 1 only exemplify some scenarios. The medium types that can be determined for a mobile phone in this application are not limited to metal, plastic, and human body, but can also include any medium type with other dielectric constants.

[0307] also, Figure 5Table 1 exemplifies scenarios where the distance between the human body and antenna 1 is d1 and d2, as well as scenarios where the distance between metal and antenna 1 is 0 mm and the distance between plastic and antenna 1 is 0 mm. The present application is not limited to the above examples for the distance between the medium and the mobile phone that can be determined by the mobile phone, and more distances between the medium and the mobile phone can be identified and determined.

[0308] In an embodiment of the present application, in a scenario where the same type of medium has different distances from the mobile phone antenna 1, the amplitude change of the sampling point relative to the reference point is greatly different. Then, after determining the medium type of the medium located near the mobile phone, the processor in the mobile phone can further determine the distance range between the medium and the mobile phone based on the amplitude threshold range of the amplitude change of the sampling point relative to the reference point.

[0309] Optionally, combined with Figure 4a , this application provides Example 3;

[0310] The mobile phone can determine the relative position between the medium and the mobile phone based on the amplitude and phase threshold range within which the amplitude and phase changes of at least one sampling point relative to the reference point are located.

[0311] Optionally, after the mobile phone determines the media type of the media near the mobile phone, it can further determine the relative position of the media to the mobile phone. The relative position may include which side of the mobile phone the media is near, such as the front, back, or side of the mobile phone.

[0312] Exemplarily, at least one sampling point and the reference point are at the same operating frequency of the antenna 1. The reference point may be a reflection coefficient of the antenna 1 in the FS state.

[0313] Here, the “nearby” is used to indicate a preset distance range.

[0314] In scenarios where the medium of the same medium type and the mobile phone antenna are in different relative positions, the amplitude and phase changes of the sampling point relative to the reference point may vary. Therefore, the mobile phone can obtain empirical values ​​of the amplitude and phase changes of the sampling point relative to the reference point in scenarios where the medium of the same medium type and the mobile phone antenna are in different relative positions through multiple tests. This can then determine the amplitude and phase threshold ranges for scenarios where the medium of the same medium type and the mobile phone antenna are in different relative positions.

[0315] For example, after the mobile phone processor determines the type of medium near the mobile phone, it can further determine the relative position between the mobile phone antenna and the medium based on the amplitude and phase threshold range within which the amplitude and phase change at the sampling point relative to the reference point falls. The processor can read the mapping relationship between the relative position between the medium and the mobile phone corresponding to the medium type and the amplitude and phase threshold range from internal memory 121, thereby determining the target amplitude and phase threshold range within which the amplitude and phase change at the current sampling point relative to the reference point falls, and further determining the relative position corresponding to the target amplitude and phase threshold range. This allows the relative position between a medium of a known medium type and the mobile phone antenna to be detected.

[0316] Optionally, the processor may also update the mapping relationship between the amplitude and phase threshold range and the relative position (between the mobile phone antenna and the medium) in each medium type scenario in the memory as needed.

[0317] For example, Figure 6 Mobile phone in Figure 7 (1) Figure 7 (2) shows a schematic diagram of a scene where a person is located at the side of a mobile phone and a scene where a person approaches the mobile phone from the side 100 of the mobile phone; Figure 7 (3) shows the changing trajectory of the reflection coefficient in the Smith chart in the scenario where the human body is located at the side of the mobile phone and the human body approaches the mobile phone from the side 100 of the mobile phone.

[0318] for Figure 6 Mobile phone in Figure 8 (1) Figure 8 (2) shows a scene in which a human body is located on the front face 301 of the mobile phone, and a schematic diagram of a scene in which a human body approaches the mobile phone from the front face 301 of the mobile phone; Figure 8 (3) shows the changing trajectory of the reflection coefficient in the Smith chart when the human body is located on the front 301 of the mobile phone and when the human body approaches the mobile phone from the front 301 of the mobile phone.

[0319] for Figure 6 Mobile phone in Figure 9 (1) Figure 9 (2) shows a schematic diagram of a scene in which a human body is located on the back 302 of the mobile phone, and a scene in which a human body approaches the mobile phone from the back 302 of the mobile phone; Figure 9 (3) shows the changing trajectory of the reflection coefficient in the Smith chart when the human body is located on the back 302 of the mobile phone and when the human body approaches the mobile phone from the back 302 of the mobile phone.

[0320] For example, Figure 6 、 Figure 7 、 Figure 8 、 Figure 9 As shown, the antenna 103 (ie, the antenna 1 mentioned above) is arranged on the side 100 of the mobile phone.

[0321] It should be noted that Figures 6 to 9 In the mobile phones shown, the same reference numerals denote the same objects. Therefore, each reference numeral is not described one by one. Reference numerals not mentioned can be referred to in the accompanying drawings. Figures 6 to 9 The explanations of the same figure marks as those mentioned in the drawings will not be repeated here.

[0322] Table 2 shows an example of Figures 7 to 9 Partial data on the amplitude and phase changes of the sampling points in each scenario relative to the reference point. The reference point is the reflection coefficient of antenna 1 at a certain operating frequency when the phone is in FS state.

[0323]

[0324] Table 2

[0325] Table 2 is Figures 7 to 9 Part of the data of the embodiment, in Table 2, the antenna 103 is Figures 6 to 9 The antenna 103 is located on the side 100 of the mobile phone. The "side" in Table 2 is used to indicate Figure 7 The human body is located 100 degrees to the side of the phone, and the human body approaches the phone from the side 100 degrees; "front" means Figure 8 The human body is located at the front 301 of the mobile phone, and the human body approaches the mobile phone from the front 301; "back" is used to represent Figure 9 In the middle, a human body is located at the back side 302 of the mobile phone, and the human body approaches the mobile phone from the back side 302 .

[0326] The “relative amplitude” mentioned in this article is used to indicate the amplitude change of a sampling point relative to a reference point; the “relative phase” mentioned in this article is used to indicate the phase change of a sampling point relative to a reference point.

[0327] Among them, the reference point in Table 2 is Figure 7 (3) Figure 8 (3) and Figure 9 (3) The reference curve 401 shown corresponds to a sampling point (i.e., a reflection coefficient) at the operating frequency 1. The reference curve 401 is when the mobile phone is not in the case and is in the FS state. Figures 6 to 9 The reflection coefficient of the antenna 103 in a certain working frequency band at different working frequencies. The reference curve 401 is also a sampling curve. Figure 5 The explanation principle of the sampling curve is the same as that in , so it will not be repeated here.

[0328] Combined with Table 2, Figures 7 to 9 Provide detailed explanation:

[0329] For example, Figure 7 (1) and Figure 7As shown in (2), the user's hand 104 is located on the side 100 of the mobile phone. The hand 104 moves from the side 100 of the mobile phone to the antenna 103 at a distance of 20 mm in the direction of the black arrow until the hand 104 touches the antenna 103, so that the hand 104 is located on the side 100 of the mobile phone and the distance from the antenna 103 is 0 mm.

[0330] exist Figure 7 (1) Change to Figure 7 During the process (2), the hand 104 gradually approaches the antenna 103, causing the reflection coefficient of the mobile phone antenna 103 to change.

[0331] exist Figure 7 (3) shows Figure 5 The partial schematic diagram of the Smith chart shown in the figure is as follows: Figure 7 The principle of the sampling curve shown in (3) is the same as Figure 5 The introduction is similar to that of , and the similarities will not be repeated here.

[0332] For example, in Figure 7 In (3), reference curve 401 shows the reflection coefficient of the mobile phone without a case in the FS state. The sampling point corresponding to the working frequency point 1 in reference curve 401 can be used as the corresponding reference point in Table 2.

[0333] exist Figure 7 (1) Change to Figure 7 (2) In the process, Figure 7 (3) shows Figure 7 Sampling curves for multiple scenarios where the distance between the middle hand 104 and the antenna 103 is 20 mm, 15 mm, 10 mm, 8 mm, 5 mm, 2 mm, and 0 mm.

[0334] For example, as shown in Table 2, when a person is positioned to the side of a mobile phone and the distance between the person and the mobile phone antenna is 0 mm, the amplitude change at the sampling point relative to the reference point is 0.64, and the phase change at the sampling point relative to the reference point is 1.78. The amplitude and phase changes in the other scenarios shown in Table 2 are all smaller than these. Based on the amplitude change of approximately 0.6 and the phase change of approximately 1.7 at the sampling point relative to the reference point, the mobile phone can determine that the relative position of the medium and the mobile phone is: the person is positioned to the side of the mobile phone and the distance between the mobile phone and the person is 0 mm.

[0335] For example, Figure 8 (1) and Figure 8 As shown in (2), the user's hand 104 moves from a position 20 mm away from the antenna 103 in the direction of the black arrow from the front of the mobile phone 301 to the antenna 103 until the hand 104 touches the antenna 103, so that the distance between the hand 104 and the antenna 103 is 0 mm.

[0336] exist Figure 8 (1) Change to Figure 8 During the process (2), the hand 104 gradually approaches the antenna 103, causing the reflection coefficient of the mobile phone antenna 103 to change.

[0337] exist Figure 8 (3) shows Figure 5 The partial schematic diagram of the Smith chart shown in the figure is as follows: Figure 8 The principle of the sampling curve shown in (3) is the same as Figure 7 The introduction of (3) is similar and the similarities are not repeated here.

[0338] For example, Figure 8 The reference curve 401 in (3) is Figure 7 The reference curve 401 in (3) is the same.

[0339] exist Figure 8 (1) Change to Figure 8 (2) In the process Figure 8 (3) shows Figure 8 Sampling curves for multiple scenarios where the distance between the hand 104 and the antenna 103 is 20 mm, 15 mm, 10 mm, 8 mm, 5 mm, 2 mm, and 0 mm.

[0340] For example, as shown in Table 2, when a person approaches the phone from the front and is 10 mm away from the phone antenna, the phase change at the sampling point relative to the reference point is -0.84. In all other scenarios listed in Table 2, the phase change at the sampling point relative to the reference point is greater than -0.84. Based on the fact that the phase change at the sampling point relative to the reference point is near -0.84, the phone can determine that the person is approaching the phone from the front and the distance between the phone and the person is 10 mm or greater.

[0341] For example, Figure 9 (1) and Figure 9 As shown in (2), the user's hand 104 moves from a position 20 mm away from the antenna 103 in the direction of the black arrow from the back of the mobile phone 302 to the antenna 103 until the hand 104 touches the antenna 103, so that the distance between the hand 104 and the antenna 103 is 0 mm.

[0342] exist Figure 9 (1) Change to Figure 9 During the process (2), the hand 104 gradually approaches the antenna 103, causing the reflection coefficient of the mobile phone antenna 103 to change.

[0343] exist Figure 9 (3) shows Figure 5 The partial schematic diagram of the Smith chart shown in the figure is as follows: Figure 9 The principle of the sampling curve shown in (3) is the same as Figure 7 The introduction of (3) is similar and the similarities are not repeated here.

[0344] For example, Figure 9 The reference curve 401 in (3) is Figure 7 The reference curve 401 in (3) is the same.

[0345] exist Figure 9 (1) Change to Figure 9 (2) In the process Figure 9 (3) shows Figure 8 Sampling curves for multiple scenarios where the distance between the hand 104 and the antenna 103 is 20 mm, 15 mm, 10 mm, 8 mm, 5 mm, 2 mm, and 0 mm.

[0346] For example, as shown in Table 2, when a person approaches the phone from the back and is 10 mm away from the phone's antenna, the phase change at the sampling point relative to the reference point is 0.29. In other scenarios listed in Table 2, the phase change at the sampling point relative to the reference point is not near 0.29. Based on the fact that the phase change at the sampling point relative to the reference point is near 0.29, the phone can determine that the person is approaching the phone from the back and the distance between the phone and the person is 10 mm or greater.

[0347] It should be noted that although the human body is used as an example here, when the medium type is a medium type other than the human body, the mobile phone can adopt a similar solution to determine the relative position between the medium and the mobile phone by using the amplitude and phase threshold range of the amplitude and phase change of the sampling point relative to the reference point.

[0348] In addition, it should be understood that the above example uses an antenna located on the side of a mobile phone as an example. However, if the layout of the antennas in the mobile phone changes, or the number of antennas changes, or the direction of the medium close to the mobile phone changes, or the type of medium changes, the amplitude and phase threshold ranges used to determine the relative position between the mobile phone and the medium will also be different. Therefore, the amplitude and phase threshold ranges of the amplitude and phase changes of the sampling points relative to the reference point illustrated in the above example are not used to limit the technical solution of the mobile phone of this application when determining the scene in which it is located.

[0349] It should be noted that in different scenarios, there may be an overlap in the amplitude and phase threshold ranges of amplitude and phase changes. In this case, when the current transmission power of the antenna is greater than the preset power and it is determined that power fallback is required, the power can be reduced by the corresponding amount according to the distance between the human body and the antenna in any scenario where the determined amplitude and phase threshold ranges overlap.

[0350] In Example 3, scene differentiation can be performed based on the amplitude and phase threshold range within which the amplitude and phase changes at the sampling point relative to the reference point fall. For multiple scenes that cannot be differentiated based on amplitude and phase changes, the phone can perform control operations based on the control methods that meet the needs of multiple scenes. Control operations include, but are not limited to, reducing the antenna's transmit power and providing message reminders.

[0351] In an embodiment of the present application, when the relative positions of the same type of medium and the mobile phone are different, there are differences in the amplitude changes of the sampling points relative to the reference points. Then, after determining the medium type of the medium located near the mobile phone, the processor in the mobile phone can further determine the relative position between the medium and the mobile phone based on the amplitude phase threshold range of the amplitude phase change of the sampling points relative to the reference point. Optionally, the distance between the medium and the mobile phone can also be determined.

[0352] In addition, the relative position between the medium and the mobile phone detected by the mobile phone of the present application and the scene where the mobile phone approaches the mobile phone from different sides are not limited to Figures 7 to 9 Schematic scene.

[0353] Optionally, combined Figure 4a , this application provides Example 4;

[0354] When a medium approaches the mobile phone antenna within a preset distance range (for example, 0 to 10 mm), the mobile phone can detect from which side of the mobile phone the medium and the hand are approaching the mobile phone, such as the medium approaching the mobile phone from the front, the medium approaching the mobile phone from the back, or the medium approaching the mobile phone from the side.

[0355] Optionally, after the mobile phone determines the medium type of the medium located near the mobile phone, it may further determine from which side of the mobile phone the medium is approaching the mobile phone.

[0356] In this example, the mobile phone can determine from which side the medium is approaching the mobile phone based on the amplitude and phase threshold range of the amplitude and phase changes of multiple sampling points relative to the reference point.

[0357] The implementation principles of Example 4 are similar to those of Example 3, and the similarities are not repeated here.

[0358] The difference between Example 4 and Example 3 is that Example 3 detects the relative position between the medium and the mobile phone, such as the surface of the mobile phone where the medium is located, which can be considered a static scene; while Example 4 detects the surface of the mobile phone from which the medium is approaching the mobile phone, which can be considered a dynamic scene.

[0359] Different from Example 3, in Example 4, when the mobile phone performs scene detection, it can determine from which side the medium approaches the mobile phone based on the amplitude and phase threshold range of the amplitude and phase changes of each sampling point relative to the reference point within a period of time.

[0360] For example, when the relative position between the medium and the mobile phone is the same based on the amplitude and phase changes relative to the reference point at each sampling point within the above period of time, it can be determined that the medium is approaching or moving away from the mobile phone from the relative position.

[0361] In an embodiment of the present application, when the same type of medium approaches the mobile phone from different sides of the mobile phone antenna, there is a difference in the amplitude change of the sampling point relative to the reference point. Then, after determining the medium type of the medium located near the mobile phone, the processor in the mobile phone can determine from which side of the mobile phone the medium is approaching the mobile phone based on the amplitude and phase threshold range of the amplitude and phase changes of multiple sampling points relative to the reference point. Optionally, the mobile phone can also determine the distance between the medium and the mobile phone.

[0362] For example, after determining from which side the medium approaches the mobile phone, at least one of the following operations can be performed. For example, if the medium is a human body, the transmission power of antenna 1 can be reduced as needed; antenna 1 can be controlled to stop working, and the mobile phone can be controlled to switch the working antenna; the direction of the antenna beam of antenna 1 can be adjusted, which is different from the direction in which the medium approaches the mobile phone.

[0363] Optionally, when the mobile phone detects from which side the medium approaches the mobile phone, considering that the scenario of the medium approaching the mobile phone is a short-term behavior of the user, in order to improve the accuracy of the detection, the mobile phone can use multiple sampling points in a relatively short period of time to detect from which side the medium approaches the mobile phone.

[0364] Figure 4b This is an exemplary process of performing scene detection based on multiple collected sampling points, which may include: S201 and S203.

[0365] Optionally, after S101 , in S201 , the processor acquires a plurality of sampling points.

[0366] Exemplarily, the sampling points are used to represent the reflection coefficient of the mobile phone antenna 1 .

[0367] For example, the processor takes 50 ms to acquire one sampling point. The processor may collect 10 sampling points within 500 ms and use the 10 sampling points to detect whether a medium is approaching the mobile phone.

[0368] S203: The processor determines whether there is a medium approaching the mobile phone based on the acquired change trend or fluctuation information of the multiple sampling points.

[0369] For example, the mobile phone can calculate the changing trend or fluctuation of the reflection coefficient over time by tracking the changing trajectory of the reflection coefficient over time, and determine whether there is a medium close to the mobile phone based on the changing trend or fluctuation (variance or standard deviation, etc.) of the reflection coefficient.

[0370] For example, if the changing trends of the reflection coefficients are the same or the fluctuations of the reflection coefficients are small, it can be determined that there is a medium close to the mobile phone antenna.

[0371] For example, the same change trend of the reflection coefficient may include but is not limited to:

[0372] The amplitude and phase change of the sampling point relative to the reference point (also called relative amplitude and phase) increases over time. Please refer to Example 5.

[0373] The amplitude and phase changes of the sampling point relative to the reference point are greater than the preset amplitude and phase thresholds. Please refer to Example 6.

[0374] The amplitude and phase changes of the sampling point relative to the reference point continuously increase or decrease over time. Please refer to Example 6.

[0375] The amplitude change of the sampling point relative to the reference point has a time derivative greater than zero. Please refer to Example 7.

[0376] Optionally, combined Figure 4b , this application provides Example 5;

[0377] In a scenario where the distance between the medium and the mobile phone antenna is less than or equal to a preset distance threshold (e.g., 10 mm), the mobile phone can determine whether the medium is approaching or moving away from the mobile phone based on changes in the reflection coefficient of the antenna.

[0378] For example, in a scenario where the distance between the medium and the antenna is within a preset distance threshold (e.g., 10 mm), when the medium is close to the mobile phone antenna, the closer the medium is to the mobile phone antenna, the more obvious the change in the reflection coefficient. When the medium is far away from the mobile phone antenna, the farther the medium is from the mobile phone antenna, the weaker the change in the reflection coefficient. Then, when the mobile phone detects that the amplitude and phase changes of the antenna's reflection coefficient relative to a reference point increase over time, it can be determined that the medium is approaching the mobile phone antenna. Similarly, when the mobile phone detects that the amplitude and phase changes of the antenna's reflection coefficient relative to a reference point decrease over time, it can be determined that the medium is moving away from the mobile phone antenna.

[0379] Exemplarily, the multiple sampling points (ie, multiple reflection coefficients) collected here are at the same operating frequency as the reference point of the antenna 1. The reference point may be a reflection coefficient of the antenna 1 in the FS state.

[0380] For example, referring to Table 2 above, when a human body approaches the mobile phone antenna from the side, back, or front of the mobile phone, the relative amplitude increases over time as the distance between the human body and the mobile phone antenna decreases from 10 mm to 0 mm. In this case, the mobile phone can determine that a medium is approaching the mobile phone when it is determined that the amplitude change of the reflection coefficient relative to the reference point increases over time. Continuing to refer to Table 2 above, when a human body moves away from the mobile phone antenna from the side, back, or front of the mobile phone, the relative amplitude decreases over time as the distance between the human body and the mobile phone antenna increases from 0 to 10 mm. In this case, the mobile phone can determine that a medium is moving away from the mobile phone when it is determined that the amplitude change of the reflection coefficient relative to the reference point decreases over time.

[0381] For example, the mobile phone can detect the relationship between the relative amplitude 1 corresponding to the previous sampling point (that is, the amplitude change of the sampling point relative to the reference point) and the relative amplitude 2 corresponding to the current sampling point (that is, the amplitude change of the sampling point relative to the reference point). When the mobile phone detects that the relative amplitude 1 is smaller than the relative amplitude 2, it means that the relative amplitude has increased, and the mobile phone can determine that a medium is approaching the mobile phone; when the mobile phone detects that the relative amplitude 1 is greater than the relative amplitude 2, it means that the relative amplitude has decreased, and the mobile phone can determine that the medium is moving away from the mobile phone.

[0382] Optionally, combined Figure 4b , this application provides Example 6:

[0383] In Example 5 above, the phone can detect if a medium is approaching the phone when the medium is within 10mm of the phone's antenna. This Example 6 can detect not only if a medium is approaching the phone within 10mm of the phone's antenna, but also if the medium is approaching the phone beyond 10mm.

[0384] For example, the mobile phone processor may determine whether a medium is approaching the mobile phone based on whether the change trends of multiple sampling points are the same.

[0385] For example, when the mobile phone processor detects multiple sampling points, if the amplitude and phase changes of each sampling point relative to the reference point are greater than or equal to the preset amplitude and phase threshold, it means that the change trends of the multiple sampling points are the same.

[0386] For another example, when the mobile phone processor detects that the amplitude and phase changes of a sampling point relative to a reference point continue to decrease or increase over time, the processor can determine that the change trends of multiple sampling points are the same.

[0387] Specifically, when the mobile phone processor detects that the amplitude change and phase change of the sampling point relative to the reference point continue to decrease over time, the processor can determine that the change trends of multiple sampling points are the same.

[0388] When the mobile phone processor detects that the amplitude change and phase change of the sampling point relative to the reference point continue to increase over time, the processor can determine that the change trends of multiple sampling points are the same.

[0389] When the mobile phone processor detects that the amplitude change of the sampling point relative to the reference point continues to increase over time, and the phase change of the sampling point relative to the reference point continues to decrease over time, the processor can determine that the change trends of multiple sampling points are the same.

[0390] When the mobile phone processor detects that the amplitude change of the sampling point relative to the reference point continues to decrease over time, and the phase change of the sampling point relative to the reference point continues to increase over time, the processor can determine that the change trends of multiple sampling points are the same.

[0391] For example, the mobile phone processor detects that a group of collected sampling points have the same change trend, and the processor can determine that there is a medium approaching the mobile phone.

[0392] Exemplarily, the multiple sampling points (ie, multiple reflection coefficients) collected here are at the same operating frequency as the reference point of the antenna 1. The reference point may be a reflection coefficient of the antenna 1 in the FS state.

[0393] For example, Figure 10 Schematic diagram showing exemplary amplitude and phase changes of a sampling point relative to a reference point.

[0394] exist Figure 10 In the figure, the horizontal axis represents the sampling points collected in order from the earliest to the latest time (for example, the reflection coefficient of antenna 1). For example, the horizontal axis x=1 represents the first sampling point collected among the 15 sampling points collected. Here, 15 sampling points are shown.

[0395] For example, Figure 12 The scene shown in Figure 12 In (1), the mobile phone is in FS state. In FS state, the mobile phone collects the following Figure 10 The 1st to 5th sampling points shown; then, from Figure 12 (1) changes to Figure 12 (2) The user holds the mobile phone in his hand, and the distance between the user's hand and the antenna 103 is 15 mm. As mentioned above, when the distance between the medium and the antenna exceeds a certain distance threshold (for example, 10 mm), the reflection coefficient of the antenna changes slightly. Figure 12 (2) In the scenario, the mobile phone collects Figure 10 The 6th to 10th sampling points shown; then, the user's hand leaves the phone, causing Figure 12 (2) Change to Figure 12 (1) The mobile phone returns to FS state. In FS state, the mobile phone collects the following Figure 10The 11th to 15th sampling points.

[0396] exist Figure 10 In (1), the vertical axis y represents the amplitude change of the sampling point relative to the reference point. Figure 10 In (2), the vertical axis y represents the phase change of the sampling point relative to the reference point.

[0397] Among them, Figure 10 In the figure, when the horizontal axis x = (1, 2, 3, 4, 5, 11, 12, 13, 14, 15), the mobile phone is in the FS state, and any sampling point (i.e., reflection coefficient) in the FS state can be used as a reference point.

[0398] As mentioned above, when the medium is more than a certain distance from the antenna, for example, 10 mm, the reflection coefficient of the antenna changes slightly. Figure 10 It can be seen that in Figure 12 In the scenario shown in (2) where a human body is close to the mobile phone, when x = (5, 6, 7, 8, 9, 10), the amplitude and phase changes of the sampling points relative to the reference point are very small. Therefore, the amplitude and phase changes of a single sampling point relative to the reference point cannot distinguish the FS state and the state where the medium is close to the mobile phone.

[0399] However, from Figure 10 It can be seen that in Figure 12 In the scenario shown in (2) where a person is close to a mobile phone, the reflection coefficient of the antenna changes slightly while the person is holding the phone. Figure 10 (1) and Figure 10 As shown in (2), when x = (6, 7, 8, 9, 10), the amplitude change and phase change of the sampling point relative to the reference point have a stable direction of change over time. Figure 10 In (1), when x takes the values ​​of 6, 7, 8, 9, and 10, the amplitude change of the sampling point relative to the reference point has a stable trend of decreasing over time. Figure 10 In (2), when x takes values ​​of 6, 7, 8, 9, and 10, the phase change of the sampling point relative to the reference point shows a stable trend of increasing over time. Therefore, in scenarios where the reflection coefficient changes slightly, the mobile phone can detect the change trend of multiple sampling points relative to the reference point. If multiple sampling points show the same change trend relative to the reference point, the mobile phone can determine that there is a medium close to the mobile phone.

[0400] It should be noted that the scene with slight change in reflection coefficient is not limited to Figure 12 The scenario shown in (2) where the medium distance to the antenna exceeds the distance threshold may also include a scenario where the mobile phone is placed in the user's pocket but is close to the user.

[0401] For example, when detecting whether the change trends of multiple sampling points are the same, the mobile phone may determine whether the amplitude and phase change (amplitude change and phase change) of each sampling point relative to the reference point is greater than or equal to a preset amplitude and phase threshold (including a first amplitude threshold and a first phase threshold). If the amplitude and phase change of each sampling point relative to the reference point is greater than or equal to the preset amplitude and phase threshold, then the change trends of the multiple sampling points are the same. Conversely, if the amplitude and phase change of at least one sampling point relative to the reference point is less than the preset amplitude and phase threshold, then the change trends of the multiple sampling points are different.

[0402] In scenarios where the reflection coefficient changes slightly (for example, when the distance between the human body and the phone antenna is more than 10mm), it is difficult to distinguish between the FS state and the medium approaching state using the amplitude and phase changes of a single sampling point relative to a reference point. In scenarios where the medium is close to the phone but the reflection coefficient changes slightly, the amplitude and phase changes of the sampling point relative to the reference point can have a stable trend over time. The phone can then detect whether the amplitude and phase change trends of multiple sampling points relative to the reference point are the same. If the same trends are detected for multiple sampling points relative to the reference point, it can detect the presence of a medium approaching the phone in scenarios with slight reflection coefficient changes.

[0403] It should be noted that when a mobile phone uses the same reflection coefficient variation trend to detect the approach of a medium, this is not limited to scenarios with slight reflection coefficient variations. It can also be applied to stable scenarios with significant reflection coefficient variations to detect the medium approaching the mobile phone. For example, a stable scenario with significant reflection coefficient variations can be a stable scenario with a significant reflection coefficient variation within 10mm of the mobile phone antenna.

[0404] Optionally, after the mobile phone detects the same trend of change in the reflection coefficient and determines that there is a medium approaching the mobile phone, if the mobile phone continues to collect the trend of change in the reflection coefficient, and the trend of change relative to the medium approaching the mobile phone becomes smaller (for example, the amplitude and phase change of the sampling point relative to the reference point becomes smaller), or the reflection coefficient cannot be detected, the mobile phone can determine that the medium is moving away from the mobile phone.

[0405] Optionally, combined Figure 4b , this application provides Example 7;

[0406] In scenarios where the reflection coefficient changes slightly, for example, when the distance between the medium and the antenna is outside the preset distance threshold (for example, 10 mm), the relative amplitude change between the two sampling points is small when the medium approaches or moves away from the phone. This makes it difficult for the phone to accurately detect the medium's approach or distance from the phone antenna using the method in Example 5.

[0407] As the medium moves closer to or further away from the phone antenna, the antenna's sampling point (i.e., the reflection coefficient) at each time t may change. Therefore, the sampling point can be considered a function of time t. Similarly, the relative amplitude (i.e., |Δ|) also changes with time, so |Δ| is also a function of time t. Therefore, d|Δ| / dt can be used to express the time derivative of the amplitude change at the sampling point relative to the reference point.

[0408] Although Δ changes slightly over time in scenarios where the reflection coefficient changes slightly, the derivative of |Δ| with respect to time t, d|Δ| / dt, changes significantly over time. Therefore, the phone can detect whether the medium is approaching or moving away from the phone by measuring the derivative of the relative amplitude (i.e., |Δ|) of the sampling point relative to the reference point over a period of time, d|Δ| / dt. If d|Δ| / dt > 0, it indicates that the change trend of multiple sampling points is the same, confirming that the medium is approaching the phone antenna. If d|Δ| / dt < 0, it indicates that the medium is moving away from the phone antenna.

[0409] Exemplarily, the multiple sampling points (ie, multiple reflection coefficients) collected here are at the same operating frequency as the reference point of the antenna 1. The reference point may be a reflection coefficient of the antenna 1 in the FS state.

[0410] Alternatively, during the short period of time when the phone's scene switches, the amplitude and phase change (i.e., Δ) of the sampling point relative to the reference point may undergo a brief micro-fluctuation, causing dΔ to undergo a brief, sudden change over time. The phone's processor can then determine whether the current scene has changed based on whether dΔ / dt undergoes a brief, sudden change over time.

[0411] In an embodiment of the present application, the mobile phone can use the changes in the time derivatives of the relative amplitudes of multiple sampling points to determine whether the medium is approaching or moving away from the mobile phone. In particular, in scenarios where the reflection coefficient changes slightly, the changes in the time derivatives of the relative amplitudes of the sampling points are more obvious than the amplitude and phase changes of the sampling points relative to the reference point, which is conducive to detecting the slight approach or slight distance of the medium in scenarios where the reflection coefficient changes slightly.

[0412] It should be noted that when a mobile phone uses the time derivative of the relative amplitude at a sampling point to determine whether the medium is approaching or moving away from the phone, it is not limited to scenarios with subtle changes in the reflection coefficient. It can also be applied to detect the medium's approach or movement away from the phone in stable scenarios with significant changes in the reflection coefficient. For example, a stable scenario with significant changes in the reflection coefficient can be a stable scenario where the distance between the medium and the phone antenna is within 10mm.

[0413] Optionally, the mobile phone may also determine whether the reflection coefficient of the mobile phone's antenna is in a stable state based on whether the detected sampling points have the same changing trend.

[0414] For example, when the mobile phone detects that the changing trends of the sampling points are the same, it can be determined that the reflection coefficient of the mobile phone's antenna is in a stable state. When the mobile phone detects that the changing trends of the sampling points are different, it can be determined that the reflection coefficient of the mobile phone's antenna is in an unstable state (i.e., a micro-motion state).

[0415] The mobile phone can then use the sampling points in a stable state to perform the scene detection described in Examples 1 to 4 (including but not limited to detection of scenes such as medium type and whether the antenna is disconnected), and use the sampling points in a stable state to detect whether a medium is approaching the mobile phone.

[0416] Optionally, combined Figure 4b , this application provides Example 8:

[0417] As described above, after the distance between the medium and the antenna exceeds a preset distance threshold (e.g., 10 mm), e.g. Figure 12 In the scenario shown in (2) where the human body is 15 mm away from the antenna, the antenna's reflection coefficient changes slightly. The phone cannot distinguish the scenario by the amplitude and phase changes of a single sampling point relative to the reference point. However, when a medium approaches the phone, the antenna's reflection coefficient may fluctuate slightly. The phone can then determine whether the reflection coefficient has fluctuated slightly by detecting the fluctuations in the amplitude and phase changes of the sampling point relative to the reference point, thereby determining whether a medium is approaching the phone.

[0418] Among them, the micro-motion (ie, weak movement) scenario can be used to represent a scenario with little impact on the antenna near field (ie, a weak change in reflection coefficient).

[0419] For example, please refer to Figure 11 and Figure 12 In this example, the reference point is a reflection coefficient of antenna 1 when the mobile phone is in FS state. The sampling point and the reference point are at the same operating frequency of antenna 1.

[0420] For example, Figure 11 The curve 506 in FIG. Figure 12 (2) shows the amplitude change of the sampling point relative to the reference point in the scenario where the mobile phone is held but the hand is far from the antenna, and the trajectory of the change over time. From curve 506, it can be seen that in the scenario where the mobile phone is held but the hand is far from the mobile phone antenna, the amplitude change of the sampling point relative to the reference point fluctuates greatly over time, and the reflection coefficient may fluctuate slightly (in a slightly fluctuating state, that is, an unstable state). For example, the above fluctuations can be reflected by variance. Then, the mobile phone can detect that the variance of the amplitude and phase change of the sampling point relative to the reference point is greater than or equal to the preset variance threshold, and determine that the reflection coefficient of the antenna has fluctuated slightly, thereby determining that there is a medium close to the mobile phone.

[0421] It should be noted that the scene where the reflection coefficient slightly changes can be any scene where a medium is close to the mobile phone and causes the reflection coefficient to slightly change. The scene of slight change is not limited to Figure 12 The scenario shown in (2) is that the hand is holding the mobile phone and the hand is far away from the antenna. It may also include but is not limited to the scenario that the hand approaches the mobile phone antenna from a distance (for example, greater than 10 mm), causing the reflection coefficient to fluctuate slightly, or the scenario that the mobile phone is placed in the user's pocket and the person moves, causing the reflection coefficient to fluctuate slightly.

[0422] For example, Figure 11 The curve 505 in FIG. 5 represents Figure 12 (1) shows the amplitude change of the sampling point relative to the reference point in the scenario of the mobile phone in the FS state without a case. The change trajectory over time is shown. From curve 505, it can be seen that in the FS state, the amplitude change of the sampling point relative to the reference point fluctuates slightly over time, and the reflection coefficient does not fluctuate slightly, that is, the reflection coefficient is in a stable state. The mobile phone can then detect that the variance of the amplitude and phase change of the sampling point relative to the reference point is less than the preset variance threshold, and determine that the reflection coefficient of the antenna has not fluctuated slightly and that the reflection coefficient is in a stable state.

[0423] Optionally, the mobile phone can also determine the fluctuation size of the amplitude change by whether the standard deviation of the amplitude change of the sampling point relative to the reference point is greater than or equal to a preset standard deviation threshold, and then determine whether the reflection coefficient has micro-moved.

[0424] Exemplarily, if the mobile phone detects that the standard deviation of the amplitude change is greater than or equal to a preset standard deviation threshold, the mobile phone can determine that the fluctuation of the amplitude change meets the preset fluctuation condition, thereby determining that the reflection coefficient has slightly fluctuated.

[0425] Exemplarily, if the mobile phone detects that the standard deviation of the amplitude change is less than a preset standard deviation threshold, the mobile phone may determine that the fluctuation of the amplitude change does not meet the preset fluctuation condition, thereby determining that the reflection coefficient has slightly fluctuated.

[0426] For example, Figure 11 As shown, in curve 505, the antenna's reflection coefficient is in a stable state. The reflection coefficient is primarily affected by coefficient measurement errors and varies steadily. The processor calculates that the standard deviation of the relative amplitude of the reflection coefficient in curve 505 is approximately 7*1e-4. In contrast, in curve 506, the antenna's reflection coefficient is in an unstable state (i.e., a micro-vibration state), with significant variations in the reflection coefficient. The processor calculates that the standard deviation of the relative amplitude of the reflection coefficient in curve 506 is approximately 2e-3.

[0427] For example, the mobile phone can detect the standard deviation of the collected reflection coefficient relative to a reference point. If the standard deviation is greater than or equal to a preset standard deviation threshold, the mobile phone can determine that the reflection coefficient of the antenna is slightly fluctuating, thereby confirming that a medium is approaching the mobile phone. If the standard deviation is less than the preset standard deviation threshold, the reflection coefficient is stable and has not slightly fluctuated, thereby confirming that no medium is approaching the mobile phone.

[0428] also, Figure 11 The amplitude change of the sampling point relative to the reference point is used as an example for explanation, but in other embodiments, Figure 11 The principle is similar to that of the CMOS. The mobile phone can determine whether the amplitude-phase change meets the preset fluctuation condition by detecting whether the variance or standard deviation of the phase change of the sampling point relative to the reference point is greater than the preset variance threshold or preset standard deviation threshold about the phase, thereby determining whether the reflection coefficient has micro-movement.

[0429] For example, the fluctuation information of the amplitude and phase change of the sampling point relative to the reference point that satisfies the preset fluctuation conditions may include but is not limited to:

[0430] The variance of the amplitude and phase changes of the sampling point relative to the reference point is greater than or equal to a preset variance threshold; and / or,

[0431] The standard deviation of the amplitude and phase changes of the sampling point relative to the reference point is greater than or equal to the preset standard deviation threshold.

[0432] For example, the mobile phone processor can determine whether the reflection coefficient is slightly fluctuating based on the fluctuation information of multiple sampling points relative to the reference point, so that when it is determined that the reflection coefficient is slightly fluctuating, it can be determined that a medium is close to the mobile phone.

[0433] For example, the mobile phone processor can detect the fluctuation information (variance or standard deviation) of a set of collected sampling points. When the fluctuation information meets the preset conditions, the processor can determine that the reflection coefficient is slightly moving, thereby determining that there is a medium approaching the mobile phone; when the fluctuation information does not meet the preset conditions, the processor can determine that the reflection coefficient is not slightly moving, that is, the reflection coefficient is in a stable state, and the processor can determine that there is no medium approaching the mobile phone.

[0434] Exemplarily, the stable state here may include but is not limited to: FS state, a stable state in which the medium is close to the mobile phone antenna so that the reflection coefficient of the antenna changes steadily (for example, a scenario in which the medium is within 10 mm close to the mobile phone), etc.

[0435] It should be noted that Figure 11 The horizontal axis and Figure 10 The meaning of the horizontal axis is the same as that of , which will not be repeated here. The vertical axis y represents the amplitude change of the sampling point relative to the reference point.

[0436] This application takes into account the high accuracy of reflection coefficient detection. In some scenarios (such as scenarios where the reflection coefficient changes slightly), when the reflection coefficient change caused by the medium (such as the human body) approaching the antenna is small, in scenarios where the reflection coefficient causes micro-fluctuations, the fluctuation of the reflection coefficient (i.e., the variance or standard deviation) is obvious relative to the detection accuracy. In this case, the mobile phone can use the fluctuation of the reflection coefficient to detect whether the reflection coefficient has micro-fluctuated, thereby determining whether there is a medium approaching the mobile phone antenna. Among them, when the mobile phone detects micro-fluctuations in the reflection coefficient, it can determine that there is a medium approaching the mobile phone antenna.

[0437] It should be noted that when a mobile phone uses the fluctuation information of multiple sampling points relative to a reference point to determine whether there has been a slight fluctuation in the reflection coefficient, thereby determining whether a medium is approaching the mobile phone, the method is not limited to scenarios with slight fluctuations in the reflection coefficient. It can also be applied to detect the presence of a medium in stable scenarios with significant fluctuations in the reflection coefficient. For example, a stable scenario with significant fluctuations in the reflection coefficient can be a stable scenario where the reflection coefficient fluctuates significantly when the distance between the medium and the mobile phone antenna is within 10mm.

[0438] Optionally, the mobile phone may also determine whether the reflection coefficient of the mobile phone's antenna is in a stable state based on the detected fluctuations of multiple reflection coefficients.

[0439] Considering that the reflection coefficient is stable when the medium is close to the mobile phone antenna within a preset distance threshold, when the mobile phone is in a case, or when the antenna is disconnected, the mobile phone can obtain sampling points to determine the medium type, or the antenna is disconnected, or when the mobile phone is in a case, etc. when detecting that the reflection coefficient of the antenna is in a stable state, which can improve the accuracy of scene detection.

[0440] In this example, a schematic diagram of the phase change of the sampling point relative to the reference point is not shown. It can be understood that in a scenario where the reflection coefficient slightly fluctuates and the medium is close to the mobile phone, the fluctuation of the phase change of the sampling point relative to the reference point over time is also greater than the fluctuation of the phase change of the sampling point relative to the reference point over time when the antenna reflection coefficient is in a stable state.

[0441] Exemplarily, the fluctuation of the amplitude change of the sampling point relative to the reference point can be used to determine whether there is a medium close to the mobile phone antenna. Optionally, the fluctuation of the phase change of the sampling point relative to the reference point can be further combined to determine whether there is a medium close to the mobile phone antenna.

[0442] In an embodiment of the present application, the processor can combine the fluctuation (variance or standard deviation) of the reflection coefficient relative to the reference point, and / or the stability of the change trend of the reflection coefficient (i.e., whether the change trend is the same) to detect whether there is a medium approaching in a scenario where the reflection coefficient changes slightly or significantly. In addition, for scenarios where the detection and recognition accuracy requirements are not high, the processor can also combine the fluctuation (variance or standard deviation) of the reflection coefficient relative to the reference point, and / or the change trend of the reflection coefficient to detect whether the reflection coefficient of the antenna is in a stable state. The processor of the embodiment of the present application performs scene detection through the change trend of the reflection coefficient in the time dimension and the change fluctuation in the time dimension, thereby improving the scene recognition capability of the mobile phone.

[0443] It should be noted that the scenarios in which the reflection coefficient changes slightly as detected in the embodiments of the present application include not only the scenarios in which the distance between the medium and the antenna is greater than a preset distance threshold (e.g., 10 mm) as exemplified above, but also scenarios in which the reflection coefficient changes slightly may include, but are not limited to, the following scenarios:

[0444] Scenario 1: Antenna 1 is installed on the side of the phone. The radiation intensity of antenna 1 to the front and back of the phone is weak. As a result, the reflection coefficient of the antenna changes slightly when the medium approaches the phone from the front or back.

[0445] Scenario 2: Antenna solutions for electronic devices are continuously improving towards low SAR. As a result, when a person is close to the antenna, the reflection coefficient does not change significantly. Therefore, when a person is close to a low-SAR electronic device, the antenna's reflection coefficient also changes slightly.

[0446] For any scenario where the reflection coefficient changes slightly, the mobile phone can detect that a medium is approaching the mobile phone by using the same trend of change or unstable fluctuation of the reflection coefficient.

[0447] Furthermore, it should be noted that if the mobile phone detects that the antenna's reflection coefficient is in a micro-motion state (i.e., unstable state), and if the mobile phone detects that the medium near the mobile phone is a human body, then, based on the current antenna transmit power, power backoff is determined to be necessary. The antenna's transmit power may be backed off by the power backoff amount corresponding to the preset distance threshold (e.g., 10 mm).

[0448] Figure 4c A process of refreshing a reference point is shown as an example. Figure 4c The process can be Figure 4a is implemented in S101. Figure 4c The process may include: S301, S302 and S303.

[0449] S301: The processor obtains multiple sampling points within a second preset time period.

[0450] As mentioned above, the sampling point is the reflection coefficient sampled from the antenna.

[0451] For example, considering that the reflection coefficient of the antenna can remain stable for a long time when the mobile phone is in a case, the mobile phone processor can obtain multiple reflection coefficients of antenna 1 within a second preset time period (referred to as "long time") to track the reflection coefficient of antenna 1 for a long time.

[0452] S302: The processor determines whether the reflection coefficient of the antenna is in a stable state based on the multiple sampling points obtained within the second preset time period.

[0453] Optionally, the processor may periodically execute S301. For example, the processor may sample the antenna reflection coefficient within a fixed time period every day, such as one hour from 3 a.m. to 4 a.m. every day (i.e., the second preset time length), to obtain multiple sampling points, and use the multiple sampling points to determine whether the sampling points of the antenna (i.e., the reflection coefficient) are in a stable state during the time period from 3 a.m. to 4 a.m.

[0454] For example, the processor may track the reflection coefficient of antenna 1 for a long period of time according to a second preset duration to determine whether the reflection coefficient of the antenna is in a stable state within the second preset duration. Within the second preset duration, the processor may collect the reflection coefficient multiple times to obtain multiple sampling points. In other words, the processor may collect the reflection coefficient in real time and determine whether the reflection coefficient of the antenna is in a stable state based on the real-time collected reflection coefficient.

[0455] Exemplarily, the manner in which the processor determines that the reflection coefficient of the antenna is in a stable state based on the multiple reflection coefficients acquired within the second preset time period may include but is not limited to: manner 1 and manner 2.

[0456] In mode 1, the processor determines whether the reflection coefficient of the antenna is in a stable state based on long-term fluctuation information of multiple reflection coefficients obtained within a second preset time period.

[0457] Exemplarily, the processor detects that the variance (or standard deviation) of the multiple sampling points obtained is less than the preset variance threshold (or the preset standard deviation threshold), indicating that the reflection coefficient of the antenna is in a stable state during the target time period corresponding to the multiple sampling points in this cycle. The target time period here can be all or part of the time period corresponding to the second preset duration. In other words, although the mobile phone checks whether the reflection coefficient of the mobile phone antenna is in a stable state from 3 to 4 a.m. every day, it is not necessarily the case that the reflection coefficient of the mobile phone antenna is in a stable state during the entire time period from 3 to 4 a.m., and the mobile phone antenna may be in a stable state during part of the time period. The processor can find the target time period in which the reflection coefficient is in a stable state within the second preset duration, thereby using the multiple sampling points within the target time period to refresh the reference point.

[0458] For example, the processor may track the antenna's reflection coefficient in real time over a second preset time period, calculate the dynamic variance of the collected reflection coefficient in real time, and determine whether the variance of the reflection coefficient is within a preset variance threshold. If the processor detects that the variance of the reflection coefficient collected between 3:00 a.m. and 3:30 a.m. is within the preset variance threshold, but the variance of the reflection coefficient collected between 3:00 a.m. and 3:31 a.m. is greater than the preset variance threshold, the processor may determine that the antenna's reflection coefficient is stable during 3:00 a.m. to 3:30 a.m. (i.e., the target time period).

[0459] Exemplarily, the processor detects that the variance (or standard deviation) of the multiple sampling points obtained is greater than or equal to the preset variance threshold (or the preset standard deviation threshold), indicating that the reflection coefficient of the antenna is in an unstable state (i.e., a dynamic state) during the target time period corresponding to the multiple sampling points within the second preset time length, such as the medium micro-motion scenario described above.

[0460] In mode 2, the processor determines whether the reflection coefficient of the antenna is in a stable state according to the difference between the maximum value and the minimum value of multiple reflection coefficients over a long period of time.

[0461] Exemplarily, the processor detects that the difference between the maximum value of the reflection coefficient and the minimum value of the reflection coefficient among the multiple reflection coefficients obtained is less than a preset threshold, indicating that the difference between the multiple reflection coefficients obtained is small. The processor can determine that the reflection coefficient of the antenna is in a stable state within the time period corresponding to the multiple reflection coefficients within the second preset time length.

[0462] Exemplarily, the processor detects that the difference between the maximum value of the reflection coefficient and the minimum value of the reflection coefficient among the multiple reflection coefficients obtained is greater than or equal to the preset threshold, indicating that the differences between the multiple reflection coefficients obtained are large. The processor can determine that within the target time period corresponding to the multiple reflection coefficients within the second preset time length, the reflection coefficient of the antenna is in an unstable state.

[0463] S303: When the processor detects that the plurality of sampling points of the antenna are in a stable state, the processor refreshes the reference point based on the sampling points in the stable state.

[0464] Exemplarily, for a target time period in which the reflection coefficient of the antenna detected by the processor is in a stable state, the processor may randomly select a reflection coefficient from the reflection coefficients collected within the target time period as a first reference point; the processor may calculate the amplitude and phase changes between the first reference point and the initially set reference point (for example, a reflection coefficient in the FS state obtained in S101); if the processor detects that the amplitude and phase changes are greater than a preset reflection coefficient threshold (which may include an amplitude threshold and a phase threshold), for example, the processor switches from a non-shell state to a shell state, indicating that the reference point needs to be refreshed, the processor may update the reference point to the first reference point.

[0465] Optionally, if the processor detects that the amplitude and phase changes between the first reference point and the initially set reference point are less than or equal to the preset reflection coefficient threshold (which may include an amplitude threshold and a phase threshold), it indicates that there is no need to refresh the reference point.

[0466] In the embodiment of the present application, the reflection coefficient of the antenna is different when the mobile phone is not in the case and when the mobile phone is in the case; and the reflection coefficient of the antenna is also different when the mobile phone is in the case of different media. Figure 4a As can be seen from the process of the embodiment, the mobile phone processor needs to perform scene detection based on reference points. To improve the accuracy of scene detection, the mobile phone can periodically determine the time period when the antenna's reflection coefficient is in a stable state (where the case is a stable state) and use the reflection coefficient in the stable state during this time period to refresh the reference point. This allows the mobile phone to use the latest reference point for scene detection.

[0467] For example, the mobile phone can use the reflection coefficient in the FS state as a reference point to detect the scene in which the mobile phone is located based on the amplitude and phase changes of the sampling point relative to the reference point. For example, when the mobile phone switches from the FS state (i.e., the state without a case) to the state with a case, the reflection coefficient of the antenna is relatively stable. Then, the mobile phone can refresh the reference point when the reflection coefficient of the antenna is stable, thereby using the reflection coefficient of the mobile phone in the state with a case and no other medium close to it as the updated reference point. In this way, the mobile phone can use the updated reference point (such as the reflection coefficient in the state with a case) to detect the scene in which the mobile phone is located. Figure 4a The process described in the embodiment re-detects the scene in which the mobile phone is located based on the amplitude and phase changes of each re-sampled sampling point relative to the updated reference point.

[0468] Exemplary detection scenarios may include, but are not limited to, determining the type of media near the phone, whether the antenna is disconnected, the relative position of the media and the phone, the distance between the media and the phone, whether the phone is in a case, and the material of the case. A scenario where the phone is in a case may include a scenario where the distance between a metal or plastic medium and the phone antenna is 0 mm.

[0469] It should be noted that in the above Figure 4a In the embodiment, when the processor executes S105 to determine the scene in which the mobile phone is located based on the amplitude and phase changes of each sampling point relative to the reference point, regardless of whether the reflection coefficient of the mobile phone's antenna is in a stable state or an unstable state (i.e., a micro-motion state), the mobile phone of the embodiment of the present application can detect any one of the scenes in Examples 1 to 4 above.

[0470] For example, the mobile phone processor may use the amplitude and phase changes of the sampling points relative to the reference points in a stable state to determine the scene in which the mobile phone is located.

[0471] For example, when a phone is in a case or has an antenna disconnected, the reflection coefficient changes significantly in stable states. Therefore, compared to using sampling points when the reflection coefficient is in an unstable state to detect whether the phone is in a case or has an antenna disconnected, the phone uses sampling points when the reflection coefficient is in a stable state to detect whether the phone is in a case or has an antenna disconnected. This has higher scene detection accuracy.

[0472] Optionally, the processor may perform scene detection using sampling points where the reflection coefficient of the antenna is in an unstable state.

[0473] For example, the mobile phone processor may use the amplitude and phase changes of the sampling points in an unstable state relative to the reference point to determine the scene in which the mobile phone is located.

[0474] For example, if the mobile phone is a foldable screen mobile phone, the mobile phone can use the amplitude and phase changes of multiple sampling points in an unstable state (i.e., a micro-motion state) relative to a reference point to determine the medium type. For example, when the medium type is determined to be a mobile phone screen, it can be determined that it is a scene of a folded mobile phone screen. When the medium type is determined to be a human body, it can be determined that it is a scene of a human body approaching the mobile phone. The processor can thus use the sampling points in the micro-motion state to distinguish between the scene of a folded mobile phone screen and the scene of a human body approaching the mobile phone.

[0475] In an embodiment of the present application, the mobile phone can track the reflection coefficient of the antenna for a long time, determine the time period when the reflection coefficient of the antenna is in a stable state, and use the sampling points within this time period to obtain a first reference point. Then, when the state of the mobile phone deviates from the state when it was shipped from the factory (for example, the mobile phone is wearing a case), the mobile phone can use the first reference point to refresh the initial reference point, thereby achieving periodic refreshing of the reference point. In actual applications, users may wear a case when using their mobile phones, and may regularly change the case to a different material. Then, the mobile phone of the embodiment of the present application can achieve self-calibration and update of the reference point when the user wears or updates the case while using the mobile phone, thereby using the updated reference point for scene detection, and can achieve dynamic adaptation of scene detection in different scenarios.

[0476] It should be noted that Figures 6 to 9 、 Figure 12 The same reference numerals in the figures represent the same objects, therefore, the reference numerals in the figures are not explained one by one. Figures 7 to 9 as well as Figure 12 Reference numerals not mentioned herein may be referred to Figure 6 The explanation of the same figure marks in the figure will not be repeated here.

[0477] Optionally, for each scene detected by the mobile phone, there may be overlap in the amplitude and phase threshold ranges between different scenes. Therefore, when detecting the scene in which the mobile phone is located based on the amplitude and phase threshold ranges, multiple scenes may be detected based on sampling points within a period of time. Then, when the mobile phone processor executes the above S105 to determine the scene in which the mobile phone is located based on the amplitude and phase changes of at least one sampling point relative to a reference point, if the mobile phone detects that the mobile phone is in scene A at a target time point within a period of time as the scene in which the mobile phone is located, then when continuing to perform scene detection based on sampling points after the target time point, if the mobile phone detects scene B that is exclusive of scene A, scene B can be excluded from being the scene in which the mobile phone is located; conversely, for the same period of time, when continuing to perform scene detection based on sampling points after the target time point, if the mobile phone detects scene C that is compatible with scene A, scene C can also be considered as the scene in which the mobile phone is located.

[0478] For example, if a mobile phone detects that the antenna is in a stable state during a target time period, it can use the sampling points in the stable state to perform scene detection. If the mobile phone detects a first scene during the target time period, the first scene can be used as the scene the phone is in. A second scene subsequently detected during the target time period that is inconsistent with the first scene can be excluded and not used as the scene the phone is in. Conversely, a third scene subsequently detected during the target time period that is compatible with the first scene can be used as the scene the phone is in, thereby enhancing the accuracy of scene detection.

[0479] For example, if the FS scene, the phone in a case scene, and the phone placed horizontally on a table scene are detected in sequence during the target time period, the phone in a case scene is incompatible with the FS scene and can be excluded as the phone's scene. The horizontally placed table scene is compatible with the FS scene and can be retained. This confirms that the phone is in the horizontally placed table scene, preventing scene interference that could lead to scene detection errors and improving scene detection accuracy.

[0480] For example, the mobile phone can configure the compatibility relationship and the exclusive relationship between different scenes. The mobile phone can use the pre-configured compatibility relationship and the exclusive relationship between scenes to retain and exclude scenes.

[0481] In the above embodiment, a single reference point is used as an example to describe the solution for a mobile phone to detect the scene in which it is located. In a possible implementation, the mobile phone can also be configured with multiple reference points, and use the multiple reference points and the multiple sampling points collected to detect the scene in which the mobile phone is located. Figure 4d FIG. 1 is a flow chart showing an exemplary electronic device detection scenario according to an embodiment of the present application. Figure 4d As shown, the process may include S401, S402, and S403.

[0482] S401: The processor sets multiple reference points according to the scene in which the mobile phone is located.

[0483] Exemplarily, the processor may select the reflection coefficient of the mobile phone antenna in each scenario as a reference point for the corresponding scenario according to the scenario in which the mobile phone is located when the mobile phone antenna is in a stable state.

[0484] For example, the processor selects a reflection coefficient of the antenna in the FS state as the reference point of the FS scenario, selects a reflection coefficient of the antenna in the scenario where the mobile phone has a plastic case as the plastic case reference point, and selects a reflection coefficient of the antenna in the scenario where the mobile phone has a metal case as the metal case reference point.

[0485] S402: The processor obtains multiple sampling points.

[0486] S403: The processor determines the scene where the mobile phone is located based on the amplitude and phase changes of the multiple sampling points relative to each reference point.

[0487] Exemplarily, the processor is provided with three reference points for the above three scenarios.

[0488] For any reference point, the processor can determine the amplitude and phase differences (i.e., amplitude and phase differences, including amplitude and phase differences) between the multiple sampling points and the reference point based on the amplitude and phase changes of the multiple sampling points relative to the reference point. This can then yield three amplitude and phase differences corresponding to the three reference points. The processor can then determine the scene corresponding to the reference point with the smallest of the three amplitude and phase differences as the scene the phone is in.

[0489] Exemplarily, when the processor determines the amplitude and phase differences between the multiple sampling points and the reference point based on the amplitude and phase changes of the multiple sampling points relative to the reference point, the processor may use the average of the multiple amplitude and phase changes corresponding to the multiple sampling points as the amplitude and phase difference between the multiple sampling points and the reference point.

[0490] Among them, the amplitude-phase difference between multiple sampling points and the reference point expresses the amplitude-phase change between the multiple sampling points and the reference point. Therefore, the method of determining the amplitude-phase difference is not limited to the scheme of taking the average, and may also include other schemes not listed, which are not limited in this application.

[0491] Optionally, when the processor is provided with multiple reference points, the mobile phone Figure 4c When refreshing the reference point by using the method, the processor can refresh the reference point according to the sampling point in the stable state when executing S303. Figure 4d The solution is used to determine the target scene that the mobile phone is in, such as the scene where the mobile phone is in a plastic shell. Then, the processor refreshes the reference point corresponding to the target scene among the multiple reference points based on the sampling point in the stable state, such as the plastic shell reference point.

[0492] It is understandable that, in order to implement the above functions, the electronic device includes hardware and / or software modules that perform the corresponding functions. In combination with the algorithm steps of each example described in the embodiments disclosed herein, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is executed in the form of hardware or computer software driving hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application in combination with the embodiments, but such implementation should not be considered to be beyond the scope of this application.

[0493] In one example, Figure 13 A schematic block diagram of an apparatus 300 according to an embodiment of the present application is shown. The apparatus 300 may include: a processor 301 and a transceiver / transceiver pin 302 , and optionally, a memory 303 .

[0494] The various components of the device 300 are coupled together via a bus 304, wherein the bus 304 includes, in addition to a data bus, a power bus, a control bus, and a status signal bus. However, for the sake of clarity, the various buses are collectively referred to as bus 304 in the figure.

[0495] Optionally, the memory 303 may be used for instructions in the aforementioned method embodiment. The processor 301 may be used to execute instructions in the memory 303 and control the receiving pin to receive a signal and control the transmitting pin to send a signal.

[0496] The apparatus 300 may be the electronic device or a chip of the electronic device in the above method embodiment.

[0497] Among them, all relevant contents of each step involved in the above method embodiment can be referred to the functional description of the corresponding functional module and will not be repeated here.

[0498] This embodiment further provides a computer storage medium, which stores computer instructions. When the computer instructions are executed on an electronic device, the electronic device executes the above-mentioned related method steps to implement the scene recognition method in the above-mentioned embodiment.

[0499] This embodiment further provides a computer program product. When the computer program product is run on a computer, it enables the computer to execute the above-mentioned related steps to implement the scene recognition method in the above-mentioned embodiment.

[0500] In addition, an embodiment of the present application also provides a device, which can specifically be a chip, component or module, and the device may include a connected processor and memory; wherein the memory is used to store computer-executable instructions, and when the device is running, the processor can execute the computer-executable instructions stored in the memory to enable the chip to execute the scene recognition method in the above-mentioned method embodiments.

[0501] Among them, the electronic device, computer storage medium, computer program product or chip provided in this embodiment is used to execute the corresponding method provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding method provided above, and will not be repeated here.

[0502] Through the description of the above implementation methods, technical personnel in the relevant field can understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example. In actual applications, the above-mentioned functions can be distributed and completed by different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.

[0503] In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of modules or units is only a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0504] Units described as separate components may or may not be physically separate, and components shown as units may be one physical unit or multiple physical units, that is, they may be located in one place or distributed in multiple places. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.

[0505] In addition, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.

[0506] Any content of each embodiment of this application, as well as any content of the same embodiment, can be freely combined. Any combination of the above content is within the scope of this application.

[0507] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solution of the embodiment of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for enabling a device (which can be a single-chip microcomputer, chip, etc.) or a processor (processor) to execute all or part of the steps of the various embodiments of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0508] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of this application, ordinary technicians in this field can also make many forms without departing from the purpose of this application and the scope of protection of the claims, all of which are within the protection of this application.

[0509] The steps of the method or algorithm described in conjunction with the disclosure of the embodiments of the present application can be implemented in a hardware manner, or can be implemented by a processor executing a software instruction. The software instruction can be composed of corresponding software modules, and the software module can be stored in a random access memory (Random Access Memory, RAM), a flash memory, a read-only memory (Read Only Memory, ROM), an erasable programmable read-only memory (Erasable Programmable ROM, EPROM), an electrically erasable programmable read-only memory (Electrically EPROM, EEPROM), a register, a hard disk, a mobile hard disk, a read-only compact disc (CD-ROM) or any other form of storage medium well known in the art. An exemplary storage medium is coupled to the processor so that the processor can read information from the storage medium and can write information to the storage medium. Of course, the storage medium can also be a component of the processor. The processor and the storage medium can be located in an ASIC.

[0510] Those skilled in the art will appreciate that in one or more of the above examples, the functions described in the embodiments of the present application 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 codes on a computer-readable medium. Computer-readable media include computer storage media and communication media, wherein communication media include any media that facilitates the transmission of computer programs from one place to another. The storage medium can be any available medium that can be accessed by a general-purpose or special-purpose computer.

[0511] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of this application, ordinary technicians in this field can also make many forms without departing from the purpose of this application and the scope of protection of the claims, all of which are within the protection of this application.

Claims

1. A scene recognition method, characterized in that: Applied to an electronic device, wherein the electronic device includes a first antenna, the method includes: Obtain at least one first reflection coefficient of the first antenna at a first operating frequency, wherein the first reflection coefficient includes an amplitude and a phase; determining a first amplitude difference and a first phase difference according to the first reflection coefficient and a first preset reflection coefficient; Determining a first medium type of a first medium based on a first amplitude threshold range within which the first amplitude difference value lies and a first phase threshold range within which the first phase difference value lies, the first medium being a medium located near the electronic device, or determining whether the first antenna is in a disconnected state; The method further comprises: Determining, according to a second mapping relationship between relative positions and amplitude and phase threshold ranges, a second amplitude threshold range that matches the first amplitude difference and a second phase threshold range that matches the first phase difference, wherein the amplitude and phase threshold ranges include an amplitude threshold range and a phase threshold range; Based on the second mapping relationship, the target relative position matching both the second amplitude threshold range and the second phase threshold range is determined as the relative position relationship between the first medium and the electronic device.

2. The method according to claim 1, characterized in that The method further comprises: Based on a first mapping relationship between distance ranges and amplitude threshold ranges, a first distance range matching the first amplitude difference is determined as the distance range between the first medium and the electronic device.

3. The method according to claim 1, characterized in that The number of the at least one first reflection coefficient is multiple; After determining, based on the second mapping relationship, the target relative position that matches both the second amplitude threshold range and the second phase threshold range as the relative position relationship between the first medium and the electronic device, the method further includes: It is detected that the target relative positions corresponding to the plurality of first reflection coefficients are the same, and it is determined that the first medium is approaching or moving away from the electronic device from the target relative position.

4. The method according to any one of claims 1 to 3, characterized in that The method further comprises: Acquiring a plurality of second reflection coefficients of the first antenna at the first operating frequency, wherein each of the second reflection coefficients includes an amplitude and a phase; determining a plurality of second amplitude differences and a plurality of second phase differences according to each of the second reflection coefficients and a second preset reflection coefficient; It is detected that the change trends of the multiple second amplitude differences are the same as those of the multiple second phase differences, and it is determined that there is a medium approaching the electronic device.

5. The method according to claim 4, characterized in that The detecting that the plurality of second amplitude differences have the same changing trend as the plurality of second phase differences, and determining that a medium is close to the electronic device, includes: It is detected that the multiple second amplitude difference values ​​are all greater than the first amplitude threshold, and the multiple second phase difference values ​​are all greater than the first phase threshold, and it is determined that there is a medium approaching the electronic device.

6. The method according to claim 4, characterized in that The detecting that the plurality of second amplitude differences have the same changing trend as the plurality of second phase differences, and determining that a medium is close to the electronic device, includes: detecting that the plurality of second amplitude differences continuously increase or continuously decrease in a sampling time sequence, and determining that the plurality of second amplitude differences have the same change trend; detecting that the plurality of second phase difference values ​​continuously increase or continuously decrease in the sampling time sequence, and determining that the plurality of second phase difference values ​​have the same change trend; It is detected that the change trends of the multiple second amplitude differences are the same, and it is detected that the change trends of the multiple second phase differences are the same, and it is determined that there is a medium approaching the electronic device.

7. The method according to any one of claims 1 to 3, characterized in that The method further comprises: Acquire a plurality of second reflection coefficients of the first antenna at the first operating frequency, wherein each of the second reflection coefficients includes an amplitude and a phase; determining a plurality of second amplitude differences and a plurality of second phase differences according to each of the second reflection coefficients and a second preset reflection coefficient; determining derivatives of the plurality of second amplitude differences with respect to sampling times of the plurality of second reflection coefficients; When it is detected that the derivative is greater than zero, it is determined that a medium is close to the electronic device.

8. The method according to claim 7, characterized in that After determining the derivatives of the plurality of second amplitude differences with respect to the sampling times of the plurality of second reflection coefficients, the method further includes: It is detected that the derivative is less than zero, and it is determined that there is a medium moving away from the electronic device.

9. The method according to any one of claims 1 to 3, characterized in that The method further comprises: Acquire a plurality of third reflection coefficients of the first antenna at the first operating frequency, wherein each of the third reflection coefficients includes an amplitude and a phase; determining a plurality of third amplitude differences and a plurality of third phase differences according to each of the third reflection coefficients and a third preset reflection coefficient; It is detected that the fluctuation information of the plurality of third amplitude differences and the fluctuation information of the plurality of third phase differences meet a preset condition, and it is determined that there is a medium approaching the electronic device.

10. The method according to claim 9, characterized in that The detecting that the fluctuation information of the plurality of third amplitude differences and the fluctuation information of the plurality of third phase differences meet a preset condition and determining that a medium is close to the electronic device includes: detecting that a variance of the plurality of third amplitude difference values ​​is greater than a first preset variance threshold, and detecting that a variance of the plurality of third phase difference values ​​is greater than a second preset variance threshold, and / or, It is detected that the standard deviation of the plurality of third amplitude differences is greater than a first preset standard deviation threshold, It is determined that a medium is close to the electronic device when it is detected that a standard deviation of the plurality of third phase difference values ​​is greater than a second preset standard deviation threshold.

11. The method according to any one of claims 1 to 3, characterized in that The first medium type includes at least one of the following: Human body, metal, plastic, magnetic materials.

12. An electronic device, characterized in that: The electronic device includes at least one antenna, the at least one antenna including a first antenna, and the electronic device also includes a memory and a processor, the memory and the processor are coupled; the memory stores program instructions, and when the program instructions are executed by the processor, the electronic device executes the scene recognition method as described in any one of claims 1 to 11.

13. A computer-readable storage medium, characterized in that The method comprises a computer program. When the computer program is run on an electronic device, the electronic device comprises at least one antenna, wherein the at least one antenna comprises a first antenna, so that the electronic device executes the scene recognition method according to any one of claims 1 to 11.

14. A chip, characterized in that: The electronic device comprises one or more interface circuits and one or more processors; the interface circuit is used to receive a signal from a memory of the electronic device and send the signal to the processor, wherein the signal includes a computer instruction stored in the memory; when the processor executes the computer instruction, the electronic device executes the scene recognition method described in any one of claims 1 to 11.

Citation Information

Patent Citations

  • Electronic device and method thereof for grip recognition

    CN109643843A