CN114325416A - Battery electric quantity detection method and device, storage medium and electronic equipment - Google Patents

Battery electric quantity detection method and device, storage medium and electronic equipment Download PDF

Info

Publication number
CN114325416A
CN114325416A CN202011035891.6A CN202011035891A CN114325416A CN 114325416 A CN114325416 A CN 114325416A CN 202011035891 A CN202011035891 A CN 202011035891A CN 114325416 A CN114325416 A CN 114325416A
Authority
CN
China
Prior art keywords
data
battery
electrical
sampling
electric quantity
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.)
Pending
Application number
CN202011035891.6A
Other languages
Chinese (zh)
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.)
BYD Semiconductor Co Ltd
Original Assignee
BYD Semiconductor Co 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 BYD Semiconductor Co Ltd filed Critical BYD Semiconductor Co Ltd
Priority to CN202011035891.6A priority Critical patent/CN114325416A/en
Publication of CN114325416A publication Critical patent/CN114325416A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Charge And Discharge Circuits For Batteries Or The Like (AREA)
  • Secondary Cells (AREA)

Abstract

The disclosure relates to a battery power detection method, a battery power detection device, a storage medium and an electronic device, so as to improve the performance of battery power detection. The method comprises the following steps: acquiring initial electric quantity of a battery and a sampling period for sampling a target electric parameter; determining first electrical data according to the initial electrical quantity and the sampling period, wherein the first electrical data is used for representing the sum of data acquired by sampling the target electrical parameter in the process that the electrical quantity of the battery is changed from the initial electrical quantity to zero according to the sampling period; acquiring second electrical data of a target sampling moment, wherein the second electrical data is used for representing the sum of data actually acquired by sampling the target electrical parameter at each time when the target sampling moment is reached; and if the electric quantity prompting equipment is not in a working state, determining the electric quantity condition of the battery at the target sampling moment according to the difference value of the first electric data and the second electric data.

Description

