Digital closed-loop self-calibration compensation circuit of magnetic sensor
By designing a digital closed-loop self-calibration compensation circuit of magnetic sensors, using the reference magnetic field and Hall sensitivity self-calibration loop, real-time closed-loop compensation for temperature and stress is achieved, which solves the problem of difficult to achieve high-precision temperature drift and stress calibration in the prior art, and significantly improves the calibration accuracy and anti-interference performance of magnetic sensors.
Patent Information
- Application Number
- CN202411826722.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-12
- Publication Date
- 2025-03-11
AI Technical Summary
Existing magnetic sensor compensation technology is difficult to achieve high-precision temperature drift and stress calibration, especially cannot meet the 0.5% temperature drift requirement of high-end products. At the same time, there is a problem of insufficient or excessive temperature zone division.
A digital closed-loop self-calibration compensation circuit of magnetic sensor is designed, and real-time closed-loop compensation for temperature and stress is achieved through the reference magnetic field generation module and Hall sensitivity self-calibration loop. The circuit includes a reference magnetic field generation module and a Hall sensitivity self-calibration loop, which uses metal coils to generate a reference magnetic field that is not affected by temperature and stress, and adjusts the bias voltage of the Hall disk in real time to adjust its sensitivity.
It achieves higher calibration accuracy, can calibrate temperature and stress at the same time, significantly optimizes the anti-interference performance of the magnetic sensor, time drift and stress, and especially improves the accuracy of the temperature drift performance.
Smart Images

