Current determination circuit, integrated chip and electronic product

By designing a current determination circuit, the voltage is converted into current using a resistor branch and a signal processing branch, and then controlled by a switch branch. This enables the determination of the direction and magnitude of the current, solving the problem that existing integrated chips can only sample in one direction and improving practicality.

CN118641823BActive Publication Date: 2024-11-12SHENZHEN SIYUAN SEMICON CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411118109.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-15
Publication Date
2024-11-12
Estimated Expiration
2044-08-15

Smart Images

  • Figure CN118641823B_ABST
    Figure CN118641823B_ABST
Patent Text Reader

Abstract

The present application discloses a current determination circuit, an integrated chip and an electronic product. The current determination circuit is connected to a current sampling resistor, and the current determination circuit includes a first resistor branch, a second resistor branch, a first signal processing branch, a second signal processing branch and a switch branch. The first signal processing branch outputs a first voltage and a second voltage. The second signal processing branch outputs a first level and a second level. The switch branch establishes a connection between a first node and a third node or establishes a connection between a second node and a fourth node. If the voltage of the first node is equal to the voltage of the second node, the direction and magnitude of the sampling current are determined based on the voltage of the third node. If the voltage of the first node is equal to the voltage of the second node, the direction and magnitude of the sampling current are determined based on the voltage of the fourth node. Through the above method, the direction and magnitude of the sampling current flowing through the current sampling resistor can be determined, and it can be applied to sampling currents in two different directions, and it is more practical.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the technical field of electronic circuits, and in particular to a current determination circuit, an integrated chip, and an electronic product. Background Art

[0002] In many electronic products, such as batteries, an integrated chip including a current sampling circuit is usually provided, which is used to collect current signals and send the current signals to a corresponding control module, which adjusts the relevant state of the electronic product according to the current signals.

[0003] However, current integrated chips can usually only sample and detect current in a single direction, and their practicality is poor. Summary of the invention

[0004] The embodiments of the present application provide a current determination circuit, an integrated chip and an electronic product, which can determine the direction and magnitude of a sampling current flowing through a current sampling resistor, and can be applied to sampling currents in two different directions, and are highly practical.

[0005] In a first aspect, an embodiment of the present application provides a current determination circuit, which is used to be connected to a current sampling resistor to determine the direction and magnitude of a sampling current flowing through the current sampling circuit, wherein the current determination circuit includes a first resistor branch, a second resistor branch, a first signal processing branch, a second signal processing branch, and a switch branch;

[0006] The first end of the first resistor branch is connected to the first end of the current sampling resistor, the second end of the first resistor branch is connected to the second end of the current sampling resistor, the third end of the first resistor branch is connected to the first end of the first signal processing branch and the third end of the switch branch at a first node, the fourth end of the first resistor branch is connected to the second end of the first signal processing branch and the fourth end of the switch branch at a second node, the third end of the first signal processing branch is connected to the first end of the second signal processing branch, the fourth end of the first signal processing branch is connected to the second end of the second signal processing branch, the third end of the second signal processing branch is connected to the first end of the switch branch, the fourth end of the second signal processing branch is connected to the second end of the switch branch, the fifth end of the switch branch is connected to the first end of the second resistor branch at a third node, and the sixth end of the switch branch is connected to the second end of the second resistor branch at a fourth node;

[0007] The first signal processing branch is used to amplify the voltage of the first node into a first voltage, and amplify the voltage of the second node into a second voltage;

[0008] The second signal processing branch is used to convert the first voltage into a first current based on a preset conversion method, and is used to convert the second voltage into a second current based on the preset conversion method, and is used to output a first level to a first end of the switch branch and a second level to a second end of the switch branch when the first current is less than the second current, and is also used to output a second level to a first end of the switch branch and a first level to a second end of the switch branch when the first current is greater than the second current;

[0009] The switch branch is used to establish a connection between the first node and the third node when the first end thereof receives the first level and the second end thereof receives the second level, wherein after the connection between the first node and the third node is established, if the voltage of the first node is equal to the voltage of the second node, the direction and magnitude of the sampling current are determined based on the voltage of the third node;

[0010] The switch branch is further used to establish a connection between the second node and the fourth node when the first end thereof receives the second level and the second end thereof receives the first level, wherein after the connection between the second node and the fourth node is established, if the voltage of the first node is equal to the voltage of the second node, the direction and magnitude of the sampling current are determined based on the voltage of the fourth node.

[0011] In one or more embodiments, the second signal processing branch includes a signal conversion unit and a current mirror unit;

[0012] The first end of the signal conversion unit is connected to the third end of the first signal processing branch, the second end of the signal conversion unit is connected to the fourth end of the first signal processing branch, the third end of the signal conversion unit and the first end of the current mirror unit are connected to a fifth node, the fourth end of the signal conversion unit and the second end of the current mirror unit and the second end of the switch branch are connected to a sixth node, the fifth end of the signal conversion unit and the third end of the current mirror unit and the first end of the switch branch are connected to a seventh node, the sixth end of the signal conversion unit and the fourth end of the current mirror unit are connected to an eighth node, and the seventh end of the signal conversion unit and the eighth end of the signal conversion unit are both input with the first input current;

[0013] The signal conversion unit is used to obtain a third current that is positively correlated with the first voltage based on the first voltage, and output the first current based on half of the difference between the first input current and the third current, wherein the first current is input to the fifth node and the seventh node respectively;

[0014] The signal conversion unit is further used for obtaining a fourth current having a positive correlation with the second voltage based on the second voltage, and outputting the second current based on half of the difference between the first input current and the fourth current, wherein the second current is input to the sixth node and the eighth node respectively;

