An offset voltage calibration circuit for rail-to-rail operational amplifiers

By using the calibration current module in the rail-to-rail op amp to calibrate the bias currents of the PMOS and NMOS input stages, the problem of poor offset voltage stability in the full common mode input range is solved, and the temperature coefficient is reduced , improves the common mode suppression ratio.

CN118508878BActive Publication Date: 2024-11-01BEIJING CIMO MICROELECTRONICS CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410764150.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-13
Publication Date
2024-11-01
Estimated Expiration
2044-06-13

AI Technical Summary

Technical Problem

The offset voltage of existing rail-to-rail operational amplifiers within the full common mode input range is difficult to stabilize, and the temperature coefficient is relatively high and is greatly affected by the temperature, resulting in deterioration of the common mode suppression ratio.

Method used

By adopting a circuit including a first calibration current module, a second calibration current module, a third calibration current module and a offset voltage calibration module, the bias current of the PMOS input stage and the NMOS input stage are respectively calibrated, disconnected and restored. Connect, adjust the calibration current to reduce the magnitude of the offset voltage and calibrate at the load and output stages to ensure that the offset voltage is stable within the full common mode input range.

Benefits of technology

It is achieved to stabilize the total offset voltage of the rail-to-rail operational amplifier to a lower level within the full common mode input range, and reduce the temperature coefficient of the offset voltage and improve the common mode rejection ratio.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118508878B_ABST
    Figure CN118508878B_ABST
Patent Text Reader

Abstract

The present application relates to an offset voltage calibration circuit for a rail-to-rail operational amplifier, comprising: a first calibration current module inputting a first calibration current to a load stage; a second calibration current module inputting a second calibration current to the load stage; a third calibration current module inputting a third calibration current to the load stage; the offset voltage calibration module is used to: disconnect the connection between a PMOS input stage and an NMOS input stage and the load stage; adjust the first calibration current to calibrate a first offset voltage caused by the load stage and the output stage; restore the connection between the PMOS input stage and the NMOS input stage and the load stage; adjust the second calibration current to calibrate a second offset voltage caused by the PMOS input stage; adjust the third calibration current to calibrate a third offset voltage caused by the NMOS input stage; the offset voltage of the rail-to-rail operational amplifier can be accurately calibrated, and the offset voltage can be stabilized at a lower level within a full common mode input range.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of circuit design, and in particular to an offset voltage calibration circuit for a rail-to-rail operational amplifier. Background Art

[0002] Rail-to-Rail Operational Amplifiers usually use complementary differential input pairs to form the input stage, so that the input stage can achieve a higher gain within the full common-mode input range (i.e., the common-mode input voltage is within the range of 0V-power supply voltage). However, within the full common-mode input range, the total offset voltage (Offset Voltage) of the rail-to-rail operational amplifier changes with the common-mode input voltage (Common Mode Voltage), which deteriorates the common-mode rejection ratio of the rail-to-rail operational amplifier. Therefore, it is necessary to calibrate (trim) the offset voltage of the rail-to-rail operational amplifier to stabilize the offset voltage within a certain level. The current offset voltage calibration technology is difficult to stabilize the offset voltage within a certain level within the full common-mode input range, and the temperature coefficient of the offset voltage after calibration is high and is greatly affected by temperature. Summary of the invention

[0003] In view of this, the present application proposes an offset voltage calibration circuit for a rail-to-rail operational amplifier, a rail-to-rail operational amplifier and an offset voltage calibration method for a rail-to-rail operational amplifier, which can accurately calibrate the offset voltage of the rail-to-rail operational amplifier, reduce the variation amplitude of the offset voltage with the common-mode input voltage, and stabilize the offset voltage at a lower level within the full common-mode input range.

[0004] According to one aspect of the present application, an offset voltage calibration circuit for a rail-to-rail operational amplifier is provided, comprising a first calibration current module, a second calibration current module, a third calibration current module and an offset voltage calibration module; the rail-to-rail operational amplifier comprises a PMOS input stage, an NMOS input stage, a load stage and an output stage; the PMOS input stage and the NMOS input stage are respectively connected to the load stage; the load stage is connected to the output stage; the PMOS input stage and the NMOS input stage are used to receive a first input voltage and a second input voltage, and obtain an output current according to the first input voltage and the second input voltage; the load stage is used to obtain an output voltage according to the output current; the output stage is used to output the output voltage; wherein the bias current of the PMOS input stage and the NMOS input stage varies with the common-mode input voltage; the bias current of the load stage and the output stage does not vary with the common-mode input voltage; the common The analog input voltage is the sum of the first input voltage and the second input voltage divided by 2; the first calibration current module is used to input a first calibration current to the load stage; the second calibration current module is used to input a second calibration current to the load stage; the third calibration current module is used to input a third calibration current to the load stage; the offset voltage calibration module is used to: disconnect the connection between the PMOS input stage and the load stage and disconnect the connection between the NMOS input stage and the load stage; adjust the first calibration current to calibrate the first offset voltage caused by the load stage and the output stage; restore the connection between the PMOS input stage and the load stage and restore the connection between the NMOS input stage and the load stage; adjust the second calibration current to calibrate the second offset voltage caused by the PMOS input stage; adjust the third calibration current to calibrate the third offset voltage caused by the NMOS input stage.

[0005] In one possible implementation, adjusting the second calibration current to calibrate the second offset voltage caused by the PMOS input stage includes: before adjusting the second calibration current, setting the common-mode input voltage to a first common-mode voltage; the first common-mode voltage is a voltage that enables the PMOS input stage to work normally and the NMOS input stage to not work; and / or, adjusting the third calibration current to calibrate the third offset voltage caused by the NMOS input stage includes: before adjusting the third calibration current, setting the common-mode input voltage to a second common-mode voltage; the second common-mode voltage is a voltage that enables the NMOS input stage to work normally and the PMOS input stage to not work.

[0006] In one possible implementation, adjusting the first calibration current to calibrate the first offset voltage caused by the load stage and the output stage includes: adjusting the first calibration current to complete the calibration of the first offset voltage when the output voltage is equal to half of the power supply voltage of the rail-to-rail operational amplifier.

[0007] In a possible implementation, adjusting the second calibration current to calibrate the second offset voltage caused by the PMOS input stage includes: when the rail-to-rail operational amplifier is in a closed-loop state, adjusting the second calibration current, and completing the calibration of the second offset voltage when the output voltage is equal to the first input voltage; or, when the rail-to-rail operational amplifier is in an open-loop state, adjusting the second calibration current, and completing the calibration of the second offset voltage when the absolute value of the difference between the output voltage and the first voltage is less than a first preset threshold; or, when the rail-to-rail operational amplifier is in an open-loop state, adjusting the second calibration current, and completing the calibration of the second offset voltage when the absolute value of the current on the first voltage source is less than a second preset threshold; the first voltage source is connected to the output end of the rail-to-rail operational amplifier; the voltage of the first voltage source is the first voltage.

[0008] In a possible implementation, adjusting the third calibration current to calibrate the third offset voltage caused by the NMOS input stage includes: when the rail-to-rail operational amplifier is in a closed-loop state, adjusting the third calibration current, and completing the calibration of the third offset voltage when the output voltage is equal to the first input voltage; or, when the rail-to-rail operational amplifier is in an open-loop state, adjusting the third calibration current, and completing the calibration of the third offset voltage when the absolute value of the difference between the output voltage and the first voltage is less than a first preset threshold; or, when the rail-to-rail operational amplifier is in an open-loop state, adjusting the third calibration current, and completing the calibration of the third offset voltage when the absolute value of the current on the first voltage source is less than a second preset threshold; the first voltage source is connected to the output end of the rail-to-rail operational amplifier; the voltage of the first voltage source is the first voltage.

[0009] In a possible implementation, the second calibration current module includes a third PMOS tube, a fourth PMOS tube, a third load current mirror and a third tail current source; the source of the third PMOS tube and the source of the fourth PMOS tube are connected to the output end of the third tail current source; the input end of the third tail current source is connected to the power supply voltage of the rail-to-rail operational amplifier; the first input end of the third load current mirror is connected to the drain of the third PMOS tube to constitute the first output end of the second calibration current module; the second input end of the third load current mirror is connected to the drain of the fourth PMOS tube to constitute the second output end of the second calibration current module; the output end of the third load current mirror is grounded; the first output end and the second output end of the second calibration current module are respectively connected to the load stage, and the second calibration current is the difference between the output current of the second output end and the output current of the first output end of the second calibration current module; wherein the ratio between the transconductance of the second calibration current module and the transconductance of the PMOS input stage and the ratio between the bias current of the second calibration current module and the bias current of the PMOS input stage are equal.

[0010] In a possible implementation, adjusting the second calibration current to calibrate the second offset voltage caused by the PMOS input stage includes: inputting a second reference voltage to the gate of the third PMOS tube, and inputting a voltage that is the sum of the second reference voltage and the second calibration voltage to the gate of the fourth PMOS tube; maintaining the second reference voltage constant, adjusting the second calibration voltage to adjust the second calibration current output by the second calibration current module, and recording a target voltage value of the second calibration voltage for achieving the second offset voltage calibration.

[0011] In a possible implementation, the third calibration current module includes a third NMOS tube, a fourth NMOS tube, a fourth load current mirror and a fourth tail current source; the input end of the fourth load current mirror is connected to the power supply voltage; the first output end of the fourth load current mirror is connected to the drain of the third NMOS tube, constituting the first output end of the third calibration current module; the second output end of the fourth load current mirror is connected to the drain of the fourth NMOS tube, constituting the second output end of the third calibration current module; the source of the third NMOS tube and the source of the fourth NMOS tube are connected to the input end of the fourth tail current source; the output end of the fourth tail current source is grounded; the first output end and the second output end of the third calibration current module are respectively connected to the load stage, and the third calibration current is the difference between the output current of the second output end and the output current of the first output end of the third calibration current module; wherein the ratio between the transconductance of the third calibration current module and the transconductance of the NMOS input stage and the ratio between the bias current of the third calibration current module and the bias current of the NMOS input stage are equal.

[0012] In a possible implementation, adjusting the third calibration current to calibrate the third offset voltage caused by the NMOS input stage includes: inputting a third reference voltage into the gate of the third NMOS tube, and inputting a voltage into the gate of the fourth NMOS tube that is the sum of the third reference voltage and the third calibration voltage; maintaining the third reference voltage constant, adjusting the third calibration voltage to adjust the third calibration current output by the third calibration current module, and recording a target voltage value of the third calibration voltage for achieving the third offset voltage calibration.

[0013] In a possible implementation, the first calibration current module includes a fifth PMOS tube, a sixth PMOS tube and a fifth tail current source; the source of the fifth PMOS tube and the source of the sixth PMOS tube are connected to the output end of the fifth tail current source; the input end of the fifth tail current source is connected to the power supply voltage; the drain of the fifth PMOS tube is the first output end of the first calibration current module; the drain of the sixth PMOS tube is the second output end of the first calibration current module; the first output end and the second output end of the first calibration current module are respectively connected to the load stage, and the first calibration current is the difference between the output current of the second output end and the output current of the first output end of the first calibration current module.

[0014] In a possible implementation, adjusting the first calibration current to calibrate the first offset voltage caused by the load stage and the output stage includes: inputting a first reference voltage to the gate of the fifth PMOS tube, and inputting a voltage that is the sum of the first reference voltage and the first calibration voltage to the gate of the sixth PMOS tube; maintaining the first reference voltage constant, adjusting the first calibration voltage to adjust the first calibration current output by the first calibration current module, and recording a target voltage value of the first calibration voltage for achieving the first offset voltage calibration.

[0015] In a possible implementation, when the rail-to-rail operational amplifier is powered on again, the offset voltage calibration module is further used to: calibrate the first offset voltage according to the recorded target voltage value of the first calibration voltage; calibrate the second offset voltage according to the recorded target voltage value of the second calibration voltage; and calibrate the third offset voltage according to the recorded target voltage value of the third calibration voltage.

[0016] According to another aspect of the present application, a rail-to-rail operational amplifier is provided, comprising: a PMOS input stage, an NMOS input stage, a load stage, an output stage and an offset voltage calibration circuit; the offset voltage calibration circuit comprises a first calibration current module, a second calibration current module, a third calibration current module and an offset voltage calibration module; the PMOS input stage and the NMOS input stage are respectively connected to the load stage; the load stage is connected to the output stage; the PMOS input stage and the NMOS input stage are used to receive a first input voltage and a second input voltage, and obtain an output current according to the first input voltage and the second input voltage; the load stage is used to obtain an output voltage according to the output current; the output stage is used to output the output voltage; wherein the bias current of the PMOS input stage and the NMOS input stage varies with the common-mode input voltage; the bias current of the load stage and the output stage does not vary with the common-mode input voltage; the common The analog input voltage is the sum of the first input voltage and the second input voltage divided by 2; the first calibration current module is used to input a first calibration current to the load stage; the second calibration current module is used to input a second calibration current to the load stage; the third calibration current module is used to input a third calibration current to the load stage; the offset voltage calibration module is used to: disconnect the connection between the PMOS input stage and the load stage and disconnect the connection between the NMOS input stage and the load stage; adjust the first calibration current to calibrate the first offset voltage caused by the load stage and the output stage; restore the connection between the PMOS input stage and the load stage and restore the connection between the NMOS input stage and the load stage; adjust the second calibration current to calibrate the second offset voltage caused by the PMOS input stage; adjust the third calibration current to calibrate the third offset voltage caused by the NMOS input stage.

[0017] According to another aspect of the present application, a method for calibrating an offset voltage for a rail-to-rail operational amplifier is provided, which is applied to the above-mentioned offset voltage calibration circuit for the rail-to-rail operational amplifier, and the method includes: disconnecting the connection between the PMOS input stage and the load stage and disconnecting the connection between the NMOS input stage and the load stage; adjusting the first calibration current to calibrate the first offset voltage caused by the load stage and the output stage; restoring the connection between the PMOS input stage and the load stage and restoring the connection between the NMOS input stage and the load stage; adjusting the second calibration current to calibrate the second offset voltage caused by the PMOS input stage; and adjusting the third calibration current to calibrate the third offset voltage caused by the NMOS input stage.

[0018] The offset voltage calibration circuit for a rail-to-rail operational amplifier of the present application divides the structure of the rail-to-rail operational amplifier into a part where the bias current varies with the common-mode input voltage and a part where the bias current does not vary with the common-mode input voltage, and performs offset voltage calibration on these two parts respectively. First, the offset voltage contributed by the part where the bias current does not vary with the common-mode input voltage (i.e., the load stage and the output stage) is calibrated, and then the offset voltage contributed by the part where the bias current varies with the common-mode input voltage (i.e., the PMOS input stage and the NMOS input stage) is calibrated. The total offset voltage of the rail-to-rail operational amplifier can be accurately calibrated, and the total offset voltage can be stabilized at a lower level within the full common-mode input range.

[0019] Other features and aspects of the present application will become apparent from the following detailed description of exemplary embodiments with reference to the attached drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] The accompanying drawings, which are incorporated in and constitute a part of the specification, illustrate exemplary embodiments, features, and aspects of the present application and, together with the description, serve to explain the principles of the present application.

[0021] Figure 1 A schematic diagram of the structure of a rail-to-rail operational amplifier is shown.

[0022] Figure 2 A schematic structural diagram of an offset voltage calibration circuit for a rail-to-rail operational amplifier according to an embodiment of the present application is shown.

[0023] Figure 3(a) to Figure 3(c) A schematic diagram showing an offset voltage calibration circuit according to an embodiment of the present application performing offset voltage calibration on a rail-to-rail operational amplifier.

[0024] Figure 4 A schematic structural diagram of a second calibration current module and a third calibration current module according to an embodiment of the present application is shown.

[0025] Figure 5 A schematic structural diagram of a first calibration current module according to an embodiment of the present application is shown.

[0026] Figure 6 A schematic structural diagram of a rail-to-rail operational amplifier according to an embodiment of the present application is shown.

[0027] Figure 7 A circuit structure diagram of a rail-to-rail operational amplifier according to an embodiment of the present application is shown.

[0028] Figure 8 A flow chart of a method for offset voltage calibration of a rail-to-rail operational amplifier according to an embodiment of the present application is shown.

[0029] Fig. 9 A schematic structural diagram of a chip according to an embodiment of the present application is shown.

[0030] Fig.10 A schematic diagram showing a method for calibrating an offset voltage of a rail-to-rail operational amplifier according to an embodiment of the present application is shown.

[0031] Figure 11(a) to Figure 11(e) A schematic diagram showing the variation of the total offset voltage with the common-mode input voltage during the calibration process of the offset voltage calibration method according to an embodiment of the present application is shown.

[0032] Fig.12 The simulation results of the total offset voltage changing with the common-mode input voltage after calibration according to the offset voltage calibration method of an embodiment of the present application are shown.

[0033] Fig.13 The simulation results of the total offset voltage changing with temperature after calibration according to the offset voltage calibration method according to an embodiment of the present application are shown. DETAILED DESCRIPTION

[0034] Various exemplary embodiments, features and aspects of the present application will be described in detail below with reference to the accompanying drawings. The same reference numerals in the accompanying drawings represent elements with the same or similar functions. Although various aspects of the embodiments are shown in the accompanying drawings, the drawings are not necessarily drawn to scale unless otherwise specified.

[0035] The word “exemplary” is used exclusively herein to mean “serving as an example, example, or illustration.” Any embodiment described herein as “exemplary” is not necessarily to be construed as preferred or advantageous over other embodiments.

[0036] In addition, in order to better illustrate the present application, numerous specific details are given in the following specific embodiments. It should be understood by those skilled in the art that the present application can also be implemented without certain specific details. In some examples, methods, means, components and circuits well known to those skilled in the art are not described in detail in order to highlight the subject matter of the present application.

[0037] The offset voltage of an operational amplifier, also known as the input offset voltage, refers to the offset voltage at the output when the input of the operational amplifier is zero. The offset voltage is caused by inevitable non-ideal factors in the circuit manufacturing process and changes with temperature. Rail-to-rail operational amplifiers typically adopt a complementary differential input pair structure, that is, there is a PMOS differential input pair and an NMOS differential input pair in the input stage at the same time, so that at least one differential input pair can operate in the amplification state within the full common-mode input range, and a relatively high gain can be achieved within the full common-mode input range. Compared with an operational amplifier with only one differential input pair in the input stage, when the common-mode input voltage VCM of the rail-to-rail operational amplifier is relatively high, for example, when VCM > (VDD - Vthp), the NMOS differential input pair conducts and the PMOS differential input pair disconnects. The PMOS differential input pair no longer contributes to the gain and also no longer contributes to the input offset voltage; when the common-mode input voltage is relatively low, for example, when VCM < (VSS + Vthn), the PMOS differential input pair conducts and the NMOS differential input pair disconnects. The NMOS differential input pair no longer contributes to the gain and also no longer contributes to the input offset voltage; when the common-mode input voltage is not in the above two intervals, that is, (VSS + Vthn) < VCM < (VDD - Vthp), the PMOS differential input pair and the NMOS differential input pair conduct at the same time and contribute to the gain and the input offset voltage at the same time; where VCM represents the common-mode input voltage of the rail-to-rail operational amplifier, VDD represents the power supply voltage of the rail-to-rail operational amplifier, VSS represents the ground voltage, Vthp represents the threshold voltage of the PMOS transistor in the PMOS differential input pair, and Vthn represents the threshold voltage of the NMOS transistor in the NMOS differential input pair. That is, within the full common-mode input range, the total offset voltage of the rail-to-rail operational amplifier changes with the common-mode input voltage. The change of the total offset voltage with the common-mode input voltage deteriorates the common-mode rejection ratio of the rail-to-rail operational amplifier. Therefore, an offset voltage calibration technique is needed to make the total offset voltage of the rail-to-rail operational amplifier stable within a certain level within the full common-mode input range.

[0038] In the related art, a method for calibrating the offset voltage of a rail-to-rail operational amplifier first compares the common-mode input voltage with a reference voltage to determine whether the bias current is provided to the PMOS differential input pair or the NMOS differential input pair, so that within a wider common-mode input voltage range, the offset voltage only comes from the PMOS differential input pair or the NMOS differential input pair, and at the same time, the offset voltage contributed by the PMOS differential input pair and the offset voltage contributed by the NMOS differential input pair are calibrated separately, and some calibration current is injected into the circuit so that when only the PMOS differential input pair is working or only the NMOS differential input pair is working, the equivalent input offset voltage is about 0V. However, this calibration method can only calibrate the offset voltage when only the PMOS differential input pair is working or only the NMOS differential input pair is working, and the calibration current is no longer accurate when both differential input pairs are working, and a high offset voltage will still exist. Moreover, in addition to the input stage, the subsequent circuits or devices in the rail-to-rail operational amplifier also contribute to the offset voltage. For example, the cascode stage and the output stage all contribute to the offset voltage. The above calibration method does not calibrate the offset voltage contributed by the subsequent circuits or devices. In addition, if a rail-to-rail operational amplifier is implemented using MOS devices, the temperature coefficient of its equivalent input offset voltage is low; at the same time, in order to maintain the transconductance stability of the input stage at different temperatures, the bias current of the rail-to-rail operational amplifier usually uses a current proportional to absolute temperature (PTAT). If you want to maintain a stable offset voltage and a stable transconductance, you need a stable calibration current, that is, you need to generate a calibration current with a low temperature coefficient to calibrate the offset voltage. If the offset voltage is calibrated only once at room temperature, if the temperature coefficient of the calibration current is high after the temperature changes, it will in turn affect the temperature coefficient of the offset voltage after calibration. Therefore, the temperature coefficient of the offset voltage calibrated using the above calibration method is high.

[0039] In view of this, the present application provides an offset voltage calibration circuit for a rail-to-rail operational amplifier, which can accurately calibrate the offset voltage of the rail-to-rail operational amplifier, reduce the amplitude of the offset voltage change with the common-mode input voltage, stabilize the offset voltage at a lower level, and the temperature coefficient of the offset voltage after calibration is low.

[0040] Figure 1 A schematic diagram of the structure of a rail-to-rail operational amplifier is shown in FIG. Figure 1As shown, the rail-to-rail operational amplifier may include a PMOS input stage, an NMOS input stage, a load stage and an output stage; the PMOS input stage and the NMOS input stage are respectively connected to the load stage; the load stage is connected to the output stage; the PMOS input stage and the NMOS input stage are used to receive a first input voltage and a second input voltage, and obtain an output current according to the first input voltage and the second input voltage; the load stage is used to obtain an output voltage according to the output current; the output stage is used to output the output voltage; wherein the bias current of the PMOS input stage and the NMOS input stage varies with the common-mode input voltage; the bias current of the load stage and the output stage does not vary with the common-mode input voltage; the common-mode input voltage is the sum of the first input voltage and the second input voltage divided by 2.

[0041] The PMOS input stage may include a first PMOS transistor MP1, a second PMOS transistor MP2, a first load current mirror and a first tail current source (i.e. Figure 1 A device providing current ITAILP in the rail-to-rail operational amplifier); the source of MP1 and the source of MP2 are connected to the output end of the first tail current source; the input end of the first tail current source is connected to the power supply voltage (i.e., VDD) of the rail-to-rail operational amplifier; the first input end of the first load current mirror is connected to the drain of MP1 to form a first output end of the PMOS input stage; the second input end of the first load current mirror is connected to the drain of MP2 to form a second output end of the PMOS input stage; the output end of the first load current mirror is grounded; the first output end and the second output end of the PMOS input stage are respectively connected to the load stage.

[0042] The NMOS input stage may include a first NMOS transistor MN1, a second NMOS transistor MN2, a second load current mirror, and a second tail current source (i.e. Figure 1 A device providing current ITAILN in the middle); an input terminal of the second load current mirror is connected to VDD; a first output terminal of the second load current mirror is connected to the drain of MN1, forming a first output terminal of the NMOS input stage; a second output terminal of the second load current mirror is connected to the drain of MN2, forming a second output terminal of the NMOS input stage; a source of MN1 and a source of MN2 are connected to an input terminal of a second tail current source; an output terminal of the second tail current source is grounded; a first output terminal and a second output terminal of the NMOS input stage are respectively connected to the load stage.

[0043] MP1 and MP2 can form a PMOS differential input pair, MN1 and MN2 can form an NMOS differential input pair, the gate of MP1 and the gate of MN1 are the first input terminal of the rail-to-rail operational amplifier, used to receive the first input voltage (i.e., VIP); the gate of MP2 and the gate of MN2 are the second input terminal of the rail-to-rail operational amplifier, used to receive the second input voltage (i.e., VIN), and the common-mode input voltage VCM=(VIP+VIN) / 2. The first tail current source can provide a bias current ITAILP for the PMOS differential input pair, and the second tail current source can provide a bias current ITAILN for the NMOS differential input pair. The first tail current source and the second tail current source can be implemented by a current mirror, and the specific implementation method can refer to the relevant technology. The bias current of the PMOS input stage includes a bias tail current (i.e., ITAILP) and a load bias current (i.e., IP1 and IP2), and the bias current of the NMOS input stage includes a bias tail current (i.e., ITAILN) and a load bias current (i.e., IN1 and IN2). The load bias current in the first load current mirror completely follows the change of the bias tail current of the PMOS differential input pair, and the load bias current in the second load current mirror completely follows the change of the bias tail current of the NMOS differential input pair, so as to avoid the bias current of the subsequent circuit (i.e., the load stage and the output stage) changing with the common mode input voltage. The circuit structure of the first load current mirror and the second load current mirror can refer to the relevant technology. The MOS tube MPs is a device for determining whether the bias current should be provided to the PMOS input stage or the NMOS input stage. The gate of MPs is connected to the reference voltage VREF. When VCM is higher than VREF, MPs determines that the current IB*2 should be transferred to the NMOS input stage through the current mirror, and the bias current of the PMOS input stage is pulled to 0. At this time, ITAILN=IB*2, IN1=IN2=IB; when VCM is lower than VREF, MPs determines that the current IB*2 maintains to flow through the PMOS input stage. At this time, ITAILP=2*IB, IP1=IP2=IB.

[0044] The PMOS input stage and the NMOS input stage will generate some error currents when working (i.e., the difference between the output currents of the two output terminals of the PMOS input stage and the difference between the output currents of the two output terminals of the NMOS input stage). These error currents are usually output after addition and amplification through some post-stage circuit structures. Here, the load stage and the output stage are used to describe the post-stage circuit structure. The load stage usually uses a common source and common gate circuit structure to add the error currents generated by the two input stages, and can convert the added current into an output voltage. The output stage can output the output voltage (i.e., VOUT). The circuit structure of the load stage and the output stage can refer to the relevant technology. When performing offset voltage calibration in the relevant technology, the calibration current can be directly injected into the load stage.

[0045] From the above analysis, we can see that the bias current of the PMOS input stage and the NMOS input stage will change with VCM, while the bias current of the load stage and the output stage generally does not change with VCM. Figure 1 The rail-to-rail operational amplifier shown is divided into two parts: the part where the bias current varies with VCM (i.e., the PMOS input stage and the NMOS input stage) and the part where the bias current does not vary with VCM (i.e., the load stage and the output stage). The offset voltage can be calibrated for each of these two parts.

[0046] Figure 2 A schematic diagram of a circuit for calibrating an offset voltage of a rail-to-rail operational amplifier according to an embodiment of the present application is shown. The circuit can be used for Figure 1 The offset voltage of the rail-to-rail op amp shown is calibrated as Figure 2 As shown, the circuit may include a first calibration current module 201 , a second calibration current module 202 , a third calibration current module 203 and an offset voltage calibration module 204 .

[0047] Among them, the first calibration current module 201 is used to input the first calibration current to the load level; the second calibration current module 202 is used to input the second calibration current to the load level; the third calibration current module 203 is used to input the third calibration current to the load level; the offset voltage calibration module 204 is used to:

[0048] Disconnecting the PMOS input stage from the load stage and disconnecting the NMOS input stage from the load stage;

[0049] adjusting the first calibration current to calibrate a first offset voltage caused by the load stage and the output stage;

[0050] Restoring the connection between the PMOS input stage and the load stage and restoring the connection between the NMOS input stage and the load stage;

[0051] adjusting the second calibration current to calibrate a second offset voltage caused by the PMOS input stage;

[0052] The third calibration current is adjusted to calibrate a third offset voltage caused by the NMOS input stage.

[0053] In this embodiment, the offset voltage calibration module 204 may calibrate the first offset voltage, the second offset voltage, and the third offset voltage in sequence.

[0054] In one possible implementation, adjusting the second calibration current to calibrate the second offset voltage caused by the PMOS input stage may include: before adjusting the second calibration current, setting the common-mode input voltage to a first common-mode voltage; the first common-mode voltage is a voltage that enables the PMOS input stage to work normally and enables the NMOS input stage to not work.

[0055] In one possible implementation, adjusting the third calibration current to calibrate the third offset voltage caused by the NMOS input stage may include: before adjusting the third calibration current, setting the common-mode input voltage to a second common-mode voltage; the second common-mode voltage is a voltage that enables the NMOS input stage to work normally and enables the PMOS input stage to not work.

[0056] As an example, the first common mode voltage may be 0V, and the second common mode voltage may be a power supply voltage VDD of a rail-to-rail operational amplifier.

[0057] Exemplarily, the order of calibrating the second offset voltage and calibrating the third offset voltage can be swapped, that is, after completing the first offset voltage calibration, the offset voltage calibration module 204 can first set the common-mode input voltage to the second common-mode voltage, and calibrate the third offset voltage caused by the NMOS input stage; and then set the common-mode input voltage to the first common-mode voltage, and calibrate the second offset voltage caused by the PMOS input stage.