Figure CN119596212A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of high-precision magnetic sensor compensation, and in particular to a digital closed-loop self-calibration compensation circuit for a magnetic sensor. Background Art
[0002] The temperature drift performance of magnetic sensors is particularly critical, because the application environment requires the output sensitivity of magnetic sensors to be within a certain deviation range at -40 to 150°C. Generally, 25°C is used as the benchmark, and the output sensitivity at each temperature is required to deviate by no more than 3% relative to the sensitivity at 25°C. High-end products can already achieve a temperature drift performance of 0.5%.
[0003] Take the Hall sensor as an example. Under the same bias, the Hall sensor itself will output different Hall signals at different temperatures. We hope that the ideal sensor will have equal output signals at different operating temperatures. However, the temperature drift of the Hall sensor itself may be as large as 10%, which is completely unable to meet the application requirements. Therefore, a signal processing circuit is needed to compensate for this deviation.
[0004] Common Hall sensor compensation schemes are as follows:
[0005] Existing Solution 1: By adjusting the gain of the signal processing circuit, when the sensitivity of the Hall disk decreases due to temperature, the gain of the signal processing circuit at that temperature is increased. For example, directly controlling the gain of the adjustable gain OPA of the signal chain, or the gain of the output stage AMP. It is also possible to add a resistive load with the same structure as the Hall disk to the op amp to achieve temperature compensation, or to give the signal chain circuit a bias current with a certain temperature coefficient. However, the existing solution 1 has the following disadvantages: the temperature drift coefficient is difficult to accurately match, and multiple tape-outs are required to obtain test data to correct the temperature drift coefficient of the circuit gain. Although the trim bit can be increased to reduce the tape-out cost, there are usually only one or two temperature compensation points, and the compensation accuracy is very poor.
[0006] Existing solution 2: Temperature interpolation compensation solution, such as Figure 1As shown, a temperature sensor is designed inside the chip, and the working environment temperature of the chip (such as -50 to 150°C) is divided into fixed temperature zones (such as 8 temperature zones, -50°C, -25°C, 0°C, 25°C, 50°C, 75°C, 100°C, 125°C, and 150°C). After the tape-out is completed, the temperature coefficient of the chip is tested (during the test, only the temperature offset coefficient of the corresponding temperature point is tested), and the corresponding compensation coefficient is written into the internal memory of the chip. When the operating temperature of the chip is 60°C, the temperature sensor first detects the ambient temperature and outputs it to the chip temperature coefficient processing unit, and the compensation coefficient corresponding to 60°C is obtained through a linear interpolation algorithm (60°C is between 50°C and 75°C, the temperature compensation coefficients of 50°C and 75°C are written externally, and the temperature offset between 50°C and 75°C is regarded as linear, and the temperature compensation coefficient of 60°C can be calculated using a linear formula). The compensation coefficient is then converted into the size of the gain-adjustable OPA or Hall plate bias unit of the corresponding codeword control signal chain processing unit to achieve the final temperature compensation. However, the prior art solution 2 has the following disadvantages: an additional temperature sensor is required. In addition, too few temperature zones will result in insufficient compensation accuracy, and too many temperature zones will result in resource consumption. Moreover, if the temperature changes too much within the temperature zone, this method cannot achieve correct calibration.
[0007] Therefore, the development process of the prior art is summarized as follows: Initially, the magnetic sensor achieved temperature compensation through circuit design. For example, when the temperature coefficient of the Hall disk is known, the circuit is designed with the opposite temperature coefficient to achieve temperature compensation. This method cannot modify the degree of compensation after tape-out, and it is difficult to achieve accurate temperature compensation. The compensation change can only be achieved through repeated tape-outs, which is too time-consuming and costly. A calibrated interpolation temperature compensation method has gradually developed. Although it can save tape-out time and costs and improve the temperature drift compensation effect. However, the temperature drift performance can only meet the needs of mid- and low-end products, and cannot meet the 0.5% temperature drift requirement of high-end products. And there is a possibility of compensation failure in some special cases, such as Figure 2 The temperature form changes suddenly. For example, the temperature curve of the Hall plate itself is very irregular, and it is a non-linear curve in the pre-planned temperature range. For example, within 50℃~75℃, it is a parabola shape that first rises and then falls. Figure 4 As shown, the upward point cannot obtain an accurate compensation coefficient through the linear interpolation algorithm. Because the temperature range inside the chip is fixed at 50℃ and 75℃, the range between the two temperature points cannot be refined. Therefore, the temperature compensation coefficient -sens_drift1 obtained by simple linear interpolation cannot truly compensate for the temperature offset at 60℃, because the actual temperature offset at 60℃ is sens_drift2.
[0008] Moreover, temperature interpolation compensation requires additional temperature sensors. Too few temperature zones will result in insufficient compensation accuracy, while too many temperature zones will lead to resource consumption. In addition, existing magnetic sensor compensation solutions can only compensate for temperature coefficients. In product applications, in addition to temperature, stress also affects sensor sensitivity. For example, package stress. For the same chip, the sensitivity coefficient of the sensor will show different trends under different package structures. As time goes by, water vapor and other factors will also affect the package, which will be converted into stress effects. However, the existing solutions do not consider stress effects. Summary of the invention
[0009] The present invention aims to provide a digital closed-loop self-calibration compensation circuit for a magnetic sensor, wherein the chip can automatically adjust the sensitivity according to the influence of temperature and stress. The present invention can achieve higher calibration accuracy and can simultaneously calibrate temperature and stress.
[0010] The present invention is achieved through the following technical solutions:
[0011] A digital closed-loop self-calibration compensation circuit for a magnetic sensor, the circuit comprising:
[0012] A reference magnetic field generation module is used to generate a reference magnetic field through a metal coil, and the reference magnetic field is not affected by temperature and stress, and serves as a standard for calibrating the Hall sensitivity self-calibration loop;
[0013] The Hall sensitivity self-calibration loop is used to adjust the bias voltage of the magnetic sensor in real time according to the change in the output voltage of the magnetic sensor caused by the reference magnetic field, so as to adjust the sensitivity of the magnetic sensor; and demodulate the output signal of the reference magnetic field on the magnetic sensor from all the output signals of the magnetic sensors through a demodulation extraction circuit.
[0014] Further, the reference magnetic field generation module includes a current source, a switch modulation circuit C and a metal coil;
[0015] The first end Ip and the second end In of the current source are both connected to the input end of the switch modulation circuit C, and the first end Lp and the second end Ln of the metal coil are both connected to the output end of the switch modulation circuit C.
[0016] Furthermore, the switch modulation circuit C is controlled by the first clock signal ckcoil, and the control logic includes:
[0017] When the first clock signal ckcoil is at a high level, the first end Ip of the current source is connected to the first end Lp of the metal coil, and the second end In of the current source is connected to the second end Ln of the metal coil;
[0018] When the first clock signal ckcoil is at a low level, the first end Ip of the current source is connected to the second end Ln of the metal coil, and the second end In of the current source is connected to the first end Lp of the metal coil.
[0019] Furthermore, the magnetic sensor adopts a Hall plate, a TMR sensor or an AMR sensor.
[0020] Further, the Hall sensitivity self-calibration loop includes a low-dropout linear regulator, a first switch modulation circuit A, a Hall disk, a second switch modulation circuit B, a preamplifier, a demodulation extraction circuit, an analog-to-digital converter, and a digital signal processor;
[0021] A low-dropout linear regulator to provide a stable power supply to the Hall plate;
[0022] A first switch modulation circuit A and a second switch modulation circuit B are used to output a differential signal corresponding to the control Hall disk to a pre-amplifier;
[0023] A pre-amplifier, used to amplify the analog voltage signal output by the Hall disk and output it to the demodulation extraction circuit;
[0024] The demodulation extraction circuit is used to extract the output analog voltage signal on the Hall disk caused by the reference magnetic field generated by the metal coil from the analog voltage signal output by the Hall disk caused by the external magnetic field Bext; and only transmit the output analog voltage signal corresponding to the reference magnetic field to the analog-to-digital converter, and filter out the output voltage signal corresponding to the external magnetic field Bext;
[0025] An analog-to-digital converter, used for converting the analog voltage signal output by the reference magnetic field acting on the Hall disk into a digital voltage signal;
[0026] The digital signal processor is used to filter, accelerate and reduce noise on the digital voltage signal output by the reference magnetic field, and output a signal to control the bias signal of the Hall disk to achieve control of the sensitivity of the Hall disk.
[0027] Furthermore, the low voltage difference linear regulator is connected to the first switch modulation circuit A, the first switch modulation circuit A is connected to the Hall disk, the Hall disk is connected to the second switch modulation circuit B, the first switch modulation circuit A is also connected to the second switch modulation circuit B, the second switch modulation circuit B is connected to the input end of the pre-amplifier, the output end of the pre-amplifier is connected to the demodulation extraction circuit, the demodulation extraction circuit is connected to the analog-to-digital converter, the analog-to-digital converter is connected to the digital signal processor, and the digital signal processor is connected to the low voltage difference linear regulator.
[0028] Furthermore, the Hall plate is modulated by the first switch modulation A and the second switch modulation B controlled by the second clock signal ckhall, and the control logic includes:
[0029] When the second clock signal ckhall is at a high level, the h2 terminal of the Hall disk is connected to a low voltage difference linear regulator, the h4 terminal is grounded, and the differential signal between the h1 terminal and the h3 terminal is output to the pre-amplifier;
[0030] When the second clock signal ckhall is at a low level, the h1 terminal of the Hall disk is connected to the low voltage difference linear regulator, the h3 terminal is grounded, and the differential signal between the h2 terminal and the h4 terminal is output to the pre-amplifier.
[0031] Furthermore, the closed-loop control process of the Hall sensitivity self-calibration loop is:
[0032] Store the output of the metal coil magnetic field acting on the Hall disk at room temperature as a reference value;
[0033] When the temperature or stress changes, the sensitivity of the Hall disk changes, but the magnetic field generated by the metal coil does not change. The change in the output of the metal coil acting on the Hall disk is only the change in the Hall disk itself caused by temperature or stress (change relative to the reference value); and the change is processed by the Hall sensitivity self-calibration loop as feedback to control the bias amount (bias voltage or bias current) of the Hall disk;
[0034] Under a new temperature or stress environment, when the change value increases, the bias of the Hall disk is reduced to reduce the sensitivity of the Hall disk, so that the output change of the external magnetic field Bext acting on the Hall disk under the new temperature or stress environment compared to the output under normal temperature is controlled within the required accuracy; when the change value decreases, the bias of the Hall disk is increased to increase the sensitivity of the Hall disk.
[0035] Further, the circuit is adaptable to a voltage biased magnetic sensor or a current biased magnetic sensor.
[0036] Compared with the prior art, the present invention has the following advantages and beneficial effects:
[0037] 1. The present invention provides a digital closed-loop self-calibration compensation circuit for a magnetic sensor. Through a digital closed-loop self-calibration compensation method, the compensation accuracy can be maximized, so that the temperature drift, time drift and anti-interference performance of the magnetic sensor to packaging stress are greatly optimized, especially the temperature drift performance can be qualitatively improved. The present invention can achieve higher calibration accuracy, and can simultaneously calibrate temperature and stress, and can realize real-time closed-loop compensation for temperature and stress;
[0038] 2. The present invention is also applicable when the Hall plate is replaced with other magnetic sensors, such as AMR sensors and TMR sensors.
[0039] 3. The loop calibration of the present invention is for the bias voltage source or bias current source of the magnetic field sensing device, that is, it is applicable not only to the magnetic sensor with voltage bias, but also to the magnetic sensor with current bias. BRIEF DESCRIPTION OF THE DRAWINGS
[0040] The drawings described herein are used to provide a further understanding of the embodiments of the present invention, constitute a part of this application, and do not constitute a limitation of the embodiments of the present invention. In the drawings:
[0041] Figure 1 It is a circuit diagram of a temperature interpolation compensation scheme in the prior art;
[0042] Figure 2 This is a temperature drift curve for a special case;
[0043] Figure 3 This is a structural diagram of a digital closed-loop self-calibration compensation circuit for a magnetic sensor according to Embodiment 1 of the present invention;
[0044] Figure 4 The demodulation clock signal of Embodiment 1 of the present invention;
[0045] Figure 5 This is a structural diagram of a digital closed-loop self-calibration compensation circuit for a magnetic sensor according to Embodiment 2 of the present invention. DETAILED DESCRIPTION
[0046] Hereinafter, the term "include" or "may include" used in various embodiments of the present invention indicates the presence of the invented function, operation or element, and does not limit the addition of one or more functions, operations or elements. In addition, as used in various embodiments of the present invention, the terms "include", "have" and their cognates are intended only to indicate specific features, numbers, steps, operations, elements, components or combinations of the foregoing items, and should not be understood as first excluding the presence of one or more other features, numbers, steps, operations, elements, components or combinations of the foregoing items or the possibility of adding one or more features, numbers, steps, operations, elements, components or combinations of the foregoing items.
[0047] In various embodiments of the present invention, the expression "or" or "at least one of A or / and B" includes any combination or all combinations of the words listed at the same time. For example, the expression "A or B" or "at least one of A or / and B" may include A, may include B, or may include both A and B.
[0048] The expressions (such as "first", "second", etc.) used in various embodiments of the present invention may modify the various constituent elements in various embodiments, but may not limit the corresponding constituent elements. For example, the above expressions do not limit the order and / or importance of the elements. The above expressions are only used for the purpose of distinguishing an element from other elements. For example, the first user device and the second user device indicate different user devices, although both are user devices. For example, without departing from the scope of various embodiments of the present invention, the first element may be referred to as the second element, and similarly, the second element may also be referred to as the first element.
[0049] It should be noted that if it is described that one component element is “connected” to another component element, the first component element may be directly connected to the second component element, and a third component element may be “connected” between the first component element and the second component element. Conversely, when one component element is “directly connected” to another component element, it can be understood that there is no third component element between the first component element and the second component element.
[0050] The terms used in various embodiments of the present invention are only used for the purpose of describing specific embodiments and are not intended to limit various embodiments of the present invention. As used herein, the singular form is intended to also include the plural form, unless the context clearly indicates otherwise. Unless otherwise limited, all terms used here (including technical terms and scientific terms) have the same meaning as the meaning generally understood by those of ordinary skill in the art to which the various embodiments of the present invention belong. The terms (such as the terms defined in the dictionary generally used) will be interpreted as having the same meaning as the contextual meaning in the relevant technical field and will not be interpreted as having an idealized meaning or an overly formal meaning, unless clearly defined in various embodiments of the present invention.
[0051] In order to make the objectives, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with embodiments and drawings. The exemplary embodiments of the present invention and their description are only used to explain the present invention and are not intended to limit the present invention.
[0052] The traditional magnetic sensor temperature compensation method is not flexible enough or has limited compensation accuracy. Too few temperature zones will lead to insufficient compensation accuracy, and too many temperature zones will lead to resource consumption. If the temperature changes too much within the temperature zone, this method cannot achieve correct calibration. In addition, it does not consider the impact of stress and other issues.
[0053] The present invention designs a digital closed-loop self-calibration compensation circuit for a magnetic sensor. Through a digital closed-loop self-calibration compensation method, the compensation accuracy can be maximized, so that the temperature drift, time drift and anti-interference performance of the magnetic sensor to packaging stress are greatly optimized, especially the temperature drift performance can be qualitatively improved. The present invention can achieve higher calibration accuracy, and can simultaneously calibrate temperature and stress, and can realize real-time closed-loop compensation for temperature and stress.
[0054] In addition, this architecture is also applicable to the following scenarios:
[0055] 1. It is also applicable to replace the Hall plate with other magnetic sensors, such as AMR sensor and TMR sensor.
[0056] 2. The loop is calibrated with the bias voltage source or bias current source of the magnetic field sensing device, that is, it is applicable not only to magnetic sensors with voltage bias, but also to magnetic sensors with current bias.
[0057] Example 1
[0058] like Figure 3 As shown, the present invention is a digital closed-loop self-calibration compensation circuit for a magnetic sensor. The magnetic sensor of the present invention adopts a Hall disk, and the voltage source (low-dropout linear regulator) is calibrated. The circuit includes:
[0059] A reference magnetic field generation module is used to generate a reference magnetic field through a metal coil, and the reference magnetic field is not affected by temperature and stress, and serves as a standard for calibrating the Hall sensitivity self-calibration loop;
[0060] The Hall sensitivity self-calibration loop is used to adjust the bias voltage of the Hall disk in real time according to the change in the output voltage of the Hall disk caused by the reference magnetic field, so as to adjust the sensitivity of the Hall disk; and demodulate the output signal of the reference magnetic field on the Hall disk from all the Hall disk output signals through a demodulation extraction circuit.
[0061] In this embodiment, the reference magnetic field generating module includes a current source, a switch modulation circuit C and a metal coil; the first end Ip and the second end In of the current source are both connected to the input end of the switch modulation circuit C, and the first end Lp and the second end Ln of the metal coil are both connected to the output end of the switch modulation C.
[0062] Specifically, the switch modulation circuit C is controlled by the first clock signal ckcoil, and the control logic includes:
[0063] When the first clock signal ckcoil is at a high level, the first end Ip of the current source is connected to the first end Lp of the metal coil, and the second end In of the current source is connected to the second end Ln of the metal coil;
[0064] When the first clock signal ckcoil is at a low level, the first end Ip of the current source is connected to the second end Ln of the metal coil, and the second end In of the current source is connected to the first end Lp of the metal coil.
[0065] In this embodiment, the Hall sensitivity self-calibration loop includes a low voltage drop linear regulator, a first switch modulation circuit A, a Hall disk, a second switch modulation circuit B, a preamplifier, a demodulation extraction circuit, an analog-to-digital converter and a digital signal processor; specifically:
[0066] A low-dropout linear regulator to provide a stable power supply to the Hall plate;
[0067] A first switch modulation circuit A and a second switch modulation circuit B are used to output a differential signal corresponding to the control Hall disk to a pre-amplifier;
[0068] A pre-amplifier, used to amplify the analog voltage signal output by the Hall disk and output it to a demodulation extraction circuit;
[0069] The demodulation extraction circuit is used to extract the output analog voltage signal on the Hall disk caused by the reference magnetic field generated by the metal coil from the analog voltage signal output by the Hall disk caused by the external magnetic field Bext; and only transmit the output analog voltage signal corresponding to the reference magnetic field to the analog-to-digital converter, and filter out the output voltage signal corresponding to the external magnetic field Bext;
[0070] An analog-to-digital converter, used for converting the analog voltage signal output by the reference magnetic field acting on the Hall disk into a digital voltage signal;
[0071] The digital signal processor is used to filter, accelerate and reduce noise on the digital voltage signal output by the reference magnetic field, and output a signal to control the bias signal of the Hall disk to achieve control of the sensitivity of the Hall disk.
[0072] The circuit connection relationship in the Hall sensitivity self-calibration loop is:
[0073] The low voltage difference linear regulator is connected to the first switch modulation circuit A, the first switch modulation circuit A is connected to the Hall disk, the Hall disk is connected to the second switch modulation circuit B, the first switch modulation circuit A is also connected to the second switch modulation circuit B, the second switch modulation circuit B is connected to the input end of the preamplifier, the output end of the preamplifier is connected to the demodulation extraction circuit, the demodulation extraction circuit is connected to the analog-to-digital converter, the analog-to-digital converter is connected to the digital signal processor, and the digital signal processor is connected to the low voltage difference linear regulator.
[0074] Specifically, the Hall plate is modulated by the first switch modulation A and the second switch modulation B controlled by the second clock signal ckhall, and the control logic includes:
[0075] When the second clock signal ckhall is at a high level, the h2 terminal of the Hall disk is connected to a low voltage difference linear regulator, the h4 terminal is grounded, and the differential signal between the h1 terminal and the h3 terminal is output to the pre-amplifier;
[0076] When the second clock signal ckhall is at a low level, the h1 terminal of the Hall disk is connected to the low voltage difference linear regulator, the h3 terminal is grounded, and the differential signal between the h2 terminal and the h4 terminal is output to the pre-amplifier.
[0077] The preamplifier amplifies the output voltage and outputs it to the demodulation extraction circuit. The output of the demodulation extraction circuit is connected to the analog-to-digital converter. The output of the analog-to-digital converter is connected to the digital signal processor. The output of the digital signal processor controls the low-dropout linear regulator. The output of the low-dropout linear regulator provides power to the Hall disk.
[0078] In the above technical solution, the magnetic field generated by the metal coil is converted into a voltage signal through the Hall disk. Since the magnetic field generated by the metal coil is very small, the voltage signal acting on the output of the Hall disk is very small, so it is amplified by the pre-amplifier and output to the demodulation extraction circuit. The main function of the demodulation extraction circuit is to extract the output voltage signal of the Hall disk under the action of the reference magnetic field Bref generated by the metal coil from the voltage signal output by the Hall disk under the action of the external magnetic field Bext. Only the output voltage signal corresponding to the reference magnetic field Bref is transmitted to the analog-to-digital converter, and the output voltage signal corresponding to the external magnetic field Bext is filtered out. The analog-to-digital converter converts the analog voltage signal output by the Hall disk under the action of the reference magnetic field Bref into a digital signal so that the digital signal processor can further process the voltage signal. The digital signal processor will filter, accelerate and reduce noise on the voltage signal output by the reference magnetic field Bref. The signal output by the digital signal processor controls the bias signal of the Hall disk to achieve control of the sensitivity of the Hall disk.
[0079] The working principle of the present invention is:
[0080] The influence of temperature and stress on the sensitivity of magnetic sensors is through affecting the sensitivity of the internal Hall disk. When temperature and stress cause the sensitivity of the Hall disk to change, a feedback quantity is required to control the bias voltage of the Hall disk to correct the sensitivity of the Hall disk. This feedback quantity is controlled by a constant quantity that is not affected by temperature.
[0081] This constant is the magnetic field generated by the metal coil. The magnetic field generated by the metal coil is based on the phenomenon of electromagnetic induction. When current passes through the coil, the moving charges in the coil will generate a magnetic field. The magnetic field generated by the coil mainly depends on the current intensity in the coil and the number of turns of the coil. According to the Biot-Savart law, the magnitude of the magnetic field generated by a coil with a radius of r when a current I flows through it is μI. The magnetic field generated by multiple coils at the center point is their accumulation. That is,
[0082] B=μnI
[0083] μ is the magnetic permeability: the magnetic permeability is related to temperature.
[0084] Therefore, as long as the current of the metal coil is stable and not affected by temperature, the magnetic field is stable and not affected by temperature. Similarly, the magnetic field generated by the metal coil will not be affected by stress.
[0085] The closed-loop self-calibration compensation circuit will first store the output of the metal coil magnetic field acting on the Hall disk at room temperature as a reference value. When the temperature or stress changes, the sensitivity of the Hall disk changes, but the magnetic field generated by the metal coil does not change. Therefore, the change in the output of the metal coil acting on the Hall disk is only the change of the Hall disk itself due to temperature or stress (change relative to the reference value); and the change is processed by the loop as feedback to control the bias of the Hall disk (bias voltage or bias current). In the new temperature or stress environment, when the change value increases, the bias of the Hall disk is reduced to reduce the sensitivity of the Hall disk, so that the change of the output of the external magnetic field Bext acting on the Hall disk in the new temperature or stress environment compared to the output in the normal temperature environment is controlled within the required accuracy; when the change value decreases, the bias of the Hall disk is increased to increase the sensitivity of the Hall disk.
[0086] The key to this closed-loop control is how to extract the output voltage signal of the reference magnetic field on the Hall disk from all the voltage signals output by the Hall. Because in actual applications, the voltage signal output by the Hall disk includes not only the signal generated by the reference magnetic field, but also the signal generated by the external magnetic field and the coil offset voltage.
[0087] The extraction principle is shown in Table 1. The external magnetic field is modulated by the second clock signal ckhall, and the reference magnetic field is modulated by the first clock signal ckcoil. The two clock signals are as follows: Figure 4 As shown, the output voltage signal generated by the external magnetic field on the Hall disk can be modulated into the form of "+, -, +, -", the voltage signal output by the reference magnetic field on the Hall disk can be modulated into the form of "+, +, -, -", and the offset voltage is still in the form of "+, +, +, +". The demodulation extraction circuit completes ph1+ph2-ph3-ph4 at ph5 and ph6 and then divides it by 4 to get the average to obtain the output voltage (reference magnetic field Vref voltage) of the reference magnetic field on the Hall disk.
[0088] Table 1Bref extraction principle table
[0089]
[0090] Example 2
[0091] like Figure 5As shown, the difference between this embodiment and embodiment 1 is that the loop of this embodiment calibrates the bias current source of the magnetic field sensing device. Other parts are similar to embodiment 1 and will not be described one by one here.
[0092] The specific implementation methods described above further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific implementation method of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. A digital closed-loop self-calibration compensation circuit for a magnetic sensor, characterized in that: The circuit includes: A reference magnetic field generation module, used to generate a reference magnetic field through a metal coil, and the reference magnetic field is not affected by temperature and stress, and serves as a standard for calibrating the Hall sensitivity self-calibration loop; The Hall sensitivity self-calibration loop is used to adjust the bias voltage of the magnetic sensor in real time according to the change in the output voltage of the magnetic sensor caused by the reference magnetic field, so as to adjust the sensitivity of the magnetic sensor; and demodulate the output signal of the reference magnetic field on the magnetic sensor from all the output signals of the magnetic sensors through a demodulation extraction circuit.
2. A magnetic sensor digital closed-loop self-calibration compensation circuit according to claim 1, characterized in that: The reference magnetic field generation module includes a current source, a switch modulation circuit C and a metal coil; The first end Ip and the second end In of the current source are both connected to the input end of the switch modulation circuit C, and the first end Lp and the second end Ln of the metal coil are both connected to the output end of the switch modulation circuit C.
3. A magnetic sensor digital closed-loop self-calibration compensation circuit according to claim 2, characterized in that: The switch modulation circuit C is controlled by a first clock signal ckcoil, and the control logic includes: When the first clock signal ckcoil is at a high level, the first end Ip of the current source is connected to the first end Lp of the metal coil, and the second end In of the current source is connected to the second end Ln of the metal coil; When the first clock signal ckcoil is at a low level, the first end Ip of the current source is connected to the second end Ln of the metal coil, and the second end In of the current source is connected to the first end Lp of the metal coil.
4. The digital closed-loop self-calibration compensation circuit for a magnetic sensor according to claim 1, characterized in that: The magnetic sensor is a Hall plate, a TMR sensor or an AMR sensor.
5. A magnetic sensor digital closed-loop self-calibration compensation circuit according to claim 4, characterized in that: The Hall sensitivity self-calibration loop includes a low-dropout linear regulator, a first switch modulation circuit A, a Hall disk, a second switch modulation circuit B, a preamplifier, a demodulation extraction circuit, an analog-to-digital converter, and a digital signal processor; The low voltage drop linear regulator is used to provide a stable power supply for the Hall plate; The first switch modulation circuit A and the second switch modulation circuit B are used to output the differential signal corresponding to the control Hall disk to the pre-amplifier; The pre-amplifier is used to amplify the analog voltage signal output by the Hall disk and output it to the demodulation extraction circuit; The demodulation extraction circuit is used to extract the output analog voltage signal on the Hall disk caused by the reference magnetic field generated by the metal coil from the analog voltage signal output by the Hall disk caused by the external magnetic field; and only transmit the output analog voltage signal corresponding to the reference magnetic field to the analog-to-digital converter, and filter out the output voltage signal corresponding to the external magnetic field; The analog-to-digital converter is used to convert the analog voltage signal output by the reference magnetic field acting on the Hall disk into a digital voltage signal; The digital signal processor is used to filter, accelerate and reduce noise on the digital voltage signal output by the reference magnetic field, and output a signal to control the bias signal of the Hall disk to achieve control of the sensitivity of the Hall disk.
6. A digital closed-loop self-calibration compensation circuit for a magnetic sensor according to claim 5, characterized in that: The low voltage difference linear regulator is connected to a first switch modulation circuit A, the first switch modulation circuit A is connected to a Hall disk, the Hall disk is connected to a second switch modulation circuit B, the first switch modulation circuit A is also connected to a second switch modulation circuit B, the second switch modulation circuit B is connected to an input end of a preamplifier, an output end of the preamplifier is connected to a demodulation extraction circuit, the demodulation extraction circuit is connected to an analog-to-digital converter, the analog-to-digital converter is connected to a digital signal processor, and the digital signal processor is connected to the low voltage difference linear regulator.
7. A digital closed-loop self-calibration compensation circuit for a magnetic sensor according to claim 5, characterized in that: The Hall plate is modulated by the first switch modulation A and the second switch modulation B controlled by the second clock signal ckhall, and the control logic includes: When the second clock signal ckhall is at a high level, the h2 terminal of the Hall disk is connected to a low voltage difference linear regulator, the h4 terminal is grounded, and the differential signal between the h1 terminal and the h3 terminal is output to the pre-amplifier; When the second clock signal ckhall is at a low level, the h1 terminal of the Hall plate is connected to a low voltage difference linear regulator, the h3 terminal is grounded, and the differential signal between the h2 terminal and the h4 terminal is output to the pre-amplifier.
8. The digital closed-loop self-calibration compensation circuit for a magnetic sensor according to claim 1, characterized in that: The closed-loop control process of the Hall sensitivity self-calibration loop is: Store the output of the metal coil magnetic field acting on the Hall disk at room temperature as a reference value; When the temperature or stress changes, the sensitivity of the Hall disk changes, but the magnetic field generated by the metal coil does not change. The change in the output of the metal coil acting on the Hall disk is only the change in the Hall disk itself caused by temperature or stress. The variation is processed by the Hall sensitivity self-calibration loop and used as feedback to control the bias of the Hall disk; Under a new temperature or stress environment, when the change value increases, the bias of the Hall disk is reduced to reduce the sensitivity of the Hall disk, so that the change of the output of the external magnetic field acting on the Hall disk under the new temperature or stress environment compared with the output under normal temperature environment is controlled within the required accuracy; when the change value decreases, the bias of the Hall disk is increased to increase the sensitivity of the Hall disk.
9. A digital closed-loop self-calibration compensation circuit for a magnetic sensor according to claim 8, characterized in that: The bias amount includes a bias voltage or a bias current.
10. The digital closed-loop self-calibration compensation circuit for a magnetic sensor according to claim 1, characterized in that: The circuit is suitable for voltage biased magnetic sensors or current biased magnetic sensors.
Citation Information
Cited By
Detection system, method and device of permanent magnet motor and readable storage medium
CN120334734A
Hall sensor detection device and method
CN121432307A
TMR current sensor automatic attitude calibration method, device, equipment and medium
CN121934007A
Automatic attitude calibration method, apparatus, equipment and medium for TMR current sensors
CN121934007B