Power consumption management method and device, electronic equipment and medium
By displaying power consumption information of background applications or processes on electronic devices, users can manage these target objects, solve power consumption problems caused by the abuse of background resources, extend the device standby time, and improve user experience.
Patent Information
- Application Number
- CN202311480323.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-11-08
- Publication Date
- 2025-05-09
AI Technical Summary
Applications or processes running in the background of electronic devices abuse resources in a state that is unaware of the user, resulting in serious power consumption, shortening standby time, and affecting the user experience.
Provides a power consumption management method, by displaying the power consumption information of the target object in the preset time period, including operating status and power consumption behavior, allowing users to manage the target object according to their own needs, avoiding unnecessary waste of power resources.
Detailed display of the power resource consumption of the target object, help users to manage accurately, reduce resource abuse, extend the standby time of equipment, and improve user experience.
Smart Images

Figure CN119967544A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of electronic devices, and in particular to a power consumption management method, device, electronic device and medium. Background Art
[0002] When using electronic devices such as mobile phones, the standby time of the electronic devices has a great impact on the user experience. However, when users are using electronic devices, background operations will abuse various resources in the electronic devices without the user's awareness, causing serious power consumption of the electronic devices and greatly shortening the standby time of the electronic devices.
[0003] Therefore, it is necessary to manage the power consumption of electronic devices such as mobile phones. Summary of the invention
[0004] In order to overcome the problems existing in the related art, the present disclosure provides a power consumption management method, device, electronic device and medium.
[0005] According to a first aspect of an embodiment of the present disclosure, a power consumption management method is provided, which is applied to an electronic device. The power consumption management method includes:
[0006] In response to the first operation, displaying power consumption information of a target object in the electronic device in a preset time period, wherein the power consumption information includes an operating state and power consumption behavior of the target object;
[0007] Based on the second operation, the target object is managed.
[0008] In some embodiments, the power consumption management method further includes:
[0009] In response to a third operation, power consumption detection is performed on the application and process running in the background of the electronic device, wherein the third operation is used to indicate that the application and the process are switched from foreground operation to background operation;
[0010] The application program and the process having a preset power consumption behavior are determined as the target objects.
[0011] In some embodiments, the preset power consumption behavior includes a first behavior of occupying hardware resources of the electronic device and / or a second behavior of occupying network resources of the electronic device.
[0012] In some embodiments, the first behavior includes at least one of the following behaviors:
[0013] Invoking a sensor of the electronic device;
[0014] Calling the GPS;
[0015] Call the audio device;
[0016] The central processing unit of the electronic device is called.
[0017] In some embodiments, the second behavior includes at least one of the following behaviors:
[0018] Use of data traffic of the electronic device;
[0019] Using a mobile hotspot of the electronic device.
[0020] In some embodiments, managing the target object based on the second operation includes:
[0021] Based on the second operation, displaying a management method for the target object;
[0022] The target object is managed based on the selected management method.
[0023] In some embodiments, the management method includes at least one of the following methods:
[0024] prohibiting the target object from running in the background;
[0025] Stopping the power consumption behavior of the target object that is currently running in the background;
[0026] The target object is permanently prohibited from performing the power-consuming behavior while running in the background.
[0027] In some embodiments, the power consumption management method further includes:
[0028] In response to the third operation, displaying the first control;
[0029] The step of displaying the power consumption information of the target object in the electronic device in a preset time period in response to the first operation includes:
[0030] In response to the first operation acting on the first control, the power consumption information of each of the target objects in the preset time period is displayed in a list.
[0031] In some embodiments, the power consumption management method further includes:
[0032] In response to the fourth operation, the target objects are sorted in descending order of power consumption according to the power consumption of the power consumption behavior of the target objects.
[0033] In some embodiments, the power consumption information also includes the duration of the power consumption behavior and / or the number of times the power consumption behavior occurs.
[0034] According to a second aspect of an embodiment of the present disclosure, there is provided a power consumption management device, which is applied to an electronic device, and the power consumption management device includes:
[0035] A first processing module, configured to display power consumption information of a target object in the electronic device in a preset time period in response to a first operation, wherein the power consumption information includes an operating state and power consumption behavior of the target object;
[0036] The second processing module is used to manage the target object based on the second operation.
[0037] In some embodiments, the power consumption management device further includes:
[0038] A third processing module, the third processing module is used for:
[0039] In response to a third operation, power consumption detection is performed on the application and process running in the background of the electronic device, wherein the third operation is used to indicate that the application and the process are switched from foreground operation to background operation;
[0040] The application program and the process having a preset power consumption behavior are determined as the target objects.
[0041] In some embodiments, the preset power consumption behavior includes a first behavior of occupying hardware resources of the electronic device and / or a second behavior of occupying network resources of the electronic device.
[0042] In some embodiments, the first behavior includes at least one of the following behaviors:
[0043] Invoking a sensor of the electronic device;
[0044] Calling the GPS;
[0045] Call the audio device;
[0046] The central processing unit of the electronic device is called.
[0047] In some embodiments, the second behavior includes at least one of the following behaviors:
[0048] Use of data traffic of the electronic device;
[0049] Using a mobile hotspot of the electronic device.
[0050] In some embodiments, the second processing module is specifically configured to:
[0051] Based on the second operation, displaying a management method for the target object;
[0052] The target object is managed based on the selected management method.
[0053] In some embodiments, the management method includes at least one of the following methods:
[0054] prohibiting the target object from running in the background;
[0055] Stopping the power consumption behavior of the target object that is currently running in the background;
[0056] The target object is permanently prohibited from performing the power-consuming behavior while running in the background.
[0057] In some embodiments, the power consumption management device further includes:
[0058] A fourth processing module, wherein the fourth processing module is used for:
[0059] In response to the third operation, displaying the first control;
[0060] The step of displaying the power consumption information of the target object in the electronic device in a preset time period in response to the first operation includes:
[0061] In response to the first operation acting on the first control, the power consumption information of each of the target objects in the preset time period is displayed in a list.
[0062] In some embodiments, the power consumption management device further includes:
[0063] The sorting module is used to sort the target objects in descending order of power consumption according to the power consumption of the power consumption behavior of the target objects in response to the fourth operation.
[0064] In some embodiments, the power consumption information also includes the duration of the power consumption behavior and / or the number of times the power consumption behavior occurs.
[0065] According to a third aspect of an embodiment of the present disclosure, there is provided an electronic device, including:
[0066] processor;
[0067] a memory for storing processor-executable instructions;
[0068] The processor is configured to execute the power consumption management method as described in the first aspect of the present disclosure.
[0069] According to a fourth aspect of an embodiment of the present disclosure, a non-temporary computer-readable storage medium is provided. When instructions in the storage medium are executed by a processor of an electronic device, the electronic device can execute the power consumption management method as described in the first aspect of the present disclosure.
[0070] The above-mentioned method disclosed in the present invention has the following beneficial effects: the power consumption management method in the present invention can display the operating status and power consumption behavior of the target object in detail to the user, so that the user can accurately know the power resource consumption during the operation of the target object. The user can then manage the target object according to his or her own usage needs, avoiding the target object from abusing various resources in the electronic device and causing unnecessary waste of power resources, increasing the standby time of the electronic device, and improving the user's usage experience.
[0071] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0072] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.
[0073] Figure 1 is a flow chart showing a method for managing power consumption according to an exemplary embodiment.
[0074] Figure 2 is a flow chart showing a method for managing power consumption according to an exemplary embodiment.
[0075] Figure 3 is a flow chart showing a method for managing power consumption according to an exemplary embodiment.
[0076] Figure 4 is a schematic diagram showing power consumption information according to an exemplary embodiment.
[0077] Figure 5 It is a block diagram of a power consumption management device according to an exemplary embodiment.
[0078] Figure 6 It is a block diagram of an electronic device according to an exemplary embodiment. DETAILED DESCRIPTION
[0079] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present disclosure. Instead, they are merely examples of devices and methods consistent with some aspects of the present disclosure as detailed in the appended claims.
[0080] With the advancement of science and technology, mobile phones and other electronic devices have become necessities of people's lives. Electronic devices have independent operating systems and independent operating spaces, which are not only easy to carry, but also can meet users' requirements for a rich Internet experience in application functions such as entertainment, business, news and services. However, during the use of mobile phones and other electronic devices, applications or processes running in the background of electronic devices are likely to abuse various resources of electronic devices without the user's awareness, resulting in serious power consumption of electronic devices, greatly shortening the standby time of electronic devices, and thus giving users a bad user experience.
[0081] In the related art, power consumption management is usually performed based on the historical power consumption information of applications or processes, and an entry is provided for users to stop the operation of applications or processes. However, the running status and power consumption behavior of applications or processes cannot be accurately located, and users cannot accurately understand the reasons for abnormal power consumption behavior. For example, users cannot know whether the application or process is consuming power normally or abnormally; nor can the current status of the application or process be accurately located. For example, users cannot know what operation the application or process is performing. Since the power consumption cause / current status of the application or process cannot be accurately located, users cannot accurately manage the application or process, and problems such as mistakenly closing the application or not accurately closing the application that abuses resources occur, resulting in a poor user experience when managing power consumption.
[0082] In order to solve the above problems, the present disclosure provides a power consumption management method, which is applied to electronic devices. The power consumption management method in the present disclosure displays the operating status and power consumption behavior of a target object running on the electronic device to the user, so that the user can know in detail the power resource consumption during the operation of the target object, thereby facilitating the user to manage the target object according to their own usage needs, thereby minimizing the abuse of power resources, increasing the standby time of the electronic device, and improving the user's usage experience.
[0083] The exemplary embodiments of the present disclosure provide a power consumption management method, which is applied to electronic devices, which can be smart devices that can run applications or processes, such as mobile phones, tablet computers, notebooks, smart robots, and smart wearable devices. In addition, the electronic devices are also provided with various hardware resources and energy storage devices that provide power for the operation of various hardware resources.
[0084] like Figure 1 As shown, the power consumption management method shown in the present disclosure includes:
[0085] S101. In response to a first operation, display power consumption information of a target object in an electronic device in a preset time period.
[0086] S102: Manage the target object based on the second operation.
[0087] In step S101, the power consumption information includes the running state and power consumption behavior of the target object. Among them, the target object in the present disclosure can be an application, and can also be a process, such as a push process, a service process, or a phone service process. The application can be, for example, a payment application, a camera application, a shopping application, or a quick application. The number of target objects can be multiple, such as including both applications running in the foreground and applications or processes running in the background. The target object may also not include applications running in the foreground, but only applications or processes running in the background.
[0088] Among them, the foreground operation of the running state of the target object refers to the application currently being used by the user and the process related to the application. The background operation of the target object means that the user is not currently operating or displaying on the display screen, but switching to the background to run the application and related processes. Whether the application or process is running in the foreground or in the background, according to the type of application, it will call the hardware resources set on the electronic device, such as the global positioning system, the central processing unit, or the sensor of the electronic device, thereby generating power consumption behavior. For the power consumption behavior of the application or process, some behaviors are necessary to provide users with better services, while some behaviors not only cannot provide users with a better user experience, but also consume a lot of power and hardware resources, such as the application running in the background occupying network resources to download or upload data; for example, the process running in the background occupies the computing resources of the central processing unit; for example, the application running in the background constantly calls the global positioning system for positioning. All of the above behaviors are resource abuse behaviors, which will consume a lot of power during the process of these resource abuse behaviors, and are all abnormal power consumption behaviors, which greatly shorten the standby time of electronic devices.
[0089] In some embodiments, the power consumption information may also include the duration of the power consumption behavior and / or the number of times the power consumption behavior occurs. In addition, the present disclosure may also display the duration of the power consumption behavior and / or the number of times the power consumption behavior occurs on the interface of the electronic device to facilitate users to understand the specific circumstances of the power consumption behavior more intuitively and clearly.
[0090] In one example, the power consumption information may include the operating state of the target object, the power consumption behavior, and the duration of the power consumption behavior. In another example, the power consumption information may include the operating state of the target object, the power consumption behavior, and the number of times the power consumption behavior occurs. In another example, the power consumption information may include the operating state of the target object, the power consumption behavior, the duration of the power consumption behavior, and the number of times the power consumption behavior occurs.
[0091] When displaying power consumption information, in one example, the display interface may show that the first application program calls the GPS (Global Positioning System) in the background for 10 minutes. In another example, the display interface may show that the second process continuously calls the central processor of the electronic device in the background for 20 minutes, or that the second application calls the sensor 50 times in the background within one hour.
[0092] The preset time period may be determined according to the running state of the target object. For example, when the target object is an application or process running in the foreground, the preset time period may be a period of time starting from when the application or process is started and ending at the current time. When the target object is an application or process running in the background, the preset time period may be a period of time starting from when the application or process switches from the foreground to the background and ending at the current time. The current time may be the moment when the user views the power consumption information of the target object in the electronic device through the first operation.
[0093] In some embodiments, the interface that displays applications or processes running in the foreground and applications or processes running in the background can be called a power consumption details interface. Displaying the power consumption details interface can facilitate users to manage and view the running status and specific power consumption of applications or processes in both foreground and background running states, and facilitate users to manage applications or processes that generate power consumption according to their own usage.
[0094] In one example, a video application is running in the background and the video application occupies network resources to download videos. Based on the user's first operation, the power consumption details interface will be displayed to the user, and the power consumption details interface will display "the video application occupies network resources to download videos for 10 minutes". If the user wants the video application to download videos, the user can do nothing, and the video application will continue to download videos. However, if the user does not want the video application to download videos, the user can manage the video application, such as closing the video application, so as to avoid the video application occupying network resources and reduce the power resource consumption of the video application.
[0095] In another example, a user is using a shopping app to shop. Based on the user's first operation, the power consumption details interface will be displayed to the user, and the power consumption details interface will display "The shopping app called the microphone for 2 minutes." If the user does not want his or her conversation to be collected and wants to protect his or her privacy, the user can manage the shopping app, such as prohibiting the shopping app from calling the microphone, thereby protecting privacy while reducing power consumption.
[0096] The first operation may be a click operation, a sliding operation, a voice input operation, etc. performed by a user on the display screen of the electronic device, or a gesture operation of the user collected by the electronic device; or a processing operation automatically performed by the electronic device. In one example, the user may open the status bar by a pull-down operation, and a preset control is provided in the status bar. The name of the preset control may be, for example, power consumption information. The first operation may be an operation in which the user clicks the preset control, thereby displaying the power consumption information of the target object in the display of the electronic device. The display mode may be a power consumption details interface, a list interface, a graphical interface, etc.
[0097] In another example, the electronic device can also detect the user's gesture information through a camera and a sensor. When a preset gesture is detected, it means that the user wants to view the power consumption information of the target object, and then display it in an image or text on the display interface of the electronic device, or display it in the form of voice broadcast.
[0098] In another example, when the number of applications or processes running in the foreground and background that consume power in an electronic device reaches a first threshold, the electronic device automatically pops up a power consumption details interface; for another example, when the power consumption per unit time of an application or process in the electronic device reaches a second threshold, a prompt interface may be issued, displaying the power consumption information of the application or process in the prompt interface.
[0099] In step S102, the second operation may be a click operation, a sliding operation, a voice input, a gesture operation, or the like performed by the user. For example, a management control is set corresponding to each power consumption information. When the management control is clicked, it indicates that the user has performed the second operation, and the target object is managed according to the management method corresponding to the management control selected by the user. There are many ways to manage the target object, such as closing an application or process, or prohibiting an application or process from calling hardware resources or network resources. After seeing the power consumption information of the target object, the user can adopt different management methods for different target objects according to their own usage needs. For example, the user can directly close the application and prohibit the application from running; for another example, the user can also permanently prohibit the target object from calling certain hardware resources, etc.
[0100] In an example, the second operation may be to slide an area where a target object is displayed in detail, thereby directly closing the target object corresponding to the area.
[0101] In another example, the management method selection interface may be displayed first through a preset operation, and then a management method may be selected through a second operation acting on the management method selection interface, so as to manage the application or process according to the management method selected by the user.
[0102] The disclosed embodiment provides a power consumption management method, whereby a user can know in detail the reasons for the power consumption behavior of an application or process with abnormal power consumption behavior, and how long the power consumption behavior lasts, so that the user can participate in the power consumption management process according to his / her own usage needs. Since the user is allowed to participate in the power consumption management process, the power consumption management process can be made more humane and personalized, and the application or process that the user wants to keep can be retained, avoiding the occurrence of incorrect management and unmanageable situations, and more reasonably solving the power consumption problem caused by the abuse of resources by the application or process.
[0103] According to an exemplary embodiment, this embodiment provides a power consumption management method. The power consumption management method in this embodiment is a specific definition of step S102 above. Step S102 includes the following steps:
[0104] S1021. Based on the second operation, display a management method for the target object.
[0105] S1022. Manage the target object based on the selected management method.
[0106] In step S1201, the second operation may be a user's voice operation, gesture operation, touch operation or sliding operation, etc. When the user applies the second operation when the power consumption information of the target object is displayed on the electronic device, it indicates that the user wants to manage the target object. Since there are a variety of management methods for the target object, in order to facilitate the user to select the management method according to their own usage needs, the management method will be displayed on the display screen of the electronic device. It can be displayed in the form of a list, in the form of an image, or in the form of voice playback.
[0107] The management method includes at least one of the following methods:
[0108] Prohibit the target object from running in the background;
[0109] Stop the power consumption behavior of the target object that is currently running in the background;
[0110] Permanently prohibit the target object from consuming power while running in the background.
[0111] Among them, prohibiting the target object from running in the background means clearing the target object in the background, that is, closing the target object. For example, a shopping application in an electronic device is running in the background. When the management method of prohibiting the target object from running in the background is selected, the shopping application and related processes running in the background will be closed, and the shopping application will no longer call other hardware resources. At the same time, the shopping application will no longer consume power.
[0112] Among them, stopping the power consumption behavior of the target object currently running in the background means stopping the power consumption behavior of the target object in the background running process this time. For example, the video application calls the microphone in the background running process. When the user wants to better protect his privacy, he can choose to stop the power consumption behavior of the target object currently running in the background. This management method stops the video application from calling the microphone in the background running process. At this time, the video application running in the background cannot use the microphone. It should be noted that this method is only used to close a certain power consumption behavior in the current background application, and will not close the application. The application is still running in the background and can call other hardware resources or network resources except for the resources that are prohibited from calling. At the same time, when the application is restarted again during subsequent use, the resources that were prohibited from calling last time can still be called again, that is, this management method only manages the current usage status of the application and will not affect the subsequent use process.
[0113] Among them, permanently prohibiting the target object from consuming power while running in the background means always prohibiting the target object from consuming power while running in the background. For example, a video application calls the microphone while running in the background. When the user selects the management method of permanently prohibiting the target object from consuming power while running in the background, the video application will be permanently prohibited from using the microphone in the background, that is, the video application cannot use the microphone in the background at any time.
[0114] In addition, it should be noted that, in the specific implementation process of the two management methods of stopping the power-consuming behavior of the target object during its current background operation and permanently prohibiting the power-consuming behavior of the target object during its background operation, the target object can be closed at the same time when the power-consuming behavior of the target object during its background operation is stopped / permanently prohibited. For example, the shopping application can be stopped from calling the global positioning system during its background operation and the shopping application can be closed. Alternatively, the target object can be kept running in the background without being closed. For example, the shopping application can be stopped from calling the global positioning system during its background operation but the shopping application running in the background can be kept running in the background.
[0115] The present disclosure does not limit the specific display form of the management method. In one example, the display form of the management method can be: after the second operation is completed, a pop-up window is displayed on the current display interface, and the pop-up window includes controls corresponding to three methods: prohibiting the target object from running in the background, stopping the power-consuming behavior of the target object currently running in the background, and permanently prohibiting the target object from consuming power during the background operation.
[0116] Since the foreground application is the application currently being used by the user, the user will usually allow the application currently being used to call any hardware resources and network resources, so this embodiment only takes the application and process running in the background as an example for explanation. Of course, it is understandable that when the power consumption information is displayed, the target objects running in the foreground and the target objects running in the background can also be displayed at the same time to provide the user with more choices and management rights. For example, Figure 4 The schematic diagram of power consumption information is shown in FIG. Figure 4 The power consumption information of the first application, the second application, the third application, the first process and the second process during their operation is displayed, as well as the stop controls corresponding to each power consumption information. When the user clicks the stop control corresponding to the power consumption information of the third application, the current display interface of the electronic device displays controls corresponding to three methods, including prohibiting the target object from running in the background, stopping the power consumption behavior of the target object during the current background operation, and permanently prohibiting the target object from consuming power during the background operation. That is, the power consumption information and the list of management methods are displayed in the same interface. After the controls corresponding to the three methods are displayed, the user can select the controls based on their own needs and then manage the third application. For example, the user can click Figure 4 The first control in the management method shown in the figure can be used to prohibit the third application from running in the background and directly close the third application; for another example, the user can use the voice input method to say "prohibit the third application from using data traffic in the background", thereby prohibiting the third application from continuing to use data traffic, thereby achieving the purpose of saving power; for another example, the user can also select "permanently prohibit the third application from using data traffic in the background" through a sliding touch operation, thereby achieving the effect of saving power without having to set it up every time.
[0117] In another example, the display form of the management method can be: after the second operation is completed, a new display interface is entered, and controls corresponding to the three methods of prohibiting the target object from running in the background, stopping the power-consuming behavior of the target object currently running in the background, and permanently prohibiting the target object from consuming power in the background are displayed on the display interface. That is, the display interface of the power consumption information and the display interface of the management method are different display interfaces. When the display interface of the management method appears, the display interface of the power consumption information disappears.
[0118] In addition, it should be noted that the management of the target object based on the second operation proposed in the embodiment of the present disclosure is to manage each target object based on the second operation. That is, the user or the electronic device manages a certain target object separately, not all target objects.
[0119] When the display interface displays the controls corresponding to the management methods for the target object, the user can select at least one control corresponding to the management method to manage the target object. For example, the display interface displays the following: Figure 4 The user can select any one of the three methods, or any two or three of the three controls. Afterwards, in step S1022, the target object will be managed based on the control selected by the user. For example, if the user selects the controls corresponding to the two methods of prohibiting the third application from running in the background and permanently prohibiting the third application from consuming power during the background running, the electronic device will close the third application and permanently prohibit the third application from using data traffic in the background based on the management method selected by the user.
[0120] The following takes the user's participation in power consumption management as an example to specifically explain the interaction process between the user and the electronic device in the above power consumption management method:
[0121] The user performs a first operation, for example, the user clicks a certain control in the display interface of the electronic device;
[0122] When the electronic device receives the signal corresponding to the first operation, in response to the first operation, the electronic device displays the power consumption information of the target object in the electronic device in a preset time period;
[0123] The user views the power consumption information of the target object displayed on the display interface of the electronic device in a preset time period. If the user wants to manage a certain target object, the user performs a second operation, for example, the user slides the power consumption information of a certain target object;
[0124] When the electronic device receives the signal corresponding to the second operation, in response to the second operation, it displays a method for managing the target object, for example, controls corresponding to two methods of prohibiting the target object from running in the background and stopping the power consumption behavior of the target object during the current background running are displayed on the display interface of the electronic device;
[0125] The user selects the control corresponding to the method that prohibits the target object from running in the background;
[0126] The electronic device manages power consumption of the target object according to the management method selected by the user.
[0127] According to an exemplary embodiment, Figure 2 As shown, the power consumption management method in this embodiment includes:
[0128] S201. In response to a third operation, power consumption detection is performed on applications and processes running in the background of the electronic device.
[0129] S202: Determine applications and processes with preset power consumption behaviors as target objects.
[0130] S203: In response to the first operation, display power consumption information of a target object in the electronic device in a preset time period.
[0131] S204: Manage the target object based on the second operation.
[0132] Among them, steps S203 and S204 are the same as steps S101 and S102 in the above embodiment, and are not described again here.
[0133] In some embodiments, after an application or process with a preset power consumption behavior is determined as a target object, the power consumption information of the target object may be displayed in the power consumption details interface.
[0134] In step S201, since the foreground application is usually the application that the user currently wants to use, in order to ensure that the user has a good user experience, the current application and its related processes are allowed to call any resources. Even if there are some power-consuming behaviors, these power-consuming behaviors are usually guaranteed to proceed normally. Therefore, this embodiment only considers background-running applications and processes that have little impact on the user's experience as detection targets, wherein the third operation is used to characterize the switching of an application or process from foreground operation to background operation.
[0135] In one example, the third operation can be a click operation, a sliding operation, a voice input, a gesture operation, etc. performed by the user, for example, the user pulls down the status bar, clicks the power consumption detection control set in the status bar, and starts to detect the power consumption of the application or process running in the background of the electronic device; for another example, the user performs a gesture operation of power consumption detection, and starts to detect the power consumption of the application or process running in the background of the electronic device. The gesture operation of power consumption detection can be set according to the specific situation.
[0136] In another example, the third operation may also be an operation of switching an application or process from foreground operation to background operation, such as clicking a return to desktop button, sliding a desktop navigation key, etc. For example, the display interface of the current electronic device is an application interface. When the return to desktop button of the electronic device is clicked, it indicates that the user has performed the third operation, the display interface is switched from the application interface to the desktop, and the application is switched from foreground operation to background operation; for another example, the display interface of the current electronic device is a first application interface, and the user voice records opening a second application, indicating that the user has performed the third operation, the display interface is switched from the first application interface to the second application interface, and the first application is switched from foreground operation to background operation; for another example, the user slides the desktop navigation key to switch the display interface from the first application interface to the second application interface, and the first application is switched from foreground operation to background operation. This example is an automatic power consumption detection after the user switches the application or process from foreground operation to background operation, that is, real-time detection.
[0137] In one example, the power consumption detection may be a single detection of an application or process running in the background of the electronic device after the user performs a third operation. For example, ten minutes after the first application enters the background, the user clicks on the power consumption detection control set in the status bar to start the power consumption detection of the application or process running in the background of the electronic device.
[0138] In another example, the power consumption detection can also be a multiple detection of the application or process running in the background of the electronic device automatically performed by the electronic device in a preset time period, for example, after the first application is switched to the background, the power consumption behavior of the first application is continuously detected. In order to make the detection result more accurate, the detection frequency can be set, and the application or process running in the background of the electronic device is detected according to the detection frequency, wherein the detection frequency can be set according to the actual application or process running in the background of the electronic device, for example, when the number of applications or processes running in the background of the electronic device is relatively small, a slower detection frequency can be set, such as once every five minutes; for another example, when the number of applications or processes running in the background of the electronic device is relatively large, a faster detection frequency can be set, such as once every minute. In the present disclosure, the electronic device is used to automatically detect the power consumption of the application or process running in the background of the electronic device, so that the background operation of the electronic device can be monitored in real time, and the application or process with preset power consumption behavior, i.e. abnormal power consumption, is added to the power consumption details interface in a timely manner, so that the user or the electronic device can manage the power consumption of the application or process in real time and reduce unnecessary power consumption behavior.
[0139] In step S202, the preset power consumption behavior includes a first behavior of occupying the hardware resources of the electronic device, the preset power consumption behavior includes a second behavior of occupying the network resources of the electronic device, and the preset power consumption behavior can also include the first behavior of occupying the hardware resources of the electronic device and the second behavior of occupying the network resources of the electronic device at the same time. Among them, the first behavior includes at least one of the following behaviors: calling the sensor of the electronic device, for example, the sports application calls the sensor to obtain the number of steps, heart rate, blood oxygen, etc.; calling the global positioning system, for example, the takeaway software calls the global positioning system to obtain the user's address; calling the audio device, wherein the audio device refers to the hardware system that inputs, processes, stores and outputs the sound, for example, the recorder calls the microphone to obtain the sound of the user and the user's environment; calling the central processor of the electronic device, for example, the application or process directly calls the central processor, the application or process frequently wakes up the system, and the application or process is locked for a long time after the electronic device turns off the screen, wherein the application or process frequently wakes up the system means that after the system enters the dormant state, the application or process wakes up the system from the dormant state to the non-dormant state. The dormant state here means that the application or process no longer uses the central processor. In this process, the electronic device does not necessarily have a bright screen. Calling the central processor of the electronic device may also include that the application or process remains locked for a long time after the screen of the electronic device is turned off, which means that the user has stopped using the electronic device, but the application or process has locked the central processor for a long time, causing the central processor to continue to work without the user's perception, resulting in a large amount of power consumption. The second behavior includes at least one of the following behaviors: using the data traffic of the electronic device, such as video applications using the data traffic of the electronic device; using the mobile hotspot of the electronic device, such as video applications continuously using WIFI to upload or download video resources without the user's perception.
[0140] In one example, when an application or process running in the background of an electronic device has at least one power consumption behavior among preset power consumption behaviors, the application or process can be determined as a target object.
[0141] In another example, in order to avoid adding the power consumption information of background applications or processes with short-term preset power consumption behaviors to the power consumption details interface, thereby increasing the operating burden of the electronic device, the present disclosure can also record the duration of the power consumption behavior of the application or process with the preset power consumption behavior, that is, the duration of the preset power consumption behavior, and can also record the amount of network resource traffic used by the application or process, as well as the number of calls to hardware resources or traffic resources, and when at least one of the duration of the preset power consumption behavior is greater than the preset duration, the total network resource traffic used is greater than the preset traffic, and the number of calls to hardware resources or traffic resources is greater than the preset number, the application or process is taken as the target object. Among them, the size of the preset threshold can be set according to the type of application or process. For example, if it is detected that a sports application running in the background is calling a sensor, the number of times the sports application calls the sensor is recorded. When the number of times it calls the sensor is greater than 100 times, the sports application is determined as a target object. For another example, if it is detected that a food delivery application running in the background is calling a global positioning system, the duration of its call to the global positioning system is recorded. When the duration of its call to the global positioning system is greater than 10 minutes, the food delivery application is determined as a target object. For another example, if it is detected that a news application running in the background is using data traffic, the amount of data traffic used is recorded. When the amount of data traffic used is greater than 500 megabytes, the news application is determined as a target object.
[0142] Of course, it is understandable that when the electronic device is detecting applications and processes running in the background, if some applications and processes are running in the background but these applications and processes do not consume power during operation, for example, these applications and processes do not call hardware resources such as sensors, GPS, microphones, etc., nor do they obviously occupy the computing resources of the central processing unit, nor do they occupy a large amount of network resources, then it can be considered that these applications are not target objects that need to be optimized. Therefore, these applications and processes do not need to display the running status and power consumption information of these applications and processes in the power consumption details interface.
[0143] By adopting the method in this embodiment, various applications and processes running in the background that meet the preset behaviors can be accurately identified as target objects, and the running status and specific power consumption information of the target objects can be displayed to the user, so that the user can manage the applications running in the background that do not have much impact on the user perception but call a large amount of resources and consume power, thereby reducing unnecessary consumption of power, extending the standby time of electronic devices, improving human-computer interaction performance, and improving the user experience.
[0144] According to an exemplary embodiment, Figure 3 As shown, the power consumption management method in this embodiment includes:
[0145] S301. In response to a third operation, display a first control.
[0146] S302: In response to a first operation on a first control, display power consumption information of each target object in a preset time period in a list format.
[0147] S303: Manage the target object based on the second operation.
[0148] Among them, step S303 is the same as step S102 in the above embodiment and will not be described again.
[0149] In step S301, the present disclosure does not limit the specific type of the first control. For example, the first control may be a preset control in the status bar, a preset control in the shortcut box, etc.
[0150] Among them, the third operation can be a user's voice operation, gesture operation, touch operation or sliding operation, etc. For example, a first control is set in the status bar, and when the user pulls down the status bar, it means that the user has performed the third operation, and the first control in the status bar is displayed in the display interface of the electronic device; for another example, a first control is set in the shortcut box, and when the user slides the shortcut bar in the display interface, it means that the user has performed the third operation, and the first control is displayed in the display interface.
[0151] In addition to the implementation methods in the above embodiments, in step S302, the first operation can also be a click operation, a sliding operation, a voice input operation, etc. performed by the user on the first control. In one example, the user clicks on the first control located in the status bar, and the power consumption information of each target object in the preset time period is displayed in a list format on the display interface of the electronic device.
[0152] In one example, if Figure 4 The schematic diagram of power consumption information shown can display the power consumption information of the target object in a list format. Displaying the power consumption information of the target object in a list format can clearly display the power consumption information, making it convenient for users to check the power consumption information of the target object and then manage the target object.
[0153] According to an exemplary embodiment, the power consumption management method in this embodiment includes:
[0154] In response to the fourth operation, the target objects are sorted in descending order of power consumption according to the power consumption of the power consumption behaviors of the target objects.
[0155] In this step, in one example, the fourth operation may be a click operation, gesture operation, touch operation or sliding operation of the display interface by the user. For example, the user double-clicks the display interface, and the electronic device responds to the double-click operation by arranging the target objects in the power consumption details interface in order of power consumption from large to small.
[0156] In another example, a second control may be preset on the display interface, and the second control is used to arrange the target objects in order of power consumption from large to small. The fourth operation may also be a click operation, a touch operation, or a sliding operation of the user on the second control in the display interface. For example, the user clicks on the second control, and the electronic device responds to the click operation to arrange the target objects in the power consumption details interface in order of power consumption from large to small. Of course, it is understandable that the first operation and the fourth operation may be the same operation, that is, when the power consumption information of the target object in a preset time period is displayed on the display screen of the electronic device, the target objects are directly displayed in the order of power consumption from large to small, so that the user can quickly know that the target objects in front are applications or processes with large power consumption, so that the user can quickly process these target objects with large power consumption first, reduce unnecessary power loss, save the user's self-search process, and improve the user's experience.
[0157] In addition, in order to sort the target objects according to the amount of power consumption of their power consumption behaviors, it is also necessary to first obtain the amount of power consumption of the power consumption behaviors of the target objects. In one example, the power consumption of the power consumption behaviors of the target objects can be calculated by the duration of the power consumption behaviors and / or the number of times the power consumption behaviors occur, as well as the unit power consumption of each power consumption behavior. For example, if an application consumes m mAh of power when calling a sensor once, then when the application calls the sensor 50 times, the power consumption of the application calling the sensor is 50m mAh; for another example, if an application uses GPS for one minute, it consumes n mAh of power. When the application uses GPS for ten minutes, the power consumption of the application using GPS for ten minutes is 10n mAh.
[0158] Among them, the unit power consumption can be obtained in the following ways: for example, the unit power consumption of the power consumption behavior can be calculated based on the power consumption of the power consumption behavior detected by the built-in chip or built-in software of the electronic device, the duration of the power consumption behavior and / or the number of times the power consumption behavior occurs. For example, the built-in software of the electronic device detects that an application uses GPS in the background for 20 minutes, consuming a total of A mAh during the process. The unit power consumption of the power consumption behavior of using GPS in the background can be calculated to be a mAh per minute; for another example, the unit power consumption of the power consumption behavior can also be obtained based on the unit power consumption defined in the system parameters or the unit power consumption defined in the software parameters. For example, the system parameters define that it takes b mAh to call a sensor once; for another example, the software parameters define that it takes c mAh to use 1 megabyte of data traffic.
[0159] In another example, a power statistics chip can be set in the electronic device to calculate the power consumption of the target object's power consumption behavior. For example, the power statistics chip records the power consumption behavior of the application program, which consumes a total of M mAh, and stores the calculated power consumption in a memory. When needed, the power consumption data in the memory can be directly called.
[0160] The exemplary embodiment of the present disclosure provides a power consumption management device, which is applied to electronic devices, such as Figure 5 As shown, this disclosure shows a block diagram of a power consumption management device.
[0161] The block diagram includes a first processing module 51 and a second processing module 52. The first processing module 51 is used to display the power consumption information of the target object in the electronic device in a preset time period in response to a first operation, wherein the power consumption information includes the operating state and power consumption behavior of the target object; the second processing module 52 is used to manage the target object based on the second operation.
[0162] In an exemplary embodiment of the present disclosure, the power consumption management device further includes:
[0163] The third processing module is used for:
[0164] In response to a third operation, power consumption detection is performed on the application and process running in the background of the electronic device, wherein the third operation is used to indicate that the application and process are switched from foreground operation to background operation;
[0165] Applications and processes that have preset power consumption behaviors are identified as target objects.
[0166] In an exemplary embodiment of the present disclosure, the preset power consumption behavior includes a first behavior of occupying hardware resources of the electronic device and / or a second behavior of occupying network resources of the electronic device.
[0167] In an exemplary embodiment of the present disclosure, the first behavior includes at least one of the following behaviors:
[0168] Invoke sensors of electronic devices;
[0169] Calling the GPS;
[0170] Call the audio device;
[0171] Call the central processing unit of the electronic device.
[0172] In an exemplary embodiment of the present disclosure, the second behavior includes at least one of the following behaviors:
[0173] Use of data traffic from electronic devices;
[0174] Use a mobile hotspot from an electronic device.
[0175] In the exemplary embodiment of the present disclosure, the second processing module 52 is specifically used for:
[0176] Based on the second operation, displaying a management method for the target object;
[0177] Manage the target object based on the selected management method.
[0178] In an exemplary embodiment of the present disclosure, the management method includes at least one of the following methods:
[0179] Prohibit the target object from running in the background;
[0180] Stop the power consumption behavior of the target object that is currently running in the background;
[0181] Permanently prohibit the target object from consuming power while running in the background.
[0182] In an exemplary embodiment of the present disclosure, the power consumption management device further includes:
[0183] The fourth processing module is used for:
[0184] In response to the third operation, displaying the first control;
[0185] In response to the first operation, displaying power consumption information of a target object in the electronic device in a preset time period includes:
[0186] In response to a first operation on the first control, power consumption information of each target object in a preset time period is displayed in a list format.
[0187] In an exemplary embodiment of the present disclosure, the power consumption management device further includes:
[0188] The sorting module is used to sort the target objects in descending order of power consumption according to the power consumption of the power consumption behavior of the target objects in response to the fourth operation.
[0189] In an exemplary embodiment of the present disclosure, the power consumption information further includes the duration of the power consumption behavior and / or the number of times the power consumption behavior occurs.
[0190] Regarding the power consumption management device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.
[0191] Figure 6 is a block diagram of an electronic device 600 according to an exemplary embodiment. For example, the electronic device 600 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.
[0192] Reference Figure 6 , the electronic device 600 may include one or more of the following components: a processing component 602 , a memory 604 , a power component 606 , a multimedia component 608 , an audio component 610 , an input / output (I / O) interface 612 , a sensor component 614 , and a communication component 616 .
[0193] The processing component 602 generally controls the overall operation of the electronic device 600, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 602 may include one or more processors 620 to execute instructions to complete all or part of the steps of the above-mentioned method. In addition, the processing component 602 may include one or more modules to facilitate the interaction between the processing component 602 and other components. For example, the processing component 602 may include a multimedia module to facilitate the interaction between the multimedia component 608 and the processing component 602.
[0194] The memory 604 is configured to store various types of data to support operations on the electronic device 600. Examples of such data include instructions for any application or method operating on the electronic device 600, contact data, phone book data, messages, pictures, videos, etc. The memory 604 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.
[0195] The power supply component 606 provides power to the various components of the electronic device 600. The power supply component 606 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to the electronic device 600.
[0196] The multimedia component 608 includes a screen that provides an output interface between the electronic device 600 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 608 includes a front camera and / or a rear camera. When the electronic device 600 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera may receive external multimedia data. Each front camera and the rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
[0197] The audio component 610 is configured to output and / or input audio signals. For example, the audio component 610 includes a microphone (MIC), and when the electronic device 600 is in an operating mode, such as a call mode, a recording mode, and a voice recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 604 or sent via the communication component 616. In some embodiments, the audio component 610 also includes a speaker for outputting audio signals.
[0198] I / O interface 612 provides an interface between processing component 602 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: a home button, a volume button, a start button, and a lock button.
[0199] The sensor assembly 614 includes one or more sensors for providing various aspects of status assessment for the electronic device 600. For example, the sensor assembly 614 can detect the open / closed state of the electronic device 600, the relative positioning of the components, such as the display and keypad of the electronic device 600, and the sensor assembly 614 can also detect the position change of the electronic device 600 or a component of the electronic device 600, the presence or absence of contact between the user and the electronic device 600, the orientation or acceleration / deceleration of the electronic device 600, and the temperature change of the electronic device 600. The sensor assembly 614 may include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 614 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 614 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
[0200] The communication component 616 is configured to facilitate wired or wireless communication between the electronic device 600 and other devices. The electronic device 600 can access a wireless network based on a communication standard, such as WiFi, 2G or 3G, or a combination thereof. In an exemplary embodiment, the communication component 616 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 616 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.
[0201] In an exemplary embodiment, the electronic device 600 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the above methods.
[0202] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory 604 including instructions, and the instructions can be executed by a processor 620 of an electronic device 600 to perform the above method. For example, the non-transitory computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.
[0203] A non-transitory computer-readable storage medium, when instructions in the storage medium are executed by a processor of an electronic device, enables the electronic device to execute the power consumption management method provided by an exemplary embodiment of the present disclosure.
[0204] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of the present disclosure that follow the general principles of the present disclosure and include common knowledge or customary techniques in the art that are not disclosed in the present disclosure. The specification and examples are intended to be exemplary only, and the true scope and spirit of the present disclosure are indicated by the following claims.
[0205] It should be understood that the present disclosure is not limited to the exact structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.
Claims
1. A power consumption management method, characterized in that: Applied to electronic equipment, the power consumption management method includes: In response to the first operation, displaying power consumption information of a target object in the electronic device in a preset time period, wherein the power consumption information includes an operating state and power consumption behavior of the target object; Based on the second operation, the target object is managed.
2. The power consumption management method according to claim 1, characterized in that: The power consumption management method further includes: In response to a third operation, power consumption detection is performed on the application and process running in the background of the electronic device, wherein the third operation is used to indicate that the application and the process are switched from foreground operation to background operation; The application program and the process having a preset power consumption behavior are determined as the target objects.
3. The power consumption management method according to claim 2, characterized in that: The preset power consumption behavior includes a first behavior of occupying hardware resources of the electronic device and / or a second behavior of occupying network resources of the electronic device.
4. The power consumption management method according to claim 3, characterized in that: The first behavior includes at least one of the following behaviors: Invoking a sensor of the electronic device; Calling the GPS; Call the audio device; The central processing unit of the electronic device is called.
5. The power consumption management method according to claim 3, characterized in that: The second behavior includes at least one of the following behaviors: Use of data traffic of the electronic device; Using a mobile hotspot of the electronic device.
6. The power consumption management method according to claim 1, characterized in that: The managing the target object based on the second operation includes: Based on the second operation, displaying a management method for the target object; The target object is managed based on the selected management method.
7. The power consumption management method according to claim 6, characterized in that: The management method includes at least one of the following methods: prohibiting the target object from running in the background; Stopping the power consumption behavior of the target object that is currently running in the background; The target object is permanently prohibited from performing the power-consuming behavior while running in the background.
8. The power consumption management method according to claim 1, characterized in that: The power consumption management method further includes: In response to the third operation, displaying the first control; The step of displaying the power consumption information of the target object in the electronic device in a preset time period in response to the first operation includes: In response to the first operation acting on the first control, the power consumption information of each of the target objects in the preset time period is displayed in a list.
9. The power consumption management method according to claim 1, characterized in that: The power consumption management method further includes: In response to the fourth operation, the target objects are sorted in descending order of power consumption according to the power consumption of the power consumption behavior of the target objects.
10. The power consumption management method according to any one of claims 1 to 9, characterized in that: The power consumption information also includes the duration of the power consumption behavior and / or the number of times the power consumption behavior occurs.
11. A power consumption management device, characterized in that: Applied to electronic equipment, the power consumption management device comprises: A first processing module, configured to display power consumption information of a target object in the electronic device in a preset time period in response to a first operation, wherein the power consumption information includes an operating state and power consumption behavior of the target object; The second processing module is used to manage the target object based on the second operation.
12. An electronic device, characterized in that: Includes: processor; a memory for storing processor-executable instructions; The processor is configured to execute the power consumption management method as described in any one of claims 1-10.
13. A non-transitory computer-readable storage medium, characterized in that: When the instructions in the storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the power consumption management method as described in any one of claims 1 to 10.