WO2022022609A1 - Method for preventing inadvertent touch and electronic device - Google Patents

Method for preventing inadvertent touch and electronic device Download PDF

Info

Publication number
WO2022022609A1
WO2022022609A1 PCT/CN2021/109122 CN2021109122W WO2022022609A1 WO 2022022609 A1 WO2022022609 A1 WO 2022022609A1 CN 2021109122 W CN2021109122 W CN 2021109122W WO 2022022609 A1 WO2022022609 A1 WO 2022022609A1
Authority
WO
WIPO (PCT)
Prior art keywords
electronic device
ultrasonic
ultrasonic echo
scene
data
Prior art date
Application number
PCT/CN2021/109122
Other languages
French (fr)
Chinese (zh)
Inventor
李经纬
刘浩东
李琳
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Publication of WO2022022609A1 publication Critical patent/WO2022022609A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/02Constructional features of telephone sets
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/02Constructional features of telephone sets
    • H04M1/0202Portable telephone sets, e.g. cordless phones, mobile phones or bar type handsets
    • H04M1/026Details of the structure or mounting of specific components
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72448User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions
    • H04M1/72454User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions according to context-related or environment-related conditions
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/725Cordless telephones
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W52/00Power management, e.g. TPC [Transmission Power Control], power saving or power classes
    • H04W52/02Power saving arrangements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M2250/00Details of telephonic subscriber devices
    • H04M2250/12Details of telephonic subscriber devices including a sensor for measuring a physical value, e.g. temperature or motion
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Definitions

  • the present application relates to the field of terminals, and in particular, to a method and electronic device for preventing accidental touch.
  • the mistaken touch of the mobile phone screen will bring a bad experience to the user.
  • the call is interrupted by accidentally hitting the hang-up button; due to capacitive factors such as skin,
  • the mobile phone in the pocket or backpack is unlocked by mistake or the application is clicked by mistake, etc., which may bring public opinion or risk of withdrawal to the user. Therefore, accurate detection of the state of the mobile phone and prevention of accidental touches can improve the user experience.
  • the present application provides a method and electronic device for preventing accidental touch, which are used to solve the problem of accidental touch in use of the electronic device.
  • an embodiment of the present application provides a method for preventing accidental touch, which is applied to an electronic device, where the electronic device includes an ultrasonic transmitter and an ultrasonic receiver, wherein the method includes:
  • the ultrasonic transmitter transmits ultrasonic signals N times, each ultrasonic signal includes multiple ultrasonic signals, N is greater than or equal to 2, and N is a positive integer.
  • the ultrasonic receiver receives N times of ultrasonic echo signals, wherein one ultrasonic echo signal is generated by the reflection of one ultrasonic signal, and each ultrasonic echo signal includes a plurality of ultrasonic echo signals.
  • the electronic device may obtain first data according to each received ultrasonic echo signal, where the first data includes signal strengths and propagation times of multiple ultrasonic echo signals.
  • the electronic device may obtain the first scene type in which the electronic device is located according to the first data of the N ultrasonic echo signals.
  • the first scene type may be an occlusion scene or a non-occlusion scene. If the first scene type is a occlusion scene, the electronic device enables the anti-mistouch function.
  • the electronic device when it is detected that the electronic device is currently blocked in a pocket or a backpack, the electronic device can automatically activate the anti-mistouch function, so as to prevent the occurrence of false touches and reduce the power consumption of the electronic device, It provides users with a friendly operating environment and improves the user experience.
  • the ultrasonic transmitter and the ultrasonic receiver are arranged on the top of the electronic device, wherein the top is further provided with any one or more of the following electronic devices: an earpiece, a front-facing camera, a microphone, Proximity light sensor, ambient light sensor, etc.
  • an ultrasonic transmitter is integrated in the earpiece, or the earpiece is an ultrasonic transmitter, which can transmit ultrasonic signals.
  • an ultrasonic receiver is integrated in the microphone, or the microphone is an ultrasonic receiver, which can receive ultrasonic signals.
  • the method may further specifically include: the electronic device inputs the first data of the N times ultrasonic echo signals into the first classification model to obtain the first scene type in which the electronic device is located.
  • the first classification model is obtained by using the first training data to train the first training model, and the first training data may include S sample data, S is greater than or equal to 2, and S is a positive integer.
  • the S pieces of sample data include sample data obtained under multiple known scene types, and one sample data includes second data of N times ultrasonic echo signals generated by transmitting N times ultrasonic signals under one known scene type.
  • the second data includes information such as signal strength and propagation time of the plurality of ultrasonic echo signals.
  • Several known scene types include: unoccluded scene and occluded scene.
  • the method may further specifically include: the electronic device generates a first image from the first data of the N-th ultrasonic echo signal, and the color value of the first image represents the signal of the ultrasonic echo signal Intensity, the horizontal axis of the first image represents the receiving batch of ultrasonic echo signals, and the vertical axis of the first image can represent the transmission time from transmitting ultrasonic signals to receiving ultrasonic echo signals. Then, the electronic device inputs the first image into the first classification model, and the first scene type in which the electronic device is located can be obtained.
  • a sample data includes a second image corresponding to a known scene type
  • the second image is generated from the second data of the N times ultrasonic echo signals
  • the color value of the second image indicates that under a known scene type
  • the signal strength of the received ultrasonic echo signal, the abscissa coordinate of the second image represents the acceptance batch of ultrasonic echo signals received in a known scene type, and the vertical axis coordinate of the second image represents a known scene
  • the transmission time from the transmission of ultrasonic signals to the reception of ultrasonic echo signals.
  • the first training model may be an extreme gradient boosting XGBoost model, or a neural network NN model, or a gradient boosting decision tree GBDT model, or a random forest RF model.
  • the occluded scene may include any one or more of the following: the electronic device is located in a pocket, the electronic device is located in a bag, the electronic device is blocked by a book, the electronic device is blocked by hair, the electronic device Covered by palms, electronic devices covered by clothing, etc.
  • the anti-mistouch function includes any one or more of the following: the screen of the electronic device is turned off, the electronic device does not respond to fingerprints to unlock the screen, the electronic device does not respond to face recognition to unlock the screen, the electronic device does not respond to face recognition to unlock the screen, Respond to sliding up to unlock the screen, the electronic device does not respond to gestures to unlock the screen, the electronic device does not respond to raising the hand to brighten the screen, the electronic device does not respond to raising the hand to answer incoming calls, the electronic device does not respond to fingerprints to answer incoming calls, etc.
  • the electronic device when it is detected that the electronic device is in an entertainment scene, the electronic device turns off the anti-mistouch function, and the entertainment scene may include any one or more of the following: the electronic device plays video, plays music, runs games etc.
  • the electronic device does not enable the anti-mistouch function if the proximity light sensor does not detect that the object is blocked.
  • the electronic device if the ambient light sensor detects that the ambient light brightness is higher than the first brightness value, eg, 10 lux (lx), the electronic device does not enable the accidental touch prevention function.
  • the first brightness value eg, 10 lux (lx)
  • the ultrasonic transmitter may transmit ultrasonic signals N times at intervals of a transmission period T, and the continuous transmission time t of one ultrasonic signal is shorter than the transmission period T of the ultrasonic signal.
  • an embodiment of the present application provides an electronic device, the electronic device includes: an ultrasonic transmitter, an ultrasonic receiver, a display screen, a memory, and a processor coupled to the memory, where data and executable data are stored in the memory instruction.
  • the processor can transmit ultrasonic signals N times through the ultrasonic transmitter, each ultrasonic signal includes multiple ultrasonic signals, N is greater than or equal to 2, and N is a positive integer.
  • the processor can receive N times ultrasonic echo signals through the ultrasonic receiver, wherein, one ultrasonic echo signal is generated by the reflection of one ultrasonic signal, and each ultrasonic echo signal includes a plurality of ultrasonic echo signals.
  • the processor may also obtain first data according to each received ultrasonic echo signal, where the first data includes signal strengths and propagation times of multiple ultrasonic echo signals.
  • the processor may obtain the first scene type in which the electronic device is located according to the first data of the N ultrasonic echo signals.
  • the first scene type may be an occlusion scene or a non-occlusion scene. If the first scene type is an occlusion scene, the processor controls the display screen to enable the anti-mistouch function.
  • the electronic device when it is detected that the electronic device is currently blocked in a pocket or a backpack, the electronic device can automatically activate the anti-mistouch function, so as to prevent the occurrence of false touches and reduce the power consumption of the electronic device , provides users with a friendly operating environment and improves the user experience.
  • the ultrasonic transmitter and the ultrasonic receiver are arranged on the top of the electronic device, wherein the top is further provided with any one or more of the following electronic devices: an earpiece, a front-facing camera, a microphone, Proximity light sensor, ambient light sensor, etc.
  • an ultrasonic transmitter is integrated into the earpiece, or the earpiece is an ultrasonic transmitter, which can transmit ultrasonic signals.
  • an ultrasonic receiver is integrated in the microphone, or the microphone is an ultrasonic receiver, which can receive ultrasonic signals.
  • the processor inputs the first data of the N times ultrasonic echo signals into the first classification model to obtain the first scene type in which the electronic device is located.
  • the first classification model is obtained by using the first training data to train the first training model.
  • the first training data may include S sample data, where S is greater than or equal to 2, and S is a positive integer.
  • the S pieces of sample data include sample data obtained under multiple known scene types, and one sample data includes second data of N times ultrasonic echo signals generated by transmitting N times ultrasonic signals under one known scene type.
  • the second data includes information such as signal strength and propagation time of the plurality of ultrasonic echo signals.
  • Several known scene types include: unoccluded scene and occluded scene.
  • the processor may further specifically include: the processor generates a first image from the first data of the N times ultrasonic echo signals, and the color value of the first image represents the signal strength of the ultrasonic echo signals,
  • the abscissa coordinate of the first image represents the receiving batch of ultrasonic echo signals, and the ordinate axis coordinate of the first image may represent the transmission time from transmitting the ultrasonic signal to receiving the ultrasonic echo signal.
  • the processor inputs the first image into the first classification model, and can obtain the first scene type in which the electronic device is located.
  • a sample data includes a second image corresponding to a known scene type
  • the second image is generated from the second data of the N times ultrasonic echo signals
  • the color value of the second image indicates that under a known scene type
  • the signal strength of the received ultrasonic echo signal, the abscissa coordinate of the second image represents the acceptance batch of ultrasonic echo signals received in a known scene type, and the vertical axis coordinate of the second image represents a known scene
  • the transmission time from the transmission of ultrasonic signals to the reception of ultrasonic echo signals.
  • the first training model may be an extreme gradient boosting XGBoost model, or a neural network NN model, or a gradient boosting decision tree GBDT model, or a random forest RF model.
  • the occluded scene may include any one or more of the following: the electronic device is located in a pocket, the electronic device is located in a bag, the electronic device is occluded by a book, the electronic device is occluded by hair, the electronic device Covered by palms, electronic devices covered by clothing, etc.
  • the anti-mistouch function includes any one or more of the following: the electronic device turns off the screen, the electronic device does not respond to fingerprints to unlock the screen, the electronic device does not respond to face recognition to unlock the screen, the electronic device does not respond to face recognition to unlock the screen, Respond to sliding up to unlock the screen, the electronic device does not respond to gestures to unlock the screen, the electronic device does not respond to raising the hand to brighten the screen, the electronic device does not respond to raising the hand to answer incoming calls, the electronic device does not respond to fingerprints to answer incoming calls, etc.
  • the processor when it is detected that the processor is in an entertainment scene, the processor turns off the anti-mistouch function, and the entertainment scene may include any one or more of the following: playing video, playing music, running games, and the like.
  • the processor does not enable the anti-mistouch function if the proximity light sensor does not detect that the object is blocked.
  • the processor does not enable the false-touch prevention function if the ambient light sensor detects that the ambient light brightness is higher than the first brightness value, eg, 10 lux (lx), the processor does not enable the false-touch prevention function.
  • the first brightness value eg, 10 lux (lx)
  • the ultrasonic transmitter may transmit ultrasonic signals N times at intervals of a transmission period T, and the continuous transmission time t of one ultrasonic signal is less than the transmission period T of the ultrasonic signal.
  • an embodiment of the present application provides a computer-readable storage medium, where a computer program is stored in the computer-readable storage medium, and when the computer program runs on an electronic device, the electronic device performs the execution of the first aspect The operation corresponding to the provided method.
  • an embodiment of the present application provides a computer program product, which, when the computer program product runs on a computer, causes the computer to execute the method described in the first aspect.
  • the electronic device can accurately detect the current state.
  • the electronic device can automatically activate the anti-mistouch function, such as turning off the electronic device.
  • Screen do not respond to screen unlocking (which can include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.), do not respond to raising your hand to brighten the screen, do not respond to raising your hand to answer incoming calls, do not respond to fingerprints to answer incoming calls, turn off always on Display (always on display, AOD), etc., can prevent the occurrence of false touches and reduce the power consumption of electronic devices by transmitting ultrasonic signals at intervals, providing users with a friendly operating environment and improving user experience.
  • the ultrasonic signal can be transmitted at intervals by setting the duty ratio, which reduces the power consumption compared with the existing method of continuously measuring the distance of the ultrasonic signal to detect obstacles, and can achieve low power consumption and constant In the open state, determine whether the current electronic device is blocked.
  • the solution of the present application can effectively identify static objects around the electronic device, so that the electronic device can more effectively and accurately determine whether the current electronic device is in a blocked state in scenarios such as pockets and backpacks.
  • the use of ultrasonic sensors instead of optical proximity sensors to achieve the anti-mistouch function can also reduce the number of electronic devices in electronic devices and save the front opening of the screen, narrow the frame space of electronic devices, increase the screen ratio of electronic devices, and improve electronic devices. Dust and water resistance, etc.
  • FIG. 1 is a schematic diagram of a hardware structure of an electronic device provided by an embodiment of the present application.
  • FIG. 2 is a software structural block diagram of an electronic device provided by an embodiment of the present application.
  • 3a is a schematic diagram of the appearance of an electronic device provided by an embodiment of the present application.
  • Figure 3b is a schematic diagram of an ultrasonic emission sound field provided by an embodiment of the present application.
  • 3c is a schematic diagram of an ultrasonic echo path provided by an embodiment of the present application.
  • FIG. 4 is an example diagram of an impulse response of an ultrasonic echo signal in some scenarios provided by an embodiment of the present application.
  • FIG. 5a is a schematic diagram of a user scenario provided by an embodiment of the present application.
  • FIG. 5b is a schematic diagram of a user scenario provided by an embodiment of the present application.
  • FIG. 5c is a schematic diagram of a user scenario provided by an embodiment of the present application.
  • 6a is a schematic diagram of a user interface provided by an embodiment of the present application.
  • 6b is a schematic diagram of a user interface provided by an embodiment of the present application.
  • FIG. 7 is a flowchart of a method for preventing false touches provided by an embodiment of the present application.
  • FIG. 8 is a signal strength diagram of an ultrasonic echo signal in some scenarios provided by an embodiment of the present application.
  • FIG. 9 is a schematic diagram of a convolutional neural network algorithm provided by an embodiment of the present application.
  • FIG. 10 is a block diagram of functional modules of an electronic device for preventing accidental touches provided by an embodiment of the present application.
  • the present application provides a method and electronic device for preventing accidental touch, which are used to solve the problem of accidental touch in use of the electronic device.
  • This application is based on machine learning, by intermittently transmitting ultrasonic waves and collecting the echoes reflected by the ultrasonic waves encountering obstacles, and according to the signal characteristics of the echoes, it is detected whether the current electronic device is in a blocked state.
  • the electronic device can automatically activate the anti-mistouch mode. In the anti-mistouch mode, the electronic device does not respond to touch operations, unlock the screen, raise the hand to brighten the screen, AOD and other commands.
  • the electronic device can accurately detect whether it is currently in a blocked state, and when it is determined that the electronic device is currently blocked in a pocket or a backpack, the electronic device can automatically activate the anti-mistouch function, such as the electronic device Turn off the screen, do not respond to screen unlocking (which can include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.), do not respond to raising your hand to brighten the screen, do not respond to raising your hand to answer incoming calls, turn off AOD, etc., to prevent false positives.
  • screen unlocking which can include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.
  • do not respond to raising your hand to brighten the screen do not respond to raising your hand to answer incoming calls, turn off AOD, etc.
  • the occurrence of a touch situation and the power consumption of the electronic device are reduced, a user-friendly operating environment is provided, and the user experience is improved.
  • ultrasonic sensors instead of optical proximity sensors to achieve the anti-mistouch function can also reduce the number of electronic devices in electronic devices and save the front opening of the screen, narrow the frame space of electronic devices, increase the screen ratio of electronic devices, and improve electronic devices.
  • the application of ultrasonic sensors is more extensive, especially in the case of strong light, water mist, etc., the optical proximity sensor is easy to fail.
  • One of the solutions in the prior art is to use ultrasonic signals to continuously measure distances to determine whether an object is dynamically approaching or moving away.
  • the electronic device continuously transmits ultrasonic signals, and by acquiring the time and signal strength changes of the ultrasonic signals from transmitting to receiving echoes, it is judged whether an object is dynamically approaching or moving away near the electronic device.
  • the ultrasonic signal needs to be continuously transmitted, the audio channel needs to be turned on all the time, and the power consumption is large; and due to the different materials and positions of different obstacles, the time for the ultrasonic signal to encounter the ultrasonic echo signal reflected by different obstacles , signal strength, etc.
  • the ultrasonic signal can be transmitted at intervals by setting the duty cycle, which reduces the power consumption compared with the aforementioned ultrasonic signal ranging scheme, and can determine whether the current electronic device is blocked in the low-power normally-on state.
  • the solution of the present application can effectively identify static objects around the electronic device, so that the electronic device can more effectively and accurately determine whether the current electronic device is in a blocked state in scenarios such as pockets and backpacks.
  • Ultrasound is a sound wave with a frequency higher than 20,000 hertz (Hz). Since the frequency of the sound wave that can be discerned by the human ear is about 20 to 20,000 Hz, generally when the vibration frequency of the sound wave is greater than 20,000 Hz, the human ear cannot hear it.
  • the lower limit of the frequency of the ultrasonic wave is approximately equal to The upper limit of human hearing, so it is called ultrasound.
  • the exemplary electronic device 100 provided in the embodiment of the present application is introduced. It should be understood that the electronic device 100 may have more or fewer components than those shown in the figures, may combine two or more components, or may have different component configurations.
  • the various components shown in the figures 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.
  • FIG. 1 is a schematic structural diagram of an electronic device 100 .
  • 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.
  • Mobile communication module 150 wireless communication module 160, audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, sensor module 180, buttons 190, motor 191, indicator 192, camera 193, display screen 194 and Subscriber identification module (subscriber identification module, SIM) card interface 195 and so on.
  • SIM Subscriber identification module
  • the sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, a gravity 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, and ambient light. Sensor 180L, ultrasonic sensor 180M, etc.
  • the structures illustrated in the embodiments of the present application do not constitute a specific limitation on the electronic device 100 .
  • the electronic device 100 may include more or less components than shown, or combine some components, or separate some components, or arrange different components.
  • the illustrated components may be implemented in hardware, software, or a combination of software and hardware.
  • the processor 110 may include one or more processing units, for example, the processor 110 may include an application processor (application processor, AP), a modem processor, a graphics processor (graphics processing unit, GPU), an image signal processor (image signal processor, ISP), controller, memory, video codec, digital signal processor (digital signal processor, DSP), baseband processor, and/or neural-network processing unit (NPU) Wait. Wherein, different processing units may be independent devices, or may be integrated in one or more processors.
  • application processor application processor, AP
  • modem processor graphics processor
  • graphics processor graphics processor
  • ISP image signal processor
  • controller memory
  • video codec digital signal processor
  • DSP digital signal processor
  • NPU neural-network processing unit
  • the controller may be the nerve center and command center of the electronic device 100 .
  • the controller can generate an operation control signal according to the instruction operation code and timing signal, and complete the control of fetching and executing instructions.
  • a memory may also be provided in the processor 110 for storing instructions and data.
  • the memory in processor 110 is cache memory. This memory may hold instructions or data that have just been used or recycled by the processor 110 . If the processor 110 needs to use the instruction or data again, it can be called directly from the memory. Repeated accesses are avoided and processor 110 latency is reduced, thereby increasing the efficiency of the system.
  • the processor 110 may include one or more interfaces.
  • the interface may include an integrated circuit (inter-integrated circuit, I2C) interface, an integrated circuit built-in audio (inter-integrated circuit sound, I2S) interface, a pulse code modulation (pulse code modulation, PCM) interface, a universal asynchronous transceiver (universal asynchronous transmitter) receiver/transmitter, UART) interface, mobile industry processor interface (MIPI), general-purpose input/output (GPIO) interface, subscriber identity module (SIM) interface, and / or universal serial bus (universal serial bus, USB) interface, etc.
  • I2C integrated circuit
  • I2S integrated circuit built-in audio
  • PCM pulse code modulation
  • PCM pulse code modulation
  • UART universal asynchronous transceiver
  • MIPI mobile industry processor interface
  • GPIO general-purpose input/output
  • SIM subscriber identity module
  • USB universal serial bus
  • the I2C interface is a bidirectional synchronous serial bus that includes a serial data line (SDA) and a serial clock line (SCL).
  • the processor 110 may contain multiple sets of I2C buses.
  • the processor 110 can be respectively coupled to the touch sensor 180K, the charger, the flash, the camera 193 and the like through different I2C bus interfaces.
  • the processor 110 may couple the touch sensor 180K through the I2C interface, so that the processor 110 and the touch sensor 180K communicate with each other through the I2C bus interface, so as to realize the touch function of the electronic device 100 .
  • the I2S interface can be used for audio communication.
  • the processor 110 may contain multiple sets of I2S buses.
  • the processor 110 may be coupled with the audio module 170 through an I2S bus to implement communication between the processor 110 and the audio module 170 .
  • the audio module 170 can transmit audio signals to the wireless communication module 160 through the I2S interface, so as to realize the function of answering calls through a Bluetooth headset.
  • the PCM interface can also be used for audio communications, sampling, quantizing and encoding analog signals.
  • the audio module 170 and the wireless communication module 160 may be coupled through a PCM bus interface.
  • the audio module 170 can also transmit audio signals to the wireless communication module 160 through the PCM interface, so as to realize the function of answering calls through the Bluetooth headset. Both the I2S interface and the PCM interface can be used for audio communication.
  • the UART interface is a universal serial data bus used for asynchronous communication.
  • the bus may be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication.
  • a UART interface is typically used to connect the processor 110 with the wireless communication module 160 .
  • the processor 110 communicates with the Bluetooth module in the wireless communication module 160 through the UART interface to implement the Bluetooth function.
  • the audio module 170 can transmit audio signals to the wireless communication module 160 through the UART interface, so as to realize the function of playing music through the Bluetooth headset.
  • the MIPI interface can be used to connect the processor 110 with peripheral devices such as the display screen 194 and the camera 193 .
  • MIPI interfaces include camera serial interface (CSI), display serial interface (DSI), etc.
  • the processor 110 communicates with the camera 193 through a CSI interface, so as to realize the photographing function of the electronic device 100 .
  • the processor 110 communicates with the display screen 194 through the DSI interface to implement the display function of the electronic device 100 .
  • the GPIO interface can be configured by software.
  • the GPIO interface can be configured as a control signal or as a data signal.
  • the GPIO interface may be used to connect the processor 110 with the camera 193, the display screen 194, the wireless communication module 160, the audio module 170, the sensor module 180, and the like.
  • the GPIO interface can also be configured as I2C interface, I2S interface, UART interface, MIPI interface, etc.
  • the SIM interface can be used to communicate with the SIM card interface 195 to realize the function of transferring data to the SIM card or reading data in the SIM card.
  • the USB interface 130 is an interface that conforms to the USB standard specification, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, and the like.
  • the USB interface 130 can be used to connect a charger to charge the electronic device 100, and can also be used to transmit data between the electronic device 100 and peripheral devices. It can also be used to connect headphones to play audio through the headphones.
  • the interface can also be used to connect other electronic devices, such as AR devices.
  • the interface connection relationship between the modules illustrated in the embodiments of the present application is only a schematic illustration, and does not constitute a structural limitation of the electronic device 100 .
  • the electronic device 100 may also adopt different interface connection manners in the foregoing embodiments, or a combination of multiple interface connection manners.
  • the charging management module 140 is used to receive charging input from the charger.
  • the charger may be a wireless charger or a wired charger.
  • the power management module 141 is used for connecting 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 supplies power to the processor 110 , the internal memory 121 , the external memory, the display screen 194 , the camera 193 , and the wireless communication module 160 .
  • the wireless communication function of the electronic device 100 may be implemented by the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modulation and demodulation processor, the baseband processor, and the like.
  • Antenna 1 and Antenna 2 are used to transmit and receive electromagnetic wave signals.
  • Each antenna in electronic device 100 may be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve antenna utilization.
  • the antenna 1 can be multiplexed as a diversity antenna of the wireless local area network. In other embodiments, the antenna may be used in conjunction with a tuning switch.
  • the mobile communication module 150 may provide wireless communication solutions including 2G/3G/4G/5G etc. applied on the electronic device 100 .
  • the mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (LNA) and the like.
  • the mobile communication module 150 can receive electromagnetic waves from the antenna 1, filter and amplify 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 then turn it into an electromagnetic wave for radiation through the antenna 1 .
  • at least part of the functional modules of the mobile communication module 150 may be provided in the processor 110 .
  • at least part of the functional modules of the mobile communication module 150 may be provided in the same device as at least part of the modules of the processor 110 .
  • the modem processor may include a modulator and a demodulator.
  • the modulator is used to modulate the low frequency baseband signal to be sent into a medium and high frequency signal.
  • the demodulator is used to demodulate the received electromagnetic wave signal into a low frequency baseband signal. Then the demodulator transmits the demodulated low-frequency baseband signal to the baseband processor for processing.
  • the low frequency baseband signal is processed by the baseband processor and passed to the application processor.
  • the application processor outputs sound signals through audio devices (not limited to the speaker 170A, the receiver 170B, etc.), or displays images or videos through the display screen 194 .
  • the modem processor may be a stand-alone device.
  • the modem processor may be independent of the processor 110, and may be provided in the same device as the mobile communication module 150 or other functional modules.
  • the wireless communication module 160 can provide applications on the electronic device 100 including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), bluetooth (BT), global navigation satellites Wireless communication solutions such as global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), and infrared technology (IR).
  • WLAN wireless local area networks
  • BT Bluetooth
  • GNSS global navigation satellite system
  • FM frequency modulation
  • NFC near field communication
  • IR infrared technology
  • the wireless communication module 160 may be one or more devices integrating 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, perform frequency modulation on it, amplify it, and convert it into an electromagnetic wave for radiation through the antenna 2.
  • the antenna 1 of the electronic device 100 is coupled with the mobile communication module 150, and the antenna 2 is coupled with 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), broadband 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, etc.
  • the GNSS may include a global positioning system (global positioning system, GPS), a global navigation satellite system (GLONASS), a Beidou navigation satellite system (BDS), a quasi-zenith satellite system (quasi -zenith satellite system, QZSS) and/or satellite based augmentation systems (SBAS).
  • GPS global positioning system
  • GLONASS global navigation satellite system
  • BDS Beidou navigation satellite system
  • QZSS quasi-zenith satellite system
  • SBAS satellite based augmentation systems
  • the electronic device 100 implements a display function through a GPU, a display screen 194, an application processor, and the like.
  • the GPU is a microprocessor for image processing, and is connected to the 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 alter display information.
  • 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 or an active-matrix organic light-emitting diode (active-matrix organic light).
  • LED organic light-emitting diode
  • AMOLED organic light-emitting diode
  • FLED flexible light-emitting diode
  • Miniled MicroLed, Micro-oLed, quantum dot light-emitting diode (quantum dot light emitting diodes, QLED) and so on.
  • the electronic device 100 may include one or N display screens 194 , where N is a positive integer greater than one.
  • the display screen 194 has a touch function, which may be called a touch screen, that is, the electronic device 100 can respond according to the corresponding position of the user touching the display screen 194 .
  • the electronic device 100 may implement a shooting function through an ISP, a camera 193, a video codec, a GPU, a display screen 194, an application processor, and the like.
  • the ISP is used to process the data fed back by the camera 193 .
  • the shutter is opened, the light is transmitted to the camera photosensitive element through the lens, the light signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing, and converts it into an image visible to the naked eye.
  • ISP can also perform algorithm optimization on image noise, brightness, and skin tone.
  • ISP can also optimize the exposure, color temperature and other parameters of the shooting scene.
  • the ISP may be provided in the camera 193 .
  • Camera 193 is used to capture still images or video.
  • the object is projected through the lens to generate an optical image onto the photosensitive element.
  • the photosensitive element may be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor.
  • CMOS complementary metal-oxide-semiconductor
  • the photosensitive element converts the optical signal into an electrical signal, and then transmits the electrical signal to the ISP to convert it into a digital image signal.
  • the ISP outputs the digital image signal to the DSP for processing.
  • DSP converts digital image signals into standard RGB, YUV and other formats of image signals.
  • the electronic device 100 may include 1 or N cameras 193 , where N is a positive integer greater than 1.
  • a 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, and the like.
  • Video codecs are used to compress or decompress digital video.
  • the electronic device 100 may support one or more video codecs.
  • the electronic device 100 can play or record videos of various encoding formats, such as: Moving Picture Experts Group (moving picture experts group, MPEG) 1, MPEG2, MPEG3, MPEG4 and so on.
  • MPEG Moving Picture Experts Group
  • MPEG2 moving picture experts group
  • MPEG3 MPEG4
  • MPEG4 Moving Picture Experts Group
  • the NPU is a neural-network (NN) computing processor.
  • NN neural-network
  • Applications such as intelligent cognition of the electronic device 100 can be implemented through the NPU, such as image recognition, face recognition, speech recognition, text understanding, and the like.
  • 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 through the external memory interface 120 to realize the data storage function. For example to save files like music, video etc in external memory card.
  • Internal memory 121 may be used to store computer executable program code, which includes instructions.
  • the processor 110 executes various functional applications and data processing of the electronic device 100 by executing the instructions stored in the internal memory 121 .
  • the internal memory 121 may include a storage program area and a storage data area.
  • the storage program area can store an operating system, an application required for at least one function (such as a face recognition function, a fingerprint recognition function, a mobile payment function, etc.) and the like.
  • the storage data area may store data created during the use of the electronic device 100 (such as face information template data, fingerprint information template, etc.) and the like.
  • the internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, universal flash storage (UFS), and the like.
  • the electronic device 100 may implement audio functions through an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, an application processor, and the like. Such as music playback, recording, etc.
  • the audio module 170 is used for converting digital audio information into analog audio signal output, and also for converting analog audio input into digital audio signal. Audio module 170 may also be used to encode and decode audio signals. In some embodiments, the audio module 170 may be provided in the processor 110 , or some functional modules of the audio module 170 may be provided in the processor 110 .
  • Speaker 170A also referred to as a "speaker" is used to convert audio electrical signals into sound signals.
  • the electronic device 100 can listen to music through the speaker 170A, or listen to a hands-free call.
  • the receiver 170B also referred to as "earpiece" is used to convert audio electrical signals into sound signals.
  • the voice can be answered by placing the receiver 170B close to the human ear.
  • the microphone 170C also called “microphone” or “microphone” is used to convert sound signals into electrical signals.
  • the user can make a sound by approaching the microphone 170C through a human mouth, and input the sound signal into the microphone 170C.
  • the electronic device 100 may be provided with at least one microphone 170C. In other embodiments, the electronic device 100 may be provided with two microphones 170C, which can implement a noise reduction function in addition to collecting sound signals. In other embodiments, the electronic device 100 may further be provided with three, four or more microphones 170C to collect sound signals, reduce noise, identify sound sources, and implement directional recording functions.
  • the earphone jack 170D is used to connect wired earphones.
  • the earphone interface 170D can be the USB interface 130, or can be a 3.5mm open mobile terminal platform (OMTP) standard interface, a cellular telecommunications industry association of the USA (CTIA) standard interface.
  • OMTP open mobile terminal platform
  • CTIA cellular telecommunications industry association of the USA
  • the pressure sensor 180A is used to sense pressure signals, and can convert the pressure signals into electrical signals.
  • the pressure sensor 180A may be provided on the display screen 194 .
  • the capacitive pressure sensor may be comprised of at least two parallel plates of conductive material. When a force is applied to the pressure sensor 180A, the capacitance between the electrodes changes.
  • the electronic device 100 determines the intensity of the pressure according to the change in capacitance. When a touch operation acts on the display screen 194, the electronic device 100 detects the intensity of the touch operation according to the pressure sensor 180A.
  • the electronic device 100 may also calculate the touched position according to the detection signal of the pressure sensor 180A.
  • touch operations acting on the same touch position but with different touch operation intensities may correspond to different operation instructions. For example, when a touch operation whose intensity is less than the first pressure threshold acts on the short message application icon, the instruction for viewing the short message is executed. When a touch operation with a touch operation intensity greater than or equal to the first pressure threshold acts on the short message application icon, the instruction to create a new short message is executed.
  • the gyro sensor 180B may be used to determine the motion attitude of the electronic device 100 .
  • the angular velocity of electronic device 100 about three axes ie, x, y, and z axes
  • the gyro sensor 180B can be used for image stabilization.
  • the gyro sensor 180B detects the shaking angle of the electronic device 100, calculates the distance that the lens module needs to compensate according to the angle, and allows the lens to offset the shaking of the electronic device 100 through reverse motion to achieve anti-shake.
  • the gyro sensor 180B can also be used for navigation and somatosensory game scenarios.
  • Gravity sensor 180C is used to measure gravity.
  • the electronic device 100 can measure the direction of gravity and the data value of gravity through the gravity sensor 180C to assist the conversion of the display screen.
  • the magnetic sensor 180D includes a Hall sensor.
  • the electronic device 100 can detect the opening and closing of the flip holster using the magnetic sensor 180D.
  • the electronic device 100 can detect the opening and closing of the flip according to the magnetic sensor 180D. Further, according to the detected opening and closing state of the leather case or the opening and closing state of the flip cover, characteristics such as automatic unlocking of the flip cover are set.
  • the acceleration sensor 180E can detect the magnitude of the acceleration of the electronic device 100 in various directions (generally three axes).
  • the magnitude and direction of gravity can be detected when the electronic device 100 is stationary. It can also be used to identify the posture of electronic devices, and can be used in applications such as horizontal and vertical screen switching, pedometers, etc.
  • the electronic device 100 can measure the distance through infrared or laser. In some embodiments, when shooting a scene, the electronic device 100 can use the distance sensor 180F to measure the distance to achieve fast focusing.
  • Proximity light sensor 180G may include, for example, light emitting diodes (LEDs) and light detectors, such as photodiodes.
  • the light emitting diodes may be infrared light emitting diodes.
  • the electronic device 100 emits infrared light to the outside through the light emitting diode.
  • Electronic device 100 uses photodiodes 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 may 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 holds the electronic device 100 close to the ear to talk, so as to automatically turn off the screen to save power.
  • Proximity light sensor 180G can also be used in holster mode, pocket mode automatically unlocks and locks the screen.
  • the proximity light sensor and the ultrasonic sensor can be coupled to determine whether the electronic device enables the anti-mistouch function. For example, when either the proximity light sensor or the ultrasonic sensor detects that the current electronic device is in a blocked state, the electronic device is turned on. Anti-mistouch function; or when both the proximity light sensor and the ultrasonic sensor detect that the current electronic device is in a blocked state, the electronic device will turn on the anti-mistouch function, etc.
  • the ambient light sensor 180L is used to sense ambient light brightness.
  • the electronic device 100 can adaptively adjust the brightness of the display screen 194 according to the perceived ambient light brightness.
  • the ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures.
  • the ambient light sensor 180L can also cooperate with the proximity light sensor 180G to detect whether the electronic device 100 is in the pocket to prevent accidental touch.
  • the ambient light sensor and the ultrasonic sensor can be coupled to determine whether the electronic device enables the anti-mistouch function.
  • the ultrasonic sensor detects that the electronic device is in a blocked state
  • the ambient light sensor detects that the brightness of the ambient light is higher than At a certain brightness value
  • the anti-mistouch function is still not turned on; or when the ambient light sensor detects that the ambient light brightness is lower than the first brightness value, such as 10 lux (lx), and the ultrasonic sensor detects that the current electronic device is in a blocked state , the electronic device will turn on the anti-mistouch function, etc.
  • the fingerprint sensor 180H is used to collect fingerprints.
  • the electronic device 100 can use the collected fingerprint characteristics to realize fingerprint unlocking, accessing application locks, taking pictures with fingerprints, answering incoming calls with fingerprints, and the like.
  • the temperature sensor 180J is used to detect the temperature.
  • the electronic device 100 uses the temperature detected by the temperature sensor 180J to execute a temperature processing strategy. For example, when the temperature reported by the temperature sensor 180J exceeds a threshold value, the electronic device 100 reduces the performance of the processor located near the temperature sensor 180J in order to reduce power consumption and implement thermal protection.
  • the electronic device 100 when the temperature is lower than another threshold, the electronic device 100 heats the battery 142 to avoid abnormal shutdown of the electronic device 100 caused by the low temperature.
  • the electronic device 100 boosts the output voltage of the battery 142 to avoid abnormal shutdown caused by low temperature.
  • Touch sensor 180K also called “touch panel”.
  • the touch sensor 180K may be disposed on the display screen 194 , and 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 a touch operation on or near it.
  • the touch sensor can pass the detected touch operation to the application processor to determine the type of touch event.
  • Visual output related to touch operations may be provided through display screen 194 .
  • the touch sensor 180K may also be disposed on the surface of the electronic device 100 , which is different from the location where the display screen 194 is located.
  • the ultrasonic sensor 180M is used to detect the current state of the electronic device 100 by transmitting and receiving ultrasonic waves, and then the processor 110 determines whether to enable the anti-mistouch mode.
  • the keys 190 include a power-on key, a volume key, and the like. Keys 190 may be mechanical keys. It can also be a touch key.
  • 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 .
  • Motor 191 can generate vibrating cues.
  • the motor 191 can be used for vibrating alerts for incoming calls, and can also be used for touch vibration feedback.
  • touch operations acting on different applications can correspond to different vibration feedback effects.
  • the motor 191 can also correspond to different vibration feedback effects for touch operations on different areas of the display screen 194 .
  • Different application scenarios for example: time reminder, receiving information, alarm clock, games, etc.
  • the touch vibration feedback effect can also support customization.
  • the indicator 192 can be an indicator light, which can be used to indicate the charging state, the change of the power, and can also be used to indicate a message, a missed call, a notification, and the like.
  • the SIM card interface 195 is used to connect a SIM card.
  • the SIM card can be contacted and separated from the electronic device 100 by inserting into the SIM card interface 195 or pulling out from the SIM card interface 195 .
  • the electronic device 100 may support 1 or N SIM card interfaces, where N is a positive integer greater than 1.
  • the SIM card interface 195 can support Nano SIM card, Micro SIM card, SIM card and so on. Multiple cards can be inserted into the same SIM card interface 195 at the same time. The types of the plurality of cards may be the same or different.
  • the SIM card interface 195 can also be 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 call and data communication.
  • FIG. 2 is a block diagram of the software structure of the electronic device 100 according to the embodiment of the present application.
  • the layered architecture divides the software into several layers, and each layer has a clear role and division of labor. Layers communicate with each other through software interfaces.
  • the Android system can be divided into four layers, which are, from top to bottom, an application layer, an application framework layer, an Android runtime (Android runtime) and system libraries, and a kernel layer.
  • the application layer can include a series of application packages.
  • the application package may include applications (also referred to as applications) such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, and short message.
  • applications also referred to as applications
  • the application layer may also include an application in the anti-mistouch mode, and when the application in the anti-mistouch mode runs, the ultrasonic sensor needs to be called to send/receive ultrasonic signals.
  • the application framework layer provides an application programming interface (application programming interface, API) and a programming framework for applications in the application layer.
  • the application framework layer includes some predefined functions.
  • the application framework layer can include a window manager, a content provider, a view system, a phone manager, a resource manager, a notification manager, a Local Profile Assistant (LPA), and an ultrasonic sensor call Control Manager, etc.
  • a window manager a content provider
  • a view system a phone manager
  • a resource manager a notification manager
  • LPA Local Profile Assistant
  • ultrasonic sensor call Control Manager etc.
  • a window manager is used to manage window programs.
  • the window manager can get the size of the display screen, determine whether there is a status bar, lock the screen, take screenshots, etc.
  • Content providers are used to store and retrieve data and make these data accessible to applications.
  • the data may include video, images, audio, calls made and received, browsing history and bookmarks, phone book, etc.
  • the view system includes visual controls, such as controls for displaying text, controls for displaying pictures, and so on. View systems can be used to build applications.
  • a display interface can consist of one or more views.
  • the display interface including the short message notification icon may include a view for displaying text and a view for displaying pictures.
  • the phone manager is used to provide the communication function of the electronic device 100 .
  • the management of call status including connecting, hanging up, etc.).
  • the resource manager provides various resources for the application, such as localization strings, icons, pictures, layout files, video files and so on.
  • the notification manager enables applications to display notification information in the status bar, which can be used to convey notification-type messages, and can disappear automatically after a brief pause without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc.
  • the notification manager can also display notifications in the status bar at the top of the system in the form of graphs or scroll bar text, such as notifications from applications running in the background, and can also display notifications on the screen in the form of a dialog interface. For example, text information is prompted in the status bar, a prompt sound is issued, the electronic device vibrates, and the indicator light flashes.
  • the Android Runtime includes core libraries and a virtual machine. Android runtime is responsible for scheduling and management of the Android system.
  • the core library consists of two parts: one is the function functions that the java language needs to call, and the other is the core library of Android.
  • the application layer and the application framework layer run in virtual machines.
  • the virtual machine executes the java files of the application layer and the application framework layer as binary files.
  • the virtual machine is used to perform functions such as object lifecycle management, stack management, thread management, safety and exception management, and garbage collection.
  • a system library can include multiple functional modules. For example: surface manager (surface manager), media library (Media Libraries), 3D graphics processing library (eg: OpenGL ES), 2D graphics engine (eg: SGL), etc.
  • surface manager surface manager
  • media library Media Libraries
  • 3D graphics processing library eg: OpenGL ES
  • 2D graphics engine eg: SGL
  • the Surface Manager is used to manage the display subsystem and provides a fusion of two-dimensional (2-Dimensional, 2D) and three-dimensional (3-Dimensional, 3D) layers for multiple applications.
  • the media library supports playback and recording of a variety of commonly used audio and video formats, as well as still 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.
  • the 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.
  • 2D graphics engine is a drawing engine for 2D drawing.
  • the kernel layer is the layer between hardware and software.
  • the kernel layer contains at least display drivers, camera drivers, audio drivers, sensor drivers, and virtual card drivers.
  • the sensor driving includes the driving of the ultrasonic sensor, and the driving of the ultrasonic sensor is used to drive the ultrasonic sensor 180M.
  • the ultrasonic sensor 180M is used for sending and receiving ultrasonic signals.
  • the workflow of the software and hardware of the electronic device 100 is exemplified in conjunction with capturing a photographing scene.
  • a corresponding hardware interrupt is sent to the kernel layer.
  • the kernel layer processes touch operations into raw input events (including touch coordinates, timestamps of touch operations, etc.). Raw input events are stored at the kernel layer.
  • the application framework layer obtains the original input event from the kernel layer, and identifies the control corresponding to the input event. Taking the touch operation as a touch click operation, and the control corresponding to the click operation is the control of the camera application icon, for example, the camera application calls the interface of the application framework layer to start the camera application, and then starts the camera driver by calling the kernel layer.
  • the camera 193 captures still images or video.
  • Ultrasonic sensors are sensors developed using the characteristics of ultrasonic waves.
  • Ultrasound is a kind of mechanical wave whose vibration frequency is higher than that of sound wave. It has the characteristics of high frequency, short wavelength, small diffraction phenomenon, good directionality, and can become a ray and propagate in a direction.
  • Ultrasound is highly directional. Ultrasonic waves can propagate in gases, liquids and solids, and the propagation speed is different. Ultrasonic waves will also have phenomena such as refraction, reflection, and diffraction, and they will be attenuated during the propagation process.
  • Ultrasonic waves propagate in the air, and their frequency is low, generally tens of kilohertz (kHz), while in solids and liquids, the frequencies are higher, and the propagation attenuation in air is also faster, while in liquids and solids, Relative attenuation is smaller and spreads farther.
  • kHz kilohertz
  • Ultrasonic sensors may include ultrasonic transmitters and ultrasonic receivers, and in the embodiments of the present application, reference to ultrasonic transmitters and ultrasonic receivers is intended to cover all functional alternatives that may be collectively referred to as ultrasonic sensors.
  • the ultrasonic transmitter is used to transmit ultrasonic signals. When the ultrasonic signal encounters obstacles, it will reflect the ultrasonic echo to the ultrasonic receiver, so that the ultrasonic sensor can detect the object to be measured.
  • the ultrasonic transmitter and ultrasonic receiver of the ultrasonic sensor can be concentrated on the same device or can be separated.
  • the ultrasonic sensor can even be any available combination of ultrasonic transmitter and ultrasonic receiver with the same function.
  • the number of ultrasonic sensors may be one or more.
  • the ultrasonic transmitter is intended to comprise one or more ultrasonic transmitters and the ultrasonic receiver is intended to comprise one or more ultrasonic receivers.
  • the number of ultrasonic transmitters and the number of ultrasonic receivers may or may not be equal. This embodiment of the present application does not impose any restrictions on the quantity and position of the ultrasonic sensors on the electronic device 100 .
  • One or more earpieces, speakers, microphones of the electronic device 100 for audio functions may also be used for the measurement of ultrasound. It can be understood that the earpiece and the loudspeaker can be used as an ultrasonic transmitter, and the microphone can be used as an ultrasonic receiver, which can save the component cost and internal space of the electronic device 100 .
  • an earpiece 301 may be installed above the front of the mobile phone 300, and the earpiece 301 may be used as an ultrasonic transmitter for transmitting ultrasonic signals.
  • a noise reduction microphone 302 may be installed on the top of the mobile phone 300, and the microphone 302 may be used as an ultrasonic receiver for receiving ultrasonic echo signals.
  • FIG 3b shows a schematic diagram of the emission range of the ultrasonic transmitter.
  • the transmission trajectory of the ultrasonic signal is a conical beam with the ultrasonic transmitter as the origin, and the center line of the conical beam is the ultrasonic wave.
  • the emission direction of the signal, the ultrasonic signal is scattered to the surrounding space along the direction of the first angle with the emission direction, forming a conical beam.
  • the specific value of the first angle is related to the specific design of the ultrasonic transmitter. There are no restrictions on the application.
  • the transmitted ultrasonic signal can be a single-frequency continuous wave (continuous wave, CW), a linear frequency modulation continuous wave (linear frequency modulation, LFM), a ZC sequence (Zadoff-Chu sequence), etc.
  • CW continuous wave
  • LFM linear frequency modulation
  • ZC sequence Zadoff-Chu sequence
  • power consumption can be reduced by intermittently transmitting ultrasonic waves, that is, by setting a duty ratio.
  • the ultrasonic wave signal can be continuously transmitted for 150 milliseconds in a period of 1 second.
  • the channel for transmitting ultrasonic waves is powered off, that is, ultrasonic signals are not transmitted, so that the duty cycle is 0.15, which can ensure that the power consumption of transmitting ultrasonic waves is at a relatively low level.
  • the ultrasonic waves emitted by the earpiece will pass through different paths to form ultrasonic echoes and propagate to the microphone.
  • the main paths of the ultrasonic echoes involved in this embodiment of the present application are shown in Figure 3c:
  • Solid structure sound path 303 ultrasonic waves emitted from the earpiece 301 pass through the internal solid structure of the mobile phone 300 and propagate to the microphone 302 .
  • the propagation speed of sound in solids (>2000m/s) is faster than that in air (about 340m/s), so the propagation time of solid structure sound path 303 is the shortest, and the propagation time of this path 303 is very stability.
  • Direct air sound path 304 the earpiece 301 emits ultrasonic waves, which are propagated into the air, and are directly propagated to the microphone 302 without being reflected.
  • the propagation time of the direct air sound path 304 is slower than that of the solid structure sound path 303, but the path 304 is less affected by external objects, so the propagation time of the air direct sound path 304 is also relatively stable.
  • Air reflected sound path 305 the earpiece 301 emits ultrasonic waves and propagates into the air.
  • the ultrasonic signal When encountering obstacles above the microphone and the earpiece, the ultrasonic signal generates ultrasonic echoes through reflection, refraction, diffraction, etc., and the ultrasonic echoes propagate to the microphone 302. . Due to uncertainties such as the existence of obstacles, materials, occlusion positions, and occlusion distances, the air-reflected sound path 305 cannot accurately measure its propagation time.
  • the processor of the mobile phone 300 determines whether there is an obstacle above the mobile phone 300 according to the propagation time, sound wave intensity and other information of the different ultrasonic echo signals, and then determines whether it is necessary to activate the protection.
  • Accidental touch mode the processor of the mobile phone 300 determines whether there is an obstacle above the mobile phone 300 according to the propagation time, sound wave intensity and other information of the different ultrasonic echo signals, and then determines whether it is necessary to activate the protection.
  • Accidental touch mode is the processor of the mobile phone 300 determines whether there is an obstacle above the mobile phone 300 according to the propagation time, sound wave intensity and other information of the different ultrasonic echo signals, and then determines whether it is necessary to activate the protection.
  • Accidental touch mode the processor of the mobile phone 300 determines whether there is an obstacle above the mobile phone 300 according to the propagation time, sound wave intensity and other information of the different ultrasonic echo signals, and then determines whether it is necessary to activate the protection.
  • Accidental touch mode the processor of the mobile phone 300 determines whether there is an
  • the ultrasonic echo Sig R received by the microphone 302 is the linear superposition of the ultrasonic signals on each path after the time t of the ultrasonic Sig T emitted by the earpiece 301 . Therefore, the baseband signal of the ultrasonic echo Sig R received by the microphone 302 can be expressed as:
  • the baseband signal received by the ultrasonic receiver is a replica of a delay ⁇ i of the ultrasonic sequence transmitted by the ultrasonic transmitter Sig(t- ⁇ i ) .
  • the amplitude A i will not change drastically, and the phase It is possible to change with the movement.
  • the effect of the path on the signal is equivalent to passing through a linear system with impulse response h:
  • ⁇ (t) is the Dirac shock function. Therefore, if the impulse response h(t) of the signal can be obtained, the amplitudes of the delays of different paths can be known, so as to separate the paths of different delays.
  • the correlation calculation is used, which is equivalent to the conjugation of the reverse sequence of convolution, which satisfies the commutative law.
  • FIG. 4 shows a schematic diagram of the impulse response of a single-frame ultrasonic echo signal collected by a mobile phone microphone in some scenarios, wherein the abscissa of each figure represents the path traveled by the ultrasonic waves The ordinate of each figure represents the intensity of the ultrasonic echo signal impulse response. The larger the value, the higher the intensity.
  • the waveform of the correlation peak in the figure can reflect the occlusion of objects near the mobile phone.
  • the main peak represents the impact response of the ultrasonic wave directly from the earpiece to the microphone path through the internal solid structure of the mobile phone and the air
  • the peak after the main peak represents the impact of the ultrasonic wave reaching the microphone after it is reflected from an obstacle after it is emitted from the earpiece.
  • the main peak and the next peak after the main peak may have different waveform fusion, amplitude changes, etc., and then show different data characteristics. .
  • Figure a in Figure 4 is an example diagram of the ultrasonic echo impulse response when the palm is blocked at 0 cm above the mobile phone;
  • Figure b in Figure 4 is an example diagram of the ultrasonic echo impulse response when the palm is blocked at 6 cm above the mobile phone;
  • Figure c in Figure 4 is an example diagram of the ultrasonic echo impulse response when the palm is blocked at 8 cm above the mobile phone;
  • Figure d in Figure 4 is an example diagram of the ultrasonic echo impulse response when the mobile phone is in a backpack;
  • Figure 4 e The picture is an example diagram of the ultrasonic echo impulse response when the mobile phone is in the pocket of jeans;
  • the picture f in FIG. 4 is an example diagram of the ultrasonic echo impulse response when the mobile phone is not blocked above. It can be seen from Figure 4 that under different scenarios, the width, position and height of the main peak and the width, position and height of the next peak after the main peak show different shapes.
  • This application is mainly used in the detection of whether the electronic device is currently in a blocked state.
  • the electronic device can automatically activate the anti-mistouch mode.
  • the anti-mistouch mode the The electronic device does not respond to commands such as touch operations, unlocking the screen, raising the hand to brighten the screen, AOD, etc., which can prevent the occurrence of false touches and reduce the power consumption of the electronic device, improving the user experience.
  • the screen unlocking may include sliding screen unlocking, touch unlocking, password unlocking, gesture unlocking, fingerprint unlocking, face unlocking, voice unlocking, voiceprint unlocking, and the like.
  • the electronic device restricts the response to the command, not limited to the above-mentioned touch operation, screen unlocking, raising your hand to brighten the screen, AOD, etc., but also other commands, such as raising your hand to answer an incoming call, automatic Adjusting brightness, etc., developers can set according to specific conditions, and this application does not make any restrictions.
  • Figure 5a shows a common application scenario, the pocket scenario: the user puts the mobile phone 501 in the pocket 502, the mobile phone 501 can detect that it is in a blocked state, and then in the anti-mistouch mode, the mobile phone 501 does not respond to touch operations , unlock the screen, raise your hand to brighten the screen, AOD and other commands to prevent accidental touches.
  • This embodiment does not impose any restrictions on the material of the pocket, and the material of the pocket may be cotton, chiffon, polyester, mixed fabric, and the like.
  • Figure 5b shows another common application scenario, the luggage scenario: the user puts the mobile phone 503 in the backpack 504, the mobile phone 503 can detect that it is in a blocked state, and then in the anti-mistouch mode, the mobile phone 503 does not respond to touch Commands such as operation, unlocking the screen, raising your hand to brighten the screen, and AOD can prevent accidental touches.
  • the luggage scene here is a broad concept, which can include backpacks, single-shoulder backpacks, handbags, wallets, handbags, boxes, etc. This embodiment does not impose any restrictions on the material of the backpack, and the material of the backpack can be cotton, cowhide, etc. , leather, canvas, plastic, mixed materials, and more.
  • FIG. 5c shows an application scenario in which the palm 506 covers the upper part of the mobile phone 505, and the palm 506 has different distances from the mobile phone 505, such as 2 cm.
  • the palm 506 when the palm 506 is close to the top of the mobile phone 505, that is, at a distance of 0 cm, the mobile phone is considered to be blocked, and the anti-mistouch function is enabled at this time.
  • the application scenarios shown in FIGS. 5a, 5b, and 5c do not limit the embodiments of the present application.
  • the anti-mistouch mode is not only applied to pocket scenarios, backpack scenarios, luggage scenarios, and palm blocking scenarios, but also applied to other electronic devices.
  • the occluded situation such as book occlusion, face occlusion (during a call), etc., can be set by the developer according to the specific situation, which is not limited in this application.
  • a setting bar 602 of “Anti-Accidental Touch Mode” may be displayed on the setting user interface 601 of the electronic device, and the user may manually select an option 603 to enable/disable the “Anti-Accidental Touch Mode”.
  • the "anti-accidental touch mode” is turned on, when the electronic device detects that it is currently in a blocked state, the electronic device turns on the anti-accidental touch function, which effectively prevents the occurrence of a false-touch situation.
  • the anti-mistouch function can be that the electronic device turns off the screen, the electronic device does not respond to the screen unlocking (which may include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.), the electronic device does not respond to raising the hand to turn on the screen, and the electronic device does not respond. In response to raising your hand to answer an incoming call, the electronic device turns off AOD and other functions.
  • the anti-accidental touch function of the electronic device may be interrupted.
  • the electronic device can be set not to activate the anti-mistouch function, so even if the electronic device is detected to be blocked, for example, when the user plays games on the horizontal screen of the mobile phone, the hand is blocked. Going to the top of the electronic device does not activate the automatic screen off either. Or the user can set to turn on or off the anti-mistouch function by himself, or set one or more applications to turn on or off the anti-mistouch function by himself. If the user chooses to turn off the "anti-mistouch mode" function, the electronic device will turn off the aforementioned anti-mistouch function. In the general settings, the setting of "Anti-Accidental Touch Mode" can take effect for all applications.
  • a shortcut button 605 for the anti-touch mode may also be displayed, so that the user can quickly turn on/off the anti-touch mode.
  • This embodiment of the present application does not impose any restrictions on the name and icon of the "anti-touch mode" in the user interface, and what is shown in FIG. 6a and FIG. 6b is just an example.
  • GUI graphical user interface
  • an incoming call scenario when the electronic device has not yet activated the anti-mistouch state, other judgment logic may be added to the audio driver layer to turn off ultrasonic detection in certain usage scenarios, thereby improving user experience and further reducing power consumption .
  • the entertainment scenario may include the user using an electronic device to watch videos, listen to music, play games, etc.; the incoming call scenario includes the electronic device receiving an incoming call or instant messaging software (such as WeChat, QQ, Skype, Face Time, etc.) voice chat, video chat, etc.
  • Ultrasonic sensors can also be combined with other sensors for coupling judgment, such as gravity sensors, gyroscope sensors, and ambient light sensors.
  • the processor of the electronic device can perform a coupling analysis on whether the detections reported by the ambient light sensor and the ultrasonic sensor are currently in a blocked state. As long as there is one that indicates that the current electronic device is in a blocked state, the electronic device can determine whether the detection is currently in a blocked state. It is currently blocked, and then the electronic device turns on the anti-mistouch function, and the touch screen is locked.
  • the method is applied to an electronic device with an ultrasonic transmitter and an ultrasonic receiver.
  • the ultrasonic transmitter and the ultrasonic receiver may be arranged on the top of the electronic device, or may be located at other positions, which are not limited in this embodiment.
  • the ultrasonic transmitter and the ultrasonic receiver are intended to cover any electronic device capable of transmitting and receiving ultrasonic waves, and are not limited to the ultrasonic transmitter and ultrasonic receiver in the narrow sense.
  • the ultrasonic transmitter and ultrasonic receiver can be centralized on the same device, or they can be separated.
  • the number of ultrasonic transmitters or ultrasonic receivers may be one or more.
  • the ultrasonic transmitter is intended to comprise one or more ultrasonic transmitters and the ultrasonic receiver is intended to comprise one or more ultrasonic receivers.
  • the number of ultrasonic transmitters and the number of ultrasonic receivers may or may not be equal, which is not limited in this embodiment of the present application.
  • FIG. 7 is a schematic flowchart of a method for preventing accidental touch provided by an embodiment of the present application. As shown in Figure 7, the method may include:
  • the electronic device transmits ultrasonic signals N times, wherein N is greater than or equal to 2, and N is a positive integer.
  • the electronic device may intermittently transmit ultrasonic signals to the surroundings through the ultrasonic transmitter, that is, the electronic device may transmit multiple ultrasonic signals at intervals; wherein, one ultrasonic signal may include multiple ultrasonic signals.
  • This application does not impose any restrictions on the type of ultrasonic transmitter used, the frequency, direction, intensity, etc. of the transmitted ultrasonic waves, which can be adjusted according to the actual situation, and will not be repeated here.
  • the electronic device receives N times ultrasonic echo signals.
  • a primary ultrasonic echo signal may include a plurality of ultrasonic echo signals.
  • the electronic device obtains first data according to each received ultrasonic echo signal.
  • the first data of each received ultrasonic echo signal may include signal strengths, propagation times, etc. of multiple ultrasonic echo signals.
  • the first data of the signal may be an impulse response graph of the ultrasonic echo signal.
  • the electronic device can acquire the impulse response graph of the N times ultrasonic echo signals, and combine the first data of the N times ultrasonic echo signals into a first image.
  • N is 10
  • each of the a and b in FIG. 8 is a first image generated by impulse response maps of 10 frames of ultrasonic echo signals.
  • the first image is composed of a plurality of first pixels.
  • the abscissa represents the number of frames, that is, the number of times to collect the received ultrasonic echo signals; the ordinate represents the ranging, that is, the relative distance of the ultrasonic signal from transmission to reception; the color of each first pixel point
  • the value represents the signal strength of an ultrasonic echo signal, and different color values represent different signal strengths of the ultrasonic echo signal.
  • the lighter the color the greater the signal strength of the ultrasonic echo signal.
  • picture a in FIG. 8 is a first image collected when the mobile phone is in a leather bag
  • picture b in FIG. 8 is a first image collected when the top of the mobile phone is unobstructed.
  • the electronic device inputs the first data of the N times ultrasonic echo signals into the first classification model to obtain the first scene type.
  • the first classification model is a credible model obtained by training the first training model based on the machine learning algorithm and using the first training data. How the first classification model is trained will be explained later, and will not be repeated here.
  • the first scene type may include two types of electronic equipment being blocked and electronic equipment not being blocked, and may also be more subdivided scene types, such as leather bag blocking scene, canvas bag blocking scene, cotton shirt pocket blocking scene, jeans pocket scene.
  • scene types such as leather bag blocking scene, canvas bag blocking scene, cotton shirt pocket blocking scene, jeans pocket scene.
  • a convolutional neural network (convolutional neural networks, CNN) algorithm may be used to perform feature extraction on the first data of the collected N times ultrasonic echo signals, that is, the first image, to obtain the first feature data, and then The first feature data is input into the first classification model.
  • CNN convolutional neural networks
  • the convolutional neural network algorithm mainly has two operators, one is the convolutional layer and the other is the pooling layer.
  • Convolutional layers can be used to extract features, and pooling layers can be used to reduce the number of parameters.
  • the convolution kernel is used to extract features.
  • the convolution kernel can be a matrix.
  • the convolution layer can perform convolution operations within the sliding window by sliding a sliding window to extract image features at different positions. .
  • the output of the convolutional layer is input to the pooling layer.
  • Commonly used pooling can be maximum pooling and average pooling. Maximum pooling is to extract the most obvious features. Average pooling is to consider each pixel and extract the average feature.
  • the pooling layer also slides a sliding window, and takes the maximum value or average value within the sliding window.
  • the first image generated by a certain ultrasonic echo signal is used as the input image and input into the convolutional neural network algorithm.
  • the convolutional neural network algorithm can perform two-layer convolution on the first image.
  • the feature extraction of the layered layer finally obtains the first feature data.
  • first input the input image into the convolutional layer with pooling layer perform the first rough detection on the input image, extract the approximate positions of the feature points of the input image, and obtain the first level Level 1 feature map;
  • the feature map is then input to the convolutional layer with a pooling layer, and the predicted feature points of the Level 1 feature map are taken as the center to re-extract more accurate feature point positions to obtain the second-level Level 2 feature map; then the Level 2 feature map passes through
  • the fully connected layer can combine the features corresponding to each image to output the first feature data; the finally generated first feature data is input into the first classification model.
  • step S105 determine whether the electronic device is in a blocked state according to the first scene type, if so, go to step S106, if not, do nothing, continue to send and receive ultrasonic signals, that is, go to step S101.
  • the determination result may be directly output as that the electronic device is blocked or the electronic device is not blocked.
  • the first scene type is a plurality of subdivided scene types, such as a leather bag occlusion scene, a canvas bag occlusion scene, a cotton shirt pocket occlusion scene, a jeans pocket occlusion scene, a palm occlusion scene, a book occlusion scene, a hair occlusion scene, etc., then It is necessary to determine whether the electronic device is in a blocked state according to the detected specific scene type.
  • the result of the first scene type detected by the ultrasonic sensor may also be combined with the scene type detected by other sensors, such as a gravity sensor, a gyroscope sensor, and an ambient light sensor, for coupling judgment.
  • the processor of the electronic device can couple and analyze the reported results of the ambient light sensor and the ultrasonic sensor. For example, although the ultrasonic sensor detects that the electronic device is blocked, the ambient light sensor detects that the brightness of the ambient light is higher than a certain brightness value.
  • the anti-mistouch function is still not turned on; or when the ambient light sensor detects that the ambient light brightness is lower than a certain brightness value, and the ultrasonic sensor detects that the current electronic device is blocked, the electronic device will turn on the anti-mistouch function, etc. .
  • the processor of the electronic device can also perform coupling analysis on the reported results of the proximity light sensor and the ultrasonic sensor. For example, when either the proximity light sensor or the ultrasonic sensor detects that the current electronic device is blocked, the electronic device turns on the anti-mistouch function. ; or when both the proximity light sensor and the ultrasonic sensor detect that the current electronic device is in a blocked state, the electronic device will turn on the anti-mistouch function, etc. It can be understood that in other embodiments of the present application, other sensors can also be combined or other coupling logics can be used. It is sufficient to achieve the purpose set forth in this application.
  • the electronic device enables the anti-mistouch function.
  • the anti-mistouch function may be that the electronic device turns off the screen, the electronic device does not respond to screen unlocking (which may include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.), and the electronic device does not respond to raising a hand
  • screen unlocking which may include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.
  • the electronic device does not respond to raising a hand
  • the electronic device does not respond to raising the hand to answer the incoming call
  • the electronic device does not respond to the fingerprint to answer the incoming call
  • the electronic device turns off AOD and other functions.
  • the anti-accidental touch function of the electronic device may be interrupted.
  • the electronic device can be set not to activate the anti-mistouch function, so even if the electronic device is detected to be blocked, for example, when the user plays games on the horizontal screen of the mobile phone, the hand is blocked. Going to the top of the electronic device does not activate the automatic screen off either. Or the user can set to turn on or off the anti-mistouch function by himself, or set one or more applications to turn on or off the anti-mistouch function by himself.
  • the following describes how the first classification model is trained.
  • the first classification model is a credible model obtained by training the first training model using the first training data based on a machine learning classification algorithm.
  • the first training data includes multiple sample data
  • the multiple sample data is sample data obtained in multiple scenarios
  • one sample data includes first sample data of N times ultrasonic echo signals in a known scenario and The first sample scene type for this scene.
  • the first sample scene type is a known scene type.
  • a plurality of first sample data constitute a first sample data vector, which corresponds to a first sample scene type label formed by a plurality of first sample scene types.
  • the sample data can be divided into two parts, one part of the sample data is used to train the model, and the other part of the sample data can be used to test the accuracy of the model.
  • a first sample data is a second image generated by the second data of N times of ultrasonic echo signals generated by transmitting N times of ultrasonic signals, and the second data of each received ultrasonic echo signal may include a plurality of The signal strength, propagation time, etc. of the ultrasonic echo signal.
  • the second image is composed of a plurality of second pixels.
  • the abscissa represents the number of frames, that is, the number of times of collecting the received ultrasonic echo signals, and the ordinate represents ranging, that is, the ultrasonic signal is from The relative distance from transmission to reception, the color value of each second pixel represents the signal strength of an ultrasonic echo signal, and different color values represent different signal intensities of the ultrasonic echo signal. In the example of Figure 8, the color The shallower the signal strength of the ultrasonic echo signal is.
  • the first sample scene type may include two types of electronic equipment being blocked and electronic equipment not being blocked, and may also be more subdivided scene types, such as a leather bag blocking scene, a canvas bag blocking scene, a cotton shirt pocket blocking scene,
  • the embodiments of the present application do not limit the situations in which the jeans pocket occlusion scene, the palm occlusion scene, the book occlusion scene, the hair occlusion scene, and the like are blocked by various occluders.
  • the machine learning classification models used in the training process may include but are not limited to: extreme gradient boosting (XGBoost) model, neural network (NN) model, gradient boosting decision tree (GBDT) ) model, random forest (RF) model, etc.
  • XGBoost extreme gradient boosting
  • NN neural network
  • GBDT gradient boosting decision tree
  • RF random forest
  • an XGBoost model can be used to train to obtain a credible first classification model.
  • the XGBoost model is an integrated machine learning model that uses the gradient boosting framework and is based on a decision tree. It can be composed of multiple decision trees.
  • the decision tree here is a classification and regression tree (CART), CART
  • CART classification and regression tree
  • the decision is a binary tree, and the values of the internal node features are "Yes” and "No".
  • the branch with the value of "Yes” for each node can be used as the left branch of the node, and the value of "No” can be used. ” as the right branch of the node; the basic idea of the XGBoost model is to gradually build multiple decision trees according to the characteristics of the samples.
  • a training model also called a weak classifier
  • the first sample data vector is input into the weak classifier to obtain a sample recognition result, if the sample recognition result is the same as the first If the scene type label does not match, it indicates that the current weak classifier needs to be iterated.
  • the specific iterative process can be understood as adjusting the value of the weak classifier according to the residual between the sample identification result and the scene type label of the first sample.
  • the first classification model is credible, and its confidence level can be 95% or 98% in the test, which can actually be adjusted according to specific needs.
  • FIG. 10 shows a block diagram of functional modules of an electronic device for preventing accidental touches provided by an embodiment of the present application.
  • the functional modules of the electronic device can be implemented by hardware, software or a combination of hardware and software to implement the solution of the present application.
  • the functional modules described in FIG. 10 may be combined or separated into several sub-blocks to implement the scheme of the present application. Accordingly, what is described above in this application may support any possible combination or separation or further definition of the functional modules described below.
  • the electronic device includes an ultrasonic transmitter and an ultrasonic receiver, and the ultrasonic transmitter and the ultrasonic receiver may be disposed on the top of the electronic device, or may be located at other positions, which are not limited in this embodiment.
  • the ultrasonic transmitter and the ultrasonic receiver are intended to cover any electronic device capable of transmitting and receiving ultrasonic waves, and are not limited to the ultrasonic transmitter and ultrasonic receiver in the narrow sense.
  • the ultrasonic transmitter and ultrasonic receiver can be centralized on the same device, or they can be separated.
  • the number of ultrasonic transmitters or ultrasonic receivers may be one or more.
  • the ultrasonic transmitter is intended to comprise one or more ultrasonic transmitters and the ultrasonic receiver is intended to comprise one or more ultrasonic receivers.
  • the number of ultrasonic transmitters and the number of ultrasonic receivers may or may not be equal, which is not limited in this embodiment of the present application.
  • the electronic device may specifically include: an ultrasonic signal transmitting module, an ultrasonic echo signal receiving module, a signal feature extraction module, a scene classification module, a false-touch prevention function enabling module, and an offline model training module.
  • the ultrasonic signal transmitting module is used for transmitting ultrasonic signals for N times, wherein N is greater than or equal to 2, and N is a positive integer.
  • the ultrasonic signal transmitting module can intermittently transmit ultrasonic signals to the surroundings through the ultrasonic transmitter, that is, the electronic device can transmit ultrasonic signals multiple times at intervals; wherein, one ultrasonic signal can include multiple ultrasonic signals.
  • This application does not impose any restrictions on the type of ultrasonic transmitter used, the frequency, direction, intensity, etc. of the transmitted ultrasonic waves, which can be adjusted according to the actual situation, and will not be repeated here.
  • the ultrasonic echo signal receiving module is used for receiving N times ultrasonic echo signals.
  • the transmitted ultrasonic signal will generate ultrasonic echo when encountering obstacles.
  • the ultrasonic echo signal receiving module can receive the ultrasonic echo signal through the ultrasonic receiver. , liquid) through propagation, attenuation, refraction, reflection, diffraction, etc.
  • a primary ultrasonic echo signal may include a plurality of ultrasonic echo signals.
  • the signal feature extraction module is configured to perform feature extraction on the obtained first data of each received ultrasonic echo signal to obtain the first feature data, which is used as the input of the first classification model.
  • the first data of the ultrasonic echo signals received each time may include signal strengths, propagation times, etc. of a plurality of ultrasonic echo signals, and the first data of the ultrasonic echo signals received each time may be A graph of the impulse response of an ultrasonic echo signal.
  • the electronic device may acquire the impulse response graph of the N times ultrasonic echo signals, and combine the first data of the N times ultrasonic echo signals into a first image. For details, refer to step S103 in the foregoing method embodiment.
  • the signal feature extraction module may use a convolutional neural network (convolutional neural networks, CNN) algorithm to perform feature extraction on the first data of the collected N times ultrasonic echo signals, that is, the first image, to obtain the first a feature data, and then input the first feature data into the first classification model.
  • CNN convolutional neural networks
  • the scene classification module is configured to input the first data of the N ultrasonic echo signals into the first classification model to obtain the first scene type.
  • the first classification model is a credible model obtained by training the first training model using the first training data based on the machine learning algorithm.
  • the first scene type may include two types of electronic equipment being blocked and electronic equipment not being blocked, and may also be more subdivided scene types, such as leather bag blocking scene, canvas bag blocking scene, cotton shirt pocket blocking scene, jeans pocket scene.
  • scene types such as leather bag blocking scene, canvas bag blocking scene, cotton shirt pocket blocking scene, jeans pocket scene.
  • the scene classification module is further configured to determine whether the electronic device is in a blocked state according to the first scene type. If the first scene type is classified into two types: the electronic device is blocked and the electronic device is not blocked, the scene classification module can directly output the determination result that the electronic device is blocked or the electronic device is not blocked. If the first scene type is a plurality of subdivided scene types, such as a leather bag occlusion scene, a canvas bag occlusion scene, a cotton shirt pocket occlusion scene, a jeans pocket occlusion scene, a palm occlusion scene, a book occlusion scene, a hair occlusion scene, etc., then The scene classification module needs to determine whether the electronic device is in a blocked state according to the detected specific scene type.
  • the scene classification module may further combine the results of the first scene type detected by the ultrasonic sensor with the scene types detected by other sensors to perform coupling judgment, such as a gravity sensor, a gyroscope sensor, an ambient light sensor, and a proximity light sensor. Wait.
  • the scene classification module can perform coupling analysis on the reported results of the ambient light sensor and the ultrasonic sensor.
  • the anti-mistouch function is still not turned on; or when the ambient light sensor detects that the ambient light brightness is lower than a certain brightness value, and the ultrasonic sensor detects that the current electronic device is blocked, the electronic device will turn on the anti-mistouch function, etc.
  • the scene classification module may also perform coupling analysis on the reported results of the proximity light sensor and the ultrasonic sensor. For example, when either the proximity light sensor or the ultrasonic sensor detects that the current electronic device is in a blocked state, the electronic device is turned on. Anti-mistouch function; or when both the proximity light sensor and the ultrasonic sensor detect that the current electronic device is in a blocked state, the electronic device will turn on the anti-mistouch function, etc. It can be understood that in other embodiments of the present application, other sensors can also be combined or other coupling logics can be used. It is sufficient to achieve the purpose set forth in this application.
  • the anti-mistouch function enabling module is used to automatically turn on the anti-mistouch function when it is detected that the electronic device is in a blocked state.
  • the anti-mistouch function may be that the electronic device turns off the screen, the electronic device does not respond to screen unlocking (which may include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.), and the electronic device does not respond to raising a hand
  • screen unlocking which may include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.
  • the electronic device does not respond to raising a hand
  • the electronic device does not respond to raising the hand to answer the incoming call
  • the electronic device does not respond to the fingerprint to answer the incoming call
  • the electronic device turns off AOD and other functions.
  • the anti-accidental touch function of the electronic device may be interrupted.
  • the electronic device can be set to not activate the anti-mistouch function, so even if the electronic device is detected to be blocked, for example, when the user plays games on the horizontal screen of the mobile phone, the hand is blocked. Going to the top of the electronic device does not activate the automatic screen off either. Or the user can set to turn on or off the anti-mistouch function by himself, or set one or more applications to turn on or off the anti-mistouch function by himself.
  • the electronic device can accurately detect whether it is currently in a blocked state, and when it is determined that the electronic device is currently blocked in a pocket or a backpack, the electronic device can automatically activate the anti-mistouch function, such as The screen of the electronic device is turned off, the screen does not respond to unlocking (which may include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.), does not respond to raising the hand to brighten the screen, does not respond to raising the hand to answer incoming calls, turns off AOD, etc.
  • unlocking which may include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.
  • ultrasonic sensors instead of optical proximity sensors to achieve the anti-mistouch function can also reduce the number of electronic devices in electronic devices and save the front opening of the screen, narrow the frame space of electronic devices, increase the screen ratio of electronic devices, and improve electronic devices. Dust and water resistance, etc.
  • the embodiments of the present application may be provided as a method, a system, or a computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media having computer-usable program code embodied therein, including but not limited to disk storage, optical storage, and the like.
  • These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory result in an article of manufacture comprising instruction means, the instructions
  • the apparatus implements the functions specified in the flow or flow of the flowcharts and/or the block or blocks of the block diagrams.

