Method for controlling screen-off display, electronic device and storage medium

By introducing the hardware synthesis module HWC into the processor of the electronic device, the display is notified in advance to be powered on and the display power-on process and the screen-off display processing process are executed in parallel, which solves the problem of long screen-off display in the screen-off state and improves user experience.

CN117707319BActive Publication Date: 2024-10-15HONOR DEVICE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310804587.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-06-30
Publication Date
2024-10-15
Estimated Expiration
2043-06-30

AI Technical Summary

Technical Problem

In the existing technology, when an electronic device touches the screen in the screen-off state, the screen-off display takes a long time, resulting in poor user experience.

Method used

By introducing the hardware synthesis module HWC into the processor, touch screen events directly notify the display to power on and initialize in advance, and execute the display power-on process and screen-off display processing process in parallel, shortening the overall time-consuming of screen-off display.

Benefits of technology

The time-consuming screen-off display is significantly reduced, making the screen-off display faster and improving the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117707319B_ABST
    Figure CN117707319B_ABST
Patent Text Reader

Abstract

The present application provides a method, electronic device and storage medium for controlling off-screen display, and relates to the field of display technology. When the display screen is in the off-screen state and a touch screen event occurs, the touch screen event in the off-screen state is passed to the HWC, and the HWC immediately notifies the display screen to start powering on and initializing in advance; at the same time, the AOD application will start the off-screen display process and send an AOD start instruction to the HWC. When the HWC receives the AOD start instruction, the HWC determines whether the display screen has completed power-on and initialization. If completed, the AOD will send the AOD pattern and AOD backlight parameters to the display screen, and then the display screen completes the off-screen display based on the AOD pattern and AOD backlight parameters. The present application greatly reduces the overall time consumption of the off-screen display process by implementing the display screen power-on process and the off-screen display processing process in parallel, making the off-screen display faster and improving the user experience.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of communication technology, and in particular to a method for controlling screen-off display, an electronic device, and a storage medium. Background Art

[0002] With the rapid development of electronic technology, electronic devices such as smart phones and tablets have more and more functions and have become indispensable tools in people's lives and work. Taking mobile phones as an example, users often turn on the screen of their mobile phones to check time, notifications and other information. In order to facilitate users to check basic information such as time and save power of electronic devices, the always on display (AOD) function of electronic devices came into being.

[0003] The implementation principle of the AOD function is: after the screen of the electronic device is turned off, some pixels of the screen can be lit up to display information such as clock, date, battery level, message reminders, etc., while other pixels of the screen are always in a closed state, for example, these closed pixels appear black, so that users can conveniently view the above information without lighting up the entire screen of the electronic device, and can reduce the power consumption of the electronic device.

[0004] Currently, when an electronic device is in the screen-off state, it takes a long time for the AOD pattern to be displayed after the user touches the screen. In other words, the screen-off display process in the screen-off state in the related art is time-consuming. Summary of the invention

[0005] The present application provides a method for controlling the off-screen display, an electronic device, and a storage medium. In a scenario where the screen is touched in the off-screen state, the off-screen display processing flow and the display screen power-on flow are executed simultaneously, thereby shortening the off-screen display time and improving the user experience.

[0006] In a first aspect, the present application provides a method for controlling an off-screen display, the method being applied to an electronic device, the electronic device comprising a processor and a display screen, the processor comprising an off-screen display AOD application, a display driver, and a hardware synthesis module HWC, the method comprising:

[0007] When the display screen is in the off state, the HWC receives a touch screen event; in response to the touch screen event, the HWC triggers the display screen to power on and initialize; the HWC receives an AOD startup instruction from the AOD application; in response to the AOD startup instruction, the HWC determines whether the display screen has completed powering on and initialization;

[0008] If the display screen has completed power-on and initialization, the HWC returns a completion message to the AOD application; or, if the display screen has not completed power-on and initialization, the HWC waits until the display screen has completed power-on and initialization and returns a completion message to the AOD application;

[0009] The HWC receives the AOD pattern from the AOD application and transmits the AOD pattern to the display screen; the HWC receives the AOD backlight parameters from the AOD application and sends the AOD pattern to the display screen, so as to trigger the display screen to turn on the backlight and display the AOD pattern based on the AOD backlight parameters.

[0010] Through the method for controlling the off-screen display provided by the embodiment of the present application, when the display screen is in the off-screen state and a touch screen event occurs, the touch screen event in the off-screen state is passed to the HWC, and the HWC immediately notifies the display screen to start powering on and initializing in advance; at the same time, the AOD application will start the off-screen display process and send an AOD start instruction to the HWC. When the HWC receives the AOD start instruction, the HWC determines whether the display screen has completed power-on and initialization. If completed, the AOD will send the AOD pattern and AOD backlight parameters to the display screen, and then the display screen completes the off-screen display based on the AOD pattern and AOD backlight parameters. The present application greatly reduces the overall time consumption of the off-screen display process by implementing the display screen power-on process and the off-screen display processing process in parallel, making the off-screen display faster and improving the user experience.

[0011] The display screen power-on process may include triggering the display screen power-on through a touch screen event, and the display screen power-on and initialization process. The screen-off display processing process includes triggering the AOD application to start the AOD service through a touch screen event, the AOD application sending the AOD start instruction, sending the AOD pattern, and sending the AOD backlight parameters.

[0012] In some possible implementations, the processor further includes a touch screen driver. The touch screen event is transmitted from the touch sensor of the display screen to the touch screen driver, which is then transmitted from the touch screen driver to the display driver, and then transmitted from the display driver to the HWC.

[0013] In some possible implementations, the processor further includes a display HAL. The touch screen event is transmitted from the touch sensor of the display screen to the touch screen driver, then from the touch screen driver to the display driver, then from the display driver to the display HAL, and then from the display HAL to the HWC.

[0014] In some possible implementations, the processor further includes an input subsystem. The touch screen event is transmitted from the touch sensor of the display screen to the touch screen driver, then transmitted from the touch screen driver to the input subsystem, and then transmitted from the input subsystem to the AOD application. The AOD startup instruction is triggered when the AOD application receives the touch screen event.

[0015] In some possible implementations, the time when the touch screen event is delivered to the HWC is earlier than or equal to the time when the touch screen event is delivered to the AOD application.

[0016] In the related technology, when the display screen is in the off state, if the touch screen driver receives a touch screen event, the touch screen driver will pass the touch screen event in the off state to the input subsystem, and then the input subsystem will pass the touch screen event to the AOD application, and the AOD application will start the off-screen display process, and then the display driver will trigger the display screen to power on and initialize. After completing the power-on and initialization, the display driver will trigger the display screen to display the AOD pattern to achieve off-screen display.

[0017] Compared with the related art, the improvement of the present application lies in that: after the touch screen driver senses the touch screen event in the off-screen state, the touch screen driver transmits the touch screen event to the HWC through the display driver and the display HAL, or transmits the touch screen event directly to the HWC through the display driver to trigger the HWC to execute the display screen power-on process. At the same time, the touch screen driver transmits the touch screen event in the off-screen state to the input subsystem, and then the input subsystem transmits the touch screen event in the off-screen state to the AOD application to start the off-screen display process.

[0018] That is to say, after the touch screen driver senses a touch screen event in the off-screen state, the touch screen driver immediately notifies the HWC to execute the display power-on process, and at the same time notifies the AOD application to start the off-screen display process.

[0019] Compared with the related art, the HWC executes the display screen power-on process in advance in the screen-off display process of this application. It can be understood that before starting the screen-off display process, the HWC has already started to execute the display screen power-on process, and after starting the screen-off display, the display screen power-on process has been completed or is about to be completed. When the HWC receives the AOD start instruction sent by the AOD, the HWC will first determine whether the display screen has completed power-on. If the display screen has completed power-on, the HWC returns a completion message to the AOD application to trigger the AOD application to send the AOD pattern and AOD backlight parameters; if the display screen has not completed power-on, the HWC waits until the display screen has completed power-on, and the HWC returns a completion message to the AOD application.

[0020] This has the beneficial effect that the display screen power-on process and the screen-off display processing process are executed simultaneously, which significantly shortens the screen-off display time.

