Power consumption adjusting method and device, electronic equipment and readable storage medium

By simultaneously running the first operating system and the second operating system on the electronic device and switching the second operating system to the low-power state according to the user status, the problem of shortening the battery life of the electronic device is solved, and the power consumption reduction and battery life are achieved. Extended effect.

CN119271030APending Publication Date: 2025-01-07GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202411324788.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2020-12-19
Publication Date
2025-01-07

AI Technical Summary

Technical Problem

With the enhancement of the functions of electronic devices, their power consumption increases, resulting in a shortening of battery life. How to extend the battery life of electronic devices has become an urgent problem to be solved.

Method used

By simultaneously running the first operating system and the second operating system on the electronic device, the second operating system is switched to the target operating state with lower power consumption while satisfying the current state of the user, thereby reducing overall power consumption.

Benefits of technology

It realizes dynamic adjustment of the operating status of the second operating system according to the user's current status, reduces the power consumption of electronic devices, extends the battery life, and meets the user's usage needs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119271030A_ABST
    Figure CN119271030A_ABST
Patent Text Reader

Abstract

The invention relates to a power consumption adjusting method and device, electronic equipment and a computer readable storage medium, a first operating system and a second operating system can run on the electronic equipment at the same time, and the method comprises the steps that under the condition that the first operating system and the second operating system are both in a first running state, the current state of a user is obtained; if the current state of the user meets the system state switching condition, the second operating system enters a target running state; the power consumption of the second operating system in the target running state is smaller than that of the second operating system in the first running state. The second operating system can enter the target running state according to the current state of the user. Therefore, the appropriate target operation state can be configured for the second operation system based on the current state of the user, and the power consumption of the electronic equipment is reduced while the use of the user is met.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a power consumption adjustment method and device, an electronic device, and a readable storage medium. Background Art

[0002] With the continuous development of computer technology, the functions of electronic devices are becoming more and more powerful. However, as the functions of electronic devices increase, their power consumption also increases, and the battery life of electronic devices becomes shorter and shorter. How to extend the battery life of electronic devices has become an urgent problem to be solved. Summary of the invention

[0003] The embodiments of the present application provide a power consumption adjustment method and device, an electronic device, and a readable storage medium, which can reduce the power consumption of the electronic device and extend the battery life of the electronic device while meeting the needs of users.

[0004] A power consumption adjustment method is applied to an electronic device, wherein a first operating system and a second operating system can be run on the electronic device at the same time, and the method comprises:

[0005] When both the first operating system and the second operating system are in a first operating state, obtaining a current state of a user;

[0006] If the current state of the user meets the system state switching condition, the second operating system enters the target operating state; the power consumption of the second operating system in the target operating state is less than the power consumption of the second operating system in the first operating state.

[0007] A power consumption adjustment device is applied to an electronic device, on which a first operating system and a second operating system can be run simultaneously, and the device comprises:

[0008] A user status detection module, used for obtaining the current status of the user when both the first operating system and the second operating system are in the first operating state;

[0009] The system operation state switching module is used to enable the second operating system to enter a target operation state if the current state of the user meets the system state switching condition; the power consumption of the second operating system in the target operation state is less than the power consumption of the second operating system in the first operation state.

[0010] An electronic device includes a memory and a processor, wherein a computer program is stored in the memory, and when the computer program is executed by the processor, the processor executes the steps of the power consumption adjustment method as described above.

[0011] A computer-readable storage medium stores a computer program, which implements the steps of the power consumption adjustment method described above when executed by a processor.

[0012] The above-mentioned power consumption adjustment method and device, electronic device, and computer-readable storage medium can run the first operating system and the second operating system on the electronic device at the same time. The method includes: when the first operating system and the second operating system are both in the first operating state, obtaining the current state of the user. If the current state of the user meets the system state switching condition, the second operating system enters the target operating state; the power consumption of the second operating system in the target operating state is less than the power consumption of the second operating system in the first operating state. It is achieved that the second operating system can enter the target operating state according to the current state of the user. Therefore, it is possible to configure a suitable target operating state for the second operating system based on the current state of the user, thereby reducing the power consumption of the electronic device while satisfying the user's use, and extending the battery life of the electronic device. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0014] FIG1 is a diagram of an application environment of a power consumption adjustment method according to an embodiment;

[0015] FIG2 is a flow chart of a power consumption adjustment method according to an embodiment;

[0016] FIG3 is a flow chart of a power consumption adjustment method in another embodiment;

[0017] FIG4 is a schematic diagram of modules mounted under the first operating system and the second operating system in one embodiment;

[0018] FIG5 is a flow chart of a power consumption adjustment method in another embodiment;

[0019] FIG6 is a flow chart of obtaining the current status of the user in FIG2;

[0020] FIG7 is a flow chart of a power consumption adjustment method in a specific embodiment;

[0021] FIG8 is a structural block diagram of a power consumption adjustment device in one embodiment;

[0022] FIG9 is a structural block diagram of a power consumption adjustment device in yet another embodiment;

[0023] FIG. 10 is a schematic diagram of the internal structure of an electronic device in one embodiment. DETAILED DESCRIPTION