[0058] Figure 3(a) to Figure 3(c)A schematic diagram of an offset voltage calibration circuit for a rail-to-rail operational amplifier according to an embodiment of the present application is shown, wherein FIG3(a) shows a process of calibrating a first offset voltage, FIG3(b) shows a process of calibrating a second offset voltage, and FIG3(c) shows a process of calibrating a third offset voltage. As shown in FIG3(a), the offset voltage calibration module 204 can first disconnect the connection between the PMOS input stage and the NMOS input stage and the load stage, and the first calibration current module 201 can inject the first calibration current (i.e., Itrim_L) into the load stage, and the offset voltage calibration module 204 can calibrate the first offset voltage contributed by the load stage and the output stage by adjusting Itrim_L; as shown in FIG3(b), after calibrating the first offset voltage, the offset voltage calibration module 204 can restore the connection between the PMOS input stage and the NMOS input stage and the load stage, and set the common mode input voltage VCM to 0, or set VCM to any voltage that can make only the PMOS input stage work, and the second calibration current module 202 can inject the second calibration current (i.e., Itrim_P) into the load stage. 3(c), after calibrating the second offset voltage, the offset voltage calibration module 204 can maintain the connection between the PMOS input stage and the NMOS input stage and the load stage, and set VCM to the power supply voltage VDD, or set VCM to any voltage that can make only the NMOS input stage work, and the third calibration current module 203 can inject the third calibration current (i.e., Itrim_N) into the load stage, and the offset voltage calibration module 204 can calibrate the third offset voltage contributed by the NMOS input stage by adjusting Itrim_N; in this way, the calibration of the total offset voltage of the rail-to-rail operational amplifier can be completed.

[0059] In one possible implementation, adjusting the first calibration current to calibrate the first offset voltage caused by the load stage and the output stage may include: adjusting the first calibration current to complete the calibration of the first offset voltage when the output voltage is equal to half the power supply voltage of the rail-to-rail operational amplifier (i.e., VOUT=VDD / 2).

[0060] In one possible implementation, after restoring the connection between the PMOS input stage and the load stage and restoring the connection between the NMOS input stage and the load stage, the rail-to-rail operational amplifier can be configured into a closed-loop state through external hardware (that is, the output end of the rail-to-rail operational amplifier is connected to the second input end through a feedback network), and then the second offset voltage and the third offset voltage are calibrated.

[0061] Exemplarily, adjusting the second calibration current to calibrate the second offset voltage caused by the PMOS input stage may include: when the rail-to-rail operational amplifier is in a closed-loop state, adjusting the second calibration current, and completing the calibration of the second offset voltage when the output voltage is equal to the first input voltage (i.e., VOUT=VIP).

[0062] Exemplarily, adjusting the third calibration current to calibrate the third offset voltage caused by the NMOS input stage may include: when the rail-to-rail operational amplifier is in a closed-loop state, adjusting the third calibration current, and completing the calibration of the third offset voltage when the output voltage is equal to the first input voltage (i.e., VOUT=VIP).

[0063] As an example, the rail-to-rail operational amplifier can be configured to a unit gain closed loop state before calibrating the second offset voltage and the third offset voltage. As another example, the rail-to-rail operational amplifier can be configured to a closed loop state with a gain greater than 1 before calibrating the second offset voltage and the third offset voltage, so that the amplified offset voltage can be seen at the output end during calibration, so that the offset voltage can be calibrated more accurately, making the calibration process less susceptible to noise interference.

[0064] In one possible implementation, after restoring the connection between the PMOS input stage and the load stage and restoring the connection between the NMOS input stage and the load stage, the rail-to-rail operational amplifier can be configured to an open-loop state (i.e., the output end of the rail-to-rail operational amplifier is not connected to the input end) through external hardware, and then the second offset voltage and the third offset voltage are calibrated.

[0065] Exemplarily, adjusting the second calibration current to calibrate the second offset voltage caused by the PMOS input stage may include: when the rail-to-rail operational amplifier is in an open-loop state, adjusting the second calibration current, and completing the calibration of the second offset voltage when the absolute value of the difference between the output voltage and the first voltage is less than a first preset threshold; or, when the rail-to-rail operational amplifier is in an open-loop state, adjusting the second calibration current, and completing the calibration of the second offset voltage when the absolute value of the current on the first voltage source is less than a second preset threshold; the first voltage source is connected to the output end of the rail-to-rail operational amplifier; the voltage of the first voltage source is the first voltage.

[0066] Exemplarily, adjusting the third calibration current to calibrate the third offset voltage caused by the NMOS input stage may include: when the rail-to-rail operational amplifier is in an open-loop state, adjusting the third calibration current, and completing the calibration of the third offset voltage when the absolute value of the difference between the output voltage and the first voltage is less than a first preset threshold; or, when the rail-to-rail operational amplifier is in an open-loop state, adjusting the third calibration current, and completing the calibration of the third offset voltage when the absolute value of the current on the first voltage source is less than a second preset threshold; the first voltage source is connected to the output end of the rail-to-rail operational amplifier; the voltage of the first voltage source is the first voltage.

[0067] Among them, the first preset threshold and the second preset threshold can be set to very small positive numbers. When the absolute value of the difference between the output voltage and the first voltage is less than the first preset threshold, it can be regarded as the absolute value of the difference between the output voltage and the first voltage is the smallest; when the absolute value of the current on the first voltage source is less than the second preset threshold, it can be regarded as the absolute value of the current on the first voltage source is the smallest.

[0068] The first voltage can be set by those skilled in the art according to actual needs, and is usually set to half of the power supply voltage (i.e. VDD / 2). When the open-loop output voltage is closest to the first voltage, it can be considered that the second offset voltage and the third offset voltage are calibrated. The open-loop output voltage can be compared with the first voltage, and the calibration of the second offset voltage and the third offset voltage is completed when the absolute value of the difference between the open-loop output voltage and the first voltage is minimum. The first voltage source can also be connected to the open-loop output end, and the voltage of the first voltage source is the first voltage. The closer the open-loop output voltage is to the first voltage, the closer the current on the first voltage source is to 0. The current on the first voltage source can be measured, and the calibration of the second offset voltage and the third offset voltage is completed when the absolute value of the current is minimum.

[0069] The offset voltage calibration circuit for a rail-to-rail operational amplifier in an embodiment of the present application divides the structure of the rail-to-rail operational amplifier into two parts based on whether the bias current changes with the common-mode input voltage, and performs offset voltage calibration on the two parts respectively. First, the offset voltage contributed by the part (i.e., the load stage and the output stage) of the bias current that does not change with the common-mode input voltage is calibrated, and then the offset voltage contributed by the part (i.e., the PMOS input stage and the NMOS input stage) of the bias current that changes with the common-mode input voltage is calibrated. The total offset voltage of the rail-to-rail operational amplifier can be accurately calibrated, and the total offset voltage can be stabilized at a lower level within the full common-mode input range.

[0070] In a possible implementation, the second calibration current module 202 may be implemented by replicating a PMOS input stage; and the third calibration current module 203 may be implemented by replicating an NMOS input stage.

[0071] Figure 4 FIG. 4 shows a schematic diagram of the structure of a second calibration current module and a third calibration current module according to an embodiment of the present application, wherein: Figure 4 (a) shows a schematic diagram of the structure of the second calibration current module, Figure 4 (b) shows a schematic structural diagram of the third calibration current module.

[0072] like Figure 4 As shown in (a), the second calibration current module 202 may include a third PMOS transistor MP3, a fourth PMOS transistor MP4, a third load current mirror and a third tail current source (ie Figure 4 (a) provides a device for providing current Itailp); the source of MP3 and the source of MP4 are connected to the output end of the third tail current source; the input end of the third tail current source is connected to the power supply voltage VDD; the first input end of the third load current mirror is connected to the drain of MP3, forming the first output end of the second calibration current module 202; the second input end of the third load current mirror is connected to the drain of MP4, forming the second output end of the second calibration current module 202; the output end of the third load current mirror is grounded; the first output end and the second output end of the second calibration current module 202 are respectively connected to the load stage, and the second calibration current (i.e., Itrim_P) is the difference between the output current of the second output end of the second calibration current module 202 and the output current of the first output end.

[0073] Figure 4 In the second calibration current module 202 shown in (a), the differential input pair formed by MP3 and MP4 is Figure 1 The third load current mirror is a replica of the differential input pair formed by MP1 and MP2 in the PMOS input stage shown, the third load current mirror is a replica of the first load current mirror in the PMOS input stage, the bias current Itailp provided by the third tail current source follows the bias current ITAILP provided by the first tail current source, the third tail current source can be implemented by a current mirror, the currents Itailp, Ip1, and Ip2 correspond to the bias currents ITAILP, IP1, and IP2 in the PMOS input stage, respectively, and the second calibration current module 202 can be called a replica stage of the PMOS input stage. The replication here needs to satisfy that the ratio between the transconductance of the second calibration current module 202 and the transconductance of the PMOS input stage and the ratio between the bias current of the second calibration current module 202 and the bias current of the PMOS input stage are equal.

[0074] Assuming that the transconductance of the PMOS input stage is GP1 and the transconductance of the second calibration current module 202 is GP2, GP2 / GP1=Itailp / ITAILP=Ip1 / IP1=Ip2 / IP2.

[0075] like Figure 4 As shown in (b), the third calibration current module 203 may include a third NMOS transistor MN3, a fourth NMOS transistor MN4, a fourth load current mirror and a fourth tail current source (ie Figure 4 (b) provides a device for providing current Itailn); the input end of the fourth load current mirror is connected to the power supply voltage VDD; the first output end of the fourth load current mirror is connected to the drain of MN3, forming the first output end of the third calibration current module 203; the second output end of the fourth load current mirror is connected to the drain of MN4, forming the second output end of the third calibration current module 203; the source of MN3 and the source of MN4 are connected to the input end of the fourth tail current source; the output end of the fourth tail current source is grounded; the first output end and the second output end of the third calibration current module 203 are respectively connected to the load stage, and the third calibration current (i.e., Itrim_N) is the difference between the output current of the second output end and the output current of the first output end of the third calibration current module 203.

