CN109710051B - Processing method and electronic equipment - Google Patents

Processing method and electronic equipment Download PDF

Info

Publication number
CN109710051B
CN109710051B CN201811609000.6A CN201811609000A CN109710051B CN 109710051 B CN109710051 B CN 109710051B CN 201811609000 A CN201811609000 A CN 201811609000A CN 109710051 B CN109710051 B CN 109710051B
Authority
CN
China
Prior art keywords
mode
power consumption
module
electric energy
threshold
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201811609000.6A
Other languages
Chinese (zh)
Other versions
CN109710051A (en
Inventor
戚宇
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Lenovo Beijing Ltd
Original Assignee
Lenovo Beijing Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Lenovo Beijing Ltd filed Critical Lenovo Beijing Ltd
Priority to CN201811609000.6A priority Critical patent/CN109710051B/en
Publication of CN109710051A publication Critical patent/CN109710051A/en
Application granted granted Critical
Publication of CN109710051B publication Critical patent/CN109710051B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The application provides a processing method and electronic equipment, wherein the method comprises the following steps: monitoring whether a second mode is adopted to supply electric energy to the outside or not in the process of acquiring the electric energy through the first mode; determining that electric energy is provided externally by adopting the second mode, and acquiring power consumption parameters in the first mode; if the power consumption parameter is larger than a first threshold value, switching a first mode in which the second mode works currently into a second mode, wherein the highest allowed power consumption in the second mode is smaller than the highest allowed power consumption in the first mode; in the application, in the process that the electronic equipment acquires electric energy through the first mode and provides the electric energy to the outside through the second mode, if the power consumption parameter under the first mode is determined to be larger than the first threshold value, the highest allowable power consumption of the current work of the second mode is directly reduced, so that the power consumption requirement under the first mode can be met, the power consumption is not required to be increased through replacing a module carried by the first mode for the electronic equipment, and the control flexibility is improved.

Description

Processing method and electronic equipment
Technical Field
The present invention relates to the field of information processing technologies, and in particular, to a processing method and an electronic device.
Background
At present, electronic devices can provide power for themselves in a specific manner, such as by charging an adapter. The maximum power consumption allowed by different electronic devices in a specific mode is different, and correspondingly, the mounted modules are different.
Some electronic devices can provide power for themselves in a specific manner, and can also provide power for other electronic devices, for example, a notebook computer can provide power for a mobile phone. If these two situations occur simultaneously, it is necessary to increase the power consumption of the module mounted in a specific manner.
In the prior art, the power consumption of the module needs to be increased by replacing the module, so that the cost is obviously increased, and the flexible control is not convenient.
Disclosure of Invention
In view of the above, the present invention provides a processing method and an electronic device to solve the above technical problems.
In order to achieve the purpose, the invention provides the following technical scheme:
a method of processing, comprising:
monitoring whether a second mode is adopted to supply electric energy to the outside or not in the process of acquiring the electric energy through the first mode;
determining that electric energy is provided externally by adopting the second mode, and acquiring power consumption parameters in the first mode;
and if the power consumption parameter is larger than a first threshold value, switching a first mode in which the second mode is currently operated into a second mode, wherein the highest allowed power consumption in the second mode is smaller than the highest allowed power consumption in the first mode.
Preferably, the method further comprises the following steps:
monitoring whether the power consumption parameter falls below a second threshold while the second mode is operating in the second mode; the second threshold is less than the first threshold;
determining that the power consumption parameter falls below the second threshold, switching the second mode in which the second mode is currently operating to the first mode.
Preferably, the method further comprises the following steps:
monitoring whether the power consumption parameter is always below the second threshold value in a first time, and if so, triggering the second mode of the second mode to be switched to the first mode.
Preferably, the acquiring the power consumption parameter in the first mode includes:
and acquiring the power consumption parameters in the first mode through a sensor which is arranged in series between the first module corresponding to the first mode and the charging interface.
Preferably, the method further comprises the following steps:
determining a difference between a highest allowed power consumption in the first mode and a highest allowed power consumption in the second mode;
subtracting the difference value on the basis of the first threshold value to obtain the second threshold value.
An electronic device, comprising:
the first module is used for acquiring electric energy in a first mode;
the second module is used for providing electric energy to the outside in a second mode;
the processor is used for monitoring whether the second module provides electric energy to the outside in the process of obtaining the electric energy through the first module, determining that the second module provides the electric energy to the outside, obtaining a power consumption parameter under the first module, and switching a first mode of the current work of the second module into a second mode if the power consumption parameter is larger than a first threshold value, wherein the highest allowable power consumption under the second mode is smaller than the highest allowable power consumption under the first mode.
Preferably, the processor is further configured to monitor whether the power consumption parameter falls below a second threshold when the second module operates in the second mode; and when the second threshold is smaller than the first threshold, determining that the power consumption parameter is reduced below the second threshold, and switching the second mode in which the second module is currently working to the first mode.
Preferably, the processor is further configured to monitor whether the power consumption parameter is always below the second threshold value within a first time, and if so, execute switching the second mode in which the second module is currently operating to the first mode.
Preferably, the method further comprises the following steps:
the sensor is arranged between the first module and the charging interface;
the processor is specifically used for acquiring power consumption parameters under the first module through a sensor which is arranged between the first module and the charging interface in series.
An electronic device, comprising:
the first monitoring unit is used for monitoring whether a second mode is adopted to supply electric energy to the outside in the process of acquiring the electric energy through the first mode;
the first obtaining unit is used for determining that electric energy is supplied to the outside in the second mode and obtaining the power consumption parameter in the first mode;
and the first switching unit is used for switching the first mode of the current work of the second mode into a second mode if the power consumption parameter is larger than a first threshold, wherein the highest allowed power consumption in the second mode is smaller than the highest allowed power consumption in the first mode.
As can be seen from the foregoing technical solutions, compared with the prior art, in the process of obtaining electric energy through a first manner, an embodiment of the present application provides a processing method, which includes monitoring whether to externally provide electric energy through a second manner, determining to externally provide electric energy through the second manner, obtaining a power consumption parameter in the first manner, and if the power consumption parameter is greater than a first threshold, switching a first mode in which the second manner currently operates to a second mode, where a highest allowed power consumption in the second mode is less than a highest allowed power consumption in the first mode; therefore, in the process that the electronic equipment acquires the electric energy through the first mode and provides the electric energy to the outside through the second mode, if the power consumption parameter under the first mode is determined to be larger than the first threshold value, the highest allowable power consumption of the current work of the second mode is directly reduced, the power consumption requirement under the first mode can be met, the power consumption is not required to be increased through replacing a module carried by the first mode for the electronic equipment, and the control flexibility is improved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
FIG. 1 is a schematic flow chart of a processing method according to an embodiment of the present invention;
FIG. 2 is a schematic flow chart of a processing method according to a second embodiment of the present disclosure;
fig. 3 is a schematic flow chart of a processing method according to a third embodiment of the present invention;
FIG. 4 is a schematic diagram of a sensor arrangement according to a fourth embodiment of the present disclosure;
fig. 5 is a schematic flow chart of a processing method according to a fifth embodiment of the present invention;
fig. 6 is a schematic structural diagram of an electronic device according to an embodiment of the present application;
fig. 7 is a schematic structural diagram of an electronic device according to a fourth embodiment of the present disclosure;
fig. 8 is a schematic structural diagram of an electronic device according to a fifth embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The embodiment of the method of the present application provides a processing method, and the method may be applied to electronic devices, such as various terminal devices, e.g., a mobile phone, a tablet computer, and a notebook computer. As shown in fig. 1, the method comprises the steps of:
step 101: in the process of obtaining the electric energy through the first mode, whether a second mode is adopted to supply the electric energy to the outside is detected;
the first mode and the second mode represent different charge and discharge modes. Specifically, the first mode is a wired mode and the second mode is a wireless mode, or the first mode is a wireless mode and the second mode is a wired mode, or the first mode is a first wired mode and the second mode is a second wired mode, and the first wired mode is different from the second wired mode. The first mode and the second mode are different, so that the first mode and the second mode correspond to different modules.
For example, the first mode includes, but is not limited to, a mode of obtaining electric energy through the adapter, and the second mode includes, but is not limited to, a mode of externally providing electric energy through the wireless charging module.
Step 102: determining that electric energy is supplied to the outside in a second mode, and acquiring power consumption parameters in the first mode;
when it is determined that the electronic equipment is providing electric energy in the first mode and the second mode, the power consumption parameter in the first mode is obtained.
The power consumption parameter is used for representing the electric energy power consumption in the first mode, and specifically may be a power parameter, a current parameter, and the like. For example, the power consumption parameter may be a current power consumption parameter of the first module corresponding to the first mode, and if the first module is an adapter, the power consumption parameter may be a current power consumption parameter of the adapter.
It should be noted that, the operating loads of the electronic devices are different, the power consumption parameters in the first mode are different, and the larger the operating load is, the larger the power consumption parameter in the first mode is, the smaller the operating load is, and the smaller the power consumption parameter in the first mode is.
Step 103: and if the power consumption parameter is larger than a first threshold value, switching the first mode of the current work of the second mode into a second mode.
The first threshold is preset, and the set value may be determined based on a maximum power consumption of the first module corresponding to the first mode. For example, if the maximum power consumption of the first module is 120w, the first threshold may be set to 119w, and when the power consumption parameter exceeds 119w, the first mode in which the second mode is currently operated is switched to the second mode.
The second mode may correspond to a second module, and switching the first mode in which the second mode is currently operated to the second mode may include: and switching the second module from the first mode of current work to the second mode.
Wherein the highest allowed power consumption in the second mode is less than the highest allowed power consumption in the first mode. For example, the maximum allowed power consumption of the first mode is 20w, and the maximum allowed power consumption of the second mode is 8w, then after the first mode in which the second mode is currently operating is switched to the second mode, the power consumption parameter can be reduced by at least 10 w. If the second mode is wireless, the first mode may be epp (extended Power profile) mode, and the second mode may be bpp (baseline Power profile) mode. Wherein, the maximum allowable power consumption of the EPP mode is 15w, and the maximum allowable power consumption of the BPP mode is 5 w.
Therefore, in the first embodiment of the method of the application, in the process of acquiring the electric energy through the first mode, whether the electric energy is externally provided through the second mode is monitored, the electric energy externally provided through the second mode is determined, the power consumption parameter in the first mode is acquired, and if the power consumption parameter is greater than a first threshold value, the first mode of the current work of the second mode is switched to the second mode, wherein the highest allowable power consumption in the second mode is less than the highest allowable power consumption in the first mode; therefore, in the process that the electronic equipment acquires the electric energy through the first mode and provides the electric energy to the outside through the second mode, if the power consumption parameter under the first mode is determined to be larger than the first threshold value, the highest allowable power consumption of the current work of the second mode is directly reduced, the power consumption requirement under the first mode can be met, the power consumption is not required to be increased through replacing a module carried by the first mode for the electronic equipment, and the control flexibility is improved.
An embodiment of the method of the present application provides a processing method, as shown in fig. 2, including the following steps:
step 201: monitoring whether a second mode is adopted to supply electric energy to the outside or not in the process of acquiring the electric energy through the first mode;
step 202: determining that electric energy is provided externally by adopting the second mode, and acquiring power consumption parameters in the first mode;
step 203: if the power consumption parameter is larger than a first threshold value, switching a first mode of the second mode in current work into a second mode;
wherein the highest allowed power consumption in the second mode is less than the highest allowed power consumption in the first mode.
Step 204: monitoring whether the power consumption parameter falls below a second threshold while the second mode is operating in the second mode;
wherein the second threshold is less than the first threshold.
Since the maximum allowable power consumption of the second mode is lower than that of the first mode, the charging efficiency of the second mode in the second mode is lower than that in the first mode. Therefore, when the power consumption parameter is lower than the second threshold value, the second mode can be switched to the first mode from the second mode. The specific parameter value of the second threshold may be a fixed value preset by the system, or may be calculated by the system, and a specific calculation method will be described later.
Step 205: determining that the power consumption parameter falls below the second threshold, switching the second mode in which the second mode is currently operating to the first mode.
In the second embodiment of the method, in the process that the electronic device obtains the electric energy through the first mode and simultaneously provides the electric energy through the second mode, if the power consumption parameter in the first mode is determined to be larger than the first threshold, the highest allowable power consumption of the current work of the second mode is directly reduced, so that the power consumption requirement of the first mode can be ensured, the power consumption is not required to be increased by replacing a module carried in the first mode for the electronic device, and the control flexibility is improved; and when the second mode works in the second mode, if the power consumption parameter is determined to be reduced below the second threshold, the second mode in which the second mode works currently can be switched back to the first mode, so that the efficiency of the second mode for improving electric energy externally is improved on the basis of not influencing the power consumption requirement of the first mode.
An embodiment of the method of the present application provides a processing method, as shown in fig. 3, the method includes the following steps:
step 301: monitoring whether a second mode is adopted to supply electric energy to the outside or not in the process of acquiring the electric energy through the first mode;
step 302: determining that electric energy is provided externally by adopting the second mode, and acquiring power consumption parameters in the first mode;
step 303: if the power consumption parameter is larger than a first threshold value, switching a first mode of the second mode in current work into a second mode;
wherein the highest allowed power consumption in the second mode is less than the highest allowed power consumption in the first mode.
Step 304: monitoring whether the power consumption parameter falls below a second threshold while the second mode is operating in the second mode;
wherein the second threshold is less than the first threshold.
Step 305: determining that the power consumption parameter is reduced below the second threshold, monitoring whether the power consumption parameter is always below the second threshold in a first time, and if so, entering step 306; if not, the second mode of the current work of the second mode is kept.
Since the maximum allowable power consumption of the second mode is lower than that of the first mode, the charging efficiency of the second mode in the second mode is lower than that in the first mode. Therefore, when the power consumption parameter meets the condition, the second mode can be switched from the second mode to the first mode. If the mode is switched only by depending on the fact that the power consumption parameter is lower than the second threshold value, the current working state of the system is unstable, and the power consumption parameter in the first mode is increased and decreased suddenly, so that timing can be started when the power consumption parameter is decreased to be lower than the second threshold value, whether the power consumption parameter is always lower than the second threshold value within the first time or not is monitored, and if the power consumption parameter is lower than the second threshold value, the second mode of the second mode which works currently can be switched back to the first mode.
Step 306: and switching the second mode of the current work of the second mode to the first mode.
In the third embodiment of the method, in the process that the electronic equipment acquires the electric energy in the first mode and simultaneously provides the electric energy in the second mode, if the power consumption parameter in the first mode is determined to be larger than the first threshold, the highest allowable power consumption of the second mode in the current work is directly reduced, so that the power consumption requirement of the first mode can be ensured, the power consumption is not required to be increased by replacing a module carried in the first mode for the electronic equipment, and the control flexibility is improved; and when the second mode works in the second mode, if the power consumption parameter is determined to be reduced below the second threshold, the power consumption parameter is monitored to be always below the second threshold in the first time, and the second mode of the current work of the second mode can be switched back to the first mode, so that the efficiency of the second mode for externally improving the electric energy is improved on the basis of stable system working state.
In a fourth embodiment of the method of the present application, acquiring the power consumption parameter in the first manner includes:
and acquiring the power consumption parameters in the first mode through a sensor which is arranged in series between the first module corresponding to the first mode and the charging interface.
The sensor may include, but is not limited to, a current sensor.
For convenience of understanding, a specific application example is described, a first mode is a mode in which the adapter obtains electric energy, and a second mode is a mode in which the wireless charging module obtains electric energy, as shown in fig. 4, a current sensor may be connected in series between the 19V terminal and a charging interface (not shown in the figure), and a first threshold value is set, when a current parameter reaches the first threshold value, an alert signal is triggered to notify the processor EC, and the EC controls the wireless charging module corresponding to the second mode to switch from the first mode to the second mode.
In the fifth embodiment of the method of the present application, as shown in fig. 5, the method includes the following steps:
step 501: monitoring whether a second mode is adopted to supply electric energy to the outside or not in the process of acquiring the electric energy through the first mode;
step 502: determining that electric energy is provided externally by adopting the second mode, and acquiring power consumption parameters in the first mode;
step 503: if the power consumption parameter is larger than a first threshold value, switching a first mode of the second mode in current work into a second mode;
step 504: determining a difference between a highest allowed power consumption in the first mode and a highest allowed power consumption in the second mode;
step 505: subtracting the difference value on the basis of the first threshold value to obtain a second threshold value;
since the maximum allowable power consumption of the second mode is lower than that of the first mode, the charging efficiency of the second mode in the second mode is lower than that in the first mode. The second mode may therefore be switched from the second mode to the first mode when the power consumption parameter is below the second threshold.
Specifically, a difference between the maximum allowable power consumption in the first mode and the maximum allowable power consumption in the second mode may be determined, and then the difference may be subtracted from the first threshold to obtain a second threshold.
For example, the maximum allowed power consumption in the first mode is 15w, the maximum allowed power consumption in the second mode is 5w, and the first threshold is 119w, so that the difference between the maximum allowed power consumption in the first mode and the maximum allowed power consumption in the second mode is 10w, and the difference is subtracted from the first threshold to obtain the second threshold 109 w.
Step 506: monitoring whether the power consumption parameter falls below a second threshold while the second mode is operating in the second mode;
step 507: determining that the power consumption parameter falls below the second threshold, switching the second mode in which the second mode is currently operating to the first mode.
In another embodiment of the present application, it may also be monitored whether the power consumption parameter is always below the second threshold when the power consumption parameter is below the second threshold, and if so, the second mode in which the second mode is currently operating is switched to the first mode.
In the fifth embodiment of the method, in the process that the electronic device obtains the electric energy through the first mode and simultaneously provides the electric energy through the second mode, if the power consumption parameter in the first mode is determined to be larger than the first threshold, the highest allowable power consumption of the current work of the second mode is directly reduced, so that the power consumption requirement of the first mode can be ensured, the power consumption does not need to be increased by replacing a module carried in the first mode for the electronic device, and the control flexibility is improved; and when the second mode works in the second mode, the system can calculate the second threshold value, so that the second mode of the current work of the second mode is switched back to the first mode after the power consumption parameter is determined to be reduced below the second threshold value, and the efficiency of the second mode for externally improving the electric energy is improved on the basis of not influencing the power consumption requirement of the first mode.
Corresponding to the processing method, an embodiment of the present application further provides an electronic device, which is described in detail below through several embodiments.
An embodiment of the apparatus of the present application provides an electronic device, as shown in fig. 6, the electronic device includes: a first module 100, a second module 200, a processor 300; wherein:
a first module 100 for obtaining electrical energy in a first manner;
a second module 200 for supplying electric energy to the outside through a second manner;
the first mode and the second mode represent different charge and discharge modes. Specifically, the first mode is a wired mode and the second mode is a wireless mode, or the first mode is a wireless mode and the second mode is a wired mode, or the first mode is a first wired mode and the second mode is a second wired mode, and the first wired mode is different from the second wired mode. The first mode is different from the second mode, so that the first module is different from the second module.
For example, the first module includes but is not limited to an adapter, and correspondingly, the first mode includes but is not limited to a mode of obtaining electric energy through the adapter, and the second module includes but is not limited to a wireless charging module, and correspondingly, the second mode includes but is not limited to a mode of providing external electric energy through the wireless charging module.
And a processor 300, configured to monitor whether the second module provides external electric energy in a process of obtaining electric energy through the first module, determine to use the second module to provide external electric energy, obtain a power consumption parameter under the first module, and switch a first mode in which the second module currently operates to a second mode if the power consumption parameter is greater than a first threshold.
Wherein the highest allowed power consumption in the second mode is less than the highest allowed power consumption in the first mode.
The power consumption parameter is used for representing the electric energy power consumption in the first mode, and specifically may be a power parameter, a current parameter, and the like. For example, the power consumption parameter may be a current power consumption parameter of the first module, and if the first module is an adapter, the power consumption parameter may be a current power consumption parameter of the adapter.
It should be noted that, the operating loads of the electronic devices are different, the power consumption parameters of the first module are different, the larger the operating load is, the larger the power consumption parameter of the first module is, the smaller the operating load is, and the smaller the power consumption parameter of the first module is.
The first threshold is preset, and the set value can be determined based on the maximum power consumption of the first module. For example, the maximum power consumption of the first module is 120w, then the first threshold may be set to 119w, and when the power consumption parameter exceeds 119w, the first mode in which the second module is currently operating is switched to the second mode.
Wherein the highest allowed power consumption in the second mode is less than the highest allowed power consumption in the first mode. For example, the maximum allowed power consumption of the first mode is 20w, and the maximum allowed power consumption of the second mode is 8w, then after the first mode in which the second module is currently operating is switched to the second mode, the power consumption parameter may be reduced by at least 10 w. If the second module is a wireless charging module, the first mode may be an EPP mode and the second mode may be a BPP mode. Wherein, the maximum allowable power consumption of the EPP mode is 15w, and the maximum allowable power consumption of the BPP mode is 5 w.
Therefore, in the application, in the process that the electronic equipment acquires the electric energy through the first module and provides the electric energy to the outside through the second module, if the power consumption parameter of the first module is determined to be larger than the first threshold value, the highest allowable power consumption of the current work of the second module is directly reduced, the power consumption requirement of the first module can be met, the power consumption is not required to be increased through replacing the module carried by the first mode for the electronic equipment, and the control flexibility is improved.
In an embodiment of the apparatus of the present application, the processor is further configured to monitor whether the power consumption parameter is reduced below a second threshold when the second module operates in a second mode, determine that the power consumption parameter is reduced below the second threshold, and switch the second mode in which the second module currently operates to the first mode.
Wherein the second threshold is less than the first threshold.
Since the maximum allowable power consumption of the second mode is lower than that of the first mode, the charging efficiency of the second mode in the second mode is lower than that in the first mode. Therefore, when the power consumption parameter is lower than the second threshold value, the second module can be switched from the second mode to the first mode. The specific parameter value of the second threshold may be a fixed value preset by the system, or may be calculated by the system, specifically:
the processor is configured to determine a difference between a highest allowed power consumption in the first mode and a highest allowed power consumption in the second mode, and subtract the difference from the first threshold to obtain a second threshold.
In the second embodiment of the apparatus of the present application, in the process that the electronic device obtains the electric energy through the first module and simultaneously provides the electric energy through the second module, if it is determined that the power consumption parameter of the first module is greater than the first threshold, the highest allowable power consumption of the second module in the current work is directly reduced, so that the power consumption requirement of the first module can be ensured, the power consumption does not need to be increased by replacing the first module for the electronic device, and the flexibility of control is improved; and when the second module works in the second mode, if the power consumption parameter is determined to be reduced below the second threshold value, the second mode in which the second module works currently can be switched back to the first mode, so that the efficiency of the second module for improving the electric energy externally is improved on the basis of not influencing the power consumption requirement of the first module.
In a third embodiment of the apparatus of the present application, the processor is further configured to monitor whether the power consumption parameter is always below the second threshold value within a first time, and if so, execute switching the second mode in which the second module is currently operating to the first mode.
Since the maximum allowable power consumption of the second mode is lower than that of the first mode, the charging efficiency of the second module in the second mode is lower than that in the first mode. Therefore, when the power consumption parameter meets the condition, the second module can be switched from the second mode to the first mode. If the mode is switched only by depending on the fact that the power consumption parameter is lower than the second threshold value, the current working state of the system is unstable, and the power consumption parameter of the first module is caused to rise and fall suddenly, so that timing can be started when the power consumption parameter is reduced to be lower than the second threshold value, whether the power consumption parameter is always lower than the second threshold value within the first time or not is monitored, and if the power consumption parameter is lower than the second threshold value, the second mode in which the second module works currently can be switched back to the first mode.
An embodiment of the apparatus of the present application provides an electronic device, as shown in fig. 7, including: a first module 100, a second module 200, a processor 300, and a sensor 400; wherein:
a first module 100 for obtaining electrical energy in a first manner;
the sensor 400 is serially disposed between the first module 100 and a charging interface (not shown in the figure) for obtaining a power consumption parameter of the first module 100.
The sensor may include, but is not limited to, a current sensor.
A second module 200 for supplying electric energy to the outside through a second manner;
and the processor 300 is configured to monitor whether the second module provides external electric energy or not in the process of obtaining electric energy through the first module, determine that the second module provides external electric energy, obtain a power consumption parameter of the first module 100 through the sensor 400 serially connected between the first module 100 and the charging interface, and switch a first mode of current operation of the second module into a second mode if the power consumption parameter is greater than a first threshold.
Wherein the highest allowed power consumption in the second mode is less than the highest allowed power consumption in the first mode.
In a fifth embodiment of the apparatus of the present application, as shown in fig. 8, an electronic device includes: a first monitoring unit 801, a first acquisition unit 802, and a first switching unit 803; wherein:
the first monitoring unit 801 is configured to monitor whether a second mode is adopted to supply electric energy to the outside in the process of acquiring the electric energy through the first mode;
the first mode and the second mode represent different charge and discharge modes. Specifically, the first mode is a wired mode and the second mode is a wireless mode, or the first mode is a wireless mode and the second mode is a wired mode, or the first mode is a first wired mode and the second mode is a second wired mode, and the first wired mode is different from the second wired mode. The first mode and the second mode are different, so that the first mode and the second mode correspond to different modules.
For example, the first mode includes, but is not limited to, a mode of obtaining electric energy through the adapter, and the second mode includes, but is not limited to, a mode of externally providing electric energy through the wireless charging module.
A first obtaining unit 802, configured to determine that electric energy is externally provided in the second manner, and obtain a power consumption parameter in the first manner;
when it is determined that the electronic equipment is providing electric energy in the first mode and the second mode, the power consumption parameter in the first mode is obtained.
The power consumption parameter is used for representing the electric energy power consumption in the first mode, and specifically may be a power parameter, a current parameter, and the like. For example, the power consumption parameter may be a current power consumption parameter of the first module corresponding to the first mode, and if the first module is an adapter, the power consumption parameter may be a current power consumption parameter of the adapter.
It should be noted that, the operating loads of the electronic devices are different, the power consumption parameters in the first mode are different, and the larger the operating load is, the larger the power consumption parameter in the first mode is, the smaller the operating load is, and the smaller the power consumption parameter in the first mode is.
A first switching unit 803, configured to switch a first mode in which the second mode is currently operating to a second mode if the power consumption parameter is greater than a first threshold, where a highest allowed power consumption in the second mode is less than a highest allowed power consumption in the first mode.
The first threshold is preset, and the set value may be determined based on a maximum power consumption of the first module corresponding to the first mode. For example, if the maximum power consumption of the first module is 120w, the first threshold may be set to 119w, and when the power consumption parameter exceeds 119w, the first mode in which the second mode is currently operated is switched to the second mode.
The second mode may correspond to a second module, and switching the first mode in which the second mode is currently operated to the second mode may include: and switching the second module from the first mode of current work to the second mode.
Wherein the highest allowed power consumption in the second mode is less than the highest allowed power consumption in the first mode. For example, the maximum allowed power consumption of the first mode is 20w, and the maximum allowed power consumption of the second mode is 8w, then after the first mode in which the second mode is currently operating is switched to the second mode, the power consumption parameter can be reduced by at least 10 w. If the second mode is wireless, the first mode may be EPP mode and the second mode may be BPP mode. Wherein, the maximum allowable power consumption of the EPP mode is 15w, and the maximum allowable power consumption of the BPP mode is 5 w.
Therefore, in the application, in the process that the electronic equipment acquires the electric energy through the first mode and provides the electric energy to the outside through the second mode, if the power consumption parameter under the first mode is determined to be larger than the first threshold value, the highest allowable power consumption of the current work of the second mode is directly reduced, so that the power consumption requirement under the first mode can be met, the power consumption is not required to be increased through replacing the module carried by the first mode for the electronic equipment, and the control flexibility is improved.
In a sixth embodiment of the apparatus of this application, the electronic device further includes:
the second monitoring unit is used for monitoring whether the power consumption parameter is reduced below a second threshold value when the second mode works in the second mode;
wherein the second threshold is less than the first threshold.
A second switching unit, configured to determine that the power consumption parameter is reduced below the second threshold, and switch the second mode in which the second mode is currently operating to the first mode.
Since the maximum allowable power consumption of the second mode is lower than that of the first mode, the charging efficiency of the second mode in the second mode is lower than that in the first mode. Therefore, when the power consumption parameter is lower than the second threshold value, the second mode can be switched to the first mode from the second mode. The specific parameter value of the second threshold may be a fixed value preset by the system, or may be calculated by the system, which will be described later.
Therefore, in the embodiment, in the process that the electronic device obtains the electric energy through the first mode and simultaneously provides the electric energy through the second mode, if the power consumption parameter in the first mode is determined to be larger than the first threshold value, the highest allowable power consumption of the current work of the second mode is directly reduced, so that the power consumption requirement of the first mode can be ensured, the power consumption is not required to be increased by replacing the module carried in the first mode for the electronic device, and the control flexibility is improved; and when the second mode works in the second mode, if the power consumption parameter is determined to be reduced below the second threshold, the second mode in which the second mode works currently can be switched back to the first mode, so that the efficiency of the second mode for improving electric energy externally is improved on the basis of not influencing the power consumption requirement of the first mode.
In an embodiment of the apparatus of the present application, the electronic device further includes:
the third monitoring unit is used for monitoring whether the power consumption parameter is always below the second threshold value in the first time;
the second switching unit is specifically configured to monitor that the power consumption parameter is always below the second threshold value within a first time, and switch the second mode in which the second mode is currently operating to the first mode.
Since the maximum allowable power consumption of the second mode is lower than that of the first mode, the charging efficiency of the second mode in the second mode is lower than that in the first mode. Therefore, when the power consumption parameter meets the condition, the second mode can be switched from the second mode to the first mode. If the mode is switched only by depending on the fact that the power consumption parameter is lower than the second threshold value, the current working state of the system is unstable, and the power consumption parameter in the first mode is increased and decreased suddenly, so that timing can be started when the power consumption parameter is decreased to be lower than the second threshold value, whether the power consumption parameter is always lower than the second threshold value within the first time or not is monitored, and if the power consumption parameter is lower than the second threshold value, the second mode of the second mode which works currently can be switched back to the first mode.
In the embodiment, in the process that the electronic equipment acquires the electric energy through the first mode and simultaneously provides the electric energy through the second mode, if the power consumption parameter in the first mode is determined to be larger than the first threshold value, the highest allowable power consumption of the current work of the second mode is directly reduced, so that the power consumption requirement of the first mode can be ensured, the power consumption does not need to be increased by replacing a module carried in the first mode for the electronic equipment, and the control flexibility is improved; and when the second mode works in the second mode, if the power consumption parameter is determined to be reduced below the second threshold, the power consumption parameter is monitored to be always below the second threshold in the first time, and the second mode of the current work of the second mode can be switched back to the first mode, so that the efficiency of the second mode for externally improving the electric energy is improved on the basis of stable system working state.
In an eighth embodiment of the apparatus of the present application, the first obtaining unit is specifically configured to determine that the second mode is used to externally provide electric energy, and obtain the power consumption parameter in the first mode through a sensor arranged in series between the first module corresponding to the first mode and the charging interface.
In an embodiment of the apparatus of the present application, the electronic device further includes:
a first determining unit, configured to determine a difference between a highest allowed power consumption in the first mode and a highest allowed power consumption in the second mode;
a first calculating unit, configured to subtract the difference value from the first threshold value to obtain the second threshold value.
The embodiments in the present description are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other. The device disclosed by the embodiment corresponds to the method disclosed by the embodiment, so that the description is simple, and the relevant points can be referred to the method part for description.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (10)

1. A method of processing, comprising:
monitoring whether a second mode is adopted to supply electric energy to the outside or not in the process of acquiring the electric energy through the first mode;
determining that electric energy is provided externally by adopting the second mode, and acquiring power consumption parameters in the first mode;
if the power consumption parameter is larger than a first threshold value, switching a first mode in which the second mode works currently into a second mode, wherein the highest allowed power consumption in the second mode is smaller than the highest allowed power consumption in the first mode;
the second mode corresponds to a second module, and switching the first mode in which the second mode currently operates to the second mode includes: and switching the second module from a first mode of current work to a second mode.
2. The method of claim 1, further comprising:
monitoring whether the power consumption parameter falls below a second threshold while the second mode is operating in the second mode; the second threshold is less than the first threshold;
determining that the power consumption parameter falls below the second threshold, switching the second mode in which the second mode is currently operating to the first mode.
3. The method of claim 2, further comprising:
monitoring whether the power consumption parameter is always below the second threshold value in a first time, and if so, triggering the second mode of the second mode to be switched to the first mode.
4. The method of claim 1, wherein the obtaining the power consumption parameter in the first manner comprises:
and acquiring the power consumption parameters in the first mode through a sensor which is arranged in series between the first module corresponding to the first mode and the charging interface.
5. The method of claim 2, further comprising:
determining a difference between a highest allowed power consumption in the first mode and a highest allowed power consumption in the second mode;
subtracting the difference value on the basis of the first threshold value to obtain the second threshold value.
6. An electronic device, comprising:
the first module is used for acquiring electric energy in a first mode;
the second module is used for providing electric energy to the outside in a second mode;
the processor is used for monitoring whether the second module provides electric energy to the outside or not in the process of obtaining the electric energy through the first module, determining that the second module provides the electric energy to the outside, obtaining a power consumption parameter under the first module, and switching a first mode of the current work of the second module into a second mode if the power consumption parameter is larger than a first threshold value, wherein the highest allowable power consumption under the second mode is smaller than the highest allowable power consumption under the first mode;
the second mode corresponds to a second module.
7. The electronic device of claim 6, the processor further configured to monitor whether the power consumption parameter falls below a second threshold while the second module is operating in the second mode; and when the second threshold is smaller than the first threshold, determining that the power consumption parameter is reduced below the second threshold, and switching the second mode in which the second module is currently working to the first mode.
8. The electronic device of claim 7, wherein the processor is further configured to monitor whether the power consumption parameter is always below the second threshold for a first time, and if so, perform the switching the second mode in which the second module is currently operating to the first mode.
9. The electronic device of claim 7, further comprising:
the sensor is arranged between the first module and the charging interface;
the processor is specifically used for acquiring power consumption parameters under the first module through a sensor which is arranged between the first module and the charging interface in series.
10. An electronic device, comprising:
the first monitoring unit is used for monitoring whether a second mode is adopted to supply electric energy to the outside in the process of acquiring the electric energy through the first mode;
the first obtaining unit is used for determining that electric energy is supplied to the outside in the second mode and obtaining the power consumption parameter in the first mode;
a first switching unit, configured to switch a first mode in which the second mode currently operates to a second mode if the power consumption parameter is greater than a first threshold, where a highest allowed power consumption in the second mode is less than a highest allowed power consumption in the first mode;
the second mode corresponds to a second module, and the first switching unit is specifically configured to switch the second module from a first mode of current operation to a second mode.
CN201811609000.6A 2018-12-27 2018-12-27 Processing method and electronic equipment Active CN109710051B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811609000.6A CN109710051B (en) 2018-12-27 2018-12-27 Processing method and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811609000.6A CN109710051B (en) 2018-12-27 2018-12-27 Processing method and electronic equipment

Publications (2)

Publication Number Publication Date
CN109710051A CN109710051A (en) 2019-05-03
CN109710051B true CN109710051B (en) 2021-01-15

Family

ID=66258588

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811609000.6A Active CN109710051B (en) 2018-12-27 2018-12-27 Processing method and electronic equipment

Country Status (1)

Country Link
CN (1) CN109710051B (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105068915A (en) * 2015-08-10 2015-11-18 合肥联宝信息技术有限公司 Power supply management device and method
CN108181978A (en) * 2017-12-29 2018-06-19 合肥联宝信息技术有限公司 The electrical control method and device of a kind of electronic equipment

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7772802B2 (en) * 2007-03-01 2010-08-10 Eastman Kodak Company Charging display system
US8856561B2 (en) * 2012-05-10 2014-10-07 Hewlett-Packard Development Company, L.P. Allocating and distributing power
CN103677199B (en) * 2012-09-18 2017-11-07 联想(北京)有限公司 The method of information processing and the first electronic equipment
CN203260874U (en) * 2013-05-15 2013-10-30 深圳市文鼎创数据科技有限公司 Adapter of portable device
CN104184200A (en) * 2013-05-24 2014-12-03 台达电子工业股份有限公司 Power supply adapter, power supply adapter control method and notebook
CN105490319B (en) * 2014-09-19 2018-11-09 联想(北京)有限公司 A kind of information processing method and electronic equipment
EP3283934A1 (en) * 2015-05-14 2018-02-21 Apple Inc. Dynamic power sharing among multiple physical ports
CN206147512U (en) * 2016-07-29 2017-05-03 深圳中电长城信息安全系统有限公司 Computer and USB power supply circuit thereof

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105068915A (en) * 2015-08-10 2015-11-18 合肥联宝信息技术有限公司 Power supply management device and method
CN108181978A (en) * 2017-12-29 2018-06-19 合肥联宝信息技术有限公司 The electrical control method and device of a kind of electronic equipment

Also Published As

Publication number Publication date
CN109710051A (en) 2019-05-03

Similar Documents

Publication Publication Date Title
EP2733814B1 (en) Device, method and user equipment for power supply
CN108732413B (en) Alarm method and device for electric equipment
CN109217488B (en) Charging circuit, electronic device, charging method, and storage medium
JPWO2015045058A1 (en) Non-contact power supply system and power transmission device
US10252627B2 (en) On board charger input current limit setting based on AC input circuit voltage response
US20150171664A1 (en) Power supply system and control method thereof
CN109895650B (en) Power control system and vehicle
CN108513616A (en) A kind of battery leakage current detection method, device and circuit
CN108628431A (en) Electronic equipment and its certainly energy consumption control circuit
CN110579720B (en) Power supply monitor
CN105896639B (en) Charging control method and electronic equipment
CN109710051B (en) Processing method and electronic equipment
CN211236077U (en) Data contrast type electric power overload early warning device
US20140111014A1 (en) Charging and discharging system and method for battery
CN109038751B (en) Charging control method, mobile terminal and storage medium
CN105656327A (en) State monitoring method, power adapter and electronic equipment
CN112693361B (en) Battery protection system and method
CN114552740A (en) Plug-and-play intelligent switching system and control method thereof
CN104237807A (en) Inverter system for monitoring state of storage battery and monitoring method
CN106486716B (en) Method and system for avoiding abnormal electric quantity display of mobile terminal
CN112821494A (en) Wireless charging detection method, device and system
CN109450096A (en) A kind of power supply unit and method for controlling power supply
CN110752742A (en) Direct current conversion control circuit and method for reducing power consumption and power supply system
CN211785759U (en) Thing allies oneself with monitor terminal with power-on and power-off reminding function
CN116901775B (en) Charging gun detection method and related equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant