Alignment wake-up method, alignment wake-up device, readable storage medium, electronic device

CN116225204BActive Publication Date: 2026-10-27GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310146539.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-02-20
Publication Date
2026-10-27
Estimated Expiration
2043-02-20

AI Technical Summary

Technical Problem

相关技术中,仅对终端中的应用程序频繁唤醒终端系统的情况进行了处理,而忽略了底层外设对终端系统的频繁唤醒行为,导致对终端功耗的优化能力不足

Benefits of technology

一方面,本公开通过目标唤醒时间确定对齐唤醒时间,以对待唤醒实时闹钟进行对齐唤醒,由于在目标唤醒时间到对齐唤醒时间段内系统通常还处于唤醒状态,尚未开始休眠,可以避免终端被频繁唤醒,从而降低终端功耗;另一方面,本公开在任一内核唤醒原因对应的唤醒次数满足预设条件的情况下,才进行对齐唤醒,所以可以在降低终端功耗的同时尽可能的保证待唤醒实时闹钟的及时准确唤醒。综合以上方面,本公开可以在降低终端功耗的同时保证待唤醒实时闹钟的及时准确唤醒。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116225204B_ABST
    Figure CN116225204B_ABST
Patent Text Reader

Abstract

The present disclosure relates to the technical field of computer, in particular to an alignment wake-up method, an alignment wake-up device, a computer readable storage medium and an electronic device. The alignment wake-up method comprises: in response to the wake-up times corresponding to any kernel wake-up reason in a terminal satisfying a preset condition, determining a target wake-up time of the last kernel wake-up reason; in the case that there is a real-time alarm clock to be woken up within a first preset time period after the target wake-up time, determining an alignment wake-up time of the real-time alarm clock to be woken up according to the target wake-up time; and adjusting the alarm clock time of the real-time alarm clock to be woken up according to the alignment wake-up time. The present disclosure can reduce the frequency of the terminal being woken up during the sleep process, thereby reducing the power consumption of the terminal.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to the field of computer technology, and more specifically, to an alignment wake-up method, an alignment wake-up device, a computer-readable storage medium, and an electronic device. Background Technology

[0002] Frequent wake-ups of a terminal from sleep mode increase its power consumption. Current technologies only address the issue of applications frequently waking the terminal system, neglecting the frequent wake-ups from underlying peripherals, resulting in insufficient power consumption optimization.

[0003] It should be noted that the information disclosed in the background section above is only used to enhance the understanding of the background of this disclosure, and therefore may include information that does not constitute prior art known to those skilled in the art. Summary of the Invention

[0004] The purpose of this disclosure is to provide an aligned wake-up method, an aligned wake-up device, a computer-readable storage medium, and an electronic device, thereby reducing terminal power consumption to at least some extent.

[0005] According to a first aspect of this disclosure, an aligned wake-up method is provided, comprising: responding to a terminal where the number of wake-ups corresponding to any kernel wake-up reason meets a preset condition, and determining the most recent target wake-up time of the kernel wake-up reason; if a real-time alarm to be woken up exists within a first preset time after the target wake-up time, determining the aligned wake-up time of the real-time alarm to be woken up based on the target wake-up time; and adjusting the alarm time of the real-time alarm to be woken up based on the aligned wake-up time.

[0006] According to a second aspect of this disclosure, an aligned wake-up device is provided, comprising: a target wake-up time determination module configured to determine the most recent target wake-up time of any kernel wake-up reason in a terminal device when the number of wake-ups corresponding to any kernel wake-up reason meets a preset condition; an aligned wake-up time determination module configured to determine the aligned wake-up time of a real-time alarm to be woken up based on the target wake-up time if a real-time alarm to be woken up exists within a preset time after the target wake-up time; and a wake-up time alignment module configured to adjust the alarm time of the real-time alarm to be woken up based on the aligned wake-up time.

[0007] According to a third aspect of this disclosure, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the alignment wake-up method described in the first aspect above.

[0008] According to a fourth aspect of this disclosure, an electronic device is provided, characterized in that it includes: one or more processors; and a memory for storing one or more programs, which, when executed by the one or more processors, cause the one or more processors to implement the aligned wake-up method described in the first aspect above.

[0009] According to a fifth aspect of this disclosure, a computer program product comprising instructions is provided, which, when run on a computer, causes the computer to perform the steps of the aligned wake-up method as described in the first aspect.

[0010] The technical solution disclosed herein has the following beneficial effects: On the one hand, this disclosure determines the aligned wake-up time through the target wake-up time to perform aligned wake-up of the real-time alarm to be woken up. Since the system is usually still awake and has not yet started hibernation during the period between the target wake-up time and the aligned wake-up time, frequent wake-up of the terminal can be avoided, thereby reducing terminal power consumption. On the other hand, this disclosure only performs aligned wake-up when the number of wake-ups corresponding to any kernel wake-up reason meets a preset condition. Therefore, it can ensure the timely and accurate wake-up of the real-time alarm to be woken up as much as possible while reducing terminal power consumption. In summary, this disclosure can ensure the timely and accurate wake-up of the real-time alarm to be woken up while reducing terminal power consumption.

[0011] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure. Attached Figure Description