[0024] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0025] FIG1 is an application scenario diagram of a power consumption adjustment method in an embodiment. As shown in FIG1 , the application environment includes an electronic device 120, and the electronic device 120 is an electronic device with a dual system. Among them, the dual system includes a first operating system and a second operating system. The electronic device 120 obtains the current state of the user when the first operating system and the second operating system are both in the first operating state through the power consumption adjustment method in the present application; if the current state of the user meets the system state switching condition, the second operating system enters the target operating state; the power consumption of the second operating system in the target operating state is less than the power consumption of the second operating system in the first operating state. Here, the electronic device 120 can be any terminal device such as a mobile phone, a tablet computer, a PDA (Personal Digital Assistant), a wearable device (smart watch), a smart home, etc. Among them, a smart watch is a watch with information processing capabilities and meets the basic functional requirements of a watch.

[0026] FIG2 is a flow chart of a power consumption adjustment method in an embodiment. The power consumption adjustment method in this embodiment is described by taking the electronic device 120 in FIG1 as an example, and the electronic device can run the first operating system and the second operating system at the same time. As shown in FIG2, the power consumption adjustment method includes steps 220 to 240. Among them,

[0027] Step 220: When both the first operating system and the second operating system are in the first operating state, obtain the current state of the user.

[0028] Now the battery life is an increasingly important performance indicator in electronic devices. In order to solve the problem of battery life of electronic devices, more and more dual-system solutions are used in electronic devices to reduce power consumption. Generally, dual systems can be run simultaneously in electronic devices, or only one of the systems can be run, and the dual systems can be switched between each other. One system in the dual system (such as an RTOS system (real-time operating system)) consumes less power during operation, and the system can be used to support the basic functions of electronic devices, such as time display, alarm schedule, physiological data monitoring, call reminders and other functions. The other system in the dual system (such as an Android system) consumes more power during operation, and the system can be used to support complex functions of electronic devices, such as video voice call services, games, audio and video playback, WIFI, power management and other functions. In each embodiment of the present application, the system with less power consumption is referred to as the first operating system, and the system with more power consumption is referred to as the second operating system.

[0029] Among them, the first operating state can be considered as a normal operating state and / or a high-power operating state. The power consumption of the first operating system in the first operating state is relatively small, and it can support the basic functions of the electronic device. The power consumption of the second operating system in the first operating state is relatively large, but it can support the complex functions of the electronic device. The power consumption of the second operating system in other states except the first operating state is relatively small, and generally cannot support the complex functions of the electronic device. Therefore, when the user only needs the electronic device to support basic functions, it is sufficient to control the first operating system to run in the first operating state, without controlling the second operating system to run in the first operating state.

[0030] Since the power consumption of the second operating system is relatively large when it is in the first operating state, the current state of the user can be obtained in real time when both the first operating system and the second operating system are in the first operating state. According to the current state of the user, it is determined whether the current state of the user meets the system state switching condition. If the system state switching condition is met, the operating state of the second operating system can be switched, thereby reducing the power consumption of the electronic device. Among them, the current state of the user includes the sleep state, the do not disturb state, the awake state, etc., which is not limited in this application.

[0031] Step 240: If the current state of the user meets the system state switching condition, the second operating system enters the target operating state; the power consumption of the second operating system in the target operating state is less than the power consumption of the second operating system in the first operating state.

[0032] The system state switching condition is that the user's current state is in a preset state, for example, the preset state includes a sleep state, a do not disturb state, etc. Because the user has lower requirements for the functions supported by the electronic device when in the sleep state or the do not disturb state, the electronic device can meet the user's usage needs by supporting basic functions.

[0033] Specifically, when both the first operating system and the second operating system are in the first operating state, the current state of the user is detected. If the current state of the user meets the system state switching condition, the second operating system is controlled to switch state from the first operating state. Specifically, the second operating system can be controlled to switch from the first operating state to a target operating state corresponding to the current state of the user.

[0034] Among them, the target operating state corresponding to the user's current state refers to linking the operating state of the second operating system with the user's current state so that the operating state of the second operating system matches the user's current state. When the user's current state requires the electronic device to support complex functions, the second operating system needs to be in the first operating state to meet the user's usage needs. That is, when the user's current state only requires the electronic device to support basic functions, the second operating system may not need to be in the first operating state to reduce system power consumption. That is, at this time, the second operating system needs to switch from the first operating state to the target operating state. And the power consumption of the second operating system in the target operating state is less than the power consumption of the second operating system in the first operating state.

[0035] Because users have different requirements for the use of electronic devices in different states. Therefore, if the first operating system and the second operating system on the electronic device are both in the first operating state (normal operating state and / or high-power operating state) at the beginning, this is in line with the user's current state, and the user needs the electronic device to support complex functions. If the user enters the sleep state, that is, the user's current state meets the system state switching conditions, and the user enters the sleep state, it is obvious that the user does not need the electronic device to support complex functions, but only needs the electronic device to support basic functions, and the first operating system can provide basic functions. Therefore, based on the user's current sleep state, the second operating system can be controlled to enter the target operating state corresponding to the user's current sleep state (other operating states except the first operating state). Obviously, the power consumption of the second operating system in the target operating state is less than the power consumption of the second operating system in the first operating state.