[0015] The current mirror unit is used to mirror the first current input to the fifth node to be output from the sixth node, and to mirror the second current input to the eighth node to be output from the seventh node, wherein when the first current is less than the second current, the sixth node outputs the first level to the first end of the switch branch and the seventh node outputs the second level to the second end of the switch branch, and when the first current is greater than the second current, the sixth node outputs the second level to the first end of the switch branch and the seventh node outputs the first level to the second end of the switch branch.

[0016] In one or more embodiments, the first resistor branch includes a first resistor and a second resistor;

[0017] The first resistor is connected between a first end of the current sampling resistor and the first node, and the second resistor is connected between a second end of the current sampling resistor and the second node.

[0018] In one or more embodiments, the first signal processing branch includes a third resistor, a fourth resistor, a first switch tube, a second switch tube and a first current source;

[0019] The third resistor is connected between the first input voltage and the third end of the first switch tube, the third end of the first switch tube is also connected to the first end of the second signal processing branch, the fourth resistor is connected between the first input voltage and the third end of the second switch tube, the third end of the second switch tube is also connected to the second end of the second signal processing branch, the first end of the first switch tube is connected to the first node, the second end of the first switch tube is respectively connected to the second end of the second switch tube and the positive electrode of the first current source, the negative electrode of the first current source is grounded, and the first end of the second switch tube is connected to the second node.

[0020] In one or more embodiments, the signal conversion unit includes a third switch tube, a fourth switch tube, a fifth switch tube, a sixth switch tube, a seventh switch tube, an eighth switch tube, a second current source, a third current source and a fourth current source;

[0021] The first end of the third switch tube is connected to the fourth end of the first signal processing branch, the second end of the third switch tube is respectively connected to the second end of the fourth switch tube and the negative electrode of the second current source, the positive electrode of the second current source is grounded, the third end of the third switch tube is respectively connected to the negative electrode of the third current source, the second end of the fifth switch tube and the second end of the seventh switch tube, the third end of the fourth switch tube is respectively connected to the negative electrode of the fourth current source, the second end of the sixth switch tube and the second end of the eighth switch tube, the first end of the fifth switch tube, the first end of the sixth switch tube, the first end of the seventh switch tube and the first end of the eighth switch tube are all connected to the second input voltage, the third end of the fifth switch tube is connected to the fifth node, the third end of the sixth switch tube is connected to the sixth node, the third end of the seventh switch tube is connected to the seventh node, the third end of the eighth switch tube is connected to the eighth node, and the positive electrodes of the third current source and the fourth current source are both connected to the first input voltage;

[0022] Wherein, the third current source and the fourth current source both output the first input current.

[0023] In one or more embodiments, the current mirror unit includes a ninth switch tube, a tenth switch tube, an eleventh switch tube, a twelfth switch tube and a fifth current source;

[0024] The first end and the third end of the ninth switch tube and the first end of the tenth switch tube are all connected to the fifth node, the third end of the tenth switch tube is connected to the sixth node, the third end of the eleventh switch tube is connected to the seventh node, the first end of the eleventh switch tube and the first end and the third end of the twelfth switch tube are all connected to the eighth node, the second end of the ninth switch tube, the second end of the tenth switch tube, the second end of the eleventh switch tube and the second end of the twelfth switch tube are all connected to the positive electrode of the fifth current source, and the negative electrode of the fifth current source is grounded.

[0025] In one or more embodiments, a sum of a current output by the fifth current source and a current output by the second current source is greater than a sum of a current output by the third current source and a current output by the fourth current source.

[0026] In one or more embodiments, the switch branch includes a thirteenth switch tube and a fourteenth switch tube;

[0027] The first end of the thirteenth switch tube is connected to the third end of the second signal processing branch, the second end of the thirteenth switch tube is connected to the first node, the third end of the thirteenth switch tube is connected to the third node, the first end of the fourteenth switch tube is connected to the fourth end of the second signal processing branch, the second end of the fourteenth switch tube is connected to the second node, and the third end of the fourteenth switch tube is connected to the fourth node.

[0028] In one or more embodiments, the second resistor branch includes a fifth resistor and a sixth resistor;

[0029] The fifth resistor is connected between the third node and the ground, and the sixth resistor is connected between the fourth node and the ground.

[0030] In a second aspect, an embodiment of the present application provides an integrated chip, comprising the current determination circuit as described above.

[0031] In a third aspect, an embodiment of the present application provides an electronic product, including a current sampling resistor and the integrated chip as described above;

[0032] The integrated chip is connected to the current sampling resistor to determine the direction and magnitude of the sampling current flowing through the current sampling resistor.

