Signal processing method and device, hall sensor, medium and product

By acquiring a copy of the Hall sensor signal and clamping the signal, and determining the conversion threshold based on the electromagnetic interference situation to generate a pulse signal, the problem of inaccurate Hall sensor signal output is solved, thereby improving the accuracy of the sensing results and the data integrity of the system.

CN122260189APending Publication Date: 2026-06-23SHANGHAI INTEGRATED CIRCUIT RESEARCH & DEVELOPMENT CENTER CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
SHANGHAI INTEGRATED CIRCUIT RESEARCH & DEVELOPMENT CENTER CO LTD
Filing Date
2024-12-20
Publication Date
2026-06-23

Smart Images

  • Figure CN122260189A_ABST
    Figure CN122260189A_ABST
Patent Text Reader

Abstract

This application provides a signal processing method, apparatus, Hall sensor, medium, and product. The method includes: acquiring a copy of a signal to be processed from the Hall sensor and clamping the signal in the i-th signal period of the copy; if the signal to be processed is free from electromagnetic interference, determining a signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed; if the signal to be processed is subject to electromagnetic interference, determining the signal conversion threshold based on the DC component in the i-th signal period of the copy; and converting the signal in the (i+1)-th signal period of the signal to be processed into a pulse signal based on the signal conversion threshold. This solution simplifies signal processing by converting the signal to be processed into a pulse signal. When electromagnetic interference is present, signal conversion based on the clamped signal can correct signal loss caused by electromagnetic interference, thereby improving the accuracy of the Hall sensor's sensing results.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of signal processing, and more particularly to a signal processing method, apparatus, Hall sensor, medium, and product. Background Technology

[0002] A Hall sensor is an electronic component that uses the Hall effect to detect magnetic fields. It is widely used in applications such as position and speed detection in automobiles, current sensing devices, and proximity switches in industrial automation.

[0003] In practical circuit systems, the signal output of Hall sensors is susceptible to electromagnetic interference from circuits and other electronic components. Common electromagnetic interference mitigation solutions typically involve resetting the Hall sensor circuitry upon detecting interference; however, this approach leads to partial loss of the sensor's sensing data. Therefore, the current challenge is to improve the accuracy of Hall sensor readings. Summary of the Invention

[0004] This application provides a signal processing method, apparatus, Hall sensor, medium, and product to improve the accuracy of Hall sensor sensing results.

[0005] In a first aspect, embodiments of this application provide a signal processing method, comprising: acquiring a copy of a signal to be processed, and performing signal clamping on the signal in the i-th signal period of the copy; wherein the signal to be processed is an induced signal generated by a Hall sensor sensing a magnetic field; determining whether electromagnetic interference exists in the i-th signal period of the signal to be processed; if no electromagnetic interference exists, determining a signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed; if electromagnetic interference exists, determining a signal conversion threshold based on the DC component in the i-th signal period of the copy; and generating a pulse signal based on the signal conversion threshold and the signal conversion in the (i+1)-th signal period of the signal to be processed.

[0006] In one possible implementation, a signal clamping value is determined based on the maximum and minimum signal values ​​in the j-th signal period of the replica; wherein the j-th signal period is earlier than the i-th signal period; and signal clamping is performed on the signal in the i-th signal period of the replica, including clamping and limiting the signal in the i-th signal period of the replica based on the signal clamping value.

[0007] In one possible implementation, determining a signal clamping value based on the maximum and minimum signal values ​​in the j-th signal period of the replica includes: calculating the difference between the maximum and minimum signal values, and calculating an expansion amount based on the difference; using the sum of the maximum signal value and the expansion amount as the upper clamping value, and using the difference between the minimum signal value and the expansion amount as the lower clamping value.

[0008] In one possible implementation, determining a signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed includes: using the DC component in the i-th signal period of the signal to be processed as the signal conversion threshold; and generating a pulse signal based on the signal conversion threshold in the (i+1)-th signal period of the signal to be processed, including: generating a rising edge of the pulse signal if the signal in the (i+1)-th signal period of the signal to be processed is greater than the signal conversion threshold; and generating a falling edge of the pulse signal if the signal in the (i+1)-th signal period of the signal to be processed is less than the signal conversion threshold.

[0009] In one possible implementation, determining a signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed includes: determining a first signal conversion threshold and a second signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed; wherein the first signal conversion threshold is greater than the second signal conversion threshold; and generating a pulse signal based on the signal conversion threshold according to the signal conversion in the (i+1)-th signal period of the signal to be processed includes: generating a rising edge of the pulse signal if the signal in the (i+1)-th signal period of the signal to be processed is greater than the first signal conversion threshold; and generating a falling edge of the pulse signal if the signal in the (i+1)-th signal period of the signal to be processed is less than the second signal conversion threshold.

[0010] In one possible implementation, before acquiring a copy of the signal to be processed and clamping the signal in the i-th signal period of the copy, the method further includes: calculating the difference between the maximum and minimum signal values ​​in the signal period of the signal to be processed, and detecting whether the difference is greater than a preset threshold; acquiring a copy of the signal to be processed and clamping the signal in the i-th signal period of the copy includes: if the difference is greater than the preset threshold, acquiring a copy of the signal to be processed and clamping the signal in the i-th signal period of the copy; calculating the difference between the maximum and minimum signal values ​​in the signal period of the signal to be processed and detecting whether the difference is greater than the preset threshold, and then further includes: if the difference is not greater than the preset threshold, then no processing is performed.

