A power calibration method and device, electronic equipment and storage medium

By obtaining the battery terminal voltage threshold and charge percentage, calculating the coefficient of the linear formula, and combining it with the voltage detection of the coulomb meter for charge calibration, the problem of inaccurate battery charge display is solved, and the accuracy of charge detection and user experience are improved.

CN120820862BActive Publication Date: 2025-11-18XIAMEN UNISOC TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511316821.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-09-16
Publication Date
2025-11-18
Estimated Expiration
2045-09-16

AI Technical Summary

Technical Problem

Inaccurate battery level display can prevent users from accurately estimating how long their phone will last, potentially causing the phone to shut down prematurely and negatively impacting the user experience.

Method used

By obtaining the percentage of charge and voltage of the target device when it discharges to the battery terminal voltage threshold, the coefficients of the linear formula are calculated. Combined with the current battery terminal voltage, the charge is calibrated. The voltage is detected by a coulomb meter and a weighted sum is performed to correct the charge detection result.

Benefits of technology

It improves the accuracy of battery detection, ensuring more precise battery level display, preventing premature phone shutdown, and enhancing the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120820862B_ABST
    Figure CN120820862B_ABST
Patent Text Reader

Abstract

Embodiments of the present application provide a power calibration method and device, electronic equipment and storage medium, the method comprises: obtaining the power percentage when the target device discharges to the battery end voltage threshold, taking the power percentage as the calibration starting power, and obtaining the first time battery end voltage; obtaining the preset cutoff voltage corresponding to 0 power of the target device; according to the calibration starting power and the starting voltage, 0 power and the cutoff voltage, the coefficient of the linear formula of the preset power and voltage is solved, and the target coefficient is obtained; the second time battery power is calculated; the current power of the target device is obtained; the first difference between the first time battery end voltage and the cutoff voltage is calculated, and the ratio of the second difference between the current battery end voltage and the cutoff voltage is calculated; by calculating the ratio, the second time battery power and the current power are weighted and summed to obtain the calibrated power, which can improve the accuracy of power detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of electrical charge detection technology, and in particular to an electrical charge calibration method, apparatus, electronic device, and storage medium. Background Technology

[0002] The accuracy of battery level displays is always a major concern for end users, especially mobile phone users. Inaccurate battery levels prevent users from accurately estimating how long the phone will last, causing it to run out of power and shut down unexpectedly. Inaccurate battery levels can also cause the battery's shutdown voltage to drop, potentially leading to the system operating for extended periods in unexpectedly low-performance or unsafe low-voltage ranges. Furthermore, inaccurate battery levels can cause the phone to prematurely report 0% battery level and shut down, impacting the user's overall phone usage time. Summary of the Invention

[0003] The purpose of this application is to provide a power calibration method, apparatus, electronic device, and storage medium to improve the accuracy of power detection. The specific technical solution is as follows:

[0004] A first aspect of this application provides a power calibration method, the method comprising:

[0005] Obtain the percentage of battery charge when the target device discharges to the battery terminal voltage threshold, use this percentage as the calibration starting charge, and obtain the battery terminal voltage at the first moment, use this first moment as the starting voltage.

[0006] Obtain the preset cutoff voltage corresponding to 0 battery level of the target device;

[0007] Based on the calibration start charge and start voltage, the 0 charge and the cutoff voltage, the coefficients of the linear formula for the preset charge and voltage are solved to obtain the target coefficients;

[0008] Obtain the current battery terminal voltage of the target device; calculate the battery charge at the second moment based on the target coefficient, the linear formula, and the current battery terminal voltage;

[0009] Obtain the current battery level of the target device; calculate the first difference between the battery terminal voltage and the cutoff voltage at the first moment, and the second difference between the battery terminal voltage and the cutoff voltage at the current moment, and calculate the ratio of the first difference to the second difference; then perform a weighted summation of the battery level at the second moment and the battery level at the current moment to obtain the calibrated battery level.

[0010] In one possible implementation, obtaining the current battery terminal voltage of the target device includes:

[0011] The average value and battery terminal voltage of the target device are periodically acquired.

[0012] If, within a continuously preset number of detection cycles, the average value of the battery terminal voltage is less than the battery terminal voltage threshold, and the battery terminal voltage at the current moment is less than the battery terminal voltage threshold, the battery terminal voltage of the target device at the current moment is obtained.

[0013] In one possible implementation, after obtaining the battery terminal voltage of the target device at the current moment, the method further includes:

[0014] If the average value of the battery terminal voltage is greater than the battery terminal voltage threshold plus the preset delay value, and the battery terminal voltage at the current moment is greater than the battery terminal voltage threshold plus the preset delay value, then the calibration is exited.

[0015] In one possible implementation, after calculating the weighted sum of the battery charge at the second moment and the battery charge at the current moment using the calculated ratio to obtain the calibrated battery charge, the method further includes:

[0016] Obtain at least one of the following: average battery terminal voltage after calibration, battery temperature change information, and battery charge at the third time point;

[0017] If the average battery terminal voltage after calibration is greater than the initial voltage plus the preset voltage value, or the battery temperature change is greater than the preset temperature value, or the battery charge at the third moment is greater than the initial charge plus the preset charge value, then return to the step of obtaining the battery terminal voltage and the charge at the current moment of the target device, and recalculate the charge.

[0018] In one possible implementation, obtaining the current battery terminal voltage of the target device includes:

[0019] The current battery voltage of the target device is obtained by measuring the coulomb voltage.

[0020] A second aspect of this application provides a power calibration device, the device comprising:

[0021] The power acquisition module is used to acquire the percentage of power when the target device discharges to the battery terminal voltage threshold, and uses this percentage of power as the calibration starting power, and acquires the battery terminal voltage at the first moment, and uses this first moment of battery terminal voltage as the starting voltage;

[0022] The power setting module is used to obtain the preset cutoff voltage corresponding to 0 power of the target device;

[0023] The coefficient determination module is used to solve the coefficients of a pre-set linear formula for the energy and voltage based on the calibration start energy and start voltage, the 0 energy and the cutoff voltage, to obtain the target coefficients.

[0024] The power calculation module is used to obtain the battery terminal voltage of the target device at the current moment; and calculate the battery power at the second moment based on the target coefficient, the linear formula and the battery terminal voltage at the current moment.

[0025] The power calibration module is used to obtain the current power level of the target device; calculate the first difference between the battery terminal voltage and the cutoff voltage at the first moment, and the second difference between the battery terminal voltage and the cutoff voltage at the current moment, and calculate the ratio of the first difference and the second difference; and use the calculated ratio to perform a weighted summation of the battery power level at the second moment and the power level at the current moment to obtain the calibrated power level.

[0026] In one possible implementation, the power calibration module is specifically used to periodically acquire the average value and battery terminal voltage of the target device; within a consecutive preset number of detection cycles, if the average value of the battery terminal voltage is less than the battery terminal voltage threshold, and the battery terminal voltage at the current moment is less than the battery terminal voltage threshold, the battery terminal voltage of the target device at the current moment is acquired.

[0027] In one possible implementation, the device further includes:

[0028] The calibration exit module is used to exit calibration if the average value of the battery terminal voltage is greater than the battery terminal voltage threshold plus a preset delay value, and the current battery terminal voltage is greater than the battery terminal voltage threshold plus the preset delay value.

[0029] In one possible implementation, the device further includes:

[0030] The recalculation module is used to obtain at least one of the following: the calibrated average battery terminal voltage, battery temperature change information, and battery charge at the third moment. If the calibrated average battery terminal voltage is greater than the starting voltage plus the preset voltage value, or the battery temperature change is greater than the preset temperature value, or the battery charge at the third moment is greater than the calibration starting charge plus the preset charge value, then the step of obtaining the battery terminal voltage and the charge at the current moment of the target device is returned, and the charge is recalculated.

[0031] In one possible implementation, the power calibration module is specifically used to detect the current battery terminal voltage of the target device using a coulomb counter.

[0032] Another aspect of the embodiments of this application also provides an electronic device, including:

[0033] Memory, used to store computer programs;

[0034] The processor, when executing a program stored in memory, implements any of the above-mentioned power calibration methods.

[0035] In another aspect of the embodiments of this application, a computer-readable storage medium is provided, which stores a computer program that, when executed by a processor, implements any of the above-described power calibration methods.

[0036] In another aspect of the embodiments of this application, a computer program product containing instructions is also provided, which, when run on a computer, causes the computer to perform any of the above-described power calibration methods.

[0037] Beneficial effects of the embodiments in this application:

[0038] This application provides a power calibration method, apparatus, electronic device, and storage medium. The method includes: obtaining the percentage of battery charge when a target device discharges to a battery terminal voltage threshold, using this percentage as the calibration starting charge, and obtaining the battery terminal voltage at a first moment, using this first moment's battery terminal voltage as the starting voltage; obtaining a pre-set cutoff voltage corresponding to 0% battery charge of the target device; solving a linear formula for the pre-set charge and voltage based on the calibration starting charge, the starting voltage, the 0% battery charge, and the cutoff voltage to obtain target coefficients; obtaining the current battery terminal voltage of the target device; calculating the battery charge at a second moment based on the target coefficients, the linear formula, and the current moment's battery terminal voltage; obtaining the current battery charge of the target device; calculating a first difference between the first moment's battery terminal voltage and the cutoff voltage, and a second difference between the current moment's battery terminal voltage and the cutoff voltage, and calculating the ratio of the first difference to the second difference; and using the calculated ratio to perform a weighted summation of the battery charge at the second moment and the current moment's battery charge to obtain the calibrated charge. The solution proposed in this application allows for the acquisition of the target device's current battery terminal voltage and current power level information via a coulomb counter. The battery power level at a second moment is then used to correct the readings based on the linear relationship between power level and voltage, thereby improving the accuracy of power level detection.

[0039] Of course, implementing any product or method of this application does not necessarily require achieving all of the advantages described above at the same time. Attached Figure Description

[0040] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other embodiments can be obtained based on these drawings.

[0041] Figure 1a This is a schematic flowchart of a power calibration method provided in an embodiment of this application;

[0042] Figure 1b A comparison diagram illustrating the effects of the power calibration method provided in this application embodiment;

[0043] Figure 2 A schematic diagram of the power calibration device provided in the embodiments of this application;

[0044] Figure 3 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0045] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art based on this application are within the scope of protection of this application.

[0046] A first aspect of the embodiments of this application provides a power calibration method, see [link to previous document]. Figure 1a The method includes:

[0047] Step S11: Obtain the percentage of battery charge when the target device discharges to the battery terminal voltage threshold, use this percentage of battery charge as the calibration starting charge, and obtain the battery terminal voltage at the first moment, use this first moment of battery terminal voltage as the starting voltage.

[0048] Step S12: Obtain the preset cutoff voltage of the target device corresponding to 0 battery level;

[0049] Step S13: Based on the calibration start charge and start voltage, the 0 charge and cutoff voltage, solve the coefficients of the preset linear formula for charge and voltage to obtain the target coefficients;

[0050] Step S14: Obtain the battery terminal voltage of the target device at the current moment; calculate the battery charge at the second moment based on the target coefficient, the linear formula, and the battery terminal voltage at the current moment.

[0051] Step S15: Obtain the current battery level of the target device; calculate the first difference between the battery terminal voltage and the cutoff voltage at the first moment, and the second difference between the battery terminal voltage and the cutoff voltage at the current moment, and calculate the ratio of the first difference to the second difference; use the calculated ratio to perform a weighted summation of the battery level at the second moment and the battery level at the current moment to obtain the calibrated battery level.

[0052] Corresponding to step S11, the percentage of charge and the battery terminal voltage at the first moment when the target device discharges to the battery terminal voltage threshold are obtained. When obtaining the initial charge and voltage for calibration, the battery terminal voltage threshold can be preset. In one example, the battery terminal voltage threshold can be as follows:

[0053] Table 1 shows the values ​​for the battery terminal voltage threshold.

[0054]

[0055] As shown in the table above, corresponding battery terminal voltage thresholds (VTH) can be set for different battery temperatures. This allows for periodic detection of the target device's voltage information, recording the percentage of charge (BATT_SOC) and the battery terminal voltage at the first moment (VBAT_NOW1) when the target device discharges to the aforementioned battery terminal voltage threshold, thus obtaining the calibration starting charge (BATT_SOC_E) and starting voltage (VBAT_E). The aforementioned first moment refers to the detection time when the target device discharges to the aforementioned battery terminal voltage threshold.

[0056] In step S12, when obtaining the preset cutoff voltage corresponding to 0 battery power of the target device, the cutoff voltage (Vzp) can be preset. In one example, the cutoff voltages are shown in the table below:

[0057] Table 2 shows the values ​​of the discharge cutoff voltage.

[0058]

[0059] As shown in the table above, the corresponding cutoff voltage can be set for different battery temperatures.

[0060] Corresponding to step S13, based on the calibration start power and start voltage, the 0 power and the cutoff voltage, the coefficients of the pre-set linear formula for power and voltage are solved to obtain the target coefficients. The equations composed of the calibration start power and start voltage, and the equations composed of the 0 power and the cutoff voltage, can be combined to solve for the coefficients of the linear formula for power and voltage. For example, K and B can be calculated using the linear formula Y=KX+B and two sets of data [BATT_SOC,VABT]: two sets of data are [0%,Vzp] (reporting 0%) and the shutdown voltage and [BATT_SOC_E,VBAT_E], to obtain the coefficients of the linear formula. Here, K represents the slope, B represents the intercept, Y represents the power, and X represents the voltage.

[0061] In step S14, when calculating the battery charge at the second moment based on the target coefficient, the linear formula, and the battery terminal voltage at the current moment, the battery charge at the second moment can be calculated by substituting the current battery terminal voltage into the linear formula based on the coefficient calculated in the previous step.

[0062] Corresponding to step S15, the current battery level of the target device is obtained. This can be done when the target device meets the calibration conditions. In one possible implementation, obtaining the current battery terminal voltage of the target device includes: detecting the current battery terminal voltage of the target device using a coulomb counter. When calculating the first difference between the battery terminal voltage at the first moment and the cutoff voltage, and the second difference between the battery terminal voltage at the current moment and the cutoff voltage, and calculating the ratio of the first difference to the second difference, the difference between the battery terminal voltage at the first moment and the cutoff voltage, and the difference between the battery terminal voltage at the current moment and the cutoff voltage, can be calculated first, and then divided to obtain the ratio. Finally, the calculated ratio is used to perform a weighted summation of the battery level at the second moment and the current battery level to obtain the calibrated battery level.

[0063] As can be seen, the solution of this application can be used to obtain the battery terminal voltage and the current power information of the target device at the current moment through the coulomb counter, and then correct it by combining the battery power at the second moment with the linear relationship between power and voltage. That is, the power result calculated by the power meter (i.e., the power at the current moment) is corrected by combining the linear relationship between power and voltage, thereby improving the accuracy of power detection.

[0064] In one possible implementation, obtaining the current battery terminal voltage of the target device includes: periodically obtaining the average value and the current battery terminal voltage of the target device; and, within a consecutive preset number of detection cycles, if the average battery terminal voltage (VBAT_AVG) < a battery terminal voltage threshold (VTH), and the current battery terminal voltage (VBAT_NOW) < the battery terminal voltage threshold (VTH), then obtaining the current battery terminal voltage of the target device. Specifically, the condition for entering zero-voltage prediction can be: several consecutive cycles of VBAT_AVG... <VTH&VBAT_NOW<VTH。