[0033] The beneficial effect of the present application is that the current determination circuit of the embodiment of the present application is used to connect with the current sampling resistor to determine the direction and magnitude of the sampling current flowing through the current sampling circuit. The current determination circuit includes a first resistor branch, a second resistor branch, a first signal processing branch, a second signal processing branch and a switch branch. Wherein, the first end of the first resistor branch is connected to the first end of the current sampling resistor, the second end of the first resistor branch is connected to the second end of the current sampling resistor, the third end of the first resistor branch is connected to the first end of the first signal processing branch and the third end of the switch branch at the first node, the fourth end of the first resistor branch is connected to the second end of the first signal processing branch and the fourth end of the switch branch at the second node, the third end of the first signal processing branch is connected to the first end of the second signal processing branch, the fourth end of the first signal processing branch is connected to the second end of the second signal processing branch, the third end of the second signal processing branch is connected to the first end of the switch branch, the fourth end of the second signal processing branch is connected to the second end of the switch branch, the fifth end of the switch branch is connected to the first end of the second resistor branch at the third node, and the sixth end of the switch branch is connected to the second end of the second resistor branch at the fourth node. The first signal processing branch is used to amplify the voltage of the first node to the first voltage, and amplify the voltage of the second node to the second voltage. The second signal processing branch is used to convert the first voltage into the first current based on a preset conversion method, and to convert the second voltage into the second current based on a preset conversion method, and to output the first level to the first end of the switch branch and the second level to the second end of the switch branch when the first current is less than the second current, and to output the second level to the first end of the switch branch and the first level to the second end of the switch branch when the first current is greater than the second current. The switch branch is used to establish a connection between the first node and the third node when the first end thereof receives the first level and the second end thereof receives the second level, wherein after the connection between the first node and the third node is established, if the voltage of the first node is equal to the voltage of the second node, the direction and magnitude of the sampling current are determined based on the voltage of the third node. The switch branch is also used to establish a connection between the second node and the fourth node when the first end thereof receives the second level and the second end thereof receives the first level, wherein after the connection between the second node and the fourth node is established, if the voltage of the first node is equal to the voltage of the second node, the direction and magnitude of the sampling current are determined based on the voltage of the fourth node. In summary, when there is a voltage at the third node, it can be determined that the direction of the sampling current flows from the first end of the current sampling resistor to the second end thereof, and the magnitude of the sampling current can be determined based on the voltage at the third node and the resistance value of the current sampling resistor; when there is a voltage at the fourth node, it can be determined that the direction of the sampling current flows from the second end of the current sampling resistor to the first end thereof, and the magnitude of the sampling current can be determined based on the voltage at the fourth node and the resistance value of the current sampling resistor.It can be seen that through the above process, the direction and magnitude of the sampling current flowing through the current sampling resistor can be determined, and it can be applied to sampling currents in two different directions, and has strong practicality. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] One or more embodiments are exemplarily described by the figures in the corresponding drawings, and these exemplary descriptions are not intended to limit the embodiments. Elements with the same reference numerals in the drawings represent similar elements.

[0035] Figure 1 is a schematic diagram of a block diagram of a current determination circuit provided in an embodiment of the present application Figure 1 ;

[0036] Figure 2 is a schematic diagram of a block diagram of a current determination circuit provided in an embodiment of the present application Figure 2 ;

[0037] Figure 3 is with Figure 2 The circuit structure corresponding to the block diagram shown;

[0038] Figure 4 It is a schematic diagram of the composition structure of the integrated chip of the embodiment of the present application;

[0039] Figure 5 It is a schematic diagram of the composition structure of the electronic product of the embodiment of the present application. DETAILED DESCRIPTION

[0040] In order to make the purpose, technical scheme and advantages of the embodiments of the present application clearer, the technical scheme in the embodiments of the present application will be described clearly and in detail in combination with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0041] It should be noted that, when an element is described as being “connected to” another element, it may be directly connected to the other element, or one or more intervening elements may exist therebetween.

[0042] In addition, the technical features involved in the various embodiments of the present application described below can be combined with each other as long as there is no structural conflict between them.

[0043] Please refer to Figure 1 , Figure 1 Schematic diagram of a block diagram of a current determination circuit provided in an embodiment of the present application. Figure 1As shown, the current determination circuit 100 is used to connect with the current sampling resistor RS1 to determine the direction and magnitude of the sampling current flowing through the current sampling resistor RS1. The current determination circuit 100 includes a first resistor branch 10, a second resistor branch 20, a first signal processing branch 30, a second signal processing branch 40 and a switch branch 50.

[0044] The current sampling resistor RS1 is used to detect the magnitude of the current in the target circuit, which is the circuit whose current needs to be obtained. The current sampling resistor RS1 can be connected in series or in parallel to the target circuit.

[0045] In this embodiment, the first end of the first resistor branch 10 is connected to the first end of the current sampling resistor RS1, the second end of the first resistor branch 10 is connected to the second end of the current sampling resistor RS1, the third end of the first resistor branch 10 is connected to the first end of the first signal processing branch 30 and the third end of the switch branch 50 at the first node N1, the fourth end of the first resistor branch 10 is connected to the second end of the first signal processing branch 30 and the fourth end of the switch branch 50 at the second node N2, the third end of the first signal processing branch 30 is connected to the first end of the second signal processing branch 40, the fourth end of the first signal processing branch 30 is connected to the second end of the second signal processing branch 40, the third end of the second signal processing branch 40 is connected to the first end of the switch branch 50, the fourth end of the second signal processing branch 40 is connected to the second end of the switch branch 50, the fifth end of the switch branch 50 is connected to the first end of the second resistor branch 20 at the third node N3, and the sixth end of the switch branch 50 is connected to the second end of the second resistor branch 20 at the fourth node N4.

[0046] Specifically, the first signal processing branch 30 is used to amplify the voltage of the first node N1 into the first voltage V1, and to amplify the voltage of the second node N2 into the second voltage V2. The second signal processing branch 40 is used to convert the first voltage V1 into the first current based on a preset conversion method, and to convert the second voltage V2 into the second current based on a preset conversion method, and to output the first level to the first end of the switch branch 50 and the second level to the second end of the switch branch 50 when the first current is less than the second current, and to output the second level to the first end of the switch branch 50 and the first level to the second end of the switch branch 50 when the first current is greater than the second current. The switch branch 50 is used to establish a connection between the first node N1 and the third node N3 when the first end thereof receives the first level and the second end thereof receives the second level (at this time, the connection between the second node N2 and the fourth node N4 remains disconnected), wherein, after the connection between the first node N1 and the third node N3 is established, if the voltage of the first node N1 is equal to the voltage of the second node N2, the direction and magnitude of the sampling current are determined based on the voltage of the first node N1. The switch branch 50 is further configured to establish a connection between the second node N2 and the fourth node N4 when the first end thereof receives the second level and the second end thereof receives the first level (at this time, the connection between the first node N1 and the third node N3 remains disconnected), wherein, after the connection between the second node N2 and the fourth node N4 is established, if the voltage of the first node N1 is equal to the voltage of the second node N2, the direction and magnitude of the sampling current are determined based on the voltage of the second node N2.