Abstract

Disclosed are a method for preventing an inadvertent touch and an electronic device, for use in solving the problem of the electronic device being inadvertently touched during use. With the employment of the embodiments of the present application, the electronic device can accurately detect whether it is currently in a shielded state, when the electronic device is determined to be in a shielded scenario such as being in a pocket or backpack, the electronic device automatically turns on an inadvertent touch prevention function, such as the electronic device turning off the screen, not responding to a screen unlock, not responding to screen-waking by lifting, not responding to incoming call pickup by lifting, and turning off AOD, thus preventing the occurrence of an inadvertent touch, reducing the power consumption of the electronic device, providing a user with a friendly operating environment, and enhancing user experience. In addition, an ultrasonic sensor is employed in place of an optical proximity sensor to implement the inadvertent touch prevention function, the number of electronic components of the electronic device is reduced, a front opening on the screen is obviated, the edge frame space of the electronic device is narrowed, the screen-to-body ratio of the electronic device is increased, and the dust resistance and water resistance of the electronic device are increased.

Description

一种防误触的方法及电子设备Method and electronic device for preventing accidental touch
本申请要求于2020年7月31日提交中国专利局、申请号为202010762072.5、申请名称为“一种防误触的方法及电子设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese patent application with the application number 202010762072.5 and the application title "A Method and Electronic Device for Preventing Accidental Touch" filed with the China Patent Office on July 31, 2020, the entire contents of which are incorporated by reference in in this application.
技术领域technical field
本申请涉及终端领域,尤其涉及一种防误触的方法及电子设备。The present application relates to the field of terminals, and in particular, to a method and electronic device for preventing accidental touch.
背景技术Background technique
在生活中,手机屏幕的误触会给用户带来差劲的体验,例如,在用户通话过程中屏幕没有处于熄灭状态时,误碰到挂断按键导致通话中断;由于皮肤等电容性因素,在口袋或背包中手机被误解锁或误点应用程序等等,可能会给用户带来舆情或退机风险。因此,准确的检测手机所处的状态,以及防止误触情形的发生可以提升用户的使用体验。In daily life, the mistaken touch of the mobile phone screen will bring a bad experience to the user. For example, when the user's screen is not turned off during a call, the call is interrupted by accidentally hitting the hang-up button; due to capacitive factors such as skin, The mobile phone in the pocket or backpack is unlocked by mistake or the application is clicked by mistake, etc., which may bring public opinion or risk of withdrawal to the user. Therefore, accurate detection of the state of the mobile phone and prevention of accidental touches can improve the user experience.
发明内容SUMMARY OF THE INVENTION
本申请提供一种防误触的方法及电子设备,用来解决电子设备在使用中的误触问题。The present application provides a method and electronic device for preventing accidental touch, which are used to solve the problem of accidental touch in use of the electronic device.
第一方面,本申请实施例提供了一种防误触的方法,应用于电子设备上,电子设备包括超声波发射器和超声波接收器,其中,该方法包括:In a first aspect, an embodiment of the present application provides a method for preventing accidental touch, which is applied to an electronic device, where the electronic device includes an ultrasonic transmitter and an ultrasonic receiver, wherein the method includes:
超声波发射器发射N次超声波信号,每一次超声波信号包括多个超声波信号,N大于或等于2,N为正整数。超声波接收器接收N次超声波回波信号,其中,一次超声波回波信号由一次超声波信号经反射产生,每一次超声波回波信号包括多个超声波回波信号。电子设备可以根据每一次接收到的超声波回波信号得到第一数据,第一数据包括多个超声波回波信号的信号强度、传播时间。电子设备可以根据N次超声波回波信号的第一数据,得到电子设备所处的第一场景类型。第一场景类型可以为有遮挡场景或无遮挡场景,如果第一场景类型为有遮挡场景,则电子设备开启防误触功能。The ultrasonic transmitter transmits ultrasonic signals N times, each ultrasonic signal includes multiple ultrasonic signals, N is greater than or equal to 2, and N is a positive integer. The ultrasonic receiver receives N times of ultrasonic echo signals, wherein one ultrasonic echo signal is generated by the reflection of one ultrasonic signal, and each ultrasonic echo signal includes a plurality of ultrasonic echo signals. The electronic device may obtain first data according to each received ultrasonic echo signal, where the first data includes signal strengths and propagation times of multiple ultrasonic echo signals. The electronic device may obtain the first scene type in which the electronic device is located according to the first data of the N ultrasonic echo signals. The first scene type may be an occlusion scene or a non-occlusion scene. If the first scene type is a occlusion scene, the electronic device enables the anti-mistouch function.
实施第一方面的方法,在检测到电子设备当前在口袋或背包中等被遮挡的场景时,电子设备可以自动启动防误触功能,从而可以防止误触情况的发生以及降低电子设备的功耗,给用户提供了一个友好的操作环境,提升了用户的使用体验。By implementing the method of the first aspect, when it is detected that the electronic device is currently blocked in a pocket or a backpack, the electronic device can automatically activate the anti-mistouch function, so as to prevent the occurrence of false touches and reduce the power consumption of the electronic device, It provides users with a friendly operating environment and improves the user experience.
结合第一方面,在一些实施例中,超声波发射器和超声波接收器设置在电子设备的顶部,其中该顶部还设置有电子设备的以下任意一项或多项:听筒、前置摄像头、麦克风、接近光传感器、环境光传感器等。In combination with the first aspect, in some embodiments, the ultrasonic transmitter and the ultrasonic receiver are arranged on the top of the electronic device, wherein the top is further provided with any one or more of the following electronic devices: an earpiece, a front-facing camera, a microphone, Proximity light sensor, ambient light sensor, etc.
结合第一方面,在一些实施例中,超声波发射器集成在所述听筒中,或者,听筒即为超声波发射器,可以发射超声波信号。With reference to the first aspect, in some embodiments, an ultrasonic transmitter is integrated in the earpiece, or the earpiece is an ultrasonic transmitter, which can transmit ultrasonic signals.
结合第一方面,在一些实施例中,超声波接收器集成在所述麦克风中,或者,麦克风即为超声波接收器,可以接收超声波信号。With reference to the first aspect, in some embodiments, an ultrasonic receiver is integrated in the microphone, or the microphone is an ultrasonic receiver, which can receive ultrasonic signals.
结合第一方面,在一些实施例中,该方法还可以具体包括:电子设备将N次超声波回波信号的第一数据输入到第一分类模型,得到电子设备所处的第一场景类型。第一分类模 型是利用第一训练数据对第一训练模型进行训练得到的,第一训练数据可以包括S个样本数据,S大于或等于2,S为正整数。S个样本数据包括在多个已知场景类型下获得的样本数据,一个样本数据包括一个已知场景类型下发射N次超声波信号所产生的N次超声波回波信号的第二数据。第二数据包括多个超声波回波信号的信号强度、传播时间等信息。已知多个场景类型包括:无遮挡场景、有遮挡场景。With reference to the first aspect, in some embodiments, the method may further specifically include: the electronic device inputs the first data of the N times ultrasonic echo signals into the first classification model to obtain the first scene type in which the electronic device is located. The first classification model is obtained by using the first training data to train the first training model, and the first training data may include S sample data, S is greater than or equal to 2, and S is a positive integer. The S pieces of sample data include sample data obtained under multiple known scene types, and one sample data includes second data of N times ultrasonic echo signals generated by transmitting N times ultrasonic signals under one known scene type. The second data includes information such as signal strength and propagation time of the plurality of ultrasonic echo signals. Several known scene types include: unoccluded scene and occluded scene.
结合第一方面,在一些实施例中,该方法还可以具体包括:电子设备将N次超声波回波信号的第一数据生成第一图像,该第一图像的色彩值表示超声波回波信号的信号强度,该第一图像的横轴坐标表示超声波回波信号的接收批次,该第一图像的纵轴坐标可以表示从发射超声波信号到接收到超声波回波信号的传输时间。然后电子设备将该第一图像输入到第一分类模型,可以得到电子设备所处的第一场景类型。类似的,一个样本数据包括一个已知场景类型对应的第二图像,该第二图像由N次超声波回波信号的第二数据生成,该第二图像的色彩值表示在一个已知场景类型下接收超声波回波信号的信号强度,该第二图像的横轴坐标表示在一个已知场景类型下接收的超声波回波信号的接受批次,该第二图像的纵轴坐标表示在一个已知场景类型下发射超声波信号到接收到超声波回波信号的传输时间。With reference to the first aspect, in some embodiments, the method may further specifically include: the electronic device generates a first image from the first data of the N-th ultrasonic echo signal, and the color value of the first image represents the signal of the ultrasonic echo signal Intensity, the horizontal axis of the first image represents the receiving batch of ultrasonic echo signals, and the vertical axis of the first image can represent the transmission time from transmitting ultrasonic signals to receiving ultrasonic echo signals. Then, the electronic device inputs the first image into the first classification model, and the first scene type in which the electronic device is located can be obtained. Similarly, a sample data includes a second image corresponding to a known scene type, the second image is generated from the second data of the N times ultrasonic echo signals, and the color value of the second image indicates that under a known scene type The signal strength of the received ultrasonic echo signal, the abscissa coordinate of the second image represents the acceptance batch of ultrasonic echo signals received in a known scene type, and the vertical axis coordinate of the second image represents a known scene The transmission time from the transmission of ultrasonic signals to the reception of ultrasonic echo signals.
结合第一方面,在一些实施例中,第一训练模型可以为极端梯度提升XGBoost模型,或神经网络NN模型,或梯度提升决策树GBDT模型,或随机森林RF模型。With reference to the first aspect, in some embodiments, the first training model may be an extreme gradient boosting XGBoost model, or a neural network NN model, or a gradient boosting decision tree GBDT model, or a random forest RF model.
结合第一方面,在一些实施例中,有遮挡场景可以包括以下任意一项或多项:电子设备位于口袋中、电子设备位于箱包中、电子设备被书本遮挡、电子设备被头发遮挡、电子设备被手掌遮挡、电子设备被衣物遮挡等等。With reference to the first aspect, in some embodiments, the occluded scene may include any one or more of the following: the electronic device is located in a pocket, the electronic device is located in a bag, the electronic device is blocked by a book, the electronic device is blocked by hair, the electronic device Covered by palms, electronic devices covered by clothing, etc.
结合第一方面,在一些实施例中,防误触功能包括以下任意一项或多项:电子设备熄屏、电子设备不响应指纹解锁屏幕、电子设备不响应人脸识别解锁屏幕、电子设备不响应上滑解锁屏幕、电子设备不响应手势解锁屏幕、电子设备不响应抬手亮屏、电子设备不响应抬手接听来电、电子设备不响应指纹接听来电等。With reference to the first aspect, in some embodiments, the anti-mistouch function includes any one or more of the following: the screen of the electronic device is turned off, the electronic device does not respond to fingerprints to unlock the screen, the electronic device does not respond to face recognition to unlock the screen, the electronic device does not respond to face recognition to unlock the screen, Respond to sliding up to unlock the screen, the electronic device does not respond to gestures to unlock the screen, the electronic device does not respond to raising the hand to brighten the screen, the electronic device does not respond to raising the hand to answer incoming calls, the electronic device does not respond to fingerprints to answer incoming calls, etc.
结合第一方面,在一些实施例中,当检测到电子设备处于娱乐场景时,电子设备关闭防误触功能,娱乐场景可以包括以下任意一项或多项:电子设备播放视频、播放音乐、运行游戏等。With reference to the first aspect, in some embodiments, when it is detected that the electronic device is in an entertainment scene, the electronic device turns off the anti-mistouch function, and the entertainment scene may include any one or more of the following: the electronic device plays video, plays music, runs games etc.
结合第一方面,在一些实施例中,如果接近光传感器没有检测到物体遮挡,则电子设备不开启防误触功能。With reference to the first aspect, in some embodiments, if the proximity light sensor does not detect that the object is blocked, the electronic device does not enable the anti-mistouch function.
结合第一方面,在一些实施例中,如果环境光传感器检测到环境光亮度高于第一亮度值,例如10勒克斯(lx),则电子设备不开启防误触功能。With reference to the first aspect, in some embodiments, if the ambient light sensor detects that the ambient light brightness is higher than the first brightness value, eg, 10 lux (lx), the electronic device does not enable the accidental touch prevention function.
结合第一方面,在一些实施例中,超声波发射器可以以发射周期T间隔发射N次超声波信号,一次超声波信号的持续发射时间t小于超声波信号的发射周期T。In combination with the first aspect, in some embodiments, the ultrasonic transmitter may transmit ultrasonic signals N times at intervals of a transmission period T, and the continuous transmission time t of one ultrasonic signal is shorter than the transmission period T of the ultrasonic signal.
第二方面,本申请实施例提供了一种电子设备,该电子设备包括:超声波发射器、超声波接收器、显示屏、存储器以及耦合于所述存储器的处理器,存储器中存储有数据和可执行指令。其中,处理器可以通过超声波发射器发射N次超声波信号,每一次超声波信号包括多个超声波信号,N大于或等于2,N为正整数。处理器可以通过超声波接收器接收N次超声波回波信号,其中,一次超声波回波信号由一次超声波信号经反射产生,每一次 超声波回波信号包括多个超声波回波信号。处理器还可以根据每一次接收到的超声波回波信号得到第一数据,第一数据包括多个超声波回波信号的信号强度、传播时间。处理器可以根据N次超声波回波信号的第一数据,得到电子设备所处的第一场景类型。第一场景类型可以为有遮挡场景或无遮挡场景,如果第一场景类型为有遮挡场景,则处理器控制显示屏开启防误触功能。In a second aspect, an embodiment of the present application provides an electronic device, the electronic device includes: an ultrasonic transmitter, an ultrasonic receiver, a display screen, a memory, and a processor coupled to the memory, where data and executable data are stored in the memory instruction. Wherein, the processor can transmit ultrasonic signals N times through the ultrasonic transmitter, each ultrasonic signal includes multiple ultrasonic signals, N is greater than or equal to 2, and N is a positive integer. The processor can receive N times ultrasonic echo signals through the ultrasonic receiver, wherein, one ultrasonic echo signal is generated by the reflection of one ultrasonic signal, and each ultrasonic echo signal includes a plurality of ultrasonic echo signals. The processor may also obtain first data according to each received ultrasonic echo signal, where the first data includes signal strengths and propagation times of multiple ultrasonic echo signals. The processor may obtain the first scene type in which the electronic device is located according to the first data of the N ultrasonic echo signals. The first scene type may be an occlusion scene or a non-occlusion scene. If the first scene type is an occlusion scene, the processor controls the display screen to enable the anti-mistouch function.
采用第一方面的电子设备,在检测到电子设备当前在口袋或背包中等被遮挡的场景时,电子设备可以自动启动防误触功能,从而可以防止误触情况的发生以及降低电子设备的功耗,给用户提供了一个友好的操作环境,提升了用户的使用体验。Using the electronic device of the first aspect, when it is detected that the electronic device is currently blocked in a pocket or a backpack, the electronic device can automatically activate the anti-mistouch function, so as to prevent the occurrence of false touches and reduce the power consumption of the electronic device , provides users with a friendly operating environment and improves the user experience.
结合第二方面,在一些实施例中,超声波发射器和超声波接收器设置在电子设备的顶部,其中该顶部还设置有电子设备的以下任意一项或多项:听筒、前置摄像头、麦克风、接近光传感器、环境光传感器等。In combination with the second aspect, in some embodiments, the ultrasonic transmitter and the ultrasonic receiver are arranged on the top of the electronic device, wherein the top is further provided with any one or more of the following electronic devices: an earpiece, a front-facing camera, a microphone, Proximity light sensor, ambient light sensor, etc.
结合第二方面,在一些实施例中,超声波发射器集成在所述听筒中,或者,听筒即为超声波发射器,可以发射超声波信号。With reference to the second aspect, in some embodiments, an ultrasonic transmitter is integrated into the earpiece, or the earpiece is an ultrasonic transmitter, which can transmit ultrasonic signals.
结合第二方面,在一些实施例中,超声波接收器集成在所述麦克风中,或者,麦克风即为超声波接收器,可以接收超声波信号。With reference to the second aspect, in some embodiments, an ultrasonic receiver is integrated in the microphone, or the microphone is an ultrasonic receiver, which can receive ultrasonic signals.
结合第二方面,在一些实施例中,还可以具体包括:处理器将N次超声波回波信号的第一数据输入到第一分类模型,得到电子设备所处的第一场景类型。第一分类模型是利用第一训练数据对第一训练模型进行训练得到的,第一训练数据可以包括S个样本数据,S大于或等于2,S为正整数。S个样本数据包括在多个已知场景类型下获得的样本数据,一个样本数据包括一个已知场景类型下发射N次超声波信号所产生的N次超声波回波信号的第二数据。第二数据包括多个超声波回波信号的信号强度、传播时间等信息。已知多个场景类型包括:无遮挡场景、有遮挡场景。With reference to the second aspect, in some embodiments, it may further include: the processor inputs the first data of the N times ultrasonic echo signals into the first classification model to obtain the first scene type in which the electronic device is located. The first classification model is obtained by using the first training data to train the first training model. The first training data may include S sample data, where S is greater than or equal to 2, and S is a positive integer. The S pieces of sample data include sample data obtained under multiple known scene types, and one sample data includes second data of N times ultrasonic echo signals generated by transmitting N times ultrasonic signals under one known scene type. The second data includes information such as signal strength and propagation time of the plurality of ultrasonic echo signals. Several known scene types include: unoccluded scene and occluded scene.
结合第二方面,在一些实施例中,还可以具体包括:处理器将N次超声波回波信号的第一数据生成第一图像,该第一图像的色彩值表示超声波回波信号的信号强度,该第一图像的横轴坐标表示超声波回波信号的接收批次,该第一图像的纵轴坐标可以表示从发射超声波信号到接收到超声波回波信号的传输时间。然后处理器将该第一图像输入到第一分类模型,可以得到电子设备所处的第一场景类型。类似的,一个样本数据包括一个已知场景类型对应的第二图像,该第二图像由N次超声波回波信号的第二数据生成,该第二图像的色彩值表示在一个已知场景类型下接收超声波回波信号的信号强度,该第二图像的横轴坐标表示在一个已知场景类型下接收的超声波回波信号的接受批次,该第二图像的纵轴坐标表示在一个已知场景类型下发射超声波信号到接收到超声波回波信号的传输时间。With reference to the second aspect, in some embodiments, it may further specifically include: the processor generates a first image from the first data of the N times ultrasonic echo signals, and the color value of the first image represents the signal strength of the ultrasonic echo signals, The abscissa coordinate of the first image represents the receiving batch of ultrasonic echo signals, and the ordinate axis coordinate of the first image may represent the transmission time from transmitting the ultrasonic signal to receiving the ultrasonic echo signal. Then, the processor inputs the first image into the first classification model, and can obtain the first scene type in which the electronic device is located. Similarly, a sample data includes a second image corresponding to a known scene type, the second image is generated from the second data of the N times ultrasonic echo signals, and the color value of the second image indicates that under a known scene type The signal strength of the received ultrasonic echo signal, the abscissa coordinate of the second image represents the acceptance batch of ultrasonic echo signals received in a known scene type, and the vertical axis coordinate of the second image represents a known scene The transmission time from the transmission of ultrasonic signals to the reception of ultrasonic echo signals.
结合第二方面,在一些实施例中,第一训练模型可以为极端梯度提升XGBoost模型,或神经网络NN模型,或梯度提升决策树GBDT模型,或随机森林RF模型。With reference to the second aspect, in some embodiments, the first training model may be an extreme gradient boosting XGBoost model, or a neural network NN model, or a gradient boosting decision tree GBDT model, or a random forest RF model.
结合第二方面,在一些实施例中,有遮挡场景可以包括以下任意一项或多项:电子设备位于口袋中、电子设备位于箱包中、电子设备被书本遮挡、电子设备被头发遮挡、电子设备被手掌遮挡、电子设备被衣物遮挡等等。In conjunction with the second aspect, in some embodiments, the occluded scene may include any one or more of the following: the electronic device is located in a pocket, the electronic device is located in a bag, the electronic device is occluded by a book, the electronic device is occluded by hair, the electronic device Covered by palms, electronic devices covered by clothing, etc.
结合第二方面,在一些实施例中,防误触功能包括以下任意一项或多项:电子设备熄屏、电子设备不响应指纹解锁屏幕、电子设备不响应人脸识别解锁屏幕、电子设备不响应 上滑解锁屏幕、电子设备不响应手势解锁屏幕、电子设备不响应抬手亮屏、电子设备不响应抬手接听来电、电子设备不响应指纹接听来电等。With reference to the second aspect, in some embodiments, the anti-mistouch function includes any one or more of the following: the electronic device turns off the screen, the electronic device does not respond to fingerprints to unlock the screen, the electronic device does not respond to face recognition to unlock the screen, the electronic device does not respond to face recognition to unlock the screen, Respond to sliding up to unlock the screen, the electronic device does not respond to gestures to unlock the screen, the electronic device does not respond to raising the hand to brighten the screen, the electronic device does not respond to raising the hand to answer incoming calls, the electronic device does not respond to fingerprints to answer incoming calls, etc.
结合第二方面,在一些实施例中,当检测到处于娱乐场景时,处理器关闭防误触功能,娱乐场景可以包括以下任意一项或多项:播放视频、播放音乐、运行游戏等。With reference to the second aspect, in some embodiments, when it is detected that the processor is in an entertainment scene, the processor turns off the anti-mistouch function, and the entertainment scene may include any one or more of the following: playing video, playing music, running games, and the like.
结合第二方面,在一些实施例中,如果接近光传感器没有检测到物体遮挡,则处理器不开启防误触功能。With reference to the second aspect, in some embodiments, if the proximity light sensor does not detect that the object is blocked, the processor does not enable the anti-mistouch function.
结合第二方面,在一些实施例中,如果环境光传感器检测到环境光亮度高于第一亮度值,例如10勒克斯(lx),则处理器不开启防误触功能。In combination with the second aspect, in some embodiments, if the ambient light sensor detects that the ambient light brightness is higher than the first brightness value, eg, 10 lux (lx), the processor does not enable the false-touch prevention function.
结合第二方面,在一些实施例中,超声波发射器可以以发射周期T间隔发射N次超声波信号,一次超声波信号的持续发射时间t小于超声波信号的发射周期T。With reference to the second aspect, in some embodiments, the ultrasonic transmitter may transmit ultrasonic signals N times at intervals of a transmission period T, and the continuous transmission time t of one ultrasonic signal is less than the transmission period T of the ultrasonic signal.
第三方面,本申请实施例提供了一种计算机可读存储介质,该计算机可读存储介质中存储有计算机程序,该计算机程序在电子设备上运行时,使得所述电子设备执行如第一方面所提供的方法对应的操作。In a third aspect, an embodiment of the present application provides a computer-readable storage medium, where a computer program is stored in the computer-readable storage medium, and when the computer program runs on an electronic device, the electronic device performs the execution of the first aspect The operation corresponding to the provided method.
第四方面,本本申请实施例提供了一种计算机程序产品,当计算机程序产品在计算机上运行时,使得计算机执行如上述第一方面所述的方法。In a fourth aspect, an embodiment of the present application provides a computer program product, which, when the computer program product runs on a computer, causes the computer to execute the method described in the first aspect.
根据本申请的技术方案,电子设备可以准确检测当前所处的状态,当判断到电子设备当前在口袋或背包中等被遮挡的特定场景时,电子设备可以自动启动防误触功能,比如电子设备熄屏、不响应屏幕解锁(可以包括上滑屏幕解锁、指纹解锁、手势解锁、人脸识别解锁等)、不响应抬手亮屏、不响应抬手接听来电、不响应指纹接听来电、关闭常亮显示(always on display,AOD)等等,可以防止误触情况的发生以及通过间隔发射超声波信号的方式降低了电子设备的功耗,给用户提供了一个友好的操作环境,提升了用户的使用体验。本申请的技术方案中,超声波信号可以通过设定占空比的方式进行间隔发射,相比现有超声波信号持续测距检测障碍物的方法来说降低了功耗,可以实现在低功耗常开状态下判断当前电子设备是否被遮挡。本申请方案可以有效识别电子设备周围的静态物体,使得电子设备可以在口袋里、背包里等场景中更有效、更精确地判断当前电子设备是否处于被遮挡的状态。另外,采用超声波传感器替代光学接近传感器实现防误触功能,还可以减少电子设备的电子器件以及节省屏幕的正面开孔,缩窄电子设备的边框空间,提升电子设备的屏占比,提高电子设备的抗尘防水性能等。According to the technical solution of the present application, the electronic device can accurately detect the current state. When it is determined that the electronic device is currently blocked in a pocket or a backpack, the electronic device can automatically activate the anti-mistouch function, such as turning off the electronic device. Screen, do not respond to screen unlocking (which can include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.), do not respond to raising your hand to brighten the screen, do not respond to raising your hand to answer incoming calls, do not respond to fingerprints to answer incoming calls, turn off always on Display (always on display, AOD), etc., can prevent the occurrence of false touches and reduce the power consumption of electronic devices by transmitting ultrasonic signals at intervals, providing users with a friendly operating environment and improving user experience. . In the technical solution of the present application, the ultrasonic signal can be transmitted at intervals by setting the duty ratio, which reduces the power consumption compared with the existing method of continuously measuring the distance of the ultrasonic signal to detect obstacles, and can achieve low power consumption and constant In the open state, determine whether the current electronic device is blocked. The solution of the present application can effectively identify static objects around the electronic device, so that the electronic device can more effectively and accurately determine whether the current electronic device is in a blocked state in scenarios such as pockets and backpacks. In addition, the use of ultrasonic sensors instead of optical proximity sensors to achieve the anti-mistouch function can also reduce the number of electronic devices in electronic devices and save the front opening of the screen, narrow the frame space of electronic devices, increase the screen ratio of electronic devices, and improve electronic devices. Dust and water resistance, etc.
附图说明Description of drawings
图1是本申请实施例提供的一种电子设备的硬件结构示意性图;1 is a schematic diagram of a hardware structure of an electronic device provided by an embodiment of the present application;
图2是本申请实施例提供的一种电子设备的软件结构框图;2 is a software structural block diagram of an electronic device provided by an embodiment of the present application;
图3a是本申请实施例提供的一种电子设备外观示意性图;3a is a schematic diagram of the appearance of an electronic device provided by an embodiment of the present application;
图3b是本申请实施例提供的一种超声波发射声场的示意性图;Figure 3b is a schematic diagram of an ultrasonic emission sound field provided by an embodiment of the present application;
图3c是本申请实施例提供的一种超声波回波路径的示意性图;3c is a schematic diagram of an ultrasonic echo path provided by an embodiment of the present application;
图4是本申请实施例提供的一些场景下超声波回波信号的冲击响应的示例图;4 is an example diagram of an impulse response of an ultrasonic echo signal in some scenarios provided by an embodiment of the present application;
图5a是本申请实施例提供的一种用户场景的示意性图;FIG. 5a is a schematic diagram of a user scenario provided by an embodiment of the present application;
图5b是本申请实施例提供的一种用户场景的示意性图;FIG. 5b is a schematic diagram of a user scenario provided by an embodiment of the present application;
图5c是本申请实施例提供的一种用户场景的示意性图;FIG. 5c is a schematic diagram of a user scenario provided by an embodiment of the present application;
图6a是本申请实施例提供的一种用户界面的示意性图;6a is a schematic diagram of a user interface provided by an embodiment of the present application;
图6b是本申请实施例提供的一种用户界面的示意性图;6b is a schematic diagram of a user interface provided by an embodiment of the present application;
图7是本申请实施例提供的一种防误触的方法流程图;7 is a flowchart of a method for preventing false touches provided by an embodiment of the present application;
图8是本申请实施例提供的一些场景下超声波回波信号的信号强度图;8 is a signal strength diagram of an ultrasonic echo signal in some scenarios provided by an embodiment of the present application;
图9是本申请实施例提供的卷积神经网络算法的示意图;9 is a schematic diagram of a convolutional neural network algorithm provided by an embodiment of the present application;
图10是本申请实施例提供的一种防误触的电子设备的功能模块框图。FIG. 10 is a block diagram of functional modules of an electronic device for preventing accidental touches provided by an embodiment of the present application.
具体实施方式detailed description
下面结合附图对本申请实施例进行具体说明。本申请以下实施例中所使用的术语只是为了描述特定实施例的目的,而并非旨在作为对本申请的限制。如在本申请的说明书和所附权利要求书中所使用的那样,单数表达形式“一个”、“一种”、“所述”、“上述”、“该”和“这一”旨在也包括复数表达形式,除非其上下文中明确地有相反指示。还应当理解,本申请中使用的术语“和/或”是指并包含一个或多个所列出项目的任何或所有可能组合。The embodiments of the present application will be described in detail below with reference to the accompanying drawings. The terms used in the following embodiments of the present application are only for the purpose of describing specific embodiments, and are not intended to be used as limitations of the present application. As used in the specification of this application and the appended claims, the singular expressions "a," "an," "the," "above," "the," and "the" are intended to also Plural expressions are included unless the context clearly dictates otherwise. It will also be understood that, as used in this application, the term "and/or" refers to and includes any and all possible combinations of one or more of the listed items.
电子设备(如手机、平板电脑等触控式终端)放在口袋、背包中时,由于皮肤等电容性因素,可能导致电子设备屏幕被解锁或误触等情况发生,降低了用户体验。本申请提供一种防误触的方法及电子设备,用来解决电子设备在使用中的误触问题。本申请基于机器学习,通过断续发射超声波并采集超声波遇到障碍物所反射的回波,根据回波的信号特征,检测当前电子设备是否处于被遮挡的状态,当判断到电子设备当前在口袋或背包中等被遮挡的场景时,电子设备可以自动启动防误触模式,在防误触模式下,电子设备不响应触摸操作、屏幕解锁、抬手亮屏、AOD等指令。When electronic devices (such as mobile phones, tablet computers and other touch-sensitive terminals) are placed in pockets or backpacks, due to capacitive factors such as skin, the screen of the electronic device may be unlocked or accidentally touched, which reduces the user experience. The present application provides a method and electronic device for preventing accidental touch, which are used to solve the problem of accidental touch in use of the electronic device. This application is based on machine learning, by intermittently transmitting ultrasonic waves and collecting the echoes reflected by the ultrasonic waves encountering obstacles, and according to the signal characteristics of the echoes, it is detected whether the current electronic device is in a blocked state. When it is determined that the electronic device is currently in the pocket Or when the backpack is blocked, the electronic device can automatically activate the anti-mistouch mode. In the anti-mistouch mode, the electronic device does not respond to touch operations, unlock the screen, raise the hand to brighten the screen, AOD and other commands.
根据本申请的技术方案,电子设备可以准确检测当前是否处于被遮挡的状态,当判断到电子设备当前在口袋或背包中等被遮挡的场景时,电子设备可以自动启动防误触功能,比如电子设备熄屏、不响应屏幕解锁(可以包括上滑屏幕解锁、指纹解锁、手势解锁、人脸识别解锁等)、不响应抬手亮屏、不响应抬手接听来电、关闭AOD等等,可以防止误触情况的发生以及降低电子设备的功耗,给用户提供了一个友好的操作环境,提升了用户的使用体验。另外,采用超声波传感器替代光学接近传感器实现防误触功能,还可以减少电子设备的电子器件以及节省屏幕的正面开孔,缩窄电子设备的边框空间,提升电子设备的屏占比,提高电子设备的抗尘防水性能等,超声波传感器适用情形还更为广泛,尤其是在强光、水雾等情形下,光学接近传感器容易失效。According to the technical solution of the present application, the electronic device can accurately detect whether it is currently in a blocked state, and when it is determined that the electronic device is currently blocked in a pocket or a backpack, the electronic device can automatically activate the anti-mistouch function, such as the electronic device Turn off the screen, do not respond to screen unlocking (which can include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.), do not respond to raising your hand to brighten the screen, do not respond to raising your hand to answer incoming calls, turn off AOD, etc., to prevent false positives. The occurrence of a touch situation and the power consumption of the electronic device are reduced, a user-friendly operating environment is provided, and the user experience is improved. In addition, the use of ultrasonic sensors instead of optical proximity sensors to achieve the anti-mistouch function can also reduce the number of electronic devices in electronic devices and save the front opening of the screen, narrow the frame space of electronic devices, increase the screen ratio of electronic devices, and improve electronic devices. The application of ultrasonic sensors is more extensive, especially in the case of strong light, water mist, etc., the optical proximity sensor is easy to fail.
现有技术中有一种方案是通过超声波信号持续测距来判断是否有物体动态的靠近或远离。具体地,电子设备持续发射超声波信号,通过获取超声波信号从发射到接受回波的时间和信号强度的变化,从而判断电子设备附近是否有物体在动态靠近或远离。在该方案中,超声波信号需要持续发射,音频通路需要一直处于开启状态,功耗较大;并且由于不同障碍物的材质、位置不同,超声波信号遇到不同障碍物反射的超声波回波信号的时间、信号强度等也不尽相同,所以该方案只能对物体动态运动过程进行有效检测,无法明确分辨静止状态的障碍物是否在遮挡电子设备。在本申请的技术方案中,将接受到的超声波回波信号数据生成特征图像,输入已经训练好的机器学习模型,得到对应的场景类型,实现对电 子设备当前是否处于被障碍物遮挡的状态的判断,进而开启防误触功能。其中,超声波信号可以通过设定占空比的方式进行间隔发射,相比前述超声波信号测距方案来说降低了功耗,可以实现在低功耗常开状态下判断当前电子设备是否被遮挡。另外,本申请方案可以有效识别电子设备周围的静态物体,使得电子设备可以在口袋里、背包里等场景中更有效、更精确地判断当前电子设备是否处于被遮挡的状态。One of the solutions in the prior art is to use ultrasonic signals to continuously measure distances to determine whether an object is dynamically approaching or moving away. Specifically, the electronic device continuously transmits ultrasonic signals, and by acquiring the time and signal strength changes of the ultrasonic signals from transmitting to receiving echoes, it is judged whether an object is dynamically approaching or moving away near the electronic device. In this solution, the ultrasonic signal needs to be continuously transmitted, the audio channel needs to be turned on all the time, and the power consumption is large; and due to the different materials and positions of different obstacles, the time for the ultrasonic signal to encounter the ultrasonic echo signal reflected by different obstacles , signal strength, etc. are also different, so this solution can only effectively detect the dynamic motion of objects, and cannot clearly distinguish whether obstacles in a stationary state are blocking electronic equipment. In the technical solution of the present application, a characteristic image is generated from the received ultrasonic echo signal data, and a trained machine learning model is input to obtain the corresponding scene type, so as to realize the status of whether the electronic device is currently blocked by an obstacle. judgment, and then turn on the anti-mistouch function. Among them, the ultrasonic signal can be transmitted at intervals by setting the duty cycle, which reduces the power consumption compared with the aforementioned ultrasonic signal ranging scheme, and can determine whether the current electronic device is blocked in the low-power normally-on state. In addition, the solution of the present application can effectively identify static objects around the electronic device, so that the electronic device can more effectively and accurately determine whether the current electronic device is in a blocked state in scenarios such as pockets and backpacks.
超声波是频率高于20000赫兹(Hz)的声波,由于人类耳朵可以辨别到的声波频率大概为20~20000Hz,一般当声波的振动频率大于20000Hz时,人耳无法听到,超声波的频率下限大约等于人的听觉上限,因此称为超声波。Ultrasound is a sound wave with a frequency higher than 20,000 hertz (Hz). Since the frequency of the sound wave that can be discerned by the human ear is about 20 to 20,000 Hz, generally when the vibration frequency of the sound wave is greater than 20,000 Hz, the human ear cannot hear it. The lower limit of the frequency of the ultrasonic wave is approximately equal to The upper limit of human hearing, so it is called ultrasound.
首先介绍本申请实施例中提供的示例性电子设备100。应该理解的是,电子设备100可以具有比图中所示的更多的或者更少的部件,可以组合两个或多个的部件,或者可以具有不同的部件配置。图中所示出的各种部件可以在包括一个或多个信号处理和/或专用集成电路在内的硬件、软件、或硬件和软件的组合中实现。First, the exemplary electronic device 100 provided in the embodiment of the present application is introduced. It should be understood that the electronic device 100 may have more or fewer components than those shown in the figures, may combine two or more components, or may have different component configurations. The various components shown in the figures 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.
图1为电子设备100的结构示意图。FIG. 1 is a schematic structural diagram of an electronic device 100 .
电子设备100可以包括:处理器110,外部存储器接口120,内部存储器121,通用串行总线(universal serial bus,USB)接口130,充电管理模块140,电源管理模块141,电池142,天线1,天线2,移动通信模块150,无线通信模块160,音频模块170,扬声器170A,受话器170B,麦克风170C,耳机接口170D,传感器模块180,按键190,马达191,指示器192,摄像头193,显示屏194以及用户标识模块(subscriber identification module,SIM)卡接口195等。其中传感器模块180可以包括压力传感器180A,陀螺仪传感器180B,重力传感器180C,磁传感器180D,加速度传感器180E,距离传感器180F,接近光传感器180G,指纹传感器180H,温度传感器180J,触摸传感器180K,环境光传感器180L,超声波传感器180M等。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. Mobile communication module 150, wireless communication module 160, audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, sensor module 180, buttons 190, motor 191, indicator 192, camera 193, display screen 194 and Subscriber identification module (subscriber identification module, SIM) card interface 195 and so on. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, a gravity 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, and ambient light. Sensor 180L, ultrasonic sensor 180M, etc.
可以理解的是,本申请实施例示意的结构并不构成对电子设备100的具体限定。在本申请另一些实施例中,电子设备100可以包括比图示更多或更少的部件,或者组合某些部件,或者拆分某些部件,或者不同的部件布置。图示的部件可以以硬件,软件或软件和硬件的组合实现。It can be understood that the structures illustrated in the embodiments of the present application 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 less components than shown, or combine some components, or separate some components, or arrange different components. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
处理器110可以包括一个或多个处理单元,例如:处理器110可以包括应用处理器(application processor,AP),调制解调处理器,图形处理器(graphics processing unit,GPU),图像信号处理器(image signal processor,ISP),控制器,存储器,视频编解码器,数字信号处理器(digital signal processor,DSP),基带处理器,和/或神经网络处理器(neural-network processing unit,NPU)等。其中,不同的处理单元可以是独立的器件,也可以集成在一个或多个处理器中。The processor 110 may include one or more processing units, for example, the processor 110 may include an application processor (application processor, AP), a modem processor, a graphics processor (graphics processing unit, GPU), an image signal processor (image signal processor, ISP), controller, memory, video codec, digital signal processor (digital signal processor, DSP), baseband processor, and/or neural-network processing unit (NPU) Wait. Wherein, different processing units may be independent devices, or may be integrated in one or more processors.
其中,控制器可以是电子设备100的神经中枢和指挥中心。控制器可以根据指令操作码和时序信号,产生操作控制信号,完成取指令和执行指令的控制。The controller may be the nerve center and command center of the electronic device 100 . The controller can generate an operation control signal according to the instruction operation code and timing signal, and complete the control of fetching and executing instructions.
处理器110中还可以设置存储器,用于存储指令和数据。在一些实施例中,处理器110中的存储器为高速缓冲存储器。该存储器可以保存处理器110刚用过或循环使用的指令或数据。如果处理器110需要再次使用该指令或数据,可从所述存储器中直接调用。避免了 重复存取,减少了处理器110的等待时间,因而提高了系统的效率。A memory may also be provided in the processor 110 for storing instructions and data. In some embodiments, the memory in processor 110 is cache memory. This memory may hold instructions or data that have just been used or recycled by the processor 110 . If the processor 110 needs to use the instruction or data again, it can be called directly from the memory. Repeated accesses are avoided and processor 110 latency is reduced, thereby increasing the efficiency of the system.
在一些实施例中,处理器110可以包括一个或多个接口。接口可以包括集成电路(inter-integrated circuit,I2C)接口,集成电路内置音频(inter-integrated circuit sound,I2S)接口,脉冲编码调制(pulse code modulation,PCM)接口,通用异步收发传输器(universal asynchronous receiver/transmitter,UART)接口,移动产业处理器接口(mobile industry processor interface,MIPI),通用输入输出(general-purpose input/output,GPIO)接口,用户标识模块(subscriber identity module,SIM)接口,和/或通用串行总线(universal serial bus,USB)接口等。In some embodiments, the processor 110 may include one or more interfaces. The interface may include an integrated circuit (inter-integrated circuit, I2C) interface, an integrated circuit built-in audio (inter-integrated circuit sound, I2S) interface, a pulse code modulation (pulse code modulation, PCM) interface, a universal asynchronous transceiver (universal asynchronous transmitter) receiver/transmitter, UART) interface, mobile industry processor interface (MIPI), general-purpose input/output (GPIO) interface, subscriber identity module (SIM) interface, and / or universal serial bus (universal serial bus, USB) interface, etc.
I2C接口是一种双向同步串行总线,包括一根串行数据线(serial data line,SDA)和一根串行时钟线(derail clock line,SCL)。在一些实施例中,处理器110可以包含多组I2C总线。处理器110可以通过不同的I2C总线接口分别耦合触摸传感器180K,充电器,闪光灯,摄像头193等。例如:处理器110可以通过I2C接口耦合触摸传感器180K,使处理器110与触摸传感器180K通过I2C总线接口通信,实现电子设备100的触摸功能。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 contain multiple sets of I2C buses. The processor 110 can be respectively coupled to the touch sensor 180K, the charger, the flash, the camera 193 and the like through different I2C bus interfaces. For example, the processor 110 may couple the touch sensor 180K through the I2C interface, so that the processor 110 and the touch sensor 180K communicate with each other through the I2C bus interface, so as to realize the touch function of the electronic device 100 .
I2S接口可以用于音频通信。在一些实施例中,处理器110可以包含多组I2S总线。处理器110可以通过I2S总线与音频模块170耦合,实现处理器110与音频模块170之间的通信。在一些实施例中,音频模块170可以通过I2S接口向无线通信模块160传递音频信号,实现通过蓝牙耳机接听电话的功能。The I2S interface can be used for audio communication. In some embodiments, the processor 110 may contain multiple sets of I2S buses. The processor 110 may be coupled with the audio module 170 through an I2S bus to implement 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 through the I2S interface, so as to realize the function of answering calls through a Bluetooth headset.
PCM接口也可以用于音频通信,将模拟信号抽样,量化和编码。在一些实施例中,音频模块170与无线通信模块160可以通过PCM总线接口耦合。在一些实施例中,音频模块170也可以通过PCM接口向无线通信模块160传递音频信号,实现通过蓝牙耳机接听电话的功能。所述I2S接口和所述PCM接口都可以用于音频通信。The PCM interface can also be used for audio communications, sampling, quantizing and encoding analog signals. In some embodiments, the audio module 170 and the wireless communication module 160 may be coupled through a PCM bus interface. In some embodiments, the audio module 170 can also transmit audio signals to the wireless communication module 160 through the PCM interface, so as to realize the function of answering calls through the Bluetooth headset. Both the I2S interface and the PCM interface can be used for audio communication.
UART接口是一种通用串行数据总线,用于异步通信。该总线可以为双向通信总线。它将要传输的数据在串行通信与并行通信之间转换。在一些实施例中,UART接口通常被用于连接处理器110与无线通信模块160。例如:处理器110通过UART接口与无线通信模块160中的蓝牙模块通信,实现蓝牙功能。在一些实施例中,音频模块170可以通过UART接口向无线通信模块160传递音频信号,实现通过蓝牙耳机播放音乐的功能。The UART interface is a universal serial data bus used for asynchronous communication. The bus may be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, a UART interface is typically used to connect the processor 110 with the wireless communication module 160 . For example, the processor 110 communicates with the Bluetooth module in the wireless communication module 160 through the UART interface to implement the Bluetooth function. In some embodiments, the audio module 170 can transmit audio signals to the wireless communication module 160 through the UART interface, so as to realize the function of playing music through the Bluetooth headset.
MIPI接口可以被用于连接处理器110与显示屏194,摄像头193等外围器件。MIPI接口包括摄像头串行接口(camera serial interface,CSI),显示屏串行接口(display serial interface,DSI)等。在一些实施例中,处理器110和摄像头193通过CSI接口通信,实现电子设备100的拍摄功能。处理器110和显示屏194通过DSI接口通信,实现电子设备100的显示功能。The MIPI interface can be used to connect the processor 110 with peripheral devices such as the display screen 194 and the camera 193 . MIPI interfaces include camera serial interface (CSI), display serial interface (DSI), etc. In some embodiments, the processor 110 communicates with the camera 193 through a CSI interface, so as to realize the photographing function of the electronic device 100 . The processor 110 communicates with the display screen 194 through the DSI interface to implement the display function of the electronic device 100 .
GPIO接口可以通过软件配置。GPIO接口可以被配置为控制信号,也可被配置为数据信号。在一些实施例中,GPIO接口可以用于连接处理器110与摄像头193,显示屏194,无线通信模块160,音频模块170,传感器模块180等。GPIO接口还可以被配置为I2C接口,I2S接口,UART接口,MIPI接口等。The GPIO interface can be configured by software. The GPIO interface can be configured as a control signal or as a data signal. In some embodiments, the GPIO interface may be used to connect the processor 110 with the camera 193, the display screen 194, the wireless communication module 160, the audio module 170, the sensor module 180, and the like. The GPIO interface can also be configured as I2C interface, I2S interface, UART interface, MIPI interface, etc.
SIM接口可以被用于与SIM卡接口195通信,实现传送数据到SIM卡或读取SIM卡中数据的功能。The SIM interface can be used to communicate with the SIM card interface 195 to realize the function of transferring data to the SIM card or reading data in the SIM card.
USB接口130是符合USB标准规范的接口,具体可以是Mini USB接口,Micro USB 接口,USB Type C接口等。USB接口130可以用于连接充电器为电子设备100充电,也可以用于电子设备100与外围设备之间传输数据。也可以用于连接耳机,通过耳机播放音频。该接口还可以用于连接其他电子设备,例如AR设备等。The USB interface 130 is an interface that conforms to the USB standard specification, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, and the like. The USB interface 130 can be used to connect a charger to charge the electronic device 100, and can also be used to transmit data between the electronic device 100 and peripheral devices. It can also be used to connect headphones to play audio through the headphones. The interface can also be used to connect other electronic devices, such as AR devices.
可以理解的是,本申请实施例示意的各模块间的接口连接关系,只是示意性说明,并不构成对电子设备100的结构限定。在本申请另一些实施例中,电子设备100也可以采用上述实施例中不同的接口连接方式,或多种接口连接方式的组合。It can be understood that the interface connection relationship between the modules illustrated in the embodiments of the present application is only a schematic illustration, and does not constitute a structural limitation of the electronic device 100 . In other embodiments of the present application, the electronic device 100 may also adopt different interface connection manners in the foregoing embodiments, or a combination of multiple interface connection manners.
充电管理模块140用于从充电器接收充电输入。其中,充电器可以是无线充电器,也可以是有线充电器。The charging management module 140 is used to receive charging input from the charger. The charger may be a wireless charger or a wired charger.
电源管理模块141用于连接电池142,充电管理模块140与处理器110。电源管理模块141接收电池142和/或充电管理模块140的输入,为处理器110,内部存储器121,外部存储器,显示屏194,摄像头193,和无线通信模块160等供电。The power management module 141 is used for connecting 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 supplies power to the processor 110 , the internal memory 121 , the external memory, the display screen 194 , the camera 193 , and the wireless communication module 160 .
电子设备100的无线通信功能可以通过天线1,天线2,移动通信模块150,无线通信模块160,调制解调处理器以及基带处理器等实现。The wireless communication function of the electronic device 100 may be implemented by the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modulation and demodulation processor, the baseband processor, and the like.
天线1和天线2用于发射和接收电磁波信号。电子设备100中的每个天线可用于覆盖单个或多个通信频带。不同的天线还可以复用,以提高天线的利用率。例如:可以将天线1复用为无线局域网的分集天线。在另外一些实施例中,天线可以和调谐开关结合使用。Antenna 1 and Antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in electronic device 100 may be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve antenna utilization. For example, the antenna 1 can be multiplexed as a diversity antenna of the wireless local area network. In other embodiments, the antenna may be used in conjunction with a tuning switch.
移动通信模块150可以提供应用在电子设备100上的包括2G/3G/4G/5G等无线通信的解决方案。移动通信模块150可以包括至少一个滤波器,开关,功率放大器,低噪声放大器(low noise amplifier,LNA)等。移动通信模块150可以由天线1接收电磁波,并对接收的电磁波进行滤波,放大等处理,传送至调制解调处理器进行解调。移动通信模块150还可以对经调制解调处理器调制后的信号放大,经天线1转为电磁波辐射出去。在一些实施例中,移动通信模块150的至少部分功能模块可以被设置于处理器110中。在一些实施例中,移动通信模块150的至少部分功能模块可以与处理器110的至少部分模块被设置在同一个器件中。The mobile communication module 150 may provide wireless communication solutions including 2G/3G/4G/5G etc. applied on the electronic device 100 . The mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (LNA) and the like. The mobile communication module 150 can receive electromagnetic waves from the antenna 1, filter and amplify 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 then turn it into an electromagnetic wave for radiation through the antenna 1 . In some embodiments, at least part of the functional modules of the mobile communication module 150 may be provided in the processor 110 . In some embodiments, at least part of the functional modules of the mobile communication module 150 may be provided in the same device as at least part of the modules of the processor 110 .
调制解调处理器可以包括调制器和解调器。其中,调制器用于将待发送的低频基带信号调制成中高频信号。解调器用于将接收的电磁波信号解调为低频基带信号。随后解调器将解调得到的低频基带信号传送至基带处理器处理。低频基带信号经基带处理器处理后,被传递给应用处理器。应用处理器通过音频设备(不限于扬声器170A,受话器170B等)输出声音信号,或通过显示屏194显示图像或视频。在一些实施例中,调制解调处理器可以是独立的器件。在另一些实施例中,调制解调处理器可以独立于处理器110,与移动通信模块150或其他功能模块设置在同一个器件中。The modem processor may include a modulator and a demodulator. Wherein, the modulator is used to modulate the low frequency baseband signal to be sent into a medium and high frequency signal. The demodulator is used to demodulate the received electromagnetic wave signal into a low frequency baseband signal. Then the demodulator transmits the demodulated low-frequency baseband signal to the baseband processor for processing. The low frequency baseband signal is processed by the baseband processor and passed to the application processor. The application processor outputs sound signals through audio devices (not limited to the speaker 170A, the receiver 170B, etc.), or displays images or videos through the display screen 194 . In some embodiments, the modem processor may be a stand-alone device. In other embodiments, the modem processor may be independent of the processor 110, and may be provided in the same device as the mobile communication module 150 or other functional modules.
无线通信模块160可以提供应用在电子设备100上的包括无线局域网(wireless local area networks,WLAN)(如无线保真(wireless fidelity,Wi-Fi)网络),蓝牙(bluetooth,BT),全球导航卫星系统(global navigation satellite system,GNSS),调频(frequency modulation,FM),近距离无线通信技术(near field communication,NFC),红外技术(infrared,IR)等无线通信的解决方案。无线通信模块160可以是集成至少一个通信处理模块的一个或多个器件。无线通信模块160经由天线2接收电磁波,将电磁波信号调频以及滤波处理,将处理后的信号发送到处理器110。无线通信模块160还可以从处理器110接收待发送的信 号,对其进行调频,放大,经天线2转为电磁波辐射出去。The wireless communication module 160 can provide applications on the electronic device 100 including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), bluetooth (BT), global navigation satellites Wireless communication solutions such as global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), and infrared technology (IR). The wireless communication module 160 may be one or more devices integrating 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, perform frequency modulation on it, amplify it, and convert it into an electromagnetic wave for radiation through the antenna 2.
在一些实施例中,电子设备100的天线1和移动通信模块150耦合,天线2和无线通信模块160耦合,使得电子设备100可以通过无线通信技术与网络以及其他设备通信。所述无线通信技术可以包括全球移动通讯系统(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,和/或IR技术等。所述GNSS可以包括全球卫星定位系统(global positioning system,GPS),全球导航卫星系统(global navigation satellite system,GLONASS),北斗卫星导航系统(beidou navigation satellite system,BDS),准天顶卫星系统(quasi-zenith satellite system,QZSS)和/或星基增强系统(satellite based augmentation systems,SBAS)。In some embodiments, the antenna 1 of the electronic device 100 is coupled with the mobile communication module 150, and the antenna 2 is coupled with 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), broadband 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, etc. The GNSS may include a global positioning system (global positioning system, GPS), a global navigation satellite system (GLONASS), a Beidou navigation satellite system (BDS), a quasi-zenith satellite system (quasi -zenith satellite system, QZSS) and/or satellite based augmentation systems (SBAS).
电子设备100通过GPU,显示屏194,以及应用处理器等实现显示功能。GPU为图像处理的微处理器,连接显示屏194和应用处理器。GPU用于执行数学和几何计算,用于图形渲染。处理器110可包括一个或多个GPU,其执行程序指令以生成或改变显示信息。The electronic device 100 implements a display function through a GPU, a display screen 194, an application processor, and the like. The GPU is a microprocessor for image processing, and is connected to the 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 alter display information.
显示屏194用于显示图像,视频等。显示屏194包括显示面板。显示面板可以采用液晶显示屏(liquid crystal display,LCD),有机发光二极管(organic light-emitting diode,OLED),有源矩阵有机发光二极体或主动矩阵有机发光二极体(active-matrix organic light emitting diode,AMOLED),柔性发光二极管(flex light-emitting diode,FLED),Miniled,MicroLed,Micro-oLed,量子点发光二极管(quantum dot light emitting diodes,QLED)等。在一些实施例中,电子设备100可以包括1个或N个显示屏194,N为大于1的正整数。优选的,显示屏194带有触摸功能,可称为触摸屏,即电子设备100可以根据用户触摸显示屏194的相应位置作出响应。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 or an active-matrix organic light-emitting diode (active-matrix organic light). emitting diode, AMOLED), flexible light-emitting diode (flex light-emitting diode, FLED), Miniled, MicroLed, Micro-oLed, quantum dot light-emitting diode (quantum dot light emitting diodes, QLED) and so on. In some embodiments, the electronic device 100 may include one or N display screens 194 , where N is a positive integer greater than one. Preferably, the display screen 194 has a touch function, which may be called a touch screen, that is, the electronic device 100 can respond according to the corresponding position of the user touching the display screen 194 .
电子设备100可以通过ISP,摄像头193,视频编解码器,GPU,显示屏194以及应用处理器等实现拍摄功能。The electronic device 100 may implement a shooting function through an ISP, a camera 193, a video codec, a GPU, a display screen 194, an application processor, and the like.
ISP用于处理摄像头193反馈的数据。例如,拍照时,打开快门,光线通过镜头被传递到摄像头感光元件上,光信号转换为电信号,摄像头感光元件将所述电信号传递给ISP处理,转化为肉眼可见的图像。ISP还可以对图像的噪点,亮度,肤色进行算法优化。ISP还可以对拍摄场景的曝光,色温等参数优化。在一些实施例中,ISP可以设置在摄像头193中。The ISP is used to process the data fed back by the camera 193 . For example, when taking a photo, the shutter is opened, the light is transmitted to the camera photosensitive element through the lens, the light signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing, and converts it into an image visible to the naked eye. ISP can also perform algorithm optimization on image noise, brightness, and skin tone. ISP can also optimize the exposure, color temperature and other parameters of the shooting scene. In some embodiments, the ISP may be provided in the camera 193 .
摄像头193用于捕获静态图像或视频。物体通过镜头生成光学图像投射到感光元件。感光元件可以是电荷耦合器件(charge coupled device,CCD)或互补金属氧化物半导体(complementary metal-oxide-semiconductor,CMOS)光电晶体管。感光元件把光信号转换成电信号,之后将电信号传递给ISP转换成数字图像信号。ISP将数字图像信号输出到DSP加工处理。DSP将数字图像信号转换成标准的RGB,YUV等格式的图像信号。在一些实施例中,电子设备100可以包括1个或N个摄像头193,N为大于1的正整数。Camera 193 is used to capture still images or video. The object is projected through the lens to generate an optical image onto the photosensitive element. The photosensitive element may be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the optical signal into an electrical signal, and then transmits the electrical signal to the ISP to convert it into a digital image signal. The ISP outputs the digital image signal to the DSP for processing. DSP converts digital image signals into standard RGB, YUV and other formats of image signals. In some embodiments, the electronic device 100 may include 1 or N cameras 193 , where N is a positive integer greater than 1.
数字信号处理器用于处理数字信号,除了可以处理数字图像信号,还可以处理其他数字信号。例如,当电子设备100在频点选择时,数字信号处理器用于对频点能量进行傅里 叶变换等。A 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, and the like.
视频编解码器用于对数字视频压缩或解压缩。电子设备100可以支持一种或多种视频编解码器。这样,电子设备100可以播放或录制多种编码格式的视频,例如:动态图像专家组(moving picture experts group,MPEG)1,MPEG2,MPEG3,MPEG4等。Video codecs are used to compress or decompress digital video. The electronic device 100 may support one or more video codecs. In this way, the electronic device 100 can play or record videos of various encoding formats, such as: Moving Picture Experts Group (moving picture experts group, MPEG) 1, MPEG2, MPEG3, MPEG4 and so on.
NPU为神经网络(neural-network,NN)计算处理器,通过借鉴生物神经网络结构,例如借鉴人脑神经元之间传递模式,对输入信息快速处理,还可以不断的自学习。通过NPU可以实现电子设备100的智能认知等应用,例如:图像识别,人脸识别,语音识别,文本理解等。The NPU is a neural-network (NN) computing processor. By drawing on the structure of biological neural networks, such as the transfer mode between neurons in the human brain, it can quickly process the input information, and can continuously learn by itself. Applications such as intelligent cognition of the electronic device 100 can be implemented through the NPU, such as image recognition, face recognition, speech recognition, text understanding, and the like.
外部存储器接口120可以用于连接外部存储卡,例如Micro SD卡,实现扩展电子设备100的存储能力。外部存储卡通过外部存储器接口120与处理器110通信,实现数据存储功能。例如将音乐,视频等文件保存在外部存储卡中。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 through the external memory interface 120 to realize the data storage function. For example to save files like music, video etc in external memory card.
内部存储器121可以用于存储计算机可执行程序代码,所述可执行程序代码包括指令。处理器110通过运行存储在内部存储器121的指令,从而执行电子设备100的各种功能应用以及数据处理。内部存储器121可以包括存储程序区和存储数据区。其中,存储程序区可存储操作系统,至少一个功能所需的应用(比如人脸识别功能,指纹识别功能、移动支付功能等)等。存储数据区可存储电子设备100使用过程中所创建的数据(比如人脸信息模板数据,指纹信息模板等)等。此外,内部存储器121可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件,闪存器件,通用闪存存储器(universal flash storage,UFS)等。Internal memory 121 may be used to store computer executable program code, which includes instructions. The processor 110 executes various functional applications and data processing of the electronic device 100 by executing the instructions stored in the internal memory 121 . The internal memory 121 may include a storage program area and a storage data area. The storage program area can store an operating system, an application required for at least one function (such as a face recognition function, a fingerprint recognition function, a mobile payment function, etc.) and the like. The storage data area may store data created during the use of the electronic device 100 (such as face information template data, fingerprint information template, etc.) and the like. In addition, the internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, universal flash storage (UFS), and the like.
电子设备100可以通过音频模块170,扬声器170A,受话器170B,麦克风170C,耳机接口170D,以及应用处理器等实现音频功能。例如音乐播放,录音等。The electronic device 100 may implement audio functions through an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, an application processor, and the like. Such as music playback, recording, etc.
音频模块170用于将数字音频信息转换成模拟音频信号输出,也用于将模拟音频输入转换为数字音频信号。音频模块170还可以用于对音频信号编码和解码。在一些实施例中,音频模块170可以设置于处理器110中,或将音频模块170的部分功能模块设置于处理器110中。The audio module 170 is used for converting digital audio information into analog audio signal output, and also for converting analog audio input into digital audio signal. Audio module 170 may also be used to encode and decode audio signals. In some embodiments, the audio module 170 may be provided in the processor 110 , or some functional modules of the audio module 170 may be provided in the processor 110 .
扬声器170A,也称“喇叭”,用于将音频电信号转换为声音信号。电子设备100可以通过扬声器170A收听音乐,或收听免提通话。Speaker 170A, also referred to as a "speaker", is used to convert audio electrical signals into sound signals. The electronic device 100 can listen to music through the speaker 170A, or listen to a hands-free call.
受话器170B,也称“听筒”,用于将音频电信号转换成声音信号。当电子设备100接听电话或语音信息时,可以通过将受话器170B靠近人耳接听语音。The receiver 170B, also referred to as "earpiece", is used to convert audio electrical signals into sound signals. When the electronic device 100 answers a call or a voice message, the voice can be answered by placing the receiver 170B close to the human ear.
麦克风170C,也称“话筒”,“传声器”,用于将声音信号转换为电信号。当拨打电话或发送语音信息时,用户可以通过人嘴靠近麦克风170C发声,将声音信号输入到麦克风170C。电子设备100可以设置至少一个麦克风170C。在另一些实施例中,电子设备100可以设置两个麦克风170C,除了采集声音信号,还可以实现降噪功能。在另一些实施例中,电子设备100还可以设置三个,四个或更多麦克风170C,实现采集声音信号,降噪,还可以识别声音来源,实现定向录音功能等。The microphone 170C, also called "microphone" or "microphone", is used to convert sound signals into electrical signals. When making a call or sending a voice message, the user can make a sound by approaching the microphone 170C through a human mouth, and input the sound signal into the microphone 170C. The electronic device 100 may be provided with at least one microphone 170C. In other embodiments, the electronic device 100 may be provided with two microphones 170C, which can implement a noise reduction function in addition to collecting sound signals. In other embodiments, the electronic device 100 may further be provided with three, four or more microphones 170C to collect sound signals, reduce noise, identify sound sources, and implement directional recording functions.
耳机接口170D用于连接有线耳机。耳机接口170D可以是USB接口130,也可以是3.5mm的开放移动电子设备平台(open mobile terminal platform,OMTP)标准接口,美国蜂窝电信工业协会(cellular telecommunications industry association of the USA,CTIA)标准接口。The earphone jack 170D is used to connect wired earphones. The earphone interface 170D can be the USB interface 130, or can be a 3.5mm open mobile terminal platform (OMTP) standard interface, a cellular telecommunications industry association of the USA (CTIA) standard interface.
压力传感器180A用于感受压力信号,可以将压力信号转换成电信号。在一些实施例中,压力传感器180A可以设置于显示屏194。压力传感器180A的种类很多,如电阻式压力传感器,电感式压力传感器,电容式压力传感器等。电容式压力传感器可以是包括至少两个具有导电材料的平行板。当有力作用于压力传感器180A,电极之间的电容改变。电子设备100根据电容的变化确定压力的强度。当有触摸操作作用于显示屏194,电子设备100根据压力传感器180A检测所述触摸操作强度。电子设备100也可以根据压力传感器180A的检测信号计算触摸的位置。在一些实施例中,作用于相同触摸位置,但不同触摸操作强度的触摸操作,可以对应不同的操作指令。例如:当有触摸操作强度小于第一压力阈值的触摸操作作用于短消息应用图标时,执行查看短消息的指令。当有触摸操作强度大于或等于第一压力阈值的触摸操作作用于短消息应用图标时,执行新建短消息的指令。The pressure sensor 180A is used to sense pressure signals, and can convert the pressure signals into electrical signals. In some embodiments, the pressure sensor 180A may be provided on the display screen 194 . There are many types of pressure sensors 180A, such as resistive pressure sensors, inductive pressure sensors, capacitive pressure sensors, and the like. The capacitive pressure sensor may be comprised of at least two parallel plates of conductive material. When a force is applied to the pressure sensor 180A, the capacitance between the electrodes changes. The electronic device 100 determines the intensity of the pressure according to the change in capacitance. When a touch operation acts on the display screen 194, the electronic device 100 detects the intensity of the touch operation according to the pressure sensor 180A. The electronic device 100 may also calculate the touched position according to the detection signal of the pressure sensor 180A. In some embodiments, touch operations acting on the same touch position but with different touch operation intensities may correspond to different operation instructions. For example, when a touch operation whose intensity is less than the first pressure threshold acts on the short message application icon, the instruction for viewing the short message is executed. When a touch operation with a touch operation intensity greater than or equal to the first pressure threshold acts on the short message application icon, the instruction to create a new short message is executed.
陀螺仪传感器180B可以用于确定电子设备100的运动姿态。在一些实施例中,可以通过陀螺仪传感器180B确定电子设备100围绕三个轴(即,x,y和z轴)的角速度。陀螺仪传感器180B可以用于拍摄防抖。示例性的,当按下快门,陀螺仪传感器180B检测电子设备100抖动的角度,根据角度计算出镜头模组需要补偿的距离,让镜头通过反向运动抵消电子设备100的抖动,实现防抖。陀螺仪传感器180B还可以用于导航,体感游戏场景。The gyro sensor 180B may be used to determine the motion attitude of the electronic device 100 . In some embodiments, the angular velocity of electronic device 100 about three axes (ie, x, y, and z axes) may be determined by gyro sensor 180B. The gyro sensor 180B can be used for image stabilization. Exemplarily, when the shutter is pressed, the gyro sensor 180B detects the shaking angle of the electronic device 100, calculates the distance that the lens module needs to compensate according to the angle, and allows the lens to offset the shaking of the electronic device 100 through reverse motion to achieve anti-shake. The gyro sensor 180B can also be used for navigation and somatosensory game scenarios.
重力传感器180C用于测量重力。在一些实施例中,电子设备100可以通过重力传感器180C测得重力方向、重力数据值辅助显示屏的转换。Gravity sensor 180C is used to measure gravity. In some embodiments, the electronic device 100 can measure the direction of gravity and the data value of gravity through the gravity sensor 180C to assist the conversion of the display screen.
磁传感器180D包括霍尔传感器。电子设备100可以利用磁传感器180D检测翻盖皮套的开合。在一些实施例中,当电子设备100是翻盖机时,电子设备100可以根据磁传感器180D检测翻盖的开合。进而根据检测到的皮套的开合状态或翻盖的开合状态,设置翻盖自动解锁等特性。The magnetic sensor 180D includes a Hall sensor. The electronic device 100 can detect the opening and closing of the flip holster using the magnetic sensor 180D. In some embodiments, when the electronic device 100 is a flip machine, the electronic device 100 can detect the opening and closing of the flip according to the magnetic sensor 180D. Further, according to the detected opening and closing state of the leather case or the opening and closing state of the flip cover, characteristics such as automatic unlocking of the flip cover are set.
加速度传感器180E可检测电子设备100在各个方向上(一般为三轴)加速度的大小。当电子设备100静止时可检测出重力的大小及方向。还可以用于识别电子设备姿态,应用于横竖屏切换,计步器等应用。The acceleration sensor 180E can detect the magnitude of the acceleration of the electronic device 100 in various directions (generally three axes). The magnitude and direction of gravity can be detected when the electronic device 100 is stationary. It can also be used to identify the posture of electronic devices, and can be used in applications such as horizontal and vertical screen switching, pedometers, etc.
距离传感器180F,用于测量距离。电子设备100可以通过红外或激光测量距离。在一些实施例中,拍摄场景,电子设备100可以利用距离传感器180F测距以实现快速对焦。Distance sensor 180F for measuring distance. The electronic device 100 can measure the distance through infrared or laser. In some embodiments, when shooting a scene, the electronic device 100 can use the distance sensor 180F to measure the distance to achieve fast focusing.
接近光传感器180G可以包括例如发光二极管(LED)和光检测器,例如光电二极管。发光二极管可以是红外发光二极管。电子设备100通过发光二极管向外发射红外光。电子设备100使用光电二极管检测来自附近物体的红外反射光。当检测到充分的反射光时,可以确定电子设备100附近有物体。当检测到不充分的反射光时,电子设备100可以确定电子设备100附近没有物体。电子设备100可以利用接近光传感器180G检测用户手持电子设备100贴近耳朵通话,以便自动熄灭屏幕达到省电的目的。接近光传感器180G也可用于皮套模式,口袋模式自动解锁与锁屏。在一个实施例中,接近光传感器和超声波传感器可以进行耦合判断电子设备是否开启防误触功能,例如,当接近光传感器或超声波传感器任一个检测到当前电子设备处于被遮挡状态时,电子设备开启防误触功能;或者当接近光传感器和超声波传感器两者均检测到当前电子设备处于被遮挡状态时,电子设备才开启防误触功能等。环境光传感器180L用于感知环境光亮度。电子设备100可以根据感知的环境光亮度自适应调节显示屏194亮度。环境光传感器180L也可用于拍照时自动调节白平衡。环 境光传感器180L还可以与接近光传感器180G配合,检测电子设备100是否在口袋里,以防误触。在一个实施例中,环境光传感器和超声波传感器可以进行耦合判断电子设备是否开启防误触功能,例如,虽然超声波传感器检测到电子设备处于被遮挡状态,但是环境光传感器检测到环境光亮度高于一定亮度值时,仍然不开启防误触功能;或者当环境光传感器检测到环境光亮度低于第一亮度值时,例如10勒克斯(lx),且超声波传感器检测到当前电子设备处于被遮挡状态,电子设备才会开启防误触功能等。Proximity light sensor 180G may include, for example, light emitting diodes (LEDs) and light detectors, such as photodiodes. The light emitting diodes may be infrared light emitting diodes. The electronic device 100 emits infrared light to the outside through the light emitting diode. Electronic device 100 uses photodiodes 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 may 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 holds the electronic device 100 close to the ear to talk, so as to automatically turn off the screen to save power. Proximity light sensor 180G can also be used in holster mode, pocket mode automatically unlocks and locks the screen. In one embodiment, the proximity light sensor and the ultrasonic sensor can be coupled to determine whether the electronic device enables the anti-mistouch function. For example, when either the proximity light sensor or the ultrasonic sensor detects that the current electronic device is in a blocked state, the electronic device is turned on. Anti-mistouch function; or when both the proximity light sensor and the ultrasonic sensor detect that the current electronic device is in a blocked state, the electronic device will turn on the anti-mistouch function, etc. The ambient light sensor 180L is used to sense ambient light brightness. The electronic device 100 can adaptively adjust the brightness of the display screen 194 according to the perceived ambient light brightness. The ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures. The ambient light sensor 180L can also cooperate with the proximity light sensor 180G to detect whether the electronic device 100 is in the pocket to prevent accidental touch. In one embodiment, the ambient light sensor and the ultrasonic sensor can be coupled to determine whether the electronic device enables the anti-mistouch function. For example, although the ultrasonic sensor detects that the electronic device is in a blocked state, the ambient light sensor detects that the brightness of the ambient light is higher than At a certain brightness value, the anti-mistouch function is still not turned on; or when the ambient light sensor detects that the ambient light brightness is lower than the first brightness value, such as 10 lux (lx), and the ultrasonic sensor detects that the current electronic device is in a blocked state , the electronic device will turn on the anti-mistouch function, etc.
指纹传感器180H用于采集指纹。电子设备100可以利用采集的指纹特性实现指纹解锁,访问应用锁,指纹拍照,指纹接听来电等。The fingerprint sensor 180H is used to collect fingerprints. The electronic device 100 can use the collected fingerprint characteristics to realize fingerprint unlocking, accessing application locks, taking pictures with fingerprints, answering incoming calls with fingerprints, and the like.
温度传感器180J用于检测温度。在一些实施例中,电子设备100利用温度传感器180J检测的温度,执行温度处理策略。例如,当温度传感器180J上报的温度超过阈值,电子设备100执行降低位于温度传感器180J附近的处理器的性能,以便降低功耗实施热保护。在另一些实施例中,当温度低于另一阈值时,电子设备100对电池142加热,以避免低温导致电子设备100异常关机。在其他一些实施例中,当温度低于又一阈值时,电子设备100对电池142的输出电压执行升压,以避免低温导致的异常关机。The temperature sensor 180J is used to detect the temperature. In some embodiments, the electronic device 100 uses the temperature detected by the temperature sensor 180J to execute a temperature processing strategy. For example, when the temperature reported by the temperature sensor 180J exceeds a threshold value, the electronic device 100 reduces the performance of the processor located near the temperature sensor 180J in order to reduce power consumption and implement thermal protection. In other embodiments, when the temperature is lower than another threshold, the electronic device 100 heats the battery 142 to avoid abnormal shutdown of the electronic device 100 caused by the low temperature. In some other embodiments, when the temperature is lower than another threshold, the electronic device 100 boosts the output voltage of the battery 142 to avoid abnormal shutdown caused by low temperature.
触摸传感器180K,也称“触控面板”。触摸传感器180K可以设置于显示屏194,由触摸传感器180K与显示屏194组成触摸屏,也称“触控屏”。触摸传感器180K用于检测作用于其上或附近的触摸操作。触摸传感器可以将检测到的触摸操作传递给应用处理器,以确定触摸事件类型。可以通过显示屏194提供与触摸操作相关的视觉输出。在另一些实施例中,触摸传感器180K也可以设置于电子设备100的表面,与显示屏194所处的位置不同。Touch sensor 180K, also called "touch panel". The touch sensor 180K may be disposed on the display screen 194 , and 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 a touch operation on or near it. The touch sensor can pass the detected touch operation to the application processor to determine the type of touch event. Visual output related to touch operations may be provided through display screen 194 . In other embodiments, the touch sensor 180K may also be disposed on the surface of the electronic device 100 , which is different from the location where the display screen 194 is located.
超声波传感器180M用于通过发射和接收超声波,检测电子设备100当前所处的状态,进而处理器110判断是否开启防误触模式。The ultrasonic sensor 180M is used to detect the current state of the electronic device 100 by transmitting and receiving ultrasonic waves, and then the processor 110 determines whether to enable the anti-mistouch mode.
按键190包括开机键,音量键等。按键190可以是机械按键。也可以是触摸式按键。电子设备100可以接收按键输入,产生与电子设备100的用户设置以及功能控制有关的键信号输入。The keys 190 include a power-on key, a volume key, and the like. Keys 190 may be mechanical keys. It can also be a touch key. 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 .
马达191可以产生振动提示。马达191可以用于来电振动提示,也可以用于触摸振动反馈。例如,作用于不同应用(例如拍照,音频播放等)的触摸操作,可以对应不同的振动反馈效果。作用于显示屏194不同区域的触摸操作,马达191也可对应不同的振动反馈效果。不同的应用场景(例如:时间提醒,接收信息,闹钟,游戏等)也可以对应不同的振动反馈效果。触摸振动反馈效果还可以支持自定义。Motor 191 can generate vibrating cues. The motor 191 can be used for vibrating alerts for incoming calls, and can also be used for touch vibration feedback. For example, touch operations acting on different applications (such as taking pictures, playing audio, etc.) can correspond to different vibration feedback effects. The motor 191 can also correspond to different vibration feedback effects for touch operations on different areas of the display screen 194 . Different application scenarios (for example: time reminder, receiving information, alarm clock, games, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect can also support customization.
指示器192可以是指示灯,可以用于指示充电状态,电量变化,也可以用于指示消息,未接来电,通知等。The indicator 192 can be an indicator light, which can be used to indicate the charging state, the change of the power, and can also be used to indicate a message, a missed call, a notification, and the like.
SIM卡接口195用于连接SIM卡。SIM卡可以通过插入SIM卡接口195,或从SIM卡接口195拔出,实现和电子设备100的接触和分离。电子设备100可以支持1个或N个SIM卡接口,N为大于1的正整数。SIM卡接口195可以支持Nano SIM卡,Micro SIM卡,SIM卡等。同一个SIM卡接口195可以同时插入多张卡。所述多张卡的类型可以相同,也可以不同。SIM卡接口195也可以兼容不同类型的SIM卡。SIM卡接口195也可以兼容外部存储卡。电子设备100通过SIM卡和网络交互,实现通话以及数据通信等功能。The SIM card interface 195 is used to connect a SIM card. The SIM card can be contacted and separated from the electronic device 100 by inserting into the SIM card interface 195 or pulling out from the SIM card interface 195 . The electronic device 100 may support 1 or N SIM card interfaces, where N is a positive integer greater than 1. The SIM card interface 195 can support Nano SIM card, Micro SIM card, SIM card and so on. Multiple cards can be inserted into the same SIM card interface 195 at the same time. The types of the plurality of cards may be the same or different. The SIM card interface 195 can also be 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 call and data communication.
图2是本申请实施例的电子设备100的软件结构框图。FIG. 2 is a block diagram of the software structure of the electronic device 100 according to the embodiment of the present application.
分层架构将软件分成若干个层,每一层都有清晰的角色和分工。层与层之间通过软件接口通信。在一些实施例中,可以将Android系统分为四层,从上至下分别为应用程序层,应用程序框架层,安卓运行时(Android runtime)和系统库,以及内核层。The layered architecture divides the software into several layers, and each layer has a clear role and division of labor. Layers communicate with each other through software interfaces. In some embodiments, the Android system can be divided into four layers, which are, from top to bottom, an application layer, an application framework layer, an Android runtime (Android runtime) and system libraries, and a kernel layer.
应用程序层可以包括一系列应用程序包。The application layer can include a series of application packages.
如图2所示,应用程序包可以包括相机,图库,日历,通话,地图,导航,WLAN,蓝牙,音乐,视频,短信息等应用程序(也可以称为应用)。As shown in FIG. 2 , the application package may include applications (also referred to as applications) such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, and short message.
应用程序层中还可以包括防误触模式的应用,在该防误触模式应用运行时需要调用超声波传感器发送/接收超声波信号。The application layer may also include an application in the anti-mistouch mode, and when the application in the anti-mistouch mode runs, the ultrasonic sensor needs to be called to send/receive ultrasonic signals.
应用程序框架层为应用程序层的应用程序提供应用编程接口(application programming interface,API)和编程框架。应用程序框架层包括一些预先定义的函数。The application framework layer provides an application programming interface (application programming interface, API) and a programming framework for applications in the application layer. The application framework layer includes some predefined functions.
如图2所示,应用程序框架层可以包括窗口管理器,内容提供器,视图系统,电话管理器,资源管理器,通知管理器,本地Profile管理助手(Local Profile Assistant,LPA)以及超声波传感器调用控制管理器等。As shown in Figure 2, the application framework layer can include a window manager, a content provider, a view system, a phone manager, a resource manager, a notification manager, a Local Profile Assistant (LPA), and an ultrasonic sensor call Control Manager, etc.
窗口管理器用于管理窗口程序。窗口管理器可以获取显示屏大小,判断是否有状态栏,锁定屏幕,截取屏幕等。A window manager is used to manage window programs. The window manager can get the size of the display screen, determine whether there is a status bar, lock the screen, take screenshots, etc.
内容提供器用来存放和获取数据,并使这些数据可以被应用程序访问。所述数据可以包括视频,图像,音频,拨打和接听的电话,浏览历史和书签,电话簿等。Content providers are used to store and retrieve data and make these data accessible to applications. The data may include video, images, audio, calls made and received, browsing history and bookmarks, phone book, etc.
视图系统包括可视控件,例如显示文字的控件,显示图片的控件等。视图系统可用于构建应用程序。显示界面可以由一个或多个视图组成的。例如,包括短信通知图标的显示界面,可以包括显示文字的视图以及显示图片的视图。The view system includes visual controls, such as controls for displaying text, controls for displaying pictures, and so on. View systems can be used to build applications. A display interface can consist of one or more views. For example, the display interface including the short message notification icon may include a view for displaying text and a view for displaying pictures.
电话管理器用于提供电子设备100的通信功能。例如通话状态的管理(包括接通,挂断等)。The phone manager is used to provide the communication function of the electronic device 100 . For example, the management of call status (including connecting, hanging up, etc.).
资源管理器为应用程序提供各种资源,比如本地化字符串,图标,图片,布局文件,视频文件等等。The resource manager provides various resources for the application, such as localization strings, icons, pictures, layout files, video files and so on.
通知管理器使应用程序可以在状态栏中显示通知信息,可以用于传达告知类型的消息,可以短暂停留后自动消失,无需用户交互。比如通知管理器被用于告知下载完成,消息提醒等。通知管理器还可以是以图表或者滚动条文本形式出现在系统顶部状态栏的通知,例如后台运行的应用程序的通知,还可以是以对话界面形式出现在屏幕上的通知。例如在状态栏提示文本信息,发出提示音,电子设备振动,指示灯闪烁等。The notification manager enables applications to display notification information in the status bar, which can be used to convey notification-type messages, and can disappear automatically after a brief pause without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc. The notification manager can also display notifications in the status bar at the top of the system in the form of graphs or scroll bar text, such as notifications from applications running in the background, and can also display notifications on the screen in the form of a dialog interface. For example, text information is prompted in the status bar, a prompt sound is issued, the electronic device vibrates, and the indicator light flashes.
安卓运行时(Android Runtime)包括核心库和虚拟机。Android runtime负责安卓系统的调度和管理。The Android Runtime includes core libraries and a virtual machine. Android runtime is responsible for scheduling and management of the Android system.
核心库包含两部分:一部分是java语言需要调用的功能函数,另一部分是安卓的核心库。The core library consists of two parts: one is the function functions that the java language needs to call, and the other is the core library of Android.
应用程序层和应用程序框架层运行在虚拟机中。虚拟机将应用程序层和应用程序框架层的java文件执行为二进制文件。虚拟机用于执行对象生命周期的管理,堆栈管理,线程管理,安全和异常的管理,以及垃圾回收等功能。The application layer and the application framework layer run in virtual machines. The virtual machine executes the java files of the application layer and the application framework layer as binary files. The virtual machine is used to perform functions such as object lifecycle management, stack management, thread management, safety and exception management, and garbage collection.
系统库可以包括多个功能模块。例如:表面管理器(surface manager),媒体库(Media  Libraries),三维图形处理库(例如:OpenGL ES),二维图形引擎(例如:SGL)等。A system library can include multiple functional modules. For example: surface manager (surface manager), media library (Media Libraries), 3D graphics processing library (eg: OpenGL ES), 2D graphics engine (eg: SGL), etc.
表面管理器用于对显示子系统进行管理,并且为多个应用程序提供了二维(2-Dimensional,2D)和三维(3-Dimensional,3D)图层的融合。The Surface Manager is used to manage the display subsystem and provides a fusion of two-dimensional (2-Dimensional, 2D) and three-dimensional (3-Dimensional, 3D) layers for multiple applications.
媒体库支持多种常用的音频,视频格式回放和录制,以及静态图像文件等。媒体库可以支持多种音视频编码格式,例如:MPEG4,H.264,MP3,AAC,AMR,JPG,PNG等。The media library supports playback and recording of a variety of commonly used audio and video formats, as well as still 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.
三维图形处理库用于实现3D图形绘图,图像渲染,合成,和图层处理等。The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.
2D图形引擎是2D绘图的绘图引擎。2D graphics engine is a drawing engine for 2D drawing.
内核层是硬件和软件之间的层。内核层至少包含显示驱动,摄像头驱动,音频驱动,传感器驱动,虚拟卡驱动。其中传感器驱动包括超声波传感器的驱动,该超声波传感器的驱动用于驱动超声波传感器180M。对应的,超声波传感器180M用于发送和接收超声波信号。The kernel layer is the layer between hardware and software. The kernel layer contains at least display drivers, camera drivers, audio drivers, sensor drivers, and virtual card drivers. The sensor driving includes the driving of the ultrasonic sensor, and the driving of the ultrasonic sensor is used to drive the ultrasonic sensor 180M. Correspondingly, the ultrasonic sensor 180M is used for sending and receiving ultrasonic signals.
在这里结合捕获拍照场景,示例性说明电子设备100软件以及硬件的工作流程。Here, the workflow of the software and hardware of the electronic device 100 is exemplified in conjunction with capturing a photographing scene.
当触摸传感器180K接收到触摸操作,相应的硬件中断被发给内核层。内核层将触摸操作加工成原始输入事件(包括触摸坐标,触摸操作的时间戳等信息)。原始输入事件被存储在内核层。应用程序框架层从内核层获取原始输入事件,识别该输入事件所对应的控件。以该触摸操作是触摸单击操作,该单击操作所对应的控件为相机应用图标的控件为例,相机应用调用应用框架层的接口,启动相机应用,进而通过调用内核层启动摄像头驱动,通过摄像头193捕获静态图像或视频。When the touch sensor 180K receives a touch operation, a corresponding hardware interrupt is sent to the kernel layer. The kernel layer processes touch operations into raw input events (including touch coordinates, timestamps of touch operations, etc.). Raw input events are stored at the kernel layer. The application framework layer obtains the original input event from the kernel layer, and identifies the control corresponding to the input event. Taking the touch operation as a touch click operation, and the control corresponding to the click operation is the control of the camera application icon, for example, the camera application calls the interface of the application framework layer to start the camera application, and then starts the camera driver by calling the kernel layer. The camera 193 captures still images or video.
超声波传感器是利用超声波的特性研制而成的传感器。超声波是一种振动频率高于声波的机械波,具有频率高、波长短、绕射现象小、方向性好、能够成为射线而定向传播等特点。超声波具有很强的方向性。超声波可以在气体、液体以及固体中传播,其传播速度不同,超声波还会有折射、反射、衍射等现象,并且在传播过程中有衰减。在空气中传播超声波,其频率较低,一般为几十千赫兹(kHz),而在固体、液体中则频率较高,在空气中传播衰减的也较快,而在液体及固体中传播,相对衰减较小,传播更远。Ultrasonic sensors are sensors developed using the characteristics of ultrasonic waves. Ultrasound is a kind of mechanical wave whose vibration frequency is higher than that of sound wave. It has the characteristics of high frequency, short wavelength, small diffraction phenomenon, good directionality, and can become a ray and propagate in a direction. Ultrasound is highly directional. Ultrasonic waves can propagate in gases, liquids and solids, and the propagation speed is different. Ultrasonic waves will also have phenomena such as refraction, reflection, and diffraction, and they will be attenuated during the propagation process. Ultrasonic waves propagate in the air, and their frequency is low, generally tens of kilohertz (kHz), while in solids and liquids, the frequencies are higher, and the propagation attenuation in air is also faster, while in liquids and solids, Relative attenuation is smaller and spreads farther.
超声波传感器可以包括超声波发射器和超声波接收器,在本申请实施例中,提及超声波发射器和超声波接收器旨在涵盖可以统称为超声波传感器的所有功能替代物。超声波发射器用来发射超声波信号,超声波信号遇到障碍物会反射超声波回波至超声波接收器,从而使超声波传感器检测到被测物体。Ultrasonic sensors may include ultrasonic transmitters and ultrasonic receivers, and in the embodiments of the present application, reference to ultrasonic transmitters and ultrasonic receivers is intended to cover all functional alternatives that may be collectively referred to as ultrasonic sensors. The ultrasonic transmitter is used to transmit ultrasonic signals. When the ultrasonic signal encounters obstacles, it will reflect the ultrasonic echo to the ultrasonic receiver, so that the ultrasonic sensor can detect the object to be measured.
超声波传感器的超声波发射器和超声波接收器可以集中在同一器件上,也可以分离开。超声波传感器甚至可以是功能相同的任何可用的超声波发射器与超声波接收器的组合。在电子设备100上,超声波传感器的数量可以是一个或多个。或者甚至是,超声波发射器旨在包括一个或多个超声波发射器,超声波接收器旨在包括一个或多个超声波接收器。超声波发射器的数量和超声波接收器的数量可以相等,也可以不相等。本申请实施例对超声波传感器在电子设备100上的数量和位置不作任何限制。The ultrasonic transmitter and ultrasonic receiver of the ultrasonic sensor can be concentrated on the same device or can be separated. The ultrasonic sensor can even be any available combination of ultrasonic transmitter and ultrasonic receiver with the same function. On the electronic device 100, the number of ultrasonic sensors may be one or more. Or even, the ultrasonic transmitter is intended to comprise one or more ultrasonic transmitters and the ultrasonic receiver is intended to comprise one or more ultrasonic receivers. The number of ultrasonic transmitters and the number of ultrasonic receivers may or may not be equal. This embodiment of the present application does not impose any restrictions on the quantity and position of the ultrasonic sensors on the electronic device 100 .
电子设备100的用于音频功能的一个或多个听筒、扬声器、麦克风也可以用于超声波的测量。可以理解的是,听筒、扬声器可以用作超声波发射器,而麦克风可以用作超声波接收器,这样可以节省电子设备100的器件成本和内部空间。如图3a所示,在一个实施例 中,手机300的正面上方可以安装有听筒301,听筒301可以用作超声波发射器,用于发射超声波信号。手机300的顶部可以安装有降噪麦克风302,麦克风302可以用作超声波接收器,用于接收超声波回波信号。图3b所示的为超声波发射器的发射范围的一个示意图,参阅图3b,可以看出超声波信号的传输轨迹是以超声波发射器为原点的圆锥形波束,该圆锥形波束的中心线是该超声波信号的发射方向,超声波信号沿着与其发射方向呈第一角度的方向向四周空间散射,形成圆锥形波束,需要说明的是,该第一角度的具体值与超声波发射器的具体设计有关,本申请不作任何限制。One or more earpieces, speakers, microphones of the electronic device 100 for audio functions may also be used for the measurement of ultrasound. It can be understood that the earpiece and the loudspeaker can be used as an ultrasonic transmitter, and the microphone can be used as an ultrasonic receiver, which can save the component cost and internal space of the electronic device 100 . As shown in Figure 3a, in one embodiment, an earpiece 301 may be installed above the front of the mobile phone 300, and the earpiece 301 may be used as an ultrasonic transmitter for transmitting ultrasonic signals. A noise reduction microphone 302 may be installed on the top of the mobile phone 300, and the microphone 302 may be used as an ultrasonic receiver for receiving ultrasonic echo signals. Figure 3b shows a schematic diagram of the emission range of the ultrasonic transmitter. Referring to Figure 3b, it can be seen that the transmission trajectory of the ultrasonic signal is a conical beam with the ultrasonic transmitter as the origin, and the center line of the conical beam is the ultrasonic wave. The emission direction of the signal, the ultrasonic signal is scattered to the surrounding space along the direction of the first angle with the emission direction, forming a conical beam. It should be noted that the specific value of the first angle is related to the specific design of the ultrasonic transmitter. There are no restrictions on the application.
发射的超声波信号可以是单频连续波(continuous wave,CW),线性调频连续波(linear frequency modulation,LFM),ZC序列(Zadoff-Chu sequence)等,关于超声波信号的发射频率以及形式,本申请不作任何限制,任何形式的发射超声波信号以实现本申请所阐述的功能,都应该在本申请的保护范围之内。本申请可以通过断续发射超声波,即设定占空比(duty ratio)的方式降低功耗,例如在一个实施例中,可以设定在1秒的周期内,有150毫秒持续发射超声波信号,剩余850毫秒的时间段内对发射超声波的通路进行下电处理,即不发射超声波信号,这样占空比为0.15,可以保证发射超声波的功耗处于一个相对较低的水平。The transmitted ultrasonic signal can be a single-frequency continuous wave (continuous wave, CW), a linear frequency modulation continuous wave (linear frequency modulation, LFM), a ZC sequence (Zadoff-Chu sequence), etc. Regarding the transmission frequency and form of the ultrasonic signal, this application Without any limitation, any form of transmitting ultrasonic signals to achieve the functions described in this application should fall within the protection scope of this application. In the present application, power consumption can be reduced by intermittently transmitting ultrasonic waves, that is, by setting a duty ratio. For example, in one embodiment, the ultrasonic wave signal can be continuously transmitted for 150 milliseconds in a period of 1 second. In the remaining 850 milliseconds, the channel for transmitting ultrasonic waves is powered off, that is, ultrasonic signals are not transmitted, so that the duty cycle is 0.15, which can ensure that the power consumption of transmitting ultrasonic waves is at a relatively low level.
在一个实施例中,听筒发出的超声波会经过不同路径形成超声波回波传播到麦克风,本申请实施例涉及的超声波回波的主要路径如图3c所示:In one embodiment, the ultrasonic waves emitted by the earpiece will pass through different paths to form ultrasonic echoes and propagate to the microphone. The main paths of the ultrasonic echoes involved in this embodiment of the present application are shown in Figure 3c:
固体结构声路径303:听筒301发射出超声波,经过手机300内部固体结构,传播到麦克风302中。声音在固体中的传播速度(>2000m/s)要快于在空气中的传播速度(约为340m/s),因此固体结构声路径303传播时间是最短的,并且该路径303的传播时间非常稳定。Solid structure sound path 303 : ultrasonic waves emitted from the earpiece 301 pass through the internal solid structure of the mobile phone 300 and propagate to the microphone 302 . The propagation speed of sound in solids (>2000m/s) is faster than that in air (about 340m/s), so the propagation time of solid structure sound path 303 is the shortest, and the propagation time of this path 303 is very stability.
空气直射声路径304:听筒301发射出超声波,传播到空气中,不经过反射而是直接传播到麦克风302中。空气直射声路径304的传播时间慢于固体结构声路径303,但是该路径304受外界物体影响很小,因此,空气直射声路径304的传播时间也较为稳定。Direct air sound path 304 : the earpiece 301 emits ultrasonic waves, which are propagated into the air, and are directly propagated to the microphone 302 without being reflected. The propagation time of the direct air sound path 304 is slower than that of the solid structure sound path 303, but the path 304 is less affected by external objects, so the propagation time of the air direct sound path 304 is also relatively stable.
空气反射声路径305:听筒301发射出超声波,传播到空气中,遇到麦克风和听筒上方的障碍物,超声波信号经过反射、折射、衍射等生成超声波回波,超声波回波又传播到麦克风302中。由于障碍物存在与否、材质、遮挡位置、遮挡距离等不确定性,因此空气反射声路径305不能准确测定其传播时间。Air reflected sound path 305: the earpiece 301 emits ultrasonic waves and propagates into the air. When encountering obstacles above the microphone and the earpiece, the ultrasonic signal generates ultrasonic echoes through reflection, refraction, diffraction, etc., and the ultrasonic echoes propagate to the microphone 302. . Due to uncertainties such as the existence of obstacles, materials, occlusion positions, and occlusion distances, the air-reflected sound path 305 cannot accurately measure its propagation time.
麦克风302接收到不同路径的超声波回波信号后,手机300的处理器根据不同超声波回波信号的传播时间、声波强度等信息,判断出手机300上方是否有障碍物遮挡,进而判定是否需要启动防误触模式。After the microphone 302 receives the ultrasonic echo signals of different paths, the processor of the mobile phone 300 determines whether there is an obstacle above the mobile phone 300 according to the propagation time, sound wave intensity and other information of the different ultrasonic echo signals, and then determines whether it is necessary to activate the protection. Accidental touch mode.
麦克风302接收到的超声波回波Sig R,是听筒301发射的超声波Sig T在时间t之后,各个路径上超声波信号的线性叠加,比如固体结构声与空气反射声会有一定程序的融合。因此,麦克风302接收到的超声波回波Sig R的基带信号可以表示为: The ultrasonic echo Sig R received by the microphone 302 is the linear superposition of the ultrasonic signals on each path after the time t of the ultrasonic Sig T emitted by the earpiece 301 . Therefore, the baseband signal of the ultrasonic echo Sig R received by the microphone 302 can be expressed as:
Figure PCTCN2021109122-appb-000001
Figure PCTCN2021109122-appb-000001
假设,从超声波发射端到超声波接收端共有P条路径,对于每条路径,超声波接收端接收到的基带信号是超声波发射端发射超声波序列的一个延时τ i的副本Sig(t-τ i)。同时, 由于在路径传播过程中会有衰减、发射相位翻转和传播相位延迟等情况,会产生对应的幅度及相位的变化,这些变化通过
Figure PCTCN2021109122-appb-000002
来体现。其中,在短时间内,幅值A i是不会剧烈变化的,而相位
Figure PCTCN2021109122-appb-000003
是有可能随运动而变化的。在此情况下,路径对于信号的影响等价于通过了一个冲击响应为h的线性系统:
It is assumed that there are P paths from the ultrasonic transmitter to the ultrasonic receiver. For each path, the baseband signal received by the ultrasonic receiver is a replica of a delay τ i of the ultrasonic sequence transmitted by the ultrasonic transmitter Sig(t-τ i ) . At the same time, due to attenuation, transmission phase inversion and propagation phase delay in the process of path propagation, corresponding amplitude and phase changes will occur.
Figure PCTCN2021109122-appb-000002
to manifest. Among them, in a short time, the amplitude A i will not change drastically, and the phase
Figure PCTCN2021109122-appb-000003
It is possible to change with the movement. In this case, the effect of the path on the signal is equivalent to passing through a linear system with impulse response h:
Figure PCTCN2021109122-appb-000004
Figure PCTCN2021109122-appb-000004
其中,δ(t)为狄拉克冲击函数。因此,如果可以求得信号的冲击响应h(t),就可以知道不同路径时延的幅度,从而来分离不同时延的路径。where δ(t) is the Dirac shock function. Therefore, if the impulse response h(t) of the signal can be obtained, the amplitudes of the delays of different paths can be known, so as to separate the paths of different delays.
假设Sig T(t)的自相关函数为δ(t),即 Assuming that the autocorrelation function of Sig T (t) is δ(t), that is
Figure PCTCN2021109122-appb-000005
Figure PCTCN2021109122-appb-000005
此处,用到了相关计算等价于卷积逆序序列的共轭,满足交换律。Here, the correlation calculation is used, which is equivalent to the conjugation of the reverse sequence of convolution, which satisfies the commutative law.
Figure PCTCN2021109122-appb-000006
Figure PCTCN2021109122-appb-000006
将接收到的超声波回波信号与发射的超声波序列进行互相关,固体声和空气声的回波信号将产生不同的相关峰,通过研究不同峰的信号特征,可以判断当前电子设备是否处于被遮挡状态,进而判定是否开启防误触模式。Cross-correlate the received ultrasonic echo signal with the transmitted ultrasonic sequence. The echo signals of solid sound and air sound will generate different correlation peaks. By studying the signal characteristics of different peaks, it can be judged whether the current electronic equipment is blocked or not. status, and then determine whether to enable the anti-mistouch mode.
在一些实施例中,参阅图4,图4中示出了一些场景下手机麦克风采集到的单帧超声波回波信号的冲击响应的示意图,其中,每张图的横坐标表示超声波所经过的路径的测距,每张图的纵坐标表示超声波回波信号冲击响应的强度,数值越大表示强度越大,图中相关峰的波形可以反映手机附近物体遮挡的情况。其中,主峰(强度最大的峰)表示超声波通过手机内部固体结构和空气直接从听筒到达麦克风路径上的冲击响应,而主峰后一峰表示超声波从听筒发出之后遇到障碍物反射后,到达麦克风的冲击响应,由于遇到的障碍物的材质不同、障碍物所处的位置、距离不同等原因,主峰和主峰后一峰可能会出现不同的波形融合、幅值变化等情况,进而表现出不同的数据特征。In some embodiments, referring to FIG. 4 , FIG. 4 shows a schematic diagram of the impulse response of a single-frame ultrasonic echo signal collected by a mobile phone microphone in some scenarios, wherein the abscissa of each figure represents the path traveled by the ultrasonic waves The ordinate of each figure represents the intensity of the ultrasonic echo signal impulse response. The larger the value, the higher the intensity. The waveform of the correlation peak in the figure can reflect the occlusion of objects near the mobile phone. Among them, the main peak (peak with the highest intensity) represents the impact response of the ultrasonic wave directly from the earpiece to the microphone path through the internal solid structure of the mobile phone and the air, and the peak after the main peak represents the impact of the ultrasonic wave reaching the microphone after it is reflected from an obstacle after it is emitted from the earpiece. In response, due to the different materials of the obstacles encountered, the location and distance of the obstacles, etc., the main peak and the next peak after the main peak may have different waveform fusion, amplitude changes, etc., and then show different data characteristics. .
图4中a图为手掌在手机上方0厘米处遮挡时超声波回波冲击响应的一个示例图;图4中b图为手掌在手机上方6厘米处遮挡时超声波回波冲击响应的一个示例图;图4中c图为手掌在手机上方8厘米处遮挡时超声波回波冲击响应的一个示例图;图4中d图为手机在背包中时超声波回波冲击响应的一个示例图;图4中e图为手机在牛仔裤口袋中时超声波回波冲击响应的一个示例图;图4中f图为手机上方无遮挡时超声波回波冲击响应的一个示例图。由图4可以看出,在不同情景下,主峰的宽度、位置、高度以及主峰后一峰的宽度、位置、高度均呈现出不同的形态。Figure a in Figure 4 is an example diagram of the ultrasonic echo impulse response when the palm is blocked at 0 cm above the mobile phone; Figure b in Figure 4 is an example diagram of the ultrasonic echo impulse response when the palm is blocked at 6 cm above the mobile phone; Figure c in Figure 4 is an example diagram of the ultrasonic echo impulse response when the palm is blocked at 8 cm above the mobile phone; Figure d in Figure 4 is an example diagram of the ultrasonic echo impulse response when the mobile phone is in a backpack; Figure 4 e The picture is an example diagram of the ultrasonic echo impulse response when the mobile phone is in the pocket of jeans; the picture f in FIG. 4 is an example diagram of the ultrasonic echo impulse response when the mobile phone is not blocked above. It can be seen from Figure 4 that under different scenarios, the width, position and height of the main peak and the width, position and height of the next peak after the main peak show different shapes.
下面结合附图介绍本申请实施例涉及的一些应用场景。Some application scenarios involved in the embodiments of the present application are described below with reference to the accompanying drawings.
本申请主要应用在电子设备检测当前是否处于被遮挡的状态,当判断到电子设备当前在口袋或背包中等被遮挡的场景时,电子设备可以自动启动防误触模式,在防误触模式下,电子设备不响应触摸操作、屏幕解锁、抬手亮屏、AOD等指令,可以防止误触情况的发生以及降低电子设备的功耗,提升了用户的使用体验。其中,屏幕解锁可以包括上滑屏幕解锁、触控解锁、密码解锁、手势解锁、指纹解锁、人脸解锁、语音解锁、声纹解锁等等。另外,在防误触模式下,电子设备限制响应的指令,不限于上述提及的触摸操作、屏幕解 锁、抬手亮屏、AOD等,还可以是其他的指令,比如抬手接听来电、自动调节亮度等,开发人员可以根据具体情况进行设置,本申请对此不作任何限制。This application is mainly used in the detection of whether the electronic device is currently in a blocked state. When it is determined that the electronic device is currently blocked in a pocket or a backpack, the electronic device can automatically activate the anti-mistouch mode. In the anti-mistouch mode, the The electronic device does not respond to commands such as touch operations, unlocking the screen, raising the hand to brighten the screen, AOD, etc., which can prevent the occurrence of false touches and reduce the power consumption of the electronic device, improving the user experience. The screen unlocking may include sliding screen unlocking, touch unlocking, password unlocking, gesture unlocking, fingerprint unlocking, face unlocking, voice unlocking, voiceprint unlocking, and the like. In addition, in the anti-mistouch mode, the electronic device restricts the response to the command, not limited to the above-mentioned touch operation, screen unlocking, raising your hand to brighten the screen, AOD, etc., but also other commands, such as raising your hand to answer an incoming call, automatic Adjusting brightness, etc., developers can set according to specific conditions, and this application does not make any restrictions.
图5a示出了一种常见的应用场景,口袋场景:用户将手机501放在口袋502中,手机501可以检测到自身处于被遮挡状态,进而在防误触模式下,手机501不响应触摸操作、屏幕解锁、抬手亮屏、AOD等指令,可以防止误触情况的发生。本实施例对口袋的材质不作任何限制,口袋的材质可以是棉质、雪纺、涤纶、混合面料等等。Figure 5a shows a common application scenario, the pocket scenario: the user puts the mobile phone 501 in the pocket 502, the mobile phone 501 can detect that it is in a blocked state, and then in the anti-mistouch mode, the mobile phone 501 does not respond to touch operations , unlock the screen, raise your hand to brighten the screen, AOD and other commands to prevent accidental touches. This embodiment does not impose any restrictions on the material of the pocket, and the material of the pocket may be cotton, chiffon, polyester, mixed fabric, and the like.
图5b示出了另一种常见的应用场景,箱包场景:用户将手机503放在背包504中,手机503可以检测到自身处于被遮挡状态,进而在防误触模式下,手机503不响应触摸操作、屏幕解锁、抬手亮屏、AOD等指令,可以防止误触情况的发生。这里的箱包场景是个广义的概念,可以包括双肩背包、单肩背包、手提包、钱包、手提袋、箱子里等情形,本实施例对背包的材质不作任何限制,背包的材质可以是棉布、牛皮、皮革、帆布、塑料以及混合材质等等。Figure 5b shows another common application scenario, the luggage scenario: the user puts the mobile phone 503 in the backpack 504, the mobile phone 503 can detect that it is in a blocked state, and then in the anti-mistouch mode, the mobile phone 503 does not respond to touch Commands such as operation, unlocking the screen, raising your hand to brighten the screen, and AOD can prevent accidental touches. The luggage scene here is a broad concept, which can include backpacks, single-shoulder backpacks, handbags, wallets, handbags, boxes, etc. This embodiment does not impose any restrictions on the material of the backpack, and the material of the backpack can be cotton, cowhide, etc. , leather, canvas, plastic, mixed materials, and more.
图5c示出了手掌506遮挡手机505上方的应用场景,手掌506距离手机505会有不同的距离,如2厘米。在一个实施例中,在手掌506紧贴手机505上方时,即距离0厘米处视为手机被遮挡,这时开启防误触功能。FIG. 5c shows an application scenario in which the palm 506 covers the upper part of the mobile phone 505, and the palm 506 has different distances from the mobile phone 505, such as 2 cm. In one embodiment, when the palm 506 is close to the top of the mobile phone 505, that is, at a distance of 0 cm, the mobile phone is considered to be blocked, and the anti-mistouch function is enabled at this time.
图5a、图5b、图5c示出的应用场景并不对本申请实施例构成限制,防误触模式除了应用在口袋场景、背包场景、箱包场景、手掌遮挡场景,还应用在其他的电子设备上方被遮挡的情形,比如书本遮挡、人脸遮挡(通话时)等等,开发人员可以根据具体情况进行设置,本申请对此不作任何限制。The application scenarios shown in FIGS. 5a, 5b, and 5c do not limit the embodiments of the present application. The anti-mistouch mode is not only applied to pocket scenarios, backpack scenarios, luggage scenarios, and palm blocking scenarios, but also applied to other electronic devices. The occluded situation, such as book occlusion, face occlusion (during a call), etc., can be set by the developer according to the specific situation, which is not limited in this application.
在一些实施例中,如图6a所示,在电子设备的设置用户界面601上可以显示有“防误触模式”设置栏602,用户可以手动选择开启/关闭“防误触模式”选项603。在“防误触模式”处于开启的状态下,当电子设备检测到当前处于被遮挡的状态时,电子设备开启防误触功能,有效防止误触情况的发生。In some embodiments, as shown in FIG. 6a , a setting bar 602 of “Anti-Accidental Touch Mode” may be displayed on the setting user interface 601 of the electronic device, and the user may manually select an option 603 to enable/disable the “Anti-Accidental Touch Mode”. When the "anti-accidental touch mode" is turned on, when the electronic device detects that it is currently in a blocked state, the electronic device turns on the anti-accidental touch function, which effectively prevents the occurrence of a false-touch situation.
防误触功能可以是电子设备熄屏,电子设备不响应屏幕解锁(可以包括上滑屏幕解锁、指纹解锁、手势解锁、人脸识别解锁等),电子设备不响应抬手亮屏,电子设备不响应抬手接听来电,电子设备关闭AOD等等功能。另外,可以理解的是,在遇到接收到来电(包括电话来电或即时通信软件的语音、视频请求)、通知消息时等情况,电子设备的防误触功能可能会被打断。在播放视频、播放音乐、运行游戏等娱乐场景下,电子设备可以设置为不会启动防误触功能,所以即使检测到电子设备处于被遮挡状态,例如用户使用手机横屏玩游戏时,手遮挡到电子设备的顶部,也不会启动自动熄屏。或者用户可以自行设置开启或关闭防误触功能,或者自行设置一个或多个应用程序开启或关闭防误触功能。若用户选择关闭“防误触模式”功能,则电子设备会关闭前述防误触功能。在通用的设置中,设置“防误触模式”可以对所有应用程序生效,另外,在每个具体应用程序的设置选项中,也可以存在“防误触模式”,选择某个应用程序打开/关闭“防误触模式”,可以使得“防误触模式”对该应用程序生效/不生效。The anti-mistouch function can be that the electronic device turns off the screen, the electronic device does not respond to the screen unlocking (which may include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.), the electronic device does not respond to raising the hand to turn on the screen, and the electronic device does not respond. In response to raising your hand to answer an incoming call, the electronic device turns off AOD and other functions. In addition, it can be understood that, in the event of receiving an incoming call (including a phone call or a voice and video request from an instant messaging software), a notification message, etc., the anti-accidental touch function of the electronic device may be interrupted. In entertainment scenarios such as playing videos, playing music, running games, etc., the electronic device can be set not to activate the anti-mistouch function, so even if the electronic device is detected to be blocked, for example, when the user plays games on the horizontal screen of the mobile phone, the hand is blocked. Going to the top of the electronic device does not activate the automatic screen off either. Or the user can set to turn on or off the anti-mistouch function by himself, or set one or more applications to turn on or off the anti-mistouch function by himself. If the user chooses to turn off the "anti-mistouch mode" function, the electronic device will turn off the aforementioned anti-mistouch function. In the general settings, the setting of "Anti-Accidental Touch Mode" can take effect for all applications. In addition, in the setting options of each specific application, there can also be "Anti-Accidental Touch Mode", select an application to open/ Turning off "Anti-Accidental Touch Mode" can make the "Anti-Accidental Touch Mode" take effect/ineffective for the application.
在一些实施例中,如图6b所示,在电子设备的用户界面的下拉通知栏604中,也可以显示有防触控模式的快捷按键605,方便用户快速开启/关闭防触控模式。In some embodiments, as shown in FIG. 6b , in the pull-down notification bar 604 of the user interface of the electronic device, a shortcut button 605 for the anti-touch mode may also be displayed, so that the user can quickly turn on/off the anti-touch mode.
本申请实施例对用户界面中“防触控模式”的名称以及图标等不作任何限制,图6a、 图6b所示仅为一个示例。This embodiment of the present application does not impose any restrictions on the name and icon of the "anti-touch mode" in the user interface, and what is shown in FIG. 6a and FIG. 6b is just an example.
本申请实施例中的术语“用户界面(user interface,UI)”,是应用程序或操作系统与用户之间进行交互和信息交换的介质接口,它实现信息的内部形式与用户可以接受形式之间的转换。用户界面常用的表现形式是图形用户界面(graphic user interface,GUI),是指采用图形方式显示的与计算机操作相关的用户界面。它可以是在电子设备的显示屏中显示的一个图标、窗口、控件等界面元素,其中控件可以包括图标、按钮、菜单、选项卡、文本框、对话框、状态栏、导航栏、Widget等可视的界面元素。The term "user interface (UI)" in the embodiments of the present application is a medium interface for interaction and information exchange between an application program or an operating system and a user, which realizes the relationship between the internal form of information and the form acceptable to the user. conversion. A commonly used form of user interface is a graphical user interface (GUI), which refers to a user interface related to computer operations that is displayed graphically. It can be an icon, window, control and other interface elements displayed on the display screen of the electronic device, wherein the control can include icons, buttons, menus, tabs, text boxes, dialog boxes, status bars, navigation bars, Widgets, etc. visual interface elements.
在一些实施例中,在电子设备还未启动防误触状态时,可以在音频驱动层加入其它判断逻辑,以在某些使用场景下,关闭超声波检测,从而提高用户体验,并进一步降低功耗。比如,在娱乐场景、来电场景等,娱乐场景可以包括用户使用电子设备看视频、听音乐、玩游戏等;来电场景包括电子设备接收到电话呼入或者即时通信软件(如微信、QQ、Skype、Face Time等)的语音聊天、视频聊天等。可以理解,在本申请的其他实施例中,也可以采用其他判断逻辑控制电子设备开启/关闭超声波检测,并不限于前述实施例,只要能够实现特定应用场景下开启/关闭防误触功能的目的即可,在此不作任何限制。In some embodiments, when the electronic device has not yet activated the anti-mistouch state, other judgment logic may be added to the audio driver layer to turn off ultrasonic detection in certain usage scenarios, thereby improving user experience and further reducing power consumption . For example, in an entertainment scenario, an incoming call scenario, etc., the entertainment scenario may include the user using an electronic device to watch videos, listen to music, play games, etc.; the incoming call scenario includes the electronic device receiving an incoming call or instant messaging software (such as WeChat, QQ, Skype, Face Time, etc.) voice chat, video chat, etc. It can be understood that in other embodiments of the present application, other judgment logic can also be used to control the electronic device to turn on/off the ultrasonic detection, which is not limited to the foregoing embodiments, as long as the purpose of turning on/off the anti-mistouch function in a specific application scenario can be achieved. That is, there is no restriction here.
超声波传感器还可以跟其他传感器结合进行耦合判断,例如重力传感器、陀螺仪传感器、环境光传感器等。在一个实施例中,电子设备的处理器可以对环境光传感器和超声波传感器分别上报的检测当前是否处于被遮挡状态作一个耦合分析,只要有一个表示当前电子设备处于被遮挡状态,电子设备可以判定当前处于被遮挡状态,然后电子设备开启防误触功能,触控显示屏处于锁定状态。可以理解,在本申请的其他实施例中,也可以采用其他耦合逻辑,本申请对电子设备采用传感器的数量、种类以及各个传感器之间的耦合逻辑并不进行任何限制,能够实现本申请阐述的防误触功能的目的即可。Ultrasonic sensors can also be combined with other sensors for coupling judgment, such as gravity sensors, gyroscope sensors, and ambient light sensors. In one embodiment, the processor of the electronic device can perform a coupling analysis on whether the detections reported by the ambient light sensor and the ultrasonic sensor are currently in a blocked state. As long as there is one that indicates that the current electronic device is in a blocked state, the electronic device can determine whether the detection is currently in a blocked state. It is currently blocked, and then the electronic device turns on the anti-mistouch function, and the touch screen is locked. It can be understood that in other embodiments of the present application, other coupling logics may also be used, and the present application does not impose any restrictions on the number and types of sensors used in electronic devices and the coupling logic between the various sensors, which can implement the The purpose of the anti-mistouch function is sufficient.
基于前述的一些实施例,下面介绍本申请提供的一种防误触的方法。Based on some of the foregoing embodiments, a method for preventing accidental touch provided by the present application is introduced below.
该方法应用于带有超声波发射器和超声波接收器的电子设备上,超声波发射器和超声波接收器可以设置在电子设备的顶部,也可以为其他位置,本实施例不做限制。The method is applied to an electronic device with an ultrasonic transmitter and an ultrasonic receiver. The ultrasonic transmitter and the ultrasonic receiver may be arranged on the top of the electronic device, or may be located at other positions, which are not limited in this embodiment.
在本申请实施例中,超声波发射器和超声波接收器旨在涵盖任何可以发射和接收超声波的功能的电子器件,并不局限于狭义的超声波发射器和超声波接收器。另外,超声波发射器和超声波接收器可以集中在同一器件上,也可以分离开。并且,超声波发射器或超声波接收器的数量可以是一个或多个。或者甚至是,超声波发射器旨在包括一个或多个超声波发射器,超声波接收器旨在包括一个或多个超声波接收器。超声波发射器的数量和超声波接收器的数量可以相等,也可以不相等,本申请实施例对此不作任何限制。In the embodiments of the present application, the ultrasonic transmitter and the ultrasonic receiver are intended to cover any electronic device capable of transmitting and receiving ultrasonic waves, and are not limited to the ultrasonic transmitter and ultrasonic receiver in the narrow sense. In addition, the ultrasonic transmitter and ultrasonic receiver can be centralized on the same device, or they can be separated. And, the number of ultrasonic transmitters or ultrasonic receivers may be one or more. Or even, the ultrasonic transmitter is intended to comprise one or more ultrasonic transmitters and the ultrasonic receiver is intended to comprise one or more ultrasonic receivers. The number of ultrasonic transmitters and the number of ultrasonic receivers may or may not be equal, which is not limited in this embodiment of the present application.
参见图7,图7是本申请实施例提供一种防误触的方法的流程示意图。如图7所示,该方法可包括:Referring to FIG. 7 , FIG. 7 is a schematic flowchart of a method for preventing accidental touch provided by an embodiment of the present application. As shown in Figure 7, the method may include:
S101,电子设备发射N次超声波信号,其中N大于或等于2,N为正整数。S101, the electronic device transmits ultrasonic signals N times, wherein N is greater than or equal to 2, and N is a positive integer.
在一些实施例中,电子设备可以通过超声波发射器断续向周围发射超声波信号,即电子设备可以间隔的发射多次超声波信号;其中,一次超声波信号可以包括多个超声波信号。本申请对采用超声波发射器的类型,对所发射的超声波的频率、方向、强度等等不做任何限制,具体可以根据实际情况调整,在此不再赘述。In some embodiments, the electronic device may intermittently transmit ultrasonic signals to the surroundings through the ultrasonic transmitter, that is, the electronic device may transmit multiple ultrasonic signals at intervals; wherein, one ultrasonic signal may include multiple ultrasonic signals. This application does not impose any restrictions on the type of ultrasonic transmitter used, the frequency, direction, intensity, etc. of the transmitted ultrasonic waves, which can be adjusted according to the actual situation, and will not be repeated here.
S102,电子设备接收N次超声波回波信号。S102, the electronic device receives N times ultrasonic echo signals.
发射的超声波信号遇到障碍物会产生超声波回波,电子设备可以通过超声波接收器接收超声波回波信号,其中,一次超声波回波信号是由前述一次超声波信号在介质(空气、固体、液体)中经过传播、衰减、折射、反射、衍射等情况得到的。同样的,一次超声波回波信号可以包括多个超声波回波信号。When the transmitted ultrasonic signal encounters an obstacle, an ultrasonic echo will be generated, and the electronic device can receive the ultrasonic echo signal through the ultrasonic receiver. It is obtained through propagation, attenuation, refraction, reflection, diffraction, etc. Likewise, a primary ultrasonic echo signal may include a plurality of ultrasonic echo signals.
S103,电子设备根据每一次接收到的超声波回波信号得到第一数据。S103, the electronic device obtains first data according to each received ultrasonic echo signal.
在一些实施例中,每一次接收到的超声波回波信号的第一数据可以包括多个超声波回波信号的信号强度、传播时间等,具体可以参考前述图4,每一次接收到的超声波回波信号的第一数据可以是一幅超声波回波信号的冲击响应图。电子设备可以获取到N次超声波回波信号的冲击响应图,并将N次超声波回波信号的第一数据组合成一幅第一图像。参考图8,在一个示例中,N为10,图8中a图、图8中b图每张图均为10帧超声波回波信号的冲击响应图生成的第一图像。第一图像由多个第一像素点构成。在第一图像中,横坐标表示帧数,即采集接收到的超声波回波信号的次数;纵坐标表示测距,即超声波信号从发射到接收经过的相对距离;每一个第一像素点的色彩值表示一个超声波回波信号的信号强度,不同的色彩值表示超声波回波信号的不同的信号强度。在图8的示例中,颜色越浅表示超声波回波信号的信号强度越大。其中,在图8的示例中,图8中a图为手机在皮包内时采集到的一个第一图像,图8中b图为手机上方无遮挡时采集到的一个第一图像。In some embodiments, the first data of each received ultrasonic echo signal may include signal strengths, propagation times, etc. of multiple ultrasonic echo signals. For details, please refer to the aforementioned FIG. 4 . The first data of the signal may be an impulse response graph of the ultrasonic echo signal. The electronic device can acquire the impulse response graph of the N times ultrasonic echo signals, and combine the first data of the N times ultrasonic echo signals into a first image. Referring to FIG. 8 , in an example, N is 10, and each of the a and b in FIG. 8 is a first image generated by impulse response maps of 10 frames of ultrasonic echo signals. The first image is composed of a plurality of first pixels. In the first image, the abscissa represents the number of frames, that is, the number of times to collect the received ultrasonic echo signals; the ordinate represents the ranging, that is, the relative distance of the ultrasonic signal from transmission to reception; the color of each first pixel point The value represents the signal strength of an ultrasonic echo signal, and different color values represent different signal strengths of the ultrasonic echo signal. In the example of FIG. 8 , the lighter the color, the greater the signal strength of the ultrasonic echo signal. Wherein, in the example of FIG. 8 , picture a in FIG. 8 is a first image collected when the mobile phone is in a leather bag, and picture b in FIG. 8 is a first image collected when the top of the mobile phone is unobstructed.
S104,电子设备将N次超声波回波信号的第一数据输入第一分类模型,得到第一场景类型。S104, the electronic device inputs the first data of the N times ultrasonic echo signals into the first classification model to obtain the first scene type.
其中,第一分类模型是基于机器学习算法,使用第一训练数据,对第一训练模型进行训练得到的可信模型。关于第一分类模型是如何训练得到的,后文会进行说明,这里暂不赘述。The first classification model is a credible model obtained by training the first training model based on the machine learning algorithm and using the first training data. How the first classification model is trained will be explained later, and will not be repeated here.
第一场景类型可以包括电子设备被遮挡和电子设备未被遮挡两种,也可以是更为细分的多个场景类型,比如皮包遮挡场景、帆布包遮挡场景、棉衬衫口袋遮挡场景、牛仔裤口袋遮挡场景、手掌遮挡场景、书本遮挡场景、头发遮挡场景、衣物遮挡等等被各种遮挡物遮挡的情况,本申请实施例对此不作限制。The first scene type may include two types of electronic equipment being blocked and electronic equipment not being blocked, and may also be more subdivided scene types, such as leather bag blocking scene, canvas bag blocking scene, cotton shirt pocket blocking scene, jeans pocket scene The embodiments of the present application do not limit the situations in which the occlusion scene, the palm occlusion scene, the book occlusion scene, the hair occlusion scene, the clothing occlusion, and the like are occluded by various occluders.
在一些实施例中,可以采用卷积神经网络(convolutional neural networks,CNN)算法对采集到的N次超声波回波信号的第一数据,即第一图像进行特征提取,得到第一特征数据,再将第一特征数据输入第一分类模型。In some embodiments, a convolutional neural network (convolutional neural networks, CNN) algorithm may be used to perform feature extraction on the first data of the collected N times ultrasonic echo signals, that is, the first image, to obtain the first feature data, and then The first feature data is input into the first classification model.
卷积神经网络算法主要有两个算子,一个是卷积层,另一个是池化层(pooling layer)。卷积层可以用来提取特征,池化层可以用来减少参数数量。在卷积层中是使用卷积核来提取特征的,卷积核可以是一个矩阵,卷积层可以通过滑动一个滑动窗口,在滑动窗口之内做卷积运算,从而提取不同位置的图像特征。卷积层的输出结果输入到池化层,常用池化可以是最大池化和平均池化,最大池化是为了提取最明显的特征,平均池化是顾及每一个像素,提取平均特征。池化层也是滑动一个滑动窗口,在滑动窗口之内取最大值或取平均值。The convolutional neural network algorithm mainly has two operators, one is the convolutional layer and the other is the pooling layer. Convolutional layers can be used to extract features, and pooling layers can be used to reduce the number of parameters. In the convolution layer, the convolution kernel is used to extract features. The convolution kernel can be a matrix. The convolution layer can perform convolution operations within the sliding window by sliding a sliding window to extract image features at different positions. . The output of the convolutional layer is input to the pooling layer. Commonly used pooling can be maximum pooling and average pooling. Maximum pooling is to extract the most obvious features. Average pooling is to consider each pixel and extract the average feature. The pooling layer also slides a sliding window, and takes the maximum value or average value within the sliding window.
在一个示例中,参考图9所示,将某次超声波回波信号生成的第一图像作为输入图,输入到卷积神经网络算法中,卷积神经网络算法可以对第一图像进行两层卷积层的特征提 取,最后得到第一特征数据。具体地,首先将输入图输入带池化层的卷积层,对输入图进行第一次粗检测,提取输入图的特征点的大概位置,得到第一层次Level 1特征图;然后将Level 1特征图再输入带池化层的卷积层,以Level 1特征图的预测特征点为中心,重新提取更为精确的特征点位置,得到第二层次Level 2特征图;之后Level 2特征图经过全连接层,全连接层可以将各个图像对应的特征进行合并,输出第一特征数据;最后生成的第一特征数据输入到第一分类模型中。In an example, as shown in FIG. 9 , the first image generated by a certain ultrasonic echo signal is used as the input image and input into the convolutional neural network algorithm. The convolutional neural network algorithm can perform two-layer convolution on the first image. The feature extraction of the layered layer finally obtains the first feature data. Specifically, first input the input image into the convolutional layer with pooling layer, perform the first rough detection on the input image, extract the approximate positions of the feature points of the input image, and obtain the first level Level 1 feature map; The feature map is then input to the convolutional layer with a pooling layer, and the predicted feature points of the Level 1 feature map are taken as the center to re-extract more accurate feature point positions to obtain the second-level Level 2 feature map; then the Level 2 feature map passes through The fully connected layer can combine the features corresponding to each image to output the first feature data; the finally generated first feature data is input into the first classification model.
S105,根据第一场景类型判定电子设备是否处于被遮挡状态,如果是,则执行步骤S106,如果否,则不作任何操作,继续收发超声波信号,即执行步骤S101。S105, determine whether the electronic device is in a blocked state according to the first scene type, if so, go to step S106, if not, do nothing, continue to send and receive ultrasonic signals, that is, go to step S101.
如果第一场景类型分类为电子设备被遮挡和电子设备未被遮挡两种,则可以直接输出判定结果为电子设备被遮挡或电子设备未被遮挡。如果第一场景类型为多个具体细分场景类型,比如皮包遮挡场景、帆布包遮挡场景、棉衬衫口袋遮挡场景、牛仔裤口袋遮挡场景、手掌遮挡场景、书本遮挡场景、头发遮挡场景等等,则需要再根据检测到的具体场景类型,再进行判定电子设备是否处于被遮挡状态。If the first scene type is classified into two types: the electronic device is blocked and the electronic device is not blocked, the determination result may be directly output as that the electronic device is blocked or the electronic device is not blocked. If the first scene type is a plurality of subdivided scene types, such as a leather bag occlusion scene, a canvas bag occlusion scene, a cotton shirt pocket occlusion scene, a jeans pocket occlusion scene, a palm occlusion scene, a book occlusion scene, a hair occlusion scene, etc., then It is necessary to determine whether the electronic device is in a blocked state according to the detected specific scene type.
在一些实施例中,还可以将超声波传感器检测到的第一场景类型结果跟其他传感器检测到的场景类型结合进行耦合判断,例如重力传感器、陀螺仪传感器、环境光传感器等。比如,电子设备的处理器可以对环境光传感器和超声波传感器的上报结果进行耦合分析,例如,虽然超声波传感器检测到电子设备处于被遮挡状态,但是环境光传感器检测到环境光亮度高于一定亮度值时,仍然不开启防误触功能;或者当环境光传感器检测到环境光亮度低于一定亮度值时,且超声波传感器检测到当前电子设备处于被遮挡状态,电子设备才会开启防误触功能等。电子设备的处理器还可以对接近光传感器和超声波传感器的上报结果进行耦合分析,例如,当接近光传感器或超声波传感器任一个检测到当前电子设备处于被遮挡状态时,电子设备开启防误触功能;或者当接近光传感器和超声波传感器两者均检测到当前电子设备处于被遮挡状态时,电子设备才开启防误触功能等。可以理解,在本申请的其他实施例中,也可以结合其他的传感器或采用其他耦合逻辑,本申请对电子设备采用传感器的数量、种类以及各个传感器之间的耦合逻辑并不进行任何限制,能够实现本申请阐述的目的即可。In some embodiments, the result of the first scene type detected by the ultrasonic sensor may also be combined with the scene type detected by other sensors, such as a gravity sensor, a gyroscope sensor, and an ambient light sensor, for coupling judgment. For example, the processor of the electronic device can couple and analyze the reported results of the ambient light sensor and the ultrasonic sensor. For example, although the ultrasonic sensor detects that the electronic device is blocked, the ambient light sensor detects that the brightness of the ambient light is higher than a certain brightness value. The anti-mistouch function is still not turned on; or when the ambient light sensor detects that the ambient light brightness is lower than a certain brightness value, and the ultrasonic sensor detects that the current electronic device is blocked, the electronic device will turn on the anti-mistouch function, etc. . The processor of the electronic device can also perform coupling analysis on the reported results of the proximity light sensor and the ultrasonic sensor. For example, when either the proximity light sensor or the ultrasonic sensor detects that the current electronic device is blocked, the electronic device turns on the anti-mistouch function. ; or when both the proximity light sensor and the ultrasonic sensor detect that the current electronic device is in a blocked state, the electronic device will turn on the anti-mistouch function, etc. It can be understood that in other embodiments of the present application, other sensors can also be combined or other coupling logics can be used. It is sufficient to achieve the purpose set forth in this application.
S106,电子设备开启防误触功能。S106, the electronic device enables the anti-mistouch function.
在一些实施例中,防误触功能可以是电子设备熄屏,电子设备不响应屏幕解锁(可以包括上滑屏幕解锁、指纹解锁、手势解锁、人脸识别解锁等),电子设备不响应抬手亮屏,电子设备不响应抬手接听来电,电子设备不响应指纹接听来电,电子设备关闭AOD等等功能。另外,可以理解的是,在遇到接收到来电(包括电话来电或即时通信软件的语音、视频请求)、通知消息时等情况,电子设备的防误触功能可能会被打断。在播放视频、播放音乐、运行游戏等娱乐场景下,电子设备可以设置为不会启动防误触功能,所以即使检测到电子设备处于被遮挡状态,例如用户使用手机横屏玩游戏时,手遮挡到电子设备的顶部,也不会启动自动熄屏。或者用户可以自行设置开启或关闭防误触功能,或者自行设置一个或多个应用程序开启或关闭防误触功能。In some embodiments, the anti-mistouch function may be that the electronic device turns off the screen, the electronic device does not respond to screen unlocking (which may include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.), and the electronic device does not respond to raising a hand When the screen is on, the electronic device does not respond to raising the hand to answer the incoming call, the electronic device does not respond to the fingerprint to answer the incoming call, the electronic device turns off AOD and other functions. In addition, it can be understood that, in the event of receiving an incoming call (including a phone call or a voice and video request from an instant messaging software), a notification message, etc., the anti-accidental touch function of the electronic device may be interrupted. In entertainment scenarios such as playing videos, playing music, running games, etc., the electronic device can be set not to activate the anti-mistouch function, so even if the electronic device is detected to be blocked, for example, when the user plays games on the horizontal screen of the mobile phone, the hand is blocked. Going to the top of the electronic device does not activate the automatic screen off either. Or the user can set to turn on or off the anti-mistouch function by himself, or set one or more applications to turn on or off the anti-mistouch function by himself.
下面说明第一分类模型是如何训练得到的。The following describes how the first classification model is trained.
在一个实施例中,第一分类模型是基于机器学习分类算法,使用第一训练数据,对第一训练模型进行训练得到的可信模型。其中,第一训练数据包括多个样本数据,多个样本数据是在多个场景下获得的样本数据,一个样本数据包括一个已知场景下的N次超声波回波信号的第一样本数据以及该场景的第一样本场景类型。第一样本场景类型为已知场景类型。多个第一样本数据构成第一样本数据向量,对应多个第一样本场景类型构成的第一样本场景类型标签。另外,样本数据可以分为两部分,一部分样本数据用于训练模型,另一部分样本数据可以用来测试模型的准确率。其中,多个是指模型训练所需足够量的数据量,例如数千、数万甚至数十万数据单元。一个第一样本数据为发射N次超声波信号所产生的N次超声波回波信号的第二数据生成的一幅第二图像,每一次接收到的超声波回波信号的第二数据可以包括多个超声波回波信号的信号强度、传播时间等。参考图8,第二图像由多个第二像素点构成,在第二图像中,横坐标表示帧数,即采集接收到的超声波回波信号的次数,纵坐标表示测距,即超声波信号从发射到接收经过的相对距离,每一个第二像素点的色彩值表示一个超声波回波信号的信号强度,不同的色彩值表示超声波回波信号的不同的信号强度,在图8的示例中,颜色越浅表示超声波回波信号的信号强度越大。第一样本场景类型可以包括电子设备被遮挡和电子设备未被遮挡两种,也可以是更为细分的多个场景类型,比如皮包遮挡场景、帆布包遮挡场景、棉衬衫口袋遮挡场景、牛仔裤口袋遮挡场景、手掌遮挡场景、书本遮挡场景、头发遮挡场景等等被各种遮挡物遮挡的情况,本申请实施例不作限制。In one embodiment, the first classification model is a credible model obtained by training the first training model using the first training data based on a machine learning classification algorithm. Wherein, the first training data includes multiple sample data, the multiple sample data is sample data obtained in multiple scenarios, and one sample data includes first sample data of N times ultrasonic echo signals in a known scenario and The first sample scene type for this scene. The first sample scene type is a known scene type. A plurality of first sample data constitute a first sample data vector, which corresponds to a first sample scene type label formed by a plurality of first sample scene types. In addition, the sample data can be divided into two parts, one part of the sample data is used to train the model, and the other part of the sample data can be used to test the accuracy of the model. Among them, multiple refers to a sufficient amount of data required for model training, such as thousands, tens of thousands or even hundreds of thousands of data units. A first sample data is a second image generated by the second data of N times of ultrasonic echo signals generated by transmitting N times of ultrasonic signals, and the second data of each received ultrasonic echo signal may include a plurality of The signal strength, propagation time, etc. of the ultrasonic echo signal. Referring to FIG. 8 , the second image is composed of a plurality of second pixels. In the second image, the abscissa represents the number of frames, that is, the number of times of collecting the received ultrasonic echo signals, and the ordinate represents ranging, that is, the ultrasonic signal is from The relative distance from transmission to reception, the color value of each second pixel represents the signal strength of an ultrasonic echo signal, and different color values represent different signal intensities of the ultrasonic echo signal. In the example of Figure 8, the color The shallower the signal strength of the ultrasonic echo signal is. The first sample scene type may include two types of electronic equipment being blocked and electronic equipment not being blocked, and may also be more subdivided scene types, such as a leather bag blocking scene, a canvas bag blocking scene, a cotton shirt pocket blocking scene, The embodiments of the present application do not limit the situations in which the jeans pocket occlusion scene, the palm occlusion scene, the book occlusion scene, the hair occlusion scene, and the like are blocked by various occluders.
在训练过程中使用的机器学习分类模型,可以包括但不限于:极端梯度提升(extreme gradient boosting,XGBoost)模型、神经网络(neural network,NN)模型、梯度提升决策树(gradient boosting decision tree,GBDT)模型,随机森林(random forest,RF)模型等等。在本申请实施例中,对具体采用何种机器学习分类算法不做限定,本领域技术人员可以根据实际应用采用不同的机器学习分类模型。The machine learning classification models used in the training process may include but are not limited to: extreme gradient boosting (XGBoost) model, neural network (NN) model, gradient boosting decision tree (GBDT) ) model, random forest (RF) model, etc. In the embodiment of the present application, there is no limitation on which machine learning classification algorithm is specifically used, and those skilled in the art may use different machine learning classification models according to actual applications.
在一些实施例中,可以采用XGBoost模型训练得出可信的第一分类模型。其中,XGBoost模型是一种使用梯度增强框架并基于决策树的集成机器学习模型,其具体可由多个决策树组成,此处的决策树是分类与回归树(Classification and regression tree,CART),CART决策是一个二叉树,内部结点特征的取值为“是”和“否”,可将每个结点的取值为“是”的分支作为该结点的左分支,将取值为“否”的分支作为该结点的右分支;XGBoost模型的基本思想为:根据样本的特征逐渐构建多个决策树,每构建一个决策树时,均要使得模型的整体效果有所提升,如使得损失函数的函数值有所下降,且当前构建的决策树拟合前一个构建的决策树所导致的残差。在该实施例中,首先可以初始化一个训练模型,也称为一个弱分类器,然后将第一样本数据向量输入该弱分类器,得到一个样本识别结果,若该样本识别结果与第一样本场景类型标签不匹配,则表明需要对当前的弱分类器进行迭代,具体迭代过程可以理解为,根据样本识别结果与第一样本场景类型标签之间的残差,调整该弱分类器的模型参数,然后在能够减少残差的梯度方向上基于调整后的模型参数建立一个新的训练模型,以此类推,重复执行上述迭代过程,直到得到样本识别结果与第一样本场景类型标签匹配,此时得到一个强分类器,即第一分类模型。该第一分类模型是可信的,在测试中其置信度可以是95%或98%等,实际可以根据具体需求调整。In some embodiments, an XGBoost model can be used to train to obtain a credible first classification model. Among them, the XGBoost model is an integrated machine learning model that uses the gradient boosting framework and is based on a decision tree. It can be composed of multiple decision trees. The decision tree here is a classification and regression tree (CART), CART The decision is a binary tree, and the values of the internal node features are "Yes" and "No". The branch with the value of "Yes" for each node can be used as the left branch of the node, and the value of "No" can be used. ” as the right branch of the node; the basic idea of the XGBoost model is to gradually build multiple decision trees according to the characteristics of the samples. The function value of the function has decreased, and the currently constructed decision tree fits the residual caused by the previously constructed decision tree. In this embodiment, a training model, also called a weak classifier, can be initialized first, and then the first sample data vector is input into the weak classifier to obtain a sample recognition result, if the sample recognition result is the same as the first If the scene type label does not match, it indicates that the current weak classifier needs to be iterated. The specific iterative process can be understood as adjusting the value of the weak classifier according to the residual between the sample identification result and the scene type label of the first sample. model parameters, and then establish a new training model based on the adjusted model parameters in the gradient direction that can reduce the residual error, and so on, repeat the above iterative process until the sample identification result matches the first sample scene type label , and a strong classifier is obtained at this time, that is, the first classification model. The first classification model is credible, and its confidence level can be 95% or 98% in the test, which can actually be adjusted according to specific needs.
基于前述的一些实施例,下面介绍本申请提供的一种防误触的电子设备的功能模块。Based on some of the foregoing embodiments, the functional modules of an electronic device for preventing accidental touches provided by the present application are introduced below.
图10示出了本申请实施例提供的一种防误触的电子设备的功能模块框图。该电子设备的功能模块可由硬件、软件或硬件与软件的组合来实施本申请方案。所属领域的技术人员应理解,图10中所描述的功能模块可经组合或分离为若干子块以实施本申请方案。因此,本申请中上面描述的内容可支持对下述功能模块的任何可能的组合或分离或进一步定义。FIG. 10 shows a block diagram of functional modules of an electronic device for preventing accidental touches provided by an embodiment of the present application. The functional modules of the electronic device can be implemented by hardware, software or a combination of hardware and software to implement the solution of the present application. Those skilled in the art should understand that the functional modules described in FIG. 10 may be combined or separated into several sub-blocks to implement the scheme of the present application. Accordingly, what is described above in this application may support any possible combination or separation or further definition of the functional modules described below.
本实施例中,电子设备包括超声波发射器和超声波接收器,超声波发射器和超声波接收器可以设置在电子设备的顶部,也可以为其他位置,本实施例不做限制。In this embodiment, the electronic device includes an ultrasonic transmitter and an ultrasonic receiver, and the ultrasonic transmitter and the ultrasonic receiver may be disposed on the top of the electronic device, or may be located at other positions, which are not limited in this embodiment.
在本申请实施例中,超声波发射器和超声波接收器旨在涵盖任何可以发射和接收超声波的功能的电子器件,并不局限于狭义的超声波发射器和超声波接收器。另外,超声波发射器和超声波接收器可以集中在同一器件上,也可以分离开。并且,超声波发射器或超声波接收器的数量可以是一个或多个。或者甚至是,超声波发射器旨在包括一个或多个超声波发射器,超声波接收器旨在包括一个或多个超声波接收器。超声波发射器的数量和超声波接收器的数量可以相等,也可以不相等,本申请实施例对此不作任何限制。In the embodiments of the present application, the ultrasonic transmitter and the ultrasonic receiver are intended to cover any electronic device capable of transmitting and receiving ultrasonic waves, and are not limited to the ultrasonic transmitter and ultrasonic receiver in the narrow sense. In addition, the ultrasonic transmitter and ultrasonic receiver can be centralized on the same device, or they can be separated. And, the number of ultrasonic transmitters or ultrasonic receivers may be one or more. Or even, the ultrasonic transmitter is intended to comprise one or more ultrasonic transmitters and the ultrasonic receiver is intended to comprise one or more ultrasonic receivers. The number of ultrasonic transmitters and the number of ultrasonic receivers may or may not be equal, which is not limited in this embodiment of the present application.
电子设备具体可以包括:超声波信号发射模块、超声波回波信号接收模块、信号特征提取模块、场景分类模块、防误触功能开启模块、离线模型训练模块。The electronic device may specifically include: an ultrasonic signal transmitting module, an ultrasonic echo signal receiving module, a signal feature extraction module, a scene classification module, a false-touch prevention function enabling module, and an offline model training module.
超声波信号发射模块用于发射N次超声波信号,其中N大于或等于2,N为正整数。在一些实施例中,超声波信号发射模块可以通过超声波发射器断续向周围发射超声波信号,即电子设备可以间隔的发射多次超声波信号;其中,一次超声波信号可以包括多个超声波信号。本申请对采用超声波发射器的类型,对所发射的超声波的频率、方向、强度等等不做任何限制,具体可以根据实际情况调整,在此不再赘述。The ultrasonic signal transmitting module is used for transmitting ultrasonic signals for N times, wherein N is greater than or equal to 2, and N is a positive integer. In some embodiments, the ultrasonic signal transmitting module can intermittently transmit ultrasonic signals to the surroundings through the ultrasonic transmitter, that is, the electronic device can transmit ultrasonic signals multiple times at intervals; wherein, one ultrasonic signal can include multiple ultrasonic signals. This application does not impose any restrictions on the type of ultrasonic transmitter used, the frequency, direction, intensity, etc. of the transmitted ultrasonic waves, which can be adjusted according to the actual situation, and will not be repeated here.
超声波回波信号接收模块用于接收N次超声波回波信号。发射的超声波信号遇到障碍物会产生超声波回波,超声波回波信号接收模块可以通过超声波接收器接收超声波回波信号,其中,一次超声波回波信号是由前述一次超声波信号在介质(空气、固体、液体)中经过传播、衰减、折射、反射、衍射等情况得到的。同样的,一次超声波回波信号可以包括多个超声波回波信号。The ultrasonic echo signal receiving module is used for receiving N times ultrasonic echo signals. The transmitted ultrasonic signal will generate ultrasonic echo when encountering obstacles. The ultrasonic echo signal receiving module can receive the ultrasonic echo signal through the ultrasonic receiver. , liquid) through propagation, attenuation, refraction, reflection, diffraction, etc. Likewise, a primary ultrasonic echo signal may include a plurality of ultrasonic echo signals.
信号特征提取模块用于将得到的每一次接收到的超声波回波信号的第一数据进行特征提取,得到第一特征数据,作为第一分类模型的输入。在一些实施例中,每一次接收到的超声波回波信号的第一数据可以包括多个超声波回波信号的信号强度、传播时间等,每一次接收到的超声波回波信号的第一数据可以是一幅超声波回波信号的冲击响应图。电子设备可以获取到N次超声波回波信号的冲击响应图,并将N次超声波回波信号的第一数据组合成一幅第一图像,具体可以参考前述方法实施例步骤S103。The signal feature extraction module is configured to perform feature extraction on the obtained first data of each received ultrasonic echo signal to obtain the first feature data, which is used as the input of the first classification model. In some embodiments, the first data of the ultrasonic echo signals received each time may include signal strengths, propagation times, etc. of a plurality of ultrasonic echo signals, and the first data of the ultrasonic echo signals received each time may be A graph of the impulse response of an ultrasonic echo signal. The electronic device may acquire the impulse response graph of the N times ultrasonic echo signals, and combine the first data of the N times ultrasonic echo signals into a first image. For details, refer to step S103 in the foregoing method embodiment.
在一些实施例中,信号特征提取模块可以采用卷积神经网络(convolutional neural networks,CNN)算法对采集到的N次超声波回波信号的第一数据,即第一图像,进行特征提取,得到第一特征数据,再将第一特征数据输入第一分类模型。卷积神经网络算法是如何提取特征的,具体可以参考方法实施例步骤S104中的描述,这里不再赘述。In some embodiments, the signal feature extraction module may use a convolutional neural network (convolutional neural networks, CNN) algorithm to perform feature extraction on the first data of the collected N times ultrasonic echo signals, that is, the first image, to obtain the first a feature data, and then input the first feature data into the first classification model. For details on how the convolutional neural network algorithm extracts features, reference may be made to the description in step S104 of the method embodiment, which will not be repeated here.
场景分类模块用于将N次超声波回波信号的第一数据输入第一分类模型,得到第一场景类型。其中,第一分类模型是基于机器学习算法,使用第一训练数据,对第一训练模型 进行训练得到的可信模型。关于第一分类模型是如何训练得到的,参考前述实施例中相关说明,这里暂不赘述。第一场景类型可以包括电子设备被遮挡和电子设备未被遮挡两种,也可以是更为细分的多个场景类型,比如皮包遮挡场景、帆布包遮挡场景、棉衬衫口袋遮挡场景、牛仔裤口袋遮挡场景、手掌遮挡场景、书本遮挡场景、头发遮挡场景等等被各种遮挡物遮挡的情况,本申请实施例不作限制。The scene classification module is configured to input the first data of the N ultrasonic echo signals into the first classification model to obtain the first scene type. Wherein, the first classification model is a credible model obtained by training the first training model using the first training data based on the machine learning algorithm. As to how the first classification model is obtained by training, refer to the relevant descriptions in the foregoing embodiments, which will not be described here for the time being. The first scene type may include two types of electronic equipment being blocked and electronic equipment not being blocked, and may also be more subdivided scene types, such as leather bag blocking scene, canvas bag blocking scene, cotton shirt pocket blocking scene, jeans pocket scene The embodiments of the present application do not limit the situations in which the occlusion scene, the palm occlusion scene, the book occlusion scene, the hair occlusion scene, and the like are occluded by various occluders.
场景分类模块还用于根据第一场景类型判定电子设备是否处于被遮挡状态。如果第一场景类型分类为电子设备被遮挡和电子设备未被遮挡两种,则场景分类模块可以直接输出判定结果为电子设备被遮挡或电子设备未被遮挡。如果第一场景类型为多个具体细分场景类型,比如皮包遮挡场景、帆布包遮挡场景、棉衬衫口袋遮挡场景、牛仔裤口袋遮挡场景、手掌遮挡场景、书本遮挡场景、头发遮挡场景等等,则场景分类模块需要再根据检测到的具体场景类型,再进行判定电子设备是否处于被遮挡状态。The scene classification module is further configured to determine whether the electronic device is in a blocked state according to the first scene type. If the first scene type is classified into two types: the electronic device is blocked and the electronic device is not blocked, the scene classification module can directly output the determination result that the electronic device is blocked or the electronic device is not blocked. If the first scene type is a plurality of subdivided scene types, such as a leather bag occlusion scene, a canvas bag occlusion scene, a cotton shirt pocket occlusion scene, a jeans pocket occlusion scene, a palm occlusion scene, a book occlusion scene, a hair occlusion scene, etc., then The scene classification module needs to determine whether the electronic device is in a blocked state according to the detected specific scene type.
在一些实施例中,场景分类模块还可以将超声波传感器检测到的第一场景类型结果跟其他传感器检测到的场景类型结合进行耦合判断,例如重力传感器、陀螺仪传感器、环境光传感器、接近光传感器等。比如,场景分类模块可以对环境光传感器和超声波传感器的上报结果进行耦合分析,例如,虽然超声波传感器检测到电子设备处于被遮挡状态,但是环境光传感器检测到环境光亮度高于一定亮度值时,仍然不开启防误触功能;或者当环境光传感器检测到环境光亮度低于一定亮度值时,且超声波传感器检测到当前电子设备处于被遮挡状态,电子设备才会开启防误触功能等。In some embodiments, the scene classification module may further combine the results of the first scene type detected by the ultrasonic sensor with the scene types detected by other sensors to perform coupling judgment, such as a gravity sensor, a gyroscope sensor, an ambient light sensor, and a proximity light sensor. Wait. For example, the scene classification module can perform coupling analysis on the reported results of the ambient light sensor and the ultrasonic sensor. The anti-mistouch function is still not turned on; or when the ambient light sensor detects that the ambient light brightness is lower than a certain brightness value, and the ultrasonic sensor detects that the current electronic device is blocked, the electronic device will turn on the anti-mistouch function, etc.
在一些实施例中,场景分类模块还可以对接近光传感器和超声波传感器的上报结果进行耦合分析,例如,当接近光传感器或超声波传感器任一个检测到当前电子设备处于被遮挡状态时,电子设备开启防误触功能;或者当接近光传感器和超声波传感器两者均检测到当前电子设备处于被遮挡状态时,电子设备才开启防误触功能等。可以理解,在本申请的其他实施例中,也可以结合其他的传感器或采用其他耦合逻辑,本申请对电子设备采用传感器的数量、种类以及各个传感器之间的耦合逻辑并不进行任何限制,能够实现本申请阐述的目的即可。In some embodiments, the scene classification module may also perform coupling analysis on the reported results of the proximity light sensor and the ultrasonic sensor. For example, when either the proximity light sensor or the ultrasonic sensor detects that the current electronic device is in a blocked state, the electronic device is turned on. Anti-mistouch function; or when both the proximity light sensor and the ultrasonic sensor detect that the current electronic device is in a blocked state, the electronic device will turn on the anti-mistouch function, etc. It can be understood that in other embodiments of the present application, other sensors can also be combined or other coupling logics can be used. It is sufficient to achieve the purpose set forth in this application.
防误触功能开启模块用于在检测到电子设备处于被遮挡状态时,自动开启防误触功能。在一些实施例中,防误触功能可以是电子设备熄屏,电子设备不响应屏幕解锁(可以包括上滑屏幕解锁、指纹解锁、手势解锁、人脸识别解锁等),电子设备不响应抬手亮屏,电子设备不响应抬手接听来电,电子设备不响应指纹接听来电,电子设备关闭AOD等等功能。另外,可以理解的是,在遇到接收到来电(包括电话来电或即时通信软件的语音、视频请求)、通知消息时等情况,电子设备的防误触功能可能会被打断。在运行游戏、播放视频、播放音乐等娱乐场景下,电子设备可以设置为不会启动防误触功能,所以即使检测到电子设备处于被遮挡状态,例如用户使用手机横屏玩游戏时,手遮挡到电子设备的顶部,也不会启动自动熄屏。或者用户可以自行设置开启或关闭防误触功能,或者自行设置一个或多个应用程序开启或关闭防误触功能。The anti-mistouch function enabling module is used to automatically turn on the anti-mistouch function when it is detected that the electronic device is in a blocked state. In some embodiments, the anti-mistouch function may be that the electronic device turns off the screen, the electronic device does not respond to screen unlocking (which may include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.), and the electronic device does not respond to raising a hand When the screen is on, the electronic device does not respond to raising the hand to answer the incoming call, the electronic device does not respond to the fingerprint to answer the incoming call, the electronic device turns off AOD and other functions. In addition, it can be understood that, in the event of receiving an incoming call (including a phone call or a voice and video request from an instant messaging software), a notification message, etc., the anti-accidental touch function of the electronic device may be interrupted. In entertainment scenarios such as running games, playing videos, playing music, etc., the electronic device can be set to not activate the anti-mistouch function, so even if the electronic device is detected to be blocked, for example, when the user plays games on the horizontal screen of the mobile phone, the hand is blocked. Going to the top of the electronic device does not activate the automatic screen off either. Or the user can set to turn on or off the anti-mistouch function by himself, or set one or more applications to turn on or off the anti-mistouch function by himself.
实施本申请发明方法的实施例,电子设备可以准确检测当前是否处于被遮挡的状态,当判断到电子设备当前在口袋或背包中等被遮挡的场景时,电子设备可以自动启动防误触 功能,比如电子设备熄屏、不响应屏幕解锁(可以包括上滑屏幕解锁、指纹解锁、手势解锁、人脸识别解锁等)、不响应抬手亮屏、不响应抬手接听来电、关闭AOD等等,可以防止误触情况的发生以及降低电子设备的功耗,给用户提供了一个友好的操作环境,提升了用户的使用体验。另外,采用超声波传感器替代光学接近传感器实现防误触功能,还可以减少电子设备的电子器件以及节省屏幕的正面开孔,缩窄电子设备的边框空间,提升电子设备的屏占比,提高电子设备的抗尘防水性能等。By implementing the embodiments of the method of the present application, the electronic device can accurately detect whether it is currently in a blocked state, and when it is determined that the electronic device is currently blocked in a pocket or a backpack, the electronic device can automatically activate the anti-mistouch function, such as The screen of the electronic device is turned off, the screen does not respond to unlocking (which may include sliding up the screen to unlock, fingerprint unlocking, gesture unlocking, face recognition unlocking, etc.), does not respond to raising the hand to brighten the screen, does not respond to raising the hand to answer incoming calls, turns off AOD, etc. Preventing accidental touches and reducing power consumption of electronic devices provides a user-friendly operating environment and improves user experience. In addition, the use of ultrasonic sensors instead of optical proximity sensors to achieve the anti-mistouch function can also reduce the number of electronic devices in electronic devices and save the front opening of the screen, narrow the frame space of electronic devices, increase the screen ratio of electronic devices, and improve electronic devices. Dust and water resistance, etc.
以上所述的具体实施方式,对本申请的目的、技术方案和有益效果进行了进一步详细说明,所应理解的是,以上所述仅为本申请的具体实施方式而已,并不用于限定本申请的保护范围,凡在本申请的技术方案的基础之上,所做的任何修改、等同替换、改进等,均应包括在本申请的保护范围之内。The specific embodiments described above further describe the purpose, technical solutions and beneficial effects of the present application in detail. It should be understood that the above descriptions are only specific embodiments of the present application, and are not intended to limit the The protection scope, any modifications, equivalent replacements, improvements, etc. made on the basis of the technical solutions of the present application shall be included within the protection scope of the present application.
本领域内的技术人员应明白,本申请的实施例可提供为方法、系统、或计算机程序产品。因此,本申请可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式。而且,本申请可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器和光学存储器等)上实施的计算机程序产品的形式。As will be appreciated by those skilled in the art, the embodiments of the present application may be provided as a method, a system, or a computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media having computer-usable program code embodied therein, including but not limited to disk storage, optical storage, and the like.
本申请是参照根据本申请实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the present application. It will be understood that each flow and/or block in the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to the processor of a general purpose computer, special purpose computer, embedded processor or other programmable data processing device to produce a machine such that the instructions executed by the processor of the computer or other programmable data processing device produce Means for implementing the functions specified in a flow or flow of a flowchart and/or a block or blocks of a block diagram.
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory result in an article of manufacture comprising instruction means, the instructions The apparatus implements the functions specified in the flow or flow of the flowcharts and/or the block or blocks of the block diagrams.
这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。These computer program instructions can also be loaded on a computer or other programmable data processing device to cause a series of operational steps to be performed on the computer or other programmable device to produce a computer-implemented process such that The instructions provide steps for implementing the functions specified in the flow or blocks of the flowcharts and/or the block or blocks of the block diagrams.
显然,本领域的技术人员可以对本申请进行各种改动和变型而不脱离本申请的精神和范围。这样,倘若本申请的这些修改和变型属于本申请权利要求及其等同技术的范围之内,则本申请也意图包含这些改动和变型在内。Obviously, those skilled in the art can make various changes and modifications to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is also intended to include these modifications and variations.

