Voltage detection circuit and voltage detection method
By designing a threshold setting module and a voltage conversion module for the voltage detection circuit, and utilizing the threshold adjustment signal and control voltage, the voltage adjustment range can be flexibly set, solving the problem that the threshold of the existing voltage detection circuit cannot be adjusted, and improving the efficiency and adaptability of voltage detection.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- CHANGXIN MEMORY TECH INC
- Filing Date
- 2022-06-17
- Publication Date
- 2026-07-17
AI Technical Summary
The detection threshold of existing voltage detection circuits cannot be flexibly adjusted, making them unable to adapt to the needs of unstable processes or changes in components.
A voltage detection circuit is designed, which uses a threshold setting module and a voltage conversion module to achieve flexible setting of the voltage regulation range by using a threshold adjustment signal and a control voltage. It includes multiple predetermined voltage regulation ranges and a control unit, and realizes voltage regulation through switching elements and transistors.
It enables flexible adjustment of the voltage detection threshold, adapting to different environments and detection needs, thus improving the efficiency and flexibility of voltage detection.
Smart Images

Figure CN117330808B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of electronic circuit technology, and more specifically, to a voltage detection circuit and voltage detection method that can flexibly adjust the voltage detection threshold. Background Technology
[0002] Voltage detection circuits are commonly used functional circuits in circuit design. After setting a detection threshold, they determine whether the voltage has reached a target value. When the process is unstable or the components change, the detection threshold also needs to be changed accordingly. However, voltage detection circuits in related technologies usually have a fixed threshold, which cannot meet the threshold adjustment requirements. Therefore, developing voltage detection circuits with threshold adjustment capabilities has become an important need in this field.
[0003] It should be noted that the information disclosed in the background section above is only used to enhance the understanding of the background of this disclosure, and therefore may include information that does not constitute prior art known to those skilled in the art. Summary of the Invention
[0004] The purpose of this disclosure is to provide a voltage detection circuit and a voltage detection method, which at least to some extent overcomes the problem that the voltage detection threshold of the voltage detection circuit cannot be flexibly adjusted due to the limitations and defects of related technologies.
[0005] According to a first aspect of this disclosure, a voltage detection circuit is provided, comprising: a threshold setting module having a first input terminal, a second input terminal, and a power supply terminal; the first input terminal being used to receive a voltage to be measured; the second input terminal being used to receive a threshold adjustment signal; the power supply terminal being used to connect to a first voltage; and being used to set a voltage adjustment range according to the threshold adjustment signal, determine a first voltage adjustment value according to the voltage to be measured within the voltage adjustment range, and generate a control voltage according to the first voltage and the first voltage adjustment value; and a voltage conversion module having an input terminal receiving the control voltage through a first node, and being used to output a first level when the control voltage is greater than a preset value, and to output a second level when the control voltage is less than or equal to the preset value.
[0006] In one exemplary embodiment of this disclosure, the device further includes a voltage bias module connected to the first node, for providing a bias voltage to the input terminal of the voltage conversion module.
[0007] In one exemplary embodiment of this disclosure, the threshold setting module has a plurality of predetermined voltage adjustment ranges, and the threshold adjustment signal is used to select one of the plurality of voltage adjustment ranges.
[0008] In one exemplary embodiment of this disclosure, the threshold setting module includes a plurality of threshold setting units and a plurality of control units, each control unit being connected to one or more threshold setting units, and each control unit being configured to enable one or more threshold setting units in response to the threshold adjustment signal.
[0009] In one exemplary embodiment of this disclosure, the voltage adjustment ranges corresponding to the plurality of threshold setting units are equal, or the voltage adjustment range of at least one threshold setting unit is different from the voltage adjustment ranges of the other threshold setting units.
[0010] In one exemplary embodiment of this disclosure, each control unit is connected to one or more threshold setting units. When the number of control units is greater than one, at least two control units are connected to the same threshold setting unit, or different control units are connected to different threshold setting units.
[0011] In one exemplary embodiment of this disclosure, the control unit includes a switching element, a first end of which is connected to a first end of a corresponding threshold setting unit, and a second end of which is connected to a second end of a corresponding threshold setting unit.
[0012] In one exemplary embodiment of this disclosure, the control terminal of the control unit is used to receive the threshold adjustment signal or the inverted signal of the threshold adjustment signal; or, the threshold adjustment signal includes a plurality of different threshold adjustment sub-signals, and the control terminal of each control unit corresponds to one threshold adjustment sub-signal, and the threshold adjustment sub-signals connected to different control units are the same or different.
[0013] In an exemplary embodiment of this disclosure, each threshold setting unit includes one or more transistors connected in series, and the threshold setting module includes: M transistors connected in series, the gates of the transistors are all coupled to the first input terminal, the first terminal of the first transistor is coupled to the power supply terminal, the second terminal is connected to the first terminal of the second transistor, the second terminal of the Mth transistor is connected to the first node, and the first terminal is connected to the second terminal of the (M-1)th transistor, where M is greater than or equal to 2.
[0014] In one exemplary embodiment of this disclosure, the switching element is implemented using a transistor.
[0015] In one exemplary embodiment of this disclosure, the voltage conversion module includes: a detection unit having a power supply terminal, an input terminal, and an output terminal, wherein the power supply terminal is used to connect to the second voltage, the input terminal is connected to the first node, the detection unit is used to determine a second voltage adjustment value based on the control voltage of the first node, and output a detection voltage through the output terminal based on the second voltage and the second voltage adjustment value; and a level conversion unit having an input terminal connected to the output terminal of the detection unit, used to output the first level or the second level based on the detection voltage.
[0016] In one exemplary embodiment of this disclosure, the detection unit includes: a first P-type transistor, the gate of which is connected to the first node as the input terminal of the voltage conversion module, the source of which is connected to the power supply terminal, and the drain of which is connected to the second node, the second node being connected to the input terminal of the level conversion unit; and a first resistor unit, the first end of which is connected to the second node, and the second end of which is grounded.
[0017] In one exemplary embodiment of this disclosure, the level conversion unit includes an inverter.
[0018] In one exemplary embodiment of this disclosure, the voltage biasing module includes: a second P-type transistor, the source of which is connected to the second voltage, and the gate and drain of which are connected to the first node; and a second resistor unit, the first end of which is connected to the first node, and the second end of which is grounded.
[0019] According to a second aspect of this disclosure, a voltage detection method is provided, applied to a voltage detection circuit as described in any of the preceding claims, comprising: outputting a threshold adjustment signal to set a voltage adjustment range; determining a first voltage adjustment value based on a voltage to be measured within the voltage adjustment range; determining a control voltage based on the first voltage adjustment value and the first voltage; detecting the control voltage; outputting a first level when the control voltage is greater than a preset value; and outputting a second level when the control voltage is less than or equal to the preset value.
[0020] In one exemplary embodiment of this disclosure, detecting the control voltage includes: determining a second voltage adjustment value based on the control voltage; outputting a detection voltage based on the second voltage adjustment value and the second voltage; outputting a first level when the detection voltage is greater than a preset flip level, and outputting a second level when the detection voltage is less than the preset flip level.
[0021] The voltage detection circuit provided in this embodiment determines the voltage adjustment range based on the threshold adjustment signal, and determines the voltage adjustment value based on the voltage to be measured being within the voltage adjustment range. It can achieve flexible adjustment of the detection threshold by detecting the control voltage generated based on the voltage adjustment value, and realize multiple voltage detection threshold setting schemes through one circuit.
[0022] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure. Attached Figure Description
[0023] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this disclosure and, together with the description, serve to explain the principles of this disclosure. It is obvious that the drawings described below are merely some embodiments of this disclosure, and those skilled in the art can obtain other drawings based on these drawings without any inventive effort.
[0024] Figure 1 This is a schematic diagram of the voltage detection circuit in an exemplary embodiment of this disclosure.
[0025] Figure 2 This is a schematic diagram of a threshold setting module in one embodiment of this disclosure.
[0026] Figure 3 This is a schematic diagram of a control unit in one embodiment of the present disclosure.
[0027] Figure 4 This is a schematic diagram of a threshold setting module and a control unit in one embodiment of this disclosure.
[0028] Figure 5 This is a schematic diagram of a voltage conversion module in one embodiment of the present disclosure.
[0029] Figure 6 This is a circuit diagram of a voltage conversion module in one embodiment of the present disclosure.
[0030] Figure 7 This is a circuit diagram of a voltage detection circuit in one embodiment of the present disclosure.
[0031] Figure 8 This is a flowchart of a voltage detection method in one embodiment of the present disclosure. Detailed Implementation
[0032] Example embodiments will now be described more fully with reference to the accompanying drawings. However, example embodiments can be implemented in many forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided to make this disclosure more comprehensive and complete, and to fully convey the concept of the example embodiments to those skilled in the art. The described features, structures, or characteristics can be combined in any suitable manner in one or more embodiments. In the following description, numerous specific details are provided to give a full understanding of embodiments of this disclosure. However, those skilled in the art will recognize that the technical solutions of this disclosure can be practiced with one or more of the specific details omitted, or other methods, components, apparatus, steps, etc., can be employed. In other instances, well-known technical solutions are not shown or described in detail to avoid obscuring various aspects of this disclosure.
[0033] Furthermore, the accompanying drawings are merely illustrative of this disclosure, and the same reference numerals in the drawings denote the same or similar parts, thus repeated descriptions of them will be omitted. Some block diagrams shown in the drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities may be implemented in software, in one or more hardware modules or integrated circuits, or in different network and / or processor devices and / or microcontroller devices.
[0034] The exemplary embodiments of this disclosure will now be described in detail with reference to the accompanying drawings.
[0035] Figure 1 This is a schematic diagram of the voltage detection circuit in an exemplary embodiment of this disclosure.
[0036] refer to Figure 1 The voltage detection circuit 100 may include:
[0037] The threshold setting module 11 has a first input terminal, a second input terminal, and a power supply terminal. The first input terminal is used to receive the voltage to be measured Vs, the second input terminal is used to receive the threshold adjustment signal SCON, and the power supply terminal is used to connect to the first voltage V1. It is used to set the voltage adjustment range according to the threshold adjustment signal SCON, determine the first voltage adjustment value ΔV1 according to the voltage to be measured Vs within the voltage adjustment range, and generate the control voltage VN1 according to the first voltage V1 and the first voltage adjustment value ΔV1.
[0038] Voltage conversion module 12, the input terminal is through the first node N1 (reference) Figure 7 It receives control voltage VN1 and outputs a first level S1 when the control voltage VN1 is greater than a preset value, and outputs a second level S2 when the control voltage VN1 is less than or equal to the preset value.
[0039] In one embodiment of this disclosure, the threshold setting module 11 has multiple predetermined voltage adjustment ranges. The threshold adjustment signal SCON is used to select one voltage adjustment range from the multiple voltage adjustment ranges as the target voltage adjustment range (including the highest adjustment voltage, the lowest adjustment voltage, and the voltage between the highest adjustment voltage and the lowest adjustment voltage). The voltage to be measured Vs is set with a first voltage adjustment value ΔV1 within the target voltage adjustment range. The voltage of the first node N1 is adjusted by the first voltage adjustment value ΔV1, thereby causing the threshold adjustment module 11 to output the adjusted control voltage VN1.
[0040] When the voltage under test Vs changes, the first voltage adjustment value ΔV1 output according to the voltage under test Vs changes, the control voltage VN1 changes, and the voltage conversion module 12 outputs the first level S1 or the second level S2 based on the changed control voltage VN1.
[0041] By setting multiple selectable voltage adjustment ranges and determining the first voltage adjustment value ΔV1 based on the measured voltage Vs within the selected target voltage adjustment range, the voltage adjustment range can be reselected at any time via the threshold adjustment signal SCON. When the measured voltage Vs changes, the range and amplitude of the control voltage VN1 remain unchanged, allowing the detection threshold of the measured voltage Vs to be changed without modifying the detection threshold of the voltage conversion module 12. The analysis is as follows:
[0042] When it is necessary to increase the detection threshold of the voltage under test Vs, the voltage conversion module 12 should only undergo a level flip when the voltage under test Vs is high. Since the flipping condition of the voltage conversion module 12 remains unchanged, the control voltage VN1 during the flip must also remain constant. Simultaneously, since the first voltage V1 that generates the control voltage VN1 remains unchanged, the corresponding first voltage adjustment value ΔV1 remains unchanged. In other words, to increase the detection threshold of the voltage under test Vs, the voltage under test Vs corresponding to the first voltage adjustment value ΔV1 needs to increase. This requires that when the voltage under test Vs has not risen to the detection threshold, the first voltage adjustment value ΔV1 should not reach the first voltage adjustment value ΔV1 corresponding to the level flip of the voltage conversion module 12. The first voltage adjustment value ΔV1 is set by the voltage under test Vs within the target voltage adjustment range, and it changes with either the voltage under test Vs or the target voltage adjustment range. Therefore, when the detection threshold of the voltage under test Vs increases, the target voltage adjustment range needs to be adjusted.
[0043] When the first voltage adjustment value ΔV1 is positively correlated with the voltage under test Vs, the target voltage adjustment range needs to be reselected to reduce the highest and lowest adjustment voltages within the target voltage adjustment range, thereby maintaining the first voltage adjustment value ΔV1 unchanged when the voltage under test Vs increases. When the first voltage adjustment value ΔV1 is inversely proportional to the voltage under test Vs, the target voltage adjustment range needs to be reselected to increase the highest and lowest adjustment voltages within the target voltage adjustment range, thereby maintaining the first voltage adjustment value ΔV1 unchanged when the voltage under test Vs increases.
[0044] Accordingly, when it is necessary to lower the detection threshold of the voltage under test Vs, the voltage conversion module 12 is required to flip its level only when the voltage under test Vs is low. As analyzed above, this requires that when the voltage under test Vs has not dropped to the detection threshold, the first voltage adjustment value ΔV1 cannot reach the first voltage adjustment value ΔV1 corresponding to the voltage conversion module 12 level flip. The first voltage adjustment value ΔV1 is set by the voltage under test Vs within the target voltage adjustment range. Therefore, when the detection threshold of the voltage under test Vs is lowered, the target voltage adjustment range needs to be adjusted.
[0045] When the first voltage adjustment value ΔV1 is directly proportional to the voltage under test Vs, the target voltage adjustment range needs to be reselected to increase the highest and lowest adjustment voltages within the target voltage adjustment range, thereby maintaining the first voltage adjustment value ΔV1 unchanged when the voltage under test Vs decreases. When the first voltage adjustment value ΔV1 is inversely proportional to the voltage under test Vs, the target voltage adjustment range needs to be reselected to decrease the highest and lowest adjustment voltages within the target voltage adjustment range, thereby maintaining the first voltage adjustment value ΔV1 unchanged when the voltage under test Vs decreases.
[0046] Therefore, the voltage detection circuit provided in this embodiment can flexibly adjust the detection threshold of the voltage under test Vs through the threshold adjustment signal SCON, and can be applied in circuits with various environments and various detection requirements to achieve efficient voltage detection.
[0047] Several embodiments of the voltage detection circuit are described below.
[0048] Figure 2 This is a schematic diagram of a threshold setting module in one embodiment of this disclosure.
[0049] refer to Figure 2 In one exemplary embodiment of this disclosure, the threshold setting module 11 includes a plurality of threshold setting units 111 and a plurality of control units 112. Each control unit 112 is connected to one or more threshold setting units 111. Each control unit 112 is used to enable one or more corresponding threshold setting units 111 in response to a threshold adjustment signal SCON. Figure 2The number and connection relationship of the threshold setting unit 111 and the control unit 112 shown are only examples. In practical applications, the number and connection relationship of the threshold setting unit 111 and the control unit 112 can be flexibly set according to the threshold setting requirements. It should be noted that this adjustable number and connection relationship is not fixed in advance, but can be switched by control signals.
[0050] Multiple threshold setting units 111 may correspond to the same voltage adjustment range, or the voltage adjustment range of at least one threshold setting unit 111 may differ from the voltage adjustment ranges of the other threshold setting units 111. When the voltage adjustment ranges of multiple threshold setting units 111 are equal, the voltage adjustment range can be set by adjusting the number of enabled threshold setting units 111, resulting in a simple and efficient control logic. When the voltage adjustment range of at least one threshold setting unit 111 differs from the voltage adjustment ranges of the other threshold setting units 111, threshold setting units 111 with different voltage adjustment ranges can be combined to make the number of voltage adjustment ranges much greater than the number of threshold setting units 111, thereby increasing the richness of threshold adjustment schemes.
[0051] In one embodiment of this disclosure, each control unit 112 is connected to one or more threshold setting units 111. This expands the voltage regulation range selectable by the control unit 112, enabling voltage regulation ranges that cannot be achieved by a single threshold setting unit 111. When the number of control units 112 is greater than one, at least two control units 112 are connected to the same threshold setting unit 111, or different control units 112 are connected to different threshold setting units 111. When different control units 112 are connected to different threshold setting units 111, the control units 112 and threshold setting units 111 have a fixed correspondence, the control logic is relatively simple, and troubleshooting is easy. When two or more control units 112 are connected to the same threshold setting unit 111, a large voltage regulation range can be achieved with a small number of threshold setting units, such as... Figure 2 As shown, when the voltage adjustment ranges of the three threshold setting units 111 are different, if different control units 112 are allowed to jointly control one threshold setting unit 111, a maximum of 7 voltage adjustment range setting schemes can be realized.
[0052] In addition, the control terminal of the control unit 112 can be used to receive a threshold adjustment signal or an inverted signal of the threshold adjustment signal; or, the threshold adjustment signal contains multiple different threshold adjustment sub-signals, and the control terminal of each control unit 112 corresponds to a threshold adjustment sub-signal, and the threshold adjustment sub-signals connected to different control units 112 may be the same or different.
[0053] In one embodiment, when enabling control unit 112, it can be divided into two groups, each group including one or more control units 112. One group of control units receives a threshold adjustment signal, and the other group receives the inverted signal of the threshold adjustment signal. The inverted signal of the threshold adjustment signal is, for example, a signal processed by a component or combination of components with signal inversion function. Components with signal inversion function include, but are not limited to, inverters, NAND gates, NOR gates, and combinations of multiple components. When one group of control units 112 is enabled, the other group of control units 112 stops working, thereby achieving two voltage adjustment ranges. It is understood that the grouping of control units 112 differs depending on the enabling control, to obtain the corresponding signal adjustment range.
[0054] The number of control units 112 in each group can be either one or multiple. When there are multiple control units 112 in each group, enabling a group of control units 112 simultaneously can expand the maximum voltage regulation range, achieving a voltage regulation range that a single control unit 112 connected to multiple threshold setting units 111 cannot achieve. For example, due to limitations such as drive capability, a single control unit 112 can connect to a maximum of x threshold setting units 111, and each threshold setting unit 111 can achieve a voltage regulation range of at most y. If the required voltage regulation range is greater than x*y, then multiple control units 112 in a group need to be enabled simultaneously to achieve a larger voltage regulation range.
[0055] In another embodiment, the threshold adjustment signal may include multiple independent threshold adjustment sub-signals, with each control terminal of the control unit 112 corresponding to one threshold adjustment sub-signal. The threshold adjustment sub-signals connected to different control units 112 may be the same or different. By controlling multiple control units 112 with multiple threshold adjustment sub-signals, the number of control schemes can be increased, the number of selectable voltage adjustment ranges can be improved, and a large number of voltage adjustment ranges can be achieved using a small number of threshold setting units 111 and control units 112.
[0056] There are multiple ways for the control unit 112 to perform the corresponding functions, including but not limited to outputting an enable signal by the control unit 112, or short-circuiting one or more threshold setting units 111 by the control unit 112.
[0057] Figure 3 This is a schematic diagram of a control unit in one embodiment of the present disclosure. Figure 3 The embodiments shown can be applied to any of the connection methods described above.
[0058] refer to Figure 3In one exemplary embodiment of this disclosure, the control unit 112 includes a switching element M, a first end of which is connected to a first end of a corresponding threshold setting unit 111, and a second end of which is connected to a second end of the corresponding threshold setting unit 111. The switching element can be implemented, for example, by a transistor.
[0059] Figure 3 The method shown disables the corresponding threshold setting unit 111 by short-circuiting the control unit 112. This control method is relatively simple to implement, requiring no circuitry in the control unit 112, and only a controllable switching element (such as a transistor) is needed. It should be noted that this method is applicable regardless of whether multiple threshold setting units 111 are connected in series, parallel, or independently. Figure 3 The control method shown.
[0060] Of course, in addition to using short-circuit control, other output enable signals can also be used to enable and operate the threshold setting unit 111, and this disclosure does not impose any special restrictions on this.
[0061] Figure 4 This is a schematic diagram of a threshold setting module and a control unit in one embodiment of this disclosure.
[0062] refer to Figure 4 In one exemplary embodiment of this disclosure, each threshold setting unit 111 includes one or more transistors 41 connected in series, and the threshold setting module 11 includes:
[0063] M transistors 41 are connected in series. The gate of each transistor 41 is coupled to the first input terminal. The first terminal of the first transistor 41 is coupled to the power supply terminal, and the second terminal is connected to the first terminal of the second transistor 41. The second terminal of the Mth transistor 41 is connected to the first node N1, and the first terminal is connected to the second terminal of the (M-1)th transistor. M is greater than or equal to 2.
[0064] exist Figure 4 In the illustrated embodiment, for simplicity, M=3. Each threshold setting unit 111 has a first N-type transistor 41. The control terminal (i.e., gate) of the first N-type transistor 41 is connected to the first input terminal of the threshold setting module 11 to receive the voltage Vs to be measured. Each threshold setting unit 111 corresponds to a control unit 112, which is implemented through a second N-type transistor 42. The control terminal of each second N-type transistor 42 is connected to a threshold adjustment sub-signal Opti, where i is a natural number greater than or equal to 1.
[0065] like Figure 4As shown, the turn-on state of the first N-type transistor 41 is affected by the measured voltage Vs. Therefore, different measured voltages Vs result in different on-state voltage drops Vth for the first N-type transistor 41. If x of the series-connected first N-type transistors 41 are enabled (their corresponding second N-type transistors 42 are not turned on, not short-circuited), a series voltage drop x*Vth is formed. This series on-state voltage drop x*Vth is the first voltage regulation value ΔV1, where x is a natural number. Therefore, the control voltage VN1 of the first node N1 is:
[0066] VN1=V1-x*Vth(1)
[0067] If the on-current I is kept constant by an additional circuit, the voltage adjustment range of each threshold setting unit 111 is 0~Vthmax, where 0 corresponds to the case where the first N-type transistor 41 is fully turned on and its internal resistance is zero (since the MOS transistor 41 is an NMOS transistor, when V1 is high, the minimum voltage drop of the first N-type transistor 41 should be the threshold voltage of the NMOS transistor), and Vthmax is the voltage drop caused when the first N-type transistor 41 is turned off. The more threshold setting units 111 that are enabled, the larger the voltage adjustment range. When x threshold setting units 111 are enabled, the voltage adjustment range is 0~x*Vthmax. When the on-current is not constant, the voltage adjustment range corresponding to each threshold setting unit 11 can be specifically analyzed according to Ohm's law and the external circuit connected to the first node N1.
[0068] The threshold setting module 11, implemented by series-connected transistors, has the advantages of small layout area, few components, and simple circuit structure. It can realize a voltage detection circuit with threshold adjustment function without occupying more layout area.
[0069] Figure 5 This is a schematic diagram of a voltage conversion module in one embodiment of the present disclosure.
[0070] refer to Figure 5 In one exemplary embodiment of this disclosure, the voltage conversion module 12 includes:
[0071] The detection unit 121 has a power supply terminal, an input terminal, and an output terminal. The power supply terminal is used to connect to the second voltage V2, and the input terminal is connected to the first node N1. The detection unit 121 is used to determine the second voltage adjustment value ΔV2 according to the control voltage VN1 of the first node N1, and output the detection voltage Vt through the output terminal according to the second voltage V2 and the second voltage adjustment value ΔV2.
[0072] The level conversion unit 122 has its input terminal connected to the output terminal of the detection unit 121, and is used to output a first level S1 or a second level S2 according to the detection voltage Vt.
[0073] Depending on the settings, the first level S1 can be either high (logic "1") or low (logic "0"), and correspondingly, the second level S2 can be either low (logic "0") or high (logic "1").
[0074] By determining the second voltage adjustment value ΔV2 based on the control voltage VN1, and outputting the detection voltage Vt through the output terminal based on the second voltage V2 and the second voltage adjustment value ΔV2, the control voltage VN1 and the detection voltage Vt can be isolated. This allows the fluctuations and adjustments of the control voltage VN1 to be smoothly reflected at the input terminal of the level conversion unit 122. Furthermore, the second voltage V2 can be used to match the input level requirements of the level conversion unit 122, so that the detection voltage Vt can not only reflect the changing trend of the control voltage VN1, but also adapt to the performance of the level conversion unit, such as flipping the level, thus reducing the level limitation on the control voltage VN1.
[0075] The level conversion unit 122 can be any component or combination of components with analog-to-digital conversion function. The level conversion unit 122 performs threshold judgment on the continuously changing detection voltage Vt, thereby outputting a digital level, which is combined into a digital pulse signal composed of a first level S1 and a second level S2, and directly outputs the voltage detection result to an external processor or a device that receives the voltage detection result.
[0076] The detection unit 121 and the level conversion unit 122 can be implemented by various circuits.
[0077] Figure 6 This is a circuit diagram of a voltage conversion module in one embodiment of the present disclosure.
[0078] refer to Figure 6 In one embodiment, the detection unit 121 may include:
[0079] The first P-type transistor P1 has its gate connected to the first node N1 as the input terminal of the voltage conversion module 12, its source connected to the power supply terminal, and its drain connected to the second node N2. The second node N2 is connected to the input terminal of the level conversion unit 122.
[0080] The first resistor unit R1 has its first end connected to the second node N2, and its second end grounded.
[0081] The level conversion unit 122 includes an inverter INV.
[0082] The first resistor unit R1 can be implemented by connecting one or more resistors in series or in parallel, or by other electronic components with resistive properties. This disclosure does not impose any special restrictions on this.
[0083] Figure 6The circuit shown implements the function of voltage conversion module 12 using the simplest components. It can directly output the voltage detection result, i.e., the first level S1 or the second level S2, based on the control voltage VN1, thus realizing the conversion from analog voltage to digital pulse. Figure 6 In the embodiment shown, the first level S1 is high (logic "1"), and the second level S2 is low (logic "0").
[0084] Figure 7 This is a circuit diagram of a voltage detection circuit in one embodiment of the present disclosure.
[0085] refer to Figure 7 In one exemplary embodiment of this disclosure, the voltage detection circuit 700 further includes a voltage bias module 13, which is connected to the first node N1 and is used to provide a bias voltage Vref to the input terminal of the voltage conversion module 12.
[0086] exist Figure 7 In the illustrated embodiment, the voltage biasing module 13 may include:
[0087] The second P-type transistor P2 has its source connected to the second voltage V2, and its gate and drain connected to the first node N1.
[0088] The second resistor unit R2 has its first end connected to the first node N1 and its second end grounded.
[0089] The second resistor unit R2 can be implemented by connecting one or more resistors in series or in parallel, or by other electronic components with resistive properties. This disclosure does not impose any special restrictions on this.
[0090] In one embodiment, the voltage bias module 13 is also used to provide a bias voltage to the first node N1 to ensure that the first node N1 is in a low-voltage stable state when the power supply terminal is disconnected from the first node N1. Figure 7 In the embodiment shown, the voltage bias module 13 can also be used to discharge the current of the threshold setting module 11 and maintain the current stability of the first node N1.
[0091] The overall analysis of the voltage detection circuit 700 shows that when the voltage to be measured Vs rises from a low voltage to exceed a threshold, the output signal of the inverter INV changes to the first level S1, i.e., a high level (logic "1").
[0092] Working principle analysis:
[0093] When the voltage to be measured Vs is low, the internal resistance of the first N-type transistor N1 is large, the on-state voltage drop Vth is large, and the control voltage VN1 is small. The first node N1 is biased at Vp0, and the second node N2 is biased at Vm1, so that the output signal of the inverter INV is the second level S2, that is, low level (logic "0").
[0094] When the voltage under test Vs increases, the internal resistance of the first N-type transistor N1 decreases and the on-state voltage drop Vth decreases. According to formula (1), the control voltage VN1 also increases accordingly. The first P-type transistor P1 gradually turns off, and the detection voltage Vt tends to the low level logic "0". When the voltage of the detection voltage Vt is lower than the flip level of the inverter INV, the output signal of the inverter INV becomes the first level S1, that is, the high level (logic "1"), indicating that the voltage under test Vs has climbed above the threshold.
[0095] The voltage detection circuit provided in this embodiment can achieve flexible adjustment of the voltage detection threshold with a small number of components, and can directly output the detection result of whether the voltage under test Vs meets the detection threshold. The circuit layout occupies a small size and has powerful functions.
[0096] Figure 8 This is a flowchart of a voltage detection method in one embodiment of the present disclosure. Figure 8 The method shown can be applied to the voltage detection circuit of any of the above embodiments.
[0097] refer to Figure 8 The voltage detection method 800 may include:
[0098] Step S1: Output a threshold adjustment signal to set the voltage adjustment range;
[0099] Step S2: Determine the first voltage adjustment value based on the voltage to be measured being within the voltage adjustment range;
[0100] Step S3: Determine the control voltage based on the first voltage adjustment value and the first voltage;
[0101] Step S4: Detect the control voltage. When the control voltage is greater than the preset value, output the first level; when the control voltage is less than or equal to the preset value, output the second level.
[0102] In one exemplary embodiment of this disclosure, detecting the control voltage includes: determining a second voltage adjustment value based on the control voltage; outputting a detection voltage based on the second voltage adjustment value and the second voltage; outputting a first level when the detection voltage is greater than a preset flip level, and outputting a second level when the detection voltage is less than the preset flip level.
[0103] Figure 8 The method shown can be implemented using various circuits to achieve flexible adjustment of the detection threshold of the voltage detection circuit.
[0104] It should be noted that although several modules or units for the device used to perform actions have been mentioned in the detailed description above, this division is not mandatory. In fact, according to embodiments of this disclosure, the features and functions of two or more modules or units described above can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided and embodied by multiple modules or units.
[0105] Other embodiments of this disclosure will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this disclosure that follow the general principles of this disclosure and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only, and the true scope and concept of this disclosure are indicated by the claims.
Claims
1. A voltage detection circuit, characterized in that, include: A threshold setting module has a first input terminal, a second input terminal, and a power supply terminal. The first input terminal is used to receive the voltage to be measured, the second input terminal is used to receive a threshold adjustment signal, and the power supply terminal is used to connect to a first voltage. The module is used to set a voltage adjustment range according to the threshold adjustment signal, determine a first voltage adjustment value according to the voltage to be measured within the voltage adjustment range, and generate a control voltage according to the first voltage and the first voltage adjustment value. The voltage conversion module receives the control voltage through a first node at its input terminal, and is used to output a first level when the control voltage is greater than a preset value, and to output a second level when the control voltage is less than or equal to the preset value. The threshold setting module has multiple predetermined voltage adjustment ranges, and the threshold adjustment signal is used to select one of the voltage adjustment ranges from the multiple voltage adjustment ranges; The threshold setting module includes multiple threshold setting units and multiple control units. Each control unit is connected to one or more threshold setting units. Each control unit is used to respond to the threshold adjustment signal and enable one or more threshold setting units. Each of the threshold setting units includes one or more transistors connected in series, and the threshold setting module includes: M transistors are connected in series, with the gate of each transistor coupled to the first input terminal. The first terminal of the first transistor is coupled to the power supply terminal, and the second terminal is connected to the first terminal of the second transistor. The second terminal of the Mth transistor is connected to the first node, and the first terminal is connected to the second terminal of the (M-1)th transistor. M is greater than or equal to 2.
2. The voltage detection circuit as described in claim 1, characterized in that, Also includes: A voltage bias module, connected to the first node, is used to provide a bias voltage to the input terminal of the voltage conversion module.
3. The voltage detection circuit as described in claim 1, characterized in that, The voltage adjustment ranges corresponding to the plurality of threshold setting units are equal, or the voltage adjustment range of at least one threshold setting unit is different from the voltage adjustment ranges of the other threshold setting units.
4. The voltage detection circuit as described in claim 1, characterized in that, Each control unit is connected to one or more threshold setting units. When the number of control units is greater than one, at least two control units are connected to the same threshold setting unit, or different control units are connected to different threshold setting units.
5. The voltage detection circuit as described in claim 1, characterized in that, The control unit includes a switching element, the first end of which is connected to the first end of the corresponding threshold setting unit, and the second end of which is connected to the second end of the corresponding threshold setting unit.
6. The voltage detection circuit as described in claim 1 or 5, characterized in that, The control terminal of the control unit is used to receive the threshold adjustment signal or the inverted signal of the threshold adjustment signal; or, the threshold adjustment signal includes multiple different threshold adjustment sub-signals, and the control terminal of each control unit corresponds to one threshold adjustment sub-signal, and the threshold adjustment sub-signals connected to different control units may be the same or different.
7. The voltage detection circuit as described in claim 5, characterized in that, The switching element is implemented using a transistor.
8. The voltage detection circuit as described in claim 1, characterized in that, The voltage conversion module includes: The detection unit has a power supply terminal, an input terminal, and an output terminal. The power supply terminal is used to connect to a second voltage, and the input terminal is connected to the first node. The detection unit is used to determine a second voltage adjustment value based on the control voltage of the first node, and to output a detection voltage through the output terminal based on the second voltage and the second voltage adjustment value. The level conversion unit has its input terminal connected to the output terminal of the detection unit and is used to output the first level or the second level according to the detection voltage.
9. The voltage detection circuit as described in claim 8, characterized in that, The detection unit includes: The first P-type transistor has its gate connected to the first node as the input terminal of the voltage conversion module, its source connected to the power supply terminal, and its drain connected to the second node. The second node is connected to the input terminal of the level conversion unit. The first resistor unit has its first end connected to the second node and its second end grounded.
10. The voltage detection circuit as described in claim 8 or 9, characterized in that, The level conversion unit includes an inverter.
11. The voltage detection circuit as described in claim 2, characterized in that, The voltage biasing module includes: The second P-type transistor has its source connected to a second voltage, and its gate and drain connected to the first node. The second resistor unit has its first end connected to the first node and its second end grounded.
12. A voltage detection method, characterized in that, The circuit is applied to the voltage detection circuit as described in any one of claims 1 to 11, comprising: Output a threshold adjustment signal to set the voltage regulation range; A first voltage adjustment value is determined based on the voltage to be measured within the voltage adjustment range; The control voltage is determined based on the first voltage adjustment value and the first voltage; The control voltage is detected, and a first level is output when the control voltage is greater than a preset value, and a second level is output when the control voltage is less than or equal to the preset value.
13. The voltage detection method as described in claim 12, characterized in that, The detection of the control voltage includes: The second voltage adjustment value is determined based on the control voltage; The detection voltage is output based on the second voltage adjustment value and the second voltage; The first level is output when the detected voltage is greater than the preset flip level, and the second level is output when the detected voltage is less than the preset flip level.