[0012] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this disclosure and, together with the description, serve to explain the principles of this disclosure. It is obvious that the drawings described below are merely some embodiments of this disclosure, and those skilled in the art can obtain other drawings based on these drawings without any inventive effort. In the drawings: Figure 1 A schematic diagram of a system architecture to which exemplary embodiments of the present disclosure may be applied is shown; Figure 2 A flowchart illustrating an aligned wake-up method according to an exemplary embodiment of this disclosure is shown. Figure 3 A flowchart illustrating a method for determining a target wake-up time according to an exemplary embodiment of the present disclosure is shown. Figure 4 A flowchart illustrating a method for determining an aligned wake-up time according to an exemplary embodiment of the present disclosure is shown. Figure 5This illustration shows a flowchart of a method for obtaining a preset extension duration corresponding to an external device in a terminal, according to an exemplary embodiment of the present disclosure. Figure 6 This illustration shows an interactive diagram of an alignment wake-up process in an exemplary embodiment of the present disclosure; Figure 7 A flowchart illustrating another aligned wake-up method in an exemplary embodiment of this disclosure is shown; Figure 8 This diagram illustrates an exemplary embodiment of the present disclosure of adjusting the alarm time of a real-time alarm clock to be woken up; Figure 9 This diagram illustrates the structure of an alignment wake-up device according to an exemplary embodiment of the present disclosure. Figure 10 A schematic diagram of an electronic device to which exemplary embodiments of the present disclosure may be applied is shown. Detailed Implementation

[0013] Exemplary embodiments will now be described more fully with reference to the accompanying drawings. However, these exemplary embodiments can be implemented in many forms and should not be construed as limited to the examples set forth herein; rather, they are provided so that this disclosure will be more comprehensive and complete, and will fully convey the concept of the exemplary embodiments to those skilled in the art. The described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.

[0014] Furthermore, the accompanying drawings are merely illustrative of this disclosure and are not necessarily drawn to scale. The same reference numerals in the drawings denote the same or similar parts, and therefore repeated descriptions of them will be omitted. Some block diagrams shown in the drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities may be implemented in software, in one or more hardware modules or integrated circuits, or in different network and / or processor devices and / or microcontroller devices.

[0015] For terminals, frequent wake-ups during sleep due to various tasks increase power consumption. Aligned wake-up can be understood as concentrating the tasks that wake up the terminal system at the same time, thereby reducing the frequency of terminal wake-ups and lowering terminal power consumption.

[0016] Taking Android devices as an example, the native App Standby Buckets background management strategy of the Android system collects the usage frequency of terminal applications and divides the applications installed on the terminal into 5 categories: active, working set, frequently used, rarely used, and restricted. The latency duration of each category is different. Among them, the "active" category can get the shortest latency duration, thus ensuring that "active" category applications can be woken up in time to achieve the purpose of timely processing of application scheduled tasks, while the latency duration of the "restricted" category applications is the longest, thus reducing the frequent wake-up of the phone by applications through real-time alarms.

[0017] However, the relevant technologies only consider the case where the application's real-time alarm frequently wakes up the terminal system, ignoring the case where other underlying external hardware devices frequently wake up the terminal system. Therefore, the ability to reduce terminal power consumption is insufficient.

[0018] In view of the above problems, an exemplary embodiment of this disclosure provides an aligned wake-up method.

[0019] Below, let's first combine Figure 1 The system architecture of the operating environment for this exemplary embodiment is described in an exemplary manner.

[0020] Figure 1 A schematic diagram of the system architecture is shown. System architecture 100 may include a terminal 110 and a network device 120. The terminal 110 may be a smartphone, tablet, desktop computer, laptop, smart wearable electronic device (such as a smartwatch), or other terminal device. The network device 120 may include a base station or other device that allows the terminal to access the network environment. The terminal 110 and network device 120 can be connected via a wired or wireless communication link for data exchange.

[0021] In one exemplary embodiment, the aligned wake-up method of this disclosure can be executed by terminal 110. For example, the terminal can count the number of wake-ups for each kernel wake-up reason, and when the number of wake-ups for any kernel wake-up reason meets a preset condition, determine the most recent target wake-up time for the kernel wake-up reason, and query the real-time alarms to be woken up that exist in the terminal within a first preset time after the target wake-up time, thereby determining the aligned wake-up time of the real-time alarms to be woken up according to the target wake-up time, and then adjusting the alarm time of the real-time alarms to be woken up according to the aligned wake-up time.

[0022] In one exemplary embodiment, the aligned wake-up method of this disclosure can be executed by network device 120. For example, the terminal can send the received kernel wake-up reason to network device 120. Network device 120 can count the number of wake-ups for kernel wake-up reasons in the terminal. When the number of wake-ups for a certain kernel wake-up reason meets a preset condition, the network device can determine the most recent target wake-up time for that kernel wake-up reason and search in the terminal for whether there is a real-time alarm to be woken up within a first preset time after the target wake-up time. If so, the network device can determine the aligned wake-up time of the real-time alarm to be woken up based on the target wake-up time and adjust the alarm time of the real-time alarm to be woken up based on the aligned wake-up time.

[0023] As can be seen from the above, the execution subject of the alignment wake-up method in this exemplary embodiment can be the aforementioned terminal 110 or network device 120, and this disclosure does not limit it in this regard.

[0024] The following is combined with Figure 2 The alignment wake-up method in this exemplary embodiment will be described. Figure 2 An exemplary flow of the aligned wake-up method is shown, which may include: Step S210: If the number of wake-ups corresponding to any kernel wake-up reason in the response terminal meets a preset condition, determine the target wake-up time of the most recent kernel wake-up reason; Step S220: If there is a real-time alarm to be woken up within a first preset time after the target wake-up time, determine the aligned wake-up time of the real-time alarm to be woken up according to the target wake-up time. Step S230: Adjust the alarm time of the real-time alarm clock to be woken up according to the alignment wake-up time.