Claims (27)

  1. 一种防误触的方法,其特征在于,电子设备包括超声波发射器和超声波接收器,所述方法包括:A method for preventing accidental touch, characterized in that the electronic device includes an ultrasonic transmitter and an ultrasonic receiver, and the method includes:
    所述超声波发射器发射N次超声波信号,每一次超声波信号包括多个超声波信号,N大于或等于2,N为正整数;The ultrasonic transmitter transmits N ultrasonic signals, each ultrasonic signal includes a plurality of ultrasonic signals, N is greater than or equal to 2, and N is a positive integer;
    所述超声波接收器接收N次超声波回波信号,其中,一次超声波回波信号由一次超声波信号经反射产生,所述每一次超声波回波信号包括多个超声波回波信号;The ultrasonic receiver receives N times of ultrasonic echo signals, wherein one ultrasonic echo signal is generated by the reflection of one ultrasonic signal, and each ultrasonic echo signal includes a plurality of ultrasonic echo signals;
    所述电子设备根据每一次接收到的超声波回波信号得到第一数据,所述第一数据包括所述多个超声波回波信号的信号强度、传播时间;The electronic device obtains first data according to each received ultrasonic echo signal, and the first data includes the signal strength and propagation time of the plurality of ultrasonic echo signals;
    所述电子设备根据所述N次超声波回波信号的所述第一数据,得到所述电子设备所处的第一场景类型;The electronic device obtains, according to the first data of the N ultrasonic echo signals, the first scene type in which the electronic device is located;
    如果所述第一场景类型为有遮挡场景,则所述电子设备开启防误触功能。If the first scene type is an occluded scene, the electronic device enables a false-touch prevention function.
  2. 如权利要求1所述的方法,其特征在于,所述超声波发射器和所述超声波接收器设置在所述电子设备的顶部,所述顶部还设置有所述电子设备的以下任意一项或多项:听筒、前置摄像头、麦克风、接近光传感器、环境光传感器。The method of claim 1, wherein the ultrasonic transmitter and the ultrasonic receiver are arranged on the top of the electronic device, and the top is further provided with any one or more of the following of the electronic device Items: Earpiece, Front Camera, Microphone, Proximity Light Sensor, Ambient Light Sensor.
  3. 如权利要求2所述的方法,其特征在于,所述超声波发射器集成在所述听筒中,或者,所述超声波发射器为所述听筒。The method of claim 2, wherein the ultrasonic transmitter is integrated in the earpiece, or the ultrasonic transmitter is the earpiece.
  4. 如权利要求2或3所述的方法,其特征在于,所述超声波接收器集成在所述麦克风中,或者,所述超声波接收器为所述麦克风。The method according to claim 2 or 3, wherein the ultrasonic receiver is integrated in the microphone, or the ultrasonic receiver is the microphone.
  5. 如权利要求1-4中任一项所述的方法,其特征在于,所述电子设备根据所述N次超声波回波信号的所述第一数据,得到所述电子设备所处的第一场景类型,具体包括:The method according to any one of claims 1-4, wherein the electronic device obtains the first scene where the electronic device is located according to the first data of the N times ultrasonic echo signals types, including:
    所述电子设备将所述N次超声波回波信号的所述第一数据输入到第一分类模型,得到所述电子设备所处的第一场景类型;所述第一分类模型是利用第一训练数据对第一训练模型进行训练得到的,所述第一训练数据包括S个样本数据,S大于或等于2,S为正整数;所述S个样本数据包括在多个已知场景类型下获得的样本数据,一个样本数据包括一个所述已知场景类型下发射N次超声波信号所产生的N次超声波回波信号的第二数据;所述第二数据包括所述多个超声波回波信号的信号强度、传播时间;所述已知多个场景类型包括:无遮挡场景、所述有遮挡场景。The electronic device inputs the first data of the N ultrasonic echo signals into a first classification model to obtain a first scene type in which the electronic device is located; the first classification model uses the first training The data is obtained by training the first training model, the first training data includes S sample data, S is greater than or equal to 2, and S is a positive integer; the S sample data includes obtained under multiple known scene types The sample data, one sample data includes a second data of N times ultrasonic echo signals generated by transmitting N times ultrasonic signals under the known scene type; the second data includes the plurality of ultrasonic echo signals. Signal strength, propagation time; the known multiple scene types include: the unobstructed scene and the blocked scene.
  6. 如权利要求5所述的方法,其特征在于,所述电子设备将所述N次超声波回波信号的所述第一数据输入到第一分类模型,得到所述电子设备所处的第一场景类型,具体包括:The method of claim 5, wherein the electronic device inputs the first data of the N times ultrasonic echo signals into a first classification model to obtain a first scene where the electronic device is located types, including:
    所述电子设备将所述N次超声波回波信号的所述第一数据生成第一图像,所述第一图像的色彩值表示超声波回波信号的信号强度,所述第一图像的横轴坐标表示超声波回波信 号的接收批次,所述第一图像的纵轴坐标表示从发射超声波信号到接收到超声波回波信号的传输时间;The electronic device generates a first image from the first data of the N ultrasonic echo signals, the color value of the first image represents the signal strength of the ultrasonic echo signal, and the abscissa coordinate of the first image Represents the receiving batch of ultrasonic echo signals, and the vertical axis of the first image represents the transmission time from transmitting ultrasonic signals to receiving ultrasonic echo signals;
    所述电子设备将所述第一图像输入到第一分类模型,得到所述电子设备所处的第一场景类型;The electronic device inputs the first image into a first classification model to obtain a first scene type where the electronic device is located;
    所述一个样本数据包括一个已知场景类型对应的第二图像,所述第二图像由所述N次超声波回波信号的第二数据生成,所述第二图像的色彩值表示在所述一个已知场景类型下接收超声波回波信号的信号强度,所述第二图像的横轴坐标表示在所述一个已知场景类型下接收的超声波回波信号的接受批次,所述第二图像的纵轴坐标表示在所述一个已知场景类型下发射超声波信号到接收到超声波回波信号的传输时间。The one sample data includes a second image corresponding to a known scene type, the second image is generated from the second data of the N times ultrasonic echo signals, and the color value of the second image is represented in the one. The signal strength of the received ultrasonic echo signals in a known scene type, the horizontal axis coordinate of the second image represents the acceptance batch of ultrasonic echo signals received in the one known scene type, the second image The coordinate of the vertical axis represents the transmission time from the transmission of the ultrasonic signal to the reception of the ultrasonic echo signal in the one known scene type.
  7. 如权利要求5或6所述的方法,其特征在于,所述第一训练模型为极端梯度提升XGBoost模型,或神经网络NN模型,或梯度提升决策树GBDT模型,或随机森林RF模型。The method according to claim 5 or 6, wherein the first training model is an extreme gradient boosting XGBoost model, or a neural network NN model, or a gradient boosting decision tree GBDT model, or a random forest RF model.
  8. 如权利要求1-7中任一项所述的方法,其特征在于,所述有遮挡场景包括以下任意一项或多项:所述电子设备位于口袋中、所述电子设备位于箱包中、所述电子设备被书本遮挡、所述电子设备被头发遮挡、所述电子设备被手掌遮挡、所述电子设备被衣物遮挡。The method according to any one of claims 1-7, wherein the occluded scene comprises any one or more of the following: the electronic device is located in a pocket, the electronic device is located in a bag, all The electronic device is blocked by a book, the electronic device is blocked by hair, the electronic device is blocked by the palm, and the electronic device is blocked by clothing.
  9. 如权利要求1-8中任一项所述的方法,其特征在于,所述防误触功能包括以下任意一项或多项:所述电子设备熄屏、所述电子设备不响应指纹解锁屏幕、所述电子设备不响应人脸识别解锁屏幕、所述电子设备不响应上滑解锁屏幕、所述电子设备不响应手势解锁屏幕、所述电子设备不响应抬手亮屏、所述电子设备不响应抬手接听来电、所述电子设备不响应指纹接听来电。The method according to any one of claims 1-8, wherein the anti-mistouch function comprises any one or more of the following: turning off the screen of the electronic device, unlocking the screen by the electronic device not responding to a fingerprint , The electronic device does not respond to face recognition to unlock the screen, the electronic device does not respond to sliding up to unlock the screen, the electronic device does not respond to gestures to unlock the screen, the electronic device does not respond to raising the hand to brighten the screen, the electronic device does not respond In response to raising the hand to answer the incoming call, the electronic device does not respond to the fingerprint to answer the incoming call.
  10. 如权利要求1-9任一项所述的方法,其特征在于,还包括:The method of any one of claims 1-9, further comprising:
    当检测到所述电子设备处于娱乐场景时,所述电子设备关闭所述防误触功能,所述娱乐场景包括以下任意一项或多项:所述电子设备播放视频、播放音乐、运行游戏。When it is detected that the electronic device is in an entertainment scene, the electronic device turns off the accidental touch prevention function, and the entertainment scene includes any one or more of the following: the electronic device plays a video, plays music, and runs a game.
  11. 如权利要求1-10任一项所述的方法,其特征在于,还包括:如果接近光传感器没有检测到物体遮挡,则所述电子设备不开启防误触功能。The method according to any one of claims 1-10, further comprising: if the proximity light sensor does not detect that the object is blocked, the electronic device does not enable the anti-mistouch function.
  12. 如权利要求1-11任一项所述的方法,其特征在于,还包括:如果环境光传感器检测到环境光亮度高于第一亮度值,则所述电子设备不开启防误触功能。The method according to any one of claims 1-11, further comprising: if the ambient light sensor detects that the brightness of the ambient light is higher than the first brightness value, the electronic device does not enable the anti-mistouch function.
  13. 如权利要求1-12任一项所述的方法,其特征在于,所述超声波发射器以发射周期T间隔发射所述N次超声波信号,所述一次超声波信号的持续发射时间t小于所述超声波信号的发射周期T。The method according to any one of claims 1-12, wherein the ultrasonic transmitter transmits the ultrasonic signals N times at intervals of a transmission period T, and the continuous emission time t of the ultrasonic signal is shorter than the ultrasonic wave The transmission period T of the signal.
  14. 一种电子设备,其特征在于,包括超声波发射器、超声波接收器、显示屏、存储器以及耦合于所述存储器的处理器,所述存储器中存储有数据和可执行指令,其中:An electronic device, characterized in that it includes an ultrasonic transmitter, an ultrasonic receiver, a display screen, a memory, and a processor coupled to the memory, wherein the memory stores data and executable instructions, wherein:
    所述处理器通过所述超声波发射器发射N次超声波信号,每一次超声波信号包括多个超声波信号,N大于或等于2,N为正整数;The processor transmits N ultrasonic signals through the ultrasonic transmitter, each ultrasonic signal includes a plurality of ultrasonic signals, N is greater than or equal to 2, and N is a positive integer;
    所述处理器通过所述超声波接收器接收N次超声波回波信号,其中,一次超声波回波信号由一次超声波信号经反射产生,所述每一次超声波回波信号包括多个超声波回波信号;The processor receives N times of ultrasonic echo signals through the ultrasonic receiver, wherein one ultrasonic echo signal is generated by the reflection of one ultrasonic signal, and each ultrasonic echo signal includes a plurality of ultrasonic echo signals;
    所述处理器根据每一次接收到的超声波回波信号得到第一数据,所述第一数据包括所述多个超声波回波信号的信号强度、传播时间;The processor obtains first data according to each received ultrasonic echo signal, and the first data includes the signal strength and propagation time of the plurality of ultrasonic echo signals;
    所述处理器根据所述N次超声波回波信号的所述第一数据,得到所述电子设备所处的第一场景类型;obtaining, by the processor, a first scene type in which the electronic device is located according to the first data of the N ultrasonic echo signals;
    如果所述第一场景类型为有遮挡场景,则所述处理器控制所述显示屏开启防误触功能。If the first scene type is an occluded scene, the processor controls the display screen to enable an anti-mistouch function.
  15. 如权利要求14所述的电子设备,其特征在于,所述超声波发射器和所述超声波接收器设置在所述电子设备的顶部,所述顶部还设置有所述电子设备的以下任意一项或多项:听筒、前置摄像头、麦克风、接近光传感器、环境光传感器。The electronic device according to claim 14, wherein the ultrasonic transmitter and the ultrasonic receiver are arranged on the top of the electronic device, and the top is further provided with any one of the following or the electronic device. Multiple: earpiece, front camera, microphone, proximity light sensor, ambient light sensor.
  16. 如权利要求15所述的电子设备,其特征在于,所述超声波发射器集成在所述听筒中,或者,所述超声波发射器为所述听筒。The electronic device according to claim 15, wherein the ultrasonic transmitter is integrated in the earpiece, or the ultrasonic transmitter is the earpiece.
  17. 如权利要求14或15所述的电子设备,其特征在于,所述超声波接收器集成在所述麦克风中,或者,所述超声波接收器为所述麦克风。The electronic device according to claim 14 or 15, wherein the ultrasonic receiver is integrated in the microphone, or the ultrasonic receiver is the microphone.
  18. 如权利要求14-17中任一项所述的电子设备,其特征在于,所述处理器根据所述N次超声波回波信号的所述第一数据,得到所述电子设备所处的第一场景类型,具体包括:The electronic device according to any one of claims 14-17, wherein the processor obtains, according to the first data of the N times ultrasonic echo signals, the first location where the electronic device is located Scenario types, including:
    所述处理器将所述N次超声波回波信号的所述第一数据输入到第一分类模型,得到所述电子设备所处的第一场景类型;所述第一分类模型是利用第一训练数据对第一训练模型进行训练得到的,所述第一训练数据包括S个样本数据,S大于或等于2,S为正整数;所述S个样本数据包括在多个已知场景类型下获得的样本数据,一个样本数据包括一个所述已知场景类型下发射N次超声波信号所产生的N次超声波回波信号的第二数据;所述第二数据包括所述多个超声波回波信号的信号强度、传播时间;所述已知多个场景类型包括:无遮挡场景、所述有遮挡场景。The processor inputs the first data of the N ultrasonic echo signals into a first classification model to obtain a first scene type in which the electronic device is located; the first classification model uses the first training The data is obtained by training the first training model, the first training data includes S sample data, S is greater than or equal to 2, and S is a positive integer; the S sample data includes obtained under multiple known scene types The sample data, one sample data includes a second data of N times ultrasonic echo signals generated by transmitting N times ultrasonic signals under the known scene type; the second data includes the plurality of ultrasonic echo signals. Signal strength, propagation time; the known multiple scene types include: the unobstructed scene and the blocked scene.
  19. 如权利要求18所述的电子设备,其特征在于,所述处理器将所述N次超声波回波信号的所述第一数据输入到第一分类模型,得到所述电子设备所处的第一场景类型,具体包括:The electronic device according to claim 18, wherein the processor inputs the first data of the N times ultrasonic echo signals into a first classification model, and obtains a first classification model where the electronic device is located. Scenario types, including:
    所述处理器将所述N次超声波回波信号的所述第一数据生成第一图像,所述第一图像的色彩值表示超声波回波信号的信号强度,所述第一图像的横轴坐标表示超声波回波信号的接收批次,所述第一图像的纵轴坐标表示从发射超声波信号到接收到超声波回波信号的 传输时间;The processor generates a first image from the first data of the N times ultrasonic echo signals, the color value of the first image represents the signal strength of the ultrasonic echo signal, and the abscissa coordinate of the first image Represents the receiving batch of ultrasonic echo signals, and the vertical axis of the first image represents the transmission time from transmitting ultrasonic signals to receiving ultrasonic echo signals;
    所述处理器将所述第一图像输入到第一分类模型,得到所述电子设备所处的第一场景类型;The processor inputs the first image into a first classification model to obtain a first scene type where the electronic device is located;
    所述一个样本数据包括一个已知场景类型对应的第二图像,所述第二图像由所述N次超声波回波信号的第二数据生成,所述第二图像的色彩值表示在所述一个已知场景类型下接收超声波回波信号的信号强度,所述第二图像的横轴坐标表示在所述一个已知场景类型下接收的超声波回波信号的接受批次,所述第二图像的纵轴坐标表示在所述一个已知场景类型下发射超声波信号到接收到超声波回波信号的传输时间。The one sample data includes a second image corresponding to a known scene type, the second image is generated from the second data of the N times ultrasonic echo signals, and the color value of the second image is represented in the one. The signal strength of the received ultrasonic echo signals in a known scene type, the horizontal axis coordinate of the second image represents the acceptance batch of ultrasonic echo signals received in the one known scene type, the second image The coordinate of the vertical axis represents the transmission time from the transmission of the ultrasonic signal to the reception of the ultrasonic echo signal in the one known scene type.
  20. 如权利要求18或19所述的电子设备,其特征在于,所述第一训练模型为极端梯度提升XGBoost模型,或神经网络NN模型,或梯度提升决策树GBDT模型,或随机森林RF模型。The electronic device according to claim 18 or 19, wherein the first training model is an extreme gradient boosting XGBoost model, or a neural network NN model, or a gradient boosting decision tree GBDT model, or a random forest RF model.
  21. 如权利要求14-20中任一项所述的电子设备,其特征在于,所述有遮挡场景包括以下任意一项或多项:所述电子设备位于口袋中、所述电子设备位于箱包中、所述电子设备被书本遮挡、所述电子设备被头发遮挡、所述电子设备被手掌遮挡、所述电子设备被衣物遮挡。The electronic device according to any one of claims 14-20, wherein the occluded scene includes any one or more of the following: the electronic device is located in a pocket, the electronic device is located in a bag, The electronic device is blocked by a book, the electronic device is blocked by hair, the electronic device is blocked by a palm, and the electronic device is blocked by clothing.
  22. 如权利要求14-21中任一项所述的电子设备,其特征在于,所述防误触功能包括以下任意一项或多项:所述电子设备熄屏、所述电子设备不响应指纹解锁屏幕、所述电子设备不响应人脸识别解锁屏幕、所述电子设备不响应上滑解锁屏幕、所述电子设备不响应手势解锁屏幕、所述电子设备不响应抬手亮屏、所述电子设备不响应抬手接听来电、所述电子设备不响应指纹接听来电。The electronic device according to any one of claims 14-21, wherein the anti-mistouch function includes any one or more of the following: the electronic device turns off the screen, the electronic device does not respond to fingerprint unlocking screen, the electronic device does not respond to face recognition to unlock the screen, the electronic device does not respond to sliding up to unlock the screen, the electronic device does not respond to gestures to unlock the screen, the electronic device does not respond to raising the hand to brighten the screen, the electronic device The electronic device does not respond to raising the hand to answer the incoming call, and the electronic device does not respond to the fingerprint to answer the incoming call.
  23. 如权利要求14-22任一项所述的电子设备,其特征在于,还包括:The electronic device according to any one of claims 14-22, further comprising:
    当检测到处于娱乐场景时,所述处理器关闭所述防误触功能,所述娱乐场景包括以下任意一项或多项:播放视频、播放音乐、运行游戏。When it is detected that it is in an entertainment scene, the processor turns off the accidental touch prevention function, and the entertainment scene includes any one or more of the following: playing a video, playing music, and running a game.
  24. 如权利要求14-23任一项所述的电子设备,其特征在于,还包括:如果接近光传感器没有检测到物体遮挡,则所述处理器不开启防误触功能。The electronic device according to any one of claims 14 to 23, further comprising: if the proximity light sensor does not detect that an object is blocked, the processor does not enable a false touch prevention function.
  25. 如权利要求14-24任一项所述的电子设备,其特征在于,还包括:如果环境光传感器检测到环境光亮度高于第一亮度值,则所述处理器不开启防误触功能。The electronic device according to any one of claims 14-24, further comprising: if the ambient light sensor detects that the brightness of the ambient light is higher than the first brightness value, the processor does not enable the anti-mistouch function.
  26. 如权利要求14-25任一项所述的电子设备,其特征在于,所述超声波发射器以发射周期T间隔发射所述N次超声波信号,所述一次超声波信号的持续发射时间t小于所述超声波信号的发射周期T。The electronic device according to any one of claims 14 to 25, wherein the ultrasonic transmitter transmits the ultrasonic signals N times at intervals of a transmission period T, and the continuous transmission time t of the ultrasonic signal is shorter than the The transmission period T of the ultrasonic signal.
  27. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质中存储有计算机程序,所述计算机程序在电子设备上运行时,使得所述电子设备执行如权利要求1至13中任一项所述的方法。A computer-readable storage medium, characterized in that a computer program is stored in the computer-readable storage medium, and when the computer program is executed on an electronic device, the electronic device executes any one of claims 1 to 13. one of the methods described.
