A method and apparatus for charging a battery
Patent Information
- Application Number
- CN202610941797.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-26
- Publication Date
- 2026-08-28
- Estimated Expiration
- 2046-06-26
Smart Images

Figure CN122475367B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of vehicle charging management technology, and in particular to a method and apparatus for charging a storage battery. Background Technology
[0002] A hybrid vehicle's powertrain consists of an internal combustion engine, an electric motor, and a battery. During vehicle operation, the internal combustion engine drives the electric motor to generate electricity, which is then rectified by a three-phase bridge circuit to charge the battery. When the vehicle starts or accelerates rapidly, the battery discharges to drive the electric motor, providing auxiliary torque. The battery typically employs a constant current-constant voltage combined charging mode. The constant current charging phase requires precise control of the charging current to ensure charging safety and battery life.
[0003] Therefore, ensuring accurate control of the charging current during constant current charging of a battery is a problem that urgently needs to be solved by those skilled in the art. Summary of the Invention
[0004] The purpose of this invention is to provide a charging method and apparatus for a storage battery. The real-time charging current detected by the BMS is more accurate. By combining the dual closed-loop regulation of the voltage inner loop and the current outer loop, as well as the feedforward control of the open-circuit voltage, the real-time charging current accurately follows the preset constant current charging current, thereby achieving precise control of constant current charging.
[0005] To address the aforementioned technical problems, this invention provides a battery charging method, comprising: acquiring the real-time charging current of the battery detected by a BMS; acquiring the output port voltage of a three-phase bridge circuit; calculating the difference between the real-time charging current and a preset constant current charging current, and inputting the result to a current loop PI controller for calculation to obtain a charging voltage compensation amount; acquiring the open-circuit voltage of the battery, and superimposing the open-circuit voltage with the charging voltage compensation amount to obtain a charging reference voltage; calculating the difference between the charging reference voltage and the output port voltage, and inputting the result to a voltage loop PI controller for calculation to obtain a duty cycle adjustment amount; and modulating a PWM pulse signal according to the duty cycle adjustment amount to control the three-phase bridge circuit to adjust the charging current output to the battery.
[0006] Preferably, obtaining the open-circuit voltage of the battery includes: obtaining the SOC and average cell temperature of the battery detected by the BMS; and determining the open-circuit voltage by querying a pre-calibrated SOC-cell temperature-open-circuit voltage correspondence table based on the SOC and the average cell temperature.
[0007] Preferably, acquiring the real-time charging current of the battery detected by the BMS includes: acquiring a detection data packet from the BMS via CAN communication, the detection data packet including the real-time charging current of the battery; performing cyclic redundancy check on the detection data packet; if the check passes, storing the real-time charging current in the detection data packet in a memory, and smoothing the real-time charging current using a sliding window filter; if the check fails, using the real-time charging current stored in the memory in the previous sampling period as the real-time charging current in the current sampling period; when the detection data packet is not received for multiple consecutive sampling periods, determining the current open-circuit voltage, superimposing the current open-circuit voltage with the preset voltage compensation amount, calculating the difference between the superimposed sum and the output port voltage, and inputting the result to the voltage loop PI controller for calculation to obtain the duty cycle adjustment amount, and then proceeding to the step of modulating a PWM pulse signal according to the duty cycle adjustment amount to control the three-phase bridge circuit to adjust the charging current output to the battery.
[0008] Preferably, the method further includes: acquiring the real-time terminal voltage of the battery; when the real-time terminal voltage reaches a preset maximum charging voltage and remains so for a preset duration, gradually reducing the charging voltage compensation amount to zero, while simultaneously transitioning the charging reference voltage to a preset full-charge voltage and then calculating the difference between the charging reference voltage and the output port voltage, and inputting the result to a voltage loop PI controller for calculation to obtain the duty cycle adjustment amount.
[0009] Preferably, after transitioning the charging reference voltage to a preset full-charge voltage, the method further includes: reducing the voltage loop proportional parameter in the voltage loop PI controller to a preset proportion of the initial voltage loop proportional parameter.
[0010] Preferably, the method further includes: acquiring the engine speed, throttle opening, vehicle speed, and braking status signals of the vehicle where the battery is located; when the engine speed is less than a preset speed threshold, using a first charging current as the preset constant current charging current; when the engine speed is greater than the preset speed threshold and the braking status signal is invalid, using a second charging current as the preset constant current charging current; when the engine speed is greater than the preset speed threshold, the vehicle speed is greater than a preset vehicle speed threshold, the throttle opening is zero, and the braking status signal is valid, determining it as a braking energy recovery condition, and using a third charging current as the preset constant current charging current; wherein, the first charging current < the second charging current < the third charging current.
[0011] Preferably, the method further includes: when it is detected that the motor of the vehicle where the battery is located has switched from motor operation to generator operation, recording the output port voltage at the switching moment as the initial charging reference voltage, and controlling the charging reference voltage to rise in a ramp manner based on the initial charging reference voltage with a preset slope, performing the step of calculating the difference between the charging reference voltage and the output port voltage, and inputting the obtained result to the voltage loop PI controller for calculation to obtain the duty cycle adjustment amount; until the output port voltage is greater than the open circuit voltage, proceeding to the step of acquiring the engine speed, throttle opening, vehicle speed and braking status signals of the vehicle where the battery is located.
[0012] Preferably, before acquiring the open-circuit voltage of the battery and superimposing the open-circuit voltage with the charging voltage compensation amount, the method further includes: acquiring the real-time SOH and maximum cell voltage difference of the battery detected by the BMS; acquiring the battery health correction amount of the battery based on the real-time SOH, wherein the battery health correction amount is the difference between the open-circuit voltage of the battery under the real-time SOH and the open-circuit voltage of the battery when the SOH is 100%; acquiring the cell consistency correction amount of each cell in the battery based on the maximum cell voltage difference, wherein the cell consistency correction amount is the difference between the open-circuit voltage estimated by the average voltage method under the voltage difference state and the measured open-circuit voltage under the balanced state; multiplying the cell consistency correction amount by the total number of cells in series in the battery to obtain the product, and adding the obtained product to the battery health correction amount to obtain the composite feedforward compensation voltage; and superimposing the composite feedforward compensation voltage with the open-circuit voltage and the charging voltage compensation amount to obtain the charging reference voltage.
[0013] Preferably, it further includes: reducing the preset constant current charging current when the maximum voltage difference of the battery cell is greater than the preset maximum voltage difference.
[0014] To solve the above-mentioned technical problems, the present invention provides a battery charging device, comprising: a memory for storing a computer program; and a processor for implementing the steps of the battery charging method as described above when executing the computer program.
[0015] This application provides a battery charging method and apparatus. First, the real-time charging current of the battery detected by the BMS and the output port voltage of the three-phase bridge circuit are acquired. The difference between the real-time charging current and the preset constant current charging current is calculated, and the result is input to a current loop PI controller for calculation to obtain a charging voltage compensation amount. The open-circuit voltage of the battery is superimposed with the charging voltage compensation amount to obtain a charging reference voltage. The difference between the charging reference voltage and the output port voltage is calculated, and the result is input to a voltage loop PI controller for calculation to obtain a duty cycle adjustment amount. A PWM pulse signal is modulated according to the duty cycle adjustment amount to control the three-phase bridge circuit to adjust the charging current output to the battery. Based on this, the real-time charging current detected by the BMS is more accurate. Combined with the dual closed-loop regulation of the voltage inner loop and the current outer loop, and the feedforward control incorporating the open-circuit voltage, the real-time charging current accurately follows the preset constant current charging current, thereby achieving precise control of constant current charging. Attached Figure Description
[0016] To more clearly illustrate the embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0017] Figure 1 This is a schematic flowchart illustrating a method for charging a storage battery provided in this application.
[0018] Figure 2 This is a control block diagram of a battery charging method provided in this application.
[0019] Figure 3 This is a schematic diagram of a battery charging system provided in this application.
[0020] Figure 4 This is a schematic diagram of the structure of a battery charging device provided in this application.
[0021] Figure 5 This is a schematic diagram of the structure of a computer-readable storage medium provided in this application. Detailed Implementation
[0022] The core of this invention is to provide a charging method and device for a storage battery. The real-time charging current detected by the BMS is more accurate. Combined with the dual closed-loop regulation of the voltage inner loop and the current outer loop, as well as the feedforward control of the open-circuit voltage, it ensures that the real-time charging current accurately follows the preset constant current charging current, thereby achieving precise control of constant current charging.
[0023] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0024] The powertrain system of a hybrid vehicle consists of an internal combustion engine, an electric motor, and a battery. The internal combustion engine is the main power source, while the electric motor is directly connected to the crankshaft of the internal combustion engine and serves as both a drive and generator. The battery is an energy storage unit: when the vehicle is driving smoothly or cruising, the internal combustion engine drives the electric motor to generate electricity, which is then stored in the battery after being regulated by a power electronic control device; when the vehicle starts or accelerates rapidly, the battery discharges to drive the electric motor to output auxiliary torque, which couples with the power of the internal combustion engine to improve the vehicle's power performance.
[0025] In existing technologies, the power circuit of a low-power power electronic control device for hybrid vehicles typically consists of a motor, a battery, a three-phase bridge circuit 21 composed of six MOSFETs (Metal-Oxide-Semiconductor Field-Effect Transistors), and sampling resistors on the DC bus. Voltage signals are acquired through the sampling resistors to calculate the charging current, and constant current charging is achieved through closed-loop control. However, this current acquisition method based on sampling resistors struggles to balance sampling accuracy and hardware cost, exhibiting two major technical drawbacks.
[0026] 1. Sampling accuracy is limited by the design of the sampling resistor value: The operating current under motor drive conditions is much greater than that under charging conditions. In order to reduce the power loss of the sampling resistor under drive conditions, a low-cost small-value resistor with a total resistance of less than 5 milliohms should be selected. However, the sampling voltage signal generated by it under charging conditions is weak and easily affected by environmental noise and voltage drift, resulting in a large current sampling error, which cannot meet the accuracy requirements of constant current charging.
[0027] 2. High-frequency harmonics exacerbate sampling deviation: The sampling resistor is located in front of the filter capacitor. When the PWM (Pulse Width Modulation) signal controls the switching on and off of the MOSFET of the three-phase bridge circuit 21, it will introduce high-frequency harmonics of the same frequency or multiples of the frequency across the sampling resistor. The harmonics are superimposed on the weak sampling voltage, further deteriorating the sampling accuracy of the charging current, and may even cause the constant current charging closed-loop control to fail.
[0028] While existing technologies can use high-precision current sensors to replace sampling resistors to improve acquisition accuracy and ensure the reliability of closed-loop control, this significantly increases the hardware cost of power electronic control devices.
[0029] Please refer to Figure 1 , Figure 1 This application provides a schematic flowchart of a battery charging method, which includes: S11: acquiring the real-time charging current of the battery detected by the BMS.
[0030] In this embodiment, the sampling resistor is primarily used for protection, not for control. The current used for control is the real-time charging current of the battery received from the BMS (Battery Management System). The BMS internally collects the real-time charging current of the battery through its own current detection circuit (such as a shunt or Hall sensor), and after internal calibration and filtering, transmits it externally as a digital signal via the CAN (Controller Area Network) bus. This step directly obtains the current data already processed by the BMS, without relying on its own current sampling circuit, thus avoiding measurement errors introduced by the sampling resistor. On the one hand, it reuses the current detection capability of the vehicle's existing BMS without increasing hardware costs; on the other hand, the current data provided by the BMS, after filtering, has high accuracy and reliability, providing accurate feedback for subsequent closed-loop control.
[0031] S12: Obtain the output port voltage of the three-phase bridge circuit.
[0032] The voltage acquisition module acquires the voltage value at the output port of the three-phase bridge circuit 21 after the filter capacitor in real time. The three-phase bridge circuit 21 is a power conversion unit connecting the motor and the battery, and its output port is directly connected to the positive and negative terminals of the battery. The voltage acquisition module can, but is not limited to, use a resistor divider network to step down the high-voltage signal to a voltage range suitable for the processor's analog-to-digital conversion, and work with an RC filter circuit to filter out high-frequency harmonics, thereby obtaining a stable voltage signal. The output port voltage reflects the actual voltage output by the three-phase bridge circuit 21 to the battery terminals.
[0033] S13: Calculate the difference between the real-time charging current and the preset constant current charging current, and input the result into the current loop PI controller for calculation to obtain the charging voltage compensation amount.
[0034] The processor subtracts the acquired real-time charging current from the preset constant current charging target current value (i.e., the preset constant current charging current) to obtain the current error at the current moment. This current error is input to the current loop PI (proportional-integral) controller, and the output after proportional and integral calculations serves as the charging voltage compensation. The preset constant current charging current can be pre-calibrated and stored in memory based on the battery type, capacity, temperature, and vehicle operating conditions, or it can be adjusted online according to actual needs; this application does not limit this. The proportional and integral parameters of the current loop PI controller can be, but are not limited to, predetermined through engineering tuning methods to ensure fast current response and steady-state accuracy.
[0035] By using current closed-loop control, the actual charging current can track the preset constant current charging current, eliminating steady-state errors caused by load changes, parameter drift, etc., and achieving the control objective of constant current charging. At the same time, the integral action of the current loop PI controller can eliminate long-term accumulated deviations, while the proportional action ensures dynamic response speed.
[0036] In this embodiment, the sampling period refers to the time interval during which the processor periodically collects the real-time charging current of the battery and the output port voltage of the three-phase bridge circuit 21, i.e., the fixed duration between two adjacent samples. As a preferred embodiment, the sampling period is set to 10 milliseconds. At the end of each sampling period, the processor reads the real-time charging current and output port voltage at the current moment, discretizes them into digital quantities, and uses them for subsequent current error calculation, voltage error calculation, and iterative calculations of the current loop PI controller and voltage loop PI controller.
[0037] S14: Obtain the open-circuit voltage of the battery, and add the open-circuit voltage to the charging voltage compensation to obtain the charging reference voltage.
[0038] In this step, the open-circuit voltage of the battery in its current state is first obtained. The open-circuit voltage represents the battery's equilibrium electromotive force and is the reference value for determining the minimum voltage required for charging. Then, the charging voltage compensation is algebraically superimposed on the above open-circuit voltage to obtain the charging reference voltage. The charging reference voltage is the target value for voltage closed-loop control, that is, the target voltage that the three-phase bridge circuit 21 should output in order to maintain or make the charging current reach the preset constant current charging current.
[0039] S15: Calculate the difference between the charging reference voltage and the output port voltage, and input the result to the voltage loop PI controller for calculation to obtain the duty cycle adjustment amount.
[0040] The voltage error at the current moment is obtained by subtracting the calculated charging reference voltage from the actual output port voltage. This voltage error is input to the voltage loop PI controller, which performs proportional and integral calculations and outputs a control quantity, the duty cycle adjustment. The proportional and integral parameters of the voltage loop PI controller can be, but are not limited to, pre-set using engineering tuning methods to ensure fast voltage tracking and zero steady-state error. This duty cycle adjustment is a value between 0 and 1, or a corresponding digital value, which determines the width of the PWM pulse.
[0041] Based on this, the voltage inner loop can quickly respond to changes in the output port voltage, adjust the duty cycle in a timely manner to suppress load disturbances, and ensure stable voltage control of the current outer loop.
[0042] S16: Modulate the PWM pulse signal according to the duty cycle adjustment to control the three-phase bridge circuit to adjust the charging current output to the battery.
[0043] The obtained duty cycle adjustment is sent to the PWM conversion module. The PWM conversion module generates a PWM pulse signal with a corresponding pulse width based on this duty cycle adjustment. For example, when the duty cycle adjustment is 0.3, the high-level time of the PWM pulse signal accounts for 30% of the entire cycle. This PWM pulse signal is applied to the control electrode of each power switch in the three-phase bridge circuit 21, controlling the on-time and off-time ratio of the switches. By changing the on-duty cycle of the switches, the electrical power transmitted from the motor end to the battery end by the three-phase bridge circuit 21 can be adjusted, thereby changing the charging current output to the battery. Specifically, the larger the duty cycle, the greater the transmitted power and the greater the charging current; conversely, the smaller the duty cycle, the less power is transmitted and the greater the charging current.
[0044] In summary, this embodiment achieves high-precision constant current charging without the need for additional high-precision current sampling hardware by using a dual-closed-loop PI control structure with the current loop as the outer loop and the voltage loop as the inner loop. Therefore, the real-time charging current detected by the BMS is more accurate, and the dual-closed-loop regulation of the voltage inner loop and current outer loop ensures that the real-time charging current accurately follows the preset constant current charging current, thereby achieving precise control of constant current charging.
[0045] Based on the above embodiments: as a preferred embodiment, obtaining the open-circuit voltage of the battery includes: obtaining the SOC and average cell temperature of the battery detected by the BMS; and determining the open-circuit voltage by querying a pre-calibrated SOC-cell temperature-open-circuit voltage correspondence table based on the SOC and average cell temperature.
[0046] First, the SOC (State of Charge) value and average cell temperature are obtained in real time from the BMS via CAN communication. The SOC is estimated in real time by the BMS based on methods such as current integration and voltage correction, reflecting the percentage of the battery's current remaining charge. The average cell temperature is obtained by the BMS by averaging the data collected from multiple temperature sensors distributed inside the battery pack, and is used to characterize the overall thermal state of the battery.
[0047] Secondly, based on the obtained SOC and average cell temperature, the open-circuit voltage under the current state is determined by querying a pre-calibrated three-dimensional correspondence table of SOC-cell temperature-open-circuit voltage. This SOC-cell temperature-open-circuit voltage correspondence table is obtained through extensive offline experimental calibration of similar cells: under specific temperature conditions, the cell is discharged from a fully charged state to the cutoff voltage with a very small current (e.g., below 0.05C), and the open-circuit voltage corresponding to different SOCs is recorded. The above experiment is repeated by changing the ambient temperature (e.g., at typical temperature points such as -20℃, 0℃, 25℃, and 40℃), thereby obtaining a three-dimensional data table covering the entire temperature range and the entire SOC interval. In practical applications, if the query point falls exactly on the calibration point, the corresponding open-circuit voltage is directly read; if it falls between calibration points, a linear interpolation or quadratic interpolation method is used to calculate the accurate open-circuit voltage. Of course, this application does not limit this calculation.
[0048] It should be noted that in this embodiment, the average open-circuit voltage of each cell in the battery is first determined by looking up the SOC-cell temperature-open-circuit voltage correspondence table. The average open-circuit voltage is then multiplied by the number of cells connected in series in the battery to obtain the open-circuit voltage used for calculating the charging reference voltage.
[0049] As a preferred embodiment, acquiring the real-time charging current of the battery detected by the BMS includes: acquiring the detection data packet of the BMS via CAN communication, the detection data packet including the real-time charging current of the battery; performing cyclic redundancy check on the detection data packet; if the check passes, storing the real-time charging current in the detection data packet into the memory, and smoothing the real-time charging current using a sliding window filter; if the check fails, calling the real-time charging current stored in the memory in the previous sampling period as the real-time charging current of the current sampling period; when no detection data packet is received for several consecutive sampling periods, determining the current open-circuit voltage, superimposing the current open-circuit voltage with a preset voltage compensation amount, calculating the difference between the superimposed sum and the output port voltage, and inputting the result to the voltage loop PI controller for calculation to obtain the duty cycle adjustment amount, and then proceeding to the step of modulating the PWM pulse signal according to the duty cycle adjustment amount to control the three-phase bridge circuit to adjust the charging current output to the battery.
[0050] First, the detection data packets sent by the BMS are received via CAN communication. The BMS encapsulates multiple parameters, including the real-time charging current of the battery, into a detection data packet according to a sampling period (e.g., 10ms) and broadcasts it via the CAN bus. The processor's CAN communication acquisition module monitors the bus in real time and captures this detection data packet. Due to uncertainties in the vehicle's driving environment, such as electromagnetic interference and poor connector contact, the detection data packets on the CAN bus may experience bit errors or packet loss. Therefore, this embodiment performs cyclic redundancy check (CRC) verification on each received detection data packet. CRC verification is an error detection technique used in digital communication. Its principle is to append several check bits to the end of the data packet. The receiving end recalculates the check bits on the data packet content and compares them with the appended bits. If they match, the data transmission is correct; if they do not match, the data has been corrupted during transmission.
[0051] If the CRC check passes, indicating that the current detection data packet is valid, the real-time charging current value in the detection data packet is extracted and stored in memory for later use in the PI calculation during the current loop. Simultaneously, to further suppress potential random noise and transient jumps, this embodiment employs a sliding window filter to smooth the extracted real-time charging current. The sliding window filter works as follows: a fixed-length queue of current values, such as 5 or 10, is maintained in memory. Each time a new valid real-time charging current is obtained, it is added to the tail of the queue, and the old value at the head of the queue is removed. Then, the arithmetic mean of all real-time charging currents in the queue is calculated, and this arithmetic mean is used as the real-time charging current for the current sampling period. The sliding window filter effectively filters out high-frequency random noise, making the current feedback involved in the closed-loop control more stable and preventing drastic fluctuations in the PI controller output due to abnormal jumps at a single sampling point.
[0052] If the CRC check fails, it indicates that the current detection data packet is corrupted. In this case, the detection data packet is discarded, and the real-time charging current stored in memory from the previous sampling period is used as the real-time charging current for the current sampling period. This approach is based on the fact that during normal vehicle operation, the battery charging current does not change abruptly, and the current change between two adjacent sampling periods is very small. Therefore, using the valid value from the previous moment to replace the current corrupted value can ensure control continuity without introducing significant errors. This mechanism effectively avoids control failures or current surges caused by single communication interference.
[0053] There is also the possibility of failing to receive valid detection data packets for multiple consecutive sampling cycles, i.e., continuous packet loss. The causes of continuous packet loss may include CAN bus communication interruption, BMS node failure, or line contact problems. When such continuous packet loss occurs, the current loop PI controller will lose its input feedback and fail to function properly because the real-time charging current cannot be obtained. If the current loop is simply stopped or its output is set to zero at this time, the charging voltage compensation will be missing, leading to a sharp drop in the charging reference voltage, causing charging current interruption or severe fluctuations, affecting the continuity of the charging process and battery safety. In this case, this embodiment switches from constant current charging to constant voltage charging. The specific method is as follows: First, obtain the current open-circuit voltage of the battery in the current state. The current open-circuit voltage can be obtained by retrieving the most recently successfully received SOC value and average cell temperature from memory, and then querying the pre-calibrated SOC-cell temperature-open-circuit voltage correspondence table based on these two parameters. Then, the current open-circuit voltage is superimposed with the preset voltage compensation to obtain a transitional charging reference voltage. The preset voltage compensation amount can be, but is not limited to, the charging voltage compensation amount output by the current loop PI controller in the last valid sampling period before continuous packet loss occurs, and is used as a hold value during the packet loss period. Alternatively, the preset voltage compensation amount can be set to 0.5V; this application does not limit this. Next, the difference between this transitional charging reference voltage and the real-time acquired output port voltage of the three-phase bridge circuit is calculated, and the calculated voltage error is input to the voltage loop PI controller for calculation to obtain the duty cycle adjustment amount. Finally, the PWM pulse signal is modulated according to the duty cycle adjustment amount to control the three-phase bridge circuit to adjust the charging current output to the battery.
[0054] By employing CRC verification, sliding window filtering, and multi-layered anti-interference measures that reuse the previous effective value, the reliability and stability of the real-time charging current obtained from the CAN bus are significantly improved, thereby meeting the real-time and accuracy requirements of constant current charging closed-loop control. Furthermore, it promptly switches to constant voltage charging when continuous packet loss occurs, preventing battery charging interruption.
[0055] In this embodiment, the sampling period refers to the time interval during which the processor periodically collects the real-time charging current of the battery and the output port voltage of the three-phase bridge circuit 21. It is a fixed duration between two adjacent samples, and also the sampling period for the BMS to sample the real-time charging current and the output port voltage of the three-phase bridge circuit 21. However, this application does not limit this period. As a preferred embodiment, the sampling period is set to 10 milliseconds. At the end of each sampling period, the processor obtains the real-time charging current and the output port voltage from the BMS, discretizes them into digital quantities, and uses them for subsequent current error calculation, voltage error calculation, and iterative calculations of the PI controller.
[0056] As a preferred embodiment, the method further includes: acquiring the real-time terminal voltage of the battery; when the real-time terminal voltage reaches the preset maximum charging voltage and remains so for a preset duration, gradually reducing the charging voltage compensation amount to zero, while simultaneously transitioning the charging reference voltage to the preset full-charge voltage, and then calculating the difference between the charging reference voltage and the output port voltage, and inputting the result to the voltage loop PI controller for calculation to obtain the duty cycle adjustment amount.
[0057] During the constant current charging phase, the real-time terminal voltage of the battery is acquired. It should be noted that the real-time terminal voltage and the output port voltage of the aforementioned three-phase bridge circuit 21 are physically at the same node. However, this step emphasizes the voltage value used to determine the charging mode switching condition. This voltage value can be provided by the same voltage acquisition module, or it can be replaced by the battery terminal voltage value reported by the BMS via CAN communication. This application does not limit this. The acquisition period of the real-time terminal voltage is consistent with the sampling period of the control system to ensure that voltage changes can be captured in a timely manner.
[0058] Secondly, the real-time terminal voltage is compared with the preset maximum charging voltage. The preset maximum charging voltage is a threshold pre-calibrated and stored in memory based on the battery type, cell material system (such as ternary lithium battery or lithium iron phosphate battery), and the number of cells connected in series. For example, for ternary lithium batteries, the maximum charging voltage can be, but is not limited to, set to the total pack voltage value corresponding to 3.98V per cell multiplied by the number of cells connected in series, at which point the corresponding SOC is approximately 80%; for lithium iron phosphate batteries, it can be, but is not limited to, set to 3.65V per cell multiplied by the number of cells connected in series, at which point the corresponding SOC is close to 100%. When the real-time terminal voltage reaches the preset maximum charging voltage, and this state is maintained for a preset duration, such as a preset number of sampling periods, for example, 5 consecutive sampling periods, i.e., 50ms, it is determined that the battery has entered the end of constant current charging and needs to switch to constant voltage charging mode. The purpose of setting the duration condition is to prevent erroneous switching caused by instantaneous voltage spikes or measurement noise, and to improve the reliability of mode switching.
[0059] Once the switching conditions are met, this embodiment gradually reduces the charging voltage compensation amount calculated by the current loop PI controller to zero. Specifically, instead of directly cutting off the current loop, the charging voltage compensation amount is gradually reduced from its current value to zero over several sampling periods with a fixed step size or a preset reduction slope. Simultaneously, the charging reference voltage, which is originally the sum of the open-circuit voltage and the charging voltage compensation amount, is smoothly transitioned to a preset full-charge voltage. For example, the charging reference voltage is initially set to the sum of the open-circuit voltage and the charging voltage compensation amount, and then increased to a preset full-charge voltage according to a preset transition slope. The preset transition slope for ternary lithium batteries can be, but is not limited to, 0.5V / s, and for lithium iron phosphate batteries, it can be, but is not limited to, 1V / s. The preset full-charge voltage and the aforementioned preset maximum charging voltage can be the same value, or the preset full-charge voltage can be slightly lower than the preset maximum charging voltage, depending on the battery's charging characteristics and safety requirements. This application does not impose any limitations on this. After the charging voltage compensation amount is completely zeroed and the charging reference voltage stabilizes at the preset full-charge voltage, the system exits the control function of the current loop, retaining only the voltage loop. At this point, the subsequent control process will calculate the difference between the charging reference voltage, which has been constant at the preset full-charge voltage, and the output port voltage, and input the result to the voltage loop PI controller for calculation to obtain the duty cycle adjustment amount, thereby maintaining the battery at a constant voltage to continue charging until the charging current naturally decays to the cutoff current and the entire charging process is completed.
[0060] By gradually reducing the charging voltage compensation amount instead of directly cutting off the current loop, the sudden change in the duty cycle of the PWM pulse wave signal during the mode switching between constant current charging and constant voltage charging is avoided. This prevents the on / off impact of the power switching transistors in the three-phase bridge circuit 21 and protects the power devices. The charging reference voltage smoothly transitions to the preset full charge voltage, so that the real-time terminal voltage of the battery will not suddenly rise or fall. This avoids the adverse effects of voltage mutation on the cell polarization state and internal chemical stability, and extends the battery life. The judgment condition of continuously preset duration improves the anti-interference capability and prevents frequent or erroneous switching caused by voltage fluctuations.
[0061] In a preferred embodiment, after transitioning the charging reference voltage to a preset full-charge voltage, the method further includes: reducing the voltage loop proportional parameter in the voltage loop PI controller to a preset proportion of the initial voltage loop proportional parameter.
[0062] During the process of switching from constant current charging to constant voltage charging, after the charging reference voltage has smoothly transitioned to the preset full charging voltage, the voltage loop proportional parameter in the voltage loop is further reduced to the preset proportion of the initial voltage loop proportional parameter.
[0063] Specifically, during the constant current charging phase, the proportional parameter of the voltage loop PI controller is denoted as... The initial voltage loop proportional parameter is set according to the system's dynamic response requirements. This initial voltage loop proportional parameter can be determined using engineering tuning methods, such as the critical proportionality method or the Ziegler-Nichols method, to ensure the voltage loop has a fast tracking speed and appropriate overshoot, thus cooperating with the outer current loop to achieve stable constant current control. However, when switching to the constant voltage charging stage, the battery's SOC is already in a high range, for example, a ternary lithium battery with an SOC exceeding 80%, or a lithium iron phosphate battery nearing full charge. At this time, the cell polarization effect is significantly enhanced. The polarization effect makes the battery terminal voltage extremely sensitive to changes in charging current: small current fluctuations can cause large fluctuations in terminal voltage. If the voltage loop proportional parameter remains a large initial voltage loop proportional parameter, small changes in voltage error will be excessively amplified, causing drastic fluctuations in duty cycle adjustment, which in turn causes oscillations in the charging current, and may even trigger overvoltage alarms or protection mechanisms in the BMS.
[0064] Therefore, in this embodiment, after the charging reference voltage stabilizes at a preset full-charge voltage, the proportional parameter of the voltage loop is actively adjusted. The voltage loop proportional parameter is reduced to a preset ratio based on the battery's polarization characteristics and actual debugging experience. For example, it can be any value between 50% and 70%, but this application does not limit this. After reducing the proportional parameter, the voltage loop gain decreases, and the voltage loop PI controller's response to voltage errors becomes smoother, effectively suppressing the risk of voltage control loop oscillation caused by polarization effects. Simultaneously, the voltage loop integral parameter... The voltage loop proportional parameter can remain unchanged to ensure steady-state voltage tracking without steady-state error. The adjustment of the proportional parameter can be a single step change or a gradual transition using a ramp method; the specific implementation method is not limited.
[0065] As a preferred embodiment, the method further includes: acquiring the engine speed, throttle opening, vehicle speed, and braking status signals of the vehicle where the battery is located; when the engine speed is less than a preset speed threshold, using a first charging current as the preset constant current charging current; when the engine speed is greater than the preset speed threshold and the braking status signal is invalid, using a second charging current as the preset constant current charging current; when the engine speed is greater than the preset speed threshold, the vehicle speed is greater than the preset vehicle speed threshold, the throttle opening is zero, and the braking status signal is valid, determining it as a braking energy recovery condition, and using a third charging current as the preset constant current charging current; wherein, the first charging current < the second charging current < the third charging current.
[0066] In this embodiment, during the constant current charging process, the preset constant current charging current is further dynamically adjusted according to the real-time driving status of the vehicle. The specific implementation method is as follows.
[0067] First, the engine speed, throttle opening, vehicle speed, and braking status signals of the vehicle containing the battery are acquired in real time via CAN communication. Engine speed and throttle opening are detected in real time by the EMS (Engine Management System) and broadcast via the CAN bus, reflecting the current engine load and the driver's acceleration intention. Vehicle speed can be provided by the anti-lock braking system or the vehicle controller. The braking status signal is a switch signal indicating whether the brake pedal is depressed; for example, the signal is valid when the brake pedal is depressed and invalid when it is released.
[0068] Secondly, the acquired engine speed is compared with a pre-calibrated preset speed threshold. The preset speed threshold is determined based on the engine's output power characteristics and load-carrying capacity at different speeds; for example, it can be set to a specific value 500-1000 rpm above idle speed, which is not limited in this application. When the engine speed is lower than the preset speed threshold, it indicates that the engine is operating at low speed, such as idling or low-speed driving. At this time, the engine's mechanical power output is limited. If a large charging current is used to charge the battery, it will significantly increase the engine load, potentially causing engine vibration or stalling. Therefore, in this embodiment, a first charging current is used as the preset constant current charging current under this condition. The value of this first charging current is relatively small, ensuring stable engine operation at low speeds while still maintaining a certain charging capacity.
[0069] When the engine speed exceeds the preset speed threshold, it indicates that the engine has entered its normal operating speed range and has sufficient power margin to drive the generator to charge the battery. At this point, it is necessary to further determine whether the vehicle is in regenerative braking mode. Specifically, this is determined by the braking status signal: if the braking status signal is invalid, i.e., the brake pedal is not depressed, the vehicle is determined to be in normal driving mode rather than regenerative braking mode. In this case, a second charging current is used as the preset constant current charging current. The value of the second charging current is greater than the first charging current, which is the rated constant current charging current, enabling a faster charging speed while ensuring stable engine operation.
[0070] When the engine speed exceeds a preset speed threshold, the vehicle speed exceeds a preset speed threshold, the throttle opening is zero, and the braking status signal is valid, these four conditions are simultaneously met, indicating that the vehicle is in regenerative braking mode. The preset speed threshold is used to eliminate false alarms when the vehicle is stationary or at extremely low speeds; it can be set to, but is not limited to, 10-20 km / h. A zero throttle opening means the driver has completely released the accelerator pedal; a valid braking status signal indicates the driver has depressed the brake pedal. Under these conditions, the motor switches from motor mode to generator mode, converting the vehicle's kinetic energy into electrical energy to feed back to the battery. At this time, a larger charging current is allowed to maximize the recovery of braking energy and improve the overall vehicle energy utilization rate. Therefore, this embodiment uses a third charging current as the preset constant current charging current, and the value of the third charging current is greater than the second charging current.
[0071] The specific values of the first, second, and third charging currents mentioned above are not fixed values, but rather adaptive values determined in advance through bench calibration tests based on the battery type, capacity, maximum allowable charging rate, and the vehicle's power hardware parameters (such as generator power and engine external characteristic curves), and stored in the control device's memory. Furthermore, they satisfy a stepped relationship of first charging current < second charging current < third charging current, such as the first charging current being 0.3C, the second charging current being 0.5C, and the third charging current being 0.7C. Of course, this application does not impose any limitations on this.
[0072] As a preferred embodiment, the method further includes: when it is detected that the motor of the vehicle where the battery is located has switched from motor operation to generator operation, recording the output port voltage at the switching moment as the initial charging reference voltage, and controlling the charging reference voltage to rise in a ramp manner based on the initial charging reference voltage with a preset slope, performing the step of calculating the difference between the charging reference voltage and the output port voltage, and inputting the result to the voltage loop PI controller for calculation to obtain the duty cycle adjustment amount; until the output port voltage is greater than the open circuit voltage, proceeding to the step of acquiring the engine speed, throttle opening, vehicle speed and braking status signals of the vehicle where the battery is located.
[0073] When the motor switches from motor operation (i.e., the battery discharges to drive the motor to output mechanical power) to generator operation (i.e., the motor is driven by the internal combustion engine or vehicle inertia to generate electricity to charge the battery), the operating state of the motor and the three-phase bridge circuit 21 changes drastically. At the moment the motor operation ends, the battery has just undergone a large current discharge, and the polarization voltage inside the cell has not yet dissipated. At this time, there is a significant deviation between the cell's open-circuit voltage and the theoretical open-circuit voltage obtained from a table based on SOC and average cell temperature. That is, the actual open-circuit voltage will be temporarily lower due to the polarization effect.
[0074] Therefore, in this embodiment, when the vehicle's motor, where the battery is located, is detected to be switching from electric motor mode to generator mode, the system temporarily enters a transition control mode. In this transition control mode, the voltage compensation output calculated by the current loop PI controller is forcibly set to zero, meaning the difference between the real-time charging current and the preset constant current charging current is not used for control adjustment, thus temporarily removing the current loop from its control function. This is to avoid unnecessary compensation output from the current loop in the initial stage after motor switching, due to unstable actual charging current or noise in the current feedback signal, and to prevent sudden changes in the duty cycle of the PWM pulse signal.
[0075] At the same time, the first charging current can be used as the current limit value of the transition control mode, but not limited to. That is, no matter how the voltage loop is adjusted, the actual output charging current will be limited to a range that does not exceed the first charging current.
[0076] In the voltage loop, the output port voltage of the three-phase bridge circuit 21 at the moment of motor switching is recorded. This voltage value is used as the initial value of the charging reference voltage, and then the charging reference voltage is controlled to rise gradually from this initial value with a preset slope. Since the initial charging reference voltage is equal to the output port voltage, the initial error of the voltage loop is zero, so the duty cycle of the PWM pulse signal will not change abruptly, and the system state remains continuous. As the charging reference voltage gradually increases with a preset slope, a positive error is generated between the charging reference voltage and the output port voltage. The voltage loop PI controller calculates the duty cycle adjustment based on this error, causing the PWM pulse width to gradually increase. The output power of the three-phase bridge circuit 21 increases accordingly, and the charging current begins to rise smoothly from zero or a very small value.
[0077] The aforementioned ramp-up process continues until the output port voltage exceeds the battery's open-circuit voltage obtained from the SOC-cell temperature-open-circuit voltage correspondence table under the current state. When the output port voltage exceeds the open-circuit voltage, it indicates that the charging reference voltage has reached the baseline value required to overcome the battery's electromotive force, and the influence of cell polarization has largely subsided. At this point, the system can safely exit the transition control mode. After exiting, the system resumes the normal control function of the current loop, that is, it recalculates the difference between the real-time charging current and the preset constant current charging current dynamically selected according to the driving state, obtains the charging voltage compensation amount through current loop PI calculation, and superimposes it with the open-circuit voltage and the composite feedforward compensation voltage to generate the charging reference voltage, and enters the normal constant current charging control process.
[0078] It should be noted that the preset slope can be, but is not limited to, a pre-calibrated rate of voltage change, such as a certain number of millivolts per millisecond. Its specific value is determined based on the voltage response characteristics of the battery, the system stability requirements, and the desired soft-start time, and can be obtained through bench testing.
[0079] As a preferred embodiment, before acquiring the open-circuit voltage of the battery and superimposing it with the charging voltage compensation, the method further includes: acquiring the real-time SOH and maximum cell voltage difference of the battery detected by the BMS; acquiring the battery health correction amount based on the real-time SOH, where the battery health correction amount is the difference between the open-circuit voltage of the battery under the real-time SOH and the open-circuit voltage of the battery when the SOH is 100%; acquiring the cell consistency correction amount of each cell in the battery based on the maximum cell voltage difference, where the cell consistency correction amount is the difference between the open-circuit voltage estimated by the average voltage method under the voltage difference state and the measured open-circuit voltage under the balanced state; multiplying the cell consistency correction amount by the total number of cells connected in series in the battery to obtain the product, and adding the obtained product to the battery health correction amount to obtain the composite feedforward compensation voltage; and superimposing the composite feedforward compensation voltage, the open-circuit voltage, and the charging voltage compensation amount to obtain the charging reference voltage.
[0080] In this embodiment, the real-time State of Harm (SOH) and maximum cell voltage difference of the battery, monitored in real time by the BMS, are obtained via CAN communication. SOH is an indicator of the battery's aging degree, expressed as a percentage of the current usable capacity to the nominal capacity. For example, an SOH of 90% means the battery capacity has decayed to 90% of that of a new battery. SOH is estimated by the BMS based on the battery cycle count, capacity decay curve, and internal resistance changes, and is transmitted externally via the CAN bus. Maximum cell voltage difference refers to the voltage difference between the highest-voltage and lowest-voltage cells in the battery pack, reflecting the consistency between the cells. Maximum cell voltage difference is also monitored and reported by the BMS in real time. For example, in a well-balanced lithium iron phosphate battery pack, the maximum cell voltage difference is less than 30mV, while in an aged or unbalanced pack, it may reach 50mV or even higher.
[0081] Secondly, the battery health correction is obtained based on the real-time SOH. The physical meaning of the battery health correction is that as the battery ages, the SOH decreases. Even under the same SOC and temperature conditions, the actual open-circuit voltage of the battery will be lower than that of a brand-new battery, i.e., the open-circuit voltage when SOH = 100%. This phenomenon is caused by irreversible chemical changes such as electrode material aging and loss of active materials. The battery health correction is precisely this voltage decrease. Its calibration method is as follows: battery samples with different SOHs are obtained through accelerated aging experiments. Their open-circuit voltages are measured under the same SOC (e.g., 50%) and temperature (e.g., 25°C). The difference between the open-circuit voltage at the current real-time SOH and the open-circuit voltage at SOH = 100% is calculated, thus generating the SOH-battery health correction relationship. Since aging only leads to a decrease in open-circuit voltage, not an increase, the battery health correction is always zero or negative. In practical use, the real-time SOH reported by the BMS is used as input, and the corresponding battery health correction amount can be obtained by looking up a table or interpolating based on the correspondence between SOH and battery health correction amount.
[0082] Next, the cell consistency correction amount for each cell in the battery is obtained based on the maximum cell voltage difference. The physical significance of the cell consistency correction amount lies in the fact that when there are voltage inconsistencies among the cells within the battery pack, simply using the average voltage of all cells to estimate the open-circuit voltage of the entire pack will result in a certain deviation. This is because there is a non-linear relationship between open-circuit voltage and SOC (State of Charge), and the results of averaging and then looking up the table are not equal to those of looking up the table first and then averaging. The calibration method for the cell consistency correction amount is as follows: Select a battery pack and artificially create different cell voltage differences (e.g., maximum voltage differences of 30mV, 50mV, 100mV, etc.) by charging and discharging individual cells separately. Under each voltage difference condition, the battery pack is allowed to stand for a sufficient period to eliminate polarization effects, allowing the terminal voltage of each cell to return to the open-circuit voltage state. Then, two methods were used to obtain the open-circuit voltage of the entire battery pack: the first method was the average voltage method, which involved measuring the open-circuit voltage of each cell, calculating the average of all cell open-circuit voltages, and then multiplying it by the total number of cells connected in series to obtain an estimated value of the open-circuit voltage of the entire pack; the second method was the direct measurement method, which involved directly measuring the voltage across the positive and negative terminals of the battery pack using a voltage acquisition module to obtain the true value of the open-circuit voltage of the entire pack. The estimated value was subtracted from the true value and then divided by the total number of cells connected in series to obtain the single-cell consistency correction amount under that voltage difference condition. Experiments showed that when there is a voltage difference between cells, the average voltage method often overestimates the open-circuit voltage of the entire pack, i.e., the estimated value is greater than the true value. Therefore, the cell consistency correction amount is negative, and the larger the voltage difference, the larger the absolute value of the cell consistency correction amount. When the maximum voltage difference between cells is less than the preset uncompensated voltage difference threshold, such as 30mV, the influence of the voltage difference on the open-circuit voltage estimation is considered negligible. At this time, both the cell consistency correction amount and the battery health correction amount are zero. Of course, this application does not limit this. In practical applications, the correspondence between the maximum cell voltage difference and the cell consistency correction amount can be generated based on the above calibration method. The current maximum cell voltage difference reported by the BMS can be obtained through CAN communication. Using the maximum cell voltage difference as input, the corresponding cell consistency correction amount can be obtained by looking up a table or interpolating based on the correspondence between the maximum cell voltage difference and the cell consistency correction amount.
[0083] Then, the cell consistency correction obtained above is multiplied by the total number of cells connected in series in the battery pack, i.e., the number of cells connected in series in the battery pack, and then added to the battery health correction to obtain the composite feedforward compensation voltage.
[0084] Finally, the calculated composite feedforward compensation voltage is added together with the battery open-circuit voltage obtained in the previous steps (i.e., the basic open-circuit voltage obtained by looking up the SOC-cell temperature-open-circuit voltage relationship table) and the charging voltage compensation amount obtained by the current loop PI calculation to obtain the final charging reference voltage. That is, charging reference voltage = basic open-circuit voltage + charging voltage compensation amount + composite feedforward compensation voltage.
[0085] As a preferred embodiment, the method further includes: reducing the preset constant current charging current when the maximum voltage difference of the battery cell is greater than the preset maximum voltage difference.
[0086] When a battery pack is used for a long time or when there are differences in the characteristics of the cells themselves, the maximum voltage difference of the cells will gradually increase. If no intervention is taken, high-voltage cells may degrade prematurely due to continuous exposure to large charging current, or even become overcharged. Low-voltage cells may be undercharged, further exacerbating the inconsistency.
[0087] In this embodiment, a preset maximum voltage difference is pre-set in the memory. The determination of the preset maximum voltage difference may be based on, but is not limited to, the battery cell material system (such as ternary lithium battery or lithium iron phosphate battery), the number of cells connected in series, and the safety usage specifications of the battery pack. For example, for a lithium iron phosphate battery pack, since the voltage change in its mid-section SOC plateau region is gradual, the preset maximum voltage difference can be set to 50mV; for ternary lithium batteries, whose voltage is more sensitive to SOC, the preset maximum voltage difference can be set to 30mV for more stringent consistency control. Of course, this application does not limit this.
[0088] During constant current charging, the processor compares the acquired maximum cell voltage difference with the preset maximum voltage difference in real time. When the maximum cell voltage difference is less than or equal to the preset maximum voltage difference, the cell consistency within the battery pack is considered acceptable, and the charging process proceeds normally according to the currently set preset constant current charging current. However, if the maximum cell voltage difference is detected to be greater than the preset maximum voltage difference, it is determined that there is a risk of severe cell voltage inconsistency in the battery pack. At this time, the system automatically executes current limiting protection: reducing the current preset constant current charging current to a safe value. The reduction can be done by adjusting it by a fixed percentage, such as reducing it to 50% or 80% of the current preset constant current charging current, or by directly switching to a pre-calibrated lower charging current level, such as the first charging current.
[0089] When the maximum voltage difference of the battery cell gradually improves and falls back below the preset maximum voltage difference after reducing the preset constant current charging current, the system can restore the preset constant current charging current to its original value. The restoration process can be implemented in a ramp manner or a direct step manner, depending on the battery management strategy.
[0090] The following is a specific embodiment for illustration.
[0091] Please refer to Figure 2 , Figure 2 This is a control block diagram of a battery charging method provided in this application. Figure 2 In this context, M stands for motor.
[0092] 1. Based on sampling period The real-time charging current after anti-interference processing is 10ms. and the output port voltage of the three-phase bridge circuit 21 Discretization is performed to obtain the corresponding discretized data. and k represents the discrete-time index; 2. Determine the battery health correction amount based on the battery health status (SOH) and the maximum cell voltage difference. Cell consistency correction amount for single cell Combined with the number of cells in series 'a' within the battery, the overall cell consistency correction amount for the battery. Composite feedforward compensation voltage .
[0093] 3. Based on the SOC and average cell temperature T, and using the pre-calibrated table of SOC-cell temperature-open circuit voltage correspondence, find the single-cell open circuit voltage that matches the current state. The open-circuit voltage of the battery .
[0094] 4. The current loop PI controller sets the preset constant current charging current. and The difference is used to perform a current loop PI calculation to obtain the charging voltage compensation amount ΔU(k). The expression for ΔU(k) is as follows: .
[0095] In the formula, It is the current error of the charging current at time k. Let be the current error of the charging current at time j. These are the initial current loop proportional parameters for the current loop PI controller. These are the initial current loop integral parameters for the current loop PI controller. The sampling period can be 10ms.
[0096] 5. Check the open-circuit voltage of the battery. The charging voltage compensation amount ΔU(k) obtained from the current loop operation and the composite feedforward compensation voltage By superimposing the values, a discretized charging reference voltage is obtained. for: .
[0097] Discretized charging reference voltage This represents the actual charging reference voltage after correction for SOH and maximum cell differential voltage.
[0098] 6. Voltage loop PI controller for and The difference is used to perform voltage loop PI calculation to obtain the duty cycle adjustment D(k): ; In the formula, , is the voltage error of the output port voltage at time k. Let be the voltage error of the output port voltage at time j. These are the initial voltage loop proportional parameters for the voltage loop PI controller. These are the initial voltage loop integral parameters for the voltage loop PI controller.
[0099] The aforementioned charging method, also known as the constant current charging control method, uses the current loop as the outer loop and the voltage loop as the inner loop, which differs from traditional lithium battery charging methods. Because the current loop is on the outer loop, the control objective is a constant current charging current. Even if the SOC (State of Charge) of a hybrid vehicle accumulates during driving, leading to an increase in open-circuit voltage... The calculation is inaccurate; the charging reference voltage... The initial value fluctuates, but during driving, the processor will sample the actual charging current from the BMS at a 10ms sampling period. Through the current loop PI calculation of the current loop PI controller, the charging reference voltage is dynamically corrected in real time: if the SOC error causes the real-time charging current to be too low, It will output positive compensation, increasing the charging reference voltage and increasing the charging current; if the SOC error causes the real-time charging current to be too high, It will output negative compensation, reduce the charging reference voltage, and reduce the charging current.
[0100] The duty cycle adjustment value D(k) is input to the PWM conversion module, which controls the PWM conversion module to modulate the pulse width of the PWM pulse signal according to the duty cycle adjustment value D(k). The adjusted PWM pulse signal is then input to the three-phase bridge circuit 21. By controlling the on and off times of the MOSFETs in the three-phase bridge circuit 21, the charging current output to the battery is adjusted.
[0101] It should be noted that, for example, for a ternary lithium battery for a hybrid vehicle with 14 series-2 parallel configurations, a nominal voltage of 51.8V, and a rated capacity of 4.9Ah, the preset maximum charging voltage can be set to 56.3V, at which point the battery's SOC is approximately 83%. Ternary lithium batteries exhibit polarization effects when the SOC exceeds 80%, thus reducing the proportional parameters of the voltage loop PI controller. The initial voltage loop proportional parameter is set to 50%-70% to reduce the instability of the voltage control loop caused by battery polarization under high SOC, which can easily trigger BMS overvoltage alarms.
[0102] For a 14-cell lithium iron phosphate battery in a hybrid vehicle with a nominal voltage of 51.2V and a rated capacity of 3Ah, the preset maximum charging voltage can be set to 56.2V, at which point the state of charge (SOC) is 100%. The purpose of setting this voltage is to fully charge the lithium iron phosphate battery so that the battery management system (BMS) can perform SOC calibration. The polarization effect of lithium iron phosphate is most pronounced during the full charge phase, and the proportional parameters of the voltage loop PI controller should also be actively adjusted. The initial voltage loop proportional parameter is set to 50%-70% to reduce excessive loop regulation and significant voltage swing, which could affect SOC calibration.
[0103] Please refer to Figure 3 , Figure 3 This application provides a schematic diagram of a battery charging system. The system includes: a first acquisition unit 31 for acquiring the real-time charging current of the battery detected by the BMS; a second acquisition unit 32 for acquiring the output port voltage of the three-phase bridge circuit 21; a first calculation unit 33 for calculating the difference between the real-time charging current and a preset constant current charging current, and obtaining a charging voltage compensation amount through a current loop PI operation; a third acquisition unit 34 for acquiring the open-circuit voltage of the battery, and superimposing the open-circuit voltage with the charging voltage compensation amount to obtain a charging reference voltage; a second calculation unit 35 for calculating the difference between the charging reference voltage and the output port voltage, and obtaining a duty cycle adjustment amount through a voltage loop PI operation; and a control unit 36 for modulating a PWM pulse signal according to the duty cycle adjustment amount to control the three-phase bridge circuit 21 to adjust the charging current output to the battery.
[0104] For a description of the battery charging system provided by the present invention, please refer to the above method embodiments; the present invention will not be described again here.
[0105] Please refer to Figure 4 , Figure 4 This is a schematic diagram of a battery charging device provided in this application. The device includes: a memory 41 for storing a computer program; and a processor 42 for implementing the battery charging method steps described above when executing the computer program.
[0106] For a description of the battery charging device provided by the present invention, please refer to the above method embodiments; the present invention will not be described again here.
[0107] Please refer to Figure 5 , Figure 5 This is a schematic diagram of the structure of a computer-readable storage medium provided in this application. The computer-readable storage medium 51 stores a computer program 52, which, when executed by the processor 42, implements the steps of the battery charging method described above.
[0108] For a description of the computer-readable storage medium provided by the present invention, please refer to the above method embodiments; the present invention will not be described again here.
[0109] It should also be noted that, in this specification, 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.
[0110] The above description of the disclosed embodiments enables those skilled in the art to make or use the invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the invention. Therefore, the invention is not to be limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A method for charging a storage battery, characterized in that, include: Obtain the real-time charging current of the battery detected by the BMS; Obtain the output port voltage of the three-phase bridge circuit; The difference between the real-time charging current and the preset constant current charging current is calculated, and the result is input to the current loop PI controller for calculation to obtain the charging voltage compensation amount. Obtain the open-circuit voltage of the battery, and add the open-circuit voltage to the charging voltage compensation amount to obtain the charging reference voltage; The difference between the charging reference voltage and the output port voltage is calculated, and the result is input to the voltage loop PI controller for calculation to obtain the duty cycle adjustment amount; The PWM pulse signal is modulated according to the duty cycle adjustment amount to control the three-phase bridge circuit to adjust the charging current output to the battery; Before acquiring the open-circuit voltage of the battery and superimposing the open-circuit voltage with the charging voltage compensation amount, the method further includes: Obtain the real-time SOH and maximum cell voltage difference of the battery detected by the BMS; The battery health correction amount is obtained based on the real-time SOH. The battery health correction amount is the difference between the open circuit voltage of the battery under the real-time SOH and the open circuit voltage of the battery when SOH is 100%. The cell consistency correction amount of each cell in the battery is obtained based on the maximum voltage difference of the cell. The cell consistency correction amount is the difference between the open circuit voltage estimated by the average voltage method under the voltage difference state and the measured open circuit voltage under the balanced state. The cell consistency correction is multiplied by the total number of cells connected in series in the battery to obtain the product, and the product is added to the battery health correction to obtain the composite feedforward compensation voltage. The charging reference voltage is obtained by superimposing the composite feedforward compensation voltage, the open-circuit voltage, and the charging voltage compensation amount.
2. The charging method for a storage battery as described in claim 1, characterized in that, Obtaining the open-circuit voltage of the battery includes: Obtain the SOC and average cell temperature of the battery as detected by the BMS; Based on the SOC and the average cell temperature, the open circuit voltage is determined by querying a pre-calibrated SOC-cell temperature-open circuit voltage correspondence table.
3. The charging method for a storage battery as described in claim 1, characterized in that, Obtain the real-time charging current of the battery detected by the BMS, including: The detection data packet of the BMS is obtained through CAN communication, and the detection data packet includes the real-time charging current of the battery. Perform cyclic redundancy check on the detected data packet; If the verification passes, the real-time charging current in the detection data packet is stored in the memory, and the real-time charging current is smoothed by a sliding window filter. If the verification fails, the real-time charging current stored in the memory in the previous sampling period is used as the real-time charging current in the current sampling period. When the detection data packet is not received for several consecutive sampling cycles, the current open circuit voltage is determined, the current open circuit voltage is superimposed with a preset voltage compensation amount, the difference between the superimposed sum and the output port voltage is calculated, and the result is input to the voltage loop PI controller for calculation to obtain the duty cycle adjustment amount. Then, the step of modulating the PWM pulse signal according to the duty cycle adjustment amount to control the three-phase bridge circuit to adjust the charging current output to the battery is entered.
4. The charging method for a storage battery as described in claim 1, characterized in that, Also includes: Obtain the real-time terminal voltage of the battery; When the real-time terminal voltage reaches the preset maximum charging voltage and remains so for a preset duration, the charging voltage compensation is gradually reduced to zero. At the same time, the charging reference voltage is transitioned to the preset full charging voltage. Then, the difference between the charging reference voltage and the output port voltage is calculated, and the result is input to the voltage loop PI controller for calculation to obtain the duty cycle adjustment amount.
5. The charging method for a storage battery as described in claim 4, characterized in that, After transitioning the charging reference voltage to a preset full-charge voltage, the method further includes: The voltage loop proportional parameter in the voltage loop PI controller is reduced to a preset ratio of the initial voltage loop proportional parameter.
6. The charging method for a storage battery as described in claim 1, characterized in that, Also includes: Acquire the engine speed, throttle opening, vehicle speed, and braking status signals of the vehicle where the battery is located; When the engine speed is less than a preset speed threshold, the first charging current is used as the preset constant current charging current. When the engine speed is greater than the preset speed threshold and the braking status signal is invalid, the second charging current is used as the preset constant current charging current. When the engine speed is greater than the preset speed threshold, the vehicle speed is greater than the preset vehicle speed threshold, the throttle opening is zero and the braking status signal is valid, it is determined to be a braking energy recovery condition, and the third charging current is used as the preset constant current charging current. Wherein, the first charging current < the second charging current < the third charging current.
7. The charging method for a storage battery as described in claim 6, characterized in that, Also includes: When it is detected that the motor of the vehicle where the battery is located has switched from motor mode to generator mode, the output port voltage at the switching moment is recorded as the initial charging reference voltage, and the charging reference voltage is controlled to rise in a ramp manner based on the initial charging reference voltage with a preset slope. The difference between the charging reference voltage and the output port voltage is calculated, and the result is input to the voltage loop PI controller for calculation to obtain the duty cycle adjustment amount. Once the output port voltage is greater than the open circuit voltage, the process proceeds to the step of acquiring the engine speed, throttle opening, vehicle speed, and braking status signals of the vehicle where the battery is located.
8. The charging method for a storage battery as described in claim 1, characterized in that, Also includes: When the maximum voltage difference of the battery cell is greater than the preset maximum voltage difference, the preset constant current charging current is reduced.
9. A charging device for a storage battery, characterized in that, include: Memory, used to store computer programs; A processor, configured to, when executing a computer program, implement the steps of the charging method for a battery as described in any one of claims 1-8.
Citation Information
Patent Citations
Constant-power charging control method and electronic equipment
CN121923331A
Vehicle system
JP2015150918A