[0011] Secondly, embodiments of this application provide a signal processing apparatus, comprising: an acquisition module, configured to acquire a copy of a signal to be processed and perform signal clamping on the signal in the i-th signal period of the copy; wherein the signal to be processed is an induced signal generated by a Hall sensor sensing a magnetic field; a judgment module, configured to determine whether electromagnetic interference exists in the i-th signal period of the signal to be processed; if no electromagnetic interference exists, a signal conversion threshold is determined based on the DC component in the i-th signal period of the signal to be processed; if electromagnetic interference exists, a signal conversion threshold is determined based on the DC component in the i-th signal period of the copy; and a conversion module, configured to generate a pulse signal based on the signal conversion threshold and the signal conversion in the (i+1)-th signal period of the signal to be processed.

[0012] Thirdly, embodiments of this application provide a Hall sensor for performing the first aspect and / or various possible implementations of the first aspect as described above; or the Hall sensor includes the second aspect and / or various possible implementations of the second aspect as described above.

[0013] Fourthly, embodiments of this application provide a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, are used to implement the first aspect and / or various possible implementations of the first aspect.

[0014] Fifthly, embodiments of this application provide a computer program product, including a computer program that, when executed by a processor, implements the first aspect and / or various possible implementations of the first aspect.

[0015] The signal processing method, apparatus, Hall sensor, medium, and product provided in this application include: acquiring a copy of the signal to be processed from the Hall sensor and clamping the signal in the i-th signal period of the copy; if the signal to be processed is free from electromagnetic interference, determining a signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed; if the signal to be processed is subject to electromagnetic interference, determining the signal conversion threshold based on the DC component in the i-th signal period of the copy; and converting the signal in the (i+1)-th signal period of the signal to be processed into a pulse signal based on the signal conversion threshold. This solution simplifies signal processing by converting the signal to be processed into a pulse signal. When electromagnetic interference is present, signal conversion based on the clamped signal can correct signal loss caused by electromagnetic interference, thereby improving the accuracy of the Hall sensor's sensing results. Attached Figure Description

[0016] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.

[0017] Figure 1 A schematic flowchart illustrating the signal processing method provided in an embodiment of this application;

[0018] Figure 2 A schematic flowchart illustrating the signal processing method provided in an embodiment of this application;

[0019] Figure 3 A schematic flowchart illustrating the signal processing method provided in an embodiment of this application;

[0020] Figure 4 A schematic flowchart illustrating the signal processing method provided in an embodiment of this application;

[0021] Figure 5 A schematic flowchart illustrating the signal processing method provided in an embodiment of this application;

[0022] Figure 6 A schematic flowchart illustrating the signal processing method provided in an embodiment of this application;

[0023] Figure 7 This is a schematic diagram of the structure of the signal processing device provided in the embodiments of this application.

[0024] The accompanying drawings illustrate specific embodiments of this application, which will be described in more detail below. These drawings and descriptions are not intended to limit the scope of the concept in any way, but rather to illustrate the concept of this application to those skilled in the art through reference to particular embodiments. Detailed Implementation

[0025] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.

[0026] A Hall sensor is an electronic component based on the Hall effect, which senses the presence and strength of a magnetic field by measuring the voltage difference induced by the magnetic field. Due to its non-contact measurement, high accuracy, and good tolerance to environmental influences, Hall sensors are widely used in modern technologies, such as position and speed detection in automobiles, current sensing devices, and proximity switches in industrial automation.

[0027] In related technologies, Hall sensors sense magnetic field signals and output corresponding sinusoidal voltage signals, converting these signals into pulse signals, i.e., the sensing result. In practical circuit systems, Hall sensors are susceptible to electromagnetic interference from circuits and other electronic components such as high-frequency signal lines, integrated circuit pins, and various connectors. This interference can lead to instability in the sensor's output signal, resulting in inaccurate sine waves and consequently inaccurate sensing results. A common electromagnetic interference handling solution is to reset the Hall sensor's circuitry after interference is detected to restore normal operation. However, this method may result in partial loss of the sensor's output signal, affecting the system's data integrity and reliability. Therefore, the current challenge is to improve the accuracy of Hall sensor sensing results.

[0028] The technical content provided in this application is only for solving the above-mentioned technical problems in related technologies. The signal processing method, apparatus, Hall sensor, medium, and product provided in the embodiments of this application include: acquiring a copy of the signal to be processed from the Hall sensor and clamping the signal in the i-th signal period of the copy; if the signal to be processed is free from electromagnetic interference, determining a signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed; if the signal to be processed is subject to electromagnetic interference, determining the signal conversion threshold based on the DC component in the i-th signal period of the copy; and based on the signal conversion threshold, converting the signal in the (i+1)-th signal period of the signal to be processed into a pulse signal. The solution of this application simplifies signal processing by converting the signal to be processed into a pulse signal. When electromagnetic interference exists, signal conversion based on the clamped signal can correct signal loss caused by electromagnetic interference, thereby improving the accuracy of the Hall sensor's sensing results.

[0029] The technical solution of this application and how the technical solution of this application solves the above-mentioned technical problems are described in detail below with specific embodiments. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments. The embodiments of this application will now be described with reference to the accompanying drawings.

[0030] Figure 1 This is a schematic flowchart of the signal processing method provided in the embodiments of this application, as shown below. Figure 1 As shown, this method is applied to a Hall sensor, and the method includes:

[0031] S101. Obtain a copy of the signal to be processed, and perform signal clamping on the signal in the i-th signal period of the copy; wherein, the signal to be processed is the induced signal generated by the Hall sensor sensing the magnetic field;