[0047] In this embodiment, the preset conversion mode is a preset mode of converting voltage into current, which can be set based on the actual application scenario. The first level and the second level are different levels. When the first level is a high level, the second level is a low level; when the first level is a low level, the second level is a high level.

[0048] In summary, when there is a voltage at the third node N3, the direction of the sampling current can be determined to flow from the first end of the current sampling resistor RS1 to its second end. At the same time, the magnitude of the sampling current can be determined based on the voltage of the third node N3 and the resistance value of the current sampling resistor RS1. Specifically, since the connection between the second node N2 and the fourth node N4 remains disconnected, no current flows through the branch where the second node N2 and the fourth node N4 are located, and the voltages of the second end and the third end of the first resistor branch 10 (i.e., the voltage of the second node N2) are equal. Since the voltage of the first node N1 is equal to the voltage of the second node N2 at this time, the difference between the voltages of the first end and the third end of the first resistor branch 10 is equal to the difference between the voltages of the first end and the second end of the first resistor branch 10. On the one hand, the difference is equal to the product of the current sampling resistor RS1 (the resistance value of the resistor is a certain value) and the sampling current; on the other hand, it is equal to the product of the resistance of the first end and the second end of the first resistor branch 10 (the resistance value of the resistor is a certain value) and the current, and the current of the first end and the second end of the first resistor branch 10 is equal to the current flowing through the first end of the second resistor branch 20, and the current flowing through the first end of the second resistor branch 20 is equal to the ratio of the voltage of the third node N3 to the partial resistance of the second resistor branch 20 (the resistance value of the resistor is a certain value). It can be seen that, by simply determining the voltage of the third node N3, the magnitude of the sampling current can be reversely deduced according to the above analysis logic.

[0049] When there is a voltage at the fourth node N4, the direction of the sampling current can be determined to flow from the second end of the current sampling resistor RS1 to the first end thereof. Similarly, the magnitude of the sampling current can be determined based on the voltage at the fourth node N4 and the resistance value of the current sampling resistor RS1. The specific analysis process can refer to the process of determining the magnitude of the sampling current based on the voltage at the third node N3 and the resistance value of the current sampling resistor RS1. It is within the scope that can be easily understood by those skilled in the art and will not be described in detail here.

[0050] It can be seen that through the above process, the direction and magnitude of the sampling current flowing through the current sampling resistor RS1 can be determined, and it can be applied to sampling currents in two different directions, and has strong practicality.

[0051] In some embodiments, the current determination circuit 100 further includes a controller, which is connected to the third node N3 and the fourth node N4 respectively to obtain the voltage of the third node N3 and the voltage of the fourth node N4, and determine the magnitude and direction of the sampled current based on the voltage of the third node N3 and the voltage of the fourth node N4. The specific determination process has been described in the above embodiments and will not be repeated here. The controller can be a microcontroller unit (MCU) or a digital signal processing (DSP) controller.

[0052] In one embodiment, if Figure 2 As shown, the second signal processing branch 40 includes a signal conversion unit 41 and a current mirror unit 42 .

[0053] Among them, the first end of the signal conversion unit 41 is connected to the third end of the first signal processing branch 30, the second end of the signal conversion unit 41 is connected to the fourth end of the first signal processing branch 30, the third end of the signal conversion unit 41 and the first end of the current mirror unit 42 are connected to the fifth node N5, the fourth end of the signal conversion unit 41 and the second end of the current mirror unit 42 and the second end of the switch branch 50 are connected to the sixth node N6, the fifth end of the signal conversion unit 41 and the third end of the current mirror unit 42 and the first end of the switch branch 50 are connected to the seventh node N7, the sixth end of the signal conversion unit 41 and the fourth end of the current mirror unit 42 are connected to the eighth node N8, and the seventh end of the signal conversion unit 41 and the eighth end of the signal conversion unit are both input with the first input current.

[0054] Specifically, the signal conversion unit 41 is used to obtain a third current that is positively correlated with the first voltage V1 based on the first voltage V1, and output a first current I1 based on half of the difference between the first input current and the third current, wherein the first current I1 is input to the fifth node N5 and the seventh node N7, respectively. The signal conversion unit 41 is also used to obtain a fourth current that is positively correlated with the second voltage V2 based on the second voltage V2, and output a second current I2 based on half of the difference between the first input current and the fourth current, wherein the second current I2 is input to the sixth node N6 and the eighth node N8, respectively. The current mirror unit 42 is used to mirror the first current I1 input to the fifth node N5 to be output from the sixth node N6, and to mirror the second current I2 input to the eighth node N8 to be output from the seventh node N7.

[0055] Among them, when the first current I1 is less than the second current I2, the sixth node N6 outputs the first level to the first end of the switch branch 50 and the seventh node N7 outputs the second level to the second end of the switch branch 50. The second current I2 is input to the sixth node N6, and the first current I1 is output from the sixth node N6, then the sixth node N6 outputs a high level; the first current I1 is input to the seventh node N7, and the second current I2 is output from the seventh node N7, then the sixth node N6 outputs a low level. It can be understood that in this embodiment, the first level is a high level and the second level is a low level as an example.

[0056] When the first current I1 is greater than the second current, the sixth node N6 outputs the second level to the first end of the switch branch 50 and the seventh node N7 outputs the first level to the second end of the switch branch 50. The second current I2 is input to the sixth node N6, the first current I1 is output from the sixth node N6, and the sixth node N6 outputs a low level; the first current I1 is input to the seventh node N7, the second current I2 is output from the seventh node N7, and the sixth node N6 outputs a high level.