[0076] Figure 4 In the third calibration current module 203 shown in (b), the differential input pair formed by MN3 and MN4 is Figure 1 The fourth load current mirror is a replica of the differential input pair formed by MN1 and MN2 in the NMOS input stage shown, the fourth load current mirror is a replica of the second load current mirror in the NMOS input stage, the bias current Itailn provided by the fourth tail current source follows the bias current ITAILN provided by the second tail current source, the fourth tail current source can be implemented by a current mirror, the currents Itailn, In1, and In2 correspond to the bias currents ITAILN, IN1, and IN2 in the NMOS input stage, respectively, and the third calibration current module 203 can be called a replica stage of the NMOS input stage. The replication here needs to satisfy the ratio between the transconductance of the third calibration current module 203 and the transconductance of the NMOS input stage and the ratio between the bias current of the third calibration current module 203 and the bias current of the NMOS input stage are equal.

[0077] Assuming that the transconductance of the NMOS input stage is GN1 and the transconductance of the second calibration current module 203 is GN2, then GN2 / GN1=Itailn / ITAILN=In1 / IN1=In2 / IN2.

[0078] As an example, the PMOS input stage can be replicated by making the circuit structure of the second calibration current module 202 the same as that of the PMOS input stage and the area and width-to-length ratio of the corresponding MOS tube in the circuit (that is, making the second calibration current module 202 and the PMOS input stage completely identical), and the NMOS input stage can be replicated by making the circuit structure of the third calibration current module 203 the same as that of the NMOS input stage and the area and width-to-length ratio of the corresponding MOS tube in the circuit (that is, making the third calibration current module 203 and the NMOS input stage completely identical). As another example, the PMOS input stage can be replicated by making the transconductance and bias current of the second calibration current module 202 proportionally smaller than that of the PMOS input stage, and the NMOS input stage can be replicated by making the transconductance and bias current of the third calibration current module 203 proportionally smaller than that of the NMOS input stage, so that the circuit area of ​​the replica stage can be saved.

[0079] It should be noted that the present application does not limit the implementation method of the PMOS input stage and the NMOS input stage, as long as it is ensured that only the bias current of the input stage in the rail-to-rail operational amplifier changes with the common-mode input voltage, and the second calibration current module 202 is a replica stage of the PMOS input stage, and the third calibration current module 203 is a replica stage of the NMOS input stage.

[0080] In a possible implementation, adjusting the second calibration current to calibrate the second offset voltage caused by the PMOS input stage may include:

[0081] A second reference voltage (ie, V2) is input to the gate of MP3, and a voltage which is the sum of the second reference voltage and a second calibration voltage (ie, ΔVtrimP) is input to the gate of MP4;

[0082] The second reference voltage is maintained constant, the second calibration voltage is adjusted to adjust the second calibration current output by the second calibration current module, and a target voltage value of the second calibration voltage for achieving the second offset voltage calibration is recorded.

[0083] In a possible implementation, adjusting the third calibration current to calibrate the third offset voltage caused by the NMOS input stage may include:

[0084] A third reference voltage (ie, V3) is input to the gate of MN3, and a voltage which is the sum of the third reference voltage and a third calibration voltage (ie, ΔVtrimN) is input to the gate of MN4;

[0085] The third reference voltage is maintained constant, the third calibration voltage is adjusted to adjust the third calibration current output by the third calibration current module, and a target voltage value of the third calibration voltage for achieving the third offset voltage calibration is recorded.

[0086] Since there is a voltage difference ΔVtrimP between the gates of MP3 and MP4, there is also a difference in the output current between the first output terminal and the second output terminal of the second calibration current module 202, and the difference in the output current of the two output terminals can be injected into the load stage as the second calibration current to calibrate the second offset voltage; similarly, there is a voltage difference ΔVtrimN between the gates of MN3 and MN4, and the difference in the output current of the two output terminals of the third calibration current module 203 can be injected into the load stage as the third calibration current to calibrate the third offset voltage. The node of the load stage to which the second calibration current and the third calibration current are injected can be determined according to actual needs, as long as the calibration of the offset voltage can be achieved.

[0087] Exemplarily, V2, V3, ΔVtrimP and ΔVtrimN are voltages with relatively low temperature coefficients, which can generate Itrim_P and Itrim_N with relatively low temperature coefficients.

[0088] For example, the offset voltage calibration module 204 may include a reference voltage source, and V2 , V3 , ΔVtrimP, and ΔVtrimN may be generated by the reference voltage source.

[0089] As an example, a bandgap voltage (Bandgap Voltage) VBG can be generated by a bandgap reference voltage source, and V2 = α*VBG, and V3 = β*VBG. The values ​​of α and β can be determined according to actual needs, as long as the differential input pair composed of MP3 and MP4 and the differential input pair composed of MN3 and MN4 can work normally.

[0090] Exemplarily, the offset voltage calibration module 204 may include a resistor digital to analog converter (RDAC), and ΔVtrimP and ΔVtrimN may be adjusted by RDAC. By adjusting ΔVtrimP and ΔVtrimN, Itrim_P and Itrim_N may be adjusted.

[0091] Exemplarily, the first output end of the second calibration current module 202 can be connected to the first output end of the PMOS input stage; the second output end of the second calibration current module 202 can be connected to the second output end of the PMOS input stage; in this way, the output current of the second calibration current module 202 enters the load stage together with the output current of the PMOS input stage, and the second calibration current can be injected into the load stage together with the error current generated by the PMOS input stage, so that the second offset voltage caused by the PMOS input stage can be calibrated.

[0092] Exemplarily, the first output terminal of the third calibration current module 203 can be connected to the first output terminal of the NMOS input stage; the second output terminal of the third calibration current module 203 can be connected to the second output terminal of the NMOS input stage; in this way, the output current of the third calibration current module 203 enters the load stage together with the output current of the NMOS input stage, and the third calibration current can be injected into the load stage together with the error current generated by the NMOS input stage, so that the third offset voltage caused by the NMOS input stage can be calibrated.

[0093] It should be noted that, although the embodiment of the present application takes the second calibration current module 202 as a replica stage of the PMOS input stage and the third calibration current module 203 as a replica stage of the NMOS input stage as an example to illustrate the implementation method of the second calibration current module 202 and the third calibration module 203, the present application should not be limited to this. The present application does not limit the implementation method of the second calibration current module 202 and the third calibration module 203, as long as the second calibration current module 202 can generate a second calibration current with a lower temperature coefficient and the third calibration current module 203 can generate a third calibration current with a lower temperature coefficient.

[0094] In a possible implementation, the first calibration current module 201 may be implemented using a PMOS differential input pair.

[0095] Figure 5 FIG. 4 shows a schematic diagram of the structure of a first calibration current module according to an embodiment of the present application. Figure 5 As shown, the first calibration current module 201 may include a fifth PMOS transistor MP5, a sixth PMOS transistor MP6 and a fifth tail current source (ie Figure 5The device that provides current ITAIL in the device); the source of MP5 and the source of MP6 are connected to the output end of the fifth tail current source; the input end of the fifth tail current source is connected to the power supply voltage VDD; the drain of MP5 is the first output end of the first calibration current module 201; the drain of MP6 is the second output end of the first calibration current module 201; the first output end and the second output end of the first calibration current module 201 are respectively connected to the load stage, and the first calibration current is the difference between the output current of the second output end and the output current of the first output end of the first calibration current module 201. MP5 and MP6 form a PMOS differential input pair, and the fifth tail current source is used to provide a stable bias current ITAIL for the PMOS differential input pair, and ITAIL can be set according to actual needs.

[0096] In a possible implementation, adjusting the first calibration current to calibrate a first offset voltage caused by the load stage and the output stage may include:

[0097] A first reference voltage (ie, V1) is input to the gate of MP5, and a voltage input to the gate of MP6 is the sum of the first reference voltage and a first calibration voltage (ie, ΔVtrimL);

[0098] The first reference voltage is maintained constant, the first calibration voltage is adjusted to adjust the first calibration current output by the first calibration current module, and a target voltage value of the first calibration voltage for achieving the first offset voltage calibration is recorded.

[0099] Since there is a voltage difference ΔVtrimL between the gates of MP5 and MP6, there is also a difference in the output current of the two output terminals of the first calibration current module 201. The difference in the output current of the two output terminals can be injected into the load stage as the first calibration current to calibrate the first offset voltage, and the first calibration current can be adjusted by adjusting ΔVtrimL. The node of the load stage to which the first calibration current is injected can be determined according to actual needs, as long as the calibration of the first offset voltage can be achieved.

[0100] Exemplarily, V1 and ΔVtrimL are voltages with relatively low temperature coefficients, so that Itrim_L with relatively low temperature coefficient can be generated. V1 and ΔVtrimL can be generated by a reference voltage source. As an example, a bandgap voltage VBG can be generated by a bandgap reference voltage source, and V1=θ*VBG can be set, and the value of θ can be determined according to actual needs, as long as the differential input pair formed by MP5 and MP6 can work normally.

[0101] It should be noted that, although the embodiment of the present application describes the implementation of the first calibration current module 201 using a PMOS differential input pair, the present application should not be limited thereto. The present application does not limit the implementation of the first calibration current module 201, as long as the implementation of the first calibration current module 201 can generate a first calibration current with a low temperature coefficient. For example, the first calibration current module 201 can also be implemented by an NMOS differential input pair; or, the first calibration current module 201 can also be implemented by using a reference current source and a current-type DAC, so that the reference current with a low temperature coefficient generated by the reference current source passes through the current-type DAC to generate the first calibration current.

[0102] The offset voltage calibration circuit of the embodiment of the present application can generate a calibration current by replicating the input stage of the rail-to-rail operational amplifier and using mature bandgap voltage generation technology. The offset voltage calibration circuit of the embodiment of the present application can make the calibration current generated by the second calibration current module 202 and the third calibration current module 203 adaptively follow the bias current of the corresponding input stage by replicating the PMOS input stage as the second calibration current module 202 and replicating the NMOS input stage as the third calibration current module 203, so that a good offset voltage calibration effect can be achieved in the transition region (i.e., the common-mode input voltage interval where the PMOS input stage and the NMOS input stage work simultaneously), and the offset voltage can be stabilized at a lower level within the full common-mode input range; and the offset voltage calibration circuit of the embodiment of the present application does not need to directly generate a calibration current with a lower temperature coefficient, and can generate a voltage with a lower temperature coefficient by using a mature bandgap voltage generation scheme, thereby generating a calibration current with a lower temperature coefficient, so that the calibrated offset voltage can have a lower temperature coefficient.