[0032] S102. Determine whether there is electromagnetic interference in the i-th signal period of the signal to be processed. If there is no electromagnetic interference, determine the signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed. If there is electromagnetic interference, determine the signal conversion threshold based on the DC component in the i-th signal period of the copy.

[0033] S103. Based on the signal conversion threshold, generate a pulse signal according to the signal conversion in the (i+1)th signal period of the signal to be processed.

[0034] In practical applications, the execution entity of this method can be a signal processing device, which can be implemented in various ways. For example, it can be implemented through a computer program, such as application software; or it can be implemented through a physical device that integrates or installs relevant computer programs, such as a chip. In practical applications, the signal processing device can also be integrated as a signal processing module into the Hall sensor. Optionally, the execution entity of this method can also be the processor of the Hall sensor.

[0035] In practical applications, the induced signal is a periodic and continuous signal, such as a sine wave or sawtooth wave, output by a hardware circuit with a Hall sensor that senses a magnetic field. Specifically, depending on the hardware architecture of different Hall sensor models, the induced signal can be either analog or digital. In this example, the creation of a copy of the signal to be processed can be achieved by copying the analog signal using a buffer or amplifier. Optionally, a digital signal can also be copied using logic gates. In practical applications, the creation of the copy of the signal to be processed can be performed by the execution body of this method or by the execution body calling other devices capable of signal copying to achieve the corresponding function. It should be noted that clamping a signal can cause signal distortion. In this example, clamping a copy of the signal to be processed instead of directly clamping the signal to be processed maximizes the preservation of the signal information and improves the integrity of the signal to be processed.

[0036] After obtaining a copy of the signal to be processed, signal clamping is applied to the signal in the i-th signal period of the copy. For example, signal clamping can be applied to the signal in all signal periods of the copy, or, based on the operating state of the Hall sensor, signal clamping can be applied to the signal in the copy when the Hall sensor is in its operating state. Specifically, the upper and lower clamping values ​​can be fixed values, or determined by the maximum and minimum signal values ​​of the signal in the previous signal period, or by the average maximum and minimum signal values ​​of multiple signal periods prior to the clamped signal period. In practical applications, the signal clamping effect can be achieved by designing clamping circuits, such as using components like diodes, Zener diodes, and operational amplifiers.

[0037] On the other hand, it is determined whether electromagnetic interference (EMI) exists in the i-th signal period of the signal to be processed. It should be noted that the i-th signal period of the signal to be processed and the i-th signal period of the copy are the same signal period, the difference being that the signals within the i-th signal period of the two signals are different. In practical applications, EMI can be detected by analyzing the signal's spectrum or amplitude changes, or by using filters or dedicated EMI detection circuits. In this example, EMI causes the signal to increase within a period, leading to an increase in the DC component of that period, further causing an abnormal signal conversion threshold in the next signal period of the signal period affected by EMI. It should be noted that in this embodiment, the DC component of a period or the DC component of a certain period refers to the DC component of the signal within that period. Therefore, through EMI detection in this example, when there is no EMI, the signal conversion threshold is determined directly based on the DC component of the i-th signal period of the signal to be processed, which improves the accuracy of the signal conversion; and when EMI exists, the signal conversion threshold is determined based on the DC component of the i-th signal period of the copy, ensuring that the signal conversion threshold does not increase abnormally. After determining the signal conversion threshold, a pulse signal is generated based on the signal conversion in the (i+1)-th signal period of the signal to be processed. In practical applications, comparator circuits or comparators can be used to ensure that pulses are generated at the correct position within the signal cycle. Furthermore, the generated pulse signals can be used for timing control, data transmission, and other applications.

[0038] In related technologies, Hall sensors output a sensing signal when they detect a change in magnetic field. If electromagnetic interference affects the magnetic field strength, it can cause a sudden increase in the Hall sensor's output signal. The conversion threshold when converting the sensing signal to a pulse signal is based on the DC component of the previous cycle. Electromagnetic interference further increases this threshold. An increased conversion threshold can prevent the signal in the current cycle from reaching the threshold or delay its arrival, leading to abnormal signal conversion. This solution sets the conversion threshold based directly on the DC component of the previous cycle when there is no electromagnetic interference, and based on the DC component of the previous cycle after signal clamping when electromagnetic interference is present. This avoids conversion threshold abnormalities caused by electromagnetic interference, thereby improving the accuracy of the Hall sensor.

[0039] In the signal processing method provided in this application embodiment, a copy of the signal to be processed from the Hall sensor is obtained, and the signal in the i-th signal period of the copy is clamped. If the signal to be processed is free from electromagnetic interference, a signal conversion threshold is determined based on the DC component in the i-th signal period of the signal to be processed; if the signal to be processed is subject to electromagnetic interference, the signal conversion threshold is determined based on the DC component in the i-th signal period of the copy. Based on the signal conversion threshold, the signal in the (i+1)-th signal period of the signal to be processed is converted into a pulse signal. This application's solution simplifies signal processing by converting the signal to be processed into a pulse signal. When electromagnetic interference is present, signal conversion based on the clamped signal can correct signal loss caused by electromagnetic interference, thereby improving the accuracy of the Hall sensor's sensing results.

[0040] Figure 2 This is a schematic flowchart of the signal processing method provided in the embodiments of this application, as shown below. Figure 2 As shown, in this embodiment... Figure 1 Based on the embodiments, the signal processing method is described in detail. The method further includes:

[0041] Step 201: Determine the signal clamping value based on the maximum and minimum signal values ​​in the j-th signal period of the replica; wherein the j-th signal period is earlier than the i-th signal period;

[0042] Step 101 involves clamping the signal in the i-th signal period of the replica, including:

[0043] Step 202: Based on the signal clamping value, clamp and limit the signal in the i-th signal period of the replica.

[0044] In this example, the j-th signal period can be the previous signal period of the i-th signal period (i.e., the (i-1)-th signal period) or the period two years prior to the i-th signal period (i.e., the (i-2)-th signal period). It should be noted that the j-th signal period is the period preceding the i-th signal period; therefore, i is at least 2 and j is at least 1. In this case, the conversion threshold for j may be uncertain. In practical applications, the signal threshold for the first period can be directly determined based on historical data. On the other hand, in practical applications, the probability of electromagnetic interference in the first signal period of the signal to be processed is very low. Therefore, this embodiment can assume that there will be no electromagnetic interference in the first period of the signal to be processed, thus ignoring the detection of electromagnetic interference in the i=1-th signal period. Optionally, there can be multiple j-th signal periods, such as the first three signal periods of the i-th signal period. The average of the maximum signal value and the average of the minimum signal value of the three signal periods are calculated and used as the upper clamping value and the lower clamping value, respectively. After determining the signal clamping value, the signal in the i-th signal period of the copy is clamped and restricted based on the signal clamping value. The scheme in this example improves signal fidelity by determining the signal clamp value based on historical periods and enhances the adaptability of signal processing by preserving the trend of signal changes.

[0045] Figure 3 This is a schematic flowchart of the signal processing method provided in the embodiments of this application, as shown below. Figure 3 As shown, in this embodiment... Figure 2 Based on the embodiments, the signal processing method will be described in detail. Step 201 of this method includes:

[0046] Step 301: Calculate the difference between the maximum and minimum signal values, and calculate the expansion amount based on the difference;

[0047] Step 302: Use the sum of the maximum signal value and the expansion amount as the upper clamping value, and the difference between the minimum signal value and the expansion amount as the lower clamping value.

[0048] In this example, the expansion amount can be a percentage of the difference, such as any value between 4% and 6%, or it can be determined based on the mapping relationship between the difference and the expansion amount in actual testing by engineers, such as a certain difference corresponding to a certain expansion amount. After determining the expansion amount, the sum of the maximum signal value and the expansion amount is used as the upper clamping value, and the difference between the minimum signal value and the expansion amount is used as the lower clamping value. This example scheme, by determining the expansion amount based on the maximum and minimum signal values, can further increase the range of signal clamping, thereby achieving adaptive clamping and reducing the possibility of false triggering.

[0049] Figure 4 This is a schematic flowchart of the signal processing method provided in the embodiments of this application, as shown below. Figure 4 As shown, in this embodiment... Figure 1Based on the embodiments, the signal processing method is described in detail. Step 102 of this method, which determines the signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed, includes:

[0050] Step 401: Use the DC component in the i-th signal period of the signal to be processed as the signal conversion threshold;

[0051] Step 103, based on the signal conversion threshold, generates a pulse signal according to the signal conversion in the (i+1)th signal period of the signal to be processed, including:

[0052] Step 402: If the signal in the (i+1)th signal period of the signal to be processed is greater than the signal conversion threshold, then the rising edge of the pulse signal is generated; if the signal in the (i+1)th signal period of the signal to be processed is less than the signal conversion threshold, then the falling edge of the pulse signal is generated.

[0053] It should be noted that this example is an implementation method for determining the signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed. The technical content of this example can also be used to implement the determination of the signal conversion threshold based on the DC component in the i-th signal period of the replica. Since the signal conversion thresholds corresponding to the signal to be processed and the replica are quite similar, the conversion threshold corresponding to the signal to be processed is used as an example, and the conversion threshold corresponding to the replica is not described in detail.

[0054] In practical applications, the DC component of the signal in the i-th signal period can be implemented in an analog circuit using an integrator, or extracted using a low-pass filter. After determining the signal conversion threshold, if the signal in the (i+1)-th signal period of the signal to be processed is greater than the signal conversion threshold, a rising edge of a pulse signal is generated. Specifically, this means that when the signal magnitude of the signal to be processed increases from below the signal conversion threshold to above the threshold, a rising edge of a pulse signal is generated. Similarly, when the signal magnitude of the signal to be processed decreases from above the signal conversion threshold to below the threshold, a falling edge of a pulse signal is generated. The scheme in this example simplifies signal processing by using a single signal conversion threshold for signal conversion, and by setting an appropriate threshold, the impact of signal amplitude variations on system performance can be eliminated to some extent, thereby improving the robustness of the system.

[0055] Figure 5 This is a schematic flowchart of the signal processing method provided in the embodiments of this application, as shown below. Figure 5 As shown, in this embodiment... Figure 1 Based on the embodiments, the signal processing method is described in detail. Step 102 of this method, which determines the signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed, includes:

[0056] Step 501: Based on the DC component in the i-th signal period of the signal to be processed, determine the first signal conversion threshold and the second signal conversion threshold; wherein, the first signal conversion threshold is greater than the second signal conversion threshold;

[0057] Step 103, based on the signal conversion threshold, generates a pulse signal according to the signal conversion in the (i+1)th signal period of the signal to be processed, including:

[0058] Step 502: If the signal in the (i+1)th signal period of the signal to be processed is greater than the first signal conversion threshold, then the rising edge of the pulse signal is generated; if the signal in the (i+1)th signal period of the signal to be processed is less than the second signal conversion threshold, then the falling edge of the pulse signal is generated.

[0059] It should be noted that this example is an implementation method for determining the signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed. The technical content of this example can also be used to implement the determination of the signal conversion threshold based on the DC component in the i-th signal period of the replica. Since the signal conversion thresholds corresponding to the signal to be processed and the replica are quite similar, the conversion threshold corresponding to the signal to be processed is used as an example, and the conversion threshold corresponding to the replica is not described in detail.

[0060] In practical applications, the DC component in the i-th signal period of the signal to be processed can be implemented in an analog circuit using an integrator, or extracted using a low-pass filter. In this example, the first and second signal conversion thresholds can be offset ranges of the DC component, such as within ±30% of the DC component, or by adding or subtracting a fixed signal value from the DC component. After determining the first and second signal conversion thresholds, if the signal in the (i+1)-th signal period of the signal to be processed is greater than the first signal conversion threshold, a rising edge of the pulse signal is generated; if the signal in the (i+1)-th signal period of the signal to be processed is less than the second signal conversion threshold, a falling edge of the pulse signal is generated. In this example, one of the two different signal conversion thresholds is used for the rising edge and the other for the falling edge. The introduction of a hysteresis effect reduces false triggering and pulse signal jitter caused by noise or small-amplitude disturbances, thereby improving the system's noise immunity.

[0061] Figure 6 This is a schematic flowchart of the signal processing method provided in the embodiments of this application, as shown below. Figure 6 As shown, this embodiment provides a detailed description of the signal processing method based on any embodiment. Before obtaining a copy of the signal to be processed in step 101 and clamping the signal in the i-th signal period of the copy, the method further includes:

[0062] Step 601: Calculate the difference between the maximum and minimum values ​​of the signal in the signal period of the signal to be processed, and check whether the difference is greater than a preset threshold.

[0063] Step 101 involves obtaining a copy of the signal to be processed and clamping the signal in the i-th signal period of the copy, including:

[0064] Step 602: If the difference is greater than the preset threshold, obtain a copy of the signal to be processed, and perform signal clamping on the signal in the i-th signal period of the copy;

[0065] Step 601 is followed by:

[0066] Step 603: If the difference is not greater than the preset threshold, no processing is performed.

[0067] For example, the signal period of the signal to be processed can be determined through spectral analysis such as Fourier transform, or by detecting the zero-crossing points of the signal (the transition points from positive to negative or from negative to positive). In practical applications, considering the low signal strength of the noise input, noise filtering can be achieved by calculating the amplitude of the signal to be processed, i.e., the difference between the maximum and minimum signal values ​​within the signal period, and comparing it with a preset threshold. For example, the preset threshold can be set based on experience or historical data, or by analyzing the statistical characteristics of the signal (such as mean, standard deviation), for example, it can be set as a multiple of the signal standard deviation. Optionally, the preset threshold can be dynamically adjusted according to the real-time signal characteristics. For example, an adaptive algorithm can be used to adjust the threshold based on short-term changes in the signal. The scheme in this example achieves noise filtering by standardizing the signal to be processed based on the preset threshold, and only processes signals exceeding the threshold, thereby reducing processing time and latency and improving the real-time performance of the system.

[0068] In the signal processing method provided in this application embodiment, a copy of the signal to be processed from the Hall sensor is obtained, and the signal in the i-th signal period of the copy is clamped. If the signal to be processed is free from electromagnetic interference, a signal conversion threshold is determined based on the DC component in the i-th signal period of the signal to be processed; if the signal to be processed is subject to electromagnetic interference, the signal conversion threshold is determined based on the DC component in the i-th signal period of the copy. Based on the signal conversion threshold, the signal in the (i+1)-th signal period of the signal to be processed is converted into a pulse signal. This application's solution simplifies signal processing by converting the signal to be processed into a pulse signal. When electromagnetic interference is present, signal conversion based on the clamped signal can correct signal loss caused by electromagnetic interference, thereby improving the accuracy of the Hall sensor's sensing results.

[0069] Figure 7 This is a schematic diagram of the signal processing device provided in the embodiments of this application, such as... Figure 7 As shown, the signal processing device provided in this embodiment includes:

[0070] The acquisition module 71 is used to acquire a copy of the signal to be processed and to perform signal clamping on the signal in the i-th signal period of the copy; wherein, the signal to be processed is the induced signal generated by the Hall sensor sensing the magnetic field;

[0071] The judgment module 72 is used to determine whether there is electromagnetic interference in the i-th signal period of the signal to be processed. If there is no electromagnetic interference, the signal conversion threshold is determined based on the DC component in the i-th signal period of the signal to be processed. If there is electromagnetic interference, the signal conversion threshold is determined based on the DC component in the i-th signal period of the copy.

[0072] The conversion module 73 is used to generate a pulse signal based on the signal conversion in the (i+1)th signal period of the signal to be processed, according to the signal conversion threshold.

[0073] In practical applications, this signal processing device can be implemented in various ways. For example, it can be implemented through computer programs, such as application software; or it can be implemented as a medium storing the relevant computer programs, such as a USB flash drive or cloud storage; or it can be implemented through a physical device that integrates or installs the relevant computer programs, such as a chip. In practical applications, the signal processing device can also be integrated as a signal processing module into a Hall sensor.