[0021] In some possible implementations, the HWC triggers the display screen to power on and initialize, including: the HWC sends a power-on indication message to the display driver, so that the display driver triggers the display screen to power on and initialize. Wherein, the display driver triggers the display screen to initialize, including: the display driver sends a 11 instruction to the display screen to trigger the display screen to start initialization; after a preset time, the display driver sends a 29 instruction to the display screen to instruct the display screen to complete initialization.

[0022] It should be noted that the protocol stipulates that it takes a preset time (recorded as T1) for the display screen to be powered on and initialized. That is to say, after the preset time T1, the display screen is initialized and ready to execute the display task issued by the display driver. In other words, the display driver needs to wait for the preset time T1, that is, until the display screen is initialized, before returning a completion message to the upper layer to further complete the screen off display.

[0023] In some possible implementations, after the HWC triggers the initialization of the display screen, the method further includes: after a preset period of time, the HWC receives a completion message returned by the display driver, the completion message being used to indicate that the display screen has completed power-on and initialization; the HWC passes the completion message to the AOD application to trigger the AOD application to send the AOD pattern.

[0024] Compared with the related art, the present application executes the display screen power-on process in advance, and the display driver will determine whether the display screen has completed power-on and initialization when receiving the AOD backlight parameters.

[0025] If the display screen completes initialization, the HWC returns a completion message to the AOD application to trigger the AOD application to send the AOD pattern.

[0026] If the display screen has not completed initialization, the HWC waits until the display screen has completed initialization, and then the HWC returns a completion message to the AOD application to trigger the AOD application to send the AOD pattern and AOD backlight parameters. Accordingly, the display screen can use the AOD backlight parameters to turn on the backlight and display the AOD pattern.

[0027] It can be seen from the analysis that compared with the related technical process, the present application solution has already started the display screen power-on process before starting the screen-off display process, and after starting the screen-off display process, the display screen power-on process has been completed or is about to be completed. In this way, by executing the screen-off display processing process and the display screen power-on process in parallel, the time consumed for the screen-off display is significantly shortened.

[0028] In actual implementation, based on the hardware requirements of the screen IC chip specifications, it takes about 120ms to power on and initialize the display screen, and the software takes about 150ms to process the off-screen display process, so the AOD overall process takes a minimum of about 270ms. Through the present application scheme, since the display screen power-on process and the off-screen display processing process can be executed in parallel, for example, when the off-screen display process is implemented in the off-screen state, 80ms to 100ms can be saved, and the overall time consumption is significantly shortened. Therefore, when the user touches the display screen in the off-screen state, the off-screen display becomes faster, which improves the user experience.

[0029] In some possible implementations, in response to the touch screen event, the HWC triggers the display screen to power on and initialize, including: when the touch screen event meets the screen off display trigger condition, in response to the touch screen event, the HWC triggers the display screen to power on and initialize.

[0030] In some possible implementations, the screen-off display triggering condition includes: the electronic device has turned on the screen-off display function, the display screen is in the screen-off state, and the user input operation is a preset touch screen operation.

[0031] In some possible implementations, the preset touch screen operation is an operation of lightly touching or clicking the display screen.

[0032] If the touch screen event meets the screen off display triggering condition, it means that the touch screen event will trigger the screen off display. This ensures that the current scene is a scene where the user input operation triggers the screen off display.

[0033] It should be noted that the touch screen driver may determine whether the touch screen event satisfies the screen off display triggering condition; the HWC may also determine whether the touch screen event satisfies the screen off display triggering condition.

[0034] In some possible implementations, the processor further includes a power management service module and a surface drawing SurfaceFlinger service module.

[0035] Among them, the AOD startup instruction is issued by the AOD application, passes through the power management service module and the SurfaceFlinger service module, and reaches the HWC.

[0036] The AOD pattern is sent by the AOD application, passed through the power management service module, the SurfaceFlinger service module and the HWC, and reaches the display driver; then the display driver sends the AOD pattern to the display screen. In some embodiments, the processor may also include a drawing module, which is used to draw the AOD pattern, and the AOD application can obtain the AOD pattern from the drawing module.

[0037] Among them, the AOD backlight parameters are sent by the AOD application, passed through the power management service module, the SurfaceFlinger service module and the HWC, and reach the display driver; then the display driver sends the AOD backlight parameters to the display screen. In some embodiments, the processor may also include a backlight module, which is used to collect backlight parameters, and the AOD application can obtain the AOD backlight parameters from the backlight module.

[0038] The beneficial effect of the present application solution is that before starting the off-screen display process, the display driver has already started to execute the display screen power-on process, and after starting the off-screen display process, the display driver has completed the power-on process or is about to complete the power-on process. In this way, the display screen power-on process and the off-screen display processing process are executed simultaneously, which significantly shortens the time consumed for off-screen display.

[0039] In another possible implementation, when the touch screen driver receives a touch screen event in the screen-off state, the touch screen driver immediately notifies the HWC to execute the display power-on process, so that the display starts to power on in advance, and the power-on time is approximately in the range of [20ms, 50ms]. At the same time, the touch screen driver passes the touch screen event in the screen-off state to the AOD application, and the AOD application starts the screen-off display process: the AOD application sends an AOD startup instruction to the display, and the AOD startup instruction can carry the display initialization parameters. When the display receives the display initialization parameters, since the display has completed power-on in advance, the display can quickly enter initialization, which can also save a certain amount of time and make the screen-off display faster.

[0040] In a second aspect, the present application provides a device for controlling off-screen display, the device comprising a unit for executing the method in the first aspect. The device may correspond to executing the method described in the first aspect, and the relevant description of the unit in the device can refer to the description of the first aspect, which will not be repeated here for the sake of brevity.

[0041] The method described in the first aspect above can be implemented by hardware, or by hardware executing corresponding software. The hardware or software includes one or more modules or units corresponding to the above functions. For example, a processing module or unit, a display module or unit, etc.

[0042] In a third aspect, the present application provides an electronic device comprising a display screen, a processor, a computer program or instructions stored in the processor and a memory, wherein the processor is used to execute the computer program or instructions so that the method in the first aspect is executed.

[0043] In a fourth aspect, the present application provides a computer-readable storage medium on which a computer program (also referred to as instructions or codes) for implementing the method in the first aspect is stored. For example, when the computer program is executed by a computer, the computer can perform the method in the first aspect.

[0044] In a fifth aspect, the present application provides a chip, including a processor. The processor is used to read and execute a computer program stored in a memory to perform the method in the first aspect and any possible implementation thereof. Optionally, the chip also includes a memory, and the memory is connected to the processor via a circuit or wire.

[0045] In a sixth aspect, the present application provides a chip system, including a processor. The processor is used to read and execute a computer program stored in a memory to perform the method in the first aspect and any possible implementation thereof. Optionally, the chip system also includes a memory, and the memory is connected to the processor via a circuit or wire.

[0046] In a seventh aspect, the present application provides a computer program product, which includes a computer program (also referred to as instructions or codes). When the computer program is executed by an electronic device, the electronic device implements the method in the first aspect.

[0047] It can be understood that the beneficial effects of the second to seventh aspects mentioned above can be found in the relevant description of the first aspect mentioned above, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0048] Figure 1 A schematic diagram of an application scenario of the method for controlling screen-off display provided in an embodiment of the present application;

[0049] Figure 2 A schematic diagram of a screen-off display process in a method for controlling screen-off display provided in an embodiment of the present application;

[0050] Figure 3 A schematic diagram comparing the method for controlling screen-off display provided in an embodiment of the present application with related technologies;

[0051] Figure 4 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application;

[0052] Figure 5 A schematic diagram of a software architecture of an electronic device provided in an embodiment of the present application;

[0053] Figure 6 A flowchart of a method for controlling screen-off display provided for related technologies;

[0054] Figure 7 A timing diagram of a method for controlling screen-off display provided in the related art;

[0055] Figure 8 A schematic diagram of the time consumption of a method for controlling screen-off display provided in the related art;

[0056] Fig. 9 A flowchart of a method for controlling screen-off display provided in an embodiment of the present application;

[0057] Fig.10 A timing diagram of a method for controlling screen-off display provided in an embodiment of the present application;

[0058] Fig.11 A flowchart of a method for controlling screen-off display provided in an embodiment of the present application;