[0025] Based on the above method, on the one hand, this disclosure determines the aligned wake-up time through the target wake-up time to perform aligned wake-up of the real-time alarm to be woken up. Since the system is usually still awake and has not yet started hibernation during the period between the target wake-up time and the aligned wake-up time, the terminal can be avoided from being frequently woken up, thereby reducing terminal power consumption. On the other hand, this disclosure only performs aligned wake-up when the number of wake-ups corresponding to any kernel wake-up reason meets a preset condition, so it can ensure the timely and accurate wake-up of the real-time alarm to be woken up as much as possible while reducing terminal power consumption. In summary, this disclosure can ensure the timely and accurate wake-up of the real-time alarm to be woken up while reducing terminal power consumption.

[0026] Below, on Figure 2 Each step in the process will be explained in detail.

[0027] refer to Figure 2In step S210, if the number of wake-ups corresponding to any kernel wake-up reason in the response terminal meets a preset condition, the target wake-up time of the most recent kernel wake-up reason is determined.

[0028] In one exemplary manner, the terminal in this disclosure may include a terminal running an operating system with a Linux kernel, such as an Android terminal.

[0029] For example, one specific implementation of step S210 may include: determining the wake-up frequency based on the number of wake-ups for any kernel wake-up reason when the terminal is in a screen-off state, and determining the target wake-up time of the most recent kernel wake-up reason in response to the wake-up frequency corresponding to any kernel wake-up reason meeting a preset condition.

[0030] Based on this Figure 3 A flowchart illustrating a method for determining a target wake-up time according to an exemplary embodiment of this disclosure is shown. (Reference) Figure 3 The method may include steps S310 to S330.

[0031] In step S310, for any kernel wake-up reason, the number of times the kernel wake-up reason has been triggered between the last time the terminal screen went out and the current time is determined.

[0032] In one exemplary implementation, the terminal device is in a screen-off state at the current moment. In other words, the terminal has been in a screen-off state from the last time the screen was turned off until the current moment. If the terminal screen is turned on, the count of wake-ups for each kernel wake-up reason is restarted from the moment the terminal screen turns off again.

[0033] For example, according to the Linux kernel's sleep / wake mechanism, when a low-level external device receives an external interrupt event, it wakes up the terminal system. During the wake-up process, the external device can transmit the wake-up reason to the terminal system as a string. The upper-level kernel wake-up statistics module can collect and statistically analyze the kernel wake-up reasons received by the terminal system and respond to the low-level wake-up events.

[0034] Based on this, the system can respond to kernel wake-up reasons sent by external devices when the terminal receives them, and then count the number of times the kernel wake-up reasons have been received by the terminal to determine the number of times the kernel wake-up reasons have been used between the terminal's last screen-off time and the current time.

[0035] In step S320, the wake-up frequency of the kernel wake-up reason is determined based on the number of wake-ups and the duration from the last time the terminal screen went out to the current time.

[0036] Taking the time elapsed from the last time the terminal's screen went off to the current time as the target duration, expressed in minutes, we can calculate the quotient of the number of wake-ups divided by the target duration, and then multiply that quotient by 60 to obtain the current wake-up frequency of the kernel wake-up reason, i.e., the number of times the device is woken up per hour. Alternatively, we can directly divide the number of wake-ups by the target duration to obtain the current wake-up frequency, i.e., the number of wake-ups per minute. This exemplary implementation does not impose any special limitations on this approach.

[0037] For example, a current moment can be determined at short intervals to calculate the wake-up frequency at that moment. Alternatively, the moment when any kernel wake-up cause event occurs can be taken as the current moment. That is, when the terminal is in a screen-off state, in response to the terminal system being woken up, the wake-up count corresponding to the kernel wake-up cause at the time of the current wake-up is incremented by 1. Then, the current wake-up frequency of that kernel wake-up cause from the last time the terminal device was screen-off to the current time of the wake-up is calculated.

[0038] In step S330, if the wake-up frequency corresponding to any kernel wake-up reason meets a preset condition, the target wake-up time of the most recent kernel wake-up reason is determined.

[0039] For example, one specific implementation of step S330 may include: responding to a terminal where the wake-up frequency corresponding to any kernel wake-up reason is greater than a preset value, and determining the most recent target wake-up time of the kernel wake-up reason. The preset value can be customized according to requirements, such as 30 times per hour. That is, when the wake-up frequency of any kernel wake-up reason in the screen-off state reaches 30 times per hour, the most recent wake-up time of that kernel wake-up reason, i.e., the target wake-up time, can be determined.

[0040] Through steps S310 to S330, a target wake-up time is determined only when the wake-up frequency for any kernel wake-up reason is relatively high. This allows for alignment wake-up processing of other tasks in the terminal based on the target wake-up time in subsequent steps, thereby saving terminal power consumption. Conversely, if the wake-up frequency for any kernel wake-up reason does not meet the preset condition (i.e., is low), it indicates that the terminal's power consumption is already low, and alignment wake-up processing is not required, ensuring that other tasks can wake up accurately and on time at their predetermined moments. In this way, by determining the wake-up frequency, the accuracy and timeliness of wake-up can be guaranteed as much as possible while saving terminal power consumption.

[0041] For example, another specific implementation of step S210 may include: responding to the fact that the number of wake-ups corresponding to any kernel wake-up reason within a second preset time period when the terminal is in a screen-off state meets a preset condition, and determining the most recent target wake-up time of the kernel wake-up reason.

[0042] In one exemplary implementation, if the number of wake-ups corresponding to any kernel wake-up reason within a second preset duration exceeds a certain preset value, the most recent target wake-up time for that kernel wake-up reason can be determined. For example, if the second preset duration is 10 minutes and the preset value is 10 times, then if the number of wake-ups for any kernel wake-up reason reaches 10 within 10 minutes from the most recent screen-off time, such as when kernel wake-up reason A reaches 10 times in the 8th minute from the most recent screen-off time, the most recent wake-up time for kernel wake-up reason A can be determined at the 8th minute, i.e., the target wake-up time for kernel wake-up reason A.