[0065] In one possible implementation, after obtaining the current battery terminal voltage of the target device, the method further includes: exiting calibration if the average value of the battery terminal voltage (VBAT_AVG) > the battery terminal voltage threshold (VTH) + a preset delay value (delat_v), and the current battery terminal voltage (BAT_NOW) > the battery terminal voltage threshold (VTH) + the preset delay value (delat_v). Specifically, the condition for exiting zero-voltage prediction can be: VBAT_AVG > VTH + delat_v & BAT_NOW > VTH + delat_v.

[0066] In one possible implementation, after calculating the weighted sum of the battery capacity at the second moment and the current moment using the calculated ratio to obtain the calibrated battery capacity, the method further includes: acquiring at least one of the calibrated average battery terminal voltage (VBAT_AVG), battery temperature change information (BATT_TEMP), and battery capacity at the third moment (batt_soc); if the calibrated average battery terminal voltage > the initial voltage + a preset voltage value, or the battery temperature change > a preset temperature value, or the battery capacity at the third moment > the calibration initial capacity + a preset capacity value, then the method returns to the step of acquiring the battery terminal voltage and the current capacity of the target device at the current moment, and recalculates the battery capacity. Specifically, when the preset voltage value is 10mV, the preset temperature value is 5 degrees, and the preset power value is 5% (corresponding to BATT_SOC_E+0.5% below), the power of the target device can be calibrated. When VBAT_AVG>VBAT_E+10mV, or BATT_TEMP changes by more than 5 degrees, or batt_soc is greater than BATT_SOC_E+0.5%, the power can be recalibrated.

[0067] To illustrate the method of the embodiments of this application, the following description is provided in conjunction with a specific embodiment, including:

[0068] 1. Record the BATT_SOC (calibration starting charge) when discharging to VTH as BATT_SOC_E, and VBAT_NOW1 as VBAT_E (starting voltage).

[0069] 2. Calculate K and B using the linear formula Y=KX+B and two sets of data [BATT_SOC,VABT]: the two sets of data are [0%,Vzp] reporting 0% and the shutdown voltage and [BATT_SOC_E, VBAT_E];

[0070] 0 = Vzp * K + B;

[0071] BATT_SOC_E = VBAT_E * K + B;

[0072] The calculation can be obtained: K=BATT_SOC_E / (VBAT_E-Vzp), B=-K*Vzp=BATT_SOC_E*Vzp / (Vzp-VBAT_E);

[0073] Substitute VBAT_NOW into Y = KX + B to calculate Vbat_soc;

[0074] VBAT_SOC = K * VBAT_NOW2 + B.

[0075] 3. Calculate Weight; Weight = (VBAT_NOW2 – VZP) / (VBAT_E – VZP).

[0076] 4. Calculate the final calibration charge; Cali_soc = vbat soc* (1 – weight) + batt_soc *weight.

[0077] 5. Recalculate the K / B conditions: VBAT_AVG > VBAT_E + 10mV, or BATT_TEMP changes by more than 5 degrees, or batt_soc is greater than BATT_SOC_E + 0.5%.

[0078] See Figure 1b During the testing of the proposed solution, after artificially introducing a 5% error, the battery level began to calibrate when the discharge voltage (VBAT) was below VTH. The error gradually decreased from 5% until it reached the cutoff voltage (Vzp), at which point the error also decreased to 0%, resulting in a 0% battery reading and a discharge voltage of approximately 3.4V. The battery level display was smooth, demonstrating the significant superiority of the proposed solution. In contrast, the control group without a calibration scheme still exhibited a 5% error at the BATT_SOC discharge cutoff, causing mobile phones and other electronic devices to shut down before reaching 0% battery, thus affecting device operation.

[0079] A second aspect of this application provides a power calibration device, see [link to previous document]. Figure 2 The device includes:

[0080] The power acquisition module 201 is used to acquire the percentage of power when the target device discharges to the battery terminal voltage threshold, use the percentage of power as the calibration start power, and acquire the battery terminal voltage at the first moment, use the battery terminal voltage at the first moment as the start voltage.