[0103] In the process of calibrating the offset voltage of the rail-to-rail operational amplifier using the above-mentioned offset voltage calibration circuit, the target voltage value of the first calibration voltage corresponding to the completion of the first offset voltage calibration, the target voltage value of the second calibration voltage corresponding to the completion of the second offset voltage calibration, and the target voltage value of the third calibration voltage corresponding to the completion of the third offset voltage calibration can be recorded. In a possible implementation, when the rail-to-rail operational amplifier is powered on again, the offset voltage calibration module 204 can also be used to: calibrate the first offset voltage according to the recorded target voltage value of the first calibration voltage; calibrate the second offset voltage according to the recorded target voltage value of the second calibration voltage; calibrate the third offset voltage according to the recorded target voltage value of the third calibration voltage. In this way, only one calibration process needs to be performed on the rail-to-rail operational amplifier using the above-mentioned offset voltage calibration circuit, that is, the offset voltage calibration effect can be maintained when the rail-to-rail operational amplifier is powered on again after power failure according to the three recorded calibration voltage values. Since the offset voltage calibration circuit of the embodiment of the present application can make the calibrated offset voltage have a lower temperature coefficient, even if the ambient temperature changes when the rail-to-rail operational amplifier is powered on again, a good offset voltage calibration effect can be maintained.

[0104] The present application also provides a rail-to-rail operational amplifier with an offset voltage calibration function.

[0105] Figure 6 FIG. 4 is a schematic diagram showing a structure of a rail-to-rail operational amplifier according to an embodiment of the present application. Figure 6 As shown, the rail-to-rail operational amplifier may include: a PMOS input stage 601, an NMOS input stage 602, a load stage 603, an output stage 604 and an offset voltage calibration circuit 605; the offset voltage calibration circuit 605 may include a first calibration current module 6051, a second calibration current module 6052, a third calibration current module 6053 and an offset voltage calibration module 6054.

[0106] The PMOS input stage 601 and the NMOS input stage 602 are connected to the load stage 603 respectively; the load stage 603 is connected to the output stage 604; the PMOS input stage 601 and the NMOS input stage 602 are used to receive a first input voltage (i.e., VIP) and a second input voltage (i.e., VIN), and obtain an output current based on the first input voltage and the second input voltage; the load stage 603 is used to obtain an output voltage based on the output current; the output stage 604 is used to output the output voltage (i.e., VOUT); wherein, the bias current of the PMOS input stage 601 and the NMOS input stage 602 varies with the common-mode input voltage; the bias current of the load stage 603 and the output stage 604 does not vary with the common-mode input voltage; the common-mode input voltage is the sum of the first input voltage and the second input voltage divided by 2.

[0107] The first calibration current module 6051 is used to input a first calibration current (i.e., Itrim_L) to the load stage 603; the second calibration current module 6052 is used to input a second calibration current (i.e., Itrim_P) to the load stage 603; the third calibration current module 6053 is used to input a third calibration current (i.e., Itrim_N) to the load stage 603; the offset voltage calibration module 6054 is used to:

[0108] Disconnecting the connection between the PMOS input stage 601 and the load stage 603 and disconnecting the connection between the NMOS input stage 602 and the load stage 603;

[0109] adjusting the first calibration current to calibrate a first offset voltage caused by the load stage 603 and the output stage 604;

[0110] Restoring the connection between the PMOS input stage 601 and the load stage 603 and restoring the connection between the NMOS input stage 602 and the load stage 603;

[0111] adjusting the second calibration current to calibrate a second offset voltage caused by the PMOS input stage 601;

[0112] The third calibration current is adjusted to calibrate a third offset voltage caused by the NMOS input stage 602 .

[0113] For example, the PMOS input stage 601, the NMOS input stage 602, the load stage 603 and the output stage 604 may be respectively as follows: Figure 1 The PMOS input stage, NMOS input stage, load stage and output stage shown in FIG. 6A , the first calibration current module 6051 may be as follows: Figure 5 The first calibration current module 201 and the second calibration current module 6052 may be as shown in FIG. Figure 4 The second calibration current module 202 shown in (a) and the third calibration current module 6053 can be as follows Figure 4 In the third calibration current module 203 shown in (b), the offset voltage calibration module 6054 is the offset voltage calibration module 204 described above.

[0114] Figure 7 A schematic diagram of the circuit structure of a rail-to-rail operational amplifier according to an embodiment of the present application is shown. Figure 7 As shown, the circuit structure of the PMOS input stage and the NMOS input stage in this circuit is similar to Figure 1 The circuit structures of the PMOS input stage and the NMOS input stage are the same, and the circuit structures of the first calibration current module, the second calibration current module and the third calibration current module are respectively the same as those of Figure 5 The first calibration current module shown, Figure 4 (a) shows the second calibration current module and Figure 4 (b) has the same circuit structure as the third calibration current module, wherein the first output end of the second calibration current module and the first output end of the PMOS input stage are connected to the first end of the first switch (i.e., S1), and the second output end of the second calibration current module and the second output end of the PMOS input stage are connected to the first end of the second switch (i.e., S2); the first output end of the third calibration current module and the first output end of the NMOS input stage are connected to the first end of the third switch (i.e., S3), and the second output end of the third calibration current module and the second output end of the NMOS input stage are connected to the first end of the fourth switch (i.e., S4); the second end of S1 and the first output end of the first calibration current module are connected to the load stage; the second end of S2 and the second output end of the first calibration current module are connected to the load stage; the second end of S3 and the second end of S4 are respectively connected to the load stage; and the load stage is connected to the output stage.

[0115] The rail-to-rail operational amplifier may also include an offset voltage calibration module. When calibrating the offset voltage of the rail-to-rail operational amplifier, the offset voltage calibration module first disconnects S1, S2, S3, and S4, maintains the first reference voltage (i.e., V1) unchanged, adjusts the first calibration current by adjusting the value of the first calibration voltage (i.e., ΔVtrimL), and calibrates the first offset voltage contributed by the load stage and the output stage; then turns on S1, S2, S3, and S4, sets the common-mode input voltage to the first common-mode voltage (e.g., to 0), makes the PMOS input stage work and the NMOS input stage not work, and maintains the second reference voltage (i.e., V2 ) is unchanged, the second calibration current is adjusted by adjusting the value of the second calibration voltage (i.e., ΔVtrimP), and the second offset voltage contributed by the PMOS input stage is calibrated; S1, S2, S3, and S4 are kept turned on, the common-mode input voltage is set to the second common-mode voltage (for example, set to VDD), the NMOS input stage is operated and the PMOS input stage is not operated, the third reference voltage (i.e., V3) is maintained unchanged, the third calibration current is adjusted by adjusting the value of the third calibration voltage (i.e., ΔVtrimN), and the third offset voltage contributed by the NMOS input stage is calibrated. The third offset voltage can also be calibrated first and then the second offset voltage.

[0116] The offset voltage calibration circuit in the rail-to-rail operational amplifier of the embodiment of the present application first calibrates the offset voltage contributed by the load stage and the output stage whose bias current does not change with the common-mode input voltage, and then calibrates the offset voltage contributed by the PMOS input stage and the NMOS input stage whose bias current changes with the common-mode input voltage, respectively. The calibration is performed three times in this way, and the offset voltage can be accurately calibrated. In addition, the second calibration current module and the third calibration current module in the offset voltage calibration circuit of the rail-to-rail operational amplifier of the embodiment of the present application are respectively the replica stages of the PMOS input stage and the NMOS input stage, and the bias current of the replica stage can completely follow the corresponding input stage, so that a calibration current that tracks the input stage bias current can be generated, thereby optimizing the offset voltage calibration effect of the transition zone, and stabilizing the offset voltage at a lower level within the full common-mode input range. In addition, the offset voltage calibration circuit in the rail-to-rail operational amplifier of the embodiment of the present application does not need to directly generate a calibration current with a lower temperature coefficient, and can generate a voltage with a lower temperature coefficient by using a mature bandgap voltage generation scheme, thereby generating a calibration current with a lower temperature coefficient, so that the calibrated offset voltage can have a lower temperature coefficient.

[0117] The present application also provides a method for calibrating an offset voltage of a rail-to-rail operational amplifier.

[0118] Figure 8 A flow chart of a method for calibrating an offset voltage of a rail-to-rail operational amplifier according to an embodiment of the present application is shown. The method can be used to calibrate the offset voltage of a rail-to-rail operational amplifier. Figure 1 The offset voltage of the rail-to-rail op amp shown in Figure 1 can be obtained by Figure 2 The offset voltage calibration circuit for the rail-to-rail operational amplifier is shown in FIG. Figure 8 As shown, the method may include:

[0119] S801 . Disconnect the connection between the PMOS input stage and the load stage, and disconnect the connection between the NMOS input stage and the load stage.

[0120] S802: Adjust the first calibration current to calibrate a first offset voltage caused by the load stage and the output stage.

[0121] S803: Restore the connection between the PMOS input stage and the load stage, and restore the connection between the NMOS input stage and the load stage.

[0122] S804: Adjust the second calibration current to calibrate a second offset voltage caused by the PMOS input stage.

[0123] S805 . Adjust the third calibration current to calibrate a third offset voltage caused by the NMOS input stage.

[0124] The implementation process of steps S801 to S805 may refer to the above description of the offset voltage calibration circuit for the rail-to-rail operational amplifier, and this application will not elaborate on this.

[0125] The offset voltage calibration method for a rail-to-rail operational amplifier in an embodiment of the present application can accurately calibrate the total offset voltage of the rail-to-rail operational amplifier by first calibrating the offset voltage contributed by the part of the bias current that does not change with the common-mode input voltage (i.e., the load stage and the output stage), and then calibrating the offset voltage contributed by the part of the bias current that changes with the common-mode input voltage (i.e., the PMOS input stage and the NMOS input stage), and stabilize the total offset voltage at a lower level within the full common-mode input range.