PCT/CN2021/109122 2020-07-31 2021-07-29 Method for preventing inadvertent touch and electronic device WO2022022609A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010762072.5 2020-07-31
CN202010762072.5A CN114070928B (en) 2020-07-31 2020-07-31 Method for preventing false touch and electronic equipment

Publications (1)

Publication Number Publication Date
WO2022022609A1 true WO2022022609A1 (en) 2022-02-03

Family

ID=80037230

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/109122 WO2022022609A1 (en) 2020-07-31 2021-07-29 Method for preventing inadvertent touch and electronic device

Country Status (2)

Country Link
CN (1) CN114070928B (en)
WO (1) WO2022022609A1 (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115236072A (en) * 2022-06-14 2022-10-25 杰能科世智能安全科技(杭州)有限公司 Lifting column state detection method and device
CN115314590A (en) * 2022-06-21 2022-11-08 华为技术有限公司 Proximity event determination method and electronic device
CN116661670A (en) * 2022-11-18 2023-08-29 荣耀终端有限公司 Method for managing gesture navigation window, electronic device and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103327148A (en) * 2013-06-28 2013-09-25 惠州Tcl移动通信有限公司 Screen backlight brightness adjusting implementation method based on mobile terminal and mobile terminal
US20170004806A1 (en) * 2015-07-01 2017-01-05 Thomas Joseph Edwards Method and apparatus to enable smartphones and computer tablet devices to communicate with interactive devices
CN106413060A (en) * 2016-10-24 2017-02-15 北京小米移动软件有限公司 Screen state control method and device
CN107943267A (en) * 2017-11-21 2018-04-20 北京小米移动软件有限公司 A kind of method and apparatus for controlling screen
CN111323783A (en) * 2020-02-27 2020-06-23 Oppo广东移动通信有限公司 Scene recognition method and device, storage medium and electronic equipment

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10311570B1 (en) * 2018-12-07 2019-06-04 Sonavista, Inc. Medical image based distortion correction mechanism
CN110300230B (en) * 2019-07-01 2021-03-19 腾讯科技(深圳)有限公司 Application control method, device, storage medium and terminal
CN111191616A (en) * 2020-01-02 2020-05-22 广州织点智能科技有限公司 Face shielding detection method, device, equipment and storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103327148A (en) * 2013-06-28 2013-09-25 惠州Tcl移动通信有限公司 Screen backlight brightness adjusting implementation method based on mobile terminal and mobile terminal
US20170004806A1 (en) * 2015-07-01 2017-01-05 Thomas Joseph Edwards Method and apparatus to enable smartphones and computer tablet devices to communicate with interactive devices
CN106413060A (en) * 2016-10-24 2017-02-15 北京小米移动软件有限公司 Screen state control method and device
CN107943267A (en) * 2017-11-21 2018-04-20 北京小米移动软件有限公司 A kind of method and apparatus for controlling screen
CN111323783A (en) * 2020-02-27 2020-06-23 Oppo广东移动通信有限公司 Scene recognition method and device, storage medium and electronic equipment

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115236072A (en) * 2022-06-14 2022-10-25 杰能科世智能安全科技(杭州)有限公司 Lifting column state detection method and device
CN115314590A (en) * 2022-06-21 2022-11-08 华为技术有限公司 Proximity event determination method and electronic device
CN116661670A (en) * 2022-11-18 2023-08-29 荣耀终端有限公司 Method for managing gesture navigation window, electronic device and storage medium
CN116661670B (en) * 2022-11-18 2024-03-08 荣耀终端有限公司 Method for managing gesture navigation window, electronic device and storage medium

Also Published As

Publication number Publication date
CN114070928B (en) 2022-10-18
CN114070928A (en) 2022-02-18

Similar Documents

Publication Publication Date Title
CN113645351B (en) Application interface interaction method, electronic device and computer-readable storage medium
CN110114747B (en) Notification processing method and electronic equipment
WO2021000807A1 (en) Processing method and apparatus for waiting scenario in application
WO2021036770A1 (en) Split-screen processing method and terminal device
WO2022022609A1 (en) Method for preventing inadvertent touch and electronic device
CN111543042A (en) Notification message processing method and electronic equipment
WO2022037726A1 (en) Split-screen display method and electronic device
EP4033339A1 (en) User interface display method and electronic device
EP3958106A1 (en) Interface display method and electronic device
WO2021008589A1 (en) Application running mehod and electronic device
CN113452945A (en) Method and device for sharing application interface, electronic equipment and readable storage medium
JP2023500656A (en) DISPLAY METHOD AND ELECTRONIC DEVICE
EP4184321A1 (en) Method for interaction between devices based on pointing operation, and electronic device
WO2021238740A1 (en) Screen capture method and electronic device
CN110058729B (en) Method and electronic device for adjusting sensitivity of touch detection
CN115032640B (en) Gesture recognition method and terminal equipment
CN114995715B (en) Control method of floating ball and related device
WO2022166435A1 (en) Picture sharing method and electronic device
WO2022078116A1 (en) Brush effect picture generation method, image editing method and device, and storage medium
WO2023061054A1 (en) Non-contact gesture control method and electronic device
WO2021129453A1 (en) Screenshot method and related device
WO2022042774A1 (en) Profile picture display method and electronic device
WO2022222702A1 (en) Screen unlocking method and electronic device
EP4310645A1 (en) Method and apparatus for enabling function in application
EP4250078A1 (en) Window page interaction method and apparatus, electronic device, and readable storage medium

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21849138

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21849138

Country of ref document: EP

Kind code of ref document: A1