[0059] Fig.12 A timing diagram of a method for controlling screen-off display provided in an embodiment of the present application;

[0060] Fig.13 A schematic diagram of the time consumption of the method for controlling the screen off display provided in an embodiment of the present application. DETAILED DESCRIPTION

[0061] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0062] The term "and / or" in this article is a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. The symbol " / " in this article indicates that the associated objects are in an or relationship, for example, A / B means A or B.

[0063] The terms "first" and "second" in the specification and claims herein are used to distinguish different objects rather than to describe a specific order of objects. In the description of the embodiments of the present application, unless otherwise specified, the meaning of "multiple" refers to two or more than two, for example, multiple processing units refer to two or more processing units, etc.; multiple elements refer to two or more elements, etc.

[0064] In the embodiments of the present application, words such as "exemplary" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design described as "exemplary" or "for example" in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way.

[0065] With the rapid development of electronic technology, electronic devices such as smartphones and tablets have more and more functions and have become indispensable tools in people's lives and work. Taking mobile phones as an example, users often turn on the screen of their mobile phones to check the time, notifications and other information. In order to facilitate users to check basic information such as time and save power of electronic devices, the screen-off display function of electronic devices came into being.

[0066] The principle of the off-screen display function is that after the electronic device turns off the screen, some pixels of the screen can be lit up to display information such as the clock, date, battery level, and message reminders, while other pixels of the screen are always in an off state, for example, these off pixels appear black, so that users can conveniently view the above information without lighting up the entire screen of the electronic device, and the power consumption of the electronic device can be reduced. Electronic devices usually turn on the off-screen display function by default.

[0067] Electronic devices can support the following two scenarios for triggering screen-off display:

[0068] Scenario 1: The screen turns off after a timeout or by pressing the power button.

[0069] like Figure 1 As shown in (a) in the figure, when the electronic device changes from the on screen to the off screen, the off screen display will be automatically triggered, that is, some pixels on the screen will be lit up to display the AOD pattern. For example, the AOD pattern includes information such as clock, date, and notification, which is convenient for users to view the above commonly used information and can reduce the power consumption of the electronic device. Then, after the AOD pattern is displayed for a period of time (5 seconds), the AOD pattern will automatically disappear.

[0070] Scenario 2: Touch the screen lightly when the screen is off to trigger the screen off display.

[0071] like Figure 1 As shown in (b) in the figure, when the electronic device is in the off-screen state, if the user touches or clicks the display screen, the off-screen display will be triggered, that is, a local area of ​​the screen will be lit up and the AOD pattern will be displayed. Then, after a period of time (5 seconds), the AOD pattern disappears automatically. This method of touching or clicking the screen in the off-screen state to trigger the off-screen display can be called "touch mode".

[0072] At present, for the above scenario 2, it takes a long time for the electronic device to realize the off-screen display in the off-screen state, and there is a problem of too long delay in the off-screen display. It should be noted that the embodiment of the present application mainly studies and improves the problem of too long delay in the off-screen display in the above scenario 2.

[0073] The inventors of the present application have discovered that the reasons why the screen-off display takes a long time in the current screen-off state mainly include: based on the hardware requirements of the screen IC chip specifications, it takes about 120ms to power on and initialize the display screen, and the software takes about 150ms to process the screen-off display process, so the overall screen-off display process takes a minimum of about 270ms. This will cause the screen-off display to take a long time, and therefore will give users a feeling that "the screen-off display is slow".

[0074] In order to solve the problem of slow display when the screen is off, an embodiment of the present application provides a method for controlling the display when the screen is off. When the display screen is in the off state and a touch screen event occurs, the touch screen event in the off state is passed to the HWC, and the HWC immediately notifies the display screen to start powering on and initializing in advance; at the same time, the AOD application will start the off-screen display process and send an AOD start instruction to the HWC. When the HWC receives the AOD start instruction, the HWC determines whether the display screen has completed power-on and initialization. If completed, the AOD will send the AOD pattern and AOD backlight parameters to the display screen, and then the display screen completes the off-screen display based on the AOD pattern and AOD backlight parameters. The present application greatly reduces the overall time consumption of the off-screen display process by implementing the display screen power-on process and the off-screen display processing process in parallel, making the off-screen display faster and improving the user experience.

[0075] Figure 2 Schematic diagram showing the state change of the display screen during the screen off display process. Figure 2 As shown, the display screen is in the off state. When the electronic device receives a touch screen event, the off screen display process is started. The display screen is first powered on and initialized, and then the display screen displays the AOD pattern to achieve off screen display. The protocol stipulates that it takes a preset time (recorded as T1) to power on and initialize the display screen. In other words, after the preset time T1, the display screen completes initialization and is ready to execute the display task issued by the display driver.

[0076] It should be noted that the display screen needs a preset time T1 to complete the initialization. After the preset time T1, the display driver will return a completion message to the upper-level AOD application to further trigger the AOD application to send the AOD pattern and AOD backlight parameters. Exemplarily, the preset time T1 can be 120ms. The preset time length is for illustrative purposes only and can be set according to actual usage requirements, and is not limited in the embodiments of the present application.

[0077] In an embodiment of the present application, the screen-off display process will involve an AOD start instruction. The AOD start instruction is used to trigger the start of the screen-off display process, that is, the display driver controls the display screen to be powered on and initialized, and then the AOD application sends the AOD pattern to the display screen, and then the AOD application sends the AOD backlight parameters to the display screen. Among them, "display screen power-on and initialization" specifically controls the display screen IC (also called display driver integrated chip) to be powered on and initialized. It can be understood that when the display screen IC is in a powered-on state, the display screen IC can control the display screen to turn on the backlight and display the AOD pattern according to the AOD backlight parameters.

[0078] In order to better understand the embodiments of the present application, Figure 3 The embodiments of the present application are briefly described in comparison with the related art:

[0079] Figure 3 (a) in FIG. 1 shows the screen-off display process in the screen-off state provided by the related art. Figure 3 As shown in (a), when a touch screen event occurs in the screen-off state, the AOD application is first notified of the touch screen event in the screen-off state, and then the AOD application starts the screen-off display process. Next, the display screen is powered on first, and then the AOD pattern is displayed to achieve the screen-off display.

[0080] Figure 3 (b) in FIG. 1 shows the screen-off display process in the screen-off state provided by the present application. Figure 3 As shown in (b), when a touch screen event occurs in the off-screen state, the HWC is immediately notified to execute the display screen power-on process, and the AOD application is notified to start the off-screen display process. In this way, the display screen power-on process and the off-screen display processing process are executed in parallel to complete the off-screen display.

[0081] Compared with the related art, the improvement of the present application lies in that: after the touch screen driver senses the touch screen event in the off-screen state, the touch screen driver transmits the touch screen event to the HWC through the display driver and the display HAL, or transmits the touch screen event directly to the HWC through the display driver to trigger the HWC to execute the display screen power-on process. At the same time, the touch screen driver transmits the touch screen event in the off-screen state to the input subsystem, and then the input subsystem transmits the touch screen event in the off-screen state to the AOD application to start the off-screen display process.

[0082] That is to say, after the touch screen driver senses a touch screen event in the off-screen state, the touch screen driver immediately notifies the HWC to execute the display power-on process, and at the same time notifies the AOD application to start the off-screen display process.

[0083] Compared with the related art, the HWC executes the display screen power-on process in advance in the screen-off display process of this application. It can be understood that before starting the screen-off display process, the HWC has already started to execute the display screen power-on process, and after starting the screen-off display, the display screen power-on process has been completed or is about to be completed. When the HWC receives the AOD start instruction sent by the AOD, the HWC will first determine whether the display screen has completed power-on. If the display screen has completed power-on, the HWC returns a completion message to the AOD application to trigger the AOD application to send the AOD pattern and AOD backlight parameters; if the display screen has not completed power-on, the HWC waits until the display screen has completed power-on, and the HWC returns a completion message to the AOD application.

[0084] This has the beneficial effect that the display screen power-on process and the screen-off display processing process are executed simultaneously, which significantly shortens the screen-off display time.

[0085] It should be noted that the electronic device described in this application is an electronic device with a display screen and a screen-off display function. For example, the electronic device can be a smart terminal such as a mobile phone, a tablet computer, a smart watch, etc. The specific technology and specific device form used by the electronic device are not limited here. For the convenience of description, the subsequent embodiments are all exemplified by the electronic device being a mobile phone.