[0126] It should be noted that although the embodiment of the present application introduces the offset voltage calibration method for the rail-to-rail operational amplifier of the present application by taking the division of the rail-to-rail operational amplifier into a PMOS input stage, an NMOS input stage, a load stage and an output stage as an example, the division method of the rail-to-rail operational amplifier structure should not be limited to this. As long as the structure of the rail-to-rail operational amplifier can be divided into a part where the bias current changes with the common-mode input voltage and a part where the bias current does not change with the common-mode input voltage, the offset voltage calibration method of the present application can be applied for calibration.

[0127] It should be noted that the offset voltage calibration method of the present application is not limited to calibrating rail-to-rail operational amplifiers made using MOS devices. The offset voltage calibration method of the present application can also be applied to calibrate rail-to-rail operational amplifiers made using devices such as BJT.

[0128] The rail-to-rail operational amplifier with offset voltage calibration function provided in the present application can be integrated into a chip. Fig. 9 A schematic diagram of the structure of a chip according to an embodiment of the present application is shown. Fig. 9 As shown, the chip may include a PMOS input stage, an NMOS input stage, a load stage, an output stage, a first calibration current module, a second calibration current module and a third calibration current module. The circuit structure of each module may be the same as Figure 7 The circuit structures of corresponding modules in the circuit shown are the same.

[0129] Exemplarily, the chip may further include a current subtractor for determining whether to provide the bias current to the PMOS input stage or the NMOS input stage (equivalent to Figure 1 in MPs).

[0130] Exemplarily, the chip may further include a fuse-digital module and a reference voltage generation module, and the fuse-digital module and the reference voltage generation module may be used to implement the functions of the above-mentioned offset voltage calibration module.