[0043] It should be noted that if no kernel wake-up reason meets the preset condition when the first 10 minutes are reached, the wake-up count for each kernel wake-up reason will restart within the second preset duration while the screen is off, and so on. If no kernel wake-up reason meets the preset condition within the 10 minutes from the most recent screen-off time, the wake-up count for each kernel wake-up reason will restart from the 10th minute.

[0044] In another exemplary implementation, the second preset duration can also be a dynamically changing value in units of the target preset duration. Thus, the preset condition is also a value that changes with the second preset duration, and the number of wake-ups for each kernel wake-up reason is continuously counted in the screen-off state, only being reset to zero after the screen is turned on. For example, if the target preset duration is 10 minutes, the first second preset duration from the most recent screen-off time is 10 minutes, and its corresponding preset condition is greater than or equal to the preset value 1. The second second preset duration from the most recent screen-off time is 20 minutes, and its corresponding preset condition is greater than or equal to twice the preset value 1, and so on.

[0045] Continue to refer to Figure 2 In step S220, if there is a real-time alarm to be woken up within a first preset time after the target wake-up time, the alignment wake-up time of the real-time alarm to be woken up is determined according to the target wake-up time.

[0046] The first preset duration can be customized according to needs, such as 2 minutes. However, it should be noted that the first preset duration should not be too long, otherwise the real-time alarm to be woken up may be woken up too early. The first preset duration should also not be too short, otherwise the real-time alarm to be woken up will be about to be woken up, and there will be little point in aligning it for wake-up. The real-time alarm to be woken up can be understood as the RTC (Real-time Clock) alarm waiting to wake up the terminal system.

[0047] For example, Figure 4This diagram illustrates a flowchart of a method for determining aligned wake-up time according to an exemplary embodiment of this disclosure. (Reference) Figure 4 The method may include steps S410 to S420. Wherein: In step S410, the external device corresponding to the kernel wake-up reason whose wake-up count meets the preset condition is determined, and the preset extension duration corresponding to the external device is obtained in the terminal.

[0048] The preset extension duration is shorter than the first preset duration. This ensures that the real-time alarm clock awaiting wake-up within the first preset duration is woken up earlier, thus avoiding an increase in the number of terminal wake-ups and reducing terminal power consumption.

[0049] For example, Figure 5 This diagram illustrates a method for obtaining a preset extension duration corresponding to an external device in a terminal, as shown in an exemplary embodiment of this disclosure. (See reference...) Figure 5 The method may include steps S510 to S530. Wherein: In step S510, the external devices corresponding to different kernel wake-up reasons are predetermined to generate a cause-device mapping table.

[0050] For example, kernel wake-up reasons can include strings representing the wake-up events of certain hardware devices. Hardware devices with the same attributes usually have the same character characteristics. Therefore, based on the character characteristics of the kernel wake-up reason strings, the external devices corresponding to each kernel wake-up reason in different systems and different versions of the system can be determined to generate a cause-device mapping table. For example, taking the Android system as an example, classifying kernel wake-up reasons according to the characteristic of different external physical device entities can yield the cause-device mapping table shown in Table 1.

[0051] Table 1. Example of cause-device mapping relationship

[0052] In Table 1, Display is an abstraction of output display devices in the Android system. Taking a mobile phone terminal as an example, the traditional Display device is the LCD (Liquid Crystal Display) screen on the phone. RTC (Real timeclock), WLAN (Wireless Local Area Network), Modem, Sensor, and ADSP (Application Digital Signal Processing System) are also mentioned.

[0053] For example, in step S520, a preset extension duration is pre-configured for the external devices in the cause device mapping table to obtain the kernel wake-up cause classification table.

[0054] For example, a preset extension duration can be pre-configured for corresponding external devices based on experience and the load of the external devices. Different external devices wake up the terminal system, and the complexity and processing time of the tasks required by the terminal system vary. The preset extension duration is used to separate the aligned wake-up time point from the current kernel wake-up time point, avoiding a situation where tasks are processed simultaneously at a single time point, leading to excessive load on the terminal system. For example, the resulting kernel wake-up reason classification table can be shown in Table 2.

[0055] Table 2. Kernel Wake-up Reason Classification Table

[0056] For example, one specific implementation of step S520 may include: pre-configuring a preset extension duration according to the external device in the terminal type cause device mapping relationship table to obtain the kernel wake-up cause classification table corresponding to the terminal type.

[0057] For example, different types of terminals, such as different models of mobile phones, usually have different hardware devices and different processing performance. Therefore, the terminal type to be aligned for wake-up can be used as the reason for the external devices included in the device mapping table to pre-configure the preset extension duration, so as to obtain the kernel wake-up reason classification table corresponding to the terminal type.

[0058] For example, based on the external device corresponding to the terminal type of the terminal to be aligned and woken up, the data record of the cause device corresponding to the terminal type can be determined from the cause device mapping table to generate the cause device mapping sub-table corresponding to the terminal type. Then, a preset extension duration can be configured for the external device in the cause device mapping sub-table to generate the kernel wake-up cause classification table corresponding to the terminal type.

[0059] Of course, without distinguishing terminal type, the preset extension duration is directly configured for external devices in the cause device mapping relationship table to generate a kernel wake-up cause classification table. This exemplary implementation does not impose any special limitations on this.

[0060] Continue to refer to Figure 5 In step S530, the kernel wake-up reason classification table is pre-stored in the terminal so as to obtain the preset extension duration corresponding to the external device from the kernel wake-up reason classification table stored in the terminal.

[0061] For example, if the kernel wake-up reason classification table corresponding to the terminal type is generated in step S520, a specific implementation of step S530 may include: storing the kernel wake-up reason classification table corresponding to the terminal type in the terminal indicated by the terminal type, so as to obtain the preset extension duration corresponding to the external device from the kernel wake-up reason classification table stored in the terminal.