[0086] See also Figure 4 , is a structural diagram of an electronic device provided in an embodiment of the present application. The electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a touch sensor 180K, an ambient light sensor 180L, and the like.

[0087] The processor 110 may include one or more processing units, for example: the processor 110 may include an application processor (application processor, AP), a modem processor, a graphics processor (graphics processing unit, GPU), an image signal processor (image signal processor, ISP), a controller, a memory, a video codec, a digital signal processor (digital signal processor, DSP), a baseband processor, and / or a neural-network processing unit (neural-network processing unit, NPU), etc. Among them, different processing units can be independent devices or integrated in one or more processors. For example, the processor 110 is used to execute the method for controlling the off-screen display in an embodiment of the present application.

[0088] 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.

[0089] The processor 110 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory may store instructions or data that the processor 110 has just used or cyclically used. If the processor 110 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 110, and thus improves the efficiency of the system.

[0090] The external memory 120 generally refers to an external memory. In the embodiment of the present application, the external memory refers to a memory other than the memory of the electronic device and the cache of the processor, and the memory is generally a non-volatile memory.

[0091] The internal memory 121, which may also be referred to as "memory", may be used to store computer executable program codes, which include instructions. The internal memory 121 may include a program storage area and a data storage area. The program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), and the like.

[0092] The display screen 194 is used to display images, videos, etc. The display screen 194 includes a display panel. The display panel may be an organic light-emitting diode (OLED). In some embodiments, the electronic device 100 may include 1 or N display screens 194, where N is a positive integer greater than 1.

[0093] The touch sensor 180K is also called a "touch panel" or a touch screen sensor. The touch sensor 180K can be set on the display screen 194, and the touch sensor 180K and the display screen 194 form a touch screen, also called a "touch screen". The touch sensor 180K is used to detect a touch operation 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 194.

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

[0095] The button 190 includes a power button, which is used to trigger turning on or off the display screen. For example, when the display screen is in a light-on state, if the user presses the power button, the display screen state changes from the light-on state to the light-off state.

[0096] The above is a specific description of the embodiment of the present application using the electronic device 100 as an example. It should be understood that the structure illustrated in the embodiment of the present application does not constitute a specific limitation on the electronic device 100. The electronic device 100 may have more or fewer components than those shown in the figure, may combine two or more components, or may have different component configurations. The various components shown in the figure may be implemented in hardware, software, or a combination of hardware and software including one or more signal processing and / or application specific integrated circuits.

[0097] In addition, an operating system is running on the above components, such as the iOS operating system developed by Apple, the Android open source operating system developed by Google, and the Windows operating system developed by Microsoft. Application programs can be installed and run on the operating system.

[0098] The operating system of the electronic device 100 may adopt a layered architecture, an event-driven architecture, a micro-kernel architecture, a micro-service architecture, or a cloud architecture. The embodiment of the present application takes the Android system of the layered architecture as an example to exemplify the software structure of the electronic device 100.

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

[0100] The layered architecture divides the software into several layers, each with a clear role and division of labor. The layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into five layers, from top to bottom: application layer (applications), application framework layer (application framework), system Native library (called Native layer), hardware abstraction layer (HAL) and kernel layer (kernel). For ease of explanation, Figure 5 The hardware layer that interacts with the above software structure is also reflected.

[0101] It should be noted that the Android system is a Linux-based operating system, mainly used for portable devices. The development of upper-layer applications (such as the application layer and application framework layer) in the Android system is generally completed based on Java. Since some low-level tasks are not easy to implement in Java, when it comes to tasks such as local services, link libraries or hardware drivers, it is usually necessary to allow C programs to implement them, and C programs run in the system Native library. The system Native library includes an interface for Java to call C++ code.

[0102] The application layer may include a series of application packages. For example, the application layer may include AOD applications and other applications, and the embodiments of the present application do not impose any limitation on this.

[0103] The application framework layer provides an application programming interface (API) and a programming framework for the application programs of the application layer. The application framework layer includes some predefined functions, which are not limited in any way in the embodiments of the present application.

[0104] Exemplarily, the application framework layer may include a power management service (PMS) module, wherein the power management service module is used to manage power on and power off of the display screen.

[0105] Exemplarily, the application framework layer may further include an AOD service module, and the AOD service module is used to provide an off-screen display service for the AOD application.

[0106] Exemplarily, the application framework layer may further include a drawing module. The drawing module is used to provide an AOD pattern for off-screen display.

[0107] The Native layer can include multiple functional modules. For example, in the present application, the Native layer includes a surface drawing (SurfaceFlinger) service module. Among them, the function of the SurfaceFlinger service module is to accept graphic display data from multiple sources, synthesize them, and then send them to the display device. Image display can be specifically completed by multiple classes such as SurfaceFlinger, HWC, display screen, etc.

[0108] In the present application, the Native layer also includes an input subsystem. The input subsystem is one of the important system services in the Android operating system, which is dedicated to processing various external input signals of input devices. Input devices include: display screen, keyboard, mouse, etc. Taking the user input as a touch screen as an example, after the display screen is touched, the corresponding hardware driver (such as the touch screen driver of the kernel layer) will be triggered. After the touch screen driver receives the touch screen event, the touch screen driver will write the touch screen event to the corresponding input device node, and then the input system will read the touch screen event from the device node, and then pass the touch screen event up layer by layer, and pass the touch screen event to the corresponding activity.

[0109] In the present application scheme, the HAL layer may include a hardware composition module (hwcomposer, HWC), which has the function or ability to use hardware to complete image data combination and display, and provide hardware support for the SurfaceFlinger service.

[0110] In the present application, the HAL layer may also include a display HAL, which is used to transmit touch screen events to the HWC to trigger the HWC to execute the display screen power-on process in advance.

[0111] The kernel layer is a layer between hardware and software. Its role is to pass application requests to the hardware. The kernel layer provides the most basic functions of the operating system. Usually, the kernel layer provides system services such as process management, interrupt response, memory management, network and inter-process communication.

[0112] In the present application, the kernel layer includes a display driver. The display driver can be combined with a display integrated circuit or chip (integrated circuit, IC) to jointly control the display function of the display. For example, the display driver and the display IC, in a combination of software and hardware, jointly implement the off-screen display function. The display driver can also be used to set the backlight parameters of the display; wherein, when the backlight parameters of the display are set to 0, the display is in an off-screen state; when the backlight parameters of the display are set to any value in the range of [1, 255], the display is in a bright screen state.

[0113] In the present application, the kernel layer also includes a touch panel (TP) driver. In the present application, the TP driver receives the touch screen event sent by the touch screen sensor of the display screen, and then reports the touch screen event to the input subsystem. Different from the related art, in the present application, in some embodiments, the TP driver also passes the touch screen event to the display driver, which is then passed to the display HAL by the display driver, and then passed to the HWC by the display HAL, to trigger the HWC to execute the display screen power-on process in advance, that is, the HWC notifies the display driver to trigger the display screen to power on and initialize. In other embodiments, the TP driver also passes the touch screen event to the display driver, which is then directly passed to the HWC by the display driver to trigger the HWC to execute the display screen power-on process in advance.

[0114] For the sake of convenience, the process of powering on and initializing the display screen is referred to as the display screen power-on process below.

[0115] The hardware layer may include a display screen (such as OLED or LCD), and the display screen is provided with a display screen IC. The hardware layer also includes a touch screen sensor. When a user clicks or touches on the display screen, the touch screen sensor of the display screen can sense the user's touch screen operation and determine that there is a touch screen event. The touch screen sensor of the display screen can send the touch screen event to the TP driver.

[0116] It should be noted that although the embodiments of the present application are described using the Android system as an example, its basic principles are also applicable to electronic devices based on operating systems such as iOS or Windows.

[0117] The execution subject of the method for controlling the off-screen display provided in the embodiment of the present application can be the above-mentioned electronic device, or it can be a functional module and / or functional entity in the electronic device that can implement the method for controlling the off-screen display, and the present application scheme can be implemented in hardware and / or software, which can be determined according to actual use requirements, and the embodiment of the present application is not limited. The following takes an electronic device as an example, and combines the accompanying drawings to exemplarily illustrate the method for controlling the off-screen display provided in the embodiment of the present application.