[0081] The power setting module 202 is used to obtain the preset cutoff voltage corresponding to 0 power of the target device;

[0082] The coefficient determination module 203 is used to solve the coefficients of a pre-set linear formula for the energy and voltage based on the calibration start energy and start voltage, the 0 energy and the cutoff voltage, to obtain the target coefficients.

[0083] The power calculation module 204 is used to obtain the battery terminal voltage of the target device at the current moment; and calculate the battery power at the second moment based on the target coefficient, the linear formula and the battery terminal voltage at the current moment.

[0084] The power calibration module 205 is used to obtain the current power level of the target device; calculate the first difference between the battery terminal voltage and the cutoff voltage at the first moment, and the second difference between the battery terminal voltage and the cutoff voltage at the current moment, and calculate the ratio of the first difference and the second difference; and use the calculated ratio to perform a weighted summation of the battery power level at the second moment and the power level at the current moment to obtain the calibrated power level.

[0085] In one possible implementation, the power calibration module is specifically used to periodically acquire the average value and battery terminal voltage of the target device; within a consecutive preset number of detection cycles, if the average value of the battery terminal voltage is less than the battery terminal voltage threshold, and the battery terminal voltage at the current moment is less than the battery terminal voltage threshold, the battery terminal voltage of the target device at the current moment is acquired.

[0086] In one possible implementation, the device further includes:

[0087] The calibration exit module is used to exit calibration if the average value of the battery terminal voltage is greater than the battery terminal voltage threshold plus a preset delay value, and the current battery terminal voltage is greater than the battery terminal voltage threshold plus the preset delay value.

[0088] In one possible implementation, the device further includes:

[0089] The recalculation module is used to obtain at least one of the following: the calibrated average battery terminal voltage, battery temperature change information, and battery charge at the third moment. If the calibrated average battery terminal voltage is greater than the starting voltage plus the preset voltage value, or the battery temperature change is greater than the preset temperature value, or the battery charge at the third moment is greater than the calibration starting charge plus the preset charge value, then the step of obtaining the battery terminal voltage and the charge at the current moment of the target device is returned, and the charge is recalculated.

[0090] In one possible implementation, the power calibration module is specifically used to detect the current battery terminal voltage of the target device using a coulomb counter.

[0091] As can be seen, the device of this application can improve the accuracy of power detection by obtaining the battery terminal voltage and power information of the target device at the current moment through the coulomb counter and then correcting it by combining the battery power at the second moment with the linear relationship between power and voltage.

[0092] This application also provides an electronic device, such as... Figure 3 As shown, it includes:

[0093] Memory 301 is used to store computer programs;

[0094] When processor 302 executes a program stored in memory 301, it performs the following steps:

[0095] The percentage of charge and the battery terminal voltage at the first moment when the target device discharges to the battery terminal voltage threshold are obtained to obtain the calibration start charge and start voltage.

[0096] Obtain the preset cutoff voltage corresponding to 0 battery level of the target device;

[0097] Based on the calibration start charge and start voltage, the 0 charge and the cutoff voltage, the coefficients of the linear formula for the preset charge and voltage are solved to obtain the target coefficients;

[0098] Obtain the current battery terminal voltage of the target device, and calculate the battery capacity at the second moment based on the target coefficient, the linear formula, and the current battery terminal voltage;

[0099] Obtain the current battery level of the target device; calculate the first difference between the battery terminal voltage and the cutoff voltage at the first moment, and the second difference between the battery terminal voltage and the cutoff voltage at the current moment, and calculate the ratio of the first difference to the second difference; use the calculated ratio to perform a weighted summation of the battery level at the second moment and the battery level at the current moment to obtain the calibrated battery level.

[0100] The communication bus mentioned in the above electronic devices can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. This communication bus can be divided into address bus, data bus, control bus, etc. For ease of illustration, only one thick line is used to represent it in the diagram, but this does not mean that there is only one bus or one type of bus.

[0101] The communication interface is used for communication between the aforementioned electronic devices and other devices.

