Current-to-frequency conversion circuit scaling factor and zero offset compensation method and apparatus
By using a software model to perform zero-point and scaling factor temperature compensation for current-frequency conversion circuits, the cumbersome hardware compensation problem in existing technologies is solved, improving production efficiency and convenience, and realizing circuit flexibility and resource versatility.
Patent Information
- Application Number
- CN202211386496.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-11-07
- Publication Date
- 2025-12-19
- Estimated Expiration
- 2042-11-07
AI Technical Summary
In the existing technology, the scaling factor and zero-point compensation steps of the current-to-frequency conversion circuit are cumbersome, resulting in low production efficiency and a complicated and inconvenient hardware compensation process.
The software model uses temperature calibration data to perform temperature compensation on the circuit's collected count values. This includes reading pre-stored compensation parameters, obtaining the current temperature, performing linear difference fitting, and compensating for zero point and scaling factor within one sampling period.
It improves the production efficiency and convenience of current-to-frequency conversion circuits, eliminates the process of soldering and adjusting resistors, and has the versatility of hardware and software resources.
Smart Images

Figure CN115752450B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application relates to a software compensation method for scale factor and zero of a current-frequency conversion circuit, and belongs to the field of analog-digital hybrid circuits. BACKGROUND
[0002] In an inertial navigation system, a current-frequency conversion circuit converts an output current of an accelerometer to generate a digital pulse signal corresponding to the current value, and a count value of the digital pulse signal can be used to calculate an acceleration value corresponding to the output current of the accelerometer and participate in navigation algorithm processing. Due to the temperature characteristics of components in the circuit, the performance of the conversion circuit for current-frequency conversion is different at different temperatures. The ratio of the output frequency of the conversion circuit to the input current is called the scale factor, and the output frequency of the conversion circuit when the input current is 0 is called the zero. The scale factor and the zero are both affected by the temperature of the circuit, and therefore it is necessary to compensate the scale factor and the zero to improve the performance of the conversion circuit.
[0003] The prior art usually relies on hardware compensation of the circuit. First, the zero is debugged, a zero debugging resistor is welded, and test verification is performed, and then the scale factor is debugged, a scale factor debugging resistor is welded, and test verification is performed. The overall compensation steps are complicated, and the production efficiency is low. The software compensation method can obtain compensation parameters through one-time debugging, and eliminates the process of welding the debugging resistor, thereby improving the convenience of using the circuit and improving the production efficiency. SUMMARY
[0004] In view of the problem that the hardware compensation debugging steps are complicated, the application aims to provide a scale factor and zero compensation method and device for a current-frequency conversion circuit, which compensates the count value of the circuit by using temperature calibration data through a software model.
[0005] To solve the above problems, the scale factor and zero compensation method for the current-frequency conversion circuit provided by the application adopts the technical scheme comprising the following steps:
[0006] 1) reading compensation parameters of a to-be-compensated circuit, including temperature points, zeros, scale factors, and target values of the scale factors at the temperature points, which are stored in advance;
[0007] 2) obtaining the temperature of the to-be-compensated circuit;
[0008] 3) judging the temperature interval in the compensation parameters according to the current temperature, and performing linear difference fitting on the zero and the scale factor corresponding to the current temperature by using the zeros and the scale factors corresponding to the two endpoints of the interval in which the current temperature is located;
[0009] 4) compensating the count value of the to-be-compensated circuit in one sampling period by using the target value of the scale factor, the fitted zero, and the scale factor.
[0010] According to another aspect of the present application, a current-frequency conversion circuit scale factor and zero position compensation device is provided, and the technical scheme is as follows:
[0011] The compensation device comprises a memory, a temperature sensor and a processor.
[0012] The memory is used for pre-storing compensation parameters of the circuit to be compensated, including temperature points and zero positions, scale factors and scale factor target values of the temperature points.
[0013] The temperature sensor is used for collecting the current temperature of the circuit to be compensated.
[0014] The processor reads the pre-stored compensation parameters in the memory through a hardware interface, acquires the current temperature of the circuit to be compensated through the temperature sensor, judges the temperature interval in the compensation parameters according to the current temperature, performs linear difference fitting on the zero position and the scale factor corresponding to the current temperature by using the zero position and the scale factor parameters corresponding to the two endpoints of the interval in which the current temperature point is located, and simultaneously performs temperature compensation on the zero position and the scale factor of the current circuit to be compensated in one sampling period.
[0015] The present application directly performs zero position and scale factor temperature compensation on the count value of the conversion circuit through software, eliminates the process of welding and debugging the resistance, improves the convenience and flexibility of the conversion circuit, improves the production efficiency, and is more convenient than the hardware compensation debugging process, and the circuit hardware and software resources used in the present application are universal. BRIEF DESCRIPTION OF DRAWINGS
[0016] The accompanying drawings, which constitute a part of the specification, illustrate embodiments of the present application and serve to explain the principles of the present application together with the text. Obviously, the drawings below only show some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative effort on the basis of these drawings.
[0017] Figure 1 Fig. 1 shows a principle schematic diagram of a current-frequency conversion circuit scale factor and zero position compensation device provided by a specific embodiment of the present application;
[0018] Figure 2 Fig. 2 shows a linear interpolation schematic diagram of a zero position and a scale factor provided by a specific embodiment of the present application. DETAILED DESCRIPTION
[0019] It should be noted that the embodiments and features of the embodiments in the present application can be combined with each other in the case of no conflict. The technical solutions in the embodiments of the present application will be described clearly and completely in combination with the drawings of the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. The description of the at least one exemplary embodiment is actually only illustrative, but not as any limitation on the present application and its application or use. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor are within the protection scope of the present application.
[0020] The current-frequency conversion circuit scale factor and zero compensation method provided by the embodiments of the present application comprises the following steps:
[0021] Step S1. The uncompensated circuit is tested at a selected temperature point, and the compensation parameters are stored, specifically as follows:
[0022] 1) The zero of each temperature point of the to-be-compensated circuit is obtained by testing;
[0023] 2) The scale factor of each temperature point of the to-be-compensated circuit is obtained by testing;
[0024] 3) Each temperature point and the zero and scale factor of each temperature point are stored;
[0025] 4) The target value of the scale factor of each temperature point is stored.
[0026] Step S2. The stored compensation parameters are used for compensation processing when the circuit works, specifically as follows:
[0027] 1) The pre-stored compensation parameters are read;
[0028] 2) The current temperature of the to-be-compensated circuit is obtained;
[0029] 3) The temperature point interval in the compensation parameters is judged according to the current temperature, and the zero and scale factor corresponding to the two endpoints of the interval where the current temperature is located are used for linear difference fitting of the zero and scale factor corresponding to the current temperature, as shown in the following formula: Figure 2
[0030] 4) The scale factor target value, the fitted zero, and the scale factor are used to compensate the current to-be-compensated circuit count value in a sampling period.
[0031] Further, the zero and scale factor are simultaneously temperature-compensated in a sampling period, and the formula is as follows:
[0032]
[0033]
[0034] F L represents the compensation result of the count value in the current sampling period, F + represents the positive count value counted in one sampling period, F - represents the negative count value counted in one sampling period, K m represents the scale factor target value, f s represents the frequency corresponding to one sampling period. K L + represents the positive scale factor of the current temperature point calculated by the linear interpolation method, K L - represents the negative scale factor of the current temperature calculated by the linear interpolation method. Z L represents the zero of the current temperature calculated by the linear interpolation method. Due to the circuit characteristics, there is only one value of the zero at a certain temperature point, so when Z L ≥ 0, Z L + = Z L , Z L - = 0, when Z L < 0, Z L + = 0, Z L - = Z L .
[0035] Based on the same idea, according to another aspect of the present application, a current-frequency conversion circuit scale factor and zero compensation device is provided.
[0036] The current-frequency conversion circuit scale factor and zero compensation device provided by the present application is described below, and the current-frequency conversion circuit scale factor and zero compensation device described below can be mutually corresponding to the current-frequency conversion circuit scale factor and zero compensation method described above.
[0037] As Figure 1 shown, in an exemplary embodiment of the present application, the current-frequency conversion circuit scale factor and zero compensation device includes a memory, a temperature sensor, and a processor.
[0038] The memory is used to pre-store compensation parameters of the circuit to be compensated, including temperature points, zero, scale factor, and scale factor target value of each temperature point.
[0039] The temperature sensor is used to collect the current temperature of the circuit to be compensated.
[0040] The processor reads the pre-stored compensation parameters in the memory through the hardware interface, acquires the current temperature of the circuit to be compensated through the temperature sensor, judges the temperature interval in the compensation parameters according to the current temperature, performs linear difference fitting on the zero and the scale factor corresponding to the current temperature by using the zero and the scale factor parameters corresponding to the two ends of the interval in which the current temperature is located, and performs temperature compensation on the zero and the scale factor corresponding to the current temperature in one sampling period, as shown in the following formula: Figure 2
[0041] Further, the zero and the scale factor are simultaneously compensated in one sampling period, and the formula is as follows:
[0042]
[0043]
[0044] Wherein, F L represents the compensation result of the count value in the current sampling period, F + represents the positive count value counted in one sampling period, F - represents the negative count value counted in one sampling period, K m represents the scale factor target value, f s represents the frequency corresponding to one sampling period. K L + represents the positive scale factor of the current temperature point calculated by the linear interpolation method, K L - represents the negative scale factor of the current temperature calculated by the linear interpolation method. Z L represents the zero of the current temperature calculated by the linear interpolation method. Since the circuit characteristics, the zero has only one value at a certain temperature point, therefore, when Z L ≥0, Z L + =Z L , Z L - =0, when Z L <0, Z L + =0, Z L - =Z L .
[0045] It should be pointed out finally that the above embodiments are only used to illustrate the technical solutions of the present application, but not to limit the same; and although the present application has been described in detail with reference to the foregoing embodiments, it should be appreciated by those skilled in the art that the technical solutions recorded in the foregoing embodiments can be modified, or some technical features thereof can be replaced equivalently; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A current-to-frequency conversion circuit scale factor and zero offset compensation method, characterized by, The method comprises the following steps: 1) reading pre-stored compensation parameters of the circuit to be compensated, including temperature points and zero position, scale factor, scale factor target value of each temperature point; 2) obtaining the current temperature of the circuit to be compensated; 3) judging the temperature interval in the compensation parameters according to the current temperature, and performing linear difference fitting on the zero position and scale factor corresponding to the current temperature by using the zero position and scale factor parameters corresponding to the two endpoints of the temperature interval; 4) compensating the current count value of the circuit to be compensated in a sampling period by using the scale factor target value, the fitted zero position and scale factor, and simultaneously compensating the zero position and scale factor in a sampling period, and the formula is as follows: Wherein, F L represents the compensation result of the count value in the current sampling period, F + represents the positive count value counted in one sampling period, F - represents the negative count value counted in one sampling period, K m represents the scale factor target value, f s represents the frequency corresponding to one sampling period, K L + represents the positive scale factor of the current temperature point calculated by linear interpolation, K L - represents the negative scale factor of the current temperature calculated by linear interpolation, Z L represents the zero position of the current temperature calculated by linear interpolation, when Z L ≥0, Z L + =Z L , Z L - =0, when Z L <0, Z L + =0, Z L - =Z L .
2. A current-to-frequency conversion circuit scaling factor and zero offset compensation device, characterized by, The memory is used for pre-storing compensation parameters of the circuit to be compensated, including temperature points and zero position, scale factor, scale factor target value of each temperature point; The temperature sensor is used for collecting the current temperature of the circuit to be compensated; The processor reads the pre-stored compensation parameters in the memory through the hardware interface, obtains the current temperature of the circuit to be compensated through the temperature sensor, judges the temperature interval in the compensation parameters according to the current temperature, performs linear difference fitting on the zero position and scale factor corresponding to the current temperature by using the zero position and scale factor parameters corresponding to the two endpoints of the temperature interval, simultaneously compensates the zero position and scale factor of the current circuit to be compensated in a sampling period, and simultaneously compensates the zero position and scale factor in a sampling period, and the formula is as follows: F L represents the compensation result of the count value in the current sampling period, F + represents the positive count value counted in one sampling period, F - represents the negative count value counted in one sampling period, K m represents the scale factor target value, f s represents the frequency corresponding to one sampling period, K L + represents the positive scale factor of the current temperature calculated by the linear interpolation method, K L - represents the negative scale factor of the current temperature calculated by the linear interpolation method, Z L represents the zero position of the current temperature calculated by the linear interpolation method, when Z L ≥ 0, Z L + = Z L , Z L - = 0, when Z L < 0, Z L + = 0, Z L - = Z L .
Citation Information
Patent Citations
Fusion compensation method
CN105571590A