[0057] It is understood that, in this embodiment, the preset conversion mode is to first convert the voltage into a current that is positively correlated with the voltage, and output the final converted current based on half of the difference between the first input current and the current. In addition, in the embodiment of the present application, the positive correlation between the two variables means that the change trends of the two variables are the same, that is, if one variable increases, the other variable also increases; conversely, if one variable decreases, the other variable also decreases.

[0058] Please refer to Figure 3 , Figure 3 An example is shown with Figure 2 A circuit structure corresponding to the block diagram shown in FIG. Figure 3 As shown, the first resistor branch 10 includes a first resistor R1 and a second resistor R2.

[0059] The first resistor R1 is connected between the first end of the current sampling resistor RS1 and the first node N1 , and the second resistor R2 is connected between the second end of the current sampling resistor RS2 and the second node N2 .

[0060] In this embodiment, the first signal processing branch 30 includes a third resistor R3, a fourth resistor R4, a first switch tube Q1, a second switch tube Q2 and a first current source IB1. The first current source IB1 is used to provide a bias current to enable the first switch tube Q1 and the second switch tube Q2 to be turned on.

[0061] Among them, the third resistor R3 is connected between the first input voltage VDD and the third end of the first switch tube Q1, the third end of the first switch tube Q1 is also connected to the first end of the second signal processing branch 40, the fourth resistor R4 is connected between the first input voltage VDD and the third end of the second switch tube Q2, the third end of the second switch tube Q2 is also connected to the second end of the second signal processing branch 40, the first end of the first switch tube Q1 is connected to the first node N1, the second end of the first switch tube Q1 is respectively connected to the second end of the second switch tube Q2 and the positive electrode of the first current source IB1, the negative electrode of the first current source IB1 is grounded GND, and the first end of the second switch tube Q2 is connected to the second node N2.

[0062] It should be noted that, in the embodiment of the present application, all the switch tubes (including the first switch tube Q1 to the fourteenth switch tube Q14) are MOS tubes as an example, wherein the gate of the MOS tube is the first end of each switch tube, the source of the MOS tube is the second end of each switch tube, and the drain of the MOS tube is the third end of each switch tube.

[0063] In addition, each switch tube can be any controllable switch, such as an insulated gate bipolar transistor (IGBT) device, an integrated gate-commutated thyristor (IGCT) device, a gate-turn-off thyristor (GTO) device, a silicon-controlled rectifier (SCR) device, a junction-gate field-effect transistor (JFET) device, a MOS-controlled thyristor (MCT) device, etc.

[0064] In this embodiment, the signal conversion unit 41 includes a third switch tube Q3, a fourth switch tube Q4, a fifth switch tube Q5, a sixth switch tube Q6, a seventh switch tube Q7, an eighth switch tube Q8, a second current source IB2, a third current source IB3 and a fourth current source IB4. The second current source IB2 is used to provide a bias current so that the third switch tube Q3 and the fourth switch tube Q4 can be turned on.

[0065] The first end of the third switch tube Q3 is connected to the fourth end of the first signal processing branch 30, the second end of the third switch tube Q3 is respectively connected to the second end of the fourth switch tube Q4 and the negative electrode of the second current source IB2, the positive electrode of the second current source IB2 is grounded GND, the third end of the third switch tube Q3 is respectively connected to the negative electrode of the third current source IB3, the second end of the fifth switch tube Q5 and the second end of the seventh switch tube Q7, the third end of the fourth switch tube Q4 is respectively connected to the negative electrode of the fourth current source IB4, the second end of the sixth switch tube Q6 and the eighth switch tube Q8 The first end of the fifth switch tube Q5, the first end of the sixth switch tube Q6, the first end of the seventh switch tube Q7 and the first end of the eighth switch tube Q8 are all connected to the second input voltage VBP, the third end of the fifth switch tube Q5 is connected to the fifth node N5, the third end of the sixth switch tube Q6 is connected to the sixth node N6, the third end of the seventh switch tube Q7 is connected to the seventh node N7, the third end of the eighth switch tube Q8 is connected to the eighth node N8, and the positive electrodes of the third current source IB3 and the fourth current source IB4 are both connected to the first input voltage VDD. Among them, the third current source IB3 and the fourth current source IB4 both output the first input current.

[0066] In this embodiment, the current mirror unit 42 includes a ninth switch tube Q9, a tenth switch tube Q10, an eleventh switch tube Q11, a twelfth switch tube Q12 and a fifth current source IB5. The fifth current source IB5 is used to provide a bias current to enable the ninth switch tube Q9, the tenth switch tube Q10, the eleventh switch tube Q11 and the twelfth switch tube Q12 to be turned on.

[0067] Among them, the first end and the third end of the ninth switch tube Q9 and the first end of the tenth switch tube Q10 are all connected to the fifth node N5, the third end of the tenth switch tube Q10 is connected to the sixth node N6, the third end of the eleventh switch tube Q11 is connected to the seventh node N7, the first end of the eleventh switch tube Q11 and the first end and the third end of the twelfth switch tube Q12 are all connected to the eighth node N8, the second end of the ninth switch tube Q9, the second end of the tenth switch tube Q10, the second end of the eleventh switch tube Q11 and the second end of the twelfth switch tube Q12 are all connected to the positive electrode of the fifth current source IB5, and the negative electrode of the fifth current source IB5 is grounded GND.

[0068] In this embodiment, the switch branch 50 includes a thirteenth switch tube Q13 and a fourteenth switch tube Q14.

[0069] Among them, the first end of the thirteenth switch tube Q13 is connected to the third end of the second signal processing branch 40, the second end of the thirteenth switch tube Q13 is connected to the first node N1, the third end of the thirteenth switch tube Q13 is connected to the third node N3, the first end of the fourteenth switch tube Q14 is connected to the fourth end of the second signal processing branch 40, the second end of the fourteenth switch tube Q14 is connected to the second node N2, and the third end of the fourteenth switch tube Q14 is connected to the fourth node N4.

