Magnetic scale testing method, magnetic scale testing device and storage medium
By performing frequency domain analysis and demodulation processing on a circular magnetic grating ruler, signals with uneven magnetization and inconsistent distribution of magnetic poles are separated, solving the problem of insufficient measurement reliability and accuracy in existing technologies and achieving high-precision characterization of magnetic pole characteristics.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- LANZHOU UNIV
- Filing Date
- 2026-06-01
- Publication Date
- 2026-06-30
AI Technical Summary
Existing performance evaluation schemes for circular magnetic scales are difficult to effectively separate amplitude modulation and frequency modulation components, resulting in poor measurement reliability, insufficient accuracy of performance evaluation, and distance dependence of traditional characterization parameters.
By controlling the turntable to drive the two-dimensional translation stage to rotate at a constant speed, the original magnetic induction signal of the TMR reading head is obtained, and frequency domain analysis and demodulation processing are performed to separate the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal, eliminate measurement distance interference, and obtain the intrinsic amplitude signal and magnetic pole characteristic characterization parameters.
It achieves precise quantitative characterization of the uniformity of magnetic pole magnetization intensity and the consistency of magnetic pole distribution spacing, thereby improving the measurement reliability and performance evaluation accuracy of circular magnetic grating rulers.
Smart Images

Figure CN122305908A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of measuring instrument testing and calibration technology, and in particular to a magnetic scale testing method, a magnetic scale testing device, and a storage medium. Background Technology
[0002] A circular magnetic scale is a precision angular displacement measuring device based on the principle of electromagnetic induction, widely used in closed-loop control scenarios for angles, speeds, and positions in rotating machinery. Its core structure consists of a ring-shaped magnetic scale body and a radial reading head: the scale body surface records periodic magnetic grating signals with a specific number of pole pairs; the reading head incorporates a magnetoresistive or Hall element, which picks up spatial magnetic signals as the measured component rotates, converts them into sinusoidal electrical signals, and outputs high-precision angular displacement data after processing. The uniformity of magnetic intensity and the consistency of pole spacing of the circular magnetic scale are the core indicators determining its angular displacement measurement accuracy and long-term service stability.
[0003] Current performance evaluation schemes for circular magnetic scales typically employ signal processing techniques such as Fast Fourier Transform and Quadrature Demodulation to analyze the signal characteristics of the orthogonal signals output by the circular magnetic scale in order to evaluate its performance.
[0004] However, due to the spatial fluctuations in the magnetic intensity recorded by the magnetic scale and the deviation in the magnetic pole spacing, the amplitude distortion and periodic measurement error of the output signal of the reading head will be caused respectively. Signal processing techniques such as fast Fourier transform and quadrature demodulation are difficult to effectively separate the amplitude modulation and frequency modulation components. Therefore, it is impossible to achieve independent quantitative characterization of the two types of defects. Moreover, the change in the detection distance between the TMR (Tunnel Magneto Resistance) reading head and the surface of the magnetic scale will significantly affect the signal amplitude during the measurement process. This results in the distance dependence of traditional characterization parameters, which cannot be used as distance-independent quantities to reflect the inherent characteristics of the magnetic scale. It can be seen that the current performance evaluation scheme for circular magnetic scales has poor measurement reliability and insufficient performance evaluation accuracy. Summary of the Invention
[0005] The main objective of this application is to propose a method, device, and storage medium for testing magnetic scales, aiming to improve the measurement reliability and performance evaluation accuracy of circular magnetic scales.
[0006] In a first aspect, the present invention provides a magnetic scale detection method, applied to a controller of a magnetic scale detection device, the method comprising: In response to the detection command, the turntable is controlled to drive the two-dimensional translation stage to rotate at a constant speed, so that the two-dimensional translation stage drives the circular magnetic scale under test to rotate at a constant speed, and the original magnetic induction signal obtained by the TMR reading head reading the circular magnetic scale under test at the target detection position is acquired. Based on the original magnetic induction signal, the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal are obtained; Based on the instantaneous amplitude modulation signal, the intrinsic amplitude signal is obtained; Based on the intrinsic amplitude signal and the instantaneous frequency modulation signal, the magnetic pole characteristic characterization parameters of the circular magnetic scale under test are determined.
[0007] In an optional implementation, before obtaining the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal based on the original magnetic induction signal, the method further includes: Frequency domain analysis was performed on the original magnetic induction signal to obtain the carrier frequency corresponding to the main peak of the signal spectrum; The original magnetic induction signal is filtered according to the carrier frequency to obtain a pure magnetic induction signal; The step of obtaining the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal based on the original magnetic induction signal includes: Based on the preset demodulation algorithm and the pure magnetic induction signal, the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal are obtained.
[0008] In an optional implementation, obtaining the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal based on a preset demodulation algorithm and the pure magnetic induction signal includes: The pure magnetic induction signal is subjected to Hilbert transform processing to obtain the analytical signal corresponding to the pure magnetic induction signal; Extract the corresponding instantaneous amplitude modulation signal and instantaneous phase from the analyzed signal; The instantaneous frequency modulation signal is calculated based on the time derivative of the instantaneous phase.
[0009] In an optional implementation, obtaining the intrinsic amplitude signal based on the instantaneous amplitude modulation signal includes: Edge effect data segments in the instantaneous amplitude modulation signal are removed to obtain the effective amplitude modulation signal; Based on the effective amplitude modulation signal and a preset coefficient of variation algorithm, the coefficient of variation corresponding to the effective amplitude modulation signal is calculated and obtained. The coefficient of variation is used to characterize the intrinsic amplitude signal.
[0010] In an optional implementation, determining the magnetic pole characteristic characterization parameters of the circular magnetic scale under test based on the intrinsic amplitude signal and the instantaneous frequency modulation signal includes: The first statistical feature of the intrinsic amplitude signal is extracted and used as the first characterization parameter to characterize the uniformity of the magnetic pole magnetization intensity. The second statistical feature of the instantaneous frequency modulation signal is extracted as a second characterization parameter to characterize the consistency of the magnetic pole distribution spacing.
[0011] In an optional implementation, after responding to a detection command and controlling the turntable to drive the two-dimensional translation stage to rotate at a constant speed, so that the two-dimensional translation stage drives the circular magnetic scale to be measured to rotate at a constant speed, the method further includes: Collect the distance signal between the laser displacement sensor and the circular magnetic scale to be measured; Based on the distance signal, determine the eccentricity information of the circular magnetic scale to be measured; The circular magnetic scale to be tested is calibrated based on the eccentricity information.
[0012] In a second aspect, the present invention provides a magnetic grating ruler detection device, comprising: a two-dimensional translation stage (101), a turntable (102), a three-axis displacement stage (103), a TMR reading head (104), and a controller; The two-dimensional translation stage (101) is disposed on the rotating platform (1021) of the turntable (102). The two-dimensional translation stage (101) is used to drive the circular magnetic scale (105) to be tested to move on a preset two-dimensional plane. The three-axis displacement stage (103) is disposed on the side of the turntable (102). The TMR reading head (104) is disposed on the moving end of the three-axis displacement stage (103). The detection end of the TMR reading head (104) faces the side of the scale body of the circular magnetic scale (105) to be tested. The three-axis displacement stage (103) is used to adjust the spatial position of the TMR reading head (104) so that the TMR reading head (104) is at the target detection position of the circular magnetic scale (105) to be tested. The turntable (102), the two-dimensional translation stage (101), the three-axis displacement stage (103), and the TMR reading head (104) are all communicatively connected to the controller; The controller is used to perform the steps of the method as described in any of the foregoing embodiments.
[0013] In an optional embodiment, the magnetic scale detection device further includes a laser displacement sensor (106), which is fixedly disposed on the side of the turntable (102), and the detection surface of the laser displacement sensor (106) faces the side of the scale body of the circular magnetic scale (105) to be tested. The laser displacement sensor (106) is communicatively connected to the controller.
[0014] In an optional embodiment, the two-dimensional translation stage (101) includes a fixing structure (1011) and a translation structure (1012). The bottom surface of the translation structure (1012) is disposed on the rotating platform (1021) of the turntable (102), and the fixing structure (1011) is disposed on the top surface of the translation structure (1012). The fixing structure (1011) is used to fix the circular magnetic scale (105) to be measured.
[0015] Thirdly, the present invention provides a computer-readable storage medium storing a computer program, which, when executed by a processor, performs the steps of the method as described in any of the foregoing embodiments.
[0016] Fourthly, the present invention provides an electronic device, comprising: a processor, a storage medium, and a bus, wherein the storage medium stores machine-readable instructions executable by the processor, and when the electronic device is running, the processor communicates with the storage medium via the bus, and the processor executes the machine-readable instructions to perform the steps of any of the methods described in the foregoing embodiments.
[0017] The beneficial effects of this application are: This application provides a magnetic scale detection method, comprising: responding to a detection command, controlling a turntable to drive a two-dimensional translation stage to rotate at a uniform speed, so that the two-dimensional translation stage drives the circular magnetic scale to be measured to rotate at a uniform speed, and acquiring the original magnetic induction signal obtained by the TMR reading head reading the circular magnetic scale to be measured at the target detection position; acquiring an instantaneous amplitude modulation signal and an instantaneous frequency modulation signal based on the original magnetic induction signal; acquiring an intrinsic amplitude signal based on the instantaneous amplitude modulation signal; and determining the magnetic pole characteristic characterization parameters of the circular magnetic scale to be measured based on the intrinsic amplitude signal and the instantaneous frequency modulation signal. In this embodiment, the magnetic scale detection method achieves accurate quantitative characterization of the uniformity of magnetic pole magnetization intensity and the consistency of magnetic pole distribution spacing by decoupling the original magnetic induction signal to separate the instantaneous amplitude modulation signal characterizing the non-uniformity of magnetic pole magnetization and the instantaneous frequency modulation signal characterizing the inconsistency of magnetic pole distribution spacing, and processing the instantaneous amplitude modulation signal to eliminate measurement distance interference and acquire the intrinsic amplitude signal, thereby improving the measurement reliability and performance evaluation accuracy of the circular magnetic scale. Attached Figure Description
[0018] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments of this application will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0019] Figure 1 This is a schematic diagram of the structure of a magnetic scale detection device provided in an embodiment of this application; Figure 2 A schematic flowchart of a magnetic ruler detection method provided in an embodiment of this application; Figure 3 A schematic flowchart of a magnetic ruler detection method provided in another embodiment of this application; Figure 4 A schematic flowchart of a magnetic ruler detection method provided in another embodiment of this application; Figure 5 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application.
[0020] Reference numerals in the attached figures: 101-Two-dimensional translation stage; 1011-Fixed structure; 1012-Translation structure; 102-Turntable; 1021-Rotation platform; 103-Three-axis displacement stage; 104-TMR reading head; 105-Circular magnetic scale to be measured; 106-Laser displacement sensor. Detailed Implementation
[0021] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. The components of the embodiments of this application described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.
[0022] Therefore, the following detailed description of the embodiments of this application provided in the accompanying drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of the application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.
[0023] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.
[0024] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0025] The following detailed description of some embodiments of this application is provided in conjunction with the accompanying drawings. Unless otherwise specified, the following embodiments and features can be combined with each other.
[0026] Current performance evaluation schemes for circular magnetic scales typically employ signal processing techniques such as Fast Fourier Transform (FFT) and quadrature demodulation to analyze the signal characteristics of the orthogonal signal output by the circular magnetic scale to assess its performance. However, due to spatial fluctuations in the magnetic intensity recorded by the magnetic scale and deviations in the magnetic pole spacing, amplitude distortion and periodic measurement errors in the output signal of the reading head can occur, respectively. Existing signal processing techniques such as FFT and quadrature demodulation struggle to effectively separate the amplitude-modulated (AM) and frequency-modulated (FM) components in the acquired magnetic induction intensity signal from the circular magnetic scale. Therefore, independent quantitative characterization of these two types of defects is impossible. Furthermore, changes in the detection distance between the TMR (Tunnel Magneto Resistance) reading head and the surface of the magnetic scale significantly affect the signal amplitude during measurement, resulting in distance dependence of traditional characterization parameters. These parameters cannot be considered distance-independent quantities reflecting the inherent characteristics of the magnetic scale, further interfering with the accuracy of performance evaluation. Therefore, current performance evaluation schemes for circular magnetic scales suffer from poor measurement reliability and insufficient accuracy.
[0027] To address the aforementioned issues, the main objective of this application is to propose a magnetic scale testing device and method, aiming to improve the measurement reliability and performance evaluation accuracy of circular magnetic scales.
[0028] Figure 1 Please refer to the schematic diagram of the magnetic scale detection device provided in one embodiment of this application. Figure 1 The magnetic scale detection device includes: a two-dimensional translation stage 101, a turntable 102, a three-axis displacement stage 103, a TMR reading head 104, and a controller.
[0029] The two-dimensional translation stage 101 is mounted on the rotating platform 1021 of the turntable 102. The two-dimensional translation stage 101 is used to move the circular magnetic scale 105 to be measured on a preset two-dimensional plane. The three-axis displacement stage 103 is located to the side of the turntable 102. The TMR reading head 104 is located at the moving end of the three-axis displacement stage 103, with the detection end of the TMR reading head 104 facing the side of the circular magnetic scale 105 to be measured. The three-axis displacement stage 103 is used to adjust the spatial position of the TMR reading head 104, so that the TMR reading head 104 is at the target detection position of the circular magnetic scale 105 to be measured.
[0030] The aforementioned turntable 102, the aforementioned two-dimensional translation stage 101, the aforementioned three-axis displacement stage 103, and the aforementioned TMR reading head 104 are all communicatively connected to the aforementioned controller.
[0031] For example, the turntable 102 can be a high-precision electric rotary platform 1021, on which the two-dimensional translation stage 101 can be fixedly mounted. The two-dimensional translation stage 101 can be, for example, an XY-axis precision displacement platform, used to support and adjust the position of the circular magnetic scale 105 to be tested in the horizontal plane. By driving the two-dimensional translation stage 101 and the circular magnetic scale 105 fixed on the two-dimensional translation stage 101 to rotate at a constant speed through the turntable 102, a stable rotational motion basis can be provided for the circumferential detection of the circular magnetic scale 105. The two-dimensional translation stage 101 can be used to preliminarily align the geometric center of the circular magnetic scale 105 to the rotation center of the turntable 102 by fine-tuning in the X and Y axes before detection, providing a basis for subsequent precise alignment calibration. It is understood that the specific type, accuracy level and driving method of the aforementioned turntable 102 and the aforementioned two-dimensional translation stage 101 can be selected and determined according to the actual detection requirements. For example, for higher precision detection scenarios, an air-bearing turntable 102 or a displacement stage equipped with a grating ruler closed-loop feedback can be used, but this is not a limitation.
[0032] The aforementioned three-axis displacement stage 103 can be, for example, an XYZ three-axis precision displacement platform. The fixed end of the three-axis displacement stage 103 can be mounted on a base on the side of the turntable 102, and the TMR reading head 104 is mounted on the moving end of the three-axis displacement stage 103. By controlling the movement of the three-axis displacement stage 103 in the three directions corresponding to the X, Y, and Z axes, the relative spatial position between the TMR reading head 104 and the circular magnetic scale 105 to be measured can be precisely adjusted. Specifically, by adjusting the moving end of the three-axis displacement stage 103, the TMR reading head 104 can be moved until the detection end of the TMR reading head 104 maintains the optimal detection gap (e.g., 0.4 mm, but not limited to this; the specific gap can be adjusted according to actual conditions) with the surface of the circular magnetic scale 105 to be measured, and is precisely aligned with the magnetic pole array area, ensuring that the acquired magnetic induction signal has the best signal-to-noise ratio and stability. The aforementioned TMR reading head 104 is a magnetic sensing element based on the tunneling magnetoresistance effect, possessing advantages such as high sensitivity, good temperature stability, and small size. It is suitable for accurately acquiring weak magnetic signals from the surface of the aforementioned circular magnetic grating 105. The aforementioned target detection position, for example, can refer to the optimal spatial position where the TMR reading head 104 is positioned after adjustment by the aforementioned triaxial displacement stage 103, enabling stable and high signal-to-noise ratio acquisition of magnetic induction signals. This position is typically determined by the detection gap and radial alignment accuracy between the TMR reading head 104 and the aforementioned circular magnetic grating 105.
[0033] The aforementioned controller can be, for example, an industrial computer, an embedded controller, a programmable logic controller, or other device with data processing and control command output functions. Its specific model and performance parameters can be selected and determined according to the integration requirements of the detection system, and are not limited here. This controller is communicatively connected to the aforementioned turntable 102, the aforementioned two-dimensional translation stage 101, the aforementioned three-axis displacement stage 103, and the aforementioned TMR reading head 104, for example, to coordinate and control the coordinated actions of these components. In response to a detection command, the controller can control the turntable 102 to drive the two-dimensional translation stage 101 and the circular magnetic scale 105 under test to rotate at a preset speed, while simultaneously controlling the TMR reading head 104 to acquire magnetic induction intensity signals at a preset sampling frequency.
[0034] It is understood that the communication connection between the aforementioned turntable 102, the aforementioned two-dimensional translation stage 101, the aforementioned three-axis displacement stage 103, the aforementioned TMR reading head 104, and the aforementioned controller can be a wired connection, such as through industrial standard buses like RS232, RS485, CAN bus, or Ethernet. It can also be a wireless connection, such as through wireless communication protocols like Wi-Fi or Bluetooth. The specific communication method chosen depends on the on-site layout of the detection system, anti-interference requirements, and real-time data acquisition needs, and is not limited here.
[0035] In the magnetic scale detection device provided in this application embodiment, the TMR reading head 104 is precisely adjusted to the target detection position by a three-axis displacement stage 103, the turntable 102 drives the two-dimensional translation stage 101 to rotate the circular magnetic scale 105 under test at a uniform speed to stably and accurately acquire magnetic induction signals, and a preset demodulation algorithm is used to decouple the original magnetic induction signal to separate the instantaneous amplitude modulation signal characterizing the non-uniformity of magnetic pole magnetization and the instantaneous frequency modulation signal characterizing the inconsistency of magnetic pole distribution spacing, and a preset normalization algorithm is used to process the instantaneous amplitude modulation signal to eliminate measurement distance interference and obtain the intrinsic amplitude signal. This achieves accurate quantitative characterization of the uniformity of magnetic pole magnetization intensity and the consistency of magnetic pole distribution spacing, thereby improving the measurement reliability and performance evaluation accuracy of the circular magnetic scale.
[0036] Furthermore, the aforementioned magnetic scale detection device may also include a laser displacement sensor 106, which is fixedly disposed on the side of the turntable 102, with the detection surface of the laser displacement sensor 106 facing the side of the circular magnetic scale 105 to be tested.
[0037] The laser displacement sensor 106 is communicatively connected to the controller.
[0038] For example, the laser displacement sensor 106 can be fixedly mounted on a base on the side of the turntable 102, with its detection end (i.e., the laser emission and reception window) facing the outer edge of the circular magnetic scale 105 to be measured. The laser displacement sensor 106 can be, for example, a high-precision laser triangular reflection displacement sensor, capable of measuring the linear distance between itself and the surface of the circular magnetic scale 105 in real time with micron-level resolution, but is not limited thereto. During the process of the turntable 102 driving the circular magnetic scale 105 to rotate at a constant speed, the laser displacement sensor 106 can, for example, continuously emit a laser beam towards the side of the circular magnetic scale 105 under the control of a controller, and receive the light signal reflected from the scale surface. The built-in signal processing circuit converts the light signal into an electrical signal proportional to the distance, thereby generating a distance signal. The laser displacement sensor 106 can transmit the acquired real-time distance signal to the controller via a communication connection.
[0039] After receiving the distance signal transmitted by the laser displacement sensor 106, the controller can analyze and process the signal to determine whether the geometric center of the circular magnetic scale 105 under test coincides with the rotation center of the turntable 102. Specifically, when the circular magnetic scale 105 under test is eccentric, the distance signal collected by the laser displacement sensor 106 will exhibit a periodic fluctuation characteristic of an approximately sinusoidal wave. The amplitude of this sine wave directly reflects the magnitude of the eccentricity, and the rotation angle corresponding to the peak or trough of the sine wave indicates the direction of the eccentricity. The controller can automatically calculate the eccentricity distance and direction between the geometric center of the circular magnetic scale 105 under test and the rotation center of the turntable 102 by performing waveform analysis on the distance signal (e.g., through peak detection, curve fitting, etc.).
[0040] After acquiring the eccentricity and eccentricity direction, the controller generates a position correction command based on the eccentricity information and sends the correction command to the two-dimensional translation stage 101. Responding to the correction command, the two-dimensional translation stage 101 precisely adjusts its X-axis and / or Y-axis directions, moving the circular magnetic scale 105 under test in the horizontal plane to gradually reduce the eccentricity. The controller continuously receives distance signals from the laser displacement sensor 106 and monitors the changes in eccentricity in real time, forming a closed-loop control loop until the distance signal meets preset alignment conditions (e.g., the fluctuation amplitude of the distance signal is less than a preset threshold, or the distance signal is approximately constant). At this point, it can be considered that the geometric center of the circular magnetic scale 105 under test and the rotation center of the turntable 102 have achieved precise alignment at the micrometer level. This precise alignment and calibration process can effectively eliminate periodic measurement errors caused by installation eccentricity, providing a reliable measurement hardware foundation for subsequent high-precision magnetic signal acquisition, and ensuring that the final obtained magnetic pole characteristic parameters truly reflect the inherent quality of the magnetic scale, rather than the interference of installation errors.
[0041] Optionally, the two-dimensional translation stage 101 may include a fixing structure 1011 and a translation structure 1012. The bottom surface of the translation structure 1012 is disposed on the rotating platform 1021 of the turntable 102, and the fixing structure 1011 is disposed on the top surface of the translation structure 1012. The fixing structure 1011 is used to fix the circular magnetic scale 105 to be measured.
[0042] For example, the translation structure 1012 can be an XY-axis precision crossed roller guide platform, which integrates an X-axis drive mechanism and a Y-axis drive mechanism to control the movement of the circular magnetic scale 105 to be measured in two orthogonal directions in the horizontal plane. The translation structure 1012 can be fixedly mounted on the rotating platform 1021 of the turntable 102 via its bottom surface, ensuring that the translation structure 1012 can rotate synchronously with the turntable 102 while maintaining its own degree of freedom of movement in the horizontal plane. The top surface of the translation structure 1012 can be a mounting reference surface for supporting the fixed structure 1011.
[0043] The aforementioned fixing structure 1011 may include, for example, a positioning base plate and a clamping fixture. The positioning base plate has a positioning groove or positioning pin hole that matches the shape of the circular magnetic scale 105 to be tested, for achieving rapid initial positioning of the circular magnetic scale 105. The clamping fixture may be in the form of a mechanical quick clamp, an electromagnetic chuck, or a pneumatic gripper, etc., for firmly pressing the circular magnetic scale 105 to be tested onto the positioning base plate after it is placed on the positioning base plate, preventing the circular magnetic scale 105 to be tested from radially shifting or axially tilting during the rotation of the turntable 102, and ensuring the positional stability and repeatability of the testing process. It is understood that the specific form of the aforementioned fixing structure 1011 is not limited to the positioning base plate and clamping fixture; it may also be a vacuum adsorption platform, permanent magnet chuck, or other special fixture customized according to the size and shape of the circular magnetic scale 105 to be tested, as long as it can reliably fix the circular magnetic scale 105 to be tested on the top surface of the translation structure 1012.
[0044] Through the cooperation of the translation structure 1012 and the fixed structure 1011, the two-dimensional translation stage 101 can not only achieve high-precision position adjustment of the circular magnetic scale 105 to be measured in the horizontal plane, but also ensure that the circular magnetic scale 105 to be measured is always stably maintained in the preset position during the high-speed rotation or long-term continuous operation of the turntable 102, providing a stable and reliable hardware foundation for subsequent precision alignment calibration and magnetic signal acquisition.
[0045] Figure 2 This is a schematic flowchart of a magnetic scale detection method provided in an embodiment of this application. The magnetic scale detection method can, for example, be derived from the above... Figure 1 The controller of the magnetic scale detection device in the embodiment executes, such as Figure 2 As shown, the magnetic ruler detection method may include: S201. In response to the detection command, control the turntable to drive the two-dimensional translation stage to rotate at a constant speed, so that the two-dimensional translation stage drives the circular magnetic scale to be tested to rotate at a constant speed, and acquire the original magnetic induction signal obtained by the TMR reading head reading the circular magnetic scale to be tested at the target detection position.
[0046] For example, the aforementioned detection command can be triggered by an operator through the input device of the controller (e.g., touchscreen, button, host computer software interface, etc.), or it can be automatically generated by a pre-written automated test program according to a preset timing sequence, but is not limited thereto. After receiving the detection command, the controller first confirms that the TMR reading head has been adjusted to the target detection position by the three-axis displacement stage, and then sends a control signal to the turntable to drive the turntable to start rotating at a preset speed (e.g., 1 rpm, 5 rpm, etc., the specific speed can be adjusted and determined according to the detection requirements). When the turntable rotates, it drives the two-dimensional translation stage on its rotating platform and the circular magnetic scale to be tested fixed on the two-dimensional translation stage to rotate synchronously.
[0047] During the uniform rotation of the circular magnetic scale under test, the controller can, for example, synchronously send a sampling command to the TMR reading head, controlling the TMR reading head to continuously collect the magnetic induction intensity signal on the surface of the circular magnetic scale under test at the target detection position at a preset sampling frequency (e.g., 1000 times per second, 5000 times per second, etc.). The TMR reading head can, for example, convert the collected analog signal into a digital signal and transmit it to the controller in real time via a communication connection. The controller stores the received magnetic induction intensity data in chronological order to form the original magnetic induction signal. This original magnetic induction signal can, for example, include all the information of the magnetic pole array of the circular magnetic scale under test, that is, it includes both the fundamental component formed by the periodic arrangement of magnetic poles, and the amplitude modulation component caused by the uneven magnetization intensity of the magnetic poles and the frequency modulation component caused by the inconsistent spacing of the magnetic poles. For example, the original magnetic induction signal can be represented in the following form:
[0048] Among them, the above The original magnetic induction signal corresponding to time t was acquired by the aforementioned TMR read head. for The instantaneous amplitude at that moment corresponds to the amplitude modulation component mentioned above. for The instantaneous angular frequency at that moment corresponds to the aforementioned frequency modulation component. For the initial phase, The whole represents the instantaneous phase.
[0049] It is understandable that the rotational speed of the aforementioned turntable and the sampling frequency of the aforementioned TMR reading head can be matched to ensure that the acquired raw magnetic induction signal has sufficient resolution and signal-to-noise ratio. This avoids the problem of insufficient sampling points per unit angle due to excessively high turntable speed, which could affect the accuracy of subsequent frequency domain analysis, and the problem of prolonged detection time and reduced detection efficiency due to excessively slow speed. The aforementioned controller can automatically calculate and set a suitable combination of rotational speed and sampling frequency according to the number of pole pairs of the circular magnetic grating ruler under test and the detection accuracy requirements; specific parameters are not limited here.
[0050] S202. Based on the original magnetic induction signal, obtain the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal.
[0051] For example, after acquiring the original magnetic induction signal, the controller may call a preset demodulation algorithm to process the original magnetic induction signal to separate the amplitude modulation component and frequency modulation component included in the original magnetic induction signal.
[0052] The aforementioned preset demodulation algorithm can be selected or designed for the purpose of constructing the analytical form of the original magnetic induction signal and extracting instantaneous feature parameters from it. The specific preset demodulation algorithm steps can be as follows: first, construct the analytical signal corresponding to the original magnetic induction signal through the preset demodulation algorithm; then, extract the correlation signal (i.e., instantaneous amplitude modulation signal) and instantaneous phase of the amplitude modulation component corresponding to the original magnetic induction signal from the analytical signal; and then, calculate and obtain the correlation signal (i.e., instantaneous frequency modulation signal) of the frequency modulation component based on the time derivative of the instantaneous phase, thereby realizing the separation of the amplitude modulation component and the frequency modulation component included in the original magnetic induction signal, that is, realizing the acquisition of the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal. Of course, the above implementation method is only one possible implementation example, and the specific implementation details of the preset demodulation algorithm used in specific applications are not limited to the above description.
[0053] The aforementioned instantaneous amplitude modulation signal corresponds to the change in the instantaneous amplitude of the original magnetic induction signal over time. Its fluctuation characteristics mainly reflect the spatial uniformity of the magnetization intensity of the magnetic poles of the circular magnetic grating ruler under test. The aforementioned instantaneous frequency modulation signal corresponds to the change in the instantaneous frequency of the original magnetic induction signal over time. Its fluctuation characteristics mainly reflect the consistency of the spacing between the magnetic poles of the circular magnetic grating ruler under test. Through the aforementioned preset demodulation algorithm, the originally superimposed composite modulation signal is decomposed into two independent feature sequences, providing basic data for subsequent quantitative analysis.
[0054] S203. Obtain the intrinsic amplitude signal based on the instantaneous amplitude modulation signal described above.
[0055] Although the instantaneous amplitude modulation signal reflects the fluctuation characteristics of the magnetic pole magnetization intensity, its amplitude is affected by the detection gap between the TMR reading head at the target detection position and the surface of the circular magnetic scale under test. When the detection gap changes (e.g., when acquiring the same circular magnetic scale under test at different measurement distances), the overall amplitude of the instantaneous amplitude modulation signal is scaled, resulting in a significant distance dependence in its statistical characteristics. Therefore, it cannot be directly used as a distance-independent quantity characterizing the intrinsic properties of the magnetic scale. Thus, the controller can further process the instantaneous amplitude modulation signal to eliminate the amplitude scaling effect caused by changes in the detection gap, thereby obtaining the intrinsic amplitude signal independent of the measurement distance. This intrinsic amplitude signal retains the inherent characteristics of the relative fluctuation of the magnetic pole magnetization intensity while eliminating the interference of the external factor of measurement distance, making it a reliable data source for subsequent magnetic pole characteristic analysis.
[0056] S204. Based on the above intrinsic amplitude signal and the above instantaneous frequency modulation signal, determine the magnetic pole characteristic characterization parameters of the circular magnetic scale to be tested.
[0057] For example, after acquiring the intrinsic amplitude signal and the instantaneous frequency modulation signal, the controller can perform statistical analysis on these two sets of signals to extract key indicators that can quantify the magnetic pole characteristics, serving as the magnetic pole characteristic characterization parameters. For instance, the controller can calculate the statistical characteristics (such as standard deviation and variance) of the intrinsic amplitude signal. The magnitude of these statistical characteristics is positively correlated with the spatial fluctuation of the magnetic pole magnetization intensity and can be used to quantify the uniformity of the magnetic pole magnetization intensity. Simultaneously, the controller can calculate the statistical characteristics (such as standard deviation and variance) of the instantaneous frequency modulation signal. The magnitude of these statistical characteristics is positively correlated with the deviation of the actual magnetic pole spacing from the theoretical design value and can be used to quantify the consistency of the magnetic pole distribution spacing. The controller can output the calculated statistical characteristics as the magnetic pole characteristic characterization parameters of the circular magnetic grating ruler under test for subsequent quality assessment, error compensation, or production control.
[0058] This application provides a magnetic scale detection method, comprising: responding to a detection command, controlling a turntable to drive a two-dimensional translation stage to rotate at a uniform speed, so that the two-dimensional translation stage drives the circular magnetic scale to be measured to rotate at a uniform speed, and acquiring the original magnetic induction signal obtained by the TMR reading head reading the circular magnetic scale to be measured at the target detection position; acquiring an instantaneous amplitude modulation signal and an instantaneous frequency modulation signal based on the original magnetic induction signal; acquiring an intrinsic amplitude signal based on the instantaneous amplitude modulation signal; and determining the magnetic pole characteristic characterization parameters of the circular magnetic scale to be measured based on the intrinsic amplitude signal and the instantaneous frequency modulation signal. In this embodiment, the magnetic scale detection method achieves accurate quantitative characterization of the uniformity of magnetic pole magnetization intensity and the consistency of magnetic pole distribution spacing by decoupling the original magnetic induction signal to separate the instantaneous amplitude modulation signal characterizing the non-uniformity of magnetic pole magnetization and the instantaneous frequency modulation signal characterizing the inconsistency of magnetic pole distribution spacing, and processing the instantaneous amplitude modulation signal to eliminate measurement distance interference and acquire the intrinsic amplitude signal, thereby improving the measurement reliability and performance evaluation accuracy of the circular magnetic scale.
[0059] Furthermore, in the above Figure 2 Based on the embodiments, before obtaining the instantaneous amplitude modulation signal and instantaneous frequency modulation signal from the original magnetic induction signal, the above method further includes: Frequency domain analysis of the original magnetic induction signal yields the carrier frequency corresponding to the main peak of the signal spectrum.
[0060] For example, after acquiring the original magnetic induction signal, the controller can first perform frequency domain analysis on the original magnetic induction signal, for example, by converting the time domain signal into a frequency domain spectrum through a fast Fourier transform. In the frequency domain spectrum, the fundamental signal formed by the periodic array of magnetic poles of the circular magnetic grating ruler under test will exhibit a clear main peak in the signal spectrum, and the frequency corresponding to the main peak of the signal spectrum is the carrier frequency.
[0061] The magnitude of the aforementioned carrier frequency is typically determined by the number of pole pairs of the circular magnetic scale under test and the rotational speed of the turntable. By identifying and extracting this carrier frequency, an accurate frequency reference can be provided for subsequent filtering processing.
[0062] It is understood that the specific implementation of the above frequency domain analysis is not limited to the Fast Fourier Transform. Other spectral analysis methods, such as power spectral density estimation, can also be used. The specific method can be selected and determined according to the actual processing accuracy and computational efficiency requirements, and no restrictions are imposed here.
[0063] The original magnetic induction signal is filtered according to the carrier frequency to obtain a pure magnetic induction signal.
[0064] For example, after identifying and acquiring the carrier frequency, the controller can, for instance, construct a bandpass filter based on the carrier frequency and use the bandpass filter to filter the original magnetic induction signal.
[0065] The passband range of the aforementioned bandpass filter can be set, for example, to a sideband bandwidth centered on the aforementioned carrier frequency and covering a preset multiple of it (e.g., plus or minus 5 times the sideband, but not limited thereto), in order to preserve the effective magnetic signal components within the frequency band.
[0066] Through the above filtering process, various interference components in the original magnetic induction signal can be effectively suppressed, such as electromagnetic interference, impulse noise introduced by mechanical vibration, and low-frequency eccentricity interference noise caused by the incomplete alignment of the geometric center of the circular magnetic scale under test with the rotation center of the turntable. The pure magnetic induction signal obtained after filtering has the characteristics of stable baseline and clear features, and can more accurately reflect the magnetic pole characteristics of the circular magnetic scale under test, providing high-quality input data for subsequent demodulation processing.
[0067] The above-mentioned acquisition of instantaneous amplitude modulation signal and instantaneous frequency modulation signal based on the original magnetic induction signal includes: Based on the preset demodulation algorithm and the aforementioned pure magnetic induction signal, the aforementioned instantaneous amplitude modulation signal and the aforementioned instantaneous frequency modulation signal are obtained.
[0068] For example, similar to the example corresponding to step S202 above, after acquiring the pure magnetic induction signal, the controller can, for example, use the pure magnetic induction signal as input and call the preset demodulation algorithm for processing to separate and reconstruct the correlation signals of the amplitude modulation component and the frequency modulation component from the pure magnetic induction signal, that is, the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal. The specific implementation method can be, for example, first constructing the analytical signal corresponding to the pure magnetic induction signal through the preset demodulation algorithm, then extracting the instantaneous amplitude modulation signal and the instantaneous phase corresponding to the pure magnetic induction signal from the analytical signal, and then calculating and acquiring the instantaneous frequency modulation signal based on the time derivative of the instantaneous phase, thereby realizing the acquisition of the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal. However, it is understood that the above content is only one possible way to acquire the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal. The actual way to acquire the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal may also include other processing steps, which are not specifically limited here.
[0069] By using the pure magnetic induction signal instead of the original magnetic induction signal as the input to the preset demodulation algorithm, the interference of various noise components on the demodulation results can be effectively avoided, so that the extracted instantaneous amplitude modulation signal and the instantaneous frequency modulation signal can more realistically reflect the inherent characteristics of the uniformity of magnetic pole magnetization intensity and the consistency of magnetic pole distribution spacing of the circular magnetic grating ruler under test.
[0070] Figure 3 For a schematic flowchart of a magnetic ruler detection method provided in another embodiment of this application, please refer to... Figure 3 Furthermore, based on the above embodiments, the acquisition of the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal according to the preset demodulation algorithm and the pure magnetic induction signal may include: S301. Perform Hilbert transformation processing on the above-mentioned pure magnetic induction signal to obtain the analytical signal corresponding to the above-mentioned pure magnetic induction signal.
[0071] For example, if The pure magnetic induction signal corresponding to time is represented as Therefore, the Hilbert transformation processing of the pure magnetic induction signal described above can be expressed as:
[0072] Among them, the above Pure magnetic induction signal processed by Hilbert transformation The above This represents the Hilbert transform operator, indicating that the signal within the parentheses is subjected to the Hilbert transform. Let be the principal value of the Cauchy integral, and denote the principal value of the Cauchy integral. Let be the kernel function, representing the convolutional form of the Hilbert transform. This is the normalization coefficient.
[0073] Based on this, the analytical signal corresponding to the pure magnetic induction signal can be obtained as follows:
[0074] Among them, the above That is, an analytical signal. It is the imaginary unit.
[0075] S302. Extract the corresponding instantaneous amplitude modulation signal and instantaneous phase from the above-analyzed signal.
[0076] Based on the above, the extracted instantaneous amplitude modulation signal can be represented, for example, as:
[0077] Among them, the above That is The instantaneous amplitude modulation signal corresponding to the given moment.
[0078] The extracted instantaneous phase can be represented, for example, as:
[0079] Among them, the above That is The instantaneous phase corresponding to a given moment.
[0080] S303. Calculate and obtain the instantaneous frequency modulation signal based on the time derivative of the instantaneous phase.
[0081] For example, the instantaneous frequency modulation signal can be calculated and obtained based on the time derivative of the instantaneous phase, for instance, using the following formula:
[0082] Among them, the above That is The instantaneous frequency modulation signal corresponding to the given moment.
[0083] Of course, the above is only one possible example. The actual representation of the pure magnetic induction signal after Hilbert transformation, the actual representation or calculation of the instantaneous amplitude modulation signal, instantaneous phase, and instantaneous frequency modulation signal, etc., may be the same as or different from the content in the above example, and are not limited to the form in the above example.
[0084] Optionally, in the foregoing Figure 2 Based on the embodiments, the above-mentioned method of obtaining the intrinsic amplitude signal from the instantaneous amplitude modulation signal includes: The edge effect data segments in the above instantaneous amplitude modulation signal are removed to obtain the effective amplitude modulation signal.
[0085] Based on the effective amplitude modulation signal and a preset coefficient of variation algorithm, the coefficient of variation corresponding to the effective amplitude modulation signal is calculated and obtained. The coefficient of variation is used to characterize the intrinsic amplitude signal.
[0086] For example, in the aforementioned instantaneous amplitude modulation signal, data segments located near the start and end positions of the signal may be affected by edge effects. For instance, near the start and end positions of the magnetic pole array of the circular magnetic grating ruler under test, incomplete magnetic pole distribution or edge leakage magnetic flux may cause distortion or abnormal fluctuations in the instantaneous amplitude modulation signal in that area. If these edge-effect-affected data segments are directly used for subsequent calculations, it may interfere with the accuracy of the calculation results. Therefore, the controller can first perform data filtering on the aforementioned instantaneous amplitude modulation signal, identify and remove the data segments affected by edge effects, and obtain the aforementioned effective amplitude modulation signal that can truly reflect the fluctuation characteristics of the magnetic pole magnetization intensity. The specific filtering rules and filtering scales can be adjusted and determined according to the actual situation, and are not limited here.
[0087] Because the uniformity of the magnetization intensity and the consistency of the pole spacing of a circular magnetic grating ruler are directly and intrinsically related to the concentration and stability of the instantaneous frequency and instantaneous amplitude sequence: the better the uniformity of the magnetization and the consistency of the spacing, the higher the concentration and the stronger the stability of the instantaneous frequency and instantaneous amplitude sequence. Therefore, after acquiring the above-mentioned effective amplitude modulation signal, the controller can use this signal in conjunction with a preset coefficient of variation algorithm to calculate the coefficient of variation corresponding to the effective amplitude modulation signal, thereby characterizing the intrinsic amplitude signal and eliminating the overall scaling effect of the detection gap change on the signal amplitude. The preset coefficient of variation algorithm can be expressed as follows:
[0088] Among them, the above That is, the coefficient of variation corresponding to the above effective amplitude modulation signal, the above The standard deviation of the data sequence of the above effective amplitude modulation signal is given by the above. The mean of the data sequence of the above effective amplitude modulation signal.
[0089] The above calculation of the coefficient of variation is based on the effective amplitude modulation signal and a preset coefficient of variation algorithm. This is achieved by ratioing the standard deviation of the instantaneous amplitude to the mean of the corresponding sequence. This offsets the overall amplitude attenuation caused by the measurement distance, ensuring that the calculated instantaneous amplitude coefficient of variation no longer changes regularly with the measurement distance. This allows for the acquisition of a distance-independent intrinsic characteristic parameter. It can effectively eliminate the interference caused by the difference between data dimensions and overall level. Compared with indicators such as single standard deviation, it is more suitable for objectively comparing the dispersion of sequences under different measurement conditions, further improving the consistency and standardization of parameter characterization system, and finally achieving accurate and unbiased quantitative characterization of the uniformity of magnetic pole magnetization intensity and the uniformity of magnetic pole distribution spacing of circular magnetic grating ruler. It is an ideal indicator for characterizing the intrinsic magnetic pole characteristics (i.e., intrinsic amplitude signal) of magnetic grating ruler.
[0090] Optionally, due to inherent defects such as installation eccentricity, geometric errors, and uneven magnetic pole distribution of the magnetic scale during the testing process, periodic disturbances will occur with rotation. These disturbances directly generate low-frequency interference at the frequency conversion and its harmonics. Furthermore, they couple to both sides of the magnetic scale carrier through amplitude modulation, generating parasitic sideband components related to defects such as uneven magnetization of the magnetic poles, magnetic pole spacing deviation, and magnetic field modulation components. These parasitic sideband components will fall within the initial bandpass filter. Within the retention range, the interference cannot be effectively suppressed in the process of "filtering the original magnetic induction signal according to the carrier frequency to obtain a pure magnetic induction signal" and will be included in the pure magnetic induction signal, entering the Hilbert transformation process in step S301. After the Hilbert transformation, the rotating harmonic interference originally located in the high-frequency sideband will be mapped to the low-frequency envelope, superimposed on the real amplitude modulation characteristics caused by defects such as uneven magnetization of magnetic poles, magnetic pole spacing deviation, and magnetic field modulation components. That is, it interferes with the analytical signal corresponding to the pure magnetic induction signal, causing envelope waveform distortion and baseline fluctuation, which seriously affects the accuracy and stability of subsequent defect feature extraction.
[0091] Therefore, before step S301 above, that is, before performing Hilbert transform processing on the pure magnetic induction signal to obtain the analytical signal corresponding to the pure magnetic induction signal, in order to separate the modulation information related to defects such as uneven magnetization of magnetic poles, magnetic pole spacing deviation, and magnetic field modulation components, and to suppress residual coupling interference, the method may further include: The pure magnetic induction signal is subjected to secondary filtering based on a preset low-pass cutoff frequency to obtain a secondary pure magnetic induction signal.
[0092] The above-mentioned Hilbert transform processing of the pure magnetic induction signal to obtain the corresponding analytical signal may include: The Hilbert transform of the above-mentioned pure magnetic induction signal is performed to obtain the analytical signal corresponding to the pure magnetic induction signal.
[0093] For example, the above-mentioned secondary filtering process on the pure magnetic induction signal can refer to the use of a zero-phase low-pass filter to purify the pure magnetic induction signal at the set low-pass cutoff frequency. From a physical mechanism perspective, the magnetic field modulation energy induced by defects such as uneven magnetization of the magnetic poles, deviation in pole spacing, and magnetic field modulation components of the magnetic grating ruler is concentrated in the range of 1~3. Therefore, the aforementioned preset low-pass cutoff frequency can be set to, for example, 4~5. However, this is not a limitation; adjustments can be made based on the actual situation.
[0094] The aforementioned design of the secondary filtering process not only fully covers all effective fault modulation frequencies and reserves a safety margin to avoid truncation of weak features, but also filters out high-frequency artifacts, sensor noise, and high-order parasitic harmonics that were not successfully removed during the "filtering of the original magnetic induction signal according to the carrier frequency" process introduced during Hilbert transformation processing. This maximizes the reduction of background interference while preserving defect-sensitive components. By combining the two stages of differentiated filtering, a layered noise reduction effect of "high-frequency sideband screening - low-frequency envelope purification" is achieved, significantly improving the purity of the amplitude modulation signal (i.e., the purity of the secondary pure magnetic induction signal compared to the pure magnetic induction signal), providing high-fidelity basic data for the subsequent quantitative characterization of the magnetic grating's operating state and defect characteristics.
[0095] In addition, in the aforementioned Figure 2 Based on the embodiments, the above-mentioned determination of the magnetic pole characteristic characterization parameters of the circular magnetic grating ruler under test according to the intrinsic amplitude signal and the instantaneous frequency modulation signal includes: The first statistical feature of the aforementioned intrinsic amplitude signal is extracted and used as the first characterization parameter to characterize the uniformity of magnetic pole magnetization intensity.
[0096] The second statistical feature of the instantaneous frequency modulation signal is extracted and used as the second characterization parameter to characterize the consistency of the magnetic pole distribution spacing.
[0097] For example, the intrinsic amplitude signal described above reflects the relative fluctuation characteristics of the magnetic pole magnetization intensity. The degree of fluctuation is directly related to the spatial uniformity of the magnetic pole magnetization intensity—when the uniformity of the magnetic pole magnetization intensity is good, the fluctuation amplitude of the intrinsic amplitude signal is small. When the uniformity of the magnetic pole magnetization intensity is poor, the fluctuation amplitude of the intrinsic amplitude signal is large. Therefore, the controller can extract the statistical characteristics (e.g., standard deviation, variance, peak-to-peak value, etc.) of the intrinsic amplitude signal as the first statistical characteristic. The magnitude of this first statistical characteristic can be used to quantitatively characterize the uniformity of the magnetic pole magnetization intensity. The smaller the value of the first statistical characteristic, the more uniform the magnetic pole magnetization intensity. Conversely, a larger value indicates significant fluctuations in the magnetization intensity.
[0098] Similarly, the instantaneous frequency modulation signal reflects the deviation of the actual magnetic pole spacing from the theoretical design value. Its fluctuation is directly related to the consistency of the magnetic pole spacing—when the magnetic pole spacing consistency is good, the fluctuation amplitude of the instantaneous frequency modulation signal is small. When the magnetic pole spacing consistency is poor, the fluctuation amplitude of the instantaneous frequency modulation signal is large. Therefore, the controller can extract the statistical characteristics (e.g., standard deviation, variance, peak-to-peak value, etc.) of the instantaneous frequency modulation signal as the second statistical characteristic. The magnitude of this second statistical characteristic can be used to quantitatively characterize the consistency of the magnetic pole spacing. The smaller the value of the second statistical characteristic, the more consistent the magnetic pole spacing. Conversely, a larger value indicates a significant spacing deviation.
[0099] The controller described above can output the extracted first and second characterization parameters as the magnetic pole characteristic characterization parameters of the circular magnetic scale under test. These parameters can be displayed on a human-machine interface for operator viewing or stored in a database for product quality traceability. They can also serve as input data for subsequent error compensation algorithms or production process optimization, guiding improvements in the magnetic scale manufacturing process. It is understood that the specific selection of the first and second statistical characteristics is not limited to standard deviation; other statistical measures, such as coefficient of variation and root mean square error, can be used according to actual testing needs. The specific applications of the magnetic pole characteristic characterization parameters are not limited to the examples given above and are not restricted here.
[0100] Figure 4 A schematic flowchart of a magnetic ruler detection method provided in another embodiment of this application is shown below. Figure 4 As shown above, in the aforementioned Figure 2 Based on the embodiments, in response to the detection command, the method further includes controlling the turntable to drive the two-dimensional translation stage to rotate at a constant speed, so that the two-dimensional translation stage drives the circular magnetic scale to be measured to rotate at a constant speed. S401. Collect the distance signal between the laser displacement sensor and the above-mentioned circular magnetic scale to be measured.
[0101] For example, during the process of the turntable driving the circular magnetic scale under test to rotate at a constant speed, the controller can synchronously control the laser displacement sensor to start distance measurement. The laser displacement sensor continuously emits a laser beam towards the side of the circular magnetic scale under test at a preset sampling frequency, and receives the reflected light signal. The built-in signal processing circuit converts the light signal into an electrical signal proportional to the distance, generating a real-time distance signal, and transmits the distance signal to the controller through a communication connection.
[0102] S402. Based on the distance signal mentioned above, determine the eccentricity information of the circular magnetic scale to be measured.
[0103] For example, after receiving the distance signal, the controller can analyze it. When the geometric center of the circular magnetic scale under test is eccentric to the rotation center of the turntable, the distance signal will exhibit periodic fluctuation characteristics. The controller can determine the eccentricity (i.e., the magnitude of the eccentricity) and the eccentricity direction (i.e., the direction of deviation) between the geometric center of the circular magnetic scale under test and the rotation center of the turntable by analyzing the waveform characteristics of the distance signal (e.g., detecting the peaks and troughs of the signal, calculating the signal amplitude, fitting the waveform curve, etc.), as the eccentricity information.
[0104] S403. Based on the above eccentricity information, calibrate the above-mentioned circular magnetic scale to be tested.
[0105] For example, after acquiring the aforementioned eccentricity information, the controller can generate a position correction command based on the eccentricity distance and direction, and send the correction command to the two-dimensional translation stage. Responding to the correction command, the two-dimensional translation stage precisely moves along its X-axis and / or Y-axis, adjusting the position of the circular magnetic scale under test in the horizontal plane to gradually reduce the eccentricity. During the calibration process, the controller continuously receives the distance signal fed back by the laser displacement sensor, monitors the change in eccentricity in real time, and forms a closed-loop control until the distance signal meets a preset alignment condition (e.g., the fluctuation amplitude of the distance signal is less than a preset threshold). Through the above calibration steps, precise alignment between the geometric center of the circular magnetic scale under test and the rotation center of the turntable can be achieved, eliminating eccentricity error interference for subsequent magnetic signal acquisition.
[0106] Of course, the above is just one possible example. The actual types of laser displacement sensors, performance parameters, working methods, and calibration procedures can be adjusted according to the actual situation.
[0107] Figure 5 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. The electronic device can be, but is not limited to, the aforementioned industrial computer, embedded controller, programmable logic controller, or other devices with data processing and control instruction output functions. Figure 5 As shown, the device 500 includes: The processor 510, storage medium 520, and bus 530 are connected in communication via bus 530.
[0108] The storage medium 520 stores machine-readable instructions that can be executed by the processor 510. When the electronic device is running, the processor 510 executes the machine-readable instructions to perform the magnetic ruler detection method.
[0109] It should be understood that, Figure 5 The structure shown is only a schematic diagram of an electronic device; the electronic device may also include components that are larger than those shown. Figure 5 The more or fewer components shown, or having the same Figure 5 The different configurations shown. Figure 5 The components shown can be implemented using hardware, software, or a combination thereof.
[0110] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the magnetic scale detection method described in the above method embodiments.
[0111] Computer-readable storage media can be electronic storage devices such as flash memory, EEPROM (Electrically Erasable Programmable Read-Only Memory), EPROM, hard disk, or ROM. Optionally, computer-readable storage media includes non-transitory computer-readable storage medium. The computer-readable storage medium has storage space for program code that performs any of the method steps described above. This program code can be read from or written to one or more computer program exhibits. The program code can be compressed, for example, in a suitable form.
[0112] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can also be implemented in other ways. The apparatus embodiments described above are merely illustrative. For example, the flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods, and computer program exhibits according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code, which contains one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions marked in the blocks may occur in a different order than those marked in the drawings. For example, two consecutive blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in a block diagram and / or flowchart, and combinations of blocks in block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or action, or using a combination of dedicated hardware and computer instructions.
[0113] In addition, the functional modules in the various embodiments of this application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.
[0114] If the functionality is implemented as a software module and sold or used as an independent exhibit, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software exhibit. This computer software exhibit is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0115] The above description is merely a preferred embodiment of this application and does not limit the patent scope of this application. Any equivalent structural transformations made based on the inventive concept of this application and the contents of the specification and drawings of this application, or direct / indirect applications in other related technical fields, are included within the patent protection scope of this application.
Claims
1. A method for detecting magnetic scales, characterized in that, A controller applied to a magnetic scale detection device, the method comprising: In response to the detection command, the turntable is controlled to drive the two-dimensional translation stage to rotate at a constant speed, so that the two-dimensional translation stage drives the circular magnetic scale under test to rotate at a constant speed, and the original magnetic induction signal obtained by the TMR reading head reading the circular magnetic scale under test at the target detection position is acquired. Based on the original magnetic induction signal, the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal are obtained; Based on the instantaneous amplitude modulation signal, the intrinsic amplitude signal is obtained; Based on the intrinsic amplitude signal and the instantaneous frequency modulation signal, the magnetic pole characteristic characterization parameters of the circular magnetic scale under test are determined.
2. The magnetic scale detection method according to claim 1, characterized in that, Before obtaining the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal based on the original magnetic induction signal, the method further includes: Frequency domain analysis was performed on the original magnetic induction signal to obtain the carrier frequency corresponding to the main peak of the signal spectrum; The original magnetic induction signal is filtered according to the carrier frequency to obtain a pure magnetic induction signal; The step of obtaining the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal based on the original magnetic induction signal includes: Based on the preset demodulation algorithm and the pure magnetic induction signal, the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal are obtained.
3. The magnetic scale detection method according to claim 2, characterized in that, The step of obtaining the instantaneous amplitude modulation signal and the instantaneous frequency modulation signal according to the preset demodulation algorithm and the pure magnetic induction signal includes: The pure magnetic induction signal is subjected to Hilbert transform processing to obtain the analytical signal corresponding to the pure magnetic induction signal; Extract the corresponding instantaneous amplitude modulation signal and instantaneous phase from the analyzed signal; The instantaneous frequency modulation signal is calculated based on the time derivative of the instantaneous phase.
4. The magnetic scale detection method according to claim 1, characterized in that, The step of obtaining the intrinsic amplitude signal based on the instantaneous amplitude modulation signal includes: Edge effect data segments in the instantaneous amplitude modulation signal are removed to obtain the effective amplitude modulation signal; Based on the effective amplitude modulation signal and a preset coefficient of variation algorithm, the coefficient of variation corresponding to the effective amplitude modulation signal is calculated and obtained. The coefficient of variation is used to characterize the intrinsic amplitude signal.
5. The magnetic scale detection method according to claim 1, characterized in that, The step of determining the magnetic pole characteristic characterization parameters of the circular magnetic scale under test based on the intrinsic amplitude signal and the instantaneous frequency modulation signal includes: The first statistical feature of the intrinsic amplitude signal is extracted and used as the first characterization parameter to characterize the uniformity of the magnetic pole magnetization intensity. The second statistical feature of the instantaneous frequency modulation signal is extracted as a second characterization parameter to characterize the consistency of the magnetic pole distribution spacing.
6. The magnetic scale detection method according to claim 1, characterized in that, In response to a detection command, the method further includes controlling the turntable to drive the two-dimensional translation stage to rotate at a constant speed, so that the two-dimensional translation stage drives the circular magnetic scale to be measured to rotate at a constant speed. Collect the distance signal between the laser displacement sensor and the circular magnetic scale to be measured; Based on the distance signal, determine the eccentricity information of the circular magnetic scale to be measured; The circular magnetic scale to be tested is calibrated based on the eccentricity information.
7. A magnetic scale detection device, characterized in that, include: Two-dimensional translation stage (101), turntable (102), three-axis displacement stage (103), TMR reading head (104), controller; The two-dimensional translation stage (101) is disposed on the rotating platform (1021) of the turntable (102). The two-dimensional translation stage (101) is used to drive the circular magnetic scale (105) to be tested to move on a preset two-dimensional plane. The three-axis displacement stage (103) is disposed on the side of the turntable (102). The TMR reading head (104) is disposed on the moving end of the three-axis displacement stage (103). The detection end of the TMR reading head (104) faces the side of the scale body of the circular magnetic scale (105) to be tested. The three-axis displacement stage (103) is used to adjust the spatial position of the TMR reading head (104) so that the TMR reading head (104) is at the target detection position of the circular magnetic scale (105) to be tested. The turntable (102), the two-dimensional translation stage (101), the three-axis displacement stage (103), and the TMR reading head (104) are all communicatively connected to the controller; The controller is used to perform the steps of the method as described in any one of claims 1-6.
8. The magnetic scale detection device according to claim 7, characterized in that, The magnetic scale detection device further includes a laser displacement sensor (106), which is fixedly disposed on the side of the turntable (102), and the detection surface of the laser displacement sensor (106) faces the side of the scale body of the circular magnetic scale (105) to be tested. The laser displacement sensor (106) is communicatively connected to the controller.
9. The magnetic scale detection device according to claim 7, characterized in that, The two-dimensional translation stage (101) includes a fixed structure (1011) and a translation structure (1012). The bottom surface of the translation structure (1012) is disposed on the rotating platform (1021) of the turntable (102). The fixed structure (1011) is disposed on the top surface of the translation structure (1012). The fixed structure (1011) is used to fix the circular magnetic scale (105) to be measured.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, performs the steps of the method as described in any one of claims 1-6.