[0036] In an embodiment of the present application, a first operating system and a second operating system can be run simultaneously on an electronic device, and the method includes: when both the first operating system and the second operating system are in a first operating state, detecting the current state of the user. If the current state of the user meets the system state switching condition, the second operating system enters the target operating state; the power consumption of the second operating system in the target operating state is less than the power consumption of the second operating system in the first operating state. It is achieved that the second operating system can enter the target operating state according to the current state of the user. Thus, a suitable target operating state can be configured for the second operating system based on the current state of the user, thereby reducing the power consumption of the electronic device while satisfying the user's use.

[0037] In one embodiment, the target operating state includes a sleep state of the second operating system or a shutdown state of the second operating system.

[0038] Specifically, if the user's current state meets the system state switching condition, the second operating system enters the target operating state. The system state switching condition is that the user's current state is in a preset state, for example, the preset state includes a sleep state or a do not disturb state. If the user's current state is in a sleep state or a do not disturb state, then the user only needs the electronic device to support basic functions, and the first operating system can provide basic functions, so the second operating system can be directly controlled to enter a sleep state or a shutdown state.

[0039] The second operating system is in a dormant state, which means that all applications and modules running on the second operating system are in a dormant state, that is, the data under the second operating system is retained in the memory, and the memory is weakly powered, and the power of all devices under the second operating system except the memory is cut off, and the application programs and modules are suspended. Because the memory is not powered off, the data in the memory can be directly read when the second operating system is awakened next time.

[0040] The second operating system being in a shutdown state means that all applications and modules running on the second operating system are in a shutdown state. That is, the power of all devices under the second operating system is cut off, and the applications and modules are closed. Because the memory is also powered off, the second operating system needs to be reinitialized when it is awakened next time to run normally.

[0041] In addition, because the second operating system is running on the CPU, if the second operating system is in different operating states, the CPU will be in different states accordingly. For example, when the second operating system is in a dormant state, the frequency of the CPU will be lower than when the second operating system is in a normal operating state; when the second operating system is in a shutdown state, the frequency of the CPU will be lower than when the second operating system is in a dormant state. Here, this application does not limit the specific data of the CPU frequency.

[0042] In the embodiment of the present application, if the current state of the user meets the system state switching condition, the second operating system enters the target operating state. Specifically, if the current state of the user is in the sleep state or the do not disturb state, then at this time the user only needs the electronic device to support basic functions, and the first operating system can provide basic functions, so the second operating system can be directly controlled to enter the sleep state or the shutdown state. Thus, when the user is in the sleep state or the do not disturb state, the power consumption is minimized while meeting the basic usage needs of the user.

[0043] In one embodiment, if the current state of the user satisfies the system state switching condition, controlling the second operating system to enter the target operating state includes:

[0044] If the user's current state is a sleeping state, the second operating system is controlled to enter a target operating state.

[0045] The system state switching condition is that the user's current state is in a preset state, for example, the preset state includes a sleep state or a do not disturb state. Specifically, if the user's current state is a sleep state, the user's current state meets the system state switching condition, and the second operating system is controlled to enter a sleep state or a shutdown state. If the user's current state is a do not disturb state, the user's current state meets the system state switching condition, and the second operating system is controlled to enter a sleep state or a shutdown state.

[0046] As shown in FIG3 , a power consumption adjustment method is provided, including:

[0047] Step 320, when both the first operating system and the second operating system are in the first operating state, detecting the current state of the user;

[0048] Step 340, if the user is currently in a sleeping state, control the second operating system to enter a dormant state or a shutdown state;

[0049] Step 360: If the user's current state is the Do Not Disturb state, control the second operating system to enter a sleep state or a shutdown state.

[0050] In the embodiment of the present application, if the current state of the user satisfies the system state switching condition, for example, if the current state of the user is in the sleep state, the current state of the user satisfies the system state switching condition, and the second operating system is controlled to enter the sleep state or the shutdown state. If the current state of the user is in the do not disturb state, the current state of the user satisfies the system state switching condition, and the second operating system is controlled to enter the sleep state or the shutdown state. Thus, the second operating system is controlled to enter the corresponding state according to the current state of the user, so as to achieve the goal of minimizing power consumption while meeting the basic usage needs of the user.

[0051] In one embodiment, the process of the second operating system entering the target operating state includes:

[0052] Transferring the control authority of the first module from the second operating system to the first operating system; the first module is a common calling module of the first operating system and the second operating system;

[0053] And / or, controlling a second module running under a second operating system to enter a target running state.

[0054] As shown in FIG4 , it is a schematic diagram of the modules mounted under the first operating system and the second operating system in the electronic device. Among them, the common calling module that can be called by both the first operating system and the second operating system is the first module 420, including a display module (LCD, Liquid crystal display), a touch module (TP, Touch Panel), etc., which is not limited in this application. Setting up the common calling module can satisfy the normal use of common calling modules such as the display module (LCD), the touch module (TP) and the like by users under any operating system.

[0055] The module that can only be called by the second operating system is the second module 440, including a WIFI module, a modem (MODEM), a memory (EMMC), a power management module (PMIC, Power Management IC), a sound module (AUDIO), etc., which is not limited in this application. Based on the second module 440, the second operating system can be used to support complex functions of the electronic device, such as video and voice call services, games, and audio and video playback.