[0074] In practical applications, the induced signal is a periodic and continuous signal, such as a sine wave, output by a hardware circuit with a Hall sensor that senses a magnetic field. Specifically, depending on the Hall sensor model, the induced signal can be an analog signal or a digital signal. In this example, the creation of a copy of the signal to be processed can be achieved by copying the analog signal using a buffer or amplifier. Optionally, a digital signal can also be copied using logic gates. In practical applications, the creation of the copy of the signal to be processed can be performed by the execution entity of this method or by the execution entity of this method calling other devices capable of signal copying to achieve the corresponding function. After obtaining the copy of the signal to be processed, the signal in the i-th signal period of the copy is clamped. For example, the signal can be clamped in all signal periods of the copy, or, based on the operating state of the Hall sensor, the signal in the copy when the Hall sensor is in the operating state is clamped. Specifically, the upper clamping value and the lower clamping value can be fixed values, or determined by the maximum and minimum signal values ​​of the signal in the previous signal period, or determined by the average maximum and minimum signal values ​​of multiple signal periods before the clamped signal period. In practical applications, signal clamping can be achieved by designing clamping circuits, such as using components like diodes, Zener diodes, and operational amplifiers.

[0075] On the other hand, it is determined whether electromagnetic interference (EMI) exists in the i-th signal period of the signal to be processed. It should be noted that the i-th signal period of the signal to be processed and the i-th signal period of the copy are the same signal period, the difference being that the signals within the i-th signal period of the two signals are different. In practical applications, EMI can be detected by analyzing the signal's spectrum or amplitude changes, or by using filters or dedicated EMI detection circuits. In this example, EMI causes the signal to increase within a period, leading to an increase in the DC component of that period, further causing an abnormal signal conversion threshold in the next signal period of the signal period affected by EMI. Therefore, through EMI detection in this example, when there is no EMI, the signal conversion threshold is determined directly based on the DC component of the i-th signal period of the signal to be processed, which improves the accuracy of the signal conversion; and when EMI exists, the signal conversion threshold is determined based on the DC component of the i-th signal period of the copy, ensuring that the signal conversion threshold does not increase abnormally. After determining the signal conversion threshold, a pulse signal is generated based on the signal conversion in the (i+1)-th signal period of the signal to be processed. In practical applications, a comparison circuit or comparator can be used to ensure that the pulse is generated at the correct position in the signal period. Furthermore, the generated pulse signals can be used for applications such as timing control and data transmission.

[0076] In related technologies, Hall sensors output a sensing signal when they detect a change in magnetic field. If electromagnetic interference affects the magnetic field strength, it can cause a sudden increase in the Hall sensor's output signal. The conversion threshold when converting the sensing signal to a pulse signal is based on the DC component of the previous cycle. Electromagnetic interference further increases this threshold. An increased conversion threshold can prevent the signal in the current cycle from reaching the threshold or delay its arrival, leading to abnormal signal conversion. This solution sets the conversion threshold based directly on the DC component of the previous cycle when there is no electromagnetic interference, and based on the DC component of the previous cycle after signal clamping when electromagnetic interference is present. This avoids conversion threshold abnormalities caused by electromagnetic interference, thereby improving the accuracy of the Hall sensor.

[0077] In the signal processing apparatus provided in this application embodiment, a copy of the signal to be processed from the Hall sensor is acquired, and the signal in the i-th signal period of the copy is clamped. If the signal to be processed is free from electromagnetic interference, a signal conversion threshold is determined based on the DC component in the i-th signal period of the signal to be processed; if the signal to be processed is subject to electromagnetic interference, the signal conversion threshold is determined based on the DC component in the i-th signal period of the copy. Based on the signal conversion threshold, the signal in the (i+1)-th signal period of the signal to be processed is converted into a pulse signal. This solution simplifies signal processing by converting the signal to be processed into a pulse signal. When electromagnetic interference is present, signal conversion based on the clamped signal can correct signal loss caused by electromagnetic interference, thereby improving the accuracy of the Hall sensor's sensing results.

[0078] The acquisition module 71 is also used to determine the signal clamping value based on the maximum and minimum signal values ​​in the j-th signal period of the replica; wherein the j-th signal period is earlier than the i-th signal period;

[0079] The acquisition module 71 is specifically used to clamp and limit the signal in the i-th signal period of the copy based on the signal clamp value.

[0080] In this example, the j-th signal period can be the previous signal period of the i-th signal period (i.e., the (i-1)-th signal period), or the period two years prior to the i-th signal period (i.e., the (i-2)-th signal period). Optionally, there can be multiple j-th signal periods, such as the first three signal periods of the i-th signal period. The average of the maximum and minimum signal values ​​of the three signal periods are calculated and used as the upper clamping value and the lower clamping value, respectively. After determining the signal clamping values, the signal in the i-th signal period of the copy is clamped and restricted based on the signal clamping values. The scheme in this example improves signal fidelity by determining the signal clamping value based on historical periods, and improves the adaptability of signal processing by preserving the trend of signal changes.

[0081] The acquisition module 71 is specifically used to calculate the difference between the maximum signal value and the minimum signal value, and to calculate the expansion amount based on the difference;

[0082] The sum of the maximum signal value and the expansion amount is used as the upper clamping value, and the difference between the minimum signal value and the expansion amount is used as the lower clamping value.