[0131] Fig.10 A schematic diagram showing a method for calibrating the offset voltage of a rail-to-rail operational amplifier according to an embodiment of the present application is shown. The calibration process can be performed in the above chip by executing the above method. Fig.10 As shown, the Fuse-Digital module of the chip can receive digital signals from the off-chip communication port and generate corresponding calibration words (trim code) and control signals trimCAS according to the received digital signals. TrimCAS is used to control the switches in the circuit (i.e. Fig.10 s1~s6 in it are turned on or off; the reference voltage generating module can generate a first reference voltage (i.e., θ*VBG), a second reference voltage (i.e., α*VBG), a third reference voltage (i.e., β*VBG), a first calibration voltage (i.e., ΔVtrimL), a second calibration voltage (i.e., ΔVtrimP) and a third calibration voltage (i.e., ΔVtrimN) with a lower temperature coefficient, and can adjust ΔVtrimL, ΔVtrimP and ΔVtrimN according to the calibration word.

[0132] When calibrating the offset voltage of the rail-to-rail operational amplifier, trimCAS first controls all switches s1 to s6 to disconnect, disconnecting the connection between the PMOS input stage, the NMOS input stage, the second calibration current module, and the third calibration current module and the load stage. Then adjust ΔVtrimL to adjust the first calibration current (i.e., Itrim_L), for example, ΔVtrimL can be changed according to a certain step size. When VOUT is exactly equal to VDD / 2, it is considered that the first offset voltage contributed by the load stage and the output stage has been calibrated. The corresponding ΔVtrimL at this time can be written into the fuse-digital module.

[0133] After calibrating the first offset voltage, trimCAS controls all switches s1 to s6 to turn on, restore the connection between the PMOS input stage, the NMOS input stage, the second calibration current module, the third calibration current module and the load stage, and configure the rail-to-rail operational amplifier to a unit gain closed loop state. The common-mode input voltage can be set to 0, or other common-mode input voltages that can ensure that the NMOS input stage does not work, and then adjust ΔVtrimP to adjust the second calibration current (i.e., Itrim_P), for example, ΔVtrimP can be changed according to a certain step size. When VOUT = VIP, it is considered that the second offset voltage contributed by the PMOS input stage has been calibrated. The corresponding ΔVtrimP at this time can be written into the fuse-digital module.

[0134] After calibrating the second offset voltage, the connection between the PMOS input stage, the NMOS input stage, the second calibration current module, the third calibration current module and the load stage is maintained, and the rail-to-rail operational amplifier is maintained in a unit gain closed loop state. The common mode input voltage can be set to VDD, or other common mode input voltages that can ensure that the PMOS input stage does not work, and then ΔVtrimN is adjusted to adjust the third calibration current (i.e., Itrim_N), for example, ΔVtrimN can be changed according to a certain step size. When VOUT = VIP, it is considered that the third offset voltage contributed by the NMOS input stage has been calibrated. The corresponding ΔVtrimN at this time can be written into the fuse-digital module.

[0135] The ΔVtrimL, ΔVtrimP, and ΔVtrimN corresponding to each step of calibration when it is completed can be written into the fuse-digital module through a programmable electronic fuse (Efuse) or a laser trimming fuse (Laserfuse). In this way, the ΔVtrimL, ΔVtrimP, and ΔVtrimN corresponding to the calibration when it is completed can be recorded in the chip, so that these calibration voltages are still recorded in the chip when it is powered on again after power failure, so that the offset voltage can be quickly calibrated according to these recorded calibration voltages, ensuring that the calibration effect still exists when the chip is powered on again after power failure.

[0136] Three DC voltages can be used to simulate the first offset voltage Vos_L, the second offset voltage Vos_P and the third offset voltage Vos_N, where Vos_L = 0.5 mV, Vos_P = -1 mV, and Vos_N = 1 mV. In the above offset voltage calibration process, the variation of the total offset voltage with the common mode input voltage VCM can be simulated. Figure 11(a) to Figure 11(e) A schematic diagram showing the change of the total offset voltage with the common-mode input voltage during the calibration process of the offset voltage calibration method according to an embodiment of the present application is shown, wherein the red curve in FIG11(a) shows the change curve of the total offset voltage with the common-mode input voltage when no calibration is performed, the pink curve in FIG11(b) shows the change curve of the total offset voltage with the common-mode input voltage after the first offset voltage is calibrated, the orange curve in FIG11(c) shows the change curve of the total offset voltage with the common-mode input voltage after the second offset voltage is calibrated, the green curve in FIG11(d) shows the change curve of the total offset voltage with the common-mode input voltage after the third offset voltage is calibrated, and FIG11(e) is a detailed enlarged view of the green curve in FIG11(d).

[0137] As shown in Figure 11(a), when the offset voltage is not calibrated, the total offset voltage varies greatly with the common-mode input voltage, ranging from -1.04674mV to 0.951655mV. As shown in Figure 11(b), since the first offset voltage is completely calibrated, the total offset voltage is equal to the second offset voltage contributed by the PMOS input stage at low common-mode input voltage, and equal to the third offset voltage contributed by the N input stage at high common-mode input voltage. As shown in Figure 11(c), after the second offset voltage is calibrated, it can be seen that the total offset voltage is almost completely calibrated in the low common-mode input voltage range. The total offset voltage changes slightly in the high common-mode input voltage range, which is mainly due to the inherent non-ideality of the current mirror in the actual circuit, but it does not affect the effectiveness of the calibration method. As shown in Figure 11(d), after the third offset voltage is calibrated, it can be seen that the total offset voltage basically does not change with the common-mode input voltage. As shown in FIG11( e), after calibration, the total offset voltage changes with the common-mode input voltage by a very small amount, with the maximum change being only -5.36406 μV to 5.57724 μV. Therefore, the offset voltage calibration method for the rail-to-rail operational amplifier of the embodiment of the present application can accurately calibrate the offset voltage, greatly reduce the change of the offset voltage with the common-mode input voltage, and stabilize the offset voltage at a lower level within the full common-mode input range.

[0138] For the above chip, the offset voltage calibration method of the embodiment of the present application is used to calibrate the actual offset voltage of the MOS model provided in the process design kit (PDK) from the chip processing factory, and the change of the calibrated total offset voltage with the common-mode input voltage and temperature is simulated by the Monte Carlo simulation method. Fig.12 FIG. 4 shows the simulation results of the total offset voltage changing with the common mode input voltage after calibration according to the offset voltage calibration method of an embodiment of the present application. Fig.12 As shown, through multiple simulations using the Monte Carlo simulation method, it can be seen that after calibration, the maximum variation of the total offset voltage with the common-mode input voltage is within -72.55μV to 71.495μV, and the variation of the total offset voltage with the common-mode input voltage is very small. Fig.13 FIG. 4 shows the simulation results of the total offset voltage changing with temperature after calibration according to the offset voltage calibration method of an embodiment of the present application. Fig.13 As shown, by performing multiple simulations using the Monte Carlo simulation method, it can be seen that the maximum rate of change of the total offset voltage with temperature after calibration is about 573.5826nV / °C, and the rate of change of the total offset voltage with temperature is very low. The total offset voltage has a certain change with temperature after calibration, which is mainly due to the inherent temperature characteristics of the MOS tube mismatch. Compared with the existing offset voltage calibration method, after calibration by the offset voltage calibration method of the embodiment of the present application, the offset voltage changes with the common mode input voltage and temperature are significantly improved. The offset voltage calibration method of the embodiment of the present application can stabilize the offset voltage at a lower level within the full common mode input range, and the offset voltage temperature coefficient after calibration is low.

[0139] The embodiments of the present application have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and changes will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The selection of terms used herein is intended to best explain the principles of the embodiments, practical applications, or technical improvements in the market, or to enable other persons of ordinary skill in the art to understand the embodiments disclosed herein.

Claims

1. An offset voltage calibration circuit for a rail-to-rail operational amplifier, characterized in that: It includes a first calibration current module, a second calibration current module, a third calibration current module and an offset voltage calibration module; The rail-to-rail operational amplifier comprises a PMOS input stage, an NMOS input stage, a load stage and an output stage; the PMOS input stage and the NMOS input stage are respectively connected to the load stage; the load stage is connected to the output stage; the PMOS input stage and the NMOS input stage are used to receive a first input voltage and a second input voltage, and obtain an output current according to the first input voltage and the second input voltage; the load stage is used to obtain an output voltage according to the output current; the output stage is used to output the output voltage; wherein the bias current of the PMOS input stage and the NMOS input stage varies with a common-mode input voltage; the bias current of the load stage and the output stage does not vary with the common-mode input voltage; the common-mode input voltage is the sum of the first input voltage and the second input voltage divided by 2; The first calibration current module is used to input a first calibration current to the load stage; the second calibration current module is used to input a second calibration current to the load stage; the third calibration current module is used to input a third calibration current to the load stage; The offset voltage calibration module is used for: Disconnecting the PMOS input stage from the load stage and disconnecting the NMOS input stage from the load stage; adjusting the first calibration current to calibrate a first offset voltage caused by the load stage and the output stage; Restoring the connection between the PMOS input stage and the load stage and restoring the connection between the NMOS input stage and the load stage; adjusting the second calibration current to calibrate a second offset voltage caused by the PMOS input stage; The third calibration current is adjusted to calibrate a third offset voltage caused by the NMOS input stage.

2. The circuit according to claim 1, characterized in that Adjusting the second calibration current to calibrate the second offset voltage caused by the PMOS input stage includes: before adjusting the second calibration current, setting the common-mode input voltage to a first common-mode voltage; the first common-mode voltage is a voltage that enables the PMOS input stage to work normally and the NMOS input stage to not work; and / or, Adjusting the third calibration current to calibrate the third offset voltage caused by the NMOS input stage includes: before adjusting the third calibration current, setting the common-mode input voltage to a second common-mode voltage; the second common-mode voltage is a voltage that enables the NMOS input stage to work normally and the PMOS input stage to not work.

3. The circuit according to claim 1, characterized in that Adjusting the first calibration current to calibrate a first offset voltage caused by the load level and the output stage includes: The first calibration current is adjusted to complete calibration of the first offset voltage when the output voltage is equal to half of the power supply voltage of the rail-to-rail operational amplifier.

4. The circuit according to claim 2, characterized in that Adjusting the second calibration current to calibrate a second offset voltage caused by the PMOS input stage includes: When the rail-to-rail operational amplifier is in a closed-loop state, the second calibration current is adjusted to complete calibration of the second offset voltage when the output voltage is equal to the first input voltage; or When the rail-to-rail operational amplifier is in an open-loop state, the second calibration current is adjusted, and when the absolute value of the difference between the output voltage and the first voltage is less than a first preset threshold, the calibration of the second offset voltage is completed; or, When the rail-to-rail operational amplifier is in an open-loop state, the second calibration current is adjusted, and when the absolute value of the current on the first voltage source is less than a second preset threshold, the calibration of the second offset voltage is completed; the first voltage source is connected to the output end of the rail-to-rail operational amplifier; the voltage of the first voltage source is the first voltage.

5. The circuit according to claim 2, characterized in that Adjusting the third calibration current to calibrate a third offset voltage caused by the NMOS input stage comprises: When the rail-to-rail operational amplifier is in a closed-loop state, the third calibration current is adjusted, and when the output voltage is equal to the first input voltage, the calibration of the third offset voltage is completed; or, When the rail-to-rail operational amplifier is in an open-loop state, the third calibration current is adjusted, and when the absolute value of the difference between the output voltage and the first voltage is less than a first preset threshold, the calibration of the third offset voltage is completed; or, When the rail-to-rail operational amplifier is in an open-loop state, the third calibration current is adjusted, and when the absolute value of the current on the first voltage source is less than a second preset threshold, the calibration of the third offset voltage is completed; the first voltage source is connected to the output end of the rail-to-rail operational amplifier; the voltage of the first voltage source is the first voltage.

6. The circuit according to any one of claims 2 to 5, characterized in that: The second calibration current module includes a third PMOS tube, a fourth PMOS tube, a third load current mirror and a third tail current source; the source of the third PMOS tube and the source of the fourth PMOS tube are connected to the output end of the third tail current source; the input end of the third tail current source is connected to the power supply voltage of the rail-to-rail operational amplifier; the first input end of the third load current mirror is connected to the drain of the third PMOS tube to form the first output end of the second calibration current module; the second input end of the third load current mirror is connected to the drain of the fourth PMOS tube to form the second output end of the second calibration current module; the output end of the third load current mirror is grounded; the first output end and the second output end of the second calibration current module are respectively connected to the load stage, and the second calibration current is the difference between the output current of the second output end and the output current of the first output end of the second calibration current module; The ratio of the transconductance of the second calibration current module to the transconductance of the PMOS input stage is equal to the ratio of the bias current of the second calibration current module to the bias current of the PMOS input stage.

7. The circuit according to claim 6, characterized in that Adjusting the second calibration current to calibrate a second offset voltage caused by the PMOS input stage includes: A second reference voltage is input to the gate of the third PMOS tube, and a voltage which is the sum of the second reference voltage and a second calibration voltage is input to the gate of the fourth PMOS tube; The second reference voltage is maintained constant, the second calibration voltage is adjusted to adjust the second calibration current output by the second calibration current module, and a target voltage value of the second calibration voltage for achieving the second offset voltage calibration is recorded.

8. The circuit according to claim 7, characterized in that The third calibration current module includes a third NMOS tube, a fourth NMOS tube, a fourth load current mirror and a fourth tail current source; the input end of the fourth load current mirror is connected to the power supply voltage; the first output end of the fourth load current mirror is connected to the drain of the third NMOS tube, forming the first output end of the third calibration current module; the second output end of the fourth load current mirror is connected to the drain of the fourth NMOS tube, forming the second output end of the third calibration current module; the source of the third NMOS tube and the source of the fourth NMOS tube are connected to the input end of the fourth tail current source; the output end of the fourth tail current source is grounded; the first output end and the second output end of the third calibration current module are respectively connected to the load stage, and the third calibration current is the difference between the output current of the second output end and the output current of the first output end of the third calibration current module; The ratio of the transconductance of the third calibration current module to the transconductance of the NMOS input stage is equal to the ratio of the bias current of the third calibration current module to the bias current of the NMOS input stage.

9. The circuit according to claim 8, characterized in that Adjusting the third calibration current to calibrate a third offset voltage caused by the NMOS input stage comprises: Inputting a third reference voltage to the gate of the third NMOS transistor, and inputting a voltage which is the sum of the third reference voltage and a third calibration voltage to the gate of the fourth NMOS transistor; The third reference voltage is maintained constant, the third calibration voltage is adjusted to adjust the third calibration current output by the third calibration current module, and a target voltage value of the third calibration voltage for achieving the third offset voltage calibration is recorded.

10. The circuit according to claim 9, characterized in that The first calibration current module includes a fifth PMOS tube, a sixth PMOS tube and a fifth tail current source; the source of the fifth PMOS tube and the source of the sixth PMOS tube are connected to the output end of the fifth tail current source; the input end of the fifth tail current source is connected to the power supply voltage; the drain of the fifth PMOS tube is the first output end of the first calibration current module; the drain of the sixth PMOS tube is the second output end of the first calibration current module; the first output end and the second output end of the first calibration current module are respectively connected to the load stage, and the first calibration current is the difference between the output current of the second output end and the output current of the first output end of the first calibration current module.

11. The circuit according to claim 10, characterized in that Adjusting the first calibration current to calibrate a first offset voltage caused by the load level and the output stage includes: Inputting a first reference voltage to the gate of the fifth PMOS tube, and inputting a voltage which is a sum of the first reference voltage and a first calibration voltage to the gate of the sixth PMOS tube; The first reference voltage is maintained constant, the first calibration voltage is adjusted to adjust the first calibration current output by the first calibration current module, and a target voltage value of the first calibration voltage for achieving the first offset voltage calibration is recorded.

12. The circuit according to claim 11, characterized in that When the rail-to-rail operational amplifier is powered on again, the offset voltage calibration module is further used to: Calibrate the first offset voltage according to the recorded target voltage value of the first calibration voltage; Calibrate the second offset voltage according to the recorded target voltage value of the second calibration voltage; The third offset voltage is calibrated according to the recorded target voltage value of the third calibration voltage.

13. A rail-to-rail operational amplifier, characterized in that: It includes a PMOS input stage, an NMOS input stage, a load stage, an output stage and an offset voltage calibration circuit; the offset voltage calibration circuit includes a first calibration current module, a second calibration current module, a third calibration current module and an offset voltage calibration module; The PMOS input stage and the NMOS input stage are connected to the load stage respectively; the load stage is connected to the output stage; the PMOS input stage and the NMOS input stage are used to receive a first input voltage and a second input voltage, and obtain an output current according to the first input voltage and the second input voltage; the load stage is used to obtain an output voltage according to the output current; the output stage is used to output the output voltage; wherein the bias current of the PMOS input stage and the NMOS input stage varies with a common-mode input voltage; the bias current of the load stage and the output stage does not vary with the common-mode input voltage; the common-mode input voltage is the sum of the first input voltage and the second input voltage divided by 2; The first calibration current module is used to input a first calibration current to the load stage; the second calibration current module is used to input a second calibration current to the load stage; the third calibration current module is used to input a third calibration current to the load stage; The offset voltage calibration module is used for: Disconnecting the PMOS input stage from the load stage and disconnecting the NMOS input stage from the load stage; adjusting the first calibration current to calibrate a first offset voltage caused by the load stage and the output stage; Restoring the connection between the PMOS input stage and the load stage and restoring the connection between the NMOS input stage and the load stage; adjusting the second calibration current to calibrate a second offset voltage caused by the PMOS input stage; The third calibration current is adjusted to calibrate a third offset voltage caused by the NMOS input stage.

14. A method for calibrating an offset voltage of a rail-to-rail operational amplifier, characterized in that: The offset voltage calibration circuit for a rail-to-rail operational amplifier applied to any one of claims 1-12, the method comprising: Disconnecting the PMOS input stage from the load stage and disconnecting the NMOS input stage from the load stage; adjusting the first calibration current to calibrate a first offset voltage caused by the load stage and the output stage; Restoring the connection between the PMOS input stage and the load stage and restoring the connection between the NMOS input stage and the load stage; adjusting the second calibration current to calibrate a second offset voltage caused by the PMOS input stage; The third calibration current is adjusted to calibrate a third offset voltage caused by the NMOS input stage.