[0056] The modules that can only be called by the first operating system, namely the third module 460, include GPS module, A+G module (accelerometer acc and gyroscope gyro), heart rate sensor (PPG, Photo Plethysmo Graphy), barometer (BAROMETER), electrocardiogram (ECG, Electrocardiograph), light sensor (LIGHT SENSOR), Bluetooth module (BT, Bluetooth), etc., and this application does not limit this. Based on the above third module 460, the first operating system can be used to support basic functions of electronic devices, such as time display, alarm schedule, physiological data monitoring, call reminder and other functions.

[0057] If the user's current state meets the system state switching conditions, the second operating system enters the target operating state. In one case, the process of the second operating system entering the target operating state includes: transferring the control authority of the first module from the second operating system to the first operating system; the first module is a common call module of the first operating system and the second operating system; and controlling the second module running under the second operating system to enter the target operating state. That is, if the user's current state meets the system state switching conditions, the control authority of the first module is transferred from the second operating system to the first operating system, that is, at this time the second operating system does not have the control authority to call the common call module, and the first operating system has the control authority to call the common call module. At the same time, the second operating system controls the second module to enter a dormant state or a shutdown state.

[0058] In another case, the process of the second operating system entering the target operating state includes: transferring the control authority of the first module from the second operating system to the first operating system; the first module is a common call module of the first operating system and the second operating system; or, controlling the second module running under the second operating system to enter the target operating state. Here, it is divided into two cases. The first case is that the control authority of the first module is transferred from the second operating system to the first operating system, and the second operating system does not control the second module. The second case is that the second module running under the second operating system is controlled to enter a dormant state or a shutdown state, and does not control the first module.

[0059] In the embodiment of the present application, the modules in the electronic device are divided into a common calling module that can be called by both the first operating system and the second operating system, a module that can be called only by the first operating system, and a module that can be called only by the second operating system, so that when controlling the second operating system to enter the target operating state, the common calling module or the module that can be called only by the second operating system can be directly and accurately controlled. Thus, the second operating system can be finally accurately controlled to enter the target operating state.

[0060] In one embodiment, transferring the control authority of the first module from the second operating system to the first operating system includes:

[0061] A control authority transfer instruction is sent to the second operating system through the first operating system; the control authority transfer instruction is used to instruct the second operating system to transfer the control authority of the first module to the first operating system.

[0062] Among them, the common calling module that can be called by both the first operating system and the second operating system is the first module, including a display module (LCD), a touch module (TP), etc., and this application does not limit this. The process of the second operating system entering the target operating state includes: transferring the control authority of the first module from the second operating system to the first operating system. Specifically, the first operating system sends a control authority transfer instruction to the second operating system, and after the second operating system receives the control authority transfer instruction, the second operating system transfers the control authority of the first module to the first operating system. For example, the second operating system transfers the control authority of calling the display module (LCD), the touch module (TP), etc. to the first operating system.

[0063] In the embodiment of the present application, the first operating system sends a control authority transfer instruction to the second operating system. After the second operating system receives the control authority transfer instruction, the second operating system transfers the control authority of the first module to the first operating system. This is equivalent to handing over the control right of the first module to the first operating system. After the second operating system enters the dormant state or the shutdown state, the first operating system can continue to control the first module, which does not affect the user's calling of the first module under the first operating system.

[0064] In one embodiment, controlling the second module running under the second operating system to enter a target running state includes:

[0065] A control instruction is sent to the second operating system through the first operating system; the control instruction is used to control the second module running under the second operating system to enter a target operating state.

[0066] Among them, the module that can only be called by the second operating system is the second module, including a WIFI module, a modem (MODEM), a memory (EMMC), a power management module (PMIC, Power Management IC), a sound module (AUDIO), etc., and this application does not limit this.

[0067] Controlling the second module running under the second operating system to enter a target operating state includes: sending a control instruction to the second operating system through the first operating system, the second operating system receiving the control instruction, and controlling the second module running under the second operating system to enter the target operating state according to the control instruction. For example, controlling the second module running under the second operating system to enter a dormant state or a shutdown state according to the control instruction.

[0068] In the embodiment of the present application, when controlling the second module running under the second operating system to enter the target operating state, it includes: sending a control instruction to the second operating system through the first operating system, the second operating system receiving the control instruction, and controlling the second module running under the second operating system to enter the target operating state according to the control instruction. Because the operating power consumption of the first operating system is relatively low, the first operating system controls the second module under the second operating system to enter a dormant state or a shutdown state. Thus, only the first operating system continues to be in the first operating state on the electronic device, and the power consumption of the electronic device is reduced while ensuring that the user can use the first operating system normally.

[0069] In one embodiment, a power consumption adjustment method is provided, further comprising:

[0070] When the user is in a non-sleeping state, the second operating system restores the first operating state from the target operating state.

[0071] As shown in FIG5 , a power consumption adjustment method is provided, including:

[0072] Step 520, when both the first operating system and the second operating system are in the first operating state, detecting the current state of the user;

[0073] Step 540, determining whether the user's current state is a sleeping state;

[0074] Step 560: If the user is currently in a sleeping state, the second operating system enters a target operating state.

[0075] Step 580: If the user enters a non-sleep state from a sleep state, the second operating system restores the first operating state from the target operating state.

