A message processing method, electronic device and readable storage medium
By identifying the user's eye movement data to interact, the interaction inconvenience problem that requires touch control in the prior art is solved, and convenient human-computer interaction without contact is achieved.
Patent Information
- Application Number
- CN202310212372.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-02-27
- Publication Date
- 2025-03-21
- Estimated Expiration
- 2043-02-27
AI Technical Summary
When existing electronic devices process notification messages, users need to interact through touch control, resulting in inconvenience in interaction when the device cannot be touched.
By identifying the user's eye movements, the user's gaze coordinates and gaze duration are determined, the notification message of interest to the user is determined based on these data, and the interaction operation corresponding to the eye movement recognition data is performed to achieve contactless human-computer interaction.
It improves the convenience of human-computer interaction, allowing users to interact with electronic devices without touching the device, and is suitable for situations where the device cannot be touched.
Smart Images

Figure CN118550400B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of intelligent interaction technology, and in particular to a message processing method, an electronic device, and a readable storage medium. Background Art
[0002] When an electronic device receives a notification message, the electronic device will display it in an area designated for displaying the notification message, such as a drop-down notification bar on a mobile phone lock screen or a main interface.
[0003] When the content of the notification message is too much, the electronic device will display the beginning part of the notification message in the designated area. After that, the electronic device detects that the user clicks on the notification message, and then displays the complete message content. Alternatively, when the user is watching a short video or reading a news page, he needs to slide the electronic device to turn the page. The above process of user interaction with the electronic device needs to be implemented through touch control. In the case where some users cannot touch the electronic device, the interactive operation of touch control brings inconvenience to people. Summary of the invention
[0004] In view of this, the present application provides a message processing method, an electronic device and a readable storage medium, which can determine the user's gaze point coordinates and gaze duration by identifying the user's eye movements, and determine the notification message that the user is interested in based on the gaze point coordinates and gaze duration, and perform interaction on the notification message corresponding to the eye movement recognition data, so that the user can interact with the electronic device without contact, thereby improving the convenience of human-computer interaction.
[0005] In the first aspect, the message processing method provided by the present application is applied to an electronic device. A first interface is displayed in the electronic device, and the first interface includes a notification message. Afterwards, the electronic device collects first image data through a target image sensor, and the first image data includes an eye image of the user. The electronic device can determine the user's first eye movement data based on the user's first image data, and the first eye movement data includes first gaze point coordinates and first gaze duration. When the user gazes at the notification message in the first interface, the first gaze point coordinates determined by the electronic device are located in the display area of the notification message, and the first gaze duration is greater than the first preset duration threshold. At this time, it indicates that the user is interested in viewing the notification message, so the electronic device can display a second interface, and the second interface is the display interface of the application corresponding to the notification message.
[0006] In the above message processing method, the electronic device can determine the coordinates of the user's gaze point and gaze duration in the display screen by collecting and identifying the user's eye image. Afterwards, the electronic device can determine whether the user wants to operate the notification message in the display interface based on the user's gaze point and gaze duration, thereby realizing the interactive operation of the notification message based on the user's eye movement. In this way, the user can perform a more convenient contactless human-computer interaction process on the electronic device through eye movement.
[0007] In a possible implementation of the first aspect, the process of an electronic device displaying a first interface is as follows: first, a third interface is displayed. The third interface includes a long notification message in a folded state, and the number of characters in the long notification message is greater than a preset character threshold. Next, second image data is collected through a target image sensor, and the second image data includes an eye image of the user. Afterwards, the second eye movement data of the user is determined based on the second image data of the user; the second eye movement data includes second gaze point coordinates and second gaze duration, and finally, in response to the second gaze point coordinates being located in the display area of the long notification message, and the second gaze duration being greater than the second preset duration threshold, the first interface is displayed, and the first interface includes a long notification message in an expanded state.
[0008] In the above-mentioned message processing method, the long notification message is folded and displayed in the third interface to ensure effective information display in a limited interface and avoid the lengthy content in the long notification message being displayed in the third interface, thereby improving the display effect. By collecting the second image data, the electronic device can determine the user's intention to view the long notification message. If the user stares at the folded long notification message for a long time, it can be determined that the user wants to view the long notification message. Therefore, the electronic device can display the first interface when the coordinates of the second gaze point are located in the display area of the long notification message and the second gaze duration is greater than the second preset duration threshold. The first interface includes the long notification message in the expanded state.
[0009] In a possible implementation of the first aspect, after the electronic device displays the first interface, the third image data may be collected through the target image sensor, and the third image data includes the user's eye image. Afterwards, the electronic device determines the user's third eye movement data based on the user's third image data, and the third eye movement data includes the third gaze point coordinates and the third gaze duration. Finally, in response to the third gaze point coordinates being outside the display area of the long notification message on the first interface, the electronic device displays a fourth interface, and the fourth interface includes the long notification message in a folded state, or the fourth interface does not include the long notification message.
[0010] In the above message processing method, after displaying the first interface, the electronic device can determine the user's reading interest in the notification message through the third gaze point coordinates and the third gaze duration determined by the third image data. If the third gaze point coordinates are outside the display area of the long notification message on the first interface, it can be said that the user is no longer interested in continuing to read the notification message, and the electronic device can continue to display the long notification message in a folded state in the fourth interface. Alternatively, the electronic device can also remove the long notification message from the displayed fourth interface.
[0011] In a possible implementation of the first aspect, in response to the first gaze point coordinates being outside the display area of the notification message, the electronic device may further display a fifth interface after a first preset time period, and the fifth interface does not include the notification message.
[0012] When the coordinates of the first gaze point are detected to be outside the display area of the notification message, the electronic device can determine that the user no longer intends to read the notification message in the first display interface. At this time, the electronic device can display the fifth interface that does not include the notification message, so as to achieve the purpose of not repeatedly displaying the read message.
[0013] In a possible implementation of the first aspect, the electronic device includes a time-of-flight TOF image sensor and an RGB image sensor. Accordingly, the electronic device may first obtain the current ambient light brightness, and in response to the current ambient light brightness being greater than a first preset brightness threshold, control the RGB image sensor to collect first RGB image data; in response to the current ambient light brightness being less than or equal to the first preset brightness threshold, control the TOF image sensor to collect first TOF image data. The image data collected by the TOF image sensor in dim light is more accurate, while the image data collected by the RGB image sensor in bright light is more accurate. Therefore, the electronic device may select a suitable target image sensor according to the current ambient light brightness, so that the first image data may be accurately collected by the target image sensor.
[0014] In a possible implementation of the first aspect, in response to the current ambient light brightness being greater than a first preset brightness threshold, after controlling the RGB image sensor to collect first RGB image data, the electronic device may also determine whether the user's eyes are covered by a reflective object, and switch the working states of the RGB image data and the TOF image sensor according to the determination result. If it is determined based on the first RGB image data that the user's eyes are not covered by a reflective object, the RGB image sensor is controlled to be turned off, and the TOF image sensor is controlled to be turned on to collect the first image data, thereby ensuring the accuracy of the image data collected by the image sensor.
[0015] In a possible implementation of the first aspect, the electronic device includes a time-of-flight TOF image sensor and an RGB image sensor. The electronic device may first control the RGB image sensor to collect first RGB image data and the TOF image sensor to collect first TOF image data, and if it is determined based on the first RGB image data and / or the first TOF image data that the user's eyes are covered with reflective objects, the current ambient light brightness is obtained. Afterwards, in response to the current ambient light brightness being greater than a first preset brightness threshold, the electronic device may control the TOF image sensor to turn off, so as to accurately collect the first image data through the target image sensor.
[0016] In a possible implementation of the first aspect, the electronic device may also determine an eye movement calibration result to ensure accurate recognition of eye movement based on the eye movement calibration result. Specifically, the electronic device displays a sixth interface, and the sixth interface includes at least one calibration position. The electronic device collects fourth image data through a target image sensor, and determines the coordinates of a fourth gaze point of the user based on the fourth image data. Thereafter, based on the coordinates of the calibration position and the error between the coordinates of the fourth gaze point, the electronic device may determine the eye movement calibration result.
[0017] In a possible implementation of the first aspect, the electronic device includes a time-of-flight TOF image sensor and an RGB image sensor. In the process of obtaining the eye movement calibration result, the electronic device can control the TOF image sensor to collect the second TOF image data, and control the RGB image sensor to collect the second RGB image data. By jointly collecting image data with two image sensors, the accuracy of the eye movement calibration result can be ensured and errors can be avoided.
[0018] In a possible implementation of the first aspect, in the process of obtaining the eye movement calibration result, the electronic device may connect the TOF image sensor and the RGB image sensor via a connecting line to ensure that the TOF image sensor and the RGB image sensor can synchronously collect data and improve the accuracy of the eye movement calibration result. The connecting line is used to transmit a synchronization signal so that the TOF image sensor and the RGB image sensor synchronously collect image data based on the synchronization signal.
[0019] In a possible implementation of the first aspect, the electronic device includes a hardware abstraction HAL layer and a hardware layer; the HAL layer includes a smart perception control module and a smart perception TA, the hardware layer includes a secure memory, the secure memory is used to store image data collected by the target image sensor; the smart perception TA runs in a trusted execution environment. The electronic device determines the user's first eye movement data based on the user's first image data, including: the smart perception control module obtains a file descriptor, the file descriptor is used to describe the storage location of the first image data in the electronic device; the smart perception TA obtains the first image data from the secure memory according to the file descriptor; the smart perception TA encrypts the first image data and sends the encrypted first image data to the smart perception control module; the smart perception control module decrypts the encrypted first image data and determines the first eye movement data according to the first image data. In order to ensure the security of the image data during transmission, the smart perception TA encrypts the image and then sends it to the smart perception control module. Or the smart perception TA determines the first eye movement data according to the first image data, and sends the first eye movement data to the smart perception control module. The determination of the eye movement data by the smart perception TA running in the trusted execution environment can also prevent the image data from being destroyed during transmission.
[0020] In another possible implementation of the first aspect, the electronic device further includes a kernel layer; the HAL layer further includes a camera hardware abstraction layer HAL, the camera HAL includes a sensor node, the kernel layer further includes a camera driver, the hardware layer further includes at least one image sensor and a corresponding register, and the at least one image sensor is set in one or more cameras. When the electronic device collects the first image data through the target image sensor, it can go through the following process: first, the sensor node obtains the identification and configuration parameters of the target image sensor to be controlled; the sensor node sends the identification and configuration parameters of the target image sensor to the camera driver; the camera driver configures the configuration data of the target image sensor in the register of the target image sensor according to the identification of the target image sensor; the camera driver sends a message of data configuration completion to the sensor node; the sensor node sends a first start command to the camera driver according to the message of data configuration completion; the camera driver sends a second start command to the target image sensor; the target image sensor obtains the configuration parameters of the target image sensor from the register according to the second start command, and collects image data based on the configuration parameters.
[0021] In the above method, the sensor node can obtain the identification and configuration parameters of the target image sensor based on the request sent by the intelligent perception control module. After that, the electronic device can configure and start the target image sensor according to the identification and configuration parameters of the target image sensor, thereby ensuring that the corresponding target image sensor can collect image data.
[0022] In a possible implementation of the first aspect, the electronic device also includes an application layer and a framework layer; the application layer includes a system user interface UI, and the framework layer includes the smart perception service. After displaying the first interface, the electronic device can create a path to the image sensor in the following method: First, the system UI sends a smart perception registration request to the smart perception service; the smart perception registration request is used to start eye movement recognition or eye movement calibration process. Afterwards, the smart perception service sends a smart perception process call request to the smart perception control module based on the smart perception registration request; the smart perception process call request includes the identification and configuration parameters of the target image sensor. Finally, the smart perception control module creates a path to the target image sensor based on the identification and configuration parameters of the target image sensor.
[0023] In a possible implementation of the first aspect, the framework layer also includes a camera service. The electronic device creates a path for the target image sensor, and can first control the camera service to receive a path creation request for the target image sensor sent by the smart perception control module; the path creation request includes the identifier and configuration parameters of the target image sensor; the camera service sends the identifier and configuration parameters of the target image sensor to the camera HAL; the camera HAL creates the path of the target image sensor based on the identifier of the target image sensor; the camera HAL returns a result of successful path creation of the target image sensor to the camera service; the camera service returns the path creation result of the target image sensor to the smart perception control module based on the received result of successful path creation of the target image sensor. The smart perception control module first sends a path creation request to the camera service, so that the camera service can send the identifier and configuration parameters of the target image sensor included in the path creation request to the camera HAL to achieve the creation of the path of the target image sensor.
[0024] In a possible implementation of the first aspect, the intelligent perception control module obtains a file descriptor, including: the intelligent perception control module sends a data request to the camera service, where the data request is used to obtain a file descriptor; the camera service calls the camera HAL to obtain the file descriptor according to the data request; and the camera service sends the file descriptor to the intelligent perception control module.
[0025] In a second aspect, the present application provides an electronic device, which includes a display screen, a camera, a memory and one or more processors; the display screen, the camera, the memory and the processor are coupled; the camera includes a time-of-flight TOF image sensor and an RGB image sensor; the display screen is used to display an image generated by the processor, the camera is used to capture images, and the memory is used to store computer program codes, and the computer program codes include computer instructions; when the processor executes the computer instructions, the electronic device executes the method as in the first aspect and any possible design method thereof.
[0026] In a third aspect, the present application provides a readable storage medium, including computer instructions. When the computer instructions are executed on an electronic device, the electronic device executes the method as described in the first aspect and any possible design thereof.
[0027] In a fourth aspect, the present application provides a computer program product. When the computer program product is run on an electronic device, the electronic device executes the method as described in the first aspect and any possible design thereof.
[0028] It can be understood that the method of the first aspect, the electronic device of the second aspect, the readable storage medium of the third aspect, and the computer program product of the fourth aspect provided above are all used to execute the corresponding methods provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding methods provided above, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0029] Figure 1 A one-handed operation schematic diagram provided for an embodiment of the present application;
[0030] Figure 2 A schematic diagram of an electronic device provided in an embodiment of the present application;
[0031] Figure 3 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application;
[0032] Figure 4 A software structure block diagram of an electronic device provided in an embodiment of the present application;
[0033] Figure 5 A schematic diagram of interaction between software modules provided in an embodiment of the present application;
[0034] Figure 6 A display schematic diagram provided for an embodiment of the present application;
[0035] Figure 7 Another display schematic diagram provided for an embodiment of the present application;
[0036] Figure 8A schematic diagram of an eye movement interaction setting interface provided in an embodiment of the present application;
[0037] Fig. 9 A signal interaction diagram of an eye movement calibration provided in an embodiment of the present application;
[0038] Fig.10 A schematic diagram of eye movement interaction provided in an embodiment of the present application;
[0039] Fig.11 A schematic diagram of another eye movement interaction provided in an embodiment of the present application;
[0040] Fig.12 A schematic diagram of another eye movement interaction provided in an embodiment of the present application;
[0041] Fig.13 A signal interaction diagram for eye movement recognition provided by an embodiment of the present application;
[0042] Fig.14 A schematic diagram of another eye movement interaction provided in an embodiment of the present application;
[0043] Fig.15 Another display schematic diagram provided for an embodiment of the present application;
[0044] Fig.16 A schematic diagram of a lock screen interface provided in an embodiment of the present application;
[0045] Fig.17 A flowchart of a message processing method provided in an embodiment of the present application;
[0046] Fig.18 A schematic diagram of eye movement interaction provided in an embodiment of the present application;
[0047] Fig.19 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0048] In the following, the terms "first" and "second" are used for descriptive purposes only and are not to be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features. In the description of this embodiment, unless otherwise specified, "plurality" means two or more.
[0049] In order to make the following embodiments clear and concise, a brief introduction to related concepts or technologies is first given:
[0050] Rich execution environment (REE), also known as rich execution environment, common execution environment, untrusted execution environment, etc., refers to the system operating environment of the mobile terminal, in which can run, for example, REE has good openness and scalability.
[0051] Trusted execution environment (TEE), also known as the security side or security zone, is an area that requires authorization to access. TEE refers to an independent security area established inside the processor through hardware resource isolation. TEE and REE coexist in the operating environment of electronic devices, but TEE and REE are completely isolated in hardware. TEE has its own operating space and strict protection measures. Therefore, it has a higher security level than REE, and REE cannot access the relevant resources of TEE, so that TEE has the security ability to protect the internal code and information of TEE, and can resist attacks on the REE side and resist security threats.
[0052] REE+TEE architecture refers to an architecture that provides services for applications through the combination of TEE and REE. In other words, TEE and REE exist together in electronic devices. For example, TEE can implement an operating mechanism isolated from REE through hardware support. TEE has its own operating space, with a higher security level than REE, and can protect assets in TEE (such as data, software, etc.) from software attacks. Only authorized security software can be executed in TEE, and it also protects the confidentiality of the resources and data of the security software. Compared with REE, TEE can better protect the security of data and resources due to its protection mechanisms such as isolation and permission control.
[0053] A trusted application (TA) is an application running in TEE that can provide security services to client applications (CA) running in REE, such as key generation and key management, security authentication, intelligent perception and other security tasks.
[0054] CA usually refers to an application running in REE, which can call TA through the client application programming interface (API) and instruct TA to perform corresponding security operations.
[0055] When users use electronic devices such as mobile phones, tablet computers, and televisions, they often need to interact with the electronic devices to control them. Users can interact with electronic devices through physical buttons, such as pressing physical buttons on a mobile phone, pressing a keyboard connected to a computer, etc. Users can also interact with electronic devices through touch, such as using a mobile phone to touch, click, or slide the touch screen of the mobile phone. However, these interaction methods all require the user to touch the electronic device in order to interact. If the user cannot touch the electronic device, then the user cannot interact with the electronic device. In addition, when a user operates an electronic device with one hand, for example, Figure 1 As shown, after the user holds a mobile phone of a certain size in one hand, the user can only touch area a in the touch screen with the thumb or finger, and cannot click, slide, or perform other operations on area b.
[0056] To this end, the present application provides a message processing method, where the electronic device can determine the coordinates of the user's gaze point and gaze duration in the display screen by collecting and identifying the user's eye image. Afterwards, the electronic device can determine whether the user wants to operate the notification message in the display interface based on the user's gaze point and gaze duration, thereby realizing the interactive operation of the notification message based on the user's eye movement. In this way, the user can perform a more convenient contactless human-computer interaction process on the electronic device through eye movement.
[0057] The message processing method provided in the embodiment of the present application can be applied to the electronic device 100. For example, Figure 2 As shown, the electronic device 100 can be a mobile phone 21, a tablet computer 22, a smart screen 23, a laptop computer 24, a vehicle-mounted device, a wearable device (such as a smart watch), an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (PDA), an artificial intelligence device, and other terminal devices with display functions. The operating system installed in the electronic device 100 includes but is not limited to Or other operating systems. This application does not limit the specific type of the electronic device 100 or the installed operating system.
[0058] Figure 31 shows a schematic diagram of the structure of the electronic device 100. The electronic device 100 may include a processor 310, an external memory interface 320, an internal memory 321, a universal serial bus (USB) interface 330, a charging management module 340, a power management module 341, a battery 342, an antenna 1, an antenna 2, a mobile communication module 350, a wireless communication module 360, an audio module 370, a speaker 370A, a receiver 370B, a microphone 370C, an earphone interface 370D, a sensor module 380, a button 390, a motor 391, an indicator 392, a camera 393, a display screen 394, and a subscriber identification module (SIM) card interface 395.
[0059] It is to be understood that the structure illustrated in the embodiment of the present invention does not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may include more or fewer components than shown in the figure, or combine some components, or separate some components, or arrange the components differently. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.
[0060] The processor 310 may include one or more processing units, for example, the processor 310 may include an application processor (AP), a modem processor, a graphics processor (GPU), an image signal processor (ISP), a controller, a memory, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors.
[0061] The controller may be the nerve center and command center of the electronic device 100. The controller may generate an operation control signal according to the instruction operation code and the timing signal to complete the control of fetching and executing instructions.
[0062] The processor 310 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in the processor 310 is a cache memory. The memory may store instructions or data that the processor 310 has just used or cyclically used. If the processor 310 needs to use the instruction or data again, it may be directly called from the memory. This avoids repeated access, reduces the waiting time of the processor 310, and thus improves the efficiency of the system.
[0063] In some embodiments, the processor 310 may include one or more interfaces. The interface may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.
[0064] The I2C interface is a bidirectional synchronous serial bus, including a serial data line (SDA) and a serial clock line (SCL). In some embodiments, the processor 310 may include multiple groups of I2C buses. The processor 310 may be coupled to the touch sensor 380K, the charger, the flash, the camera 393, etc. through different I2C bus interfaces. For example: the processor 310 may be coupled to the touch sensor 380K through the I2C interface, so that the processor 310 communicates with the touch sensor 380K through the I2C bus interface to realize the touch function of the electronic device 100.
[0065] The MIPI interface can be used to connect the processor 310 with peripheral devices such as the display screen 394 and the camera 393. The MIPI interface includes a camera serial interface (CSI), a display serial interface (DSI), etc. In some embodiments, the processor 310 and the camera 393 communicate via the CSI interface to realize the shooting function of the electronic device 100. The processor 310 and the display screen 394 communicate via the DSI interface to realize the display function of the electronic device 100.
[0066] 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 can be used to connect the processor 310 with the camera 393, the display screen 394, the wireless communication module 360, the audio module 370, the sensor module 380, etc. The GPIO interface can also be configured as an I2C interface, an I2S interface, a UART interface, a MIPI interface, etc.
[0067] It is understandable that the interface connection relationship between the modules illustrated in the embodiment of the present invention is only a schematic illustration and does not constitute a structural limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may also adopt different interface connection methods in the above embodiments, or a combination of multiple interface connection methods.
[0068] The charging management module 340 is used to receive charging input from a charger. The charger may be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 340 may receive charging input from a wired charger through the USB interface 330. In some wireless charging embodiments, the charging management module 340 may receive wireless charging input through a wireless charging coil of the electronic device 100. While the charging management module 340 is charging the battery 342, it may also power the electronic device through the power management module 341.
[0069] The power management module 341 is used to connect the battery 342, the charging management module 340 and the processor 310. The power management module 341 receives input from the battery 342 and / or the charging management module 340, and supplies power to the processor 310, the internal memory 321, the external memory, the display screen 394, the camera 393, and the wireless communication module 360. The power management module 341 can also be used to monitor parameters such as battery capacity, battery cycle number, battery health status (leakage, impedance), etc. In some other embodiments, the power management module 341 can also be set in the processor 310. In other embodiments, the power management module 341 and the charging management module 340 can also be set in the same device.
[0070] The wireless communication function of the electronic device 100 can be implemented through the antenna 1, the antenna 2, the mobile communication module 350, the wireless communication module 360, the modem processor and the baseband processor.
[0071] Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in electronic device 100 can be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve the utilization of antennas. For example, antenna 1 can be reused as a diversity antenna for a wireless local area network. In some other embodiments, the antenna can be used in combination with a tuning switch.
[0072] The mobile communication module 350 can provide solutions for wireless communications including 2G / 3G / 4G / 5G, etc., applied to the electronic device 100. The mobile communication module 350 may include at least one filter, a switch, a power amplifier, a low noise amplifier (LNA), etc. The mobile communication module 350 can receive electromagnetic waves from the antenna 1, and filter, amplify, etc. the received electromagnetic waves, and transmit them to the modulation and demodulation processor for demodulation. The mobile communication module 350 can also amplify the signal modulated by the modulation and demodulation processor, and convert it into electromagnetic waves for radiation through the antenna 1.
[0073] The wireless communication module 360 can provide wireless communication solutions for application in the electronic device 100, including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication technology (NFC), infrared technology (IR), etc.
[0074] In some embodiments, antenna 1 of electronic device 100 is coupled to mobile communication module 350, and antenna 2 is coupled to wireless communication module 360, so that electronic device 100 can communicate with the network and other devices through wireless communication technology.
[0075] The electronic device 100 implements the display function through a GPU, a display screen 394, and an application processor. The GPU is a microprocessor for image processing, which connects the display screen 394 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 310 may include one or more GPUs, which execute program instructions to generate or change display information.
[0076] The display screen 394 is used to display images, videos, etc. The display screen 394 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode or an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), Miniled, MicroLed, Micro-oLed, a quantum dot light-emitting diode (QLED), etc. In some embodiments, the electronic device 100 may include 1 or N display screens 394, where N is a positive integer greater than 1.
[0077] The electronic device 100 can realize the shooting function through ISP, camera 393, video codec, GPU, display screen 394 and application processor. ISP is used to process the data fed back by camera 393. For example, when taking a photo, the shutter is opened, and 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 the noise, brightness and skin color of the image. ISP can also optimize the exposure, color temperature and other parameters of the shooting scene. In some embodiments, ISP can be set in camera 393.
[0078] The camera 393 is used to capture still images or videos. The object generates an optical image through the lens and projects it onto the photosensitive element. The photosensitive element can be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the light signal into an electrical signal, and then passes the electrical signal to the ISP to be converted into a digital image signal. The ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into an image signal in a standard RGB, YUV or other format. In some embodiments, the electronic device 100 may include 1 or N cameras 393, where N is a positive integer greater than 1.
[0079] The camera 393 may include a time of flight (TOF) camera and an RGB camera, etc.
[0080] Among them, the TOF camera uses near-infrared light that is invisible to the human eye, and receives light reflected by an object, and converts the distance of the photographed scene through the time difference or phase difference between the light emission and reflection to form distance depth data. RGB camera, that is, red (R), green (G), blue (B) three-color camera, can obtain an image including multiple colors by changing the three color channels of red (R), green (G), and blue (B) and superimposing them on each other. In an embodiment of the present application, the TOF camera and the RGB camera are used to collect the user's eye image. For example, when an electronic device realizes the function of eye movement interaction, the TOF camera and / or the RGB camera can be controlled to collect images, and then eye movement recognition or calibration and other operations are performed based on the collected images to realize the function of eye movement interaction.
[0081] The digital signal processor is used to process digital signals, and can process not only digital image signals but also other digital signals. For example, when the electronic device 100 is selecting a frequency point, the digital signal processor is used to perform Fourier transform on the frequency point energy.
[0082] Video codecs are used to compress or decompress digital videos. The electronic device 100 may support one or more video codecs. Thus, the electronic device 100 may play or record videos in a variety of coding formats, such as moving picture experts group (MPEG) 3, MPEG2, MPEG3, MPEG4, etc.
[0083] NPU is a neural network (NN) computing processor. By drawing on the structure of biological neural networks, such as the transmission mode between neurons in the human brain, it can quickly process input information and can also continuously self-learn. Through NPU, applications such as intelligent cognition of electronic device 100 can be realized, such as image recognition, intelligent perception, voice recognition, text understanding, etc.
[0084] The external memory interface 320 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100. The external memory card communicates with the processor 310 through the external memory interface 320 to implement a data storage function, such as storing music, video and other files in the external memory card.
[0085] The internal memory 321 may be used to store computer executable program codes, which include instructions. The processor 310 executes various functional applications and data processing of the electronic device 100 by running the instructions stored in the internal memory 321. The internal memory 321 may include a program storage area and a data storage area.
[0086] The electronic device 100 can implement audio functions such as music playing and recording through the audio module 370, the speaker 370A, the microphone 370C, the headphone interface 370D, and the application processor.
[0087] The sensor module 380 in the electronic device may include a pressure sensor 380A, a gyro sensor 380B, an acceleration sensor 380E, a distance sensor 380F, a fingerprint sensor 380H, a touch sensor 380K, an ambient light sensor 380L, and the like.
[0088] The pressure sensor 380A is used to sense the pressure signal and can convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 380A can be set on the display screen 394. There are many types of pressure sensors 380A, such as resistive pressure sensors, inductive pressure sensors, capacitive pressure sensors, etc. The capacitive pressure sensor can be a parallel plate including at least two conductive materials. When a force acts on the pressure sensor 380A, 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 394, the electronic device 100 detects the touch operation intensity according to the pressure sensor 380A. The electronic device 100 can also calculate the touch position according to the detection signal of the pressure sensor 380A. In some embodiments, touch operations acting on the same touch position but with different touch operation intensities can correspond to different operation instructions. For example: when a touch operation with a touch operation intensity less than the first pressure threshold acts on the short message application icon, an instruction to view the short message is executed. When a touch operation with a touch operation intensity greater than or equal to the first pressure threshold acts on the short message application icon, an instruction to create a new short message is executed.
[0089] The gyro sensor 380B can be used to determine the motion posture of the electronic device 100. In some embodiments, the angular velocity of the electronic device 100 around three axes (i.e., x, y, and z axes) can be determined by the gyro sensor 380B. The gyro sensor 380B can be used for anti-shake shooting. Exemplarily, when the shutter is pressed, the gyro sensor 380B detects the angle of the electronic device 100 shaking, calculates the distance that the lens module needs to compensate based on the angle, and allows the lens to offset the shaking of the electronic device 100 through reverse movement to achieve anti-shake. The gyro sensor 380B can also be used for navigation and somatosensory game scenes.
[0090] The acceleration sensor 380E can detect the magnitude of the acceleration of the electronic device 100 in all directions (generally three axes). When the electronic device 100 is stationary, the magnitude and direction of gravity can be detected. It can also be used to identify the posture of the electronic device and is applied to applications such as horizontal and vertical screen switching and pedometers.
[0091] The distance sensor 380F is used to measure the distance. The electronic device 100 can measure the distance by infrared or laser. In some embodiments, when shooting a scene, the electronic device 100 can use the distance sensor 380F to measure the distance to achieve fast focusing.
[0092] The ambient light sensor 380L is used to sense the brightness of the ambient light. The electronic device 100 can adaptively adjust the brightness of the display screen 394 according to the perceived brightness of the ambient light. The ambient light sensor 380L can also be used to automatically adjust the white balance when taking pictures. The ambient light sensor 380L can also cooperate with the proximity light sensor 380G to detect whether the electronic device 100 is in a pocket to prevent accidental touches.
[0093] The fingerprint sensor 380H is used to collect fingerprints. The electronic device 100 can use the collected fingerprint characteristics to achieve fingerprint unlocking, access application locks, fingerprint photography, fingerprint answering calls, etc.
[0094] The touch sensor 380K is also called a "touch panel". The touch sensor 380K can be set on the display screen 394, and the touch sensor 380K and the display screen 394 form a touch screen, also called a "touch screen". The touch sensor 380K is used to detect touch operations acting 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 the touch operation can be provided through the display screen 394. In other embodiments, the touch sensor 380K can also be set on the surface of the electronic device 100, which is different from the position of the display screen 394.
[0095] The key 390 includes a power key, a volume key, etc. The key 390 may be a mechanical key or a touch key. The electronic device 100 may receive key input and generate key signal input related to user settings and function control of the electronic device 100.
[0096] Motor 391 can generate vibration prompts. Motor 391 can be used for incoming call vibration prompts, and can also be used for touch vibration feedback. For example, touch operations acting on different applications (such as taking pictures, audio playback, etc.) can correspond to different vibration feedback effects. For touch operations acting on different areas of the display screen 394, motor 391 can also correspond to different vibration feedback effects. Different application scenarios (for example: time reminders, receiving messages, alarm clocks, games, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect can also support customization.
[0097] Indicator 392 may be an indicator light, which may be used to indicate charging status, power changes, messages, missed calls, notifications, etc.
[0098] The software system of the electronic device 100 may adopt a layered architecture, an event-driven architecture, a micro-core architecture, a micro-service architecture, or a cloud architecture. In the embodiment of the present invention, the Android system of the layered architecture is taken as an example to exemplify the software structure of the electronic device 100.
[0099] Figure 4It is a software structure block diagram of the electronic device 100 according to an embodiment of the present invention.
[0100] The layered architecture divides the software into several layers, each with clear roles and division of labor. The layers communicate with each other through software interfaces. In some embodiments, the Android system may include, for example, an application layer, an application framework layer, an Android runtime (Android runtime) and a system library, a hardware abstraction layer (HAL) and a kernel layer. It should be noted that the embodiments of the present application are illustrated by taking the Android system as an example. In other operating systems (such as Hongmeng system, IOS system, etc.), as long as the functions implemented by each functional module are similar to those of the embodiments of the present application, the solutions of the present application can also be implemented.
[0101] The application layer can include a series of application packages.
[0102] like Figure 4 As shown, the application package may include camera, gallery, calendar, call, map, navigation, WLAN, settings, system user interface (UI), music, short message and other applications.
[0103] Among them, the settings application can turn on or off the smart perception function. In response to the user's operation of turning on the smart perception function in the settings application, the electronic device can capture images and identify the user's eye movement data from the captured images, so as to achieve eye movement interaction based on the user's eye movement data. Optionally, in response to the user's operation of turning on the smart perception function in the settings application, the electronic device can display a guidance interface for eye movement calibration. The guidance interface may include guidance text information and guidance images or symbols for guiding the user to complete the eye movement calibration process, so as to guide the user to complete the specified eye movement according to the guidance text information and the guidance image or symbol guidance interface. After that, the electronic device can complete the eye movement calibration process according to the specified eye movement completed by the user.
[0104] The application framework layer provides an application programming interface (API) and a programming framework for the applications in the application layer. The application framework layer includes some predefined functions.
[0105] like Figure 4 As shown, the application framework layer may include a window manager, a content provider, a view system, a resource manager, a notification manager, an intelligent perception service, a camera service, etc.
[0106] The window manager is used to manage window programs. The window manager can obtain the display screen size, determine whether there is a status bar, lock the screen, capture the screen, etc.
[0107] Content providers are used to store and retrieve data and make it accessible to applications. The data may include videos, images, audio, calls made and received, browsing history and bookmarks, phone books, etc.
[0108] The view system includes visual controls, such as controls for displaying text, controls for displaying images, etc. The view system can be used to build applications. A display interface can be composed of one or more views. For example, a display interface including a text notification icon can include a view for displaying text and a view for displaying images.
[0109] The resource manager provides various resources for applications, such as localized strings, icons, images, layout files, video files, and so on.
[0110] The notification manager enables applications to display notification information in the status bar. It can be used to convey notification-type messages and can disappear automatically after a short stay without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc. The notification manager can also be a notification that appears in the system top status bar in the form of a chart or scroll bar text, such as notifications of applications running in the background, or a notification that appears on the screen in the form of a dialog window. For example, a text message is displayed in the status bar, a prompt sound is emitted, an electronic device vibrates, an indicator light flashes, etc.
[0111] The Intelligent Perception Service is used to process the eye movement recognition and tracking requests sent by the application and return the processing results to the application to implement the eye movement recognition and tracking functions.
[0112] The camera service is used to manage the work of the camera. For example, it can control the camera to be turned on and off, and control the camera shooting parameters such as resolution and frame rate.
[0113] Android Runtime includes core libraries and virtual machines. Android runtime is responsible for scheduling and management of the Android system.
[0114] The core library consists of two parts: one is the function that needs to be called by the Java language, and the other is the Android core library.
[0115] The application layer and the application framework layer run in a virtual machine. 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 life cycle management, stack management, thread management, security and exception management, and garbage collection.
[0116] The system library may include multiple functional modules, such as surface manager, media library, 3D graphics processing library (such as OpenGL ES), 2D graphics engine (such as SGL), etc.
[0117] The surface manager is used to manage the display subsystem and provide the fusion of 2D and 3D layers for multiple applications.
[0118] The media library supports playback and recording of a variety of commonly used audio and video formats, as well as static image files, etc. The media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.
[0119] The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.
[0120] A 2D graphics engine is a drawing engine for 2D drawings.
[0121] The hardware abstraction layer (HAL) is an encapsulation of the Linux kernel driver, providing an interface to the upper layer and shielding the implementation details of the underlying hardware. The HAL layer can include the camera HAL and the intelligent perception control module.
[0122] Among them, the camera HAL is the core software framework of the Camera, which can include sensor nodes and image front end (IFE) nodes. The sensor node and IFE node are components (nodes) in the image data and control instruction transmission path (also called transmission pipeline) created by the camera HAL.
[0123] The intelligent perception control module is the core software application of intelligent perception. The intelligent perception control module includes the intelligent perception client application (CA), and the intelligent perception CA runs in the REE environment.
[0124] A smart perception trusted application (TA) is an application for smart perception that runs in a TEE environment.
[0125] The kernel layer is the layer between hardware and software. The kernel layer contains at least display driver, camera driver, audio driver, and sensor driver.
[0126] Among them, the camera driver is the driver layer of the Camera device, which is mainly responsible for the interaction with the camera hardware.
[0127] The hardware layer includes display, TOF camera, RGB camera, IFE module, IPE module, IFE-Lite module, secure buffer, etc.
[0128] Among them, the image front end (IFE) module can perform image processing such as AE and AWB on the image data.
[0129] The lightweight image pre-processing (IFE-Lite) module is a simplified version of the IFE module and can be used to forward image data without processing the image data during the forwarding process.
[0130] The image processing engine (IPE) module is mainly composed of two parts: NPS and PPS, which are used to perform hardware noise reduction, cropping, noise reduction, color processing, detail enhancement and other image processing tasks. Among them, hardware noise reduction includes, for example, multi-frame noise reduction (MFNR) and multi-frame super-resolution (MFSR).
[0131] Secure memory refers to a memory with security protection function, which can be used to store image data collected by the TOF camera and the RGB camera. In some embodiments, the image acquired by the TOF camera is forwarded by the IFE-Lite module and stored in the secure memory, and the image acquired by the RGB camera can be processed by the IFE module before the IPE module sends the processed image to the secure memory.
[0132] Combine the following Figure 5 , the interaction between the software modules involved in the method provided in the embodiment of the present application is described.
[0133] like Figure 5 As shown, the applications, system UI, smart perception services, smart perception control modules, camera services, camera HAL, camera driver, TOF camera, RGB camera, IFE-Lite, IFE module, IPE module and secure memory in the electronic device are located on the REE side, and the smart perception TA in the electronic device is located on the TEE side.
[0134] The system UI in the application layer can interact with the smart perception service in the framework layer. The system UI can interact with the smart perception service by calling a preset application programming interface (API).
[0135] The intelligent perception service in the framework layer interacts with the intelligent perception control module in the HAL layer.
[0136] The smart perception control module in the HAL layer interacts with the camera service in the framework layer. The smart perception control module can interact with the camera service by calling the interface (vendor native development kit, VNDK).
[0137] The camera service in the framework layer interacts with the camera HAL in the HAL layer. The camera HAL may include sensor nodes and IFE nodes. The sensor node interacts with the camera driver in the kernel layer, and the IFE node may also interact with the camera driver in the kernel layer. The camera driver may be used to drive the TOF camera or RGB camera in the hardware layer to collect image data in a preset working mode (e.g., eye tracking acquisition mode).
[0138] The IFE-Lite module can forward the image data collected by the TOF camera to the secure memory for storage. The IPE module can forward the image data collected by the RGB camera to the secure memory for storage.
[0139] The camera driver can also be used to obtain the file descriptor (FD) of the image data collected by the TOF camera from the IFE-Lite module, and / or obtain the FD of the image data collected by the RGB camera from the IPE module. Among them, FD is used to indicate the storage location of the image data collected by the TOF camera or the RGB camera in the secure memory.
[0140] Afterwards, the camera driver sends FD to the IFE node of the camera HAL, the IFE node can send FD to the camera service, and the camera service can send FD to the smart perception control module. The smart perception control module sends FD to the smart perception TA on the TEE side. The smart perception TA can read the image data from the secure memory according to the FD. After the encryption module in the smart perception TA encrypts the image data, the smart perception TA sends the encrypted image data to the smart perception control module on the REE side. Among them, the encryption key can also be transmitted between the smart perception TA and the smart perception control module. The smart perception control module can decrypt the encrypted image data with the secret key, and perform eye movement recognition and tracking based on the decrypted image data to obtain the user's eye movement data. The smart perception control module sends the eye movement data to the smart perception service, and the smart perception service sends the eye movement data to the system UI. The system UI determines the user's gaze point and gaze action based on the eye movement data, and performs operations on the interactive objects corresponding to the gaze point according to the user's gaze action.
[0141] Among them, the solid arrows in the figure can be used to represent control flow, and the dotted arrows can be used to represent data flow.
[0142] Optionally, after the smart perception TA on the REE side reads the image data from the secure memory according to the FD, it can also perform eye movement recognition and tracking on the read image data to obtain the user's eye movement data. Afterwards, the smart perception TA sends the eye movement data to the smart perception control module, which then sends the eye movement data to the smart perception service, which finally sends the eye movement data to the system UI, so that the system UI can determine the user's gaze point and gaze action based on the eye movement data, and perform operations on the interactive object corresponding to the gaze point according to the user's gaze action, which can ensure the security of eye movement recognition.
[0143] The embodiment of the present application provides a message processing method that can be applied to an electronic device including a front camera, wherein the front camera refers to a camera located on the same side as the display screen of the electronic device, so as to ensure that when the user looks at the display screen, the front camera can obtain the user's eye image.
[0144] Optionally, the method can also be applied to an electronic device connected to an eye movement detection device. The electronic device can obtain the user's eye movement information through the eye movement detection device. The eye movement detection device can include, for example, smart glasses, an eye movement detector, or a non-wearable image acquisition device.
[0145] First, the electronic device enables the eye movement interaction function. There are many ways for the electronic device to start this function, for example, the eye movement recognition function can be started in response to a user's trigger operation (such as a touch operation, a voice operation, or a gesture operation, etc.).
[0146] In some embodiments, Figure 6 As shown in (a) of FIG. 1 , the interface displayed by the electronic device includes multiple application icons. In response to the user clicking the setting application icon, the electronic device displays the following Figure 6 In the setting interface shown in (b) of FIG. 1 , the setting options displayed in the setting display interface include eye movement interaction. The eye movement interaction corresponding operation bar in the setting interface can display the enabled state of the eye movement interaction function, such as Figure 6 As shown in (b) of the figure, the operation bar corresponding to the eye movement interaction shows "off", indicating that the electronic device has not enabled the eye movement interaction function. After the electronic device detects that the user clicks on the setting option of the eye movement interaction, it displays the following Figure 6 The eye movement interaction setting interface shown in (c) in FIG. 1 includes a switch button for enabling the eye movement interaction function. Figure 6 The switch button shown in (c) in the figure indicates that the eye movement interaction function is not enabled. Figure 6 By clicking the switch button shown in (c) in the figure, the eye interaction function can be enabled.
[0147] After the eye movement interaction function is enabled, the electronic device performs eye movement calibration. In some embodiments, the electronic device performs eye movement calibration each time the eye movement interaction function is enabled; in other embodiments, the electronic device performs eye movement calibration periodically (such as once a month, once a week, etc.); in other embodiments, the electronic device performs eye movement calibration after the eye movement interaction function is enabled for the first time. This application does not limit the specific practice and calibration frequency of the eye movement calibration performed by the electronic device.
[0148] In some embodiments, the electronic device may store the user's eye movement calibration data, and after the electronic device recognizes the user's current eye movement data based on the collected images, it may determine the user's gaze point position based on the eye movement calibration data and the current eye movement data. The eye movement calibration data is obtained based on the user's gaze at a known position on the display screen of the electronic device, and is used to indicate the relationship between the user's eye movement data and the user's gaze point position on the display screen.
[0149] In some examples, the electronic device may determine whether eye movement calibration data is stored in the electronic device after detecting that a user turns on a switch button for activating an eye movement interaction function.
[0150] In response to the eye movement calibration data being stored in the electronic device, the electronic device can obtain image data, identify the user's eye movement data from the image data, and then determine the user's current gaze coordinate point based on the eye movement calibration data and the eye movement data. Specifically, the electronic device can identify the direction in which the user's eyes are looking from the image data, and then determine the position of the gaze point of the user's eyes looking at the display screen based on the relationship between the user's eye movement data indicated by the eye movement calibration data and the physical position in the display screen. For example, the electronic device can identify the direction in which the user's eyes are looking from the image data, and then determine the position of the gaze point of the user's eyes looking at the display screen based on the relationship between the user's eye movement data indicated by the eye movement calibration data and the physical position in the display screen.
[0151] In response to the fact that the eye movement calibration data is not stored in the electronic device, the electronic device may display an eye movement calibration interface to guide the user to complete the eye movement calibration process, thereby obtaining the user's eye movement calibration data. Specifically, the electronic device may display an eye movement calibration guidance interface, which may include guidance text information and guidance images or symbols for guiding the user to complete the eye movement calibration process, so as to guide the user to complete the specified eye movement according to the guidance text information and the guidance image or symbol guidance interface, and then the electronic device may complete the eye movement calibration process according to the specified eye movement completed by the user.
[0152] For example, the first guidance interface displayed by the electronic device may display guidance text information, and then the second guidance interface displayed by the electronic device may display calibration circles corresponding to the guidance text and guidance images or symbols. For example, the first guidance interface may display guidance text information: calibration circles displayed in sequence on the gaze screen until the interface displays that the eye movement calibration is completed. Afterwards, the second guidance interface displayed by the electronic device may display the following in sequence in a preset order: Figure 7 The calibration circles 1, 2, 3, 4 and 5 are shown in (a) of the figure. In response to the user staring at the calibration circle displayed on the screen for more than the first calibration time, the electronic device cancels the display of the calibration circle and continues to display the calibration circles that have not been displayed among the five calibration circles until all the calibration circles have been displayed on the screen. For another example, a guidance text message may be displayed in the first guidance interface: All the calibration circles are displayed on the screen, please keep your eyes on the white circles until all the calibration circles turn green. Afterwards, the second guidance interface displayed by the electronic device may display the following Figure 7As shown in (b) of FIG. 1 , there are calibration circles 1, 2, 3, 4, 5, 6, 7, 8, and 9 without color filling. The electronic device can change the color of each calibration circle to white in a preset order. In response to the user's gaze action on the calibration circle with a white color, the electronic device changes the color of the calibration circle with a white color to green. In response to all calibration circles turning green, the electronic device can display a third guidance interface for indicating the completion result of eye movement calibration.
[0153] In some examples, after the electronic device detects that the user turns off the switch button for activating the eye movement interaction function, the electronic device can retain the eye movement calibration data stored in the electronic device. Afterwards, the electronic device detects that the user turns on the switch button for activating the eye movement interaction function again, and the eye movement interaction function can be implemented according to the stored eye movement calibration data.
[0154] Optionally, after the electronic device detects that the user turns off the switch button for activating the eye movement interaction function, the electronic device may delete the eye movement calibration data stored in the electronic device. Afterwards, after the electronic device detects that the user turns on the switch button for activating the eye movement interaction function again, the eye movement calibration data may be acquired again.
[0155] In some examples, the electronic device detects that the user Figure 6 After clicking the switch button shown in (c) in FIG. Figure 8 The eye movement interaction setting interface shown includes options such as eye movement interaction, manual eye movement calibration and automatic eye movement calibration. The eye movement interaction setting interface also includes a switch button corresponding to the eye movement interaction option and in the turned-on state, a start button corresponding to the manual eye movement calibration option, and a switch button corresponding to the automatic eye movement calibration option.
[0156] The start button corresponding to the manual eye movement calibration option is used to start the eye movement calibration process. In response to the user clicking the start button, the electronic device can start the eye movement calibration process to obtain the user's eye movement calibration data. The specific eye movement calibration process can be referred to the above embodiment, which will not be described here.
[0157] Among them, the electronic device detects that the user Figure 6 After the switch button shown in (c) is clicked, Figure 8 In the eye movement interaction setting interface shown, the switch button corresponding to the eye movement automatic calibration option may be in the default off state.
[0158] In response to the user Figure 8In the example, the electronic device can change the state of the switch button corresponding to the eye movement automatic calibration option from the off state to the on state by clicking the switch button corresponding to the eye movement automatic calibration option shown in the figure, and automatically calibrate according to the preset rules. For example, the electronic device can obtain the position of the gaze point of the user's eyes looking at the display screen and the actual position of the eye movement interaction object determined within a preset time period. Afterwards, the electronic device updates the stored eye movement calibration data based on the gaze point position and the actual position of the corresponding interaction object.
[0159] In some examples, during the eye movement calibration process, the electronic device may establish an eye movement calibration channel through steps S901 to S904, wherein: Fig. 9 Steps S901 to S904 are shown in FIG.
[0160] S901. The setting application calls the eye movement calibration interface of the system UI to trigger the eye movement calibration process.
[0161] In some embodiments, in response to a user's Figure 6 (c) The on-off operation performed by the switch button corresponding to the eye movement interaction, or the on-off operation performed by the user in response to the user's Figure 8 For the click operation of the start control for starting manual eye movement calibration, the setting application can call the eye movement calibration interface of the system UI so that the system UI can trigger the eye movement calibration process.
[0162] Optionally, an application supporting eye movement interaction in an electronic device can trigger an eye movement calibration process by calling an eye movement calibration interface of a system UI. The system UI includes an eye movement interaction whitelist and / or an eye movement interaction blacklist, wherein the eye movement interaction whitelist is used to indicate applications that can call the eye movement calibration interface, and the eye movement interaction blacklist is used to indicate applications that cannot call the eye movement calibration interface.
[0163] For example, the electronic device may include a switch button for displaying eye movement interaction in the setting interface of application A that supports eye movement interaction. In response to the user turning on the switch button, application A may call the eye movement calibration interface of the system UI.
[0164] S902. The system UI sends an eye movement calibration registration request to the smart perception service.
[0165] The eye movement calibration registration request is used to request the intelligent perception service to perform eye movement calibration and obtain eye movement calibration results.
[0166] In some embodiments, the eye movement calibration registration request includes an eye movement calibration fence. The eye movement calibration fence is a virtual boundary created around the display area of the display screen. When the user gazes at the area within the virtual boundary, the electronic device can calibrate the user's eye movement information.
[0167] S903. The intelligent perception service sends an eye movement calibration process call request to the intelligent perception control module.
[0168] In addition, the system UI can also register a callback with the smart perception service. The purpose of registering the callback is that when the smart perception service obtains the eye movement calibration result, it can return the eye movement calibration result to the system UI.
[0169] That is, the system UI can notify the smart perception control module to perform the eye movement calibration operation through the smart perception service. The smart perception service can send the eye movement calibration result obtained from the smart perception control module to the system UI.
[0170] S904: In response to receiving the eye movement calibration process call request, the intelligent perception control module creates a camera path according to the eye movement calibration process call request.
[0171] Specifically, the intelligent perception control module can obtain the number of cameras started, the ID used to indicate the camera, and image parameters such as the resolution, frame rate, and data stream format of the image output by the camera from the eye movement calibration process call request.
[0172] It should be understood that during the startup of the electronic device, the camera service can send a camera query request to the camera HAL, and the camera query request is used to request the supported cameras during the operation of the electronic device. After receiving the camera query request, the camera HAL can send the data of the cameras supported by the electronic device to the camera service, and the camera service can store the received data of the cameras supported by the electronic device. Among them, the camera data supported by the electronic device includes the camera identification (identity, ID), type, location of each camera, and the maximum resolution size, frame rate and data stream format supported by each camera.
[0173] For example, if the electronic device includes three cameras, a front TOF camera with an ID of A, a front RGB camera with an ID of B, and a rear camera with an ID of C, wherein the rear camera C and the display screen are respectively located on the same side of the electronic device. The smart perception control module can send a camera query request to the camera service, and the camera service sends the camera data supported by the electronic device to the smart perception control module. The smart perception control module can determine the target camera according to the camera data supported by the electronic device, for example, the target camera can be determined to be the camera with ID A and ID B.
[0174] Alternatively, if Fig. 9 As shown, in response to receiving the eye movement calibration process call request, the step S904 of the intelligent perception control module creating a camera path according to the eye movement calibration process call request may include the following steps (S905-S909):
[0175] S905. The intelligent perception control module sends a camera opening request to the camera service.
[0176] The camera open request includes the target camera's data.
[0177] For example, the smart perception control module may send a request to open the camera to the camera service through the vendor native development kit (VNDK) interface, wherein the request to open the camera may include information such as the camera ID, the resolution size of the camera output image, the frame rate, and the data stream format.
[0178] S906: In response to receiving the request to open the target camera, the camera service sends a request to open the target camera to the camera HAL.
[0179] The target camera's open request carries the stream allocation information, which is used to create a channel for transmitting data streams and control streams. The stream allocation information includes the ID for indicating the camera, and image parameters such as the resolution, frame rate, and data stream format of the image output by the camera.
[0180] In addition, the camera service can register a callback with the camera HAL, which is used to allow the camera HAL to notify the camera service of the result of creating the channel.
[0181] S907: The camera HAL creates a channel for the target camera according to the opening request of the target camera.
[0182] The camera HAL includes sensor nodes and IFE nodes. The sensor node is used to send the data of the target camera to the camera driver, and the IFE node can obtain the FD of the image data collected by the target camera. The open request of the target camera includes the data of the TOF camera and the data of the RGB camera. The data of the TOF camera includes the ID of the TOF camera and the working sequence of the TOF camera, and the data of the RGB camera includes the ID of the RGB camera and the working sequence of the RGB camera. The camera driver can configure the working sequence in the register of the target camera through the I2C bus based on the camera ID, so that the target camera can work according to the working sequence in the register.
[0183] Specifically, the sensor node in the camera HAL can send the data of the TOF camera to the camera driver, and the camera driver can configure the working sequence of the TOF camera to the register of the TOF camera. The TOF camera collects image data according to the working sequence in its corresponding register, and the image data is forwarded by the IFE-Lite module and written into the secure memory for storage. The IFE-Lite module can also send the FD corresponding to the image data to the IFE node in the camera HAL through the camera driver. The sensor node in the camera HAL can send the data of the RGB camera to the camera driver, and the camera driver can configure the working sequence of the RGB camera to the register of the RGB camera. The RGB camera collects image data according to the working sequence in its corresponding register, and the image data is processed by 3A statistics and raw2yuv conversion by the IFE module. The obtained image data is then sent to the secure memory for storage after being scaled by the IPE module based on the preset resolution size. The IPE module can also send the FD corresponding to the image data to the IFE node in the camera HAL through the camera driver.
[0184] Exemplarily, the sensor node sends the distribution information of the eye movement calibration mode carried in the opening request of the target camera to the camera driver module of the Kernel layer. The camera driver writes or updates the configuration parameters in the distribution information into the registers of the TOF camera and the RGB camera. Afterwards, the camera driver sends a startup instruction to the TOF camera and the RGB camera to enable the TOF camera and the RGB camera to collect image data. In response to receiving the startup command, the TOF camera and the RGB camera start to collect image data.
[0185] After that, the TOF camera sends the collected TOF RAW image to the IFE-Lite module. The IFE-Lite module sends the TOF RAW image to the secure memory, and sends the first FD corresponding to the TOF RAW image to the IFE node via the camera driver. The RGB camera sends the collected RGB RAW image to the IFE module for 3A statistics and raw2yuv conversion processing, and then sends it to the IPE module for scaling according to the preset resolution size to obtain the processed RGB image. The IPE module sends the processed RGB image to the secure memory, and sends the second FD corresponding to the processed RGB image to the IFE node via the camera driver.
[0186] Optionally, hard synchronization can be achieved between the TOF camera and the RGB camera to ensure the accuracy of eye movement calibration. Specifically, the TOF camera and the RGB camera can be connected by a cable, and the RGB camera is set as the master camera module (master), and the TOF camera is set as the slave camera module (slave). Thus, the RGB camera outputs a field synchronization signal (xvs) to the TOF camera.
[0187] S908: The camera HAL returns the result of creating the channel to the camera service.
[0188] The result of creating the path can be success or failure. If the result of creating the path is failure, the camera HAL notifies the camera service that the path creation failed. If the result of creating the path is success, the camera HAL notifies the camera service that the path creation is successful, and S909 and subsequent steps can be continued.
[0189] S909. In response to receiving the notification of successful channel creation, the camera service returns a message indicating that the camera opening is complete to the intelligent perception control module.
[0190] The camera opening completion means that the preparation work before the camera takes a photo or a video (for example, camera parameter configuration, power-on, and other preparation work) has been completed.
[0191] Afterwards, the electronic device can perform eye movement calibration based on the established eye movement calibration channel. When displaying the guidance interface, for example, based on the preset rules, the following is displayed in the display interface: Figure 7 (a) or Figure 7 When the calibration circle shown in (b) is used, the electronic device can perform the following steps (such as Fig. 9 Steps S910-S920) shown in the figure perform eye movement calibration:
[0192] S910: In response to receiving a message indicating that the camera is opened, the intelligent perception control module sends a data request to the camera service.
[0193] The data request is used to request the data stream, that is, to obtain the FD sent by the IFE-Lite module and / or the IPE module.
[0194] S911. In response to receiving a data request sent by the intelligent perception control module, the camera service calls the camera HAL to obtain a data stream.
[0195] The data stream may include the first FD and the second FD. Exemplarily, the camera driver may send the first FD and the second FD to the IFE node in the camera HAL, and the IFE node then sends the first FD and the second FD to the camera service through the interface of the camera HAL.
[0196] S912. The camera service sends the first FD and the second FD to the intelligent perception control module.
[0197] S913. The smart perception control module sends the first FD and the second FD to the smart perception TA.
[0198] S914. The intelligent perception TA reads the TOF RAW image and the RGB image from the secure memory according to the first FD and the second FD.
[0199] S915, Smart Perception TA encrypts the TOF RAW image and RGB image.
[0200] Among them, the smart perception TA includes an encryption module. Among them, the encryption module is used to encrypt the TOF RAW image and RGB image based on the secret key, so as to ensure that the TOF RAW image and RGB image will not be intercepted or modified by malicious programs after leaving the TEE side, thereby ensuring the accuracy of eye movement calibration.
[0201] S916. The smart perception TA sends the encrypted TOF RAW image and RGB image to the smart perception control module.
[0202] In some embodiments, the smart perception TA can also synchronously send a secret key to the smart perception control module so that the smart perception control module can decrypt the encrypted TOF RAW image and RGB image based on the secret key.
[0203] S917. The intelligent perception control module decrypts the encrypted TOF RAW image and RGB image, and performs eye movement calibration based on the TOF RAW image and RGB image.
[0204] The intelligent perception control module can obtain preset calibration data. The intelligent perception control module can perform eye movement recognition on the TOF RAW image and the RGB image to identify the user's gaze point coordinates. After that, the intelligent perception control module compares the user's gaze point coordinates with the expected gaze point coordinates in the preset calibration data, and determines the user's eye movement calibration result based on the comparison result.
[0205] For example, the intelligent perception control module can calculate the distance between the user's gaze point coordinates and the expected gaze point coordinates in the preset calibration data. If the distance is less than or equal to the preset distance, it means that the difference between the user's actual gaze point and the expected gaze point is not large, and the eye movement calibration result is a successful calibration. If the distance is greater than the preset distance, it means that the difference between the user's actual gaze point and the expected gaze point is large, and the eye movement calibration result is a failed calibration.
[0206] Optionally, the intelligent perception control module includes a TOF image processing unit, a face detection and key point extraction unit, an eye movement calibration unit, and an eye movement recognition unit.
[0207] Exemplarily, the TOF image processing unit can process the 2-phase TOF RAW image acquired by the TOF camera, and output a TOF infrared (IR) image with a resolution of 640*480, and a corresponding auto exposure (AE) time. The TOF IR image output by the TOF image processing unit or the RGB image with a resolution of 1024*768 output by the RGB camera is input into the face detection and key point extraction unit, which can output a face area rectangular frame and a face key point array after performing face detection.
[0208] The eye movement calibration unit can input 5 preset calibration point information (pixels) or 9 pixels (the number of pixels is not limited in this application), and obtain 10 consecutive TOF IR images and 10 RGB images based on each calibration point. Then, the face detection and key point extraction unit processes each picture to obtain the face area rectangular frame and face key point array in each picture, the current resolution and physical size (PPI) of the electronic device display, and the physical deviation of the calibration IR / RGB relative to the origin in the display interface (which can be the upper left corner of the display). After that, the eye movement calibration unit can output 5*10 or 9*10 16-dimensional floating point (float) calibration feature vectors accordingly.
[0209] The eye movement recognition unit inputs the face area rectangle and face key point array in a single picture, 5*10 or 9*10 16-dimensional float type calibration feature vectors, the current resolution and physical size (PPI) of the electronic device display, and the physical deviation of the calibration IR / RGB relative to the origin in the display interface (which can be the upper left corner of the display). After that, the eye movement recognition unit can output the gaze point position based on the origin in the display interface as a reference.
[0210] S918. The intelligent perception control module sends the eye movement calibration result to the intelligent perception service.
[0211] The smart perception control module can pass the eye movement calibration results to the smart perception service based on the callback previously registered with the smart perception service.
[0212] S919. The intelligent perception service sends the eye movement calibration result to the system UI.
[0213] Similarly, the intelligent perception service can pass the eye movement calibration results to the system UI based on the callback previously registered with the system UI.
[0214] S920. The system UI displays a calibration result interface according to the eye movement calibration result.
[0215] The system UI can display a calibration result interface based on the eye movement calibration result to prompt the user whether the calibration is completed. If the eye movement calibration result is a calibration failure, the displayed calibration result interface may include a restart eye movement calibration control; if the eye movement calibration result is a calibration success, the displayed calibration result interface may include an eye movement interaction authorization interface. The eye movement interaction authorization interface may include applications that support eye movement interaction and authorization controls corresponding to each application. In response to the user clicking the authorization control, the electronic device may add the corresponding application to the eye movement interaction whitelist.
[0216] Optionally, in the above-mentioned eye movement calibration process, after the smart perception TA reads the TOF RAW image and the RGB image from the secure memory according to the first FD and the second FD, the smart perception TA can perform eye movement calibration processing based on the TOF RAW image and the RGB image, and then send the eye movement calibration result to the smart perception control module. The smart perception control module sends the eye movement calibration result to the smart perception service, and the smart perception service sends the eye movement calibration result to the system UI, and the system UI displays the calibration result interface according to the eye movement calibration result.
[0217] In some examples, if the eye movement calibration result is a calibration failure, the calibration result interface displayed by the system UI may include an indicator for indicating calibration failure, and a start control for re-calibrating the eye movement, to remind the user that the eye movement calibration has failed, and the user can re-execute the calibration process by clicking the start control for re-calibrating the eye movement. If the eye movement calibration result is a calibration success, the calibration result interface displayed by the system UI may include an indicator for indicating calibration success, to remind the user that the eye movement calibration is successful.
[0218] Optionally, when an application supporting eye movement interaction is run for the first time or the eye movement interaction function is enabled, the electronic device may prompt the user to perform an authorization operation. Exemplarily, the electronic device may display an authorization interface, which may include an authorization control and a never-authorize control. In response to the user clicking the authorization control in the authorization prompt, the electronic device may add the application to the eye movement interaction whitelist. In response to the user clicking the never-authorize control in the authorization prompt, the electronic device may add the user to the eye movement interaction blacklist.
[0219] After the eye movement calibration is successful, the electronic device can display a specific interface in the system UI, and in response to detecting that the user is looking at the target area, the interactive object can be determined. Afterwards, the electronic device performs corresponding operations on the interactive object based on the detected user's gaze duration on the target area.
[0220] For example, Fig.10As shown in (a), the display interface shows that the drop-down notification bar includes the display area of message A, the display area of message B, and the display area of message C. When the user wants to open the application interface corresponding to message A to fully display the content corresponding to message A, he can gaze at the area corresponding to message A in the interface. Afterwards, the electronic device recognizes the user's gaze action of gazing at the display area of message A through the eye movement recognition process. In response to the user's gaze action, the electronic device obtains the link corresponding to message A and performs an operation to open the link corresponding to message A. Fig.10 As shown in (b) in the figure, the content in the link corresponding to message A is displayed on the display screen of the electronic device.
[0221] Optionally, the gaze areas in the display page may be divided according to actual operations actually performed on the application display content.
[0222] In some examples, a web page can be displayed in an electronic device, and the electronic device can recognize the user's eye movement. When the user's eye movement data is recognized as looking at the page-turning area below the web page, such as Fig.11 In the dotted box area shown in (a), the electronic device can switch the currently displayed web page to the next page. The electronic device can switch web pages by sliding or turning pages. When the electronic device switches by sliding, it can determine the sliding switching range according to the length of time the user stares at the page turning area. For example, Fig.11 As shown in (a) of FIG. 1 , the user gazes at the page turning area for 1 second, and the electronic device can slide the current page upward by one line, so that the first line of the current page is not displayed in the display area, and the first line of the next page is connected with the last line of the current page, as shown in FIG. Fig.11 As shown in (b) in the figure, sliding page turning is realized. When the electronic device turns pages, the current page can be replaced with the content of the next page after the user's gaze time reaches a preset gaze threshold.
[0223] The page turning area is covered on the displayed content of the web page. It can be understood that the page turning area can be covered on the displayed content of the web page in the form of a transparent layer, so that the user can see the content of the part of the web page covered by the page turning area, and the page turning area can also be covered on the displayed content of the web page in the form of an opaque layer or a semi-transparent layer. In this way, the user can intuitively feel the existence of the page turning area, so that the user can look at the page turning area when the page needs to be turned, avoiding page turning due to misoperation.
[0224] In some examples, the display page of the electronic device is an e-book page and a short video playback page. Fig.12The display interface shown includes area A at the bottom, area B at the top, area C on the right, and area D on the left. In the e-book page, the eye movement operation area in the e-book page can be determined according to the page turning method set by the user. For example, if the page turning method set by the user is sliding page turning, area A at the bottom of the display page is the next page turning gaze area, and area B is the previous page turning gaze area. If the page turning method set by the user is switching page turning, area A at the bottom of the display page can be the next page turning gaze area, and area B is the previous page turning gaze area, or area C on the right side of the display page can be the next page turning gaze area, and area D on the left side is the previous page turning gaze area. If the display page is a short video playback page, area A at the bottom of the display page is the next video switching gaze area, and area B is the previous video switching gaze area.
[0225] After the eye movement calibration process is completed and the eye movement calibration result is successful, the electronic device can trigger the display process of human-computer interaction based on eye movement in a preset scene or when a trigger event occurs.
[0226] The preset scenario may include, for example, a scenario where the electronic device receives a new notification message, a scenario where an application supporting eye movement interaction is started, or a scenario where an interface supporting eye movement interaction is displayed in a display interface of the electronic device. Alternatively, the triggering event may include, for example, an event where the electronic device receives a new notification message, an event where an application supporting eye movement interaction is started, or an event where an interface supporting eye movement interaction is displayed in a display interface of the electronic device.
[0227] For example, after receiving a new notification message, the electronic device may display the notification message in a drop-down notification bar, such as Fig.10 As shown in (a) in FIG. 1 , the electronic device may then call the eye movement recognition interface of the system UI. The electronic device may display a web page corresponding to a browser application, or display a reading page corresponding to an e-book application, and may also call the eye movement recognition interface of the system UI.
[0228] After the electronic device calls the eye movement recognition interface of the system UI, it can be used as follows: Fig.13 Steps S1301 to S1303 shown establish an eye movement recognition channel so as to complete the eye movement recognition process based on the eye movement recognition channel and realize human-computer interaction based on eye movement.
[0229] S1301. The system UI sends an eye movement recognition registration request to the intelligent perception service.
[0230] The eye movement recognition registration request includes an eye movement recognition fence. The eye movement recognition fence is to create a virtual boundary around the display area of the display screen. When the user looks at the area inside the virtual boundary, the electronic device can recognize the user's eye movement information.
[0231] The electronic device can determine the eye movement recognition fence according to the preset scene or trigger event of calling the eye movement recognition interface of the system UI, or obtain the eye movement recognition fence carried by the preset scene or trigger event. For example, if the preset scene is to display a message in the notification message drop-down menu bar, the corresponding eye movement recognition fence is the area in the drop-down menu bar where the notification message is displayed, such as Fig.10 The display area corresponding to message A, message B and message C in the display interface of the electronic device; if the trigger event is a web page of a browser application displayed in the display interface of the electronic device, the trigger event can send an eye movement recognition fence corresponding to the reading interface, such as Fig.11 The dotted box area in .
[0232] S1302. The intelligent perception service sends an eye movement recognition process call request to the intelligent perception control module.
[0233] In addition, the system UI can also register a callback with the smart perception service. The purpose of registering this callback is that when the smart perception service obtains the eye movement recognition result, it can return the eye movement recognition result to the system UI. In other words, the system UI can notify the smart perception control module to perform the eye movement recognition operation through the smart perception service. The smart perception service can send the eye movement recognition result obtained from the smart perception control module to the system UI.
[0234] S1303. In response to receiving the eye movement recognition process call request, the intelligent perception control module creates a camera path according to the eye movement recognition process call request.
[0235] In some examples, the intelligent perception control module can obtain the current ambient light data, and determine the current ambient light brightness based on the ambient light data, and then determine the camera ID that needs to be turned on based on the current ambient light brightness. For example, the intelligent perception control module can determine the target camera that needs to be turned on under the current ambient light brightness based on the control relationship between the ambient light brightness and the camera.
[0236] For example, if the electronic device includes three cameras, a front TOF camera with an ID of A, a front RGB camera with an ID of B, and a rear camera with an ID of C, wherein the rear camera C and the display screen are on the same side of the electronic device. And the control relationship obtained by the intelligent perception control module is: if the current ambient light brightness is greater than 100 lux (lux), the RGB camera is controlled to turn on; if the current ambient light brightness is less than or equal to 100 lux, the TOF camera is controlled to turn on. Then, when the intelligent perception control module obtains that the current light brightness is 50, it can control the TOF camera to turn on.
[0237] It can be understood that the above considerations are that when the current ambient light brightness is less than or equal to 100 lux, the image captured by the RGB camera is inaccurate compared to the image captured by the TOF camera. When the current ambient light brightness is greater than 100 lux, the image captured by the RGB camera is more accurate, and there is no need to turn on the TOF camera to capture the image. Therefore, the control relationship between the ambient light brightness and the camera in the above example is obtained. The actual control relationship obtained can be determined according to actual needs, and is not limited here.
[0238] Optionally, the intelligent perception control module can obtain current ambient light data at certain time intervals and change the camera channel according to the latest acquired current ambient light brightness, thereby ensuring that the currently opened camera channel can accurately identify eye movements and reduce the operating costs of the camera channel, such as power consumption and occupied resources.
[0239] For example, the intelligent perception control module can obtain the current ambient light brightness every 2 seconds, and determine the camera channel that needs to be created or closed based on the latest acquired current ambient light brightness. For example, the intelligent perception control module has created a TOF camera channel, that is, the TOF camera is turned on. At this time, when the intelligent perception control module detects that the current ambient light brightness is 150lux, it can control the currently enabled TOF camera channel to be closed and create an RGB camera channel.
[0240] In this way, the currently enabled camera channel can be synchronized with the current ambient light brightness in real time, thereby ensuring that the currently enabled camera channel can capture more accurate images, further ensuring the accuracy of eye movement recognition.
[0241] In some examples, when receiving an eye movement recognition process call request, the smart perception control module can first create two channels for the TOF camera and the RGB camera, that is, turn on the TOF camera and the RGB camera at the same time, so that the TOF camera and the RGB camera start collecting image data at the same time. Afterwards, the smart perception control module can identify whether there is a reflective obstruction to the user's eyes based on the image data collected by the RGB camera and the TOF camera, such as identifying whether the user is wearing glasses, or identifying a reflective obstruction between the user's eyes and the camera.
[0242] The intelligent perception control module may include a face recognition unit, which can identify the characteristic information of the eyes of the face based on the image data collected by the RGB camera and the TOF camera. When the characteristic information identified by the face recognition unit matches the image characteristics of wearing glasses, it can be considered that the user is wearing glasses. In addition, if the face recognition unit recognizes that there are a preset number of reflective points on the user's face except the pupil area, it can be considered that there is a reflective obstruction between the user's eyes and the camera.
[0243] The intelligent perception control module can further control the empty camera channel according to the ambient light brightness after identifying whether there is a reflective obstruction to the user's eyes. For example, if the intelligent perception control module identifies that there is a reflective obstruction to the user's eyes, it can determine whether the current ambient light brightness is greater than the preset ambient light brightness threshold. In response to the current ambient light brightness being greater than the preset ambient light brightness threshold, the intelligent perception control module can control the channel of the TOF camera to be closed and keep the RGB camera channel in an open state; in response to the current ambient light brightness being less than or equal to the preset ambient light brightness threshold, the intelligent perception control module can control the channel of the TOF camera to remain open and control the RGB camera channel to be closed. If the intelligent perception control module identifies that there is no reflective obstruction to the user's eyes, the channel of the TOF camera can be controlled to be closed and the channel of the RGB camera can be kept in an open state.
[0244] Alternatively, if Fig.13 As shown, in response to receiving the eye movement recognition process call request, the step S1303 of the intelligent perception control module creating a camera path according to the eye movement recognition process call request may include the following steps (S1304-S1308):
[0245] S1304. The intelligent perception control module sends a request to open the target camera to the camera service.
[0246] The target camera opening request includes the target camera data.
[0247] Exemplarily, the intelligent perception control module may send a request for opening a target camera to the camera service through a VNDK interface, wherein the request for opening the target camera carries information such as resolution size and data stream format.
[0248] At the same time, the smart perception control module can register a callback with the camera service. The registered callback is used to notify the smart perception control module that the target camera opening operation has been completed after the camera service completes the target camera opening.
[0249] S1305: In response to receiving the request to open the target camera, the camera service sends a request to open the target camera to the camera HAL.
[0250] The target camera's open request carries the stream allocation information, which is used to create a channel for transmitting data streams and control streams. The stream allocation information includes the ID for indicating the camera, and image parameters such as the resolution, frame rate, and data stream format of the image output by the camera.
[0251] In addition, the camera service can register a callback with the camera HAL, which is used to allow the camera HAL to notify the camera service of the result of creating the channel.
[0252] S1306. The camera HAL creates a path to the target camera according to the opening request of the target camera.
[0253] The camera HAL can send the data of the target camera to the camera driver through the sensor node, and obtain the FD of the image data collected by the target camera through the IFE node. The data of the target camera includes the ID of the target camera and the working sequence of the target camera. Based on the camera ID, the camera driver configures the working sequence in the register of the target camera through the I2C bus so that the target camera can work according to the working sequence in the register.
[0254] In some examples of the TOF camera pathway, the sensor node in the camera HAL can send the TOF camera data to the camera driver, and the camera driver can configure the TOF camera's working sequence to the TOF camera's register. The TOF camera collects image data according to the working sequence in its corresponding register, and the image data is forwarded by the IFE-Lite module and written to the secure memory for storage. The IFE-Lite module can also send the FD corresponding to the image data to the IFE node in the camera HAL through the camera driver.
[0255] In some examples of RGB camera paths, the sensor node in the camera HAL can send RGB camera data to the camera driver, and the camera driver can configure the working sequence of the RGB camera to the register of the RGB camera. The RGB camera collects image data according to the working sequence in its corresponding register. The image data is processed by the IFE module for 3A statistics and raw2yuv conversion. The obtained image data is then scaled by the IPE module based on the preset resolution size and sent to the secure memory for storage. The IPE module can also send the FD corresponding to the image data to the IFE node in the camera HAL through the camera driver.
[0256] Exemplarily, the sensor node sends the distribution information of the eye movement recognition mode carried in the opening request of the target camera to the camera driver module of the Kernel layer. The camera driver writes or updates the configuration parameters in the distribution information into the registers of the TOF camera and / or the RGB camera. Afterwards, the camera driver sends a startup instruction to the TOF camera and / or the RGB camera to enable the TOF camera and / or the RGB camera to collect image data. In response to receiving the startup command, the TOF camera and / or the RGB camera starts to collect image data.
[0257] After that, the TOF camera sends the collected TOF RAW image to the IFE-Lite module. The IFE-Lite module sends the TOF RAW image to the secure memory, and sends the first FD corresponding to the TOF RAW image to the camera driver. The RGB camera sends the collected RGB RAW image to the IFE module for 3A statistics and raw2yuv conversion processing, and then sends it to the IPE module for scaling according to the preset resolution size to obtain the processed RGB image. The IPE module sends the processed RGB image to the secure memory, and sends the second FD corresponding to the processed RGB image to the camera driver.
[0258] Optionally, the camera driver may send a message to the sensor node indicating that the configuration parameter writing is completed. In response to receiving the message indicating that the configuration parameter writing is completed, the sensor node sends a start command to the camera driver module.
[0259] S1307: The camera HAL returns the result of creating the channel to the camera service.
[0260] The result of creating the path may be success or failure. If the result of creating the path is failure, the camera HAL notifies the camera service that the path creation failed. If the result of creating the path is success, the camera HAL notifies the camera service that the path creation was successful, and S1308 and subsequent steps may continue to be executed.
[0261] S1308. In response to receiving the notification of successful channel creation, the camera service returns a message indicating that the camera is opened successfully to the intelligent perception control module.
[0262] It can be understood that the camera opening completion means that the preparation work before the camera takes a photo or a video, for example, the preparation work including camera parameter configuration, power-on, etc. has been completed.
[0263] Afterwards, the electronic device can perform eye movement recognition based on the established eye movement recognition channel and realize human-computer interaction based on eye movement recognition.
[0264] For example, Fig.13 Steps S1309 to S1319 shown:
[0265] S1309: In response to receiving the message indicating that the camera is opened, the intelligent perception control module sends a data request to the camera service.
[0266] The data request is used to request to obtain the FD sent by the IFE-Lite module and / or the IPE module.
[0267] S1310: In response to receiving a data request sent by the intelligent perception control module, the camera service calls the camera HAL to obtain a data stream.
[0268] The data stream may include the first FD and / or the second FD. Exemplarily, the camera driver may send the first FD and / or the second FD to the IFE node. The IFE node sends the first FD and / or the second FD to the camera service through the interface of the camera HAL.
[0269] S1311. The camera service sends the first FD and / or the second FD to the intelligent perception control module.
[0270] S1312. The smart perception control module sends the first FD and / or the second FD to the smart perception TA.
[0271] S1313. The intelligent perception TA reads the TOF RAW image and / or the RGB image from the secure memory accordingly according to the first FD and / or the second FD.
[0272] S1314. The intelligent perception TA encrypts the TOF RAW image and / or RGB image.
[0273] Among them, the smart perception TA includes an encryption module, which is used to encrypt the TOF RAW image and / or RGB image based on a secret key, so as to ensure that the TOF RAW image and / or RGB image will not be maliciously intercepted, modified, etc. after leaving the TEE side where the smart perception TA is located, thereby ensuring the accuracy of the eye movement recognition data.
[0274] S1315. The smart perception TA sends the encrypted TOF RAW image and / or RGB image to the smart perception control module.
[0275] In some embodiments, the smart perception TA can also send a secret key to the smart perception control module so that the smart perception control module can decrypt the encrypted TOF RAW image and / or RGB image based on the secret key.
[0276] S1316. The intelligent perception control module decrypts the encrypted TOF RAW image and / or RGB image, and performs eye movement recognition processing based on the TOF RAW image and / or RGB image.
[0277] The intelligent perception control module can perform eye movement recognition on the TOF RAW image and / or RGB image to identify the user's eye movement data, which may include data such as gaze point coordinates and gaze duration.
[0278] S1317. The intelligent perception control module sends the eye movement data to the intelligent perception service.
[0279] The smart perception control module can pass the eye movement data to the smart perception service based on the callback previously registered with the smart perception service.
[0280] S1318. The intelligent perception service sends the eye movement data to the system UI.
[0281] Similarly, the intelligent perception service can pass the eye movement data to the system UI based on the callback previously registered with the system UI.
[0282] S1319: The system UI determines the interactive object and the interactive operation performed on the interactive object according to the eye movement data.
[0283] The eye movement data may include the gaze point coordinates and the gaze duration. The system UI can determine the object that the user is looking at, i.e., the interactive object, based on the gaze point coordinates in the eye movement data. After confirming the interactive object, the system UI can further perform corresponding interactive operations on the interactive object based on the gaze duration.
[0284] Optionally, after the smart perception TA reads the TOF RAW image and / or the RGB image from the secure memory according to the first FD and / or the second FD, the smart perception TA can perform eye movement recognition processing based on the TOF RAW image and / or the RGB image, and then send the eye movement data to the smart perception control module. The smart perception control module sends the eye movement data to the smart perception service, and the smart perception service sends the eye movement data to the system UI, and the system UI determines the interactive object and the interactive operation performed on the interactive object according to the eye movement data.
[0285] In some examples, when the user is looking at a long notification message that is folded, such as Fig.14 As shown in (a), the electronic device can expand the folded long notification message according to the user's gaze time on the area where the long notification message is located. When the number of characters in the notification message content is greater than a preset character threshold, the electronic device can consider the notification message to be a long notification message and fold the long notification message for display.
[0286] Specifically, when the electronic device folds and displays a newly received long notification message in the first designated area in the display interface, the electronic device begins to recognize the user's eye movements, and determines based on the eye movement recognition results whether the user has been staring at the first designated area where the long notification message is displayed within a first preset time period, and the area of the first designated area is smaller than the display area in the drop-down notification message bar.
[0287] In response to the user gazing at the first designated area where the long notification message is displayed within a first preset time period, that is, when the electronic device determines based on the eye movement recognition result that the user's gaze position is within the first designated area, the electronic device obtains the user's gaze time on the designated area based on the eye movement recognition result. If the user's gaze time on the designated area exceeds the first preset gaze time threshold, the electronic device may deem that the user wants to perform an interactive operation on the interactive object, and may display the expanded long notification message in the second designated area in the display interface, and cancel the folded display of the first designated area, such as Fig.14 As shown in (b) in the figure, wherein the second designated area is larger than the first designated area.
[0288] In addition, if the electronic device displays the expanded long notification message in the second designated area in the display interface, and determines based on eye movement recognition that the user is not looking at the second designated area, the display of the long notification message in the notification message bar can be cancelled. Fig.14 Or, cancel the expanded display of the long notification message in the second designated area, and fold and display the long notification message in the first designated area again, as shown in (c) in FIG. Fig.14 As shown in (a) in .
[0289] In addition, if the electronic device displays the expanded long notification message in the second designated area of the display interface, and determines based on eye movement recognition that the user's gaze time in the second designated area is greater than the second preset gaze time threshold, it can be considered that the user wants to open the application that sent the long notification message. At this time, the electronic device can open the application corresponding to the long notification message. Fig.14 As shown in (b) of FIG. 1 , if the time for which the user gazes at the second designated area corresponding to the message A is greater than the second preset gaze time threshold, the following may be displayed: Fig.14 The display interface shown in (d) in the figure. Among them, the long notification message and the application may include, for example, a text message notification message corresponding to a message application, a video update notification message corresponding to a video application, and a music recommendation notification message corresponding to a music player application, which is not limited here.
[0290] Optionally, when the electronic device can open the application corresponding to the long notification message, it can first obtain a link corresponding to the long notification message. The link can be a link for opening an interface that can display the content of the long notification message, or a link for opening an interface with the long message notification as the theme, which does not necessarily include the content in the long message notification.
[0291] In response to the user not gazing at the first designated area within the first preset time length, or the time the user gazes at the first designated area does not exceed the first preset gaze time threshold, the electronic device may deem that the user is not interested in the long notification message, that is, has no intention to perform interactive operations, and may cancel the folded display of the first designated area in the display interface after the time length of the long notification message being folded and displayed exceeds a second preset time length.
[0292] Optionally, when the object the user is gazing at is a short notification message that is not folded and displayed, the short notification message can be interactively operated based on the user's gaze duration on the area where the short notification message is located. When the number of characters in the notification message content is less than or equal to a preset character threshold, the electronic device can consider the notification message to be a short notification message.
[0293] Specifically, when the electronic device displays a newly received short notification message in the first designated area in the display interface, the electronic device begins to recognize the user's eye movements and determines whether the user is staring at the third designated area where the short notification message is displayed within a third preset time period based on the eye movement recognition results.
[0294] In response to the user gazing at the third designated area displayed by the short notification message within the third preset time length, that is, when the electronic device determines based on the eye movement recognition result that the user's gaze position is within the third designated area, the electronic device obtains the user's continuous gaze time length on the third designated area based on the eye movement recognition result. If the user's continuous gaze time length on the third designated area exceeds the third preset gaze time length threshold, the electronic device may deem that the user wants to perform an interactive operation on the short notification message, and may display the application interface corresponding to the short notification message on the display interface, that is, open the application corresponding to the short notification message.
[0295] In addition, in response to the user not gazing at the third designated area within the third preset time length, or the user's gazing time length at the third designated area does not exceed the fourth preset gazing time length threshold, the electronic device may deem that the user is not interested in the short notification message, that is, has no intention to perform interactive operations on the short notification message. The electronic device may cancel the display of the short notification message in the third designated area of the display interface after the display time length of the long notification message in the third designated area exceeds the fourth preset time length.
[0296] In some embodiments, the user can interact with the application by looking at a specified position in the display interface displayed by the application running in the electronic device. The specified position can be as follows: Fig. 9 One or more of the areas in the display diagram may also be other areas determined according to actual needs. Optionally, the designated position may be an invisible transparent area or a visible area. The visible area may be suspended above the display interface displayed by the application, so that the user can accurately focus on the designated position.
[0297] Specifically, the designated location may include an area where the text content of the notification message is located, such as Fig.14 As shown in (a) of FIG. 1 , the electronic device can detect that the coordinates of the user's gaze point are within the area displayed by message A. In addition, the specified location can also include the display area of some controls corresponding to the notification message. For example, Fig.15 As shown, the designated position corresponding to message A includes a collapse control, a view details control, and a delete control. In response to the user looking at the collapse control, the electronic device can fold and display message A; in response to the user looking at the view details control, the electronic device can open the application display interface corresponding to message A; in response to the user looking at the delete control, the electronic device can delete message A from the notification message bar display interface. The designated position corresponding to message B includes an expand control, a view details control, and a delete control. In response to the user looking at the expand control, the electronic device can expand and display message B. The designated position corresponding to message C includes a reply control, a view details control, and a delete control. In response to the user looking at the reply control, the electronic device can display a text input box for replying to the message. The type and function of the gaze control at the designated position can be set according to the actual message, and are not limited here.
[0298] For example, when a short video application is running, the electronic device displays a short video display interface, and short video A is playing in the short video display interface. If the electronic device detects that the user is looking at the first target area at the bottom of the short video display interface, the short video A played in the short video display interface can be replaced with short video B. After that, if the electronic device detects that the user is looking at the second target area at the bottom of the short video display interface, the short video B played in the short video display interface can be replaced with short video C. After the short video A played in the short video display interface is replaced with short video B, if the electronic device detects that the user is looking at the second target area at the top of the short video display interface, the short video B played in the short video display interface can be replaced with short video A. Among them, the recommendation order of short video A is greater than the recommendation order of short video B, and the recommendation order of short video B is greater than the recommendation order of short video C. In this way, when the electronic device detects that the user is looking at the first target area or the second target area in the short video display interface, the short videos can be played in sequence according to the preset recommendation order.
[0299] Optionally, when the electronic device detects that the user is gazing at the first target area at the bottom of the short video display interface and the gazing time exceeds 3 seconds, the short video A played in the short video display interface can be replaced with short video B.
[0300] In addition, eye movement interaction can also be applied in shooting scenarios. In some examples, when an electronic device displays a shooting interface of a video or picture, it can determine the gaze position of the user in the display screen in response to the user's gaze. Afterwards, the electronic device can focus on the picture corresponding to the gaze position.
[0301] Optionally, when the electronic device displays a video or picture shooting interface, it can determine the gaze position on the display screen that changes with the user's eye movement in response to the user's continuous gaze. Afterwards, the electronic device can continuously focus on the picture corresponding to the gaze position, thereby achieving tracking focus.
[0302] In some embodiments, when the electronic device displays the lock screen interface, the user's eye movement can be recognized, and eye movement unlocking can be performed based on the eye movement recognition result. Fig.16 When gazing at the unlocking area in the lock screen interface shown, the user's eye movement can be identified to achieve gaze unlocking.
[0303] Optionally, when the electronic device displays the lock screen interface, it can recognize the user's eye movements and face, and unlock the device based on the eye movement and face recognition results to improve security. Fig.16When gazing at the unlocking area in the lock screen interface shown, the user's eye movements and face can be recognized, and whether the lock can be unlocked can be determined based on the eye movement recognition results and the face recognition results.
[0304] For example, the electronic device detects that the user is looking at Fig.16 When you look at the unlock area in the lock screen interface shown, image data can be collected. Afterwards, the electronic device determines the user's eye movement data based on the image data, wherein the eye movement data may include eye movement features corresponding to the user, and the user's identity can be identified based on the eye movement features. The electronic device can also determine the user's facial information based on the image data, wherein the facial information may include facial features corresponding to the user, and the electronic device can identify the user's identity based on the facial features. When the user identity verified by the electronic device based on the eye movement features is the same as the user identity verified based on the facial features, the electronic device can unlock the lock screen and display the unlocked operation interface.
[0305] The message processing method provided by the present application can determine the user's gaze point and gaze duration in the display screen by collecting and identifying the user's eye image. Afterwards, the electronic device can determine whether the user wants to operate the notification message in the display interface based on the user's gaze point and gaze duration, thereby realizing the interactive operation of the notification message based on the user's eye movement.
[0306] In this way, users can interact with electronic devices through eye movements, thus achieving a more convenient contactless human-computer interaction process.
[0307] In the message processing method provided by the present application, when the intelligent perception control module creates a camera path according to the eye movement recognition process call request, the current ambient light data can be obtained. Afterwards, the intelligent perception control module can determine the current ambient light brightness according to the ambient light data, and then determine the camera to be turned on according to the current ambient light brightness. In this way, the camera to be turned on is determined according to the actual environment, the accuracy of the collected image is ensured, and the accuracy of eye movement recognition is then improved.
[0308] In the message processing method provided in the present application, when the intelligent perception control module creates a camera path according to the eye movement calibration process call request, it can simultaneously establish paths where multiple cameras are located to ensure the accuracy of the eye movement calibration.
[0309] In the message processing method provided by the present application, in the above-mentioned eye movement calibration process, after the smart perception TA reads the TOF RAW image and RGB image from the secure memory according to the first FD and the second FD, the smart perception TA can perform eye movement calibration processing based on the TOF RAW image and the RGB image; in the above-mentioned eye movement recognition process, after the smart perception TA reads the TOF RAW image and / or the RGB image from the secure memory according to the first FD and / or the second FD, the smart perception TA can perform eye movement recognition processing based on the TOF RAW image and / or the RGB image. The security of image data in the eye movement calibration or eye movement recognition process is further improved, thereby ensuring the accuracy of eye movement calibration and eye movement interaction.
[0310] For example, Fig.17 The following is a flow chart of a video music processing method provided by the embodiment of the present application. Fig.10 As shown, the method includes the following steps.
[0311] S1701: The electronic device displays a first interface, which includes a notification message.
[0312] In some embodiments, the electronic device may display the first interface through the following process. Specifically, the electronic device displays the third interface, and the third interface includes a long notification message in a folded state. The number of characters in the long notification message is greater than a preset character threshold. The electronic device may obtain the number of characters in the notification message, and determine the notification message with the number of characters greater than the preset character threshold as a long notification message, and then display the long notification message in a folded state in the third interface, such as Fig.14 As shown in (a) in the figure, the notification message is briefly displayed in the drop-down notification message bar.
[0313] Afterwards, the electronic device collects second image data through the target image sensor, and the second image data includes the user's eye image. Afterwards, the electronic device determines the user's second eye movement data based on the user's second image data, and the second eye movement data includes second gaze point coordinates and second gaze duration. In response to the second gaze point coordinates being located in the display area of the long notification message, and the second gaze duration being greater than the second preset duration threshold, the electronic device displays the first interface, and the first interface includes the long notification message in an expanded state, such as Fig.14 As shown in (b) in .
[0314] In some embodiments, after the electronic device displays the first interface, it can also collect third image data through the target image sensor, and the third image data includes the user's eye image. Afterwards, the electronic device determines the user's third eye movement data based on the user's third image data. The third eye movement data includes third gaze point coordinates and third gaze duration. In response to the third gaze point coordinates being outside the display area of the long notification message on the first interface, the electronic device displays a fourth interface, and the fourth interface includes the long notification message in a folded state, such as Fig.14 As shown in (a) in FIG. 1 , message A is displayed again in a folded state. Alternatively, the fourth interface does not include a long notification message, such as Fig.14 As shown in (c) in the figure, message A is no longer displayed in the display interface.
[0315] S1702: Collect first image data through a target image sensor; the first image data includes an eye image of a user.
[0316] In some embodiments, the electronic device may obtain current ambient light data, determine the current ambient light brightness based on the ambient light data, and then determine the target image sensor to be turned on based on the current ambient light brightness. For example, the electronic device may determine the target camera to be turned on under the current ambient light brightness based on the control relationship between the ambient light brightness and the camera.
[0317] In some examples, the electronic device includes a time-of-flight TOF image sensor and an RGB image sensor. When the electronic device collects the first image data through the target image sensor, it can collect it through the following process. Specifically, the electronic device can first obtain the current ambient light brightness, and in response to the current ambient light brightness being greater than the first preset brightness threshold, control the RGB image sensor to collect the first RGB image data; in response to the current ambient light brightness being less than or equal to the first preset brightness threshold, control the TOF image sensor to collect the first TOF image data.
[0318] For example, if the current ambient light brightness is greater than 100 lux, the electronic device controls the RGB camera to turn on; if the current ambient light brightness is less than or equal to 100 lux, the electronic device controls the TOF camera to turn on. Then, when the electronic device obtains that the current ambient light brightness is 50, it can control the TOF camera to turn on.
[0319] In some embodiments, in response to the current ambient light brightness being greater than a first preset brightness threshold, after the electronic device controls the RGB image sensor to collect the first RGB image data, it can also determine whether the user's eyes are covered by a reflective object based on the first RGB image data. If it is determined based on the first RGB image data that the user's eyes are not covered by a reflective object, the electronic device controls the RGB image sensor to turn off, and controls the TOF image sensor to turn on and collect the first image data.
[0320] The electronic device can identify the feature information of the eyes of the face based on the first RGB image data. If the identified feature information matches the image feature of wearing glasses, it can be considered that the user is wearing glasses and the glasses are reflective objects. In addition, if the face recognition unit identifies that there are a preset number of reflective points in the area of the user's face except the pupil, it can be considered that there is a reflective object between the user's eyes and the image sensor.
[0321] S1703: Determine first eye movement data of the user based on the first image data of the user; the first eye movement data includes first gaze point coordinates and first gaze duration.
[0322] The electronic device can use the eye movement recognition model to determine the eye movement data. The electronic device includes an eye movement recognition unit, and the eye movement recognition unit includes an eye movement recognition model. Input the face area rectangular frame and face key point array in a single picture, 5*10 or 9*10 16-dimensional float type calibration feature vectors, the current resolution and physical size (PPI) of the electronic device display, and the physical deviation of the calibrated IR / RGB relative to the origin in the display interface (which can be the upper left corner of the display) into the eye movement recognition model. After that, the eye movement recognition unit can output the gaze point position based on the origin in the display interface of the display as a reference.
[0323] S1704: In response to the first gaze point coordinates being within the display area of the notification message and the first gaze duration being greater than a first preset duration threshold, displaying a second interface, where the second interface is a display interface of an application corresponding to the notification message.
[0324] In some embodiments, in response to the first gaze point coordinates being outside the display area of the notification message, Fig.18 As shown in (a) of FIG. 1 , when the user looks at the display area of any notification message, the electronic device displays the following after a first preset time period: Fig.18 The fifth interface shown in (b) in FIG. 5 may be a page that does not include a notification message.
[0325] In some embodiments, the electronic device includes a time-of-flight TOF image sensor and an RGB image sensor. When the target image sensor collects the first image data, the electronic device can control the RGB image sensor to collect the first RGB image data and the TOF image sensor to collect the first TOF image data. If it is determined based on the first RGB image data and / or the first TOF image data that the user's eyes are covered with reflective objects, the current ambient light brightness is obtained. In response to the current ambient light brightness being greater than the first preset brightness threshold, the electronic device controls the TOF image sensor to turn off.
[0326] In some embodiments, the electronic device may display a sixth interface, the sixth interface including at least one calibration position. Afterwards, the electronic device collects fourth image data through the target image sensor, and determines the coordinates of the fourth gaze point of the user based on the fourth image data, so as to determine the eye movement calibration result based on the coordinates of the calibration position and the error between the coordinates of the fourth gaze point.
[0327] The electronic device may display the sixth interface in response to the user operation. Figure 6 As shown in (a) of FIG. 1 , the interface displayed by the electronic device includes multiple application icons. In response to the user clicking the setting application icon, the electronic device displays the following Figure 6 In the setting interface shown in (b) of FIG. 1 , the setting options displayed in the setting display interface include eye movement interaction. The eye movement interaction corresponding operation bar in the setting interface can display the enabled state of the eye movement interaction function, such as Figure 6 As shown in (b) of the figure, the operation bar corresponding to the eye movement interaction shows "off", indicating that the electronic device has not enabled the eye movement interaction function. After the electronic device detects that the user clicks on the setting option of the eye movement interaction, it displays the following Figure 6 The eye movement interaction setting interface shown in (c) in FIG. 1 includes a switch button for enabling the eye movement interaction function. Figure 6 The switch button shown in (c) in the figure indicates that the eye movement interaction function is not enabled. Figure 6 After clicking the switch button shown in (c) in the figure, the sixth interface can be displayed.
[0328] Afterwards, the electronic device collects fourth image data through the target image sensor, and determines the coordinates of the fourth gaze point of the user based on the fourth image data, so as to determine the eye movement calibration result based on the coordinates of the calibration position and the error between the coordinates of the fourth gaze point. For example, the electronic device can obtain the calibration position of the user's eyes looking at the display screen determined within a preset time period, and the fourth gaze point coordinates of the eye movement interaction object determined based on the fourth image data. Afterwards, the electronic device drives the error between the coordinates of the calibration position and the fourth gaze point coordinates to determine the eye movement calibration result, so as to update the stored eye movement calibration data.
[0329] In some embodiments, the electronic device includes a time-of-flight TOF image sensor and an RGB image sensor. When the electronic device collects the fourth image data through the target image sensor, the TOF image sensor can be controlled to collect the second TOF image data, and the RGB image sensor can be controlled to collect the second RGB image data. It is ensured that the second TOF image data and the second RGB image data are simultaneously calibrated for eye movement, thereby ensuring the accuracy of the eye movement calibration, and then achieving more accurate eye movement recognition in the subsequent process.
[0330] Optionally, the electronic device includes a time-of-flight TOF image sensor and an RGB image sensor, and a hard-wired connection can be implemented between the TOF camera and the RGB camera to ensure the accuracy of eye movement calibration. Specifically, the TOF camera and the RGB camera can be connected by a connecting line, and the connecting line is used to transmit a synchronization signal so that the TOF image sensor and the RGB image sensor can synchronously collect image data based on the synchronization signal. In addition, the electronic device can also set the RGB camera as the main camera module (master) and the TOF camera as the slave camera module (slave). Thereby, the RGB camera outputs a field synchronization signal (xvs) to the TOF camera.
[0331] In some embodiments, the electronic device includes a hardware abstraction HAL layer and a hardware layer, the HAL layer includes an intelligent perception control module and an intelligent perception TA, the hardware layer includes a secure memory, and the secure memory is used to store image data collected by a target image sensor; the intelligent perception TA runs in a trusted execution environment.
[0332] When the electronic device determines the user's first eye movement data based on the user's first image data, it can obtain a file descriptor by controlling the smart perception control module. The file descriptor is used to describe the storage location of the first image data in the electronic device. After that, the smart perception TA is controlled to obtain the first image data from the secure memory according to the file descriptor. The smart perception TA encrypts the first image data and sends the encrypted first image data to the smart perception control module. The smart perception control module decrypts the encrypted first image data and determines the first eye movement data based on the first image data. Among them, the smart perception TA can also synchronously send a secret key to the smart perception control module so that the smart perception control module can decrypt the encrypted TOF RAW image and RGB image based on the secret key.
[0333] Optionally, after the smart perception TA obtains the first image data from the secure memory according to the file descriptor, it can also determine the first eye movement data according to the first image data, and send the first eye movement data to the smart perception control module.
[0334] In some embodiments, the electronic device further includes a kernel layer; the HAL layer further includes a camera hardware abstraction layer HAL, the camera HAL includes a sensor node, the kernel layer further includes a camera driver, the hardware layer further includes at least one image sensor and a corresponding register, at least one image sensor is set in one or more cameras, and when the electronic device collects the first image data through the target image sensor, the sensor node can be controlled to obtain the identification and configuration parameters of the target image sensor to be controlled. The sensor node sends the identification and configuration parameters of the target image sensor to the camera driver. The camera driver configures the configuration data of the target image sensor in the register of the target image sensor according to the identification of the target image sensor. The camera driver sends a message of data configuration completion to the sensor node. The sensor node sends a first startup command to the camera driver according to the message of data configuration completion. The camera driver sends a second startup command to the target image sensor, and the target image sensor obtains the configuration parameters of the target image sensor from the register according to the second startup command, and collects image data based on the configuration parameters.
[0335] In some embodiments, the electronic device also includes an application layer and a framework layer; the application layer includes a system user interface UI, and the framework layer includes an intelligent perception service.
[0336] After displaying the first interface, the electronic device can control the system UI to send a smart perception registration request to the smart perception service, and the smart perception registration request is used to start the eye movement recognition or eye movement calibration process. Based on the smart perception registration request, the smart perception service sends a smart perception process call request to the smart perception control module; the smart perception process call request includes the identification and configuration parameters of the target image sensor; the smart perception control module creates a path to the target image sensor according to the identification and configuration parameters of the target image sensor.
[0337] In some embodiments, the framework layer also includes a camera service. The electronic device can create a path for the target image sensor through the following process. Specifically, the camera service receives a path creation request for the target image sensor sent by the smart perception control module, and the path creation request includes the identifier and configuration parameters of the target image sensor. The camera service sends the identifier and configuration parameters of the target image sensor to the camera HAL; the camera HAL creates the path of the target image sensor based on the identifier of the target image sensor; the camera HAL returns the result of successful path creation of the target image sensor to the camera service; the camera service returns the result of path creation of the target image sensor to the smart perception control module based on the received result of successful path creation of the target image sensor.
[0338] In some embodiments, when the electronic device controls the intelligent perception control module to obtain a file descriptor, it can control the intelligent perception control module to send a data request to the camera service, and the data request is used to obtain the file descriptor; the camera service calls the camera HAL to obtain the file descriptor based on the data request; the camera service sends the file descriptor to the intelligent perception control module.
[0339] Combination of the above Figure 5-Figure 18 The message processing method provided by the embodiment of the present application is described in detail. Fig.19 The electronic device provided by the embodiments of the present application is described in detail.
[0340] In one possible design, Fig.19 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. Fig.19 As shown, the electronic device 100 may include: a display unit 1901 and a processing unit 1902. The electronic device 100 may be used to implement the functions of the electronic device involved in the above method embodiment.
[0341] Optionally, the display unit 1901 is used to support the electronic device 100 to display interface content; and / or to support the electronic device 100 to execute Fig. 9 S920 in the , and Fig.17 S1701 and S1704 in the table.
[0342] Optionally, the processing unit 1902 is used to support the electronic device 100 to execute Fig. 9 S901-S919, Fig.13 S1301-S1319 in, and Fig.17 S1703 in.
[0343] Optionally, Fig.19 The electronic device 100 shown may also include a storage unit ( Fig.19 (not shown), the storage unit stores a program or instruction. When the processing unit 1902 executes the program or instruction, Fig.19 The electronic device 100 shown can execute the message processing method described in the above method embodiment.
[0344] Fig.19 The technical effects of the electronic device 100 shown can refer to the technical effects of the message processing method described in the above method embodiment, which will not be repeated here.
[0345] In addition to being in the form of the electronic device 100, the technical solution provided by the present application may also be a functional unit or chip in the electronic device, or a device used in conjunction with the electronic device.
[0346] An embodiment of the present application also provides a readable storage medium, which includes computer instructions. When the computer instructions are executed on the above-mentioned electronic device, the electronic device executes each function or step in the above-mentioned method embodiment.
[0347] The embodiment of the present application also provides a computer program product, including a computer program. When the computer program runs on an electronic device, the electronic device executes each function or step in the above method embodiment.
[0348] Through the description of the above implementation methods, technical personnel in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example. In actual applications, the above-mentioned functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.
[0349] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0350] The units described as separate components may or may not be physically separated, and the components shown as units may be one physical unit or multiple physical units, that is, they may be located in one place or distributed in multiple different places. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.
[0351] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0352] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solution of the embodiment of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium, including several instructions to enable a device (which can be a single-chip microcomputer, chip, etc.) or a processor (processor) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store program code.
[0353] The above contents are only specific implementation methods of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions within the technical scope disclosed in the present application shall be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.
Claims
1. A message processing method, characterized in that: Used in electronic equipment, The electronic device comprises: a hardware abstraction HAL layer and a hardware layer; The hardware abstraction HAL layer includes an intelligent perception control module and an intelligent perception trusted application program, the hardware layer includes a secure memory, the secure memory is used to store image data collected by the target image sensor, and the image data includes first image data; The smart perception trusted application runs in a trusted execution environment; The method comprises: Displaying a first interface, wherein the first interface includes a notification message; The first image data is collected by the target image sensor; the first image data includes an eye image of the user; Determining first eye movement data of the user based on the first image data of the user; the first eye movement data includes first gaze point coordinates and first gaze duration; Wherein, determining the first eye movement data of the user based on the first image data of the user includes: The intelligent perception control module obtains a file descriptor, where the file descriptor is used to describe a storage location of the first image data in the electronic device; The smart perception trusted application obtains the first image data from the secure memory according to the file descriptor; The smart perception trusted application encrypts the first image data and sends the encrypted first image data to the smart perception control module; The intelligent perception control module decrypts the encrypted first image data, and determines the first eye movement data according to the decrypted first image data; or the smart perception trusted application determines the first eye movement data according to the unencrypted first image data, and sends the first eye movement data to the smart perception control module; In response to the first gaze point coordinates being within the display area of the notification message and the first gaze duration being greater than a first preset duration threshold, a second interface is displayed, where the second interface is a display interface of an application corresponding to the notification message.
2. The method according to claim 1, characterized in that: The displaying of the first interface includes: Displaying a third interface, wherein the third interface includes a long notification message in a folded state; the number of characters in the long notification message is greater than a preset character threshold; Collecting second image data by using a target image sensor; the second image data includes an eye image of a user; Determine second eye movement data of the user based on the second image data; the second eye movement data includes second gaze point coordinates and second gaze duration; In response to the second gaze point coordinates being located within the display area of the long notification message and the second gaze duration being greater than a second preset duration threshold, a first interface is displayed, wherein the first interface includes the long notification message in an expanded state.
3. The method according to claim 2, characterized in that After displaying the first interface, the method further includes: Collecting third image data by using a target image sensor; the third image data includes an eye image of a user; Determine third eye movement data of the user based on the third image data; the third eye movement data includes third gaze point coordinates and third gaze duration; In response to the third gaze point coordinates being located outside the display area of the long notification message in the folded state in the first interface, a fourth interface is displayed, wherein the fourth interface includes the long notification message in the folded state, or the fourth interface does not include the long notification message in the folded state.
4. The method according to claim 1, characterized in that: The method further comprises: In response to the first gaze point coordinates being outside the display area of the notification message, a fifth interface is displayed after a first preset time period, and the fifth interface does not include the notification message.
5. The method according to any one of claims 1 to 4, characterized in that The electronic device includes a time-of-flight TOF image sensor and an RGB image sensor; The collecting of first image data by using a target image sensor includes: Get the current ambient light brightness; In response to the current ambient light brightness being greater than a first preset brightness threshold, controlling the RGB image sensor to collect first RGB image data; In response to the current ambient light brightness being less than or equal to a first preset brightness threshold, the TOF image sensor is controlled to collect first TOF image data.
6. The method according to claim 5, characterized in that After controlling the RGB image sensor to collect first RGB image data in response to the current ambient light brightness being greater than a first preset brightness threshold, the method further includes: If it is determined based on the first RGB image data that the user's eyes are not covered by reflective objects, the RGB image sensor is controlled to be turned off, and the TOF image sensor is controlled to be turned on to collect the first image data.
7. The method according to claim 1, characterized in that The electronic device includes a time-of-flight TOF image sensor and an RGB image sensor; The collecting of first image data by using a target image sensor includes: Control the RGB image sensor to collect first RGB image data and the TOF image sensor to collect first TOF image data; If it is determined based on the first RGB image data and / or the first TOF image data that the user's eyes are covered by a reflective object, obtaining the current ambient light brightness; In response to the current ambient light brightness being greater than a first preset brightness threshold, the TOF image sensor is controlled to be turned off.
8. The method according to any one of claims 1 to 4, characterized in that The method further comprises: displaying a sixth interface, wherein the sixth interface includes at least one calibration position; collecting fourth image data by means of a target image sensor; Determine the coordinates of a fourth gaze point of the user based on the fourth image data; An eye movement calibration result is determined based on the coordinates of the calibration position and the error between the coordinates of the fourth gaze point.
9. The method according to claim 8, characterized in that The electronic device includes a time-of-flight TOF image sensor and an RGB image sensor; The collecting the fourth image data by the target image sensor includes: The TOF image sensor is controlled to collect second TOF image data, and the RGB image sensor is controlled to collect second RGB image data.
10. The method according to claim 7 or 9, characterized in that: The electronic device includes a time-of-flight TOF image sensor and an RGB image sensor; the TOF image sensor is connected to the RGB image sensor via a connecting line; the connecting line is used to transmit a synchronization signal so that the TOF image sensor and the RGB image sensor synchronously collect image data based on the synchronization signal.
11. The method according to claim 1, characterized in that: The electronic device further comprises a core layer; The hardware abstraction HAL layer also includes a camera HAL, the camera HAL includes a sensor node, the kernel layer also includes a camera driver, the hardware layer also includes at least one image sensor and corresponding registers, and the at least one image sensor is set in one or more cameras; The collecting of first image data by using a target image sensor includes: The sensor node obtains the identification and configuration parameters of the target image sensor to be controlled; The sensor node sends the identification and configuration parameters of the target image sensor to the camera driver; The camera driver configures the configuration data of the target image sensor in a register of the target image sensor according to the identifier of the target image sensor; The camera driver sends a message that data configuration is completed to the sensor node; The sensor node sends a first start command to the camera driver according to the message that the data configuration is completed; The camera driver sends a second start command to the target image sensor; The target image sensor obtains configuration parameters of the target image sensor from a register according to the second start command, and collects image data based on the configuration parameters.
12. The method according to claim 11, characterized in that The electronic device also includes an application layer and a framework layer; The application layer includes the system user interface UI, and the framework layer includes the intelligent perception service; After displaying the first interface, the method further includes: The system user interface UI sends a smart perception registration request to the smart perception service; the smart perception registration request is used to start an eye movement recognition or eye movement calibration process; The smart perception service sends a smart perception process call request to the smart perception control module based on the smart perception registration request; the smart perception process call request includes an identifier and configuration parameters of a target image sensor; The intelligent perception control module creates a path for the target image sensor according to the identification and configuration parameters of the target image sensor.
13. The method according to claim 12, characterized in that The framework layer also includes a camera service; The path of creating the target image sensor comprises: The camera service receives a path creation request of a target image sensor sent by the intelligent perception control module; the path creation request includes an identifier and configuration parameters of the target image sensor; The camera service sends the identification and configuration parameters of the target image sensor to the camera HAL; The camera HAL creates a path to the target image sensor based on the identifier of the target image sensor; The camera HAL returns a result indicating that the path to the target image sensor is successfully created to the camera service; The camera service returns the path creation result of the target image sensor to the smart perception control module based on the received path creation result of the target image sensor.
14. The method according to claim 13, characterized in that The intelligent perception control module obtains the file descriptor, including: The smart perception control module sends a data request to the camera service, where the data request is used to obtain a file descriptor; The camera service calls the camera HAL to obtain the file descriptor according to the data request; The camera service sends the file descriptor to the smart perception control module.
15. An electronic device, characterized in that: The electronic device includes a display screen, an image sensor, a memory and one or more processors; the display screen, the image sensor, the memory and the processor are coupled; the display screen is used to display an image generated by the processor, the image sensor is used to collect image data, and the memory is used to store computer program code, and the computer program code includes computer instructions; when the processor executes the computer instructions, the electronic device executes the method described in any one of claims 1 to 14.
16. A readable storage medium, characterized in that: The method comprises computer instructions, which, when executed on an electronic device, cause the electronic device to execute the method as claimed in any one of claims 1 to 14.
Citation Information
Patent Citations
Information processing method and mobile terminal
CN107608514A
Gaze information control operation realization method and device
CN110174937A
Eye movement detection method, eye movement detection device, equipment and storage medium
CN111685724A