[0062] For example, in step S520, without distinguishing terminal type, a preset extension duration is directly pre-configured for the external device in the cause device mapping table to generate a kernel wake-up cause classification table. Considering that different types of terminals correspond to different external devices, another specific implementation of step S530 may include: determining the data record of the external device corresponding to the terminal type from the kernel wake-up cause classification table according to the external device corresponding to the terminal type of the terminal, so as to obtain a kernel wake-up cause classification sub-table corresponding to the terminal type; pre-storing the kernel wake-up cause classification sub-table in the terminal indicated by the terminal type, so as to obtain the preset extension duration corresponding to the external device from the kernel wake-up cause classification sub-table stored in the terminal.

[0063] For example, by pre-establishing a classification table of wake-up cause events for different hardware devices, the corresponding table is stored in the terminal of the corresponding model, such as in the mobile phone flash (flash memory, a long-life non-volatile memory that can retain the stored data information even when the power is off). When the mobile phone is woken up during sleep in actual use, it can quickly query the category of the kernel wake-up cause (i.e. the external device corresponding to the kernel wake-up cause) to determine the preset extension duration, and then determine the alignment wake-up time in the subsequent step S420 based on the preset extension duration.

[0064] Continue to refer to Figure 4 In step S420, the aligned wake-up time of the real-time alarm clock to be woken up is determined according to the target wake-up time and the preset extension duration.

[0065] For example, the target wake-up time can be increased by adding a preset delay time to obtain the aligned wake-up time. If the target wake-up time is A and the preset delay time is Feature_delay_time, then the aligned wake-up time B = A + Feature_delay_time.

[0066] Through the above steps S410 to S420, the alignment wake-up time can be determined according to the preset extension duration corresponding to the external device indicated by different kernel wake-up reasons, thereby improving the accuracy of the alignment wake-up time determination.

[0067] In another exemplary implementation, the aligned wake-up time can also be determined by: obtaining a third preset duration, and determining the aligned wake-up time of the real-time alarm to be woken up based on the target wake-up time and the third preset duration; wherein the third preset duration is less than the first preset duration.

[0068] For example, the target wake-up time can be directly added to a third preset duration to determine the aligned wake-up time for the real-time alarm to be woken up. This eliminates the need to distinguish between different external devices and store a kernel wake-up reason classification table, achieving aligned wake-up based on external devices without increasing the terminal's storage requirements. The third preset duration can be determined empirically, taking the maximum, average, median, or minimum value of the preset delay duration for each external device. The principle is to minimize the frequency of the terminal being woken up from sleep mode while avoiding a rush of tasks at the same time.

[0069] Continue to refer to Figure 2 In step S230, the alarm time of the real-time alarm clock to be woken up is adjusted according to the alignment wake-up time.

[0070] For example, the alarm time of the real-time alarm to be woken up within the first preset duration can be modified to align with the wake-up time.

[0071] Before aligned wake-up, since there could be at least a few minutes between the target wake-up time and the real-time alarm to be woken up, the terminal system would normally go to sleep after completing its task at time A, waiting to be woken up at the next time point, i.e., the alarm time of the real-time alarm to be woken up, and then process the scheduled task of the real-time alarm to be woken up again. Therefore, the system would be woken up at least twice. After aligned wake-up, the scheduled task that was originally scheduled for the alarm time of the real-time alarm to be woken up is moved to be executed near the aligned wake-up time. Since there is only a small preset extension time or a third preset time interval between the target wake-up time and the aligned wake-up time, the target wake-up time and the aligned wake-up time are very close. During these two time points, the system is usually still awake and has not yet started to sleep. In other words, during these two time points, the system can process the task that was originally scheduled to be processed at the alarm time in advance, thereby achieving the purpose of aligned wake-up. This can reduce at least one wake-up. If there are multiple real-time alarms to be woken up within the first preset time after the target wake-up time, the number of wake-ups can be reduced even more, thereby reducing the overhead caused by frequent system wake-ups and reducing the standby power consumption of the terminal.

[0072] For example, Figure 6 This illustration shows an interaction diagram during an aligned wake-up process according to an exemplary embodiment of this disclosure. (Reference) Figure 6Hardware device 61 wakes up the terminal system and sends a kernel wake-up reason to the kernel wake-up event receiving module 62 of the terminal system. The kernel wake-up event receiving module 62 sends the kernel wake-up reason to the kernel wake-up reason statistics module 63 and the kernel wake-up reason identification module 64. The kernel wake-up reason statistics module 63 can count the wake-up frequency of each kernel wake-up reason in the screen-off state, in units of wake-ups per hour. If the counted frequency is greater than a preset value, such as more than 30 wake-ups per hour, it notifies the kernel wake-up reason identification module 64 to query the preset extension duration pre-configured by the external device corresponding to the most recently received kernel wake-up reason, and notifies the delay parameter decision module 65 to calculate the aligned wake-up time point. Upon receiving a query message from the kernel wake-up cause statistics module 63, the kernel wake-up cause identification module 64 queries the kernel wake-up cause classification table stored in the kernel wake-up cause classification table module 66 for the preset extension duration configured for the external device corresponding to the most recently received kernel wake-up cause. This preset extension duration is then sent to the delay parameter decision module 65. The delay parameter decision module 65 determines the aligned wake-up time based on the most recent target wake-up time of the kernel wake-up cause at the aligned time point, calculated from the trigger time sent by the kernel wake-up cause statistics module 63, and the preset extension duration sent by the kernel wake-up cause identification module 64. This aligned wake-up time is then sent to the AlarmManager Service 67. The AlarmManager Service adjusts the wake-up time of the RTC (Real-Time Clock) device 68 based on the received aligned wake-up time. Furthermore, the cloud parameter update module 69 can also update the kernel wake-up cause classification table stored in the kernel wake-up cause classification table module and update parameters needed by other modules based on updates to external devices.