[0070] In this embodiment, the second resistor branch 20 includes a fifth resistor R5 and a sixth resistor R6.

[0071] The fifth resistor R5 is connected between the third node N3 and the ground GND, and the sixth resistor R6 is connected between the fourth node N4 and the ground GND.

[0072] In one embodiment, the sum of the current output by the fifth current source IB5 and the current output by the second current source IB2 is greater than the sum of the current output by the third current source IB3 and the current output by the fourth current source IB4, so that when the first level or the second level is a high level, the voltage corresponding to the high level is close to or equal to the first input voltage VDD, so as to ensure that only one of the thirteenth switch tube Q13 and the fourteenth switch tube Q14 is turned on, and then ensure that only one of the third node N3 and the fourth node N4 has a voltage, so as to improve the reliability and accuracy of detecting the sampling current.

[0073] The following Figure 3 The principle of the circuit structure shown is explained.

[0074] When the sampling current flows from the first end to the second end of the current sampling resistor RS1, that is, when the sampling current (recorded as IRS1) flows from the left side to the right side of the current sampling resistor RS1, the voltage at the first end of the current sampling resistor RS1 (recorded as VIP) is greater than the voltage at the second end of the current sampling resistor RS1 (recorded as VIN), that is, VIP>VIN. In this case, when the current determination circuit 100 is just started, the current flowing through the first resistor R1 and the second resistor R2 are both 0, so the voltage VIP_R of the first node N1=VIP>VIN=the voltage VIN_R of the second node N2. Then the current flowing through the first switch tube Q1 is greater than the current flowing through the second switch tube Q2, V1>V2. The current flowing through the third switch tube Q3 (referred to as IQ3) is greater than the current flowing through the fourth switch tube Q4 (referred to as IQ4). The third current source IB3 and the fourth current source IB4 both output the first input current (referred to as Iin). Assuming that the fifth switch tube Q5 and the seventh switch tube Q7 are configured as the same switch tube, and the sixth switch tube Q6 and the eighth switch tube Q8 are configured as the same switch tube, the current flowing through the fifth switch tube Q5 is the first current I1, the current flowing through the sixth switch tube Q6 is the second current I2, the current flowing through the seventh switch tube Q7 is the first current I1, and the current flowing through the eighth switch tube Q8 is the second current I2. It can be obtained that Iin=IQ3+2I1=IQ4+2I2. Combined with IQ3>IQ4, it can be obtained that I1<I2. The current flowing through the fifth switch tube Q5 is mirrored to the current flowing through the tenth switch tube Q10, that is, the first current I1 flows out from the sixth node N6, and the second current I2 flows into the sixth node N6, then the sixth node N6 outputs a high level (that is, the voltage V4 of the sixth node N6 is a high level), and the fourteenth switch tube Q14 is turned off. At the same time, the current flowing through the eighth switch tube Q8 is mirrored to the current flowing through the eleventh switch tube Q11, that is, the second current I2 flows out from the seventh node N7, and the first current I1 flows into the seventh node N7, then the seventh node N7 outputs a low level (that is, the voltage V4 of the seventh node N7 is a low level), and the thirteenth switch tube Q13 is turned on. Subsequently, the connection between the first node N1 and the third node N3 is established, and the connection between the second node N2 and the fourth node N4 is disconnected. Current flows through the first resistor R1 (this current is recorded as IR1), and no current flows through the second resistor R2 until the voltage of the first node N1 is equal to the voltage of the second node N2, that is, VIP_R=VIN_R, and the stable operating point of the current determination circuit 100 is reached. At this time, various parameters in the current determination circuit 100 remain unchanged.

[0075] At this time, since there is no current flowing through the second resistor R2, VIN=VIN_R. And since VIP_R=VIN_R, IR1=(VIP-VIP_R) / R1=(VIP-VIN) / R1. At the same time, VIP-VIN is the voltage across the current sampling resistor RS1, then VIP-VIN=IRS1*RS1. The current flowing through the first resistor R1 is also the current flowing through the fifth resistor R5. The voltage of the third node N3 is recorded as VN3, then VN3=IR1*R5=(VIP-VIN) / R1*R5=IRS1*RS1 / R1*R5. It can be seen that when the resistance values ​​of the current sampling resistor RS1, the first resistor R1 and the fifth resistor R5 are all determined, the size of the sampling current IRS1 can be determined according to the voltage VN3 of the third node N3 obtained. As long as there is a voltage on the third node N3, it can be determined that the direction of the sampling current IRS1 is from the first end of the current sampling resistor RS1 to the second end.

[0076] When the sampling current flows from the second end to the first end of the current sampling resistor RS1, that is, the sampling current IRS1 flows from the right side to the left side of the current sampling resistor RS1, VIP<VIN. In this case, when the current determination circuit 100 is just started, the current flowing through the first resistor R1 and the second resistor R2 are both 0, so VIP_R=VIP<VIN=VIN_R. Then the current flowing through the first switch tube Q1 is less than the current flowing through the second switch tube Q2, V1<V2, so IQ3<IQ4. Combined with Iin=IQ3+2I1=IQ4+2I2, it can be obtained that I1>I2. The first current I1 flows out from the sixth node N6, and the second current I2 flows into the sixth node N6, then the sixth node N6 outputs a low level (that is, the voltage V4 of the sixth node N6 is a low level), and the fourteenth switch tube Q14 is turned on. At the same time, the second current I2 flows out from the seventh node N7, and the first current I1 flows into the seventh node N7, then the seventh node N7 outputs a high level (i.e., the voltage V4 of the seventh node N7 is a high level), and the thirteenth switch tube Q13 is disconnected. Then, the connection between the first node N1 and the third node N3 is disconnected, and the connection between the second node N2 and the fourth node N4 is established. A current flows through the second resistor R2 (this current is recorded as IR2), and no current flows through the first resistor R1, until the voltage of the first node N1 is equal to the voltage of the second node N2, i.e., VIP_R=VIN_R, and the stable operating point of the current determination circuit 100 is reached, and at this time, the various parameters in the current determination circuit 100 remain unchanged.

