Calibration method for integral nonlinearity of analog-to-digital converter of standard meter and analog-to-digital converter
By dividing the voltage range of the analog-to-digital converter into calibration intervals and calculating the calibration coefficient and offset for error correction, the problems of large computational complexity and high complexity in the existing technology are solved, and high-precision real-time calibration and full-range coverage are achieved.
Patent Information
- Application Number
- CN202510738410.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-04
- Publication Date
- 2025-09-19
AI Technical Summary
The existing technology has a large amount of calculation when calibrating the integral nonlinearity of the analog-to-digital converter, which makes it difficult to meet the real-time calibration requirements. In addition, the hardware optimization method is costly and the software correction method is complex.
The voltage range of the analog-to-digital converter is divided into several calibration intervals. The calibration coefficient and offset are calculated by collecting the measured code value and the ideal code value. The error is corrected using the linear relationship and stored in the calibration register.
It achieves high-precision integral nonlinearity calibration with low computational complexity, is suitable for real-time calibration of standard meters, and covers the full range.
Smart Images

Figure CN120675561A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to a calibration method for integral nonlinearity of an analog-to-digital converter of a standard table and an analog-to-digital converter, belonging to the field of calibration of analog-to-digital converters. Background Art
[0002] In modern electricity metering equipment, the ADC (Analog-to-Digital Converter) is a key component, and its performance directly impacts the accuracy and stability of measurement. However, in practical applications, ADCs are subject to integral nonlinearity (INL) errors, resulting in deviations between measured and ideal values. This error can significantly reduce measurement reliability, particularly in scenarios requiring high precision. ADC integral nonlinearity refers to the deviation between the actual converted output and the ideal linear output, typically manifesting as an inconsistency in the width of the quantization interval. Currently, some high-end ADCs are reducing INL errors through hardware design improvements, such as optimizing the internal capacitor array and calibration algorithms. However, such methods are often costly and difficult to completely eliminate in mass production. For standard meter applications, software-based calibration techniques are commonly used to compensate for ADC nonlinearity through subsequent digital processing. However, existing software calibration methods, which are mostly based on polynomial fitting or interpolation algorithms, have high computational complexity and are difficult to meet real-time calibration requirements. Current ADC integral nonlinearity (INL) calibration techniques primarily include the following:
[0003] 1. Hardware optimization method: Reduce integral nonlinearity error by improving the internal hardware design of the ADC. Common methods include:
[0004] 1) Optimize capacitor arrays: Reduce nonlinear errors caused by mismatch by improving capacitor matching accuracy.
[0005] 2) Internal correction circuit: A dedicated correction circuit is added inside the ADC to compensate for nonlinearity in real time.
[0006] 2. Software correction method: Compensate for the ADC's integral nonlinearity error through subsequent digital processing. The main algorithms include:
[0007] 1) Polynomial fitting: The calibration curve is fitted using sampling points, which is suitable for small-scale error correction.
[0008] 2) Segmented interpolation: Divide the measuring range into multiple intervals and correct the error in each segment through interpolation calculation.
[0009] The existing technology mainly has the following defects:
[0010] Hardware optimization method: increases circuit complexity and cost, and has limited effect in high-precision measurements.
[0011] Software correction method: requires complex algorithms and a lot of computing resources. Summary of the Invention
[0012] The object of the present invention is to provide a calibration method for the integral nonlinearity of a standard table analog-to-digital converter and an analog-to-digital converter, so as to solve the problem of large amount of calculation when calibrating the ADC.
[0013] To achieve the above object, the solution of the present invention includes:
[0014] The present invention provides a calibration method for the integral nonlinearity of a standard meter analog-to-digital converter, comprising the following steps: 1) dividing the voltage range of the analog-to-digital converter to be calibrated into a plurality of calibration intervals, each calibration interval including at least two corresponding voltage values; 2) acquiring corresponding measurement code values obtained by converting an analog signal through the analog-to-digital converter, wherein the analog signal is obtained according to the voltage value in each calibration interval; 3) obtaining a calibration coefficient and an offset for each calibration interval according to two measurement code values and two ideal code values arbitrarily selected within each calibration interval, wherein the measurement code value and the ideal code value are in a linear relationship with the calibration coefficient as the slope and the offset as the intercept, wherein the two ideal code values correspond to code values in an ideal state obtained by converting two voltage values corresponding to the two selected measurement code values through the ideal analog-to-digital converter, and the calibration coefficient and the offset are used to correct the integral nonlinearity error of the analog-to-digital converter.
[0015] Furthermore, in step 2), the process of collecting each measurement code value includes: inputting the voltage value into the analog-to-digital converter to be calibrated and continuously inputting the set time to obtain multiple conversion code values corresponding to the voltage value, and taking the average value of the multiple conversion code values as the measurement code value corresponding to the voltage value.
[0016] Furthermore, the calculated calibration coefficient and offset are stored in a calibration register of the analog-to-digital converter to be calibrated, so as to perform error correction on the analog-to-digital converter to be calibrated.
[0017] Furthermore, the linear relationship is:
[0018] M ideal [k]=K*M average [k]+Β
[0019] Among them, M ideal is the ideal code value, M average is the measurement code value, k is the voltage value, K is the calibration coefficient, and B is the offset.
[0020] An analog-to-digital converter performs integral nonlinearity error correction based on a calibration coefficient and an offset; the calibration coefficient and the offset are obtained by the following steps: 1) dividing the voltage range of the analog-to-digital converter into a plurality of calibration intervals, each calibration interval including at least two corresponding voltage values; 2) acquiring analog signals and converting them into corresponding measurement code values through the analog-to-digital converter, wherein the analog signals are obtained corresponding to the voltage values in each calibration interval; 3) obtaining the calibration coefficient and the offset of each calibration interval based on two arbitrarily selected measurement code values and two ideal code values in each calibration interval, wherein the measurement code values and the ideal code values are in a linear relationship with the calibration coefficient as the slope and the offset as the intercept, and the two ideal code values respectively correspond to code values in an ideal state obtained by converting two voltage values corresponding to the two selected measurement code values through the ideal analog-to-digital converter.
[0021] Furthermore, in step 2), the process of collecting each measurement code value includes: inputting the voltage value into the analog-to-digital converter to be calibrated and continuously inputting the set time to obtain multiple conversion code values corresponding to the voltage value, and taking the average value of the multiple conversion code values as the measurement code value corresponding to the voltage value.
[0022] Furthermore, the calibration coefficient and the offset are stored in a calibration register of the analog-to-digital converter to perform error correction of the analog-to-digital converter.
[0023] Furthermore, the linear relationship is:
[0024] M ideal [k]=K*M average [k]+Β
[0025] Where Mideal is the ideal code value, Mapaverage is the measured code value, k is the voltage value, K is the calibration coefficient, and B is the offset.
[0026] The beneficial effects of the present invention are as follows: the present invention is a pioneering invention. The present invention first divides the voltage range of the analog-to-digital converter to be calibrated into a plurality of calibration intervals including at least two corresponding voltage values; then, the analog signal corresponding to the voltage value within each calibration interval is input into the analog-to-digital converter to be calibrated to obtain the corresponding measurement code value; finally, based on two arbitrarily selected measurement code values, two ideal code values, and the linear relationship between the measured code value and the ideal code value in each calibration interval, a calibration coefficient and offset for correcting integral nonlinearity error are obtained for each calibration interval. The present invention calibrates the analog-to-digital converter to be calibrated interval by interval, achieving high correction accuracy while reducing computational complexity and achieving full range coverage. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] Figure 1 It is a schematic diagram of a correction architecture of the present invention;
[0028] Figure 2 It is a correction process diagram of the present invention. DETAILED DESCRIPTION
[0029] In order to make the objectives, technical solutions and advantages of the present invention more clear, the present invention is further described in detail below with reference to the accompanying drawings and implementation methods.
[0030] The idea of the present invention is to divide the entire measuring range of the analog-to-digital converter into several calibration intervals, and then apply the analog signal corresponding to the calibration interval to the analog-to-digital converter, so as to calculate the calibration coefficient and offset of each calibration interval based on the measurement code value obtained by converting the analog signal.
[0031] Method implementation method:
[0032] This embodiment provides a calibration method for the integral nonlinearity of a standard analog-to-digital converter, such as Figure 1 As shown, it includes: ADC module: ADC module of the standard meter to be tested; precision signal source: providing high-stability analog input signal; host computer system: used for data acquisition, processing and calibration operations.
[0033] like Figure 2 As shown, the following steps are included:
[0034] S1. Range division: Divide the full-scale range (voltage range) of the ADC to be calibrated into N segments, with each segment serving as an independent calibration interval.
[0035] S2. Data acquisition: The precision signal source is used to input the corresponding conversion battery T[k] (analog signal) into the analog-to-digital converter according to the corresponding voltage value in each calibration interval. The code value of the analog signal after conversion by the analog-to-digital converter to be calibrated is collected, and then the measurement code value corresponding to the corresponding voltage value in each calibration interval is recorded based on these code values. As a specific embodiment of the present invention, after the precision signal source has been input stably for a period of time, the code value after ADC conversion for a certain voltage value is read for 10 minutes, and then the average value M of the code value for 10 minutes is calculated. average [k], and the average value is used as the measurement code value. The measurement code values collected for the voltage value in each calibration interval are at least 2.
[0036] Let's use a specific example to illustrate the process of step S2: The calibration interval of an ADC to be calibrated is [0, 2.5V]. To collect the code value of a 2V voltage within this calibration interval after ADC conversion, the precision signal source is controlled to input a 2V voltage signal (analog signal) into the ADC for 10 minutes. The host computer then reads multiple code values corresponding to 2V within 10 minutes and then uses the average of these code values as the measured code value of 2V within the calibration interval [0, 2.5V]. The same process is applied to voltage values within other calibration intervals.
[0037] S3. Calculation of segment calibration coefficients:
[0038] 1) Analyze the data collected in each calibration interval and set the ideal code value M for the voltage value corresponding to the measurement pressure collected in each calibration interval. ideal [k], the ideal code value represents the code value corresponding to the voltage value of k input to the ADC in the ideal state, M average [k] is the measurement code value converted when the voltage value k is input to the ADC in a normal state.
[0039] 2) The past code values within each calibration interval have the following relationship:
[0040] M ideal [k]=K*M average [k]+Β (1)
[0041] Where K is the calibration coefficient and B is the offset.
[0042] 3) Calculate the calibration coefficient and offset in each calibration interval using the two-point method:
[0043]
[0044] S4. Calibration coefficient writing: The calibration coefficient and offset of each calibration interval are stored in the calibration register of the ADC module to achieve integral nonlinearity calibration of the full range.
[0045] S5. Verification of calibration results: The ADC output code value after calibration is collected again by the host computer to verify the calibration accuracy.
[0046] Analog to Digital Converter Implementation:
[0047] This embodiment provides an analog-to-digital converter. When performing integral nonlinearity error correction, the analog-to-digital converter adopts the method described in the method embodiment. Since the introduction of this method is clear enough, it will not be repeated here.
[0048] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to the above embodiments, ordinary technicians in the field should understand that the specific embodiments of the present invention can still be modified or replaced by equivalents. Any modification or equivalent replacement that does not depart from the spirit and scope of the present invention should be covered by the scope of protection of the claims of the present invention.
Claims
1. A method for calibrating the integral nonlinearity of a standard meter analog-to-digital converter, characterized in that: The method comprises the following steps: 1) dividing the voltage range of the analog-to-digital converter to be calibrated into a plurality of calibration intervals, each calibration interval including at least two corresponding voltage values; 2) collecting analog signals and converting them into corresponding measurement code values through the analog-to-digital converter, where the analog signals are obtained according to the voltage values within each calibration interval; 3) A calibration coefficient and an offset are obtained for each calibration interval based on two randomly selected measurement code values and two ideal code values within each calibration interval. The measurement code value and the ideal code value have a linear relationship with the calibration coefficient as the slope and the offset as the intercept. The two ideal code values correspond to the code values under the ideal state obtained by converting the two voltage values corresponding to the two selected measurement code values through an ideal analog-to-digital converter. The calibration coefficient and the offset are used to correct the integral nonlinearity error of the analog-to-digital converter.
2. The method for calibrating integral nonlinearity of a standard meter analog-to-digital converter according to claim 1, wherein: In step 2), the process of collecting each measurement code value includes: inputting the voltage value into the analog-to-digital converter to be calibrated and continuously inputting the set time to obtain multiple conversion code values corresponding to the voltage value, and taking the average value of the multiple conversion code values as the measurement code value corresponding to the voltage value.
3. The method for calibrating integral nonlinearity of a standard meter analog-to-digital converter according to claim 1, wherein: The calculated calibration coefficient and offset are also stored in the calibration register of the analog-to-digital converter to be calibrated, so as to perform error correction on the analog-to-digital converter to be calibrated.
4. The method for calibrating integral nonlinearity of a standard meter analog-to-digital converter according to claim 1, wherein: The linear relationship is: M ideal [k]=K*M average [k]+Β Among them, M ideal is the ideal code value, M average is the measurement code value, k is the voltage value, K is the calibration coefficient, and B is the offset.
5. An analog-to-digital converter, characterized in that The analog-to-digital converter performs integral nonlinearity error correction based on a calibration coefficient and an offset; the calibration coefficient and the offset are obtained by the following steps: 1) dividing the voltage range of the analog-to-digital converter into a plurality of calibration intervals, each calibration interval including at least two corresponding voltage values; 2) collecting analog signals and converting them into corresponding measurement code values through the analog-to-digital converter, where the analog signals are obtained according to the voltage values within each calibration interval; 3) A calibration coefficient and an offset are obtained for each calibration interval based on two randomly selected measurement code values and two ideal code values within each calibration interval. A linear relationship is present between the measurement code value and the ideal code value, with the calibration coefficient as the slope and the offset as the intercept. The two ideal code values correspond to the code values under the ideal state obtained by converting the two voltage values corresponding to the two selected measurement code values through an ideal analog-to-digital converter.
6. The analog-to-digital converter according to claim 5, wherein: In step 2), the process of collecting each measurement code value includes: inputting the voltage value into the analog-to-digital converter to be calibrated and continuously inputting the set time to obtain multiple conversion code values corresponding to the voltage value, and taking the average value of the multiple conversion code values as the measurement code value corresponding to the voltage value.
7. The analog-to-digital converter according to claim 5, wherein: The calibration coefficient and the offset are stored in the calibration register of the analog-to-digital converter to perform error correction of the analog-to-digital converter.
8. The analog-to-digital converter according to claim 5, wherein: The linear relationship is: M ideal [k]=K*M average [k]+Β Among them, M ideal is the ideal code value, M average is the measurement code value, k is the voltage value, K is the calibration coefficient, and B is the offset.