Power consumption control method, system, terminal and storage medium for notebook computer

文档序号:1920941 发布日期:2021-12-03 浏览:19次 中文

阅读说明:本技术 笔记本电脑功耗控制方法、系统、终端及存储介质 (Power consumption control method, system, terminal and storage medium for notebook computer ) 是由 马晓光 刘毅枫 尹馨 于 2021-09-13 设计创作,主要内容包括:本发明提供一种笔记本电脑功耗控制方法、系统、终端及存储介质,包括:利用电流传感器采集主板总电流;根据所述总电流和定值电压计算总功率;将所述总功率与设定的功率阈值进行比对,若所述总功率超过所述功率阈值则通过更新电源充电程序的电流限制参数调小电源充电电流。本发明能够实现对笔记本功耗的有效控制,避免笔记本电脑功耗过高导致性能下降甚至宕机的情况。且本发明的功耗控制方法避开了嵌入式控制器,且能够实现对充电程序功耗的自动调节,平衡了充电速率与功耗控制,增强了笔记本电脑的总体性能。(The invention provides a power consumption control method, a system, a terminal and a storage medium of a notebook computer, comprising the following steps: collecting the total current of the mainboard by using a current sensor; calculating total power according to the total current and a fixed value voltage; and comparing the total power with a set power threshold, and if the total power exceeds the power threshold, reducing the power supply charging current by updating a current limit parameter of a power supply charging program. The invention can realize effective control of the power consumption of the notebook computer and avoid the condition of performance reduction and even downtime caused by overhigh power consumption of the notebook computer. The power consumption control method avoids an embedded controller, can realize automatic adjustment of the power consumption of the charging program, balances the charging rate and the power consumption control, and enhances the overall performance of the notebook computer.)

1. A power consumption control method of a notebook computer is characterized by comprising the following steps:

collecting the total current of the mainboard by using a current sensor;

calculating total power according to the total current and a fixed value voltage;

and comparing the total power with a set power threshold, and if the total power exceeds the power threshold, reducing the power supply charging current by updating a current limit parameter of a power supply charging program.

2. The method of claim 1, wherein collecting the total motherboard current using a current sensor comprises:

monitoring an identification state of the processor by establishing a connection with the processor;

and if the processor is successfully identified, judging that the processor is in a working state, and starting to collect the total current of the mainboard.

3. The method of claim 2, wherein determining that the processor is in the working state if the processor is successfully identified, and starting collection of the total current of the motherboard comprises:

and acquiring the total current of the mainboard acquired by the current sensor regularly according to a set current acquisition period.

4. The method of claim 1, wherein comparing the total power to a set power threshold and if the total power exceeds the power threshold, reducing the power charging current by updating a current limit parameter of a power charging routine comprises:

gradually reducing the charging current of the power supply according to the set step pitch;

and comparing the updated total power with a set power threshold value after adjusting the charging current each time, and stopping adjusting the charging current if the updated total power is not lower than the power threshold value.

5. The method of claim 1, further comprising:

and calculating a difference value between the power threshold value and the total power, and if the difference value exceeds a preset difference value threshold value, increasing the power supply charging current by updating a current limit parameter of a power supply charging program until the difference value does not exceed the difference value threshold value.

6. A power consumption control system for a notebook computer, comprising:

the current acquisition unit is used for acquiring the total current of the mainboard by using the current sensor;

the power calculation unit is used for calculating total power according to the total current and the fixed value voltage;

and the power regulating unit is used for comparing the total power with a set power threshold value, and if the total power exceeds the power threshold value, the charging current of the power supply is reduced by updating a current limit parameter of a power supply charging program.

7. The system of claim 6, wherein the current collection unit is configured to:

monitoring an identification state of the processor by establishing a connection with the processor;

and if the processor is successfully identified, judging that the processor is in a working state, and starting to collect the total current of the mainboard.

8. The system of claim 7, wherein determining that the processor is in the working state if the processor is successfully identified and initiating collection of the total motherboard current comprises:

and acquiring the total current of the mainboard acquired by the current sensor regularly according to a set current acquisition period.

9. A terminal, comprising:

a processor;

a memory for storing instructions for execution by the processor;