[0077] At this time, since there is no current flowing through the first resistor R1, VIP=VIP_R. And since VIP_R=VIN_R, IR2=(VIN-VIN_R) / R2=(VIN-VIP) / R2. Let the voltage of the third node N3 be VN3, and combined with VIN-VIP=IRS1*RS1, it can be obtained that VN4=IR2*R6=(VIN-VIP) / R2*R6=IRS1*RS1 / R2*R6. It can be seen that when the resistance values ​​of the current sampling resistor RS1, the second resistor R2 and the sixth resistor R6 are all determined, the size of the sampling current IRS1 can be determined according to the voltage VN4 of the fourth node N4 obtained. As long as there is a voltage on the fourth node N4, it can be determined that the direction of the sampling current IRS1 is from the second end of the current sampling resistor RS1 to the first end.

[0078] In addition, in this embodiment, it can be further limited that the sum of the current output by the fifth current source IB5 and the current output by the second current source IB2 is greater than the sum of the current output by the third current source IB3 and the current output by the fourth current source IB4. Then, when the current determination circuit 100 is actually running, the current flowing out of the power supply is equal to the current flowing into the ground, that is, the third current source IB3 and the fourth current source IB4 (wherein, in this embodiment, the third current source IB3 and the fourth current source IB4 are also implemented by MOS tubes, and the specific implementation process is within the scope of easy understanding by those skilled in the art, and will not be repeated here) will enter the linear region, so that the drain-source voltage VDS of the switch tubes in the third current source IB3 and the fourth current source IB4 is very small, so it can ensure that the voltage V3 or the voltage V4 can output close to or equal to the first input voltage VDD, so that it can ensure that one of the thirteenth switch tube Q13 and the fourteenth switch tube Q14 is turned on, and only one is turned on, which is conducive to improving the reliability and accuracy of detecting the sampling current.

[0079] Please refer to Figure 4 , Figure 4 Schematic diagram of the composition structure of the integrated chip provided in the embodiment of the present application. Figure 4 As shown, the integrated chip 1000 includes the current determination circuit 100 in any embodiment of the present application.

[0080] Please refer to Figure 5 , Figure 5 This is a schematic diagram of the composition structure of the electronic product provided in the embodiment of the present application. Figure 5 As shown, the electronic product 1 includes a current sampling resistor RS1 and an integrated chip 1000 in any embodiment of the present application.

[0081] The current determination circuit 100 in the integrated chip 1000 is connected to the current sampling resistor RS1 to determine the direction and magnitude of the sampling current flowing through the current sampling resistor RS1 .

[0082] The above descriptions are merely embodiments of the present application and are not intended to limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made using the contents of the present application specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present application.

[0083] The above embodiments are only used to illustrate the technical solutions of the present application, but not to limit them. Under the idea of ​​the present application, the technical features in the above embodiments or different embodiments can also be combined, and the steps can be implemented in any order. It should be understood by ordinary technicians in this field that they can still modify the technical solutions recorded in the above embodiments, or replace some of the technical features by equivalents; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the scope of the technical solutions of the embodiments of the present application.

Claims

1. A current determination circuit, characterized in that: Used to be connected to a current sampling resistor to determine the direction and magnitude of a sampling current flowing through the current sampling resistor, the current determination circuit comprising a first resistor branch, a second resistor branch, a first signal processing branch, a second signal processing branch and a switch branch; The first end of the first resistor branch is connected to the first end of the current sampling resistor, the second end of the first resistor branch is connected to the second end of the current sampling resistor, the third end of the first resistor branch is connected to the first end of the first signal processing branch and the third end of the switch branch at a first node, the fourth end of the first resistor branch is connected to the second end of the first signal processing branch and the fourth end of the switch branch at a second node, the third end of the first signal processing branch is connected to the first end of the second signal processing branch, the fourth end of the first signal processing branch is connected to the second end of the second signal processing branch, the third end of the second signal processing branch is connected to the first end of the switch branch, the fourth end of the second signal processing branch is connected to the second end of the switch branch, the fifth end of the switch branch is connected to the first end of the second resistor branch at a third node, and the sixth end of the switch branch is connected to the second end of the second resistor branch at a fourth node; The first signal processing branch is used to amplify the voltage of the first node into a first voltage, and amplify the voltage of the second node into a second voltage; The second signal processing branch is used to convert the first voltage into a first current based on a preset conversion method, and is used to convert the second voltage into a second current based on the preset conversion method, and is used to output a first level to a first end of the switch branch and a second level to a second end of the switch branch when the first current is less than the second current, and is also used to output a second level to a first end of the switch branch and a first level to a second end of the switch branch when the first current is greater than the second current; The switch branch is used to establish a connection between the first node and the third node when the first end thereof receives the first level and the second end thereof receives the second level, wherein after the connection between the first node and the third node is established, if the voltage of the first node is equal to the voltage of the second node, the direction and magnitude of the sampling current are determined based on the voltage of the third node; The switch branch is further used to establish a connection between the second node and the fourth node when the first end thereof receives the second level and the second end thereof receives the first level, wherein after the connection between the second node and the fourth node is established, if the voltage of the first node is equal to the voltage of the second node, the direction and magnitude of the sampling current are determined based on the voltage of the fourth node.

