A nonlinear calibration circuit and method for capacitance measurement system
By introducing active integrator and nonlinear calibration circuit in the capacitance measurement system, the nonlinear problem in capacitance compensation is solved, and efficient nonlinear calibration of the capacitor to be measured is achieved, which improves measurement accuracy and speed and reduces power consumption.
Patent Information
- Application Number
- CN202211562864.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-07
- Publication Date
- 2025-03-04
- Estimated Expiration
- 2042-12-07
AI Technical Summary
The existing capacitance compensation method has nonlinear problems in capacitance measurement systems, especially when the capacitance to be measured is much smaller than the passive integrated capacitor, which affects the measurement accuracy and speed.
Nonlinear calibration of the capacitor to be measured is achieved by introducing an off-chip or on-chip active integrator, combined with nonlinear calibration circuits and methods. The scheme includes the initial capacitance, the capacitance to be measured, the quantization unit, the capacitance compensation unit, the comparator, the counting unit and the calibration capacitor. Through multiple compensation and quantization, the coefficients of the calibration curve are obtained and the nonlinear calibration is completed.
This solution can effectively compensate the parasitic capacitance on the PCB board under the conditions of an active integrator, and perform nonlinear calibration of the compensated capacitor to be measured, improving the speed and accuracy of measurement quantization and reducing power consumption.
Smart Images

Figure CN115932692B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of capacitance measurement calibration, and in particular to a nonlinear calibration circuit and method for a capacitance measurement system. Background Art
[0002] Capacitive touch technology is widely used in household appliances, industrial products, and consumer products such as mobile phones due to its advantages such as simple structure, low power consumption, fast response speed, and strong anti-interference ability. The basic principle of the capacitance measurement system is to measure and process the charge on the measured capacitor. However, the parasitic capacitance on the PCB board is generally very large, far higher than the range of capacitance that needs to be measured. Therefore, compensation technology is needed to compensate for the large parasitic capacitance and only measure a small amount of capacitance within the range of variation.
[0003] The existing scheme provides three compensation methods:
[0004] (1) Current compensation: a certain amount of current noise is introduced each time. For large parasitic capacitors, the current noise accumulated accounts for a large proportion. In addition, for the system with speed requirements, the compensation current needs a large current to complete the compensation quickly, which also consumes a lot of power.
[0005] (2) Resistance compensation adopts the discharge method. The RC discharge process itself is nonlinear and does not have a completely stable time. In addition, the discharge time will also be affected by clock jitter, which is not conducive to application.
[0006] (3) Capacitor compensation. In the case of passive integrator applications, capacitor compensation is voltage-dependent during charge sharing, so nonlinearity will occur, especially when the capacitance to be measured is not much smaller than the passive integrating capacitance.
[0007] Taking the above three compensation methods into consideration, the capacitor compensation solution has the lowest power consumption and the fastest speed, and its nonlinearity is much smaller than that of the resistor compensation. However, this method can currently only be used under the condition of an off-chip passive integrator. Summary of the invention
[0008] The purpose of the present invention is to introduce the capacitance compensation method of the present scheme into the schemes of off-chip active integrator and on-chip active integrator to obtain its advantages, and to provide corresponding calibration schemes to solve the nonlinear problem of capacitance compensation in the present scheme, and to provide a nonlinear calibration circuit and method for a capacitance measurement system.
[0009] In order to achieve the above-mentioned object of the invention, the embodiment of the present invention provides the following technical solutions:
[0010] A nonlinear calibration circuit for a capacitance measurement system comprises: an initial capacitance, a capacitance to be measured, a quantization unit, a capacitance compensation unit, a comparator, a counting unit, and a calibration capacitor, wherein:
[0011] The first end of the initial capacitor is connected to the quantization unit, the second end of the initial capacitor is connected to the ground, the quantization unit is connected to the first input end of the comparator, and the output end of the comparator is connected to the input end of the counting unit;
[0012] The first end of the capacitor to be measured is connected to the quantization unit and the capacitance compensation unit respectively, and the second end of the capacitor to be measured is connected to the ground;
[0013] The first end of the calibration capacitor is connected to the first end of the capacitor to be measured, and the second end of the calibration capacitor is connected to the ground.
[0014] Furthermore, it also includes an amplifier, wherein a first input terminal of the amplifier is connected to the quantization unit, and an output terminal of the amplifier is respectively connected to the quantization unit and a first input terminal of the comparator.
[0015] Furthermore, the first ends of the initial capacitor, the capacitor to be measured, and the calibration capacitor are all connected to a reference voltage Vref through a switch CK_CG.
[0016] Furthermore, the quantization unit includes a switch CK_S1 and a current detector; a first end of the switch CK_S1 is connected to a first input end of the comparator, a second end of the switch CK_S1 is connected to a first end of the current detector, and a second end of the current detector is connected to ground.
[0017] Furthermore, the capacitance compensation unit includes a switch CK_COMP_N, a switch CK_COMP_P, and a compensation capacitor Cd;
[0018] The first end of the switch CK_COMP_N is connected to the first end of the capacitor to be measured, the second end of the switch CK_COMP_N is connected to the first end of the switch CK_COMP_P and the first end of the compensation capacitor Cd respectively, and the second end of the switch CK_COMP_P and the second end of the compensation capacitor Cd are both connected to the ground.
[0019] Furthermore, the amplifier is also connected to a feedback capacitor Cint, a first end of the feedback capacitor Cint is connected to the first input end of the amplifier, and a second end of the feedback capacitor Cint is connected to the output end of the amplifier; the feedback capacitor Cint is connected in parallel with a switch K6, and when the switch K6 is disconnected, the amplifier is connected to the calibration circuit.
[0020] A nonlinear calibration method for a capacitance measurement system, applied to any of the calibration circuits above, comprises the following steps:
[0021] Step 1, connecting the initial capacitance to the calibration circuit, quantizing the initial capacitance, and obtaining an initial number, wherein the initial number is the number of times the charge of the initial capacitance is quantified;
[0022] Step 2, replacing the initial capacitance with the capacitance to be measured and connecting it to the calibration circuit, trying different compensation times for the capacitance to be measured, so that when the compensated capacitance to be measured is quantized, the quantization times obtained are less than the initial times, and the quantization times are the times the charge of the compensated capacitance to be measured is extracted; and at the same time, obtaining the compensation times N for the capacitance to be measured when the quantization times are less than the initial times;
[0023] Step 3, connecting the amplifier to the first input terminal of the calibration circuit, performing N times of compensation on the capacitance to be measured, and then quantizing the compensated capacitance to be measured. When the charge on the amplifier integration capacitor is 0, the quantization is completed to obtain a first count.
[0024] Step 4, respectively adding the first calibration capacitor and the second calibration capacitor to the capacitor to be measured, and repeating step 3 to obtain the second count and the third count respectively;
[0025] Step 5: Substitute the first count, the second count, and the third count into the calibration curve y=ax 2 +bx+c, we get the coefficients a, b, c of the calibration curve, and complete the nonlinear calibration of the capacitance measurement system.
[0026] Furthermore, the step of obtaining the initial number of times in step 1 specifically includes:
[0027] The reference voltage Vref charges the initial capacitor C. After the charging is completed, the charge stored on the initial capacitor C is Q. The charge Q on the initial capacitor C is quantized by the quantization unit until the voltage on the initial capacitor C is a common mode voltage Vcm. The common mode voltage Vcm is the access potential of the second input terminal of the comparator.
[0028] The process of quantizing the charge Q on the initial capacitor C by the quantization unit includes: repeatedly closing the switch CK_S1 for a period of ∆t and then opening it until the voltage on the initial capacitor C is the common mode voltage Vcm, and recording the count value of the counting unit as the initial number n1.
[0029] Furthermore, the step of obtaining the quantization times in step 2 includes:
[0030] The reference voltage Vref charges the capacitor Cs to be measured;
[0031] The capacitance compensation circuit compensates the capacitance Cs to be measured;
[0032] The remaining charge Q on the capacitor Cs to be measured after the quantization unit performs N compensations NQuantization is performed until the voltage on the capacitor Cs to be measured reaches the common mode voltage Vcm, and the quantization process is completed;
[0033] The remaining charge Q on the capacitor Cs to be measured after the quantization unit performs N compensations N The quantization process includes: repeatedly closing the switch CK_S1 for a time period of ∆t and then opening it until the voltage on the capacitor Cs to be measured is the common mode voltage Vcm, and recording the count value of the counting unit as the quantization number n2;
[0034] If n2 is greater than n1, the compensation times N are readjusted so that the remaining charge Q after the capacitor Cs to be measured is compensated N times N After the quantization unit completes the quantization, the obtained quantization number n2 is less than the initial number n1; at the same time, the compensation number N for the capacitance Cs to be measured is obtained when the quantization number n2 is less than the initial number n1.
[0035] Furthermore, the step of obtaining the first count in step 3 includes:
[0036] After N compensations are performed on the capacitor Cs to be measured, the remaining charge in the capacitor Cs to be measured is Q N1 ; Connect the amplifier to the calibration circuit, and the quantization unit will measure the charge Q on the amplifier's integral capacitor. T1 Quantization is performed, where Q T1 =Q N1 -Vcm, Vcm is the voltage of the second input terminal of the amplifier, and Vcm=Vref / 2, until the charge on the amplifier integration capacitor Q T1 is 0;
[0037] The quantization unit measures the charge Q on the amplifier's integrating capacitor. T1 The quantization process includes: repeatedly closing the switch CK_S1 for a period of ∆t and then opening it until the charge on the amplifier integration capacitor Q T1 is 0, and the count value of the counting unit is recorded as the first count m1.
[0038] Furthermore, the step of obtaining the second count in step 4 includes:
[0039] The first calibration capacitor C1 is connected in parallel with the capacitor to be measured Cs to form a capacitor group Cs1. The reference voltage Vref charges the capacitor group Cs1. After the charging is completed, the charge stored on the capacitor group Cs1 is Q 02 After the capacitor compensation circuit compensates the capacitor group Cs1 N times, the remaining charge on the capacitor group Cs1 is Q N2 ;
[0040] The quantization unit measures the charge Q on the amplifier's integrating capacitor. T2 Quantization is performed, where QT2 =Q N2 -Vcm*Cs1, until the charge on the amplifier integration capacitor is Q T2 =0;
[0041] The quantization unit measures the charge Q on the amplifier's integrating capacitor. T2 The quantization process includes: repeatedly closing the switch CK_S1 for a period of ∆t and then opening it until the charge on the amplifier integration capacitor Q T2 is 0, and the count value of the counting unit is recorded as the second count m2.
[0042] Furthermore, the step of obtaining the third count in step 4 includes:
[0043] The first calibration capacitor C1 connected in parallel with the capacitor Cs to be measured is replaced by the second calibration capacitor C2 to form a capacitor group Cs2. The reference voltage Vref charges the capacitor group Cs2. After charging, the charge stored on the capacitor group Cs2 is Q 03 After the capacitor compensation circuit compensates the capacitor group Cs2 N times, the remaining charge on the capacitor group Cs2 is Q N3 ;
[0044] The quantization unit measures the charge Q on the amplifier's integrating capacitor. T3 Quantization is performed, where Q T3 =Q N3 -Vcm*Cs2, until the charge on the amplifier integration capacitor is Q T3 =0;
[0045] The charge Q on the amplifier's integrating capacitor T3 The quantization process includes: repeatedly closing the switch CK_S1 for a period of ∆t and then opening it until the charge on the amplifier integration capacitor Q T3 is 0, and the count value of the counting unit is recorded as the third count m3.
[0046] Furthermore, the step of completing the nonlinear calibration of the capacitance measurement system in step 5 includes:
[0047] The first count m1 is used as y=ax of the calibration curve 2 +bx+c's y value, at this time x=0, calculate the coefficient c;
[0048] The second count m2 is used as the calibration curve y=ax 2 +bx+c, where x is the capacitance of the first calibration capacitor C1; and the third count m3 is used as the calibration curve y=ax 2 +bx+c, where x is the capacitance of the second calibration capacitor C2, and the coefficients a and b are calculated.
[0049] Furthermore, the method further includes step 6, removing the first calibration capacitor or the second calibration capacitor connected in parallel with the capacitor to be measured, and repeating step 3 when detecting the charge on the capacitor to be measured Cs to obtain the count mf to be measured; and using the count mf to be measured as the calibration curve y=ax 2 +bx+c, the calculated x is the charge on the capacitor Cs to be measured.
[0050] Compared with the prior art, the present invention has the following beneficial effects:
[0051] The present invention can be applied in the solution of active integrator to compensate the parasitic capacitance on the CPB board and perform nonlinear calibration on the compensated capacitance to be measured. In practical application, only the variable capacitance in the compensated capacitance to be measured is measured, thereby improving the speed and accuracy of measurement quantization and reducing power consumption. BRIEF DESCRIPTION OF THE DRAWINGS
[0052] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for use in the embodiments are briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without creative work.
[0053] Figure 1 is a circuit schematic diagram of a calibration circuit of an embodiment;
[0054] Figure 2 The circuit schematic diagram of step 1 of the calibration method of the embodiment;
[0055] Figure 3 The schematic diagram of the circuit of step 2 of the calibration method of the embodiment;
[0056] Figure 4 This is a circuit schematic diagram of step 3 of the calibration method of this embodiment;
[0057] Figure 5 4 is a schematic diagram of a circuit incorporating a first calibration capacitor in step 4 of the calibration method of the embodiment;
[0058] Figure 6 4 is a circuit schematic diagram of a second calibration capacitor incorporated in step 4 of the calibration method of this embodiment;
[0059] Figure 7 This is a circuit schematic diagram of step 6 of the calibration method of this embodiment;
[0060] Figure 8 Schematic diagram of a circuit for compensating a capacitance to be measured by a capacitance compensation circuit in an embodiment. DETAILED DESCRIPTION
[0061] The technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. The components of the embodiments of the present invention generally described and shown in the drawings here can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present invention provided in the drawings is not intended to limit the scope of the claimed invention, but merely represents the selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without making creative work belong to the scope of protection of the present invention.
[0062] It should be noted that similar numbers and letters represent similar items in the following figures, so once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures. At the same time, in the description of the present invention, the terms "first", "second", etc. are only used to distinguish the description, and cannot be understood as indicating or implying relative importance, or implying any such actual relationship or order between these entities or operations. In addition, the terms "connected", "connected", etc. can be directly connected between elements, or indirectly connected via other elements.
[0063] The present invention is implemented by the following technical solutions, see Figure 1 A nonlinear calibration circuit for a capacitance measurement system includes: a calibration capacitor, an initial capacitor C, a capacitance to be measured Cs, a quantization unit, a capacitance compensation unit, an amplifier, a comparator, and a counting unit. The calibration capacitor includes a first calibration capacitor C1 and a second calibration capacitor C2.
[0064] The first end of the initial capacitor C is connected to the quantization unit, the second end of the initial capacitor C is connected to the ground, the quantization unit is connected to the first input end of the comparator, and the output end of the comparator is connected to the input end of the counting unit. The first end of the capacitor to be measured Cs is connected to the quantization unit and the capacitance compensation unit respectively, and the second end of the capacitor to be measured Cs is connected to the ground. The first end of the first calibration capacitor C1 is connected to the first end of the capacitor to be measured Cs, and the second end of the first calibration capacitor C1 is connected to the ground. The first end of the second calibration capacitor C2 is connected to the first end of the capacitor to be measured Cs, and the second end of the second calibration capacitor C2 is connected to the ground.
[0065] Please refer to Figure 1 , control the capacitance to be measured Cs to be connected to the calibration circuit through switch K1; control the initial capacitance C to be connected to the calibration circuit through switch K2; control the first calibration capacitance C1 to be connected to the calibration circuit through switch K3; control the second calibration capacitance C2 to be connected to the calibration circuit through switch K4.
[0066] The first ends of the capacitance to be measured, the initial capacitance, the first calibration capacitance, and the second calibration capacitance are all connected to the reference voltage Vref through the switch CK_CG.
[0067] The quantization unit includes a switch CK_S1 and a current detector; the first end of the switch CK_S1 is connected to the first input end of the comparator, the second end of the switch CK_S1 is connected to the first end of the current detector, and the second end of the current detector is connected to the ground. By repeatedly controlling the switch CK_S1 to be closed for a period of ∆t and then disconnected, the initial capacitance C or the capacitance to be measured Cs is quantified.
[0068] The capacitance compensation unit includes a switch CK_COMP_N, a switch CK_COMP_P, and a compensation capacitor Cd; a first end of the switch CK_COMP_N is connected to a first end of a capacitor to be measured, a second end of the switch CK_COMP_N is respectively connected to a first end of the switch CK_COMP_P and a first end of the compensation capacitor Cd, and a second end of the switch CK_COMP_P and a second end of the compensation capacitor Cd are both connected to the ground.
[0069] The amplifier is also connected to a feedback capacitor Cint, a first end of the feedback capacitor Cint is connected to a first input end of the amplifier, and a second end of the feedback capacitor Cint is connected to an output end of the amplifier. A switch K5 is connected to the input end of the amplifier, and a switch K6 is connected in parallel to the feedback capacitor Cint. When the calibration circuit is working normally, the switch K5 is always closed (therefore, the switch K5 can also be omitted). When the switch K6 is closed, the amplifier is not connected to the calibration circuit; when the switch K6 is disconnected, the amplifier is connected to the calibration circuit.
[0070] Usually, due to the large parasitic capacitance Cp at the capacitor Cs to be measured, if the charge of the capacitor Cs to be measured is directly detected, it will be affected by the parasitic capacitance Cp. Assuming that the parasitic capacitance Cp=50pF, when the charge in the capacitor Cs to be measured is 0, the capacitance input by the capacitance detection system is not 0, but equal to 50pF. Similarly, when the charge in the capacitor Cs to be measured is 10pF, the capacitance input by the capacitance detection system is 60pF. Therefore, when it is necessary to measure the changing capacitance of 0~10pF in the capacitor Cs to be measured, it will be affected by the parasitic capacitance Cp, making the measured charge in the capacitor Cs to be measured inaccurate. Therefore, this solution will compensate for the parasitic capacitance Cp and calibrate the measured value of the compensated capacitor Cs to be measured to obtain the accurate charge value on the capacitor Cs to be measured.
[0071] Based on the above calibration circuit, the present invention also proposes a nonlinear calibration method for a capacitance measurement system, comprising the following steps:
[0072] Step 1: connect the initial capacitor to the calibration circuit, quantify the initial capacitor, and obtain an initial number, where the initial number is the number of times the charge of the initial capacitor is quantified.
[0073] like Figure 2 As shown, the reference voltage Vref charges the initial capacitor C. After the charging is completed, the charge stored on the initial capacitor C is Q. The charge Q on the initial capacitor C is quantized by the quantization unit until the voltage on the initial capacitor C is the common mode voltage Vcm. The common mode voltage Vcm is the access potential of the second input terminal of the comparator, and the quantization process is completed.
[0074] The current of the current detector in the quantization unit is I. Each time the switch CK_S1 is closed, the quantization unit quantizes the charge ∆Q on the initial capacitor C, and ∆Q=I·∆t, where ∆t is the duration of the switch CK_S1 being closed. The process of the quantization unit quantizing the charge Q on the initial capacitor C includes: repeatedly closing the switch CK_S1 for ∆t and then disconnecting it until the voltage on the initial capacitor C is the common mode voltage Vcm, and recording the count value of the counting unit as the initial number n1, which is the number of times the switch CK_S1 is closed.
[0075] In one embodiment, the capacitance of the initial capacitor C can be selected as 5pF, and 5pF is related to the gain swing of the integrator. The capacitance that can be quantified by the quantization unit in the example is 0~15pF. The effect of the detection capacitor compensation is to make its equivalent capacitance after compensation less than 5pF. In this way, even if the measured capacitance changes by 10pF on this basis, under the same number of compensation times, the equivalent capacitance value quantized by the quantization unit will still be less than 15pF, ensuring that the system will not exceed the quantization range.
[0076] Step 2: Replace the initial capacitance with the capacitance to be measured and connect it to the calibration circuit, and try different compensation times for the capacitance to be measured, so that when the compensated capacitance to be measured is quantized, the quantization number obtained is less than the initial number, and the quantization number is the number of times the charge of the compensated capacitance to be measured is extracted; at the same time, the compensation number N of the capacitance to be measured is obtained when the quantization number is less than the initial number.
[0077] like Figure 3 As shown, the reference voltage Vref charges the capacitor Cs to be measured. After the charging is completed, the charge stored on the capacitor Cs to be measured is Q0. The capacitor compensation circuit compensates the capacitor Cs to be measured. The principle of the capacitor compensation circuit is as follows: Figure 8 As shown, there are:
[0078]
[0079] The capacitance compensation circuit compensates the capacitance Cs to be measured:
[0080]
[0081]
[0082]
[0083] Wherein, Cd is the compensation capacitor; V1 is the voltage at the intersection of the capacitor Cs to be measured and the compensation capacitor Cd after the capacitor Cs to be measured is compensated once; Q1 is the remaining charge on the capacitor Cs to be measured after the capacitor Cs to be measured is compensated once;
[0084] After the capacitance compensation circuit compensates the capacitance Cs to be measured N times:
[0085]
[0086]
[0087] Among them, V N Q is the voltage at the intersection of the measured capacitance Cs and the compensation capacitance Cd after the measured capacitance Cs is compensated N times; N The remaining charge on the capacitor Cs to be measured after N compensations are performed on the capacitor to be measured;
[0088] The remaining charge Q on the capacitor Cs to be measured after the quantization unit performs N compensations N Quantization is performed until the voltage on the capacitor Cs to be measured is Vcm, and the quantization process is completed;
[0089] The remaining charge Q on the capacitor Cs to be measured after the quantization unit performs N compensations N The quantization process includes: repeatedly closing the switch CK_S1 for a period of ∆t and then opening it until the voltage on the capacitor Cs to be measured is the common mode voltage Vcm, and recording the count value of the counting unit as the quantization number n2.
[0090] If n2 is greater than n1, the compensation times N are readjusted so that the remaining charge Q after the capacitor Cs to be measured is compensated N times N After the quantization unit completes the quantization, the obtained quantization number n2 is less than the initial number n1; at the same time, the compensation number N for the capacitance Cs to be measured is obtained when the quantization number n2 is less than the initial number n1.
[0091] Step 3, connecting the calibration circuit to the first input terminal of the amplifier, performing N times of compensation on the capacitance to be measured, and then quantizing the compensated capacitance to be measured. When the charge on the amplifier integration capacitor is 0, the quantization is completed to obtain a first count.
[0092] like Figure 4As shown, after the compensation times N obtained in step 2 are used to compensate the capacitance Cs to be measured N times, the remaining charge in the capacitance Cs to be measured is Q N1 ; Disconnect switch K6, connect the amplifier to the calibration circuit, and the quantization unit calculates the charge Q on the amplifier integration capacitor T1 Quantization is performed, where Q T1 =Q N1 -Vcm, Vcm is the voltage of the second input terminal of the amplifier, and Vcm=Vref / 2, until the charge on the amplifier integration capacitor Q T1 is 0;
[0093] The quantization unit measures the charge Q on the amplifier's integrating capacitor. T1 The quantization process includes: repeatedly closing the switch CK_S1 for a period of ∆t and then opening it until the charge on the amplifier integration capacitor Q T1 is 0, and the count value of the counting unit is recorded as the first count m1.
[0094] Step 4, respectively add the first calibration capacitor and the second calibration capacitor to the capacitor to be measured, and repeat step 3 to obtain the second count and the third count respectively.
[0095] Step 3 is equivalent to connecting a calibration capacitor with a capacitance of 0 in parallel with the capacitance to be measured Cs, such as Figure 5 As shown, in this step, the first calibration capacitor C1 is connected in parallel with the capacitor to be measured Cs to form a capacitor group Cs1. The reference voltage Vref charges the capacitor group Cs1. After the charging is completed, the charge stored on the capacitor group Cs1 is Q 02 After the capacitor compensation circuit compensates the capacitor group Cs1 N times, the remaining charge on the capacitor group Cs1 is Q N2 ;
[0096] The quantization unit measures the charge Q on the amplifier's integrating capacitor. T2 Quantization is performed, where Q T2 =Q N2 -Vcm*Cs1, until the charge on the amplifier integration capacitor is Q T2 = 0. The quantization unit measures the charge Q on the amplifier integration capacitor. T2 The quantization process includes: repeatedly closing the switch CK_S1 for a period of ∆t and then opening it until the charge on the amplifier integration capacitor Q T2 is 0, and the count value of the counting unit is recorded as the second count m2.
[0097] Then, if Figure 6 As shown, the first calibration capacitor C1 connected in parallel with the capacitor to be measured Cs is replaced with the second calibration capacitor C2 to form a capacitor group Cs2. The reference voltage Vref charges the capacitor group Cs2. After the charging is completed, the charge stored on the capacitor group Cs2 is Q03 After the capacitor compensation circuit compensates the capacitor group Cs2 N times, the remaining charge on the capacitor group Cs2 is Q N3 ;
[0098] The quantization unit measures the charge Q on the amplifier's integrating capacitor. T3 Quantization is performed, where Q T3 =Q N3 -Vcm*Cs2, until the charge on the amplifier integration capacitor is Q T3 = 0. The charge on the amplifier integrating capacitor Q T3 The quantization process includes: repeatedly closing the switch CK_S1 for a period of ∆t and then opening it until the charge on the amplifier integration capacitor Q T3 is 0, and the count value of the counting unit is recorded as the third count m3.
[0099] Assuming that the first calibration capacitor C1 is 5pF and the second calibration capacitor C2 is 10pF, then step 2 and step 3 are equivalent to respectively connecting the calibration capacitors of 0pF, 5pF, and 10pF in parallel with the capacitance to be measured Cs, thereby obtaining the first count m1, the second count m2, and the third count m3, respectively. However, in other implementation schemes, the first calibration capacitor C1 and the second calibration capacitor C2 can be other data, and the purpose is also to obtain the first count m1, the second count m2, and the third count m3.
[0100] In one implementation, if the first calibration capacitor C1 = 5 pF and the initial capacitor C = 5 pF, the initial capacitor C can be directly used to replace the first calibration capacitor C1 to simplify the structure of the entire calibration circuit as much as possible.
[0101] Step 5: Substitute the first count, the second count, and the third count into the calibration curve y=ax 2 +bx+c, we get the coefficients a, b, c of the calibration curve, and complete the nonlinear calibration of the capacitance measurement system.
[0102] The first count m1 is used as y=ax of the calibration curve 2 +bx+c, where x=0, calculate the coefficient c; use the second count m2 as the calibration curve y=ax 2 +bx+c, where x is the capacitance of the first calibration capacitor C1; and the third count m3 is used as the calibration curve y=ax 2 +bx+c, where x is the capacitance of the second calibration capacitor C2, and the coefficients a and b are calculated.
[0103] The calibration curve can be in the form of a high-order polynomial. For a touch detection system, a quadratic function can meet the requirements of nonlinear calibration.
[0104] Step 6, such as Figure 7 As shown, disconnect the first calibration capacitor or the second calibration capacitor connected in parallel with the capacitor to be measured, and repeat step 3 when detecting the charge on the capacitor to be measured Cs to obtain the count mf to be measured; use the count mf to be measured as the calibration curve y=ax 2 +bx+c, the calculated x is the charge on the capacitor Cs to be measured.
[0105] The above is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any person skilled in the art can easily think of changes or substitutions within the technical scope disclosed by the present invention, which should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention should be based on the protection scope of the claims.
Claims
1. A nonlinear calibration circuit for a capacitance measurement system, characterized in that: include: Initial capacitance, capacitance to be measured, quantization unit, capacitance compensation unit, comparator, counting unit, calibration capacitance, wherein, The first end of the initial capacitor is connected to the quantization unit, the second end of the initial capacitor is connected to the ground, the quantization unit is connected to the first input end of the comparator, and the output end of the comparator is connected to the input end of the counting unit; The first end of the capacitor to be measured is connected to the quantization unit and the capacitance compensation unit respectively, and the second end of the capacitor to be measured is connected to the ground; the capacitance compensation unit is used to try different compensation times for the capacitor to be measured, so that when the compensated capacitor to be measured is quantized, the quantization number obtained is less than the initial number, the quantization number is the number of times the quantization unit extracts the charge of the compensated capacitor to be measured, and the initial number is the number of times the quantization unit quantizes the charge of the initial capacitor; and at the same time, the compensation number N of the capacitor to be measured is obtained when the quantization number is less than the initial number; The calibration capacitor includes a first calibration capacitor and a second calibration capacitor, wherein the first end of the first calibration capacitor is connected to the first end of the capacitor to be measured, and the second end of the first calibration capacitor is connected to the ground; the first end of the second calibration capacitor is connected to the first end of the capacitor to be measured, and the second end of the second calibration capacitor is connected to the ground.
2. The nonlinear calibration circuit for a capacitance measurement system according to claim 1, characterized in that: It also includes an amplifier, wherein a first input terminal of the amplifier is connected to the quantization unit, and an output terminal of the amplifier is respectively connected to the quantization unit and the first input terminal of the comparator.
3. The nonlinear calibration circuit for a capacitance measurement system according to claim 1, characterized in that: The first ends of the initial capacitor, the capacitor to be measured, and the calibration capacitor are all connected to a reference voltage Vref through a switch CK_CG.
4. The nonlinear calibration circuit for a capacitance measurement system according to claim 1, characterized in that: The quantization unit includes a switch CK_S1 and a current detector; a first end of the switch CK_S1 is connected to a first input end of the comparator, a second end of the switch CK_S1 is connected to a first end of the current detector, and a second end of the current detector is connected to the ground.
5. The nonlinear calibration circuit for a capacitance measurement system according to claim 1, characterized in that: The capacitance compensation unit includes a switch CK_COMP_N, a switch CK_COMP_P, and a compensation capacitor Cd; The first end of the switch CK_COMP_N is connected to the first end of the capacitor to be measured, the second end of the switch CK_COMP_N is connected to the first end of the switch CK_COMP_P and the first end of the compensation capacitor Cd respectively, and the second end of the switch CK_COMP_P and the second end of the compensation capacitor Cd are both connected to the ground.
6. The nonlinear calibration circuit for a capacitance measurement system according to claim 2, characterized in that: The amplifier is also connected to a feedback capacitor Cint, a first end of the feedback capacitor Cint is connected to a first input end of the amplifier, and a second end of the feedback capacitor Cint is connected to an output end of the amplifier; a switch K6 is connected in parallel to the feedback capacitor Cint, and when the switch K6 is disconnected, the amplifier is connected to the calibration circuit.
7. A nonlinear calibration method for a capacitance measurement system, applied to the calibration circuit of any one of claims 1 to 6, characterized in that: The following steps are involved: Step 1, connecting the initial capacitance to the calibration circuit, quantizing the initial capacitance, and obtaining an initial number, wherein the initial number is the number of times the charge of the initial capacitance is quantified; Step 2, replacing the initial capacitance with the capacitance to be measured and connecting it to the calibration circuit, trying different compensation times for the capacitance to be measured, so that when the compensated capacitance to be measured is quantized, the quantization times obtained are less than the initial times, and the quantization times are the times that the charge of the compensated capacitance to be measured is extracted; At the same time, the compensation times N of the capacitance to be measured is obtained when the quantization times are less than the initial times; Step 3, connecting the amplifier to the first input terminal of the calibration circuit, performing N times of compensation on the capacitance to be measured, and then quantizing the compensated capacitance to be measured. When the charge on the amplifier integration capacitor is 0, the quantization is completed to obtain a first count. Step 4, respectively adding the first calibration capacitor and the second calibration capacitor to the capacitor to be measured, and repeating step 3 to obtain the second count and the third count respectively; Step 5: Substitute the first count, the second count, and the third count into the calibration curve y=ax 2 +bx+c, we get the coefficients a, b, c of the calibration curve, and complete the nonlinear calibration of the capacitance measurement system.
8. The nonlinear calibration method for a capacitance measurement system according to claim 7, characterized in that: The step 1 of obtaining the initial number of times specifically includes: The reference voltage Vref charges the initial capacitor C. After the charging is completed, the charge stored on the initial capacitor C is Q. The charge Q on the initial capacitor C is quantized by the quantization unit until the voltage on the initial capacitor C is a common mode voltage Vcm. The common mode voltage Vcm is the access potential of the second input terminal of the comparator. The process of quantizing the charge Q on the initial capacitor C by the quantization unit includes: repeatedly closing the switch CK_S1 for a period of ∆t and then opening it until the voltage on the initial capacitor C is the common mode voltage Vcm, and recording the count value of the counting unit as the initial number n1.
9. A nonlinear calibration method for a capacitance measurement system according to claim 8, characterized in that: The step 2 of obtaining the quantization times comprises: The reference voltage Vref charges the capacitor Cs to be measured; The capacitance compensation circuit compensates the capacitance Cs to be measured; The remaining charge Q on the capacitor Cs to be measured after the quantization unit performs N compensations N Quantization is performed until the voltage on the capacitor Cs to be measured reaches the common mode voltage Vcm, and the quantization process is completed; The remaining charge Q on the capacitor Cs to be measured after the quantization unit performs N compensations N The quantization process includes: repeatedly closing the switch CK_S1 for a time period of ∆t and then opening it until the voltage on the capacitor Cs to be measured is the common mode voltage Vcm, and recording the count value of the counting unit as the quantization number n2; If n2 is greater than n1, the compensation times N are readjusted so that the remaining charge Q after the capacitor Cs to be measured is compensated N times N After the quantization unit completes the quantization, the obtained quantization number n2 is less than the initial number n1; at the same time, the compensation number N for the capacitance Cs to be measured is obtained when the quantization number n2 is less than the initial number n1.
10. The nonlinear calibration method for a capacitance measurement system according to claim 7, characterized in that: The step of obtaining the first count in step 3 comprises: After N compensations are performed on the capacitor Cs to be measured, the remaining charge in the capacitor Cs to be measured is Q N1 ; Connect the amplifier to the calibration circuit, and the quantization unit will measure the charge Q on the amplifier's integral capacitor. T1 Quantization is performed, where Q T1 =Q N1 -Vcm, Vcm is the voltage of the second input terminal of the amplifier, and Vcm=Vref / 2, until the charge on the amplifier integration capacitor Q T1 is 0; The quantization unit measures the charge Q on the amplifier's integrating capacitor. T1 The quantization process includes: repeatedly closing the switch CK_S1 for a period of ∆t and then opening it until the charge on the amplifier integration capacitor Q T1 is 0, and the count value of the counting unit is recorded as the first count m1.
11. A nonlinear calibration method for a capacitance measurement system according to claim 10, characterized in that: The step of obtaining the second count in step 4 comprises: The first calibration capacitor C1 is connected in parallel with the capacitor to be measured Cs to form a capacitor group Cs1. The reference voltage Vref charges the capacitor group Cs1. After the charging is completed, the charge stored on the capacitor group Cs1 is Q 02 After the capacitor compensation circuit compensates the capacitor group Cs1 N times, the remaining charge on the capacitor group Cs1 is Q N2 ; The quantization unit measures the charge Q on the amplifier's integrating capacitor. T2 Quantization is performed, where Q T2 =Q N2 -Vcm*Cs1, until the charge on the amplifier integration capacitor is Q T2 =0; The quantization unit measures the charge Q on the amplifier's integrating capacitor. T2 The quantization process includes: repeatedly closing the switch CK_S1 for a period of ∆t and then opening it until the charge on the amplifier integration capacitor Q T2 is 0, and the count value of the counting unit is recorded as the second count m2.
12. A nonlinear calibration method for a capacitance measurement system according to claim 11, characterized in that: The step of obtaining the third count in step 4 comprises: The first calibration capacitor C1 connected in parallel with the capacitor Cs to be measured is replaced by the second calibration capacitor C2 to form a capacitor group Cs2. The reference voltage Vref charges the capacitor group Cs2. After charging, the charge stored on the capacitor group Cs2 is Q 03 After the capacitor compensation circuit compensates the capacitor group Cs2 N times, the remaining charge on the capacitor group Cs2 is Q N3 ; The quantization unit measures the charge Q on the amplifier's integrating capacitor. T3 Quantization is performed, where Q T3 =Q N3 -Vcm*Cs2, until the charge on the amplifier integration capacitor is Q T3 =0; The charge Q on the amplifier's integrating capacitor T3 The quantization process includes: repeatedly closing the switch CK_S1 for a period of ∆t and then opening it until the charge on the amplifier integration capacitor Q T3 is 0, and the count value of the counting unit is recorded as the third count m3.
13. A nonlinear calibration method for a capacitance measurement system according to claim 12, characterized in that: The step of completing the nonlinear calibration of the capacitance measurement system in step 5 includes: The first count m1 is used as y=ax of the calibration curve 2 +bx+c's y value, when x=0, calculate the coefficient c; The second count m2 is used as the calibration curve y=ax 2 +bx+c, where x is the capacitance of the first calibration capacitor C1; and the third count m3 is used as the calibration curve y=ax 2 +bx+c, where x is the capacitance of the second calibration capacitor C2, and the coefficients a and b are calculated.
14. A nonlinear calibration method for a capacitance measurement system according to any one of claims 7 to 13, characterized in that: The method further includes step 6, removing the first calibration capacitor or the second calibration capacitor connected in parallel with the capacitor to be measured, and repeating step 3 when detecting the charge on the capacitor to be measured Cs to obtain the count mf to be measured; and using the count mf to be measured as the calibration curve y=ax 2 +bx+c, the calculated x is the charge on the capacitor Cs to be measured.
Citation Information
Patent Citations
Asynchronous capacitive sensor interface circuit with self-calibration function
CN114964318A