[0102] The memory may include random access memory (RAM) or non-volatile memory (NVM), such as at least one disk storage device. Optionally, the memory may also be at least one storage device located remotely from the aforementioned processor.

[0103] The processors mentioned above can be general-purpose processors, including central processing units (CPUs), network processors (NPs), etc.; they can also be digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.

[0104] In another embodiment provided in this application, a computer-readable storage medium is also provided, which stores a computer program that, when executed by a processor, implements the steps of any of the above-described power calibration methods.

[0105] In another embodiment provided in this application, a computer program product containing instructions is also provided, which, when run on a computer, causes the computer to perform any of the power calibration methods described above.

[0106] In the above embodiments, implementation can be achieved entirely or partially through software, hardware, firmware, or any combination thereof. When implemented using software, it can be implemented entirely or partially in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that integrates one or more available media. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., DVD), or a solid-state drive (SSD), etc.

[0107] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0108] The various embodiments in this specification are described in a related manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on its differences from other embodiments. In particular, the embodiments for apparatus, electronic devices, and storage media are basically similar to the method embodiments, so the descriptions are relatively simple; relevant parts can be referred to the descriptions of the method embodiments.

[0109] The above description is merely a preferred embodiment of this application and is not intended to limit the scope of protection of this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application are included within the scope of protection of this application.

Claims

1. A power calibration method, characterized in that, The method includes: Obtain the percentage of battery charge when the target device discharges to the battery terminal voltage threshold, use this percentage as the calibration starting charge, and obtain the battery terminal voltage at the first moment, use this first moment as the starting voltage. Obtain the preset cutoff voltage corresponding to 0 battery level of the target device; Based on the calibration start charge and start voltage, the 0 charge and the cutoff voltage, the coefficients of the linear formula for the preset charge and voltage are solved to obtain the target coefficients; Obtain the current battery terminal voltage of the target device; calculate the battery charge at the second moment based on the target coefficient, the linear formula, and the current battery terminal voltage; Obtain the current battery level of the target device; calculate the first difference between the battery terminal voltage and the cutoff voltage at the first moment, and the second difference between the battery terminal voltage and the cutoff voltage at the current moment, and calculate the ratio of the first difference to the second difference; use the calculated ratio to perform a weighted summation of the battery level at the second moment and the current battery level to obtain the calibrated battery level; wherein, calculating the first difference between the battery terminal voltage and the cutoff voltage at the first moment, and the second difference between the battery terminal voltage and the cutoff voltage at the current moment, and calculating the ratio of the first difference to the second difference includes: calculating the ratio of the first difference to the second difference using the formula: Weight = (VBAT_NOW2 – VZP) / (VBAT_E – VZP); the weighted summation of the calculated ratio between the battery level at the second moment and the current battery level to obtain the calibrated battery level includes: using the formula: Cali_soc = vbat soc* (1 – weight) + batt_soc * The weight is used to calculate the final calibrated battery level; Weight represents the ratio of the first difference to the second difference; VBAT_NOW2 represents the current battery terminal voltage; VZP represents the cutoff voltage; VBAT_E represents the battery terminal voltage at the first moment; Cali_soc represents the calibrated battery level; vbatsoc represents the current battery level; and batt_soc represents the battery level at the second moment.

2. The method according to claim 1, characterized in that, The step of obtaining the current battery terminal voltage of the target device includes: The average value and battery terminal voltage of the target device are periodically acquired. If, within a continuously preset number of detection cycles, the average value of the battery terminal voltage is less than the battery terminal voltage threshold, and the battery terminal voltage at the current moment is less than the battery terminal voltage threshold, the battery terminal voltage of the target device at the current moment is obtained.

3. The method according to claim 2, characterized in that, After obtaining the current battery terminal voltage of the target device, the method further includes: If the average value of the battery terminal voltage is greater than the battery terminal voltage threshold plus the preset delay value, and the battery terminal voltage at the current moment is greater than the battery terminal voltage threshold plus the preset delay value, then the calibration is exited.