2. The current determination circuit according to claim 1, characterized in that: The second signal processing branch includes a signal conversion unit and a current mirror unit; The first end of the signal conversion unit is connected to the third end of the first signal processing branch, the second end of the signal conversion unit is connected to the fourth end of the first signal processing branch, the third end of the signal conversion unit and the first end of the current mirror unit are connected to a fifth node, the fourth end of the signal conversion unit and the second end of the current mirror unit and the second end of the switch branch are connected to a sixth node, the fifth end of the signal conversion unit and the third end of the current mirror unit and the first end of the switch branch are connected to a seventh node, the sixth end of the signal conversion unit and the fourth end of the current mirror unit are connected to an eighth node, and the seventh end of the signal conversion unit and the eighth end of the signal conversion unit are both input with the first input current; The signal conversion unit is used to obtain a third current that is positively correlated with the first voltage based on the first voltage, and output the first current based on half of the difference between the first input current and the third current, wherein the first current is input to the fifth node and the seventh node respectively; The signal conversion unit is further used for obtaining a fourth current having a positive correlation with the second voltage based on the second voltage, and outputting the second current based on half of the difference between the first input current and the fourth current, wherein the second current is input to the sixth node and the eighth node respectively; The current mirror unit is used to mirror the first current input to the fifth node to be output from the sixth node, and to mirror the second current input to the eighth node to be output from the seventh node, wherein when the first current is less than the second current, the sixth node outputs the first level to the first end of the switch branch and the seventh node outputs the second level to the second end of the switch branch, and when the first current is greater than the second current, the sixth node outputs the second level to the first end of the switch branch and the seventh node outputs the first level to the second end of the switch branch.

3. The current determination circuit according to claim 1, characterized in that: The first resistor branch includes a first resistor and a second resistor; The first resistor is connected between a first end of the current sampling resistor and the first node, and the second resistor is connected between a second end of the current sampling resistor and the second node.

4. The current determination circuit according to claim 1, characterized in that: The first signal processing branch includes a third resistor, a fourth resistor, a first switch tube, a second switch tube and a first current source; The third resistor is connected between the first input voltage and the third end of the first switch tube, the third end of the first switch tube is also connected to the first end of the second signal processing branch, the fourth resistor is connected between the first input voltage and the third end of the second switch tube, the third end of the second switch tube is also connected to the second end of the second signal processing branch, the first end of the first switch tube is connected to the first node, the second end of the first switch tube is respectively connected to the second end of the second switch tube and the positive electrode of the first current source, the negative electrode of the first current source is grounded, and the first end of the second switch tube is connected to the second node.

5. The current determination circuit according to claim 2, characterized in that: The signal conversion unit includes a third switch tube, a fourth switch tube, a fifth switch tube, a sixth switch tube, a seventh switch tube, an eighth switch tube, a second current source, a third current source and a fourth current source; The first end of the third switch tube is connected to the fourth end of the first signal processing branch, the first end of the fourth switch tube is connected to the third end of the first signal processing branch, the second end of the third switch tube is respectively connected to the second end of the fourth switch tube and the negative electrode of the second current source, the positive electrode of the second current source is grounded, the third end of the third switch tube is respectively connected to the negative electrode of the third current source, the second end of the fifth switch tube and the second end of the seventh switch tube, the third end of the fourth switch tube is respectively connected to the negative electrode of the fourth current source, the second end of the sixth switch tube and the second end of the eighth switch tube, the first end of the fifth switch tube, the first end of the sixth switch tube, the first end of the seventh switch tube and the first end of the eighth switch tube are all connected to the second input voltage, the third end of the fifth switch tube is connected to the fifth node, the third end of the sixth switch tube is connected to the sixth node, the third end of the seventh switch tube is connected to the seventh node, the third end of the eighth switch tube is connected to the eighth node, and the positive electrodes of the third current source and the fourth current source are both connected to the first input voltage; Wherein, the third current source and the fourth current source both output the first input current.

6. The current determination circuit according to claim 5, characterized in that: The current mirror unit includes a ninth switch tube, a tenth switch tube, an eleventh switch tube, a twelfth switch tube and a fifth current source; The first end and the third end of the ninth switch tube and the first end of the tenth switch tube are all connected to the fifth node, the third end of the tenth switch tube is connected to the sixth node, the third end of the eleventh switch tube is connected to the seventh node, the first end of the eleventh switch tube and the first end and the third end of the twelfth switch tube are all connected to the eighth node, the second end of the ninth switch tube, the second end of the tenth switch tube, the second end of the eleventh switch tube and the second end of the twelfth switch tube are all connected to the positive electrode of the fifth current source, and the negative electrode of the fifth current source is grounded.

7. The current determination circuit according to claim 6, characterized in that: The sum of the current output by the fifth current source and the current output by the second current source is greater than the sum of the current output by the third current source and the current output by the fourth current source.

8. The current determination circuit according to claim 1, characterized in that: The switch branch includes a thirteenth switch tube and a fourteenth switch tube; The first end of the thirteenth switch tube is connected to the third end of the second signal processing branch, the second end of the thirteenth switch tube is connected to the first node, the third end of the thirteenth switch tube is connected to the third node, the first end of the fourteenth switch tube is connected to the fourth end of the second signal processing branch, the second end of the fourteenth switch tube is connected to the second node, and the third end of the fourteenth switch tube is connected to the fourth node.

9. The current determination circuit according to claim 1, characterized in that: The second resistor branch includes a fifth resistor and a sixth resistor; The fifth resistor is connected between the third node and the ground, and the sixth resistor is connected between the fourth node and the ground.

10. An integrated chip, characterized in that: The method comprises a current determination circuit as claimed in any one of claims 1 to 9.

11. An electronic product, characterized in that: comprising a current sampling resistor and the integrated chip as claimed in claim 10; The integrated chip is connected to the current sampling resistor to determine the direction and magnitude of the sampling current flowing through the current sampling resistor.