[0118] In order to highlight the improvements of the embodiments of the present application over the related art, the following compares the present application scheme with the related art in terms of the off-screen display process, timing diagram, and time consumption in the off-screen state, and explains the improvements. Figures 6 to 8 Describe the screen off display process, timing diagram and time consumption in the related technology, and then combine Figures 9 to 11 , the method for controlling the off-screen display provided in an embodiment of the present application is described in terms of the off-screen display process, timing diagram, and time consumption.

[0119] Related technologies - screen-off display process

[0120] The screen-off display process includes the screen-off display processing process and the display screen power-on process. Among them, the screen-off display processing process includes the process of the AOD application sending the AOD startup instruction, the process of executing based on the AOD startup instruction, and the process of sending the AOD pattern and AOD backlight parameters. The display screen power-on process includes the process of the upper layer notifying the display screen to power on, and the process of powering on and initializing the display screen.

[0121] It should be noted that when the electronic device is in the off-screen state, the display IC is in the off-screen state. After starting the off-screen display process, the AOD application first sends an AOD start command to trigger the display IC to power on, and then sends the AOD pattern and AOD backlight parameters to the display IC, and then the display IC controls the display to complete the off-screen display.

[0122] Figure 6 It is a software architecture diagram of the off-screen display process in the off-screen state in the related technology. Among them, the off-screen display process in the off-screen state can be divided into two stages: the first stage: the touch screen event transmission process, and the second stage: the off-screen display processing process. Among them, the touch screen event transmission process refers to the direction indicated by the dotted arrow, and the off-screen display startup and completion refer to the direction indicated by the solid arrow.

[0123] Phase 1: Touch screen event transmission process

[0124] refer to Figure 6 As shown in ①, when the electronic device is in the screen-off state, if the user clicks or touches the display screen, the TP driver of the electronic device will receive the user's single click or touch operation of the display screen, that is, the TP driver will sense the touch screen event in the screen-off state. The TP driver passes the touch screen event in the screen-off state to the input subsystem, and then the input subsystem passes the touch screen event in the screen-off state to the AOD application.

[0125] Phase 2: Screen-off display processing flow

[0126] After receiving a touch screen event in the screen-off state, the AOD application starts the screen-off display process.

[0127] refer to Figure 6 As shown in ②, the AOD application sends an AOD startup instruction. The AOD startup instruction passes through the power management service module, SurfaceFlinger service module and HWC in the software architecture, and then reaches the display driver. The display driver instructs the display IC to power on. After the display IC is powered on, the display driver returns a completion message to the HWC, and reports the completion message to the AOD application through the HWC. Reference Figure 6As shown in ③, the AOD application sends a screen-off display pattern (referred to as AOD pattern), which is transmitted through the power management service module, SurfaceFlinger service module and HWC in turn, and then reaches the display driver, which is passed to the display IC by the display driver. Then, refer to Figure 6 As shown in ④, the AOD application sends the AOD backlight parameters (which can be referred to as AOD backlight for short), which are transmitted through the power management service module, SurfaceFlinger service module and HWC in turn, and then reach the display driver, which is passed to the display IC by the display driver. The display IC controls the display to complete the off-screen display according to the AOD pattern and AOD backlight parameters.

[0128] pass Figure 6 It can be seen that during the off-screen display process in the off-screen state, according to relevant technologies, the touch screen event in the off-screen state needs to be passed to the AOD application first, and then the AOD application starts the off-screen display process. In the AOD implementation process, it is necessary to trigger the display screen to complete power-on and initialization first, and then the AOD application sends the AOD pattern and AOD backlight parameters to the display screen, so that the display screen completes the off-screen display.

[0129] exist Figure 6 On the basis of Figure 7 The timing diagram of the screen-off display process in the screen-off state in the related art is shown. Figure 7 As shown, the method includes the following steps S101-S115.

[0130] S101, when the display screen is in an off state, the display screen receives a touch screen operation.

[0131] In actual implementation, when a user touches or clicks a display screen, a touch sensor provided on the display screen can sense the user's touch screen operation.

[0132] Among them, the event that the display screen is touched or clicked when it is in the screen-off state can be called a touch screen event in the screen-off state.

[0133] S102, the display screen reports a touch screen event in the screen-off state to the TP driver.

[0134] S103, the TP driver transmits the touch screen event in the screen-off state to the input subsystem.

[0135] S104: The input subsystem transmits the touch screen event in the screen-off state to the AOD application.

[0136] In actual implementation, when the display screen is touched, the corresponding kernel layer TP driver will be triggered. After the TP driver receives the touch screen event, it will write the touch screen event to the corresponding input device node. Then the input system will read the touch screen event from the device node and pass the touch screen event up layer by layer.

[0137] S105, in response to a touch screen event in the screen-off state, the AOD application is started, and triggers the start of the AOD service.

[0138] After the AOD application and AOD service are started, the screen-off display process can be started.

[0139] S106, the AOD application sends an AOD startup instruction to the power management service module. The AOD startup instruction is transparently transmitted through the power management service module and the SurfaceFlinger service module in sequence and reaches the HWC.

[0140] The following S107-S112 illustrate the process of powering on the display screen.

[0141] S107, HWC passes the AOD start instruction to the display driver.

[0142] S108 , in response to the AOD start instruction, the display driver triggers the display screen to power on.

[0143] Specifically, the display driver responds to the AOD startup instruction, triggers the display screen to power on, and then the display driver sends the 11th instruction to the display screen to instruct the display screen IC parameter configuration initialization. When the 11th instruction has been sent, after an interval of 120ms, the display driver sends the 29th instruction to the display screen to instruct the display screen IC to complete the parameter configuration initialization.

[0144] S109, the display screen starts to power on and initialize.

[0145] In actual implementation, the display driver triggers the display screen IC to start powering on and initializing. It is understandable that after the display screen IC is powered on and initialized, the display screen IC is ready to execute the screen-off display task issued by the display driver.

[0146] S110, the display driver starts timing from the moment the display screen is powered on.

[0147] In actual implementation, it usually takes a preset time for the display screen to power on, for example, the preset time may be 120 ms.

[0148] S111, the display driver determines whether the timing duration reaches a preset duration.

[0149] If the timing duration reaches (ie, is greater than or equal to) the preset duration, the following S112 is continued to be executed.

[0150] If the timing duration does not reach (ie is less than) the preset duration, wait until the timing duration reaches the preset duration, and then execute the following S112.

[0151] S112: The display driver returns a completion message to the AOD application.

[0152] The following S113-S115 illustrate the process of the display screen completing the screen-off display.

[0153] S113, the AOD application sends the AOD pattern to the display driver, and the display driver transmits the AOD pattern to the display screen.

[0154] S114, the AOD application sends the AOD backlight parameters to the display driver, and the display driver transmits the AOD backlight parameters to the display screen.

[0155] S115, the display screen turns on the backlight with the AOD backlight parameters and displays the AOD pattern.

[0156] In actual implementation, the display IC controls the display to complete the off-screen display according to the AOD pattern and AOD backlight parameters.

[0157] pass Figure 7 It can be known that during the off-screen display process in the off-screen state, according to relevant technologies, the touch screen event in the off-screen state needs to be passed to the AOD application first, and then the AOD application starts the off-screen display process, and then the display screen is powered on and initialized. After the display screen is powered on and initialized, the display screen receives the AOD pattern and AOD backlight parameters sent by the AOD application, and then the display screen turns on the backlight with the AOD backlight parameters and displays the AOD pattern, thereby completing the off-screen display.

[0158] Above through Figure 6 and Figure 7 The screen-off display process and timing diagram in the screen-off state in the related art are respectively described. Figure 8 Analyze the AOD time consumption in the screen-off state in related technologies.