4. The method according to claim 2, characterized in that, After calculating the calculated ratio, the method further includes weighted summation of the battery charge at the second moment and the battery charge at the current moment to obtain the calibrated battery charge. Obtain at least one of the following: average battery terminal voltage after calibration, battery temperature change information, and battery charge at the third time point; If the average battery terminal voltage after calibration is greater than the initial voltage plus the preset voltage value, or the battery temperature change is greater than the preset temperature value, or the battery charge at the third moment is greater than the initial charge plus the preset charge value, then return to the step of obtaining the battery terminal voltage and the charge at the current moment of the target device, and recalculate the charge.

5. The method according to claim 1, characterized in that, The step of obtaining the current battery terminal voltage of the target device includes: The current battery voltage of the target device is obtained by measuring the coulomb voltage.

6. A power calibration device, characterized in that, The device includes: The power acquisition module is used to acquire the percentage of power when the target device discharges to the battery terminal voltage threshold, and uses this percentage of power as the calibration starting power, and acquires the battery terminal voltage at the first moment, and uses this first moment of battery terminal voltage as the starting voltage; The power setting module is used to obtain the preset cutoff voltage corresponding to 0 power of the target device; The coefficient determination module is used to solve the coefficients of a pre-set linear formula for the energy and voltage based on the calibration start energy and start voltage, the 0 energy and the cutoff voltage, to obtain the target coefficients. The power calculation module is used to obtain the battery terminal voltage of the target device at the current moment; and calculate the battery power at the second moment based on the target coefficient, the linear formula and the battery terminal voltage at the current moment. A power calibration module is used to obtain the current power level of the target device; calculate a first difference between the battery terminal voltage and the cutoff voltage at the first moment, and a second difference between the battery terminal voltage and the cutoff voltage at the current moment, and calculate the ratio of the first difference to the second difference; and use the calculated ratio to perform a weighted summation of the battery power at the second moment and the current power level to obtain the calibrated power level; wherein, calculating the first difference between the battery terminal voltage and the cutoff voltage at the first moment, and the second difference between the battery terminal voltage and the cutoff voltage at the current moment, and calculating the ratio of the first difference to the second difference includes: calculating the ratio of the first difference to the second difference using the formula: Weight = (VBAT_NOW2 – VZP) / (VBAT_E – VZP); and using the calculated ratio to perform a weighted summation of the battery power at the second moment and the current power level to obtain the calibrated power level includes: using the formula: Cali_soc = vbat soc* (1 – weight) + batt_soc * The weight is used to calculate the final calibrated battery level; Weight represents the ratio of the first difference to the second difference; VBAT_NOW2 represents the current battery voltage; VZP represents the cutoff voltage; VBAT_E represents the battery voltage at the first moment; Cali_soc represents the calibrated battery level; vbat soc represents the current battery level; and batt_soc represents the battery level at the second moment.

7. The apparatus according to claim 6, characterized in that, The power calibration module is specifically used to periodically acquire the average value and battery terminal voltage of the target device; within a consecutive preset number of detection cycles, if the average value of the battery terminal voltage is less than the battery terminal voltage threshold, and the battery terminal voltage at the current moment is less than the battery terminal voltage threshold, the battery terminal voltage of the target device at the current moment is acquired.

8. The apparatus according to claim 7, characterized in that, The device further includes: The calibration exit module is used to exit calibration if the average value of the battery terminal voltage is greater than the battery terminal voltage threshold plus a preset delay value, and the current battery terminal voltage is greater than the battery terminal voltage threshold plus the preset delay value.

9. An electronic device, characterized in that, include: Memory, used to store computer programs; A processor, when executing a program stored in memory, implements the method described in any one of claims 1-5.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium contains a computer program that, when executed by a processor, implements the method described in any one of claims 1-5.

Citation Information

Patent Citations

  • Method and system for accurately reporting battery capacity

    CN101526588A

  • Apparatus and method for estimating state of health of battery based on battery voltage variation pattern

    CN102119338A