[0076] The first operating state can be considered as a normal operating state and / or a high-power operating state, that is, the second operating system has a large power consumption in the first operating state and can support complex functions of the electronic device. The second operating system has a small power consumption in other states except the first operating state and generally cannot support complex functions of the electronic device.

[0077] Specifically, the current state of the user can be obtained when both the first operating system and the second operating system are in the first operating state. According to the current state of the user, it is determined whether the current state of the user meets the system state switching condition. If the system state switching condition is met, the operating state of the second operating system can be switched, thereby reducing the power consumption of the electronic device. Among them, the system state switching condition is that the current state of the user is in a preset state, for example, the preset state includes a sleep state or a do not disturb state.

[0078] If the user is currently in a sleeping state, the system state switching condition is met, and the second operating system is controlled to enter the target operating state, that is, the second operating system is controlled to enter a dormant state or a shutdown state. Because the user is in a sleeping state, the functional requirements of the electronic device are relatively low, and only basic functions are required to meet the user's usage needs. The first operating system can provide basic functions, so the second operating system can be controlled to enter a dormant state or a shutdown state.

[0079] Continue to detect the user's current state. If the user enters a non-sleep state from a sleep state, control the second operating system to restore the first operating state from the target operating state. Because the user enters a non-sleep state, the user's functional requirements for the electronic device will increase. Not only basic functions but also complex functions are required. The first operating system can only provide basic functions, so it is necessary to control the second operating system to restore the first operating state to provide complex functions. Specifically, restore the second operating system's call permission to the first module, and control the second module running under the second operating system to restore the first operating state.

[0080] In an embodiment of the present application, when both the first operating system and the second operating system are in the first operating state, the current state of the user is obtained in real time. If the user is in a sleeping state, the second operating system enters the target operating state. The current state of the user continues to be detected. If the user is in a non-sleeping state, the second operating system restores the first operating state from the target operating state. If the current state of the user changes, the second operating system also switches the state accordingly. Thus, based on the current state of the user, the second operating system is controlled to be in a state that matches the current state of the user, so as to meet the user's usage needs and reduce the power consumption of the electronic device.

[0081] In one embodiment, as shown in FIG6 , obtaining the current state of the user includes: when the user is wearing or holding the electronic device, determining the current state of the user based on the motion information and / or heart rate data. The specific process includes:

[0082] Step 620: Detect the distance information between the user and the electronic device through the distance sensor, and determine whether the user is wearing or holding the electronic device based on the distance information.

[0083] The electronic device is equipped with a distance sensor, an acceleration sensor and a heart rate sensor. Among them, the distance sensor, also known as a proximity sensor, is a sensor that uses time measurement to measure distance. Its working principle is: by emitting a light pulse and measuring the time from the emission of the light pulse to the reflection of the object, the distance between the distance sensor and the object is calculated by measuring the time. When detecting the current state of the user, the distance sensor is first used to detect the distance information of the user from the electronic device (on which the distance sensor is installed), and the distance information is used to determine whether the user is wearing or holding the electronic device. For example, a preset distance threshold is set. If the distance information of the user from the electronic device detected by the distance sensor is less than the preset distance threshold (for example, 1CM), it is concluded that the user is currently wearing or holding the electronic device. If the distance information of the user from the electronic device detected by the distance sensor is greater than or equal to the preset distance threshold (for example, 1CM), it is concluded that the user is not currently wearing or holding the electronic device. The above preset distance threshold can be determined according to empirical values ​​in practice, or it can be set to other values, and is not limited to the above 1CM.

[0084] Step 640: If yes, detecting the user's motion information through an acceleration sensor; and / or

[0085] Step 660, if yes, detect the user's heart rate data through the heart rate sensor;

[0086] Step 680, determining the user's current state based on the motion information and / or heart rate data.

[0087] If the distance information between the user and the electronic device detected by the distance sensor is less than the preset distance threshold, it is concluded that the user is currently wearing or holding the electronic device. Then the user's motion information is detected by the acceleration sensor, specifically, the three-axis acceleration of the electronic device is detected in real time by the acceleration sensor. The user's motion information can be determined by the three-axis acceleration of the electronic device within a preset time length. For example, if the average of the three-axis acceleration of the electronic device within the preset time length is greater than the preset acceleration threshold, it is determined that the user is in motion; if the average of the three-axis acceleration of the electronic device within the preset time length is less than or equal to the preset acceleration threshold, it is determined that the user is in a stationary state.

[0088] If the distance information between the user and the electronic device detected by the distance sensor is less than the preset distance threshold, it is concluded that the user is currently wearing or holding the electronic device, and then the heart rate sensor PPG is used to detect the user's heart rate data. Among them, the heart rate sensor PPG uses photoplethysmography to detect heart rate data. The PPG technology used refers to the use of an optical heart rate sensor, through the light-emitting diode on the sensor to emit light of a specific color wavelength into the epidermis of a specific part of the human body, and then the photosensitive sensor receives the corresponding reflected light or incident light to achieve the purpose of detecting the pulse signal.