[0083] In this example, the expansion amount can be a percentage of the difference, such as any value between 4% and 6%, or it can be determined based on the mapping relationship between the difference and the expansion amount in actual testing by engineers, such as a certain difference corresponding to a certain expansion amount. After determining the expansion amount, the sum of the maximum signal value and the expansion amount is used as the upper clamping value, and the difference between the minimum signal value and the expansion amount is used as the lower clamping value. This example scheme, by determining the expansion amount based on the maximum and minimum signal values, can further increase the range of signal clamping, thereby achieving adaptive clamping and reducing the possibility of false triggering.

[0084] The judgment module 72 is specifically used to take the DC component in the i-th signal period of the signal to be processed as the signal conversion threshold;

[0085] The conversion module 73 is specifically used to generate the rising edge of a pulse signal if the signal in the (i+1)th signal period of the signal to be processed is greater than the signal conversion threshold, and to generate the falling edge of a pulse signal if the signal in the (i+1)th signal period of the signal to be processed is less than the signal conversion threshold.

[0086] It should be noted that this example is an implementation method for determining the signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed. The technical content of this example can also be used to implement the determination of the signal conversion threshold based on the DC component in the i-th signal period of the replica. Since the signal conversion thresholds corresponding to the signal to be processed and the replica are quite similar, the conversion threshold corresponding to the signal to be processed is used as an example, and the conversion threshold corresponding to the replica is not described in detail.

[0087] In practical applications, the DC component of the signal in the i-th signal period can be implemented in an analog circuit using an integrator, or extracted using a low-pass filter. After determining the signal conversion threshold, if the signal in the (i+1)-th signal period of the signal to be processed is greater than the signal conversion threshold, a rising edge of a pulse signal is generated. Specifically, this means that when the signal magnitude of the signal to be processed increases from below the signal conversion threshold to above the threshold, a rising edge of a pulse signal is generated. Similarly, when the signal magnitude of the signal to be processed decreases from above the signal conversion threshold to below the threshold, a falling edge of a pulse signal is generated. The scheme in this example simplifies signal processing by using a single signal conversion threshold for signal conversion, and by setting an appropriate threshold, the impact of signal amplitude variations on system performance can be eliminated to some extent, thereby improving the robustness of the system.

[0088] The judgment module 72 is specifically used to determine a first signal conversion threshold and a second signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed; wherein the first signal conversion threshold is greater than the second signal conversion threshold;

[0089] The conversion module 73 is specifically used to generate a rising edge of a pulse signal if the signal in the (i+1)th signal period of the signal to be processed is greater than a first signal conversion threshold; and to generate a falling edge of a pulse signal if the signal in the (i+1)th signal period of the signal to be processed is less than a second signal conversion threshold.

[0090] It should be noted that this example is an implementation method for determining the signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed. The technical content of this example can also be used to implement the determination of the signal conversion threshold based on the DC component in the i-th signal period of the replica. Since the signal conversion thresholds corresponding to the signal to be processed and the replica are quite similar, the conversion threshold corresponding to the signal to be processed is used as an example, and the conversion threshold corresponding to the replica is not described in detail.

[0091] In practical applications, the DC component in the i-th signal period of the signal to be processed can be implemented in an analog circuit using an integrator, or extracted using a low-pass filter. In this example, the first and second signal conversion thresholds can be offset ranges of the DC component, such as within ±30% of the DC component, or by adding or subtracting a fixed signal value from the DC component. After determining the first and second signal conversion thresholds, if the signal in the (i+1)-th signal period of the signal to be processed is greater than the first signal conversion threshold, a rising edge of the pulse signal is generated; if the signal in the (i+1)-th signal period of the signal to be processed is less than the second signal conversion threshold, a falling edge of the pulse signal is generated. In this example, one of the two different signal conversion thresholds is used for the rising edge and the other for the falling edge. The introduction of a hysteresis effect reduces false triggering and pulse signal jitter caused by noise or small-amplitude disturbances, thereby improving the system's noise immunity.

[0092] The acquisition module 71 is also used to calculate the difference between the maximum and minimum values ​​of the signal in the signal period of the signal to be processed, and to detect whether the difference is greater than a preset threshold.

[0093] If the difference is not greater than the preset threshold, no processing will be performed.

[0094] The acquisition module 71 is specifically used to acquire a copy of the signal to be processed if the difference is greater than a preset threshold, and to perform signal clamping on the signal in the i-th signal period of the copy;

[0095] For example, the signal period of the signal to be processed can be determined through spectral analysis such as Fourier transform, or by detecting the zero-crossing points of the signal (the transition points from positive to negative or from negative to positive). In practical applications, considering the low signal strength of the noise input, noise filtering can be achieved by calculating the amplitude of the signal to be processed, i.e., the difference between the maximum and minimum signal values ​​within the signal period, and comparing it with a preset threshold. For example, the preset threshold can be set based on experience or historical data, or by analyzing the statistical characteristics of the signal (such as mean, standard deviation), for example, it can be set as a multiple of the signal standard deviation. Optionally, the preset threshold can be dynamically adjusted according to the real-time signal characteristics. For example, an adaptive algorithm can be used to adjust the threshold based on short-term changes in the signal. The scheme in this example achieves noise filtering by standardizing the signal to be processed based on the preset threshold, and only processes signals exceeding the threshold, thereby reducing processing time and latency and improving the real-time performance of the system.