[0159] like Figure 8As shown, in the related art, when the display screen is in the off-screen state, if the user clicks or touches the display screen of the electronic device, the TP driver of the electronic device receives the touch screen event in the off-screen state, and the TP driver notifies the AOD application to start the off-screen display process, and then the AOD application starts the off-screen display process: the display screen is first powered on and initialized, and then the display screen receives the AOD pattern and AOD backlight parameters sent by the AOD application, and then the display screen turns on the backlight with the AOD backlight parameters and displays the AOD pattern, completing the off-screen display process. Through analysis, it can be seen that in the off-screen display process, the upper-level software module first processes the business of the off-screen display process, and then the upper-level software module sends instructions to the display screen hardware, and the display screen hardware realizes the power-on and off-screen display of the display screen based on the instructions sent by the upper-level software module.

[0160] That is to say, the off-screen display process includes the off-screen display processing time and the display screen power-on and initialization time. For example, the off-screen display processing time is recorded as t1, and the display screen power-on and initialization time is t2, and the total time of the two is t1+t2.

[0161] In actual implementation, the process of triggering the screen off display through the touch mode usually takes more than 270ms. Among them, the software module takes about 150ms to process the AOD service, and the display IC hardware power-on and initialization takes about 120ms.

[0162] Regarding the related technologies, the screen-off display process has the problem of slow implementation of the screen-off display.

[0163] This application - screen off display process

[0164] In view of the problem that the screen-off display process in the screen-off state in the above-mentioned related technologies is time-consuming, the embodiment of the present application has made improvements in the process. When the display screen is in the screen-off state and a touch screen event occurs, the touch screen event in the screen-off state is passed to the HWC, and the HWC immediately notifies the display screen to start powering on and initializing in advance; at the same time, the AOD application will start the screen-off display process and send an AOD start instruction to the HWC. When the HWC receives the AOD start instruction, the HWC determines whether the display screen has completed power-on and initialization. If completed, the AOD will send the AOD pattern and AOD backlight parameters to the display screen, and then the display screen completes the screen-off display based on the AOD pattern and AOD backlight parameters. The present application greatly reduces the overall time consumption of the screen-off display process by implementing the display screen power-on process and the screen-off display processing process in parallel, and the screen-off display becomes faster, which improves the user experience.

[0165] The display screen power-on process may include a process of triggering the display screen power-on through a touch screen event, and a process of powering on and initializing the display screen.

[0166] Among them, the screen-off display processing flow includes triggering the AOD application to start the AOD service through a touch screen event, the AOD application sending an AOD start instruction, the AOD application sending an AOD pattern, and the AOD application sending an AOD backlight parameter.

[0167] Fig. 9 The software architecture diagram of the off-screen display process in the off-screen state provided by an embodiment of the present application is shown. Among them, the off-screen display process in the off-screen state can be divided into two stages: the first stage: notifying the HWC to execute the display screen power-on process and notifying the AOD application to start the off-screen display process, and the second stage: the HWC executes the display screen power-on process and the off-screen display processing process.

[0168] Phase 1: Notify HWC to execute the display power-on process and notify the AOD application to start the screen-off display process

[0169] refer to Fig. 9 In the direction indicated by the thin solid arrow ① in the figure, when the electronic device is in the screen-off state, if the user clicks or touches the display screen, the TP driver of the electronic device will receive the operation of the user clicking or touching the display screen, that is, the TP driver will sense the touch screen event in the screen-off state.

[0170] Different from Figure 6 In the related technical process shown in the embodiment of the present application, after the TP driver senses a touch screen event in the screen-off state, the TP driver performs the following actions:

[0171] On the one hand, referring to Fig. 9 In the direction indicated by the thick solid arrow in ①, the TP driver transmits the touch screen event in the off state to the display driver, and then the display driver transmits the touch screen event in the off state to the HWC, and then the HWC starts to execute the display power-on process, that is, the HWC notifies the display driver to trigger the display power-on and initialization. Compared with related technologies, the display will execute the power-on process in advance.

[0172] On the other hand, refer to Fig. 9 In the direction shown by the dotted arrow in ②, the TP driver transmits the touch screen event in the off-screen state to the input subsystem, and then the input subsystem transmits the touch screen event in the off-screen state to the AOD application to trigger the off-screen display processing flow.

[0173] That is to say, after the TP driver senses a touch screen event in the screen-off state, the TP driver not only notifies the AOD application to start the screen-off display process, but also notifies the HWC to execute the display power-on process, so that the display driver executes the display power-on process before receiving the power-on command issued by the AOD application.

[0174] Compared with the related art in which the TP driver transmits the touch screen event in the screen-off state to the AOD application, the AOD application starts the off-screen display process, and then the HWC executes the display power-on process, the present application scheme can detect the touch screen event in the screen-off state, and the TP driver notifies the HWC to execute the display power-on process through the display driver and display HAL. In this way, the display power-on process and the off-screen display processing process are implemented in parallel, which can shorten the off-screen display time.

[0175] Phase 2: HWC executes the display power-on process and the AOD application starts the screen-off display process

[0176] In an embodiment of the present application, while the HWC executes the display screen power-on process, the touch screen event in the screen-off state is passed to the AOD application, and then the AOD application starts the screen-off display process. In this way, the display screen power-on process and the screen-off display process are implemented in parallel to shorten the time.

[0177] refer to Fig. 9 In the direction shown by the thin solid arrow in ③, in response to the touch screen event in the off-screen state, the AOD application sends an AOD startup instruction to the lower layer. The AOD startup instruction passes through the power management service module and the SurfaceFlinger service module in the software architecture in turn, and then reaches the HWC. The HWC first sends a power-on instruction to the display driver. Since the HWC executes the display power-on process in advance, and the display power-on process has been completed or is about to be completed at this time, the HWC determines whether the display power-on process is completed.

[0178] When the display screen has been powered on, the HWC returns a completion message to the AOD application. Alternatively, when the display screen has not been powered on, the HWC waits for the display screen to be powered on, and then returns a completion message to the AOD application.

[0179] After the AOD application receives the completion message, refer to Fig. 9 In the direction indicated by the thin solid arrow ④ in FIG. , the AOD application sends the AOD pattern to the display driver, and then the display driver sends the AOD pattern to the display screen.

[0180] After completing the AOD image submission process, refer to Fig. 9 In the direction indicated by the thin solid arrow ⑤, the AOD application sends the AOD backlight parameters to the display driver, and then the display driver sends the AOD backlight parameters to the display screen.

[0181] The display then completes the screen-off display based on the AOD pattern and AOD backlight parameters.

[0182] Different from Figure 6As shown in the related technical process, the HWC has already started the display screen power-on process before or at the same time as starting the screen-off display process in the present application solution, and the display screen power-on process has been completed or is about to be completed in the screen-off display processing process. In this way, the display screen power-on process and the screen-off display processing process are implemented in parallel, which significantly shortens the time consumption of the screen-off display.

[0183] For example, in the related art, the software module takes about 150ms to process the AOD service, and based on the hardware requirements of the screen chip specifications, the time required to power on the display screen is about 120ms. Since the display screen power-on process and the screen-off display processing process of this application can be executed in parallel, the overall time consumption can be reduced by about 80ms to 100ms. Therefore, this application reduces the time required to complete the screen-off display in the screen-off state.

[0184] exist Fig. 9 On the basis of Fig.10 The timing diagram of the screen-off display process in the screen-off state in the embodiment of the present application is shown. Fig.10 As shown, the method includes the following steps S201-S217.

[0185] S201, when the display screen is in the off state, the display screen receives a touch screen operation.

[0186] It should be noted that a touch screen sensor is provided on the display screen. The touch screen is composed of the touch screen sensor and the display screen. The touch screen sensor is used to detect a touch operation acting on or near it. The touch screen sensor can transmit the detected touch operation to the application processor to determine the type of touch event. Accordingly, a visual output related to the touch operation can be provided through the display screen.

[0187] The touch screen operation may be referred to as a touch screen operation in the screen-off state, and the event corresponding to the touch screen operation may be referred to as a touch screen event in the screen-off state.

[0188] S202, the display screen reports a touch screen event in the screen-off state to the TP driver.

[0189] In actual implementation, when the display screen is touched, the corresponding kernel layer TP driver will be triggered. After the TP driver receives the touch screen event, it will write the touch screen event to the corresponding input device node. Then the input system will read the touch screen event from the device node and pass the touch screen event up layer by layer.