wherein the processor is configured to perform the method of any one of claims 1-5.

10. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the method according to any one of claims 1-5.

Technical Field

The invention relates to the technical field of notebook terminals, in particular to a power consumption control method, a power consumption control system, a power consumption control terminal and a power consumption control storage medium for a notebook computer.

Background

When the notebook computer is in a working state, the power consumption of the notebook computer comprises a plurality of power consumption peripherals besides service operation components such as a processor and the like. If the power consumption of the notebook computer is too high, the heat generation is serious, and the performance of the notebook computer is seriously influenced due to the fact that the heat dissipation capacity of the notebook computer is limited.

At present, a commonly used power consumption control method of a notebook computer depends on an embedded Controller, and an EC (embedded Controller) is a 16-bit or 8-bit singlechip, which is a unique part in the notebook computer. Moreover, the most important problem in the design of notebook computers is to control the stop of the CPU fan according to the temperature, in order to save more power and increase the endurance of the battery, and to have good heat dissipation performance and minimize the noise of the system. Some power management of the notebook computer, such as the notebook entering a standby or power-off mode, power dispatching of the external power system. And (3) performing power detection and charging and discharging tasks of the intelligent battery. And some utility shortcut buttons. These important functions are performed by the EC. The EC plays an important role in the portable, intelligent and personalized design of the notebook computer. However, the existing embedded controller has high requirements for electronic devices, so that mature EC controllers are few and are not easy to obtain.

The existing EC controller is also only a battery charging adjustment tool, and some parameters need to be manually set and then the EC controller is used to adjust the battery charging program, and the adjustment method has hysteresis.

Disclosure of Invention

In view of the above-mentioned deficiencies of the prior art, the present invention provides a method, a system, a terminal and a storage medium for controlling power consumption of a notebook computer, so as to solve the above-mentioned technical problems.

In a first aspect, the present invention provides a power consumption control method for a notebook computer, including:

collecting the total current of the mainboard by using a current sensor;

calculating total power according to the total current and a fixed value voltage;

and comparing the total power with a set power threshold, and if the total power exceeds the power threshold, reducing the power supply charging current by updating a current limit parameter of a power supply charging program.

Further, utilize current sensor to gather mainboard total current, include:

monitoring an identification state of the processor by establishing a connection with the processor;

and if the processor is successfully identified, judging that the processor is in a working state, and starting to collect the total current of the mainboard.

Further, if the processor is successfully identified, it is determined that the processor is in a working state, and collection of the total current of the main board is started, including:

and acquiring the total current of the mainboard acquired by the current sensor regularly according to a set current acquisition period.

Further, comparing the total power with a set power threshold, and if the total power exceeds the power threshold, reducing the power charging current by updating a current limit parameter of a power charging program, including:

gradually reducing the charging current of the power supply according to the set step pitch;

and comparing the updated total power with a set power threshold value after adjusting the charging current each time, and stopping adjusting the charging current if the updated total power is not lower than the power threshold value.

Further, the method further comprises:

and calculating a difference value between the power threshold value and the total power, and if the difference value exceeds a preset difference value threshold value, increasing the power supply charging current by updating a current limit parameter of a power supply charging program until the difference value does not exceed the difference value threshold value.

In a second aspect, the present invention provides a power consumption control system for a notebook computer, including:

the current acquisition unit is used for acquiring the total current of the mainboard by using the current sensor;

the power calculation unit is used for calculating total power according to the total current and the fixed value voltage;

and the power regulating unit is used for comparing the total power with a set power threshold value, and if the total power exceeds the power threshold value, the charging current of the power supply is reduced by updating a current limit parameter of a power supply charging program.

Further, the current collection unit is used for:

monitoring an identification state of the processor by establishing a connection with the processor;

and if the processor is successfully identified, judging that the processor is in a working state, and starting to collect the total current of the mainboard.

Further, if the processor is successfully identified, it is determined that the processor is in a working state, and collection of the total current of the main board is started, including:

and acquiring the total current of the mainboard acquired by the current sensor regularly according to a set current acquisition period.

Further, the power calculating unit is configured to:

gradually reducing the charging current of the power supply according to the set step pitch;