[0096] In the signal processing apparatus provided in this application embodiment, a copy of the signal to be processed from the Hall sensor is acquired, and the signal in the i-th signal period of the copy is clamped. If the signal to be processed is free from electromagnetic interference, a signal conversion threshold is determined based on the DC component in the i-th signal period of the signal to be processed; if the signal to be processed is subject to electromagnetic interference, the signal conversion threshold is determined based on the DC component in the i-th signal period of the copy. Based on the signal conversion threshold, the signal in the (i+1)-th signal period of the signal to be processed is converted into a pulse signal. This solution simplifies signal processing by converting the signal to be processed into a pulse signal. When electromagnetic interference is present, signal conversion based on the clamped signal can correct signal loss caused by electromagnetic interference, thereby improving the accuracy of the Hall sensor's sensing results.

[0097] This application also provides a Hall sensor for performing the method of any embodiment of this application; or the Hall sensor includes the apparatus of any embodiment of this application.

[0098] This application also provides a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, are used to implement the method in any of the embodiments.

[0099] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the method in any of the embodiments.

[0100] Finally, it should be noted that other embodiments of the invention will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This invention is intended to cover any variations, uses, or adaptations of the invention that follow the general principles of the invention and include common knowledge or customary techniques in the art not disclosed herein, and is not limited to the precise structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of the invention is limited only by the appended claims.

Claims

1. A signal processing method, characterized in that, The method includes: A copy of the signal to be processed is acquired, and the signal in the i-th signal period of the copy is clamped; wherein the signal to be processed is the induced signal generated by the Hall sensor sensing the magnetic field; Determine whether there is electromagnetic interference in the i-th signal period of the signal to be processed. If there is no electromagnetic interference, determine the signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed. If there is electromagnetic interference, determine the signal conversion threshold based on the DC component in the i-th signal period of the copy. Based on the signal conversion threshold, a pulse signal is generated according to the signal conversion in the (i+1)th signal period of the signal to be processed.

2. The method according to claim 1, characterized in that, The method further includes: A signal clamping value is determined based on the maximum and minimum signal values ​​in the j-th signal period of the replica; wherein the j-th signal period is earlier than the i-th signal period. The step of clamping the signal in the i-th signal period of the replica includes: Based on the signal clamping value, the signal in the i-th signal period of the replica is clamped and restricted.

3. The method according to claim 2, characterized in that, Determining the signal clamp value based on the maximum and minimum signal values ​​in the j-th signal period of the replica includes: Calculate the difference between the maximum and minimum signal values, and calculate the expansion amount based on the difference; The sum of the maximum signal value and the expansion amount is used as the upper clamping value, and the difference between the minimum signal value and the expansion amount is used as the lower clamping value.

4. The method according to claim 1, characterized in that, Determining the signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed includes: The DC component in the i-th signal period of the signal to be processed is used as the signal conversion threshold. The step of generating a pulse signal based on the signal conversion threshold and the signal conversion in the (i+1)th signal period of the signal to be processed includes: If the signal in the (i+1)th signal period of the signal to be processed is greater than the signal conversion threshold, a rising edge of a pulse signal is generated; if the signal in the (i+1)th signal period of the signal to be processed is less than the signal conversion threshold, a falling edge of a pulse signal is generated.

5. The method according to claim 1, characterized in that, Determining the signal conversion threshold based on the DC component in the i-th signal period of the signal to be processed includes: Based on the DC component in the i-th signal period of the signal to be processed, a first signal conversion threshold and a second signal conversion threshold are determined; wherein, the first signal conversion threshold is greater than the second signal conversion threshold; The step of generating a pulse signal based on the signal conversion threshold and the signal conversion in the (i+1)th signal period of the signal to be processed includes: If the signal in the (i+1)th signal period of the signal to be processed is greater than the first signal conversion threshold, then a rising edge of a pulse signal is generated; if the signal in the (i+1)th signal period of the signal to be processed is less than the second signal conversion threshold, then a falling edge of a pulse signal is generated.

6. The method according to any one of claims 1 to 5, characterized in that, Before acquiring a copy of the signal to be processed and clamping the signal in the i-th signal period of the copy, the method further includes: Calculate the difference between the maximum and minimum values ​​of the signal in the signal period of the signal to be processed, and detect whether the difference is greater than a preset threshold; The step of acquiring a copy of the signal to be processed and clamping the signal in the i-th signal period of the copy includes: If the difference is greater than a preset threshold, a copy of the signal to be processed is obtained, and the signal in the i-th signal period of the copy is clamped. The process of calculating the difference between the maximum and minimum signal values ​​within the signal period of the signal to be processed, and detecting whether the difference is greater than a preset threshold, further includes: If the difference is not greater than a preset threshold, no processing is performed.

7. A signal processing apparatus, characterized in that, The device includes: An acquisition module is used to acquire a copy of the signal to be processed and to perform signal clamping on the signal in the i-th signal period of the copy; wherein, the signal to be processed is an induced signal generated by a Hall sensor sensing a magnetic field; The judgment module is used to determine whether there is electromagnetic interference in the i-th signal period of the signal to be processed. If there is no electromagnetic interference, the signal conversion threshold is determined based on the DC component in the i-th signal period of the signal to be processed. If there is electromagnetic interference, the signal conversion threshold is determined based on the DC component in the i-th signal period of the copy. The conversion module is used to generate a pulse signal based on the signal conversion threshold and the signal conversion in the (i+1)th signal period of the signal to be processed.

8. A Hall sensor, characterized in that, The Hall sensor is used to perform the method as described in any one of claims 1 to 6; or the Hall sensor includes the signal processing apparatus as described in claim 7.

9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions, which, when executed by a processor, are used to implement the method as described in any one of claims 1 to 6.

10. A computer program product, characterized in that, It includes a computer program that, when executed by a processor, implements the method as described in any one of claims 1 to 6.