[0073] For example, Figure 7 A flowchart illustrating another aligned wake-up method according to an exemplary embodiment of this disclosure is shown. (Reference) Figure 7 The method may include steps S710 to S770.

[0074] In step S710, it is determined whether the wake-up frequency of any kernel wake-up reason is greater than a preset value. If so, proceed to step S720. In step S720, the target wake-up time of the most recent wake-up of the kernel wake-up reason is recorded; In step S730, it is checked whether there is an RTC alarm about to wake up within the first preset time after the target wake-up time. If there is, proceed to step S740; otherwise, proceed to step S770. In step S740, the wake-up time of the RTC alarm within a first preset time after the target wake-up time is obtained; In step S750, a preset extension duration is determined based on the external device corresponding to the kernel wake-up reason, and an aligned wake-up time is determined based on the target wake-up time and the preset extension duration. In step S760, the wake-up time of the RTC alarm within the first preset duration is modified to the aligned wake-up time; No processing is performed in step S770.

[0075] Taking the target wake-up time in step S720 as time point A, the first preset duration in step S730 as 2 minutes, the wake-up time of the RTC alarm within the first preset duration after the target wake-up time in step S740 as time point C, the preset extension duration in step S750 as Feature_delay_time, and the finally calculated aligned wake-up time B = A + Feature_delay_time in step S750 as an example. Figure 8 This diagram illustrates an exemplary embodiment of the present disclosure of adjusting the alarm time of a real-time alarm clock to be woken up.

[0076] refer to Figure 8 Before using the method of this disclosure for aligned wake-up processing, since the two time points of AC are at least a few minutes long, such as Figure 8 In a normal scenario, the system would enter sleep mode after completing its task at time A, waiting to be woken up at time C to handle the RTC alarm timer task. This would result in the system being woken up at least twice. However, by using the aligned wake-up method described in this disclosure, the RTC alarm timer task originally scheduled for time C is moved to near time B. Since times A and B are very close, the system is usually still awake during these two time points and has not yet entered sleep mode. This means that during this extended period (the A-B time interval), the system can process tasks that were originally scheduled for a future time C, thus achieving aligned wake-up. Obviously, this reduces the number of wake-ups by at least one. Therefore, the aligned wake-up method in this disclosure can reduce the overhead caused by frequent system wake-ups and optimize the phone's standby power consumption.

[0077] In other words, the alignment wake-up method in this disclosure can compensate for the fact that the original alignment wake-up mechanism of the terminal system does not take into account the typical situation of frequent wake-up of the terminal system by the underlying hardware devices, thereby further saving terminal power consumption.

[0078] In summary, on the one hand, this disclosure determines the aligned wake-up time through the target wake-up time to perform aligned wake-up of the real-time alarm to be woken up. Since the system is usually still awake and has not yet started hibernation during the period between the target wake-up time and the aligned wake-up time, frequent wake-ups of the terminal can be avoided, thereby reducing terminal power consumption. On the other hand, this disclosure only performs aligned wake-up when the number of wake-ups corresponding to any kernel wake-up reason meets a preset condition. Therefore, it can reduce terminal power consumption while ensuring the timely and accurate wake-up of the real-time alarm to be woken up as much as possible. In short, this disclosure can reduce terminal power consumption while ensuring the timely and accurate wake-up of the real-time alarm to be woken up.

[0079] It should be noted that the above figures are merely illustrative of the processes included in the method according to exemplary embodiments of this disclosure, and are not intended to be limiting. It is readily understood that the processes shown in the above figures do not indicate or limit the temporal order of these processes. Furthermore, it is readily understood that these processes may be executed synchronously or asynchronously, for example, in multiple modules.

[0080] Next, refer to Figure 9 As shown, this example embodiment also provides an aligned wake-up device 900, which may include a target wake-up time determination module 910, an aligned wake-up time determination module 920, and a wake-up time alignment module 930, wherein: the target wake-up time determination module 910 is configured to determine the most recent target wake-up time of any kernel wake-up reason in the terminal device when the number of wake-ups corresponding to any kernel wake-up reason in the terminal device meets a preset condition; the aligned wake-up time determination module 920 is configured to determine the aligned wake-up time of the real-time alarm to be woken up according to the target wake-up time when there is a real-time alarm to be woken up within a preset time after the target wake-up time; and the wake-up time alignment module 930 is configured to adjust the alarm time of the real-time alarm to be woken up according to the aligned wake-up time.

[0081] In one exemplary implementation, based on the foregoing embodiments, the target wake-up time determination module 910 can be specifically configured to: for any kernel wake-up reason, determine the number of times the kernel wake-up reason has been woken up from the last time the terminal screen went off to the current time, wherein the terminal device is in a screen-off state at the current time; determine the wake-up frequency of the kernel wake-up reason based on the number of wake-ups and the duration from the last time the terminal screen went off to the current time; and determine the target wake-up time of the most recent kernel wake-up reason in response to the wake-up frequency corresponding to any kernel wake-up reason satisfying a preset condition.

[0082] In one exemplary implementation, based on the foregoing embodiments, the target wake-up time determination module 910 may also be specifically configured to: in response to the fact that the number of wake-ups corresponding to any kernel wake-up reason within a second preset duration when the terminal is in a screen-off state meets a preset condition, determine the most recent target wake-up time of the kernel wake-up reason.