[0089] The motion information and / or heart rate data are input into the sleep detection algorithm to determine the current state of the user, which may include three situations. Among them, the first situation is: after the distance information of the user and the electronic device is detected by the distance sensor and is less than the preset distance threshold, it is concluded that the user is currently wearing or holding the electronic device, and the user's motion information is directly detected by the acceleration sensor. Finally, the current state of the user is determined based on the motion information. For example, if the acceleration sensor detects that the user is in a motion state, there is no need for subsequent heart rate detection, and it is concluded that the user is in a non-sleep state at this time. Thereby, the power consumption waste caused by the subsequent heart rate detection process is avoided.

[0090] The second situation is: after the distance information of the user from the electronic device is detected by the distance sensor to be less than the preset distance threshold, it is concluded that the user is currently wearing or holding the electronic device, and the heart rate data of the user is directly detected by the heart rate sensor. Finally, the current state of the user is determined based on the heart rate data. For example, if the heart rate data corresponding to the sleep state is set to 60-80 times / min, if the heart rate data of the user detected by the heart rate sensor falls between 60-80 times / min, it can be determined that the user is currently in a sleep state. If the heart rate data of the user detected by the heart rate sensor exceeds 80 times / min, it can be determined that the user is currently in a non-sleep state. Of course, the above heart rate data is just an example. In practice, it needs to be set accordingly according to the different physiological conditions of each user to meet the individual differences of the user. That is, if the heart rate data of the user detected by the heart rate sensor falls within the heart rate data range corresponding to the sleep state, the user's motion information can be detected without detecting it, and it is determined that the user is in a sleep state.

[0091] The third situation is: after the distance sensor detects that the distance information between the user and the electronic device is less than the preset distance threshold, it is concluded that the user is currently wearing or holding the electronic device, and then the user's motion information is detected by the acceleration sensor, and then the user's heart rate data is detected by the heart rate sensor. Finally, the user's current state is determined based on the user's motion information and heart rate data. The user's current state is determined from two dimensions, and the accuracy of the user's current state is higher. For example, the acceleration sensor determines that the user is in a stationary state at this time, and the user's heart rate data falls between 60-80 times / min within the preset time length, then it can be determined from two dimensions that the user is currently in a sleeping state.

[0092] In the embodiment of the present application, after the distance sensor detects that the distance between the user and the electronic device is less than a preset distance threshold, it is concluded that the user is currently wearing or holding the electronic device, and the user's current state is determined based on the user's motion information and / or heart rate data. Using multiple methods to determine the user's current state is more flexible and diverse.

[0093] In one embodiment, the first module includes at least one of a display module, a touch module, a button module, and a motor module.

[0094] In the embodiment of the present application, because the display module, touch module, button module, and motor module are generally modules that both the first operating system and the second operating system need to call, at least one of the display module, touch module, button module, and motor module is set as the first module, i.e., the common call module. So that both the first operating system and the second operating system can call any one of the common call modules. And when controlling the second operating system to enter the target operating state, it is convenient to directly prohibit the second operating system from calling the common call module. Thereby, the control of the second operating system to enter the target operating state is realized, thereby reducing the power consumption of the electronic device while satisfying the user's use.

[0095] In one embodiment, the second module includes at least one of a WIFI module, a modem, a memory, a power management module, and a sound module.

[0096] Among them, the module that can only be called by the first operating system, namely the third module, includes GPS module, A+G module (accelerometer acc and gyroscope gyro), heart rate sensor (PPG, Photo Plethysmo Graphy), barometer (BAROMETER), electrocardiogram (ECG, Electrocardiograph), light sensor (LIGHT SENSOR), Bluetooth module (BT, Bluetooth), etc., and this application does not limit this. Based on the above third module, the first operating system can be used to support the basic functions of electronic equipment, such as time display, alarm schedule, physiological data monitoring, call reminder and other functions.

[0097] The module that can only be called by the second operating system is the second module, including the WIFI module, modem (MODEM), memory (EMMC), power management module (PMIC, Power Management IC), sound module (AUDIO), etc., which is not limited in this application. Based on the second module, the second operating system can be used to support complex functions of the electronic device, such as video and voice call services, games, audio and video playback, etc.

[0098] In the embodiment of the present application, the module that can be called by the second operating system is the second module, which includes at least one of a WIFI module, a modem, a memory, a power management module, and a sound module. Therefore, based on the second module, the second operating system can be used to support complex functions of the electronic device, such as video and voice call services, games, and audio and video playback. So that when the second operating system is in the first operating state, it can meet the user's normal use of complex functions on the electronic device.

[0099] In one embodiment, the first operating system is an RTOS system, and the second operating system is an Android system.

[0100] Among them, RTOS (real-time operating system) refers to an operating system that can accept and process external events or data at a sufficiently fast speed when they are generated, and its processing results can control the production process or respond quickly to the processing system within the specified time, and control all real-time tasks to run in a coordinated and consistent manner. Therefore, the main characteristics of the RTOS system are the ability to provide timely response and high reliability.

[0101] Among them, Android system generally refers to Android, which is a free and open source operating system based on the Linux kernel.

[0102] In an embodiment of the present application, dual systems can be run simultaneously in an electronic device, and the dual systems include a first operating system and a second operating system. Among them, the first operating system is an RTOS system, which can be used to support the basic functions of the electronic device, and the RTOS system runs on an MCU (Microcontroller Unit). The second operating system is an Android system, which can be used to support the complex functions of the electronic device, and the Android system runs on the main CPU. In Figure 10 below, the first processor and the second processor are the main CPU and the MCU, respectively.