[0190] It should be noted that Fig.10 The timing diagram of the embodiment of the present application shown in FIG. Figure 7 Compared with the related technology timing diagram shown in the figure, the main difference is Fig.10The dashed box in the middle shows S203 - S206 (power-on in advance), and S212 - S214 (power-on has been completed or is about to be completed).

[0191] The following first describes the process of powering on the display screen in advance in this application in combination with S203-S206.

[0192] S203, the TP driver transmits the touch screen event in the screen-off state to the display driver, which then transmits it to the display HAL through the display driver, and then the display HAL transmits it to the HWC.

[0193] Optionally, the TP driver can determine whether the screen-off display triggering condition is met according to the touch screen event in the screen-off state. If the screen-off display triggering condition is met, the TP driver transmits the touch screen event in the screen-off state to the HWC.

[0194] Among them, the above-mentioned screen-off display triggering conditions may include: the electronic device has turned on the screen-off display function, and the display screen is in the screen-off state, and the user input operation is a preset touch screen operation.

[0195] S204, the HWC notifies the display driver to execute the display screen power-on process.

[0196] S205, the display driver triggers the display screen to power on.

[0197] In actual implementation, the display driver triggers the display IC to power on and sends 11 instructions to the display IC to trigger the display to initialize parameters. After a preset time, the display driver will send 29 instructions to the display IC, indicating that the display has completed initialization.

[0198] Among them, instruction 11 is equivalent to the start instruction, which is used to instruct the display IC to start parameter configuration initialization after power-on. Instruction 29 is equivalent to the ready instruction, which is used to indicate that the display IC parameter configuration initialization has been completed. After the initialization is completed, the display IC can work normally, for example, it can control the display screen to light up, and it can control the display screen to display content.

[0199] In actual implementation, it usually takes a preset time for the display screen to power on and initialize, for example, the preset time may be 120ms. Different display screen ICs may have the same or different corresponding preset time lengths, which can be determined according to actual usage requirements and are not limited in the embodiments of this application.

[0200] S206, the display screen is powered on and initialized.

[0201] The following describes the process of starting the screen-off display process in this application in combination with S207-S210.

[0202] S207, the TP driver transmits the touch screen event in the screen-off state to the input subsystem.

[0203] S208: The input subsystem transmits the touch screen event in the screen-off state to the AOD application.

[0204] In some embodiments, the time when the touch screen event is delivered to the HWC is earlier than the time when the touch screen event is delivered to the AOD application.

[0205] In some other embodiments, the time when the touch screen event is delivered to the HWC is equal to the time when the touch screen driver delivers the touch screen event to the AOD application.

[0206] S209, in response to a touch screen event in the screen-off state, the AOD application is started, and triggers the start of the AOD service.

[0207] After the AOD application and AOD service are started, the screen-off display process can be started.

[0208] S210, the AOD application sends an AOD startup instruction to the power management service module. The AOD startup instruction is transmitted through the power management service module and the SurfaceFlinger service module in sequence and reaches the HWC.

[0209] The following S211-S214 illustrate the processing strategy of the HWC in the case of early power-on of the present application.

[0210] S211, in response to the AOD start instruction, the HWC determines whether the display screen has completed power-on and initialization.

[0211] If the display screen has been powered on, S214 is continued to be executed, that is, the HWC directly returns a completion message to the AOD application.

[0212] If the display screen has not completed powering on, continue to execute S212-S214, that is, the HWC waits for the display screen to complete powering on, and then returns a completion message to the AOD application.

[0213] S212, the HWC waits for the display screen to be powered on.

[0214] S213, HWC receives the display screen completion message.

[0215] S214, HWC returns a completion message to the AOD application.

[0216] Compared with the related art, the present application has executed the display screen power-on process in advance, and after the HWC receives the AOD startup command, the display screen may have completed or is about to complete power-on and initialization, so the HWC will determine whether the display screen has completed power-on and initialization.

[0217] The following S215-S217 illustrate the process of implementing the screen-off display.

[0218] S215, after the AOD application receives the completion message, the AOD application sends the AOD pattern to the display driver, and then the display driver transmits the AOD pattern to the display screen.

[0219] S216, the AOD application sends the AOD backlight parameters to the display driver, and then the display driver transmits the AOD backlight parameters to the display screen.

[0220] The backlight parameter may be a backlight value preset by the system, or may be a backlight value determined according to the ambient light brightness.

[0221] S217, the display screen turns on the backlight with the AOD backlight parameter and displays the AOD pattern.

[0222] In actual implementation, the display IC turns on the backlight of the display according to the AOD backlight parameters, and controls the display to display the AOD pattern, completing the off-screen display process.

[0223] The solution of the related technology is that in the screen-off display process, the touch screen event in the screen-off state is first passed to the AOD application, and then the AOD application starts the screen-off display process, and the upper-level software module handles the screen-off display service. Then the upper-level software module sends instructions to the display hardware, and the display hardware completes the power-on and initialization of the display based on the instructions sent by the upper-level software module, and then realizes the screen-off display.

[0224] Compared with the related art, in the embodiment of the present application, when the TP driver receives a touch screen event in the off-screen state, the TP driver notifies the HWC to execute the display screen power-on process through the display driver and display HAL, so that the display screen starts to power on and initialize in advance. At the same time, the TP driver transmits the touch screen event in the off-screen state to the AOD application, and the AOD application starts the off-screen display process. In this way, the display screen power-on process and the off-screen display processing process can be implemented in parallel, thereby greatly reducing the time to complete the off-screen display in the off-screen state.

[0225] Above through Fig. 9 and Fig.10 The screen-off display process and timing diagram in the screen-off state in the embodiment of the present application are respectively described. Fig.11 and Fig.12 Another screen-off display process and timing diagram in the screen-off state in an embodiment of the present application are respectively explained.

[0226] It should be noted that Fig.11 and Fig.12 ,and Fig. 9 and Fig.10 The difference is that Fig. 9 and Fig.10 In the touch screen event transmission path, the display HAL is used, and Fig. 9 and Fig.12 The display HAL is not used in the delivery path of touch screen events.

[0227] like Fig. 9 As shown, the transmission path of touch screen events is: display screen → TP driver → display driver → display HAL → HWC.

[0228] exist Fig.11 As shown, the transmission path of touch screen events is: display screen → TP driver → display driver → HWC.

[0229] Next, combine Fig.13 The AOD time consumption in the screen-off state provided in the embodiment of the present application is analyzed, and the AOD time consumption of the present application solution is compared with the AOD time consumption of the related technology.

[0230] like Fig.13 As shown in (a), in the related art, when the display screen is in the off-screen state, if the user clicks or touches the display screen of the electronic device, the TP driver receives the touch screen event in the off-screen state, and the TP driver first notifies the AOD application to start the off-screen display process, and then the AOD application starts the off-screen display process: the display screen is first powered on and initialized, and after the display screen is powered on and initialized (a preset time is required), the AOD sends the AOD pattern and AOD backlight parameters to the display screen, triggering the display screen to complete the off-screen display. The off-screen display process includes the off-screen display processing process, which takes t1, and the display screen power-on process, which takes t2, and the overall time is t1+t2.

[0231] like Fig.13 As shown in (b), when the display screen is in the off state, if the user clicks or touches the display screen of the electronic device, the TP driver receives the touch screen event in the off state. Compared with the related art, the improvement of the present application is that the display screen power-on process and the off-screen display processing process are executed in parallel: the TP driver transmits the touch screen event to the HWC through the display driver (and the display HAL) to trigger the HWC to execute the display screen power-on process, so that the display screen starts to power on and initialize in advance; at the same time, the TP driver transmits the touch screen event in the off state to the AOD application, notifying the AOD application to start the off-screen display process.

[0232] Therefore, when the display screen is powered on and initialized, the AOD application starts the off-screen display process and sends the AOD pattern and AOD backlight parameters to the display screen. After the display screen is powered on and initialized, the display screen completes the off-screen display based on the AOD pattern and AOD backlight parameters.

[0233] In this application, since the display screen power-on process and the screen-off display process can be executed in parallel, the overall time consumed by the software processing time and the hardware processing time is less than t1 + t2. Therefore, the solution of this application reduces the time to complete the screen-off display in the screen-off state.