[0083] In one exemplary implementation, based on the foregoing embodiments, the alignment wake-up time determination module 920 can be specifically configured to: determine the external device corresponding to the kernel wake-up reason whose wake-up count meets the preset conditions, obtain the preset extension duration corresponding to the external device in the terminal; determine the alignment wake-up time of the real-time alarm to be woken up according to the target wake-up time and the preset extension duration; wherein, the preset extension duration is less than the first preset duration.

[0084] In one exemplary embodiment, based on the foregoing embodiments, the device 900 may further include a pre-storage module, which may be configured to: pre-determine external devices corresponding to different kernel wake-up reasons to generate a cause-device mapping table; pre-configure a preset extension duration for the external devices in the cause-device mapping table to obtain a kernel wake-up reason classification table; and pre-store the kernel wake-up reason classification table in the terminal to obtain the preset extension duration corresponding to the external devices from the kernel wake-up reason classification table stored in the terminal.

[0085] In one exemplary implementation, based on the foregoing embodiments, the step of pre-configuring a preset extension duration for external devices in the cause device mapping relationship table to obtain a kernel wake-up cause classification table includes: pre-configuring a preset extension duration for external devices in the cause device relationship table according to the terminal type to obtain a kernel wake-up cause classification table corresponding to the terminal type.

[0086] In one exemplary implementation, based on the foregoing embodiments, the step of pre-storing the kernel wake-up reason classification table in the terminal to obtain the preset extension duration corresponding to the external device from the kernel wake-up reason classification table stored in the terminal includes: storing the kernel wake-up reason classification table corresponding to the terminal type in the terminal indicated by the terminal type to obtain the preset extension duration corresponding to the external device from the kernel wake-up reason classification table stored in the terminal.

[0087] In one exemplary implementation, based on the foregoing embodiments, the alignment wake-up time determination module 920 can also be configured to: obtain a third preset duration, and determine the alignment wake-up time of the real-time alarm clock to be woken up based on the target wake-up time and the third preset duration; wherein, the third preset duration is less than the first preset duration.

[0088] The specific details of each module in the above-mentioned device have been described in detail in the method section of the implementation. For any undisclosed details, please refer to the implementation content of the method section, and therefore will not be repeated here.

[0089] An exemplary embodiment of this disclosure also provides an electronic device for performing the above-described aligned wake-up method. This electronic device may be the aforementioned terminal 110. Generally, the electronic device may include a processor and a memory, the memory for storing executable instructions of the processor, and the processor configured to perform the above-described aligned wake-up method by executing the executable instructions.

[0090] The following is based on Figure 10 Taking a mobile terminal 1000 as an example, the construction of this electronic device will be described by way of example. Those skilled in the art will understand that, apart from components specifically designed for mobile purposes, Figure 10 The structure can also be applied to fixed types of equipment.

[0091] like Figure 10 As shown, the mobile terminal 1000 may specifically include: a processor 1001, a memory 1002, a bus 1003, a mobile communication module 1004, an antenna 1, a wireless communication module 1005, an antenna 2, a display screen 1006, a camera module 1007, an audio module 1008, a power module 1009, and a sensor module 1010.

[0092] The processor 1001 may include one or more processing units, such as an AP (Application Processor), a modem processor, a GPU (Graphics Processing Unit), an ISP (Image Signal Processor), a controller, an encoder, a decoder, a DSP (Digital Signal Processor), a baseband processor, and / or an NPU (Neural-Network Processing Unit).

[0093] The processor 1001 can be connected to the memory 1002 or other components via the bus 1003.

[0094] The memory 1002 can be used to store computer executable program code, which includes instructions. The processor 1001 executes various functional applications and data processing of the mobile terminal 1000 by running the instructions stored in the memory 1002. The memory 1002 can also store application data, such as images, videos, and other files. The memory 1002 can also be used to store a kernel wake-up reason classification table corresponding to the terminal type of the mobile terminal 1000, so as to determine the preset extension duration for calculating the aligned wake-up time through the stored kernel wake-up reason classification table.

[0095] The communication function of mobile terminal 1000 can be implemented through mobile communication module 1004, antenna 1, wireless communication module 1005, antenna 2, modem processor, and baseband processor. Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Mobile communication module 1004 can provide 2G, 3G, 4G, and 5G mobile communication solutions for mobile terminal 1000. Wireless communication module 1005 can provide wireless communication solutions such as wireless LAN, Bluetooth, and near-field communication for mobile terminal 1000.

[0096] The display screen 1006 is used to implement display functions, such as displaying the user interface, images, and videos. The camera module 1007 is used to implement shooting functions, such as capturing images and videos. The audio module 1008 is used to implement audio functions, such as playing audio and capturing voice. The power module 1009 is used to implement power management functions, such as charging the battery, supplying power to the device, and monitoring battery status. The sensor module 1010 may include a depth sensor 10101, a pressure sensor 10102, a gyroscope sensor 10103, a barometric pressure sensor 10104, etc., to implement corresponding sensing and detection functions.

[0097] Those skilled in the art will understand that various aspects of this disclosure can be implemented as a system, method, or program product. Therefore, various aspects of this disclosure can be specifically implemented in the following forms: a completely hardware implementation, a completely software implementation (including firmware, microcode, etc.), or a combination of hardware and software aspects, collectively referred to herein as a "circuit," "module," or "system."

[0098] Exemplary embodiments of this disclosure also provide a computer-readable storage medium storing a program product capable of implementing the methods described above. In some possible embodiments, various aspects of this disclosure can also be implemented as a program product including program code that, when run on a terminal device, causes the terminal device to perform the steps described in the "Exemplary Methods" section of this specification according to various exemplary embodiments of this disclosure, such as executing... Figures 2 to 7 Any one or more steps in the process.

[0099] The computer-readable medium disclosed herein may be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. A computer-readable storage medium may be, for example,—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof.