[0103] In this way, when the first operating system and the second operating system are both in normal operating state and / or high-power operating state, the current state of the user is detected. If the current state of the user meets the system state switching condition, the second operating system is controlled to enter the sleep state or the shutdown state, that is, the second operating system does not support the complex functions of the electronic device for the time being. The basic functions of the electronic device can be supported by the first operating system. Because the power consumption of the second operating system in the sleep state or the shutdown state is less than the power consumption of the second operating system in the normal operating state and / or the high-power operating state, it is achieved that the power consumption of the electronic device is reduced while satisfying the basic functions of the user's use of the electronic device.

[0104] In a specific embodiment, a power consumption adjustment method is provided, which is applied to an electronic device, where an RTOS system and an Android system can be run simultaneously on the electronic device, and when the electronic device is turned on, both the RTOS system and the Android system are in a first running state; as shown in FIG7 , the power consumption adjustment method includes:

[0105] Step 702, the RTOS system detects the distance information between the user and the electronic device in real time through the distance sensor, and determines whether the user is wearing or holding the electronic device according to the distance information; if so, proceed to step 704;

[0106] Step 704, the RTOS system detects the user's motion information in real time through the acceleration sensor and detects the user's heart rate data in real time through the heart rate sensor, and determines the user's current state in real time based on the motion information and the heart rate data;

[0107] Step 706: If the RTOS system determines that the user is in a sleeping state, the RTOS system sends a notification message to the Android system, and the notification message carries a shutdown instruction;

[0108] Step 708, after receiving the notification information, the Android system shuts down;

[0109] Step 710: If the RTOS system detects that the user has recovered from the sleep state to the non-sleep state, the RTOS system sends a notification message to the Android system, and the notification message carries a boot instruction;

[0110] Step 712: After receiving the notification information, the Android system restarts the device.

[0111] In an embodiment of the present application, when both the first operating system and the second operating system are in the first operating state, the current state of the user is detected in real time. If the current state of the user is a sleeping state, the second operating system is controlled to enter a target operating state. The current state of the user continues to be detected. If the user enters a non-sleeping state from a sleeping state, the second operating system is controlled to restore the first operating state from the target operating state. If the current state of the user changes, the second operating system is controlled to switch states accordingly. Thus, based on the current state of the user, the second operating system is controlled to be in a state that matches the current state of the user, thereby satisfying the user's usage needs and reducing the power consumption of the electronic device.

[0112] In one embodiment, as shown in FIG8 , a power consumption adjustment device 800 is provided, which is applied to an electronic device, and the electronic device can run a first operating system and a second operating system at the same time, and the device includes:

[0113] The user status detection module 820 is used to obtain the current status of the user when the first operating system and the second operating system are both in the first operating state;

[0114] The system operation state switching module 840 is used to enable the second operating system to enter a target operation state if the user's current state meets the system state switching condition; the power consumption of the second operating system in the target operation state is less than the power consumption of the second operating system in the first operation state.

[0115] In one embodiment, the target operating state includes a sleep state of the second operating system or a shutdown state of the second operating system.

[0116] In one embodiment, the system operation state switching module 840 is further configured to enable the second operating system to enter a target operation state if the user is currently in a sleep state.

[0117] In one embodiment, the system operation state switching module 840 is also used to transfer the control authority of the first module from the second operating system to the first operating system; the first module is a common call module of the first operating system and the second operating system; and / or, control the second module running under the second operating system to enter the target operation state.

[0118] In one embodiment, the system operation state switching module 840 is further used to send a control authority transfer instruction to the second operating system through the first operating system; the control authority transfer instruction is used to instruct the second operating system to transfer the control authority of the first module to the first operating system.

[0119] In one embodiment, the system operation state switching module 840 is further used to send a control instruction to the second operating system through the first operating system; the control instruction is used to control the second module running under the second operating system to enter the target operation state.

[0120] In one embodiment, as shown in FIG9 , a power consumption adjustment device is provided, further comprising:

[0121] The system operation state recovery module 860 is used to control the second operating system to recover the first operation state from the target operation state when the user is in a non-sleeping state.

[0122] In one embodiment, the user status detection module 820 is used to determine the user's current status based on motion information and / or heart rate data when the user wears or holds the electronic device.

[0123] In one embodiment, the first module includes at least one of a display module, a touch module, a button module, and a motor module.

[0124] In one embodiment, the second module includes at least one of a WIFI module, a modem, a memory, a power management module, and a sound module.

[0125] In one embodiment, the first operating system is an RTOS system, and the second operating system is an Android system.

[0126] It should be understood that, although the various steps in the flowcharts in the above-mentioned figures are displayed in sequence according to the indications of the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps is not strictly limited in order, and these steps can be executed in other orders. Moreover, at least a portion of the steps in the above-mentioned figures may include a plurality of sub-steps or a plurality of stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these sub-steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a portion of the sub-steps or stages of other steps.

[0127] The division of the various modules in the above power consumption regulating device is only for illustration. In other embodiments, the power consumption regulating device may be divided into different modules as needed to complete all or part of the functions of the above power consumption regulating device.