Battery electric quantity detection method and device, storage medium and electronic equipment
Technical Field
The present disclosure relates to the field of electronic technologies, and in particular, to a method and an apparatus for detecting battery power, a storage medium, and an electronic device.
Background
Currently, a relatively typical current integration method is generally used for detecting the battery level. In the current integration method, an ADC (Analog-to-Digital Converter) is generally used to collect the battery current in real time, and a single chip microcomputer is used to perform integral summation of the current, so as to calculate the current consumed by current accumulation, and simultaneously display the remaining power on a corresponding display interface in real time for relevant personnel to view. In this way, after the battery current is collected in real time by the ADC, the integral summation operation is performed in the single chip microcomputer, and the remaining power can be obtained in real time only by frequently performing multiplication and addition operations, which results in occupation of operation resources of the single chip microcomputer, limited function development, and insufficient performance utilization efficiency.
Disclosure of Invention
The present disclosure provides a battery power detection method, device, storage medium and electronic device, so as to improve the performance of battery power detection.
In order to achieve the above object, according to a first aspect of the present disclosure, there is provided a battery charge amount detection method, the method including:
acquiring initial electric quantity of a battery and a sampling period for sampling a target electric parameter;
determining first electrical data according to the initial electrical quantity and the sampling period, wherein the first electrical data is used for representing the sum of data acquired by sampling the target electrical parameter in the process that the electrical quantity of the battery is changed from the initial electrical quantity to zero according to the sampling period;
acquiring second electrical data of a target sampling moment, wherein the second electrical data is used for representing the sum of data actually acquired by sampling the target electrical parameter at each time when the target sampling moment is reached;
and if the electric quantity prompting equipment is not in a working state, determining the electric quantity condition of the battery at the target sampling moment according to the difference value of the first electric data and the second electric data.
Optionally, the determining first electrical data according to the initial electrical quantity and the sampling period includes:
determining a ratio of the initial charge to the sampling period as the first electrical data.
Optionally, if the electric quantity prompting device is not in a working state, determining the electric quantity condition of the battery at the target sampling time according to a difference value between the first electrical data and the second electrical data, including:
determining a difference value obtained by subtracting the second electrical data from the first electrical data;
if the difference value is larger than a preset threshold value, determining that the electric quantity condition of the battery is sufficient;
and if the difference is smaller than or equal to the preset threshold, determining that the electric quantity condition of the battery is insufficient.
Optionally, the method further comprises:
and if the situation that the electric quantity of the battery is insufficient is determined, generating and outputting prompt information for indicating that the electric quantity of the battery is insufficient.
Optionally, the method further comprises:
if the electric quantity prompting equipment is in the working state, determining a state of charge (SOC) value and/or a residual electric quantity of the battery at the target sampling moment according to the first electric data and the second electric data;
and outputting the SOC value and/or the residual electric quantity through the electric quantity prompting equipment.
Optionally, the state of charge SOC value of the battery at the target sampling time is determined by the following equation (1):
Figure BDA0002705073810000021
wherein C is the first electrical data and D is the second electrical data.
Optionally, the remaining capacity E of the battery at the target sampling time is determined by the following formula (2):
E=(C-D)*B (2)
wherein C is the first electrical data, D is the second electrical data, and B is the sampling period.
According to a second aspect of the present disclosure, there is provided a battery charge level detecting apparatus, the apparatus comprising:
the first acquisition module is used for acquiring the initial electric quantity of the battery and the sampling period of the target electric parameter;
the first determining module is used for determining first electrical data according to the initial electrical quantity and the sampling period, wherein the first electrical data are used for representing the sum of data which are sampled according to the sampling period and are acquired by sampling the target electrical parameter each time when the battery electrical quantity is changed from the initial electrical quantity to zero;
the second acquisition module is used for acquiring second electrical data at a target sampling moment, wherein the second electrical data are used for representing the sum of data actually acquired by sampling the target electrical parameter at each time when the target sampling moment is reached;
and the second determining module is used for determining the electric quantity condition of the battery at the target sampling moment according to the difference value of the first electric data and the second electric data if the electric quantity prompting device is not in a working state.
Optionally, the first determining module is configured to determine a ratio of the initial power amount and the sampling period as the first electrical data.
Optionally, the second determining module includes:
a first determining submodule for determining a difference obtained by subtracting the second electrical data from the first electrical data;
the second determining submodule is used for determining that the electric quantity condition of the battery is sufficient if the difference value is larger than a preset threshold value;
and the third determining submodule is used for determining that the electric quantity condition of the battery is insufficient if the difference value is smaller than or equal to the preset threshold value.
Optionally, the apparatus further comprises:
and the first prompting module is used for generating and outputting prompting information for indicating that the electric quantity of the battery is insufficient if the electric quantity condition of the battery is determined to be insufficient.
Optionally, the apparatus further comprises:
the third determining module is used for determining the SOC value and/or the residual electric quantity of the battery at the target sampling moment according to the first electric data and the second electric data if the electric quantity prompting equipment is in the working state;
and the second prompting module is used for outputting the SOC value and/or the residual electric quantity through the electric quantity prompting equipment.
Optionally, the state of charge SOC value of the battery at the target sampling time is determined by the following equation (1):
Figure BDA0002705073810000041
wherein C is the first electrical data and D is the second electrical data.
Optionally, the remaining capacity E of the battery at the target sampling time is determined by the following formula (2):
E=(C-D)*B (2)
wherein C is the first electrical data, D is the second electrical data, and B is the sampling period.
According to a third aspect of the present disclosure, there is provided a computer readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the method of the first aspect of the present disclosure.
According to a fourth aspect of the present disclosure, there is provided an electronic device comprising:
a memory having a computer program stored thereon;
a processor for executing the computer program in the memory to implement the steps of the method of the first aspect of the disclosure.
According to the technical scheme, the initial electric quantity of the battery and the sampling period of the target electric parameter are obtained, the first electric data which are used for representing the sum of data which are sampled according to the sampling period and are obtained in the process that the electric quantity of the battery is changed from the initial electric quantity to zero and are obtained in each sampling process of the target electric parameter are determined according to the initial electric quantity and the sampling period, the second electric data which represent the sum of data which are actually obtained by the target electric parameter at the moment of sampling and are obtained in each sampling process are obtained, and if the electric quantity prompting device is not in a working state, the electric quantity condition of the battery at the target sampling moment is determined according to the difference value of the first electric data and the second electric data. Therefore, the time parameter in the electric quantity operation processing is eliminated by calculating the first electric data and the second electric data, so that the difference value of the first electric data and the second electric data can simply reflect the electric quantity condition of the battery, the electric quantity monitoring function is further realized, and the operation complexity is low. And when the electric quantity prompting equipment is not in a working state, the SOC value or the residual electric quantity cannot be calculated, electric quantity monitoring is only carried out through the difference value of the first electric data and the second electric data, complex multiplication and division operations are not needed, operation resources are saved, and equipment performance is saved.
Additional features and advantages of the disclosure will be set forth in the detailed description which follows.
Drawings
The accompanying drawings, which are included to provide a further understanding of the disclosure and are incorporated in and constitute a part of this specification, illustrate embodiments of the disclosure and together with the description serve to explain the disclosure without limiting the disclosure. In the drawings:
fig. 1 is a flow chart of a battery charge level detection method provided according to an embodiment of the present disclosure;
FIG. 2 is a flowchart illustrating an exemplary step of determining a power condition of a battery at a target sampling time according to a difference between first electrical data and second electrical data in a battery power detection method provided by the present disclosure;
fig. 3 is a flow chart of a battery charge level detection method provided in accordance with another embodiment of the present disclosure;
FIG. 4 is a block diagram of a battery charge level detection apparatus provided in accordance with one embodiment of the present disclosure;
FIG. 5 is a block diagram illustrating an electronic device in accordance with an example embodiment.
Detailed Description
The following detailed description of specific embodiments of the present disclosure is provided in connection with the accompanying drawings. It should be understood that the detailed description and specific examples, while indicating the present disclosure, are given by way of illustration and explanation only, not limitation.
Fig. 1 is a flowchart of a battery charge level detection method provided according to an embodiment of the present disclosure. As shown in fig. 1, the method may include the following steps.
In step 11, an initial charge of the battery and a sampling period for sampling the target electrical parameter are obtained.
Here, the initial charge of the battery refers to the charge of the battery at the initial stage of sampling, for example, the charge detection of the battery is started at time T, and then the initial charge of the battery is the actual charge of the battery at time T. There are various methods for determining the initial charge of the battery. For example, when determining the initial power amount of the current sampling, since the battery is not used in the two sampling processes, the battery power amount at the end of the previous sampling may be used as the initial power amount. For another example, the initial power amount may be predicted according to a change of the battery power amount in the history sampling process (e.g., predicting through a trained model, predicting through a graph, etc.). For another example, the initial charge of the battery may be calculated in real time using an existing method of calculating the charge of the battery.
Therefore, based on the above, when detecting the electric quantity of the battery, the initial electric quantity of the battery is easily acquired.
The sampling period for sampling the target electrical parameter may be obtained directly by the sampling device. For example, if the target electrical parameter is sampled by the sampling device ADC when detecting the electrical quantity of the battery, the sampling period may be directly obtained from the sampling setting of the ADC, and the sampling period reflects the sampling time interval. Illustratively, the target electrical parameter may be current.
In step 12, first electrical data is determined based on the initial electrical quantity and the sampling period.
The first electrical data are used for representing the sum of data which are sampled according to a sampling period and are acquired by sampling the target electrical parameters in each time when the battery electric quantity is changed from the initial electrical quantity to zero. In a physical sense, the first electrical data may characterize the discharge rate of the battery, i.e. the discharge efficiency based on the sampling period, and the calculation of the first electrical data eliminates the influence of the time parameter, which may be used as reference data.
For example, a ratio of the initial electrical quantity and the sampling period may be determined as the first electrical data. The initial electric quantity can represent the total electric quantity of the battery which can supply power outwards at this time, the sampling period represents time, the ratio of the initial electric quantity to the sampling period can represent the data of the total electric quantity which can be scattered to each sampling moment, and the influence of time parameters can be eliminated. In addition, generally, the total amount divided by the time is equivalent to the efficiency, so that the discharge efficiency in the use process of the battery can be reflected by calculating the ratio of the initial electric quantity to the sampling period.
In step 13, second electrical data is acquired at a target sampling instant.
And the second electrical data is used for representing the sum of data actually acquired by sampling the target electrical parameter at each time when the target sampling time is reached.
The second electrical data are the data actually acquired by the sampling device before the target sampling instant, which belong to the actual data and likewise do not contain a time parameter for comparison with the first electrical data as reference data.
The target sampling time can be any sampling time, if the electric quantity of which sampling time needs to be detected, the sampling time can be used as the target sampling time, and in practical application, each sampling time can be used as the target sampling time in sequence, so that the effect of detecting the electric quantity of the battery in real time is achieved.
In step 14, if the power prompting device is not in the working state, the power condition of the battery at the target sampling time is determined according to the difference value between the first electrical data and the second electrical data.
The electric quantity prompting device is used for specifically prompting the electric quantity Of the battery and prompting the SOC (State Of Charge) value and/or the residual electric quantity Of the battery. The prompting modes of the power prompting device include, but are not limited to, the following: character display, image display, light prompt and audio play. For example, if the power prompting device is a display device and prompts in a text display manner, when the power prompting device is in an operating state, the SOC value and/or the remaining power of the battery may be displayed in text on a display screen of the power prompting device.
The power prompting device prompts the battery power status when the device is in an operating state (e.g., the device is awake), and cannot prompt the battery power status when the device is not in the operating state (e.g., the device is asleep).
Therefore, if the power prompting device is not in the working state, the power condition of the battery cannot be displayed, and even if the SOC value and the remaining power are calculated, the contents cannot be output through the power prompting device, so that in order to save calculation resources, the SOC value and/or the remaining power do not need to be calculated, and the power condition of the battery at the target sampling time can be determined only according to the difference value between the first electrical data and the second electrical data.
In one possible embodiment, step 14 may include the following steps, as shown in fig. 2:
in step 21, determining a difference value obtained by subtracting the second electrical data from the first electrical data;
in step 22, if the difference is greater than the preset threshold, determining that the electric quantity of the battery is sufficient;
in step 23, if the difference is smaller than or equal to the preset threshold, it is determined that the battery capacity is insufficient.
If the difference value obtained by subtracting the second electrical data from the first electrical data is larger than the preset threshold value, the fact that the actually used electric quantity of the battery is smaller than the reference data is shown, and therefore the fact that the electric quantity of the battery is sufficient at the target sampling moment can be determined. And if the difference value obtained by subtracting the second electrical data from the first electrical data is less than or equal to the preset threshold value, the actual electric quantity of the battery exceeds the reference data, and therefore, the electric quantity shortage of the battery at the target sampling moment can be determined. The preset threshold value can be set according to actual requirements or empirical values. For example, the preset threshold may be set to zero.
According to the technical scheme, the initial electric quantity of the battery and the sampling period of the target electric parameter are obtained, the first electric data which are used for representing the sum of data which are sampled according to the sampling period and are obtained in the process that the electric quantity of the battery is changed from the initial electric quantity to zero and are obtained in each sampling process of the target electric parameter are determined according to the initial electric quantity and the sampling period, the second electric data which represent the sum of data which are actually obtained by the target electric parameter at the moment of sampling and are obtained in each sampling process are obtained, and if the electric quantity prompting device is not in a working state, the electric quantity condition of the battery at the target sampling moment is determined according to the difference value of the first electric data and the second electric data. Therefore, the time parameter in the electric quantity operation processing is eliminated by calculating the first electric data and the second electric data, so that the difference value of the first electric data and the second electric data can simply reflect the electric quantity condition of the battery, the electric quantity monitoring function is further realized, and the operation complexity is low. And when the electric quantity prompting equipment is not in a working state, the SOC value or the residual electric quantity cannot be calculated, electric quantity monitoring is only carried out through the difference value of the first electric data and the second electric data, complex multiplication and division operations are not needed, operation resources are saved, and equipment performance is saved.
Optionally, on the basis of the steps shown in fig. 1, the method provided by the present disclosure may further include the following steps:
and if the situation that the electric quantity of the battery is insufficient is determined, generating and outputting prompt information for indicating that the electric quantity of the battery is insufficient.
That is, if it is determined that the battery is low, some problems may occur if the battery is continuously used, and therefore, it is necessary to indicate that the battery is low. Therefore, it is possible to generate the prompt information indicating that the battery power is insufficient and output the prompt information through the specified device. Illustratively, the designated device may output the reminder information by means such as a visual display, an audible reminder, or the like.
By adopting the scheme, when the risk of insufficient electric quantity of the battery is determined, a certain degree of prompt can be performed so that related personnel can take certain measures.
Optionally, the method provided by the present disclosure may further include the following steps, as shown in fig. 3:
in step 31, if the electric quantity prompting device is in a working state, determining a state of charge (SOC) value and/or a residual electric quantity of the battery at a target sampling moment according to the first electric data and the second electric data;
in step 32, the SOC value and/or the remaining power are output through the power prompting device.
If the electric quantity prompting equipment is in a working state, the electric quantity prompting equipment can be used for carrying out specific electric quantity prompting. Therefore, the SOC value and/or the remaining capacity of the battery at the target sampling timing may be determined based on the first electrical data and the second electrical data.
For example, the state of charge SOC value of the battery at the target sampling time may be determined by the following equation (1):
Figure BDA0002705073810000101
where C is the first electrical data and D is the second electrical data.
For example, the remaining capacity E of the battery at the target sampling time may be determined by the following equation (2):
E=(C-D)*B (2)
where C is the first electrical data, D is the second electrical data, and B is the sampling period.
After the SOC value and/or the residual capacity are calculated, the SOC value and/or the residual capacity can be output through the capacity prompting device so as to prompt the battery capacity in detail.
By adopting the mode, only under the condition that the electric quantity prompting equipment is in a working state, the calculation of the SOC value and/or the residual electric quantity can be carried out, only under the condition, the electric quantity detection of the battery can contain complex multiplication and division operations, and meanwhile, after the SOC value and/or the residual electric quantity are calculated, the specific prompt can be carried out through the electric quantity prompting equipment, and the battery electric quantity can be conveniently known by related personnel.
The procedure of the disclosed solution will be explained below by a specific example. Assuming that the initial charge of the battery is 1000mAh at the time of the battery charge detection, sampling is performed by the ADC (sampling period is 10 ms).
It can be seen that the first electrical data is 1000mAh/10ms (1000mA 3600s)/0.01s 360000A, i.e. when the battery level is 0, the sum of the instantaneous sampled current data of all ADCs is 360000A.
When the detection is started, at the sampling time t1, with t1 as the target sampling time, the ADC instantaneous acquisition data X (t1) is 1000A, the second electrical data is 1000A, and the remaining single sampling point electrical data is 359000A.
If the electric quantity prompting device is in a sleep state (not in a working state), the SOC and/or the residual electric quantity are not calculated, and only whether the residual single sampling point electric data tend to 0 (the preset threshold value is 0) or not is monitored, and at the moment, multiplication and division operation is not involved.
If the power prompting device is in an awake state (in an operating state), the remaining power is calculated to be (C-D) × B ═ 359000a ═ 10ms ═ 359000a × (0.01 h/3600 ═ 997.222mAh, and the SOC value is calculated to be (C-D)/C ═ 100% ═ 99.722%.
If the detection is continued, at the sampling time t2, with t2 as the target sampling time, the ADC instantaneous acquisition data X (t2) is 19000A, at which time the second electrical data is 1000A +19000A is 20000A, and the remaining single-sampling-point electrical data is C-D is 340000A.
If the electric quantity prompting device is in a sleep state (not in a working state), the SOC and/or the residual electric quantity are not calculated, and only whether the residual single sampling point electric data tend to 0 (the preset threshold value is 0) or not is monitored, and at the moment, multiplication and division operation is not involved.
If the power prompting device is in an awake state (in an operating state), the remaining power is calculated to be (C-D) × B ═ 340000a ═ 10ms ═ 340000a × (0.01 h/3600 ═ 944.444mAh, and the SOC value is calculated to be (C-D)/C ═ 100% ═ 94.444%.
If the detection is continued, at the sampling time t3, with t3 as the target sampling time, the ADC instantaneous acquisition data X (t3) is 5000A, at which time the second electrical data is 1000A +19000A +5000A is 25000A, and the remaining single-sampling-point electrical data is C-D is 335000A.
If the electric quantity prompting device is in a sleep state (not in a working state), the SOC and/or the residual electric quantity are not calculated, and only whether the residual single sampling point electric data tend to 0 (the preset threshold value is 0) or not is monitored, and at the moment, multiplication and division operation is not involved.
If the power prompting device is in an awake state (in an operating state), the remaining power is calculated to be (C-D) × B ═ 335000a ═ 10ms ═ 335000a × (0.01 h/3600 ═ 930.556mAh, and the SOC value is calculated to be (C-D)/C ═ 100% ═ 93.056%.
The subsequent processes are analogized. In this way, when the specific remaining power and the SOC value do not need to be prompted (i.e., the power prompting device is not in the operating state), discrete integral multiplication and division operation is not needed, the change of the power can be identified only by performing addition and subtraction operation on the first electrical data and the second electrical data (i.e., the single sampling point related data) provided by the scheme, and when the remaining power and the SOC value need to be prompted (i.e., the power prompting device is in the operating state), the power prompting function can be provided by performing complex calculation.
It should be noted that, in the above calculation process, the units of the physical quantities are not limited to the units given in the above example, and the present disclosure does not limit this, and it is sufficient to ensure that the units of the physical quantities are relatively consistent when calculating, for example, the first electrical data is in units of a, and the second electrical data is also in units of a.
Fig. 4 is a block diagram of a battery charge level detection apparatus provided according to an embodiment of the present disclosure. As shown in fig. 4, the apparatus 40 includes:
a first obtaining module 41, configured to obtain an initial electric quantity of the battery and a sampling period for sampling a target electric parameter;
a first determining module 42, configured to determine first electrical data according to the initial electrical quantity and the sampling period, where the first electrical data is used to represent a sum of data sampled in the sampling period and acquired by each sampling of the target electrical parameter when the battery electrical quantity changes from the initial electrical quantity to zero;
a second obtaining module 43, configured to obtain second electrical data at a target sampling time, where the second electrical data is used to represent a sum of data actually obtained by sampling the target electrical parameter at each time when the target sampling time is reached;
and a second determining module 44, configured to determine, if the electric quantity prompting device is not in the working state, an electric quantity condition of the battery at the target sampling time according to a difference between the first electric data and the second electric data.
Optionally, the first determining module 42 is configured to determine a ratio of the initial power amount and the sampling period as the first electrical data.
Optionally, the second determining module 44 includes:
a first determining submodule for determining a difference obtained by subtracting the second electrical data from the first electrical data;
the second determining submodule is used for determining that the electric quantity condition of the battery is sufficient if the difference value is larger than a preset threshold value;
and the third determining submodule is used for determining that the electric quantity condition of the battery is insufficient if the difference value is smaller than or equal to the preset threshold value.
Optionally, the apparatus 40 further comprises:
and the first prompting module is used for generating and outputting prompting information for indicating that the electric quantity of the battery is insufficient if the electric quantity condition of the battery is determined to be insufficient.
Optionally, the apparatus 40 further comprises:
the third determining module is used for determining the SOC value and/or the residual electric quantity of the battery at the target sampling moment according to the first electric data and the second electric data if the electric quantity prompting equipment is in the working state;
and the second prompting module is used for outputting the SOC value and/or the residual electric quantity through the electric quantity prompting equipment.
Optionally, the state of charge SOC value of the battery at the target sampling time is determined by the following equation (1):
Figure BDA0002705073810000131
wherein C is the first electrical data and D is the second electrical data.
Optionally, the remaining capacity E of the battery at the target sampling time is determined by the following formula (2):
E=(C-D)*B (2)
wherein C is the first electrical data, D is the second electrical data, and B is the sampling period.
With regard to the apparatus in the above-described embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
Fig. 5 is a block diagram illustrating an electronic device 1900 according to an example embodiment. Referring to fig. 5, an electronic device 1900 includes a processor 1922, which may be one or more in number, and a memory 1932 for storing computer programs executable by the processor 1922. The computer program stored in memory 1932 may include one or more modules that each correspond to a set of instructions. Further, the processor 1922 may be configured to execute the computer program to perform the battery level detection method described above.
Additionally, electronic device 1900 may also include a power component 1926 and a communication component 1950, the power component 1926 may be configured to perform power management of the electronic device 1900, and the communication component 1950 may be configured to enable communication, e.g., wired or wireless communication, of the electronic device 1900. In addition, the electronic device 1900 may also include input/output (I/O) interfaces 1958. The electronic device 1900 may operate based on an operating system, such as Windows Server, stored in memory 1932TM,Mac OSXTM,UnixTM,LinuxTMAnd so on.
In another exemplary embodiment, there is also provided a computer readable storage medium including program instructions which, when executed by a processor, implement the steps of the battery level detection method described above. For example, the computer readable storage medium may be the memory 1932 that includes program instructions executable by the processor 1922 of the electronic device 1900 to perform the battery level detection method described above.
In another exemplary embodiment, a computer program product is also provided, which comprises a computer program executable by a programmable apparatus, the computer program having code portions for performing the above-mentioned battery level detection method when executed by the programmable apparatus.
The preferred embodiments of the present disclosure are described in detail with reference to the accompanying drawings, however, the present disclosure is not limited to the specific details of the above embodiments, and various simple modifications may be made to the technical solution of the present disclosure within the technical idea of the present disclosure, and these simple modifications all belong to the protection scope of the present disclosure.
It should be noted that the various features described in the above embodiments may be combined in any suitable manner without departing from the scope of the invention. In order to avoid unnecessary repetition, various possible combinations will not be separately described in this disclosure.
In addition, any combination of various embodiments of the present disclosure may be made, and the same should be considered as the disclosure of the present disclosure, as long as it does not depart from the spirit of the present disclosure.

Claims (10)

1. A battery level detection method, the method comprising:
acquiring initial electric quantity of a battery and a sampling period for sampling a target electric parameter;
determining first electrical data according to the initial electrical quantity and the sampling period, wherein the first electrical data is used for representing the sum of data acquired by sampling the target electrical parameter in the process that the electrical quantity of the battery is changed from the initial electrical quantity to zero according to the sampling period;
acquiring second electrical data of a target sampling moment, wherein the second electrical data is used for representing the sum of data actually acquired by sampling the target electrical parameter at each time when the target sampling moment is reached;
and if the electric quantity prompting equipment is not in a working state, determining the electric quantity condition of the battery at the target sampling moment according to the difference value of the first electric data and the second electric data.
2. The method of claim 1, wherein determining first electrical data based on the initial amount of power and the sampling period comprises:
determining a ratio of the initial charge to the sampling period as the first electrical data.
3. The method of claim 1, wherein determining the charge condition of the battery at the target sampling time according to the difference between the first electrical data and the second electrical data if the charge indication device is not in the working state comprises:
determining a difference value obtained by subtracting the second electrical data from the first electrical data;
if the difference value is larger than a preset threshold value, determining that the electric quantity condition of the battery is sufficient;
and if the difference is smaller than or equal to the preset threshold, determining that the electric quantity condition of the battery is insufficient.
4. The method of claim 3, further comprising:
and if the situation that the electric quantity of the battery is insufficient is determined, generating and outputting prompt information for indicating that the electric quantity of the battery is insufficient.
5. The method of claim 1, further comprising:
if the electric quantity prompting equipment is in the working state, determining a state of charge (SOC) value and/or a residual electric quantity of the battery at the target sampling moment according to the first electric data and the second electric data;
and outputting the SOC value and/or the residual electric quantity through the electric quantity prompting equipment.
6. The method of claim 5, wherein the state of charge (SOC) value of the battery at the target sampling time is determined by the following equation (1):
Figure FDA0002705073800000021
wherein C is the first electrical data and D is the second electrical data.
7. The method according to claim 5, wherein the remaining capacity E of the battery at the target sampling time is determined by the following formula (2):
E=(C-D)*B (2)
wherein C is the first electrical data, D is the second electrical data, and B is the sampling period.
8. A battery level detection apparatus, the apparatus comprising:
the first acquisition module is used for acquiring the initial electric quantity of the battery and the sampling period of the target electric parameter;
the first determining module is used for determining first electrical data according to the initial electrical quantity and the sampling period, wherein the first electrical data are used for representing the sum of data which are sampled according to the sampling period and are acquired by sampling the target electrical parameter each time when the battery electrical quantity is changed from the initial electrical quantity to zero;
the second acquisition module is used for acquiring second electrical data at a target sampling moment, wherein the second electrical data are used for representing the sum of data actually acquired by sampling the target electrical parameter at each time when the target sampling moment is reached;
and the second determining module is used for determining the electric quantity condition of the battery at the target sampling moment according to the difference value of the first electric data and the second electric data if the electric quantity prompting device is not in a working state.
9. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 7.
10. An electronic device, comprising:
a memory having a computer program stored thereon;
a processor for executing the computer program in the memory to carry out the steps of the method of any one of claims 1 to 7.
CN202011035891.6A 2020-09-27 2020-09-27 Battery electric quantity detection method and device, storage medium and electronic equipment Pending CN114325416A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011035891.6A CN114325416A (en) 2020-09-27 2020-09-27 Battery electric quantity detection method and device, storage medium and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011035891.6A CN114325416A (en) 2020-09-27 2020-09-27 Battery electric quantity detection method and device, storage medium and electronic equipment

Publications (1)

Publication Number Publication Date
CN114325416A true CN114325416A (en) 2022-04-12

Family

ID=81011616

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011035891.6A Pending CN114325416A (en) 2020-09-27 2020-09-27 Battery electric quantity detection method and device, storage medium and electronic equipment

Country Status (1)

Country Link
CN (1) CN114325416A (en)

Similar Documents

Publication Publication Date Title
CN107179512B (en) Method and device for predicting service life of battery
CN106772091B (en) Method and device for updating battery capacity value and terminal
CN111474482B (en) Electric quantity detection model establishing method, electric quantity detection device and electronic equipment
EP3611526B1 (en) Battery capacity monitor
CN104950260A (en) Model-independent battery life and performance forecaster
EP3913727A1 (en) Battery residual value determination system
CN111679206A (en) Electric quantity detection method and device, and storage medium
JP2017016991A (en) Data extraction device, data extraction method and data extraction program
CN113910909B (en) Method, device, equipment and medium for detecting performance of hydrogen fuel cell system
CN111703304B (en) Train load power supply control method, device and equipment and train
CN114325416A (en) Battery electric quantity detection method and device, storage medium and electronic equipment
WO2017002953A1 (en) Data extracting device, data extracting method, and data extracting program
JP2002056903A (en) Polarization voltage value computing method, battery voltage value compensation method and remainder state estimation method of secondary battery, secondary battery unit and device using same
CN112595984B (en) Lithium battery voltage detection method and device, electrical equipment and storage medium
CN115714437A (en) Method and device for displaying charging capacity of battery, electric terminal and storage medium
CN111198607B (en) Method and device for managing power consumption of electronic equipment
JP5307269B1 (en) Apparatus for estimating cell state of battery pack
CA3139175A1 (en) Battery performance evaluation device, electronic apparatus, charger, and battery performance evaluation method
CN113030750B (en) Method and device for detecting residual use parameters of lithium battery
CN114578235A (en) Battery capacity determination method, electronic device and storage medium
JP2000340268A (en) Electronic device and management method for battery
CN110850305B (en) Method and device for calculating electric quantity of lead-acid battery and computer-readable storage medium
JP2004361313A (en) Remaining capacity arithmetic unit and remaining capacity computing method of secondary battery
CN118040794B (en) Optical storage and charging integrated power conversion method and system
CN116583753B (en) Method and system for analysing an electrical energy storage device and energy supply system

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