[0100] In this disclosure, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in connection with an instruction execution system, apparatus, or device. In this disclosure, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium can also be any computer-readable medium other than a computer-readable storage medium, which can transmit, propagate, or transfer a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to: wireless, wireline, optical fiber, RF, etc., or any suitable combination thereof.

[0101] Furthermore, program code for performing the operations of this disclosure can be written in any combination of one or more programming languages, including object-oriented programming languages ​​such as Java and C++, and conventional procedural programming languages ​​such as C or similar languages. The program code can execute entirely on the user's computing device, partially on the user's computing device, as a standalone software package, partially on the user's computing device and partially on a remote computing device, or entirely on a remote computing device or server. In cases involving remote computing devices, the remote computing device can be connected to the user's computing device via any type of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computing device (e.g., via the Internet using an Internet service provider).

[0102] Other embodiments of this disclosure will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this disclosure that follow the general principles of this disclosure and include common knowledge or customary techniques in the art not disclosed herein. The specification and embodiments are to be considered exemplary only, and the true scope and spirit of this disclosure are indicated by the claims.

[0103] It should be understood that this disclosure is not limited to the precise structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this disclosure is limited only by the appended claims.

Claims

1. An alignment wake-up method, characterized in that, include: If the number of wake-ups corresponding to any kernel wake-up reason in the response terminal meets a preset condition, determine the target wake-up time of the most recent kernel wake-up reason. If there is a real-time alarm to be woken up within a first preset time after the target wake-up time, the aligned wake-up time of the real-time alarm to be woken up is determined according to the target wake-up time. Adjust the alarm time of the real-time alarm to be woken up according to the alignment wake-up time.

2. The alignment wake-up method according to claim 1, characterized in that, If the number of wake-ups corresponding to any kernel wake-up reason in the response terminal meets a preset condition, the most recent target wake-up time of the kernel wake-up reason is determined, including: For any kernel wake-up reason, determine the number of times the kernel wake-up reason has been triggered between the last time the terminal screen went off and the current time, wherein the terminal device is in a screen-off state at the current time; The wake-up frequency of the kernel wake-up reason is determined based on the number of wake-ups and the duration from the last time the terminal screen went out to the current time. If the wake-up frequency corresponding to any kernel wake-up reason meets a preset condition, determine the target wake-up time of the most recent kernel wake-up reason.

3. The alignment wake-up method according to claim 1, characterized in that, If the number of wake-ups corresponding to any kernel wake-up reason in the response terminal meets a preset condition, the target wake-up time of the most recent kernel wake-up reason is determined, including: If the number of wake-ups corresponding to any kernel wake-up reason within a second preset time period when the terminal is in a screen-off state meets a preset condition, the target wake-up time of the most recent kernel wake-up reason is determined.

4. The alignment wake-up method according to claim 1, characterized in that, The step of determining the aligned wake-up time of the real-time alarm clock to be woken up based on the target wake-up time includes: Determine the external device corresponding to the kernel wake-up reason where the number of wake-ups meets the preset conditions, and obtain the preset extension duration corresponding to the external device in the terminal; Based on the target wake-up time and the preset extension duration, the aligned wake-up time of the real-time alarm to be woken up is determined; Wherein, the preset extension duration is less than the first preset duration.

5. The alignment wake-up method according to claim 4, characterized in that, The method further includes: Predetermine the external devices corresponding to different kernel wake-up reasons to generate a cause-device mapping table; Pre-configure a preset extension duration for external devices in the cause device mapping table to obtain the kernel wake-up cause classification table; The kernel wake-up reason classification table is pre-stored in the terminal so as to obtain the preset extension duration corresponding to the external device from the kernel wake-up reason classification table stored in the terminal.

6. The alignment wake-up method according to claim 5, characterized in that, The external devices in the cause device mapping table are pre-configured with a preset extension duration to obtain a kernel wake-up cause classification table, including: Based on the terminal type, the external devices in the cause device relationship table are pre-configured with a preset extension duration to obtain the kernel wake-up cause classification table corresponding to the terminal type; The step of pre-storing the kernel wake-up reason classification table in the terminal, and obtaining the preset extension duration corresponding to the external device from the kernel wake-up reason classification table stored in the terminal, includes: The kernel wake-up reason classification table corresponding to the terminal type is stored in the terminal indicated by the terminal type, so as to obtain the preset extension duration corresponding to the external device from the kernel wake-up reason classification table stored in the terminal.

7. The alignment wake-up method according to claim 1, characterized in that, The step of determining the aligned wake-up time of the real-time alarm to be woken up based on the target wake-up time includes: Obtain a third preset duration, and determine the aligned wake-up time of the real-time alarm to be woken up based on the target wake-up time and the third preset duration; The third preset duration is less than the first preset duration.

8. An alignment wake-up device, characterized in that, include: The target wake-up time determination module is configured to determine the most recent target wake-up time of any kernel wake-up reason in the terminal device when the number of wake-ups corresponding to any kernel wake-up reason in the terminal device meets a preset condition. The alignment wake-up time determination module is configured to determine the alignment wake-up time of the real-time alarm to be woken up based on the target wake-up time if there is a real-time alarm to be woken up within a preset time after the target wake-up time. The wake-up time alignment module is configured to adjust the alarm time of the real-time alarm to be woken up according to the aligned wake-up time.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the method as described in any one of claims 1 to 7.

10. An electronic device, characterized in that, include: One or more processors; as well as A memory for storing one or more programs, which, when executed by one or more processors, cause the one or more processors to implement the method as described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • Wakeup synchronization method, device and terminal

    CN104239132A

  • Information processing method, apparatus, mobile terminal, and computer-readable storage medium

    CN108646909A