and comparing the updated total power with a set power threshold value after adjusting the charging current each time, and stopping adjusting the charging current if the updated total power is not lower than the power threshold value.

Further, the power regulating unit is configured to:

and calculating a difference value between the power threshold value and the total power, and if the difference value exceeds a preset difference value threshold value, increasing the power supply charging current by updating a current limit parameter of a power supply charging program until the difference value does not exceed the difference value threshold value.

In a third aspect, a terminal is provided, including:

a processor, a memory, wherein,

the memory is used for storing a computer program which,

the processor is used for calling and running the computer program from the memory so as to make the terminal execute the method of the terminal.

In a fourth aspect, a computer storage medium is provided having stored therein instructions that, when executed on a computer, cause the computer to perform the method of the above aspects.

The beneficial effect of the invention is that,

according to the power consumption control method, the system, the terminal and the storage medium of the notebook computer, provided by the invention, the total power of the notebook computer is monitored by collecting the total current of a mainboard by using a current sensor and calculating the total power according to the total current and a fixed value voltage; and comparing the total power with a set power threshold, and if the total power exceeds the power threshold, reducing the power supply charging current by updating a current limit parameter of a power supply charging program. The power consumption of the charging program is limited based on the comparison result of the total power and the power threshold value, so that the effective control of the power consumption of the notebook computer is realized, and the condition that the performance of the notebook computer is reduced and even the notebook computer is down due to overhigh power consumption is avoided. The power consumption control method avoids an embedded controller, can realize automatic adjustment of the power consumption of the charging program, balances the charging rate and the power consumption control, and enhances the overall performance of the notebook computer.

In addition, the invention has reliable design principle, simple structure and very wide application prospect.

Drawings

In order to more clearly illustrate the embodiments or technical solutions in the prior art of the present invention, the drawings used in the description of the embodiments or prior art will be briefly described below, and it is obvious for those skilled in the art that other drawings can be obtained based on these drawings without creative efforts.

FIG. 1 is a schematic flow diagram of a method of one embodiment of the invention.

FIG. 2 is another schematic flow diagram of a method of one embodiment of the invention.

FIG. 3 is a schematic block diagram of a system of one embodiment of the present invention.

Fig. 4 is a schematic structural diagram of a terminal according to an embodiment of the present invention.

Detailed Description

In order to make those skilled in the art better understand the technical solution of the present invention, the technical solution in the embodiment of the present invention will be clearly and completely described below with reference to the drawings in the embodiment of the present invention, and it is obvious that the described embodiment is only a part of the embodiment of the present invention, and not all 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 notebook computer charging mode is divided into wc, pc, nc, dc and fc modes:

wc (wake-up charge): and the awakening charging mode is responsible for initializing battery charging, initializing communication (SMBUS) between the battery and the ec, reading the residual electric quantity of the battery and judging whether the battery is overdischarged or not or whether the battery can be charged or not.

Pc (pre-charge): the pre-charging mode, which is generally a low current charging mode, is performed for about 6 seconds, and the low current charging mode is generally 0.2A, and then the pre-charging mode is converted into a normal charging (nc) mode.

Nc (normal charge): normal charging, after the precharge is completed, normal charging is performed, and the charging current is generally limited to about 2A.

Dc (discharge): the charging is stopped.

Fc (full charged): and when the battery is fully charged, the communication between the ec and the battery is utilized to obtain the information of the residual electric quantity of the battery, so as to avoid the influence on the service life of the battery due to the overcharge of the battery, and when the electric quantity of the battery is greater than 98% or the electric quantity is greater than 95%, and the charging current is less than 100mA, the battery can be considered to be fully charged.

The voltage of the high-capacity notebook lithium battery can reach 16.8v, and the charging power consumption is about 30w when the high-capacity notebook lithium battery is charged at full current.

FIG. 1 is a schematic flow diagram of a method of one embodiment of the invention. The execution main body in fig. 1 may be a power consumption control system of a notebook computer.

As shown in fig. 1, the method includes:

step 110, collecting the total current of the mainboard by using a current sensor;

step 120, calculating total power according to the total current and a fixed value voltage;

step 130, comparing the total power with a set power threshold, and if the total power exceeds the power threshold, reducing the power charging current by updating a current limit parameter of a power charging program.