[0128] For the specific definition of the power consumption adjustment device, please refer to the definition of the power consumption adjustment method above, which will not be repeated here. Each module in the above power consumption adjustment device can be implemented in whole or in part by software, hardware and a combination thereof. The above modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.

[0129] In one embodiment, an electronic device is provided, including a memory and a processor. A computer program is stored in the memory. When the computer program is executed by the processor, the processor executes the steps of a power consumption adjustment method provided in the above embodiments.

[0130] FIG10 is a schematic diagram of the internal structure of an electronic device in an embodiment. As shown in FIG10 , the electronic device includes a first processor, a second processor and a memory connected via a system bus. The first processor and the second processor are used to provide computing and control capabilities to support the operation of the entire electronic device. The memory may include a non-volatile storage medium and an internal memory. The non-volatile storage medium stores a first operating system, a second operating system and a computer program, wherein the first operating system and the second operating system can be switched with each other or run simultaneously. The computer program can be executed by the first processor and the second processor to implement a power consumption adjustment method provided in each of the above embodiments. The internal memory provides a cache operating environment for the operating system computer program in the non-volatile storage medium. The electronic device can be any terminal device such as a mobile phone, a tablet computer, a PDA (Personal Digital Assistant), a POS (Point of Sales), a vehicle-mounted computer, a wearable device, a smart home, etc.

[0131] The implementation of each module in the power consumption adjustment device provided in the embodiment of the present application may be in the form of a computer program. The computer program may be run on an electronic device or an electronic device. The program module constituted by the computer program may be stored in the memory of the electronic device or the electronic device. When the computer program is executed by the processor, the steps of the method described in the embodiment of the present application are implemented.

[0132] The embodiment of the present application also provides a computer-readable storage medium, one or more non-volatile computer-readable storage media containing computer-executable instructions, which, when executed by one or more processors, enable the processors to perform the steps of the power consumption adjustment method.

[0133] A computer program product comprising instructions, when executed on a computer, causes the computer to perform a power consumption adjustment method.

[0134] Any reference to memory, storage, database or other media used in the embodiments of the present application may include non-volatile and / or volatile memory. Suitable non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM), which is used as an external cache memory. As an illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM) and memory bus dynamic RAM (RDRAM).

[0135] The above power consumption adjustment embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.

Claims

1. A power consumption adjustment method, characterized in that: Applied to an electronic device, the electronic device is a wearable device, and the electronic device can run a first operating system and a second operating system at the same time, the method includes: Get the user's current status; If the current state of the user meets the system state switching condition, the second operating system enters the target running state.

2. The method according to claim 1, characterized in that The target operating state includes a dormant state of the second operating system or a shutdown state of the second operating system.

3. The method according to claim 1 or 2, characterized in that: The obtaining of the current status of the user includes: When both the first operating system and the second operating system are in a first operating state, obtaining a current state of a user; The power consumption of the second operating system in the target operating state is less than the power consumption of the second operating system in the first operating state.

4. The method according to claim 1 or 2, characterized in that: The power consumption of the second operating system is greater than the power consumption of the first operating system.

5. The method according to claim 1 or 2, characterized in that: If the current state of the user satisfies the system state switching condition, the second operating system enters the target running state, including: If the current state of the user is a sleeping state or a do not disturb state, the second operating system enters the target operating state.

6. The method according to claim 1 or 2, characterized in that: The method further comprises: When the user is in a non-sleeping state, the second operating system restores the first operating state from the target operating state.

7. The method according to claim 2, characterized in that The target operating state is a shutdown state, and the method further includes: When the first operating system detects that the user resumes from a sleep state to a non-sleep state, the first operating system sends a notification message to the second operating system, where the notification message carries a boot instruction; After receiving the notification information, the second operating system restarts.

8. The method according to claim 1 or 2, characterized in that: The first operating system is a real-time operating system; and / or, the second operating system is an Android system; and / or, the second operating system is a free and open source operating system based on the Linux kernel.

9. The method according to claim 1 or 2, characterized in that: The process of the second operating system entering the target running state includes: The control authority of the first module is transferred from the second operating system to the first operating system; the first module is a common calling module of the first operating system and the second operating system.

10. A power consumption adjustment device, characterized in that: Applied to an electronic device, the electronic device is a wearable device, and the electronic device can run a first operating system and a second operating system at the same time, the device includes: User status detection module, used to obtain the user's current status; The system operation state switching module is used to enable the second operating system to enter a target operation state if the current state of the user meets the system state switching condition.

11. An electronic device comprising a memory and a processor, wherein a computer program is stored in the memory, wherein: When the computer program is executed by the processor, the processor is caused to perform the steps of the power consumption adjustment method according to any one of claims 1 to 9.

12. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the power consumption adjustment method according to any one of claims 1 to 9 are implemented.

Citation Information

Patent Citations

  • Computer of hybrid system

    CN101714021A

  • Mode switching method of wearable equipment and wearable equipment

    CN106293071A

  • Application method for dual operation systems, storage device and intelligent terminal

    CN107491160A

  • Data processing method and device, and computer readable storage medium

    CN111782281A

  • Information interaction method and device, electronic equipment and readable storage medium

    CN111951921A