[0234] In actual implementation, based on the hardware requirements of the screen IC chip specifications, it takes about 120ms (ie t2) to power on and initialize the display screen, and the software takes about 150ms (ie t1) to process the off-screen display process, so the AOD overall process takes a minimum of about 270ms. Through the present application scheme, since the display screen power-on process and the off-screen display processing process can be executed in parallel, for example, when the off-screen display process is implemented in the off-screen state, it can save about 80ms to 100ms, so the overall time consumption is about 170ms to 190ms, which shows that the overall time consumption is significantly reduced. Therefore, when the user touches the display screen in the off-screen state, the off-screen display becomes faster, which improves the user experience.

[0235] Through the scheme of this application, when the display screen is in the off state and a touch screen event occurs, the touch screen event in the off state is passed to the HWC, and the HWC immediately notifies the display screen to start powering on and initializing in advance; at the same time, the AOD application will start the off-screen display process and send an AOD start instruction to the HWC. When the HWC receives the AOD start instruction, the HWC determines whether the display screen has completed power-on and initialization. If completed, the AOD will send the AOD pattern and AOD backlight parameters to the display screen, and then the display screen completes the off-screen display based on the AOD pattern and AOD backlight parameters. This application greatly reduces the overall time consumption of the off-screen display process by implementing the display screen power-on process and the off-screen display processing process in parallel, making the off-screen display faster and improving the user experience.

[0236] In another possible implementation, when the touch screen driver receives a touch screen event in the screen-off state, the touch screen driver immediately notifies the HWC to execute the display power-on process, so that the display starts to power on in advance, and the power-on time is approximately in the range of [20ms, 50ms]. At the same time, the touch screen driver passes the touch screen event in the screen-off state to the AOD application, and the AOD application starts the screen-off display process: the AOD application sends an AOD startup instruction to the display, and the AOD startup instruction can carry the display initialization parameters. When the display receives the display initialization parameters, since the display has completed power-on in advance, the display can quickly enter initialization, which can also save a certain amount of time and make the screen-off display faster.

[0237] The present application scheme shortens the time consumed to realize the off-screen display in the off-screen state by improving the mobile phone software system. When the user clicks or touches the display screen of the electronic device in the off-screen state, the electronic device uses the method for controlling the off-screen display provided by the present application to quickly display the AOD pattern, thereby improving the user experience. The optimization scheme for the off-screen display performance described in the embodiment of the present application can support all current products and adapt to all domestic and overseas versions, and has universality and versatility.

[0238] It should be noted that, in the embodiments of the present application, "greater than" can be replaced by "greater than or equal to", "less than or equal to" can be replaced by "less than", or "greater than or equal to" can be replaced by "greater than", and "less than" can be replaced by "less than or equal to".

[0239] The various embodiments described herein may be independent solutions or may be combined according to internal logic, and all of these solutions fall within the protection scope of this application.

[0240] The present application also provides a chip, which is coupled to a memory and is used to read and execute computer programs or instructions stored in the memory to execute the methods in the above embodiments.

[0241] The present application also provides an electronic device, which includes a chip, and the chip is used to read and execute a computer program or instruction stored in a memory, so that the method in each embodiment is executed.

[0242] This embodiment also provides a computer-readable storage medium, in which computer instructions are stored. When the computer instructions are executed on an electronic device, the electronic device executes the above-mentioned related method steps to implement the method for controlling the screen off display in the above-mentioned embodiment.

[0243] This embodiment also provides a computer program product, in which a computer-readable storage medium stores program code. When the computer program product runs on a computer, the computer executes the above-mentioned related steps to implement the method for controlling the screen off display in the above-mentioned embodiment.

[0244] In addition, an embodiment of the present application also provides a device, which may specifically be a chip, component or module, and the device may include a connected processor and memory; wherein the memory is used to store computer execution instructions, and when the device is running, the processor may execute the computer execution instructions stored in the memory so that the chip executes the method of controlling the screen off display in the above-mentioned method embodiments.

[0245] Among them, the electronic device, computer-readable storage medium, computer program product or chip provided in this embodiment 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.

[0246] 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 modules or units is only a logical function division, and 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.

[0247] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A method for controlling screen-off display, characterized in that: The method is applied to an electronic device, the electronic device includes a processor and a display screen, the processor includes an off-screen display AOD application, a display driver and a hardware synthesis module HWC, and the method includes: When the display screen is in an off state, the HWC receives a touch screen event; In response to the touch screen event, the HWC triggers the display screen to power on and initialize; The HWC receives an AOD start instruction from the AOD application; In response to the AOD start instruction, the HWC determines whether the display screen has completed power-on and initialization; If the display screen has completed power-on and initialization, the HWC returns a completion message to the AOD application; or, if the display screen has not completed power-on and initialization, the HWC waits until the display screen has completed power-on and initialization and returns the completion message to the AOD application; The HWC receives an AOD pattern from the AOD application and transmits the AOD pattern to the display screen; The HWC receives the AOD backlight parameters from the AOD application, and sends the AOD pattern to the display screen, so that the display screen turns on the backlight based on the AOD backlight parameters and displays the AOD pattern.

2. The method according to claim 1, characterized in that The processor also includes a touch screen driver; The touch screen event is transmitted from the touch sensor of the display screen to the touch screen driver, then transmitted from the touch screen driver to the display driver, and then transmitted from the display driver to the HWC.

3. The method according to claim 2, characterized in that The processor also includes a display HAL; The touch screen event is transmitted from the touch sensor of the display screen to the touch screen driver, then from the touch screen driver to the display driver, then from the display driver to the display HAL, and then from the display HAL to the HWC.

4. The method according to claim 2 or 3, characterized in that: The processor also includes an input subsystem; The touch screen event is transmitted from the touch sensor of the display screen to the touch screen driver, and then transmitted from the touch screen driver to the input subsystem, and then transmitted from the input subsystem to the AOD application; The AOD start instruction is triggered when the AOD application receives the touch screen event.

5. The method according to claim 4, characterized in that The time when the touch screen event is delivered to the HWC is earlier than or equal to the time when the touch screen event is delivered to the AOD application.

6. The method according to any one of claims 1 to 5, characterized in that The HWC triggers the display screen to power on and initialize, including: The HWC sends a power-on indication message to the display driver, so that the display driver triggers the display screen to power on and initialize; The display driver triggering the display screen to initialize includes: the display driver sending a start instruction to the display screen to trigger the display screen to start initialization; after a preset time, the display driver sending a preparation instruction to the display screen to instruct the display screen to complete initialization.

7. The method according to any one of claims 1 to 6, characterized in that After the HWC triggers the initialization of the display screen, the method further includes: After a preset time, the HWC receives a completion message returned by the display driver, where the completion message is used to indicate that the display screen has completed power-on and initialization; The HWC passes the completion message to the AOD application to trigger the AOD application to send the AOD pattern.

8. The method according to any one of claims 1 to 7, characterized in that In response to the touch screen event, the HWC triggers the display screen to power on and initialize, including: When the touch screen event satisfies the screen-off display triggering condition, the HWC triggers the display screen to power on and initialize in response to the touch screen event.

9. The method according to claim 8, characterized in that The screen-off display triggering condition includes: the electronic device has turned on the screen-off display function, the display screen is in the screen-off state, and the user input operation is a preset touch screen operation.

10. The method according to claim 9, characterized in that The preset touch screen operation is an operation of lightly touching or clicking the display screen.

11. The method according to any one of claims 1 to 10, characterized in that The processor also includes a power management service module and a surface drawing SurfaceFlinger service module; The AOD startup instruction is issued by the AOD application, passed through the power management service module and the SurfaceFlinger service module, and reaches the HWC; The AOD pattern is issued by the AOD application, passed through the power management service module, the SurfaceFlinger service module and the HWC, and reaches the display driver; then the display driver sends the AOD pattern to the display screen; The AOD backlight parameters are issued by the AOD application, passed through the power management service module, the SurfaceFlinger service module and the HWC, and reach the display driver; then the display driver sends the AOD backlight parameters to the display screen.

12. An electronic device, characterized in that: The electronic device comprises a display screen, a processor, a memory and a computer program stored in the memory, wherein the processor is used to execute the computer program so that the electronic device implements the method as claimed in any one of claims 1 to 11.

13. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed on an electronic device, the electronic device executes the method according to any one of claims 1 to 11.