High-precision resistance measurement system and method combining micro-differential method and ratiometric method
11327099 · 2022-05-10
Assignee
Inventors
- Zeyu Chen (Changsha, CN)
- Shaoqiang Liu (Changsha, CN)
- Dulin Li (Changsha, CN)
- Xiaoping Fan (Changsha, CN)
- Yiming Zhang (Changsha, CN)
Cpc classification
G01R27/14
PHYSICS
G01R1/30
PHYSICS
G01R27/08
PHYSICS
G01R27/02
PHYSICS
International classification
G01R27/02
PHYSICS
G01R27/08
PHYSICS
G01R27/14
PHYSICS
Abstract
Disclosed are a high-precision resistance measurement system and method combining a micro-differential method and a ratiometric method. The system includes a constant-current source, a reference resistor, a first differential amplifier, a programmable gain amplifier (PGA), an ADC, a microprocessor, a DAC and a to-be-measured resistor interface. The reference resistor and a to-be-measured resistor are connected in series between the constant-current source and ground. The voltage across the reference resistor is inputted to the first differential amplifier, and the output of the first differential amplifier is used as the reference voltage for the ADC and the DAC. The single-ended voltage to ground of the to-be-measured resistor and the output voltage of the DAC are inputted to the PGA in differential manner, and the PGA outputs the amplified difference voltage to the ADC. The output terminal of the ADC and the input terminal of the DAC are both connected to the microprocessor.
Claims
1. A high-precision resistance measurement system combining a micro-differential method and a ratiometric method, comprising: a constant-current source, a reference resistor, a first differential amplifier, a programmable gain amplifier (PGA), an analog-to-digital converter (ADC), a microprocessor, a digital-to-analog converter (DAC), and a to-be-measured resistor interface, wherein the to-be-measured resistor interface is configured to connect to a to-be-measured resistor; the reference resistor and the to-be-measured resistor are connected in series to form a series branch, wherein one terminal of the series branch is connected to the constant-current source, and an other terminal of the series brand is grounded; two input terminals of the first differential amplifier are respectively connected to two terminals of the reference resistor, and an output terminal of the first differential amplifier is connected to a voltage reference terminal of the ADC; a voltage reference terminal of the DAC is also connected to the output terminal of the first differential amplifier; a first input terminal of the PGA is configured to connect to a single-ended voltage to ground of the to-be-measured resistor, a second input terminal of the PGA is operable to be selectively connected to an output terminal of the DAC or grounded, and an output terminal of the PGA is connected to an input terminal of the ADC, wherein the single-ended voltage to ground of the to-be-measured resistor corresponds to a voltage drop across the to-be-measured resistor; and an output terminal of the ADC and an input terminal of the DAC are both connected to the microprocessor.
2. The high-precision resistance measurement system according to claim 1, wherein the constant-current source, the reference resistor, the to-be-measured resistor, and ground are connected in sequence to form the series branch, and the first input terminal of the PGA is connected to an ungrounded terminal of the to-be-measured resistor; or the high-precision resistance measurement system further comprises a second differential amplifier, wherein the constant-current source, the to-be-measured resistor, the reference resistor, and ground are connected in sequence to form the series branch, two input terminals of the second differential amplifier are respectively connected to two terminals of the to-be-measured resistor, an output terminal of the second differential amplifier is connected to the first input terminal of the PGA, and the second differential amplifier has a gain factor of 2.
3. The high-precision resistance measurement system according to claim 1, wherein a control terminal of the PGA is connected to the microprocessor, and an amplification factor of the PGA is set by the microprocessor.
4. The high-precision resistance measurement system according to claim 1, wherein an amplification factor of the PGA satisfies the following condition: a voltage value outputted by the PGA is less than a maximum conversion value of the ADC.
5. The high-precision resistance measurement system according to claim 1, further comprising: a first switch element, wherein a control terminal of the first switch element is connected to the microprocessor and is used by the microprocessor to control the second input terminal of the PGA to be connected to the output terminal of the DAC or ground; and/or a second switch element, wherein a control terminal of the second switch element is connected to the microprocessor and is used by the microprocessor to control the output terminal of the first differential amplifier to be connected to or disconnected from the voltage reference terminal of the ADC; and/or a third switch element, wherein a control terminal of the third switch element is connected to the microprocessor and is used by the microprocessor to control the output terminal of the first differential amplifier to be connected to or disconnected from the voltage reference terminal of the DAC.
6. A high-precision resistance measurement method combining a micro-differential method and a ratiometric method, comprising the following steps: step 1: connecting a to-be-measured resistor to the to-be-measured resistor interface of the high-precision resistance measurement system according to claim 1, wherein the second input terminal of the PGA is grounded; step 2: acquiring, by the microprocessor, an analog-to-digital conversion result corresponding to the to-be-measured resistor: step 2.1: amplifying, by the PGA, a single-ended voltage to ground U.sub.S of the to-be-measured resistor by a factor of A1 to obtain a first voltage U.sub.S*A1, performing, by the ADC, analog-to-digital conversion on the first voltage U.sub.S*A1 to obtain a first voltage digital quantity D1, and reading, by the microprocessor, the first voltage digital quantity D1 from the ADC; step 2.2: calculating and outputting, by the microprocessor, a given voltage digital quantity D1′ according to a resolution of the DAC and transmitting the given voltage digital quantity to the DAC, performing, by the DAC, digital-to-analog conversion on the given voltage digital quantity D1′ to obtain a given voltage U1, wherein
7. The high-precision resistance measurement method according to claim 6, wherein the high-precision resistance measurement system further comprises a first switch element, wherein a control terminal of the first switch element is connected to the microprocessor, wherein before step 2, the microprocessor controls the first switch element to connect the second input terminal of the PGA to ground; and during step 2.3, the microprocessor controls the first switch element to connect the second input terminal of the PGA to the output terminal of the DAC.
8. The high-precision resistance measurement method according to claim 6, wherein the high-precision resistance measurement system further comprises a second switch element and a third switch element, wherein control terminals of the second switch element and the third switch element are both connected to the microprocessor, wherein before step 2, the microprocessor controls the second switch element to be turned on to connect the output terminal of the first differential amplifier to the voltage reference terminal of the ADC; after step 3, the microprocessor controls the second switch element to be turned off to disconnect the output terminal of the first differential amplifier from the voltage reference terminal of the ADC; before step 2, the microprocessor controls the third switch element to be turned on to connect the output terminal of the first differential amplifier to the voltage reference terminal of the DAC; and after step 3, the microprocessor controls the third switch element to be turned off to disconnect the output terminal of the first differential amplifier from the voltage reference terminal of the DAC.
9. The high-precision resistance measurement method according to claim 6, wherein before step 2.1, the microprocessor sets an amplification factor of the PGA to A1 and after step 2.2 and before step 2.4 the microprocessor sets the amplification factor of the PGA to A2.
10. The high-precision resistance measurement method according to claim 6, wherein the constant-current source, the reference resistor, the to-be-measured resistor, and ground are connected in sequence to form the series branch, and the first input terminal of the PGA is connected to an ungrounded terminal of the to-be-measured resistor; or the high-precision resistance measurement system further comprises a second differential amplifier, wherein the constant-current source, the to-be-measured resistor, the reference resistor, and ground are connected in sequence to form the series branch, two input terminals of the second differential amplifier are respectively connected to two terminals of the to-be-measured resistor, an output terminal of the second differential amplifier is connected to the first input terminal of the PGA, and the second differential amplifier has a gain factor of 2.
11. The high-precision resistance measurement method according to claim 6, wherein a control terminal of the PGA is connected to the microprocessor, and an amplification factor of the PGA is set by the microprocessor.
12. The high-precision resistance measurement method according to claim 6, wherein an amplification factor of the PGA satisfies the following condition: a voltage value outputted by the PGA is less than a maximum conversion value of the ADC.
Description
BRIEF DESCRIPTION OF THE DRAWINGS
(1)
(2)
(3)
(4)
DETAILED DESCRIPTION OF THE EMBODIMENTS
(5) Embodiments of the present disclosure are described in detail below. The embodiments are performed based on technical solutions of the present disclosure, and detailed implementations and specific operation processes are given to further explain the technical solutions of the present disclosure.
Embodiment I
(6) This embodiment provides a high-precision resistance measurement system combining a micro-differential method and a ratiometric method. A principle block diagram of the system is shown in
(7) A first terminal of the reference resistor is connected to a first terminal of the to-be-measured resistor interface, a second terminal of the reference resistor is connected to the constant-current source, and a second terminal of the to-be-measured resistor interface is grounded.
(8) The two terminals of the reference resistor are respectively connected to two input terminals of the first differential amplifier Amp1. An output terminal of the first differential amplifier Amp1 is connected to a voltage reference terminal of the ADC through the second analog switch TI, and is connected to a voltage reference terminal of the DAC through the third analog switch HI. A control terminal of the second analog switch II and a control terminal of the third analog switch III are both connected to the microprocessor, and the second analog switch and the third analog switch are controlled by the microprocessor to be turned on and off. The voltage reference terminals described in this embodiment refer to a positive voltage reference terminal VREF(+) of the ADC or the DAC, and a negative voltage reference terminal VREF(−) is grounded.
(9) A first input terminal of the PGA is connected to a second terminal of the to-be-measured resistor. A second input terminal of the PGA is connected to the first analog switch I. The control terminal of the first analog switch I is connected to the microprocessor, and the microprocessor controls the second input terminal of the PGA to be connected to an output terminal of the DAC or ground. An output terminal of the PGA is connected to an input terminal of the ADC. A control terminal of the PGA is connected to the microprocessor. An amplification factor of the PGA is controlled by the microprocessor, and the amplification factor satisfies the following condition: a voltage value outputted by the PGA is less than a maximum conversion value of the ADC. The maximum conversion value herein may be understood as a critical input value upon overflow after the ADC performs conversion.
(10) An output terminal of the ADC and an input terminal of the DAC are both connected to the microprocessor.
(11) In this embodiment, a model of the microprocessor (CPU) is AT89C51, a model of the ADC is 8-bit (binary) ADC0809, the DAC is MAX517 having the same resolution as the ADC, the PGA is composed of an instrumentation amplifier AD620, a multiplex switch CD4051, and a resistor element, a model of the first differential amplifier Amp1 is AD620, models of the second analog switch II and the third analog switch III are AD6821, a model of the first analog switch is ADG852, a voltage reference source is REF2933AIDBZT, and the reference resistor R.sub.N is a 100-ohm manganese copper resistor.
(12) A circuit of the constant-current, source used in this embodiment is a common solution for load-grounded constant current source circuits, and is mainly composed of a common voltage reference device and an operational amplifier, as shown in
(13) In addition, in this embodiment, the first differential amplifier Amp1 amplifies a terminal voltage U.sub.N of the reference resistor R.sub.N by a factor of A.sub.REF, and transforms the voltage to a single-ended output voltage referenced to an analog ground potential (that is, a zero potential), which is provided as a common reference voltage U.sub.REF to the ADC and the DAC. In this way, measurement errors caused by a change or an inaccurate value of the working current of the to-be-measured resistor as well as the reference voltage U.sub.REF for the ADC and the DAC and changes thereof can be eliminated.
(14) The amplification factor A.sub.REF of the first differential amplifier Amp1 is set according to an amplitude of the terminal voltage U.sub.N of the reference resistor R.sub.N and an allowable reference voltage value for the ADC and the DAC.
(15) Corresponding to the above high-precision resistance measurement system, this embodiment further uses the system to further explain a method for measuring the to-be-measured resistor. The measurement method specifically includes the following steps:
(16) Step 1: Connect the to-be-measured resistor to the to-be-measured resistor interface of the high-precision resistance measurement system combining a micro-differential method and a ratiometric method.
(17) The system includes a constant-current source, a reference resistor, a first differential amplifier, a PGA, an ADC, a microprocessor, a DAC, and a to-be-measured resistor interface.
(18) The to-be-measured resistor interface is configured to connect to a to-be-measured resistor.
(19) The reference resistor and the to-be-measured resistor are connected in series to form a series branch, where one terminal of the series branch is connected to the constant-current source, and an other terminal of the series branch is grounded.
(20) Two input terminals of the first differential amplifier are respectively connected to two terminals of the reference resistor, and an output terminal of the first differential amplifier is connected to a voltage reference terminal of the ADC and the DAC.
(21) A first input terminal of the PGA is configured to connect to a single-ended voltage to ground of the to-be-measured resistor, a second input terminal of the PGA is operable to be selectively connected to an output terminal of the DAC or ground, and an output terminal of the PGA is connected to an input terminal of the ADC; the single-ended voltage to ground of the to-be-measured resistor corresponds to a voltage drop across the to-be-measured resistor.
(22) An output terminal of the ADC and an input terminal of the DAC are both connected to the microprocessor.
(23) Before step 2, it needs to be determined whether the second input terminal of the PGA is connected to ground, and if not, the control terminal of the first analog switch I needs to be controlled by the microprocessor to connect the second input terminal of the PGA to ground.
(24) Before step 2, it needs to be further determined whether the output terminal of the first differential amplifier Amp1 is connected to the voltage reference terminal of the ADC and the voltage reference terminal of the DAC. If the voltage reference terminal of either the ADC or the DAC is not connected to the output terminal of the first differential amplifier Amp1, a control terminal of a corresponding analog switch needs to be controlled by the microprocessor to connect the voltage reference terminals of both the ADC and the DAC to the output terminal of the first differential amplifier Amp1 to receive the reference voltage U.sub.REF provided by the first differential amplifier Amp1.
(25) Step 2: The microprocessor acquires calculated data of a resistance value.
(26) Step 2.1: The PGA amplifies a single-ended voltage to ground U.sub.S of the to-be-measured resistor by a factor of A1 to obtain a first voltage U.sub.S*A1, the ADC performs analog-to-digital conversion on the obtained first voltage U.sub.S*A1 to obtain a first voltage digital quantity D1, and the microprocessor reads the first voltage digital quantity D1 from the ADC.
(27) Before step 2.1, the method further includes setting the amplification factor of the PGA to A1 through the connection between the microprocessor and the control terminal of the PGA.
(28) Step 2,2: The microprocessor calculates and outputs a given voltage digital quantity D1′ according to a resolution of the DAC and the first voltage digital quantity D1 and transmits the digital quantity to the DAC which performs digital-to-analog conversion on the given voltage digital quantity D1 to obtain a given voltage U1.
(29)
└ ┘ where represents rounding down operation, p1 is the resolution of the ADC, p2 is the resolution of the DAC, n is a positive integer, and n/D1≤σ, where σ= 1/10 or σ=½.
(30) The microprocessor outputs the given voltage digital quantity D1′ according to the above equation, so that an output voltage (that is, the given voltage U1) of the DAC is close to but slightly smaller than a to-be-measured voltage U.sub.S (that is, the single-ended voltage to ground U.sub.S of the to-be-measured resistor), thereby forming a slight difference to complete the high-precision resistance measurement.
(31) Step 2.3: Switch the second input terminal of the PGA from being connected to ground to being connected to the output terminal of the DAC by controlling the control terminal of the first analog switch I through the microprocessor.
(32) Step 2,4: The PGA differentially amplifies the single-ended voltage to ground U.sub.S and the given voltage U1 of the to-be-measured resistor by a factor of A2 to obtain a second voltage (U.sub.S−U1)*A2 the ADC performs analog-to-digital conversion on the obtained second voltage (U.sub.S−U1)*A2 to obtain a second voltage digital quantity D2, and the microprocessor reads the second voltage digital quantity D2 from the ADC.
(33) After step 2.2 and before step 2.4, the method further includes: controlling, by the microprocessor, the amplification factor of the PGA to A2.
(34) During setting of the amplification factor A1 of the PGA, the amplification factor is adjusted according to an advanced value of a gain level of the PGA, so that an analog-to-digital conversion result in step 2.1 that is, the first voltage digital quantity D1 does not overflow. In addition, in order to obtain more precise resistance measurement, the amplification factor A1 of the PGA is required to be as large as possible. Therefore, the amplification factor A1 further needs to satisfy: a most significant bit of the first voltage digital quantity D1 is 1 as far as possible (for a binary ADC). In other words, in this embodiment, the amplification factor A1 is adjusted according to an advanced value of a gain level of the PGA, and when the first voltage digital quantity D1 does not overflow, a larger amplification factor indicates a better effect, so that the conversion of the ADC has no overflow, the accuracy of the analog-to-digital conversion is ensured, and the precision of the resistance measurement is maximized.
(35) In addition, during setting of the amplification factor A2 of the PGA, according to the improvement of the accuracy of the measurement system, it is required that an increase in a resolution of a corresponding ADC conversion digital result does not exceed a resolution of the ADC (that is, does not exceed a resolution capability of the ADC). The amplification factor of the PGA is adjusted according to an advanced number (binary or decimal) of a gain level, and it is ensured that an output of the PGA does not exceed an input upper limit or the resolution of the ADC.
(36) Step 3: The microprocessor calculates a resistance value R.sub.S of the to-be-measured resistor according to the following equation:
R.sub.S=R.sub.N*A.sub.REF*(D1′*p2/p1+D2/A2)/D.sub.FS, where
where
(37) R.sub.N represents a resistance value of the reference resistor, A.sub.REF represents an amplification factor of the first differential amplifier, and D.sub.FS is the maximum conversion output numeric value of the ADC.
(38) The resistance value of the to-be-measured resistor R.sub.S is calculated h combining the ratiometric method and the micro-differential method. A calculation process is:
(39)
where
(40)
D.sub.FS is the maximum output numeric value of the ADC, D.sub.FS1 is the maximum input numeric value of the DAC, D.sub.FS1=1/p2, and D.sub.FS=1/p1.
(41) Step 4: Control the control terminal of the first analog switch I through the microprocessor, so that the second input terminal of the PGA is connected to ground. The control terminal of the second analog switch II and the control terminal of the third analog switch III of the third analog switch are controlled through the microprocessor, so that the output terminal of the first differential amplifier Amp1 is disconnected from the voltage reference terminals of the ADC and the DAC.
Embodiment II
(42) In Embodiment I, since one terminal of the to-be-measured resistor is grounded, a voltage of a common connection terminal for the to-be-measured resistor and the reference resistor is a single-ended voltage to ground corresponding to a voltage drop across the to-be-measured resistor, which may be directly inputted to the first input terminal of the PGA. Differences from Embodiment I lie in that, in Embodiment II, positions of the reference resistor and the to-be-measured resistor interface are transposed, and a second differential amplifier is disposed between the to-be-measured resistor and the PGA, as shown in
(43) In this embodiment, the measurement system of the present disclosure and the measurement method of the present disclosure adopt an ADC and a DAC both having 8 bits, that is, the two converters have the same resolution of 1/255. 8 groups of to-be-measured resistors having different resistance values are selected for measurement, and a simulation test is performed in a Proteus 7.8 software environment, where A1=2, A.sub.REF=10, and D.sub.FS=255 are set. Measured resistance values, error correction amounts caused by conversion of the DAC, correction values of the measured resistances, absolute errors of the measured values, relative errors, values of corresponding amplification gains A2 and digital quantities D1′, first voltage digital quantities D1, and second voltage digital quantities D2 are shown in Table 1 (in the table, n is sequentially taken as 3, 5, 6, 2, 9, 3, and 12).
(44) TABLE-US-00001 TABLE 1 Actual Measured Correction Correction Absolute Relative No. resistance/Ω resistance/Ω amount/Ω value/Ω error/Ω error/% A2 D1″ D1 D2 1 100 100.3370 0.3676 99.969 0.031 0.031 128 18H 33H CBH 2 150 150.5515 0.5515 150.000 0.000 0.000 64 24H 4DH 99H 3 200 200.7966 0.7353 200.061 0.061 0.031 64 30H 66H CDH 4 220 220.8333 0.8578 219.976 0.024 0.011 64 38H 70H 14H 5 240 240.9314 0.9181 240.013 0.013 0.005 64 3CH 7AH 5CH 6 300 301.1029 1 1029 300.000 0.000 0.000 32 48H 99H 99H 7 350 351.3480 1.3480 350.000 0.000 0.000 32 58H B3H 33H 8 400 401.4706 1.4706 400.000 0.000 0.000 32 60H CCH CCH
(45) In addition, a 10-bit DAC device TLC5615 is selected to replace the 8-bit DAC device MAX517 in Embodiment 1. Since the conversion voltage range of TLC5615 is 0˜2 times the reference voltage, considering that it cannot exceed the power supply voltage, the reference voltage is caused to be U.sub.REF/2 to perform the same test. Test results are shown in Table 2. It can be learned from Table 2 that a conversion result of the DAC does not need to be corrected. In order to distinguish between digital quantities corresponding to the 10-bit DAC and the 8-hit DAC herein, a digital quantity inputted by the CPU to the 10-bit DAC is denoted as D0, which is a digital quantity that is derived, in the same way as in the 8-bit DAC, by rounding a 10-bit result transformed from D1′=(D1−n)/A1(D0=└D1″*p1/p2┘=└D1″*1024/255┘), and R.sub.S=R.sub.N*A.sub.REF*(D0*p2/p1+D2/A2)/D.sub.FS, where p2/p1=255/1024≈1/4.
(46) It is learned from Table 1 and Table 2 that an average absolute error of the 8 test points is 0.016Ω, a maximum absolute error does not exceed 0.1Ω, an average relative error is 0.00975%, and a maximum relative error does not exceed 0.05%. It can be learned that the present disclosure can achieve high-precision resistance measurement and has a relatively excellent test effect.
(47) TABLE-US-00002 TABLE 2 Actual Measured Absolute Relative No. resistance/Ω resistance/Ω error/Ω effort/% A2 D1″ D0 D1 D2 1 100 99.969 0.031 0.031 128 18H 60H 33H CBH 2 150 150.000 0.000 0.000 64 24H 90H 4DH 99H 3 200 200.061 0.061 0.031 64 30H C0H 66H CDH 4 220 219.975 0.024 0.011 64 38H E0H 70H 14H 5 240 240.012 0.013 0.005 64 3CH F0H 7AH 5CH 6 300 300.000 0.000 0.000 32 48H 121H 99H 99H 7 350 350.000 0.000 0.000 32 58H 161H B3H 33H 8 400 400.000 0.000 0.000 32 60H 181H CCH CCH
(48) The above embodiments are exemplary embodiments of this application, and those of ordinary skill in the art may further make various changes or improvements on this basis without departing from the general concept of this application. These changes or improvements shall fall within the scope of protection claimed by this application,