Battery simulation method and system for testing battery protection board, and medium
By setting voltage parameters and generating PWM signals, combined with real-time acquisition and feedback, high-precision simulation and detection of the battery protection board is achieved, which solves the problem of difficult to simulate the battery charging and discharging process and evaluating the protection function in the existing technology, and improves the test Reliability and automation.
Patent Information
- Application Number
- CN202411075295.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-07
- Publication Date
- 2024-11-08
AI Technical Summary
The existing battery protection board testing methods are difficult to accurately simulate the charging and discharging process of multiple batteries, lack real-time monitoring and automatic calibration functions, and cannot fully evaluate the protection functions, especially in extreme conditions.
A battery simulation method for battery protection board testing is provided. By setting voltage parameters, generating PWM signals, real-time acquisition and feedback, adjusting output voltage, combining preset test schemes and pulse current output, the battery simulation and protection parameters are realized.
It realizes high-precision simulation and comprehensive inspection of the battery protection plate, improves the reliability and automation of the test results, reduces human errors, and ensures the accuracy and consistency of the test.
Smart Images

Figure CN118914622A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of battery protection, and in particular to a battery simulation method, system and medium for testing a battery protection board. Background Art
[0002] With the rapid development of electric vehicles and portable electronic devices, battery protection boards play a vital role in ensuring battery safety and extending battery life. However, traditional battery protection board testing methods have many limitations. First, using actual batteries for testing is not only costly, but also difficult to accurately control the battery state and cannot fully simulate various working conditions. Secondly, existing battery simulators can often only provide a fixed voltage output, which makes it difficult to accurately simulate the dynamic voltage changes of the battery during the charging and discharging process. In addition, most test equipment lacks real-time monitoring and automatic calibration functions, making it difficult to ensure the accuracy and reliability of the test results. Finally, existing test methods are generally unable to fully evaluate the various protection functions of the battery protection board, especially the performance under extreme conditions. Therefore, there is an urgent need for a battery protection board testing method that can accurately simulate the charging and discharging process of multiple batteries, realize real-time monitoring and automatic calibration, and comprehensively evaluate the protection function. Summary of the invention
[0003] The present invention provides a battery simulation method, system and medium for testing a battery protection board to solve the technical problem that it is difficult to accurately simulate the charging and discharging process of multiple batteries in the existing battery protection board test.
[0004] The technical solution of the present invention to solve the above technical problems is as follows:
[0005] In one aspect, a battery simulation method for testing a battery protection board is provided, the battery simulation method comprising the following steps:
[0006] Set the output voltage parameters of each battery module, the voltage setting range is 1.5V to 4.5V;
[0007] The setting curve is input into the host computer, and the corresponding PWM signal is generated in the simulator to achieve the change of output voltage;
[0008] Collect the actual output voltage value of each battery module and feed it back to the host computer;
[0009] Compare the actual output voltage value with the set output voltage parameters and adjust the PWM signal to calibrate the output;
[0010] According to the preset test plan, the simulator is controlled to output a changing voltage value to simulate the charging and discharging process of the battery module;
[0011] Detect the protection parameters of the battery protection board and compare the detection results with the preset values;
[0012] If the test results are inconsistent, an alarm signal is generated and the abnormal situation is recorded. The test results and abnormal situation are transmitted to the host computer, and a test file is established for each battery protection board.
[0013] Furthermore, the method for setting the output voltage parameters of each battery module includes the following steps:
[0014] Determine a reference voltage Vbase;
[0015] Set the voltage fluctuation amplitude ΔV;
[0016] Set the fluctuation period T;
[0017] Assign a phase offset φi to each battery module;
[0018] The output voltage parameters of each battery module are calculated according to the following formula:
[0019] Wherein, Vset(i) is the set voltage of the i-th battery module, and t is the time.
[0020] Furthermore, the method of generating the corresponding PWM signal in the simulator comprises the following steps:
[0021] Calculate the PWM duty cycle according to the value of the set output voltage parameter;
[0022] Generate a PWM waveform of corresponding frequency;
[0023] Convert the PWM waveform into an analog voltage through low-pass filtering;
[0024] Use an operational amplifier to buffer and amplify the analog voltage.
[0025] Furthermore, the battery simulation method further comprises the following steps:
[0026] Detect the total voltage output value of the simulator;
[0027] Sampling the voltage of the battery module;
[0028] Calculate the total voltage using the following formula:
[0029] V total =∑(V actual (i))-V loss , where Vtotal is the total voltage, Vactual(i) is the actual voltage of the ith single cell, and Vloss is the system loss voltage.
[0030] Furthermore, the method of inputting the setting curve through the host computer includes the following steps:
[0031] Select a predefined charge and discharge curve template;
[0032] Set the charge and discharge rate and depth;
[0033] Generate time-voltage data points based on the selected template and parameters;
[0034] Use interpolation algorithm to generate continuous voltage change curve;
[0035] Send the curve data to the simulator for execution.
[0036] Furthermore, the battery simulation method also includes outputting a pulse current of no more than 1s through the simulator to test the overcurrent protection function of the battery protection board. The pulse current output method is:
[0037] Set the maximum current value Imax;
[0038] Set the pulse duration Tpulse;
[0039] Set the rise time constant τ;
[0040] The current output is controlled according to the following formula:
[0041] Where Ipulse(t) is the pulse current, u(t) is the unit step function, and Tpulse is the pulse duration.
[0042] Furthermore, the magnitude and duration of the pulse current can be set by the host computer, and the setting method includes the following steps:
[0043] A pulse current parameter setting area is provided on the software interface of the host computer;
[0044] Input the maximum current value Imax, pulse duration Tpulse and rise time constant τ;
[0045] Verify the validity of input parameters;
[0046] Pass the validated input parameters to the simulator.
[0047] Furthermore, the protection parameters include overcharge protection, over-discharge protection, overcurrent protection and short circuit protection. The method for detecting the protection parameters of the battery protection board includes the following steps:
[0048] Gradually adjust the output of the simulator to make the voltage or current close to the protection threshold;
[0049] Record the voltage or current value when the protection is triggered;
[0050] Calculate the deviation between the actual protection parameter and the set value.
[0051] On the other hand, a battery simulation system for testing a battery protection board is provided, the battery simulation system comprising:
[0052] 24 independent battery simulation power modules, connected in series;
[0053] Simulator, used to output single cell voltage and detect actual output voltage value;
[0054] The host computer is used to display and set the output voltage of each battery module and control the operation of the simulator through software;
[0055] Communication interface, including Bluetooth interface, CAN bus interface, RS485 interface;
[0056] High-performance MCU, used to communicate with the host computer and control the output of the battery simulation power module;
[0057] The pulse current output module can set the size and duration of the pulse current and output a pulse current not exceeding 1s;
[0058] The total voltage detection module is used to detect the total voltage of the simulator and feed back the data to the host computer;
[0059] The power module uses a 12V or 24V power supply to power the entire system.
[0060] On the other hand, a computer-readable storage medium is provided, on which a computer program is stored, and when the program is executed by a processor, the battery simulation method for testing a battery protection board as described above is implemented.
[0061] The beneficial effects of the present invention are:
[0062] The battery simulation method for testing a battery protection board provided by the present invention sets the single cell voltage of 1 to 24 batteries by adopting a high-precision voltage setting and real-time adjustment mechanism, covering a wide range of 1.5V to 4.5V, and meeting the simulation requirements of different types of batteries. By inputting the setting curve and generating the corresponding PWM signal through the host computer software, the dynamic and precise adjustment of the voltage is realized, and the voltage change characteristics of the battery during the charging and discharging process are effectively simulated. The real-time acquisition and feedback mechanism ensures the high accuracy of the simulation process. By comparing the actual output voltage with the set value and adjusting the PWM signal in time, closed-loop control is realized, and the simulation accuracy is significantly improved. The simulator output is controlled according to the preset test scheme, so that the test process is closer to the actual battery working state and the reliability of the test results is improved. In addition, the method can comprehensively detect various protection parameters of the battery protection board, and timely discover potential problems through automatic alarm and abnormal recording functions. Finally, by establishing a detailed detection file, it provides strong support for product quality control and continuous improvement, while improving the automation of the test, reducing human errors, and ensuring the accuracy and consistency of the test. BRIEF DESCRIPTION OF THE DRAWINGS
[0063] Figure 1 A flowchart of a battery simulation method according to an embodiment of the present invention;
[0064] Figure 2 is a flow chart of a method for setting output voltage parameters in one embodiment of the present invention;
[0065] Figure 3 A flowchart of a method for generating a corresponding PWM signal in one embodiment of the present invention;
[0066] Figure 4 is a flow chart of a voltage sampling method in one embodiment of the present invention;
[0067] Figure 5 A flow chart of a method for inputting a setting curve in one embodiment of the present invention;
[0068] Figure 6 A flow chart of a pulse current output method according to an embodiment of the present invention;
[0069] Figure 7 is a flow chart of a pulse current setting method in one embodiment of the present invention;
[0070] Figure 8 A flowchart of detecting protection parameters of a battery protection board in one embodiment of the present invention;
[0071] Fig. 9 FIG. 4 is a block diagram of a battery simulation system according to an embodiment of the present invention. DETAILED DESCRIPTION
[0072] In order to make the purpose, technical scheme and advantages of the present invention clearer, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. Examples of embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements with the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, and cannot be construed as limiting the present invention. In addition, it should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0073] The disclosure below provides many different embodiments or examples for implementing different structures of the present invention. In order to simplify the disclosure of the present invention, the components and settings of specific examples are described below. Of course, they are merely examples and are not intended to limit the present invention. In addition, the present invention may repeat reference numbers and / or reference letters in different examples, and such repetition is for the purpose of simplicity and clarity, and does not itself indicate the relationship between the various embodiments and / or settings discussed. In addition, the present invention provides examples of various specific brands, models and series, but those of ordinary skill in the art may be aware of the use scenarios of other brands, models and series.
[0074] The present invention provides the following preferred embodiments:
[0075] Embodiment 1
[0076] In order to solve the problem that existing battery protection board test equipment is difficult to accurately simulate the charging and discharging process of multiple batteries, this embodiment proposes a battery simulation method for battery protection board testing. The method adopts high-precision voltage setting and real-time adjustment mechanism to ensure the accuracy of the simulation process.
[0077] like Figure 1 As shown, the battery simulation method includes the following steps:
[0078] S101, setting the output voltage parameters of each battery module, with the voltage setting range being 1.5V to 4.5V.
[0079] S102, inputting a setting curve through the host computer, generating a corresponding PWM signal in the simulator to achieve a change in the output voltage.
[0080] S103, collecting the actual output voltage value of each battery module and feeding it back to the host computer.
[0081] S104: Compare the actual output voltage value with the set output voltage parameter, and adjust the PWM signal to calibrate the output.
[0082] S105 . According to a preset test scheme, control the simulator to output a changing voltage value to simulate the charge and discharge process of the battery module.
[0083] S106: Detect protection parameters of the battery protection board, and compare the detection result with the preset value.
[0084] S107. If the test results are inconsistent, an alarm signal is generated and the abnormal situation is recorded, the test results and the abnormal situation are transmitted to the host computer, and a test file is established for each battery protection board.
[0085] Specifically, this embodiment firstly realizes accurate simulation of 1 to 24 batteries by setting the output voltage parameters of each battery module. The voltage setting range is 1.5V to 4.5V, covering the operating voltage range of common lithium batteries. This flexible setting method enables the simulator to adapt to different types and quantities of battery combinations.
[0086] Furthermore, in this embodiment, the setting curve is input through the host computer software, and the corresponding PWM signal is generated inside the simulator. This method can realize the dynamic change of the output voltage, thereby accurately simulating the voltage change characteristics of the battery during the charging and discharging process. The use of PWM signals not only improves the accuracy of voltage regulation, but also enhances the response speed of the system.
[0087] It should be understood that this embodiment also includes the step of collecting the actual output voltage value of each battery module and feeding it back to the host computer. This real-time monitoring mechanism ensures the accuracy of the simulation process. By comparing the actual output voltage value with the set output voltage parameter, the system can adjust the PWM signal in time to calibrate the output, thereby achieving closed-loop control and improving simulation accuracy.
[0088] It is understandable that this embodiment controls the simulator to output a changing voltage value according to a preset test scheme to simulate the charging and discharging process of the battery module. This method makes the test process closer to the actual working state of the battery and improves the reliability and practicality of the test results.
[0089] Furthermore, the protection parameters of the battery protection board are detected and the detection results are compared with the preset values. When the detection results are inconsistent, the system will generate an alarm signal and record the abnormal situation. This design can not only detect potential problems of the battery protection board in time, but also provide detailed data support for subsequent analysis and improvement.
[0090] The benefit of this embodiment is that by transmitting the test results and abnormal conditions to the host computer and establishing a test file for each battery protection board, the test process is fully recorded and traced. This method not only improves the reliability and efficiency of the test, but also provides strong support for product quality control and continuous improvement. At the same time, this automated testing and recording method greatly reduces human errors and improves the accuracy of the test.
[0091] Embodiment 2
[0092] In order to solve the problem that the existing battery simulator is difficult to accurately simulate the dynamic change of the single cell voltage, this embodiment further optimizes the setting method of the battery module output voltage parameters. This method achieves accurate control and dynamic adjustment of the voltage of each battery module by introducing parameters such as reference voltage, fluctuation amplitude, cycle and phase offset.
[0093] like Figure 2 As shown, the method for setting the output voltage parameters of each battery module includes the following steps:
[0094] S201 : Determine a reference voltage Vbase.
[0095] S202, setting the voltage fluctuation amplitude ΔV.
[0096] S203, setting the fluctuation period T.
[0097] S204: Allocate a phase offset φi to each battery module.
[0098] S205. Calculate the output voltage parameter of each battery module according to the following formula:
[0099] Wherein, Vset(i) is the set voltage of the i-th battery module, and t is the time.
[0100] Specifically, this embodiment first determines a reference voltage Vbase, which is usually set to the nominal voltage of the battery type to be simulated. For example, for a lithium-ion battery, Vbase may be set to 3.7V. Next, a voltage fluctuation amplitude ΔV is set, which determines the range of the simulated battery voltage change. The selection of the fluctuation amplitude needs to take into account the voltage change characteristics of the actual battery during the charging and discharging process, and can usually be set between 0.1V and 0.5V.
[0101] Furthermore, this embodiment sets a fluctuation period T, which simulates the time scale of the battery voltage change. The selection of period T needs to be determined according to the actual test requirements, which can range from a few seconds to a few hours. In order to better simulate the differences between each single cell in the battery pack, this method assigns a unique phase offset φi to each battery module. This design makes the voltage changes of each simulated battery show a certain degree of randomness and asynchrony, which is closer to the working state of the real battery pack.
[0102] It should be understood that this embodiment uses a mathematical formula to calculate the output voltage parameters of each battery module. This formula comprehensively considers the reference voltage, fluctuation amplitude, time factor and phase offset of each module to generate a voltage curve that changes over time. The sine function part of the formula simulates the periodic change of the battery voltage, while the phase offset φi ensures that each module has a slightly different change pattern.
[0103] It is understandable that this parameterized setting method not only improves the accuracy of voltage simulation, but also enhances the flexibility of the system. By adjusting these parameters, the characteristics of batteries of different types and working conditions can be easily simulated. For example, by increasing ΔV, the large voltage fluctuations of aging batteries can be simulated, while shortening the period T can simulate fast charging and discharging scenarios.
[0104] The benefit of this embodiment is that by introducing this complex voltage parameter setting method, a highly realistic simulation of the battery module charging and discharging process is achieved. This not only improves the accuracy and comprehensiveness of the battery protection board test, but also provides a powerful tool for studying the performance of the battery management system under various complex working conditions. At the same time, the parameterized characteristics of this method make the test process more controllable and repeatable, providing reliable technical support for the performance evaluation and quality control of the battery protection board.
[0105] Embodiment 3
[0106] In order to solve the accuracy and stability problems of traditional simulators when generating accurate voltage output, this embodiment further optimizes the method for generating PWM signals inside the simulator. This method achieves high-precision, low-noise voltage output control through a series of precise digital and analog signal processing technologies.
[0107] like Figure 3 As shown, the method for generating the corresponding PWM signal in the simulator includes the following steps:
[0108] S301 , calculating a PWM duty cycle according to a set value of an output voltage parameter.
[0109] S302: Generate a PWM waveform of corresponding frequency.
[0110] S303 , convert the PWM waveform into an analog voltage through low-pass filtering.
[0111] S304: Use an operational amplifier to buffer and amplify the analog voltage.
[0112] Specifically, the present embodiment first calculates the PWM duty cycle according to the set output voltage parameter value. This step involves complex mathematical operations, and factors such as the power supply voltage, the target output voltage, and the PWM resolution need to be considered. For example, the duty cycle D can be calculated using the formula D = Vout / Vsupp ly * 100%, where Vout is the target output voltage and Vsupp ly is the power supply voltage. In order to improve accuracy, a 16-bit or higher digit PWM counter can be used, which can achieve more subtle voltage regulation.
[0113] Furthermore, the method generates a PWM waveform of a corresponding frequency. The selection of frequency needs to strike a balance between suppressing ripple and reducing switching losses. Generally, selecting a frequency above 20kHz can effectively reduce audible noise while maintaining low switching losses. In practical applications, high-performance timer peripherals can be used to generate accurate PWM waveforms, such as the advanced timers of the STM32 series MCUs, which have high resolution and multi-channel output capabilities.
[0114] It is important to understand that the direct output of a PWM signal is not suitable as an accurate voltage source. Therefore, this method uses low-pass filtering to convert the PWM waveform into an analog voltage. The design of the filter circuit needs to consider factors such as the PWM frequency, target ripple factor, and response speed. A typical RC low-pass filter may not be sufficient to meet high-precision requirements, so consider using a multi-stage LC filter or an active filter to further improve the signal quality.
[0115] It is understandable that in order to ensure the stability and driving capability of the output voltage, this method finally uses an operational amplifier to buffer and amplify the filtered analog voltage. When selecting an operational amplifier, parameters such as bandwidth, slew rate, and input bias current need to be considered. For example, the OPA series precision operational amplifiers from Texas Instruments can be used. They have characteristics such as low noise, low offset voltage, and high open-loop gain, which are very suitable for such applications.
[0116] The benefit of this embodiment is that by adopting this sophisticated PWM signal generation and processing method, not only the accuracy and stability of the simulator output voltage are significantly improved, but also the flexibility and controllability of the system are enhanced. This method enables the simulator to quickly and accurately adjust the output voltage, thereby more realistically simulating the dynamic characteristics of the battery under various working conditions. At the same time, due to the use of digital control technology, the system has good repeatability and temperature stability.
[0117] Embodiment 4
[0118] In order to solve the total voltage error problem in actual applications of the battery simulator, this embodiment further optimizes the voltage detection and correction method. This method achieves high-precision battery pack voltage simulation by accurately detecting the total voltage output value and the voltage of each single cell, combined with the calculation of the system loss voltage.
[0119] like Figure 4 As shown, the battery simulation method also includes the following steps:
[0120] S401. Detect the total voltage output value of the simulator.
[0121] S402: Sample the voltage of the battery module.
[0122] S403. Calculate the total voltage according to the following formula.
[0123] V total =∑(V actual (i))-V loss , where Vtotal is the total voltage, Vactual(i) is the actual voltage of the ith single cell, and Vl oss is the system loss voltage.
[0124] Specifically, this embodiment first detects the total voltage output value of the simulator. A high-precision voltage detection circuit is used, for example, a combination of a precision operational amplifier and a high-resolution ADC, such as Texas Instruments' OPA189 and ADS1248, to achieve a detection accuracy of ±0.1mV. The detection circuit uses a four-wire Kelvin connection method, which effectively eliminates the influence of wire resistance and ensures the accuracy of the measurement.
[0125] Furthermore, the method samples the voltage of each battery module. Considering that the simulator can provide analog outputs of 1 to 24 batteries, the sampling circuit needs to have multi-channel and high-precision characteristics. A multiplexer such as ADG1606 can be used with a high-performance ADC such as ADS1278 to achieve synchronous sampling, and the sampling accuracy of each channel can reach ±5mV, which fully meets the accuracy requirements of the simulator.
[0126] It should be understood that the total voltage of an actual battery pack is not simply the sum of the voltages of each cell. Various losses in the system, such as the voltage drop of the connection line and the voltage drop of components on the protection board, will affect the final total voltage value. Therefore, this embodiment introduces the concept of system loss voltage Vl oss, and estimates this loss value through an algorithm.
[0127] It can be understood that this method uses a mathematical model that comprehensively considers the actual single cell voltage and system loss to calculate the total voltage. This model not only considers the actual voltage Vactua l(i) of each single cell, but also adds the system loss voltage Vl oss. In this way, the simulator can more accurately reflect the voltage characteristics of the real battery pack.
[0128] The benefit of this embodiment is that by introducing this precise voltage detection and correction method, the overall accuracy and reliability of the battery simulator are significantly improved. This method can not only accurately simulate the voltage characteristics of various battery combinations, but also reflect the system losses in actual applications, providing a more realistic and reliable voltage environment for the testing of battery protection boards. At the same time, the implementation of this method enables the simulator to monitor and adjust the output voltage in real time, ensuring voltage stability during long-term testing. In addition, by feeding back the actual voltage value detected to the host computer, the system is also provided with the ability of self-diagnosis and calibration, further improving the long-term use accuracy of the simulator.
[0129] Embodiment 5
[0130] In order to solve the problem of insufficient flexibility of traditional battery simulation methods when simulating complex charge and discharge curves, this embodiment further optimizes the curve setting function of the host computer software. This method realizes highly customizable and accurate battery charge and discharge curve simulation by combining predefined curve templates, parameterized settings and interpolation algorithms.
[0131] like Figure 5 As shown, the method of inputting the setting curve through the host computer includes the following steps:
[0132] S501 . Select a predefined charge and discharge curve template.
[0133] S502, setting the charge and discharge rate and depth.
[0134] S503 : Generate time-voltage data points according to the selected template and parameters.
[0135] S504: Generate a continuous voltage variation curve using an interpolation algorithm.
[0136] S505: Send the curve data to the simulator for execution.
[0137] Specifically, this embodiment first provides a series of predefined charge and discharge curve templates. These templates include but are not limited to common charge and discharge modes such as constant current charging, constant voltage charging, pulse charging, constant current discharging, and constant power discharging. Each template is carefully designed by experienced battery engineers according to the characteristics of different types of batteries to ensure the authenticity and representativeness of the simulation curve.
[0138] Furthermore, this method allows the user to set the charge and discharge rate and depth. The charge and discharge rate is usually expressed in C rate, such as 0.5C, 1C, etc., while the depth can be set as a percentage, such as 20% to 80% SOC range. The setting of these parameters enables the user to adjust the curve characteristics according to specific test requirements, thereby simulating the battery behavior under different usage scenarios.
[0139] It is important to understand that, based on the selected template and the set parameters, the system will generate a series of time-voltage data points. These data points are the skeleton of the curve and represent the key nodes in the charging and discharging process. For example, for a typical lithium-ion battery constant current-constant voltage charging process, the system will generate key data such as the starting point of the constant current phase, the transition point of the constant voltage phase, and the end point of charging.
[0140] It is understandable that in order to generate a smooth and continuous voltage change curve, this method uses an interpolation algorithm. Considering the nonlinear characteristics of battery voltage change, the system uses a cubic spline interpolation algorithm. This algorithm can ensure the smoothness and continuity of the curve while accurately reflecting the subtle characteristics of battery voltage changes, such as the voltage platform in the constant voltage charging stage and the rapid voltage drop at the end of discharge.
[0141] The benefit of this embodiment is that by introducing this flexible and accurate charge and discharge curve generation method, the simulation capability and scope of application of the battery simulator are significantly improved. Users can easily simulate various complex charging and discharging conditions, including fast charging, cycle aging, charging and discharging under extreme temperature conditions, and other scenarios, providing an ideal simulation environment for comprehensive testing of battery protection boards. At the same time, the implementation of this method also provides an expansion basis for simulating more complex battery behaviors (such as self-discharge, capacity attenuation, etc.) in the future, and enhances the long-term applicability of the system. In addition, by sending the generated curve data to the simulator for execution, the consistency and controllability of the entire system are ensured, which is conducive to the repeatability and reliability of the test results.
[0142] Embodiment 6
[0143] In order to solve the problem that the traditional battery simulator lacks precise control and authenticity when testing the overcurrent protection function of the battery protection board, this embodiment further optimizes the pulse current output method. This method achieves a high degree of simulation of the actual battery short circuit or overload situation by precisely controlling the amplitude, duration and rise characteristics of the pulse current.
[0144] like Figure 6 As shown, the battery simulation method also includes outputting a pulse current of no more than 1s through the simulator to test the overcurrent protection function of the battery protection board. The pulse current output method is:
[0145] S601, setting the maximum current value Imax.
[0146] S602: Set the pulse duration Tpulse.
[0147] S603, setting the rise time constant τ.
[0148] S604, control the current output according to the following formula:
[0149] , where I pul se(t) is the pulse current, u(t) is the unit step function, and T pul se is the pulse duration.
[0150] Specifically, this embodiment first allows the user to set the maximum current value Imax. This parameter determines the peak value of the pulse current and is usually set according to the specifications of the battery protection board under test. For example, for a protection board rated for 20A overcurrent protection, Imax may be set to 25A to ensure that the protection mechanism can be triggered.
[0151] Furthermore, this method requires the user to set the pulse duration Tpulse. This parameter is usually not more than 1 second to simulate a short overcurrent condition. It should be noted that the setting of Tpulse should take into account the response time of the actual battery protection board, which is usually in the range of tens to hundreds of milliseconds.
[0152] It should be understood that this method introduces the concept of the rise time constant τ. This parameter controls the rise characteristics of the pulse current, making the current change closer to the actual performance of the battery short circuit. The value of τ is usually in the microsecond to millisecond level and can be adjusted according to the internal resistance of the actual battery and the characteristics of the protection board.
[0153] It can be understood that this method uses a mathematical model to accurately control the current output. This model combines the exponential function and the unit step function to accurately describe the rise and duration of the pulse current. The exponential function part simulates the gradual rise characteristics of the current, while the unit step function controls the start and end of the pulse.
[0154] The implementation of this embodiment requires a high-performance current control circuit. A current feedback loop composed of a high-bandwidth operational amplifier (such as AD8610) and a power MOSFET (such as IRF540N) can be considered. At the same time, a high-speed DAC (such as AD5761R) and a microcontroller (such as STM32F407) are used to generate control signals to ensure that the current waveform described by the mathematical model can be accurately reproduced.
[0155] The benefit of this embodiment is that by introducing this precise and controllable pulse current output method, the accuracy and reliability of the battery simulator in testing the overcurrent protection function are significantly improved. This method can not only simulate various overcurrent conditions, but also reflect the current rise characteristics of the actual battery during short circuit or overload, providing more realistic and comprehensive test conditions for the battery protection board. At the same time, the implementation of this method enables the simulator to accurately control the various parameters of the pulse current, facilitates systematic testing and evaluation, and helps to fully verify the performance of the battery protection board under various extreme conditions.
[0156] Embodiment 7
[0157] In order to solve the problem that the battery simulator is complex and error-prone when setting pulse current parameters, this embodiment further optimizes the user interface and parameter setting process of the host computer software. The method realizes the rapid and accurate setting of pulse current parameters by providing an intuitive parameter setting area, real-time parameter verification and a secure transmission mechanism.
[0158] like Figure 7 As shown, the magnitude and duration of the pulse current can be set by the host computer, and the setting method includes the following steps:
[0159] S701. Provide a pulse current parameter setting area on the software interface of the host computer.
[0160] S702. Input the maximum current value Imax, the pulse duration Tpulse and the rise time constant τ.
[0161] S703: Verify the validity of input parameters.
[0162] S704: Transmit the verified input parameters to the simulator.
[0163] Specifically, this embodiment designs a special pulse current parameter setting area in the upper computer software interface. This setting area adopts the principle of ergonomics, with a clear layout and intuitive operation. The parameter input box is equipped with a unit logo and a reasonable range prompt to reduce the possibility of user input errors. In addition, the setting area also includes parameter descriptions and typical value suggestions to help users understand the meaning of each parameter and select appropriate values.
[0164] Furthermore, the method requires the user to input the maximum current value Imax, the pulse duration Tpulse, and the rise time constant τ. In order to improve input efficiency and accuracy, the system provides preset value selection and value fine-tuning functions. For example, Imax can select a common value (such as 10A, 20A, 30A, etc.) through the drop-down menu, or you can directly enter the precise value through the input box. Tpulse and τ can be roughly adjusted through the slider and then accurately set through the input box.
[0165] It should be understood that this method verifies the validity in real time during the parameter input process. The verification content includes but is not limited to: whether the parameter value is within a reasonable range (such as Imax does not exceed the maximum output capacity of the simulator), whether Tpulse does not exceed 1 second, whether τ is consistent with the battery characteristics, etc. If the input parameters do not meet the requirements, the system will immediately give a warning prompt and prevent submission, and provide correction suggestions.
[0166] It is understandable that after the parameter verification is passed, the system will safely transmit these parameters to the simulator. The transmission process uses a checksum mechanism to ensure that the data will not be tampered with or errored during the transmission process. At the same time, the system will verify the parameters again on the simulator side. If an abnormality is found, it will immediately feedback to the host computer and terminate the operation to prevent potential risks caused by incorrect parameters.
[0167] The implementation of this embodiment involves the optimization design of the host computer software. The software interface is developed using the Qt framework to ensure cross-platform compatibility and good user experience. The parameter verification algorithm is implemented using C++ to ensure the efficiency of the verification process. Data transmission uses a custom protocol based on TCP / IP, combined with SSL encryption, to ensure the security and reliability of data transmission.
[0168] The benefit of this embodiment is that by introducing this user-friendly, safe and reliable pulse current parameter setting method, the operating efficiency and safety of the battery simulator are significantly improved. This method not only simplifies the parameter setting process and reduces human errors, but also ensures the effectiveness and safety of the set parameters through multiple verification mechanisms. At the same time, the implementation of this method provides appropriate guidance and protection for operators with different experience levels. In addition, through standardized parameter setting and transmission processes, this method also provides a reliable basis for subsequent test data analysis and report generation, which is conducive to the traceability and comparability of test results.
[0169] Embodiment 8
[0170] In order to solve the problem of insufficient accuracy and low efficiency in detecting protection parameters in the traditional battery protection board test method, this embodiment further optimizes the protection parameter detection method. This method achieves high-precision and high-efficiency testing of key parameters such as overcharge protection, over-discharge protection, overcurrent protection and short-circuit protection by accurately controlling the simulator output, automatically recording the trigger point and calculating the deviation.
[0171] like Figure 8 As shown, the protection parameters include overcharge protection, over-discharge protection, overcurrent protection and short circuit protection. The method for detecting the protection parameters of the battery protection board includes the following steps:
[0172] S801. Gradually adjust the output of the simulator to make the voltage or current close to the protection threshold.
[0173] S802. Record the voltage or current value when the protection is triggered.
[0174] S803. Calculate the deviation between the actual protection parameter and the set value.
[0175] Specifically, this embodiment adopts a strategy of gradually adjusting the simulator output. For overcharge and overdischarge protection, the system gradually adjusts the output voltage in small steps (usually 1-10mV); for overcurrent and short-circuit protection, the output current is gradually increased in small increments (usually 10-100mA). This fine adjustment method ensures that the protection trigger point can be accurately captured without missing the critical value due to excessive step size.
[0176] Furthermore, the method monitors the status of the protection board in real time during the adjustment process. The system continuously collects voltage and current information at the output of the protection board through a high-speed sampling circuit (sampling rate not less than 1MHz). At the same time, a digital isolator (such as ADuM1100) is used to monitor the switch status of the protection board to detect the moment of protection action. This multi-dimensional monitoring ensures that the precise moment of protection triggering can be accurately captured.
[0177] It is important to understand that when the system detects a protection action, it will immediately record the current voltage or current value. In order to improve the accuracy of the record, the system uses a ring buffer technology to continuously save the data of the most recent period of time (such as 100ms). When a protection action is detected, the system will trace back and analyze this data to find the real trigger point, thereby eliminating the error caused by the system response delay.
[0178] It is understandable that after recording the trigger value, this method will automatically calculate the deviation between the actual protection parameter and the set value. The calculation process takes into account the error of the measurement system, including the output accuracy of the simulator, the error of the measurement circuit, etc. The system uses the error propagation theory to calculate the final deviation value and its uncertainty, providing a more comprehensive and reliable test result.
[0179] The benefit of this embodiment is that by introducing this precise and automated protection parameter detection method, the accuracy and efficiency of the battery protection board test are significantly improved. This method can not only accurately measure various protection parameters, but also provide detailed error analysis, providing reliable data support for the performance evaluation and quality control of the protection board. At the same time, the implementation of this method greatly reduces the need for manual operation and judgment, and improves the consistency of the test. In addition, through automated testing processes and data analysis, this method can also quickly generate standardized test reports, which is convenient for subsequent data tracking and analysis.
[0180] Embodiment 9
[0181] In order to solve the problem of insufficient flexibility and single function of traditional battery simulation systems when simulating multiple battery series, this embodiment proposes a highly integrated and fully functional battery simulation system for battery protection board testing. The system achieves accurate simulation and comprehensive testing of complex battery packs through modular design and multi-interface integration.
[0182] like Fig. 9 As shown, the battery simulation system includes:
[0183] 24 independent battery simulation power modules, connected in series;
[0184] Simulator, used to output single cell voltage and detect actual output voltage value;
[0185] The host computer is used to display and set the output voltage of each battery module and control the operation of the simulator through software;
[0186] Communication interface, including Bluetooth interface, CAN bus interface, RS485 interface;
[0187] MCU, used to communicate with the host computer and control the output of the battery simulation power module;
[0188] The pulse current output module can set the size and duration of the pulse current and output a pulse current not exceeding 1s;
[0189] The total voltage detection module is used to detect the total voltage of the simulator and feed back the data to the host computer;
[0190] The power module uses a 12V or 24V power supply to power the entire system.
[0191] Specifically, this embodiment adopts a 24-way independent battery simulation power module design. Each module is built based on a high-precision operational amplifier (such as OPA548) and a digital potentiometer (such as AD5242), and can independently control the output voltage with an accuracy of ±1mV. These modules are connected in series and can flexibly simulate various combinations of 1 to 24 batteries in series. Optocoupler isolation (such as HCPL-7800) technology is used between modules to effectively prevent common-mode interference problems caused by series voltage superposition.
[0192] Furthermore, the core control unit of this system adopts a high-performance MCU (such as STM32F407VGT6). The MCU controls the output of each battery analog power module through the SPI interface and is responsible for communicating with the host computer. In order to improve the real-time performance and stability of the system, the MCU runs the real-time operating system FreeRTOS to achieve multi-task concurrent processing.
[0193] It is important to understand that this system integrates multiple communication interfaces, including Bluetooth 5.0 modules (such as CC2640R2F), CAN bus controllers (such as MCP2515), and RS485 transceivers (such as MAX485). This multi-interface design not only enhances the compatibility of the system, but also provides flexible communication options for different test scenarios. For example, the Bluetooth interface is suitable for short-distance wireless control, the CAN bus is suitable for reliable communication in industrial environments, and the RS485 is suitable for long-distance data transmission.
[0194] It can be understood that the pulse current output module of this system uses a current feedback loop composed of a high-speed operational amplifier (such as LT1210) and a power MOSFET (such as IRFP260N). The module can output a maximum of 100A, and the duration can be accurately controlled within the range of 1μs to 1s. The pulse waveform is generated by a high-speed DAC (such as AD9744), ensuring the accuracy and repeatability of the waveform.
[0195] Furthermore, this embodiment also includes a high-precision total voltage detection module. The module uses a voltage divider and a high-precision ADC (such as ADS1248) to accurately measure a total voltage of up to 100V with a resolution of 0.1mV. In order to ensure the safety of the measurement, the module uses photoelectric isolation technology to effectively isolate the high-voltage measurement end and the low-voltage control end.
[0196] Furthermore, in terms of power modules, this system uses a solution that combines a wide input range (10-36V) DC-DC converter (such as TPS54560) and a multi-channel LDO regulator (such as TPS7A4701). This design not only improves the adaptability of the system, but also ensures that each functional module obtains a stable, low-noise operating voltage.
[0197] The benefit of this embodiment is that by integrating multifunctional modules and advanced control strategies, the battery simulation system can fully meet the various needs of battery protection board testing. The modular design and flexible configuration capabilities of the system make it suitable for simulation testing of various battery combinations, thereby greatly improving test efficiency and accuracy. The integration of multiple communication interfaces enhances the versatility and scalability of the system, allowing it to be easily integrated into various test environments. In addition, the high-precision voltage control and current output capabilities, combined with real-time data acquisition and analysis functions, provide comprehensive and reliable technical support for the performance evaluation of battery protection boards.
[0198] Embodiment 10
[0199] In order to solve the portability and execution efficiency problems of the battery simulation method for battery protection board testing in practical applications, this embodiment further optimizes the software implementation method and proposes a solution based on a computer-readable storage medium. This solution compiles the battery simulation method into an efficient executable program and stores it in a dedicated medium, thereby achieving cross-platform application and performance optimization of the method.
[0200] Specifically, this embodiment adopts a layered software design. The bottom layer uses C language to write the core algorithm to ensure the highest execution efficiency; the middle layer uses C++ to implement the business logic, making full use of the advantages of object-oriented programming; the top layer uses Python scripting language to provide flexible user interaction and rapid prototyping capabilities. This multi-language hybrid programming strategy fully balances performance, maintainability and development efficiency.
[0201] Furthermore, the program uses the CUDA parallel computing framework to fully utilize the parallel processing capabilities of the GPU. For large-scale data processing and complex algorithm calculations (such as real-time waveform analysis, multi-parameter optimization, etc.), the CUDA kernel function is implemented, which significantly improves the calculation speed. This GPU acceleration technology enables the system to handle more complex simulation scenarios and larger data sets.
[0202] In terms of storage media, the program is compiled and stored on industrial-grade high-reliability storage devices such as SLC NAND flash memory or eMMC. These storage devices have an erase and write life of up to 100,000 times and a wide temperature range (-40°C to 85°C) to ensure long-term stable operation in harsh industrial environments. At the same time, by implementing an incremental update mechanism, it supports online firmware upgrades (OTA) to facilitate subsequent function expansion and bug fixes.
[0203] The benefit of this embodiment is that by compiling the battery simulation method for battery protection board testing into an efficient executable program and storing it in a dedicated medium, the efficiency and reliability of the battery simulation method for battery protection board testing are improved. The application of multi-language hybrid programming and GPU acceleration technology enables the system to handle more complex simulation scenarios and larger data sets to meet the needs of high-end battery testing. The integration of a real-time operating system ensures the timely execution of key tasks and improves test accuracy.
[0204] The beneficial effects of the present invention are specifically embodied in that the above are only preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A battery simulation method for testing a battery protection board, characterized in that: The battery simulation method comprises the following steps: Set the output voltage parameters of each battery module, the voltage setting range is 1.5V to 4.5V; The setting curve is input into the host computer, and the corresponding PWM signal is generated in the simulator to achieve the change of output voltage; Collecting the actual output voltage value of each battery module and feeding it back to the host computer; Comparing the actual output voltage value with the set output voltage parameter, and adjusting the PWM signal to calibrate the output; According to the preset test plan, the simulator is controlled to output a changing voltage value to simulate the charging and discharging process of the battery module; Detect the protection parameters of the battery protection board and compare the detection results with the preset values; If the detection results are inconsistent, an alarm signal is generated and the abnormal situation is recorded, the detection results and the abnormal situation are transmitted to the host computer, and a detection file is established for each battery protection board.
2. The battery simulation method for testing a battery protection board according to claim 1, characterized in that: The method for setting the output voltage parameters of each battery module comprises the following steps: Determine a reference voltage Vbase; Set the voltage fluctuation amplitude ΔV; Set the fluctuation period T; Allocating a phase offset φi to each of the battery modules; The output voltage parameter of each battery module is calculated according to the following formula: Wherein, Vset(i) is the set voltage of the i-th battery module, and t is the time.
3. The battery simulation method for testing a battery protection board according to claim 1, characterized in that: The method for generating a corresponding PWM signal in the simulator comprises the following steps: Calculate the PWM duty cycle according to the set value of the output voltage parameter; Generate a PWM waveform of corresponding frequency; Convert the PWM waveform into an analog voltage through low-pass filtering; The analog voltage is buffered and amplified using an operational amplifier.
4. The battery simulation method for testing a battery protection board according to claim 1, characterized in that: The battery simulation method further comprises the following steps: Detect the total voltage output value of the simulator; Sampling the voltage of the battery module; Calculate the total voltage using the following formula: V total =∑(V actual (i))-V loss , where Vtotal is the total voltage, Vactual(i) is the actual voltage of the i-th single cell, and Vloss is the system loss voltage.
5. The battery simulation method for testing a battery protection board according to claim 1, characterized in that: The method for inputting a setting curve through a host computer comprises the following steps: Select a predefined charge and discharge curve template; Set the charge and discharge rate and depth; Generate time-voltage data points based on the selected template and parameters; Use interpolation algorithm to generate continuous voltage change curve; The curve data is sent to the simulator for execution.
6. The battery simulation method for testing a battery protection board according to claim 1, characterized in that: The battery simulation method also includes outputting a pulse current of no more than 1s through the simulator to test the overcurrent protection function of the battery protection board, and the output method of the pulse current is: Set the maximum current value Imax; Set the pulse duration Tpulse; Set the rise time constant τ; The current output is controlled according to the following formula: Where Ipulse(t) is the pulse current, u(t) is the unit step function, and Tpulse is the pulse duration.
7. The battery simulation method for testing a battery protection board according to claim 6, characterized in that: The magnitude and duration of the pulse current can be set by the host computer, and the setting method includes the following steps: Providing a pulse current parameter setting area on the software interface of the host computer; Input the maximum current value Imax, the pulse duration Tpulse and the rise time constant τ; Verify the validity of input parameters; The verified input parameters are transmitted to the simulator.
8. The battery simulation method for testing a battery protection board according to claim 1, characterized in that: The protection parameters include overcharge protection, over-discharge protection, overcurrent protection and short circuit protection. The method for detecting the protection parameters of the battery protection board includes the following steps: gradually adjusting the output of the simulator so that the voltage or current approaches a protection threshold; Record the voltage or current value when the protection is triggered; Calculate the deviation between the actual protection parameter and the set value.
9. A battery simulation system for testing a battery protection board, characterized in that: The battery simulation system comprises: 24 independent battery simulation power modules, connected in series; Simulator, used to output single cell voltage and detect actual output voltage value; The host computer is used to display and set the output voltage of each battery module and control the operation of the simulator through software; Communication interface, including Bluetooth interface, CAN bus interface, RS485 interface; MCU, used for communicating with the host computer and controlling the output of the battery simulation power module; The pulse current output module can set the size and duration of the pulse current and output a pulse current not exceeding 1s; The total voltage detection module is used to detect the total voltage of the simulator and feed back the data to the host computer; The power module uses a 12V or 24V power supply to power the entire system.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the battery simulation method for testing a battery protection board as described in any one of claims 1 to 8 is implemented.