In order to facilitate understanding of the present invention, the power consumption control method of the notebook computer according to the present invention is further described below with reference to the principle of the power consumption control method of the notebook computer according to the present invention and the process of controlling the power consumption of the notebook computer in the embodiment.

The method provided by the invention can be operated on various control devices including a g32 singlechip, and specifically, referring to fig. 2, the power consumption control method of the notebook computer comprises the following steps:

and S1, collecting the total current of the mainboard by using a current sensor.

Monitoring an identification state of the processor by establishing a connection with the processor; if the processor is successfully identified, the processor is judged to be in a working state, the collection of the total current of the mainboard is started, and the total current of the mainboard collected by the current sensor is regularly obtained according to a set current collection period.

Specifically, whether the cpu is in the working mode is judged firstly, and if the system is not in the working state (s0), most of electricity in the notebook computer does not work at this time, so that the normal charging process is directly performed without performing power limitation, namely, the mode enters the wc mode, the pc mode and the nc mode, and the high-power charging is performed. If the notebook computer is in the s0 state, the total mainboard current collected by the current sensor is read periodically.

And S2, calculating the total power according to the total current and the fixed value voltage.

Using the formula: and when the voltage of the notebook computer is a fixed value, the total power is calculated according to the collected total current of the mainboard.

And S3, comparing the total power with a set power threshold, and if the total power exceeds the power threshold, reducing the power supply charging current by updating a current limit parameter of a power supply charging program.

If the total power exceeds a set power threshold, gradually reducing the charging current of the power supply according to a set step pitch; and comparing the updated total power with a set power threshold value after adjusting the charging current each time, and stopping adjusting the charging current if the updated total power is not lower than the power threshold value.

Specifically, the calculated power consumption is compared with a threshold, and if the calculated power consumption does not exceed the threshold, power limitation is not necessary at this time, and the normal charge mode is similarly performed in the charge mode. And if the calculated power exceeds the threshold value, switching from the normal charge mode to the power limiting mode, and reducing the charging power to be below the threshold value. And under the power limiting mode, setting the step pitch to be 1A, reducing the upper limit of the charging current by 1A through one-time adjustment, re-collecting the total current of the mainboard to calculate the total power, reducing the upper limit of the charging current by 1A if the total power is still larger than the power threshold, and performing the operation in a circulating mode until the total power does not exceed the power threshold. In modifying the upper limit of the charging current, a method of modifying parameters is employed, for example, 2 8-bit data for controlling the charging current of the battery, BAT _ CC _ H upper eight bits, and BAT _ CC _ L lower eight bits are set. And converting the 16-bit 2 system into a decimal system, namely, the decimal system is a value corresponding to the maximum charging current, and modifying the unit mA into a corresponding value.

In order to reduce the influence of power consumption regulation on the charging speed, the difference value between a power threshold value and the total power is calculated, if the difference value exceeds a preset difference value threshold value, the power supply charging current is increased through updating a current limit parameter of a power supply charging program until the difference value does not exceed the difference value threshold value. That is, when the polling is performed until the power of the current corresponding to the adc is too small, the power limiting mode is released, and the charging current is increased.

As shown in fig. 3, the system 300 includes:

a current collecting unit 310 for collecting a total current of the main board using the current sensor;

a power calculating unit 320, configured to calculate a total power according to the total current and a fixed value voltage;

the power adjusting unit 330 is configured to compare the total power with a set power threshold, and if the total power exceeds the power threshold, decrease the power charging current by updating a current limit parameter of the power charging program.

Optionally, as an embodiment of the present invention, the current collecting unit is configured to:

monitoring an identification state of the processor by establishing a connection with the processor;

and if the processor is successfully identified, judging that the processor is in a working state, and starting to collect the total current of the mainboard.

Optionally, as an embodiment of the present invention, if the processor is successfully identified, it is determined that the processor is in a working state, and the starting of collecting the total current of the motherboard includes:

and acquiring the total current of the mainboard acquired by the current sensor regularly according to a set current acquisition period.

Optionally, as an embodiment of the present invention, the power calculating unit is configured to:

gradually reducing the charging current of the power supply according to the set step pitch;

and comparing the updated total power with a set power threshold value after adjusting the charging current each time, and stopping adjusting the charging current if the updated total power is not lower than the power threshold value.

Optionally, as an embodiment of the present invention, the power adjusting unit is configured to:

and calculating a difference value between the power threshold value and the total power, and if the difference value exceeds a preset difference value threshold value, increasing the power supply charging current by updating a current limit parameter of a power supply charging program until the difference value does not exceed the difference value threshold value.

Fig. 4 is a schematic structural diagram of a terminal 400 according to an embodiment of the present invention, where the terminal 400 may be used to execute the power consumption control method of a notebook computer according to the embodiment of the present invention.

Among them, the terminal 400 may include: a processor 410, a memory 420, and a communication unit 430. The components communicate via one or more buses, and those skilled in the art will appreciate that the architecture of the servers shown in the figures is not intended to be limiting, and may be a bus architecture, a star architecture, a combination of more or less components than those shown, or a different arrangement of components.

The memory 420 may be used for storing instructions executed by the processor 410, and the memory 420 may be implemented by any type of volatile or non-volatile storage terminal or 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. The executable instructions in memory 420, when executed by processor 410, enable terminal 400 to perform some or all of the steps in the method embodiments described below.

The processor 410 is a control center of the storage terminal, connects various parts of the entire electronic terminal using various interfaces and lines, and performs various functions of the electronic terminal and/or processes data by operating or executing software programs and/or modules stored in the memory 420 and calling data stored in the memory. The processor may be composed of an Integrated Circuit (IC), for example, a single packaged IC, or a plurality of packaged ICs connected with the same or different functions. For example, the processor 410 may include only a Central Processing Unit (CPU). In the embodiment of the present invention, the CPU may be a single operation core, or may include multiple operation cores.

A communication unit 430, configured to establish a communication channel so that the storage terminal can communicate with other terminals. And receiving user data sent by other terminals or sending the user data to other terminals.

The present invention also provides a computer storage medium, wherein the computer storage medium may store a program, and the program may include some or all of the steps in the embodiments provided by the present invention when executed. The storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM) or a Random Access Memory (RAM).

Therefore, the total power of the notebook computer is monitored by collecting the total current of the mainboard by using the current sensor and calculating the total power according to the total current and the constant voltage; and comparing the total power with a set power threshold, and if the total power exceeds the power threshold, reducing the power supply charging current by updating a current limit parameter of a power supply charging program. The power consumption of the charging program is limited based on the comparison result of the total power and the power threshold value, so that the effective control of the power consumption of the notebook computer is realized, and the condition that the performance of the notebook computer is reduced and even the notebook computer is down due to overhigh power consumption is avoided. The power consumption control method of the invention avoids an embedded controller, can realize automatic adjustment of the power consumption of the charging program, balances the charging rate and the power consumption control, and enhances the overall performance of the notebook computer.

Those skilled in the art will readily appreciate that the techniques of the embodiments of the present invention may be implemented as software plus a required general purpose hardware platform. Based on such understanding, the technical solutions in the embodiments of the present invention may be embodied in the form of a software product, where the computer software product is stored in a storage medium, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and the like, and the storage medium can store program codes, and includes instructions for enabling a computer terminal (which may be a personal computer, a server, or a second terminal, a network terminal, and the like) to perform all or part of the steps of the method in the embodiments of the present invention.

The same and similar parts in the various embodiments in this specification may be referred to each other. Especially, for the terminal embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant points can be referred to the description in the method embodiment.

In the embodiments provided in the present invention, it should be understood that the disclosed system and method can be implemented in other ways. For example, the above-described system embodiments are merely illustrative, and for example, the division of the units is only one logical functional division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, systems or units, and may be in an electrical, mechanical or other form.

The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.

In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.

Although the present invention has been described in detail by referring to the drawings in connection with the preferred embodiments, the present invention is not limited thereto. Various equivalent modifications or substitutions can be made on the embodiments of the present invention by those skilled in the art without departing from the spirit and scope of the present invention, and these modifications or substitutions are within the scope of the present invention/any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

11页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:休眠唤醒装置及电子设备

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!