A circuit and method for linear optocoupler to detect the voltage of single cells in a series battery pack
By using a linear optocouple detection circuit when detecting the voltage of a single battery in series battery pack, using MOC301X_i photocouple relay and a linear optocouple HCNR200_i, combined with an operational amplifier and control chip STM32F103RCT6, linear detection and monitoring of the voltage of a single battery in series battery pack is achieved, solving the problem that the measurement circuit in the prior art cannot achieve common ground and reducing battery losses.
Patent Information
- Application Number
- CN202011125471.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-10-20
- Publication Date
- 2025-04-01
- Estimated Expiration
- 2040-10-20
AI Technical Summary
When detecting the voltage of a single battery in series battery pack, the prior art has the problem that the voltage between the single batteries is different, so that the measurement circuit cannot achieve common ground. At the same time, the battery power will also be lost when the measurement circuit is left to stand.
Using a linear optocoupler detection circuit, linear optocoupler relay, linear optocoupler HCNR200_i, operational amplifier and control chip STM32F103RCT6 are used to realize linear detection and monitoring of the voltage of the single battery cell in series battery pack.
Linear detection of the voltage of the single battery cell in series battery pack is realized, and it does not need to be shared, which solves the problem of common ground difficulties, and reduces battery losses by controlling the on-off of the measurement circuit.
Smart Images

Figure CN112327196B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of lithium battery pack charge and discharge protection circuits, and relates to a circuit for detecting the voltage of a single cell of a series-connected battery pack using a linear optocoupler. The present invention also relates to a method for detecting the voltage of a single cell of a series-connected battery pack using a linear optocoupler. Background Art
[0002] As primary energy sources gradually decrease, energy consumption is increasingly leaning towards electrical energy. In the field of new energy vehicles, series battery packs are widely used. When charging the battery pack, a device that can detect the voltage of the single cell of the series battery pack is required. Although there are some methods for measuring the voltage of the single cell when the series battery pack is charged and discharged, the measurement effect is not good, and the measurement circuit itself will also consume battery power when it is in a static state. Therefore, there is an urgent need for a method that can linearly respond to the change of the voltage of the single cell when the series battery pack is charged and discharged. Summary of the invention
[0003] The object of the present invention is to provide a circuit for detecting the voltage of single cells of a series-connected battery pack using a linear optocoupler.
[0004] The purpose of the present invention is to provide a method for detecting the voltage of a single cell of a series-connected battery pack by a linear optocoupler, which solves the problem in the prior art that when detecting the voltage of a single cell of a series-connected battery pack, the voltages between the single cells in the series-connected battery pack are different, causing the measurement circuit to be unable to achieve a common ground. At the same time, it also solves the problem of preventing circuit loss when the measurement circuit is stationary.
[0005] The first technical solution adopted by the present invention is a circuit for detecting the voltage of a single cell of a series-connected battery pack using a linear optocoupler, comprising a MOC301X_i optocoupler relay, wherein the output switch Si of the MOC301X_i optocoupler relay is connected to the positive electrode of the Cell-i battery, the switch Si is connected to the resistor Ri1, the resistor Ri1 is connected to the linear optocoupler HCNR200_i, the linear optocoupler HCNR200_i is also connected to resistors Ri2 and Ri3 respectively, the resistor Ri3 is connected to an operational amplifier, and the operational amplifier is connected to a control chip, wherein i=1, 2, ..., 12.
[0006] The first technical solution of the present invention is also characterized in that:
[0007] The operational amplifier includes a voltage comparator Gi, a negative electrode of the voltage comparator Gi is connected to a resistor Ri4, a negative electrode of the voltage comparator Gi is connected to an output end of the voltage comparator Gi through a parallel circuit of Ri5 and a capacitor Ci, and a positive electrode of the voltage comparator Gi is directly grounded.
[0008] Ri1 is connected to pin 2 of the linear optocoupler HCNR200_i, pin 1 of the linear optocoupler HCNR200_i is connected to the negative pole of the Cell-i battery, output pin 5 of the linear optocoupler HCNR200_i is connected to vcc, and resistors Ri2 and Ri3 are connected to pin 6 of the linear optocoupler HCNR200_i.
[0009] The model of the control chip is STM32F103RCT6.
[0010] The front end of the input terminal Qi of the MOC301X_i optocoupler relay is connected to the control chip, the rear end of the input terminal Qi of the MOC301X_i optocoupler relay is connected to one end of the resistor Ri, the other end of the resistor Ri is connected to one end of the light emitting diode LED, and the other end of the light emitting diode LED is grounded.
[0011] The second technical solution adopted by the present invention is a method for a linear optocoupler to detect the voltage of a single battery in a series battery pack, which specifically includes the following steps:
[0012] S1, system power-on, control chip pin initialization;
[0013] S2, determine whether the PB0-PB11 pins of the control chip are at a high level;
[0014] S3, if there is a high level in PB0-PB11, the corresponding Q1-Q12 will be powered, connect the corresponding resistors R1-R12, and then connect the positive electrode of the corresponding MOC301X_1-MOC301X_12 type optocoupler relay input end light emitting diode LED, the negative electrode of the light emitting diode LED is grounded, the light emitting diode LED can normally emit light to make the output end S1-S12 of MOC301X_1~MOC301X_12 type optocoupler relay conduct;
[0015] S3, the positive electrodes of the single cells Cell_1-Cell_12 are respectively connected to the output terminals S1-S12 of the MOC301X_1~MOC301X_12 optocoupler relays, and then connected to the positive electrodes of the light-emitting diodes LED at the input terminals of HCNR200_1~HCNR200_12 after being connected to the resistors R11-R121, and the negative electrodes of the light-emitting diodes LED are respectively connected to the negative electrodes of the single cells Cell-1-Cell-12, and the voltage changes of the single cells Cell-1~Cell-12 are respectively passed through the resistors R11-R121 to obtain different currents, thereby changing the luminous intensity of the light-emitting diodes LED;
[0016] S4, the positive pole of the photodiode PD2 at the output end of the linear optocoupler of HCNR200_1-HCNR200_12 is connected to the power supply vcc, and the negative pole of the photodiode PD2 is grounded to the resistors R12-R122 respectively to ensure the operation of the photodiode. The change in the luminous intensity of the light-emitting diode LED causes the current of the photodiode PD2 to change. The current output by the linear optocoupler of HCNR200_1-HCNR200_12 is converted into voltage through the resistors R13-R123. G1-G12 is a voltage comparator. The resistors R14-R124 are connected to the voltage comparator respectively. The negative end of the voltage comparator G1-G12, the negative electrodes of G1-G12 are respectively connected to the output end of the voltage comparator G1-G12 through the parallel circuit of R15-R125 and C1-C12, the positive electrodes of the voltage comparator G1-G12 are directly grounded, and the voltage comparator forms a voltage comparator circuit through the resistors R14-R124, R15-R125 and the capacitors C1-C12. The voltage converted by R13-R123 flows into the input end of the voltage comparator, and the voltage is amplified by the voltage comparators G1~G12 respectively, and then output to AD0-AD11;
[0017] S5, the analog voltage signals AD0-AD7 output by the voltage comparators G1-G8 are respectively transmitted to the control chip pins PA0-PA7, and the analog voltage signals AD8-AD11 output by the voltage comparators G9-G12 are respectively transmitted to the control chip pins PC0-PC3;
[0018] S6, the control chip pins PA0-PA7 and PC0-PC3 are ADC channels. The ADC converts the analog voltage signal into a digital signal, thereby obtaining the voltage of the target battery.
[0019] The beneficial effects of the present invention are that the linear optocoupler used in the present invention can directly and linearly reflect the voltage of each single cell without the need for common ground, thus solving the problem of common ground difficulty; the detection circuit for detecting the single cell in the series battery pack is independent, the number of battery packs to be measured is not limited, and the number of detected batteries can be increased. In addition, the measurement circuit can be controlled to switch arbitrarily to monitor any single cell, and the linear change of the voltage of all single cells in the series battery pack can be detected at the same time; the battery loss can be reduced by controlling the on and off of the measurement circuit. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 It is an overall circuit diagram of a circuit for detecting the voltage of single cells of a series-connected battery pack by a linear optocoupler according to the present invention;
[0021] Figure 2 It is a connection diagram of an optocoupler relay in a circuit for detecting the voltage of a single battery in a series battery pack by a linear optocoupler of the present invention;
[0022] Figure 3 It is a circuit control chip STM32F103RCT6 pin diagram of a linear optocoupler detecting the voltage of a single battery in a series battery pack. DETAILED DESCRIPTION
[0023] The present invention is described in detail below with reference to the accompanying drawings and specific embodiments.
[0024] The present invention provides a circuit for detecting the voltage of a single battery in a series battery pack using a linear optocoupler, which is applied to the measurement example of a 12-cell battery pack. Figure 1 As shown in the figure, Cell_1-Cell_12 are 12 cells in the battery pack. The cells are 3.2V lithium batteries. Each cell uses a measurement circuit, so there are 12 measurement lines in total. The measurement line includes an amplifier, an optocoupler relay S, a linear optocoupler, and a capacitor and resistor device. Each measurement circuit is divided into two parts by a linear optocoupler. The linear optocoupler input end is composed of an optocoupler relay and a resistor. The output end is composed of an amplifier, a capacitor and a resistor. Among them, S1-S12 are the output ends of the optocoupler relay of each measurement line, a total of 12 groups, which mainly control the on and off of the linear optocoupler input end of the target cell.
[0025] In the first measurement circuit, the positive pole of the Cell_1 battery is connected to the output terminal S1 of the optocoupler relay. The optocoupler relay controls the conduction of the linear optocoupler. S1 is followed by a resistor R11 to convert the voltage into current. R11 is connected to the pin 2 of the linear optocoupler HCNR200_1, and the pin 1 of the linear optocoupler HCNR200_1 is connected to the negative pole of Cell_1 to make the light-emitting diode LED emit light. The output pin 5 of the linear optocoupler HCNR200_1 is connected to vcc, and resistors R12 and R13 are connected to the pin 6 of the linear optocoupler HCNR200_1. Among them, R12 is used to protect the photodiode from the ground connection. Combined with the pin 5, the photodiode can work normally. The photodiode receives different currents according to the luminous intensity of the light-emitting diode. The current is converted into voltage through R13, and the converted voltage is connected to the input terminal of the voltage comparator to amplify the voltage. Among them, the operational amplifier is composed of resistors R14, R15, capacitor C1 and LMV321 voltage comparator G1. The analog voltage signal AD0 output by G1 is transmitted to the PA0 pin input of the control chip STM32F103RCT6. Since the STM32F103RCT6 has its own ADC conversion function, the voltage analog signal is converted into a digital signal, so that the voltage change of Cell1 battery can be obtained in real time. Similarly, the working principle of the other 11 measurement lines is the same, so the voltage change of Cell_1-Cell_12 batteries can be obtained in real time. Among them, AD0-AD7 are connected to PA1-PA7 respectively, and AD8-AD11 are connected to PC0-PC3 respectively. G1-G12 is a voltage comparator, and resistors R14-R124 are connected to the negative terminals of the voltage comparators G1-G12 respectively. The negative terminals of G1-G12 are connected to the output terminals of the voltage comparators G1-G12 through the parallel circuits of R15-R125 and C1-C12 respectively. The positive terminals of the voltage comparators G1-G12 are directly grounded. The voltage comparators form an operational amplifier circuit by connecting with resistors R14-R124, R15-R125 and capacitors C1-C12.
[0026] like Figure 2This is a linear optocoupler detection of the voltage of a single battery cell in a series battery pack, which is applied to an example diagram of the connection of an optocoupler relay control circuit for a 12-cell battery pack. The figure contains resistors and MOC301X optocoupler relays. In the first control circuit, Q1 represents the input end of the MOC301X_1 optocoupler relay, and Q1 is connected to the PB0 pin of the STM32F103RCT6 microcontroller. The resistor R1 connected behind is a current limiter to protect the light-emitting diode LED of MOC301X_1. The other end of the LED is grounded to make the diode conduct normally. S1 is the output end of MOC301X_1. Among them, the high and low levels of PB0 of STM32F103RCT6 control the conduction of MOC301X_1 optocoupler relay S1. Similarly. The working principles of the other 11 control lines are the same, so the on and off of S2-S12 in MOC301X_2-MOC301X-12 can be controlled; Figure 3 It is the pin diagram of the control chip in the present invention.
[0027] The present invention provides a method for linear optocoupler to detect the voltage of single cells of a series battery pack, which specifically comprises the following steps:
[0028] S1, system power-on, control chip pin initialization;
[0029] S2, determine whether the PB0-PB11 pins of the control chip are at a high level;
[0030] S3, if there is a high level in PB0-PB11, the corresponding Q1-Q12 will be powered, connect the corresponding resistors R1-R12, and then connect the positive electrode of the corresponding MOC301X_1-MOC301X_12 type optocoupler relay input end light emitting diode LED, the negative electrode of the light emitting diode LED is grounded, the light emitting diode LED can normally emit light to make the output end S1-S12 of MOC301X_1~MOC301X_12 type optocoupler relay conduct;
[0031] S3, the positive electrodes of the single cells Cell1-Cell12 are respectively connected to the output terminals S1-S12 of the MOC301X_1~MOC301X_12 optocoupler relays, and then connected to the positive electrodes of the light-emitting diodes LED at the input terminals of HCNR200_1~HCNR200_12 after being connected to the resistors R11-R121, and the negative electrodes of the light-emitting diodes LED are respectively connected to the negative electrodes of the single cells Cell-1~Cell-12, and the voltage changes of the single cells Cell-1~Cell-12 are respectively passed through the resistors R11-R121 to obtain different currents, thereby changing the luminous intensity of the light-emitting diodes LED;
[0032] S4, the positive pole of the photosensitive diode PD2 at the output end of the linear optocoupler of HCNR200_1-HCNR200_12 is connected to the power supply vcc, and the negative pole is grounded to the resistors R12-R122 respectively, which ensures the operation of the photosensitive diode. The current change of the photosensitive diode is the change of the luminous intensity of the linear optocoupler light-emitting diode. The current output by the linear optocoupler of HCNR200_1-HCNR200_12 is converted into voltage through the resistors R13-R123. G1-G12 is a voltage comparator. The resistors R14-R124 are connected to the voltage comparator G1- The negative end of G12 and the negative electrodes of G1-G12 are connected to the output end of the voltage comparator G1-G12 through the parallel circuit of R15-R125 and C1-C12 respectively. The positive electrode of the voltage comparator G1-12 is directly grounded. The voltage comparator forms a voltage comparator circuit through the resistors R14-R124, R15-R125 and capacitors C1-C12. The voltage converted by R13-R123 flows into the input end of the voltage comparator, and the voltage is amplified to a reasonable range (about 3V) by the voltage comparator, and then output to AD0-AD11;
[0033] S5, the analog voltage signals AD0-AD7 output by the voltage comparators G1-G8 are respectively transmitted to the control chip pins PA0-PA7, and the analog voltage signals AD8-AD11 output by the voltage comparators G9-G12 are respectively transmitted to the control chip pins PC0-PC3;
[0034] S6, the control chip pins PA0-PA7 and PC0-PC3 are ADC channels. The ADC converts the analog voltage signal into a digital signal, thereby obtaining the voltage of the target battery.
[0035] Through the above implementation process, real-time feedback data of the voltage change of the single battery in the series battery pack is obtained, and the obtained data is linear data, which is conducive to further controlling the voltage balance of the battery pack
[0036] The present invention discloses a method for detecting the voltage of a single cell of a series battery pack by a linear optocoupler. When detecting the voltage change of a target single cell, the on-off of a single cell measurement circuit is controlled by an optocoupler relay. The conduction of the optocoupler relay puts the linear optocoupler in a working state. At this time, the change of the voltage of the single cell causes the change of the luminous intensity of the light-emitting diode at the input end of the linear optocoupler. When the output end of the linear optocoupler receives the change of the intensity of the light-emitting diode through a photosensitive diode, the current changes. The current is converted into a voltage through a resistor, and the voltage is amplified by a voltage comparator. The amplified voltage analog signal is transmitted to the pin channel of the STM32F103RCT6 control chip with an ADC conversion function, and analog-to-digital conversion is performed to obtain a digital signal. At this time, the voltage of the target single cell can be obtained. The high and low levels of the STM32F103RCT6 chip pins are used to control the on-off of the optocoupler relay.
Claims
1. A circuit for detecting the voltage of a single battery in a series battery pack by a linear optocoupler, characterized in that: Applied to 12-cell battery pack, Cell_1-Cell_12 are 12 single cells in the battery pack, the single cells are 3.2V lithium batteries, each single cell uses a measurement circuit, so a total of 12 measurement lines are formed, each measurement circuit is divided into two parts by a linear optocoupler, the linear optocoupler input end is composed of an optocoupler relay and a resistor, and the output end is composed of an amplifier, a capacitor and a resistor; In the first measurement circuit, the positive pole of the Cell_1 battery is connected to the output terminal S1 of the optocoupler relay. The optocoupler relay controls the conduction of the linear optocoupler. S1 is followed by a resistor R11 to convert the voltage into current. R11 is connected to the No. 2 pin of the linear optocoupler HCNR200_1. The No. 1 pin of the linear optocoupler HCNR200_1 is connected to the negative pole of Cell_1 to make the light-emitting diode LED emit light. The output pin 5 of the linear optocoupler HCNR200_1 is connected to vcc, and resistors R12 and R13 are connected to the No. 6 pin of the linear optocoupler HCNR200_1. Among them, R12 is used to protect the photodiode from being connected to the ground. Combined with the No. 5 pin, the photodiode can work normally. The photodiode receives different currents according to the luminous intensity of the light-emitting diode. The current is converted into voltage through R13. The converted voltage is connected to the input terminal of the voltage comparator to amplify the voltage. Among them, the operational amplifier is composed of resistors R14, R15, capacitor C1 and LMV321 voltage comparator G1. The analog voltage signal AD0 output by G1 The voltage is transmitted to the PA0 pin input of the control chip STM32F103RCT6. Since the STM32F103RCT6 has its own ADC conversion function, the voltage analog signal is converted into a digital signal, so that the voltage change of the Cell1 battery can be obtained in real time; similarly, the working principle of the other 11 measurement lines is the same, so the voltage change of the Cell_1-Cell_12 batteries can be obtained in real time; among them, AD0-AD7 are connected to PA1-PA7 respectively, and AD8-AD11 They are connected to PC0-PC3 respectively; G1-G12 is a voltage comparator, and resistors R14-R124 are connected to the negative terminals of the voltage comparators G1-G12 respectively. The negative terminals of G1-G12 are connected to the output terminals of the voltage comparators G1-G12 respectively through the parallel circuits of R15-R125 and C1-C12. The positive terminals of the voltage comparators G1-G12 are directly grounded. The voltage comparators form an operational amplifier circuit through resistors R14-R124, R15-R125 and capacitors C1-C12. The circuit structure includes a MOC301X_i optocoupler relay, a switch Si at the output end of the MOC301X_i optocoupler relay is connected to the positive electrode of the Cell-i battery, the switch Si is connected to a resistor Ri1, the resistor Ri1 is connected to a linear optocoupler HCNR200_i, the linear optocoupler HCNR200_i is also connected to resistors Ri2 and Ri3, the resistor Ri3 is connected to an operational amplifier, and the operational amplifier is connected to a control chip, wherein i=1, 2, ..., 12; The operational amplifier includes a voltage comparator Gi, the negative end of the voltage comparator Gi is connected to a resistor Ri4, the negative electrode of the voltage comparator Gi is connected to the output end of the voltage comparator Gi through a parallel circuit of Ri5 and a capacitor Ci, and the positive electrode of the voltage comparator Gi is directly grounded; The Ri1 is connected to the pin 2 of the linear optocoupler HCNR200_i, the pin 1 of the linear optocoupler HCNR200_i is connected to the negative electrode of the Cell-i battery, the output pin 5 of the linear optocoupler HCNR200_i is connected to vcc, and the resistors Ri2 and Ri3 are connected to the pin 6 of the linear optocoupler HCNR200_i; The model of the control chip is STM32F103RCT6; The front end of the input terminal Qi of the MOC301X_i optocoupler relay is connected to the control chip, the rear end of the input terminal Qi of the MOC301X_i optocoupler relay is connected to one end of the resistor Ri, the other end of the resistor Ri is connected to one end of the light emitting diode LED, and the other end of the light emitting diode LED is grounded.
2. The method for detecting the voltage of a single cell of a series-connected battery pack by a circuit for detecting the voltage of a single cell of a series-connected battery pack by a linear optocoupler according to claim 1, characterized in that: The specific steps include: S1, system power-on, control chip pin initialization; S2, determine whether the PB0-PB11 pins of the control chip are at a high level; S3, if there is a high level in PB0-PB11, the corresponding Q1-Q12 will be powered, connect the corresponding resistors R1-R12, and then connect the positive electrode of the corresponding MOC301X_1-MOC301X_12 type optocoupler relay input end light emitting diode LED, the negative electrode of the light emitting diode LED is grounded, the light emitting diode LED can normally emit light to make the output end S1-S12 of MOC301X_1~MOC301X_12 type optocoupler relay conduct; S4, the positive electrodes of the single cells Cell1-Cell12 are respectively The output terminals S1-S12 of the MOC301X_1~MOC301X_12 optocoupler relays are connected to the positive electrodes of the light-emitting diodes LED at the input terminals of HCNR200_1~HCNR200_12 after being connected to the resistors R11-R121. The negative electrodes of the light-emitting diodes LED are connected to the negative electrodes of the single cells Cell-1~Cell-12 respectively. The voltage changes of the single cells Cell-1~Cell-12 respectively pass through the resistors R11-R121 to obtain different currents, thereby changing the luminous intensity of the light-emitting diodes LED. S5, the positive pole of the photodiode PD2 at the output end of the linear optocoupler of HCNR200_1-HCNR200_12 is connected to the power supply vcc, and the negative pole of the photodiode PD2 is grounded to the resistors R12-R122 respectively to ensure the operation of the photodiode. The change in the luminous intensity of the light-emitting diode LED causes the current of the photodiode PD2 to change. The current output by the linear optocoupler of HCNR200_1-HCNR200_12 is converted into voltage through the resistors R13-R123. G1-G12 is a voltage comparator. The resistors R14-R124 are connected to The negative end of the voltage comparator G1-G12, the negative electrodes of G1-G12 are respectively connected to the output end of the voltage comparator G1-G12 through the parallel circuit of R15-R125 and C1-C12, the positive electrode of the voltage comparator G1-12 is directly grounded, and the voltage comparator forms a voltage comparator circuit through the resistors R14-R124, R15-R125 and the capacitors C1-C12. The voltage converted by R13-R123 flows into the input end of the voltage comparator, and the voltage is amplified by the voltage comparators G1~G12 respectively, and then output to AD0-AD11; S6, the analog voltage signals AD0-AD7 output by the voltage comparators G1-G8 are respectively transmitted to the control chip pins PA0-PA7, and the analog voltage signals AD8-AD11 output by the voltage comparators G9-G12 are respectively transmitted to the control chip pins PC0-PC3; S7, the control chip pins PA0-PA7 and PC0-PC3 are ADC channels. The ADC converts the analog voltage signal into a digital signal, thereby obtaining the voltage of the target battery.
Citation Information
Patent Citations
Lithium battery pack management system of electric automobile
CN102427256A