Periodic anomaly detection method for discrete equipment servo motor
By performing periodic analysis and feature alignment on the phase current signal of the servo motor, combined with Z-score and Euclidean distance detection, the problem of non-steady-state signal processing in the detection of servo motors for low- and medium-value discrete equipment is solved. This achieves low-cost, highly robust anomaly detection, improving detection accuracy and scalability.
Patent Information
- Application Number
- CN202511089335.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-05
- Publication Date
- 2025-11-21
AI Technical Summary
Existing technologies for servo motor detection in low- to medium-value discrete equipment suffer from problems such as non-steady-state signal processing failure, high cost, insufficient scalability, and a contradiction between real-time performance and robustness, making it difficult to achieve low-cost, highly robust periodic anomaly detection.
By acquiring the effective value of phase current in real time from the servo driver and combining it with the PLC period boundary marker signal, period analysis and feature alignment are performed. Time alignment is performed using linear interpolation or dynamic time warping. Anomalies are detected using Z-score and Euclidean distance, supporting independent modeling and real-time detection of multiple motors.
It achieves low-cost, highly robust servo motor anomaly detection, improves detection accuracy, reduces false negative rate, supports parallel detection of multiple motors, allows model updates without downtime, reduces hardware costs, and shortens response time.
Smart Images

Figure CN120993191A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of automation equipment, specifically relating to a method for detecting periodic anomalies in servo motors of discrete equipment. Background Technology
[0002] In discrete manufacturing, such as high-end gift box forming machines in the packaging industry, the core drive component, the servo motor, often operates under unsteady conditions with frequent start-stop and periodic reversal (start-stop-reverse cycle frequency reaches 7-12 times / minute). Existing equipment fault detection technologies mainly focus on steady-state signal detection for high-value equipment (such as wind power, nuclear power, and aero engines), often employing vibration sensors combined with FFT spectrum analysis and wavelet transform. These technologies are less commonly used in fault detection for low- to medium-value discrete equipment and suffer from the following drawbacks: 1. Failure of non-steady-state signal processing: Traditional methods rely on the assumption of steady-state signal. For servo motor current signals with period fluctuations of more than ±15% (such as the current peak value reaching 3 times the rated value during startup), they cannot effectively extract time-varying features, resulting in a false negative rate of more than 30%.
[0003] 2. Insufficient cost and scalability: High-cost vibration sensors are difficult to deploy on multi-motor production lines (a single device contains 8-12 servo motors), and existing algorithms are mostly global models, so adding a motor requires retraining, resulting in high system expansion costs.
[0004] 3. Conflict between real-time performance and robustness: Industrial sites require fast fault response time, but existing machine learning methods have high computational latency in high-frequency acquisition scenarios (about 10ms / time), such as dynamic time warping (DTW), which cannot meet the real-time requirements. Summary of the Invention
[0005] The technical problem to be solved by this invention is to provide a low-cost and robust method for detecting periodic anomalies in servo motors of low- to medium-value discrete equipment, solve the problem of feature extraction under unsteady conditions, and realize independent modeling and real-time anomaly detection of multiple motors.
[0006] To solve the above problems, the present invention is achieved through the following technical solution: A method for detecting periodic anomalies in servo motors of discrete devices includes the following steps: Step 1, Data Acquisition and Preprocessing: Real-time acquisition of the effective value of the phase current from the servo driver at a sampling frequency of 100Hz, and simultaneous acquisition of the period boundary marker signal output by the PLC; Step 2, Period Analysis: The period is automatically divided based on the period boundary marker signal, and then the average duration μ of the historical periods is calculated. T and historical periodic standard deviation σ T Elimination time not in [μ T−3σ T μ T +3σ T Abnormal cycles within the range; Step 3, Periodic Feature Alignment: For the current signal of each effective period, align the time of the current signal to ensure that the features are comparable; Step 4: Perform real-time single-point anomaly detection and periodic anomaly detection.
[0007] In step 3, periodic feature alignment is performed using linear interpolation, cubic spline interpolation, or dynamic time warping (DTW).
[0008] The linear interpolation method is as follows: Based on linear interpolation, the collected values are converted from the original duration T. raw Align to standard duration T norm Generate a sequence x of equal length aligned (t), enabling flexible alignment of the time series, and using linear interpolation to unify periodic signals of different durations into a fixed number of points, formula: x aligned (t)=interpolate(x raw (t i ),t i ∈[0,T raw ],t∈[0,T norm ]); where x raw This is a linear interpolation.
[0009] The real-time single-point anomaly detection includes the following steps: Step (1): For each collection point x(t), calculate its value compared to the historical normal data mean μ. norm and the standard deviation σ of historical normal data norm ; Step (2): Calculate the Z-score for each sampling point, based on the 3σ principle for Z-score detection, formula: Z(t) = (x(t) - μ) norm )) / σ norm ; Step (3): When the calculated Z score exceeds the threshold, a real-time alarm is triggered.
[0010] The periodic anomaly detection includes the following steps: Step a: Extract 8-dimensional statistical features, normalize the 8-dimensional features, and construct a periodic feature vector f=[f1,f2,…,f8]; Step b: Calculate the Euclidean distance between the current cycle and the historical normal cycle eigenvectors. If the actual Euclidean distance d > λ⋅mean(d) normal If λ is the confidence coefficient, then it is determined to be a periodic anomaly. normal This is the normal Euclidean distance.
[0011] The eight statistical features include mean, standard deviation, maximum value, minimum value, area of integration, skewness, kurtosis, and waveform factor.
[0012] Compared with the prior art, the present invention has the following beneficial effects: 1. Cost advantage: Relying only on the servo driver's built-in current sensor and PLC periodic signal, the hardware cost is lower than that of traditional solutions; 2. Detection performance: Under load fluctuations and noise injection of 5%, the detection accuracy remains above 85%, and the false negative rate is reduced to below 5%. 3. Engineering Adaptability: Supports parallel detection of multiple motors (8-12 motors can be processed concurrently on a single device without blocking), model updates do not require downtime, and the industrial field deployment cycle is shortened to less than 2 hours. Attached Figure Description
[0013] Figure 1 This is a system architecture diagram of the present invention; Figure 2 This is a flowchart of the present invention; Figure 3 This is a logic diagram of a multi-layered detection mechanism (hierarchical response process). Detailed Implementation
[0014] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0015] In the description of this invention, it should be understood that the terms "upper", "lower", "front", "rear", "left", "right", "top", "bottom", "inner", "outer", etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. They are only for the convenience of describing this invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on this invention.
[0016] like Figure 1 , Figure 2 As shown, the method for detecting periodic anomalies in servo motors of discrete equipment includes the following steps: Step 1: Data Acquisition and Preprocessing: Real-time acquisition of the effective value of the phase current from the servo driver at a sampling frequency of 100Hz, and synchronous acquisition of the period boundary marker signal output by the PLC, where 0 indicates non-periodicity and 1 indicates the start of the period.
[0017] Step 2, Period Analysis: The period is automatically divided based on the period boundary marker signal, and then the average duration μ of the historical periods is calculated. T and historical periodic standard deviation σ T Elimination time not in [μ T −3σ T μ T +3σ T Abnormal cycles within the specified range. Thus, this invention filters abnormal cycles, eliminating those whose duration deviates from the mean by ±30%. Step 3, Periodic Feature Alignment: Since the effective value of the acquired phase current may be in different period durations, the current signal of each effective period is time-aligned to ensure that the features can be compared.
[0018] Better yet, periodic feature alignment can be achieved using linear interpolation, cubic spline interpolation, or dynamic time warping (DTW), which is suitable for extreme conditions with larger fluctuations in period duration (such as ±30% or more), but has higher computational complexity.
[0019] The linear interpolation method of this invention is as follows: based on linear interpolation, the collected values are converted from the original duration T... raw Align to standard duration T norm (e.g., 8500ms) Generate a sequence x of equal length. aligned (t), enabling flexible alignment of the time series, and using linear interpolation to unify periodic signals of different durations to a fixed number of points (e.g., 1000 points / period), formula: x aligned (t)=interpolate(x raw (t i ),t i ∈[0,T raw ],t∈[0,T norm ]); where x raw This is a linear interpolation.
[0020] Step 4: Perform real-time single-point anomaly detection and periodic anomaly detection; The real-time single-point anomaly detection includes the following steps: Step (1): For each collection point x(t), calculate its value compared to the historical normal data mean μ. norm and the standard deviation σ of historical normal data norm ; Step (2): Calculate the Z-score for each sampling point, based on the 3σ principle for Z-score detection, formula: Z(t) = (x(t) - μ) norm )) / σ norm ; Step (3): When the calculated Z score exceeds the threshold, a real-time alarm is triggered to capture sudden faults such as instantaneous overcurrent. Better yet, here the threshold |Z(t)|>3 triggers a real-time alarm, marks sudden anomalies, and has a faster response time.
[0021] The periodic anomaly detection includes the following steps: Step a: Extract 8-dimensional statistical features, including mean, standard deviation, maximum value, minimum value, area of integral, skewness, kurtosis and waveform factor, normalize the 8-dimensional features, and construct a periodic feature vector f=[f1,f2,…,f8]; Step b: Calculate the Euclidean distance between the current cycle and the historical normal cycle eigenvectors. If the actual Euclidean distance d > λ⋅mean(d) normal If the condition is not met, it is considered a periodic anomaly, used to identify progressive faults such as gearbox wear and driver communication abnormalities. Here, λ is the confidence coefficient, taken as 1.5, and d... normal This is the normal Euclidean distance.
[0022] Better yet, an anomaly is determined when the actual Euclidean distance d is greater than ||f−fnorm||2.
[0023] It should be noted that the anomaly detection in step b can also introduce machine learning models (such as Isolation Forest or One-Class SVM) to replace Euclidean distance calculation, thereby improving the detection capability for non-Gaussian distributed data and making it suitable for complex fault scenarios.
[0024] In this invention, multiple sensors are installed on the servo driver, allowing for the generation of an independent model file for each motor, supporting hot-swappable deployment. It also enables independent modeling of multiple motors and cross-platform interaction. When modeling multiple motors independently, an independent model file (e.g., model_5086_phase_current.pkl) is generated based on the motor address (e.g., 5086, 5087) and parameters, reducing the deployment cost of new motors by 40%. For real-time cross-platform interaction, a WebAPI is built using Flask, with the C# client transmitting data in JSON format (main fields include address, values, cycle, and time). This results in fast server response time and solves the problem of multi-language collaboration in industrial control systems.
[0025] Real-time communication: An HTTP API is used to enable interaction between C# and Python, defining a standardized JSON data format (example: [{"PLCName": "Demolding Shaft","parameters":[{"name": "Effective Phase Current", "address": 5006,"data": [{"values": [0.5],"time": 1690000000000},{ "values":[0.5],"time": 1690000000000,cycle:0}]} ]}, / / Other motor data]). After receiving the data, the server asynchronously processes periodic detection tasks to avoid real-time data blocking.
[0026] Edge computing adaptation: To address the resource limitations of PLC controllers, the core algorithms (cycle alignment, feature extraction) are rewritten in C language and deployed on edge nodes, reducing single-cycle processing time and meeting real-time requirements.
[0027] Human-machine interface: The HMI interface displays the periodic characteristic curves of each motor in real time (such as mean trend and Euclidean distance change), allowing engineers to quickly locate faulty motors through a visual interface.
[0028] Multimodal fusion: In the future, vibration signals and temperature sensor data can be fused to further improve detection accuracy through feature-level fusion (such as serial multimodal feature vectors) or decision-level fusion (such as voting mechanisms).
[0029] The above description is only a preferred embodiment of the present invention. It should be noted that those skilled in the art can make several changes and improvements without departing from the overall concept of the present invention, and these should also be considered within the scope of protection of the present invention.
Claims
1. A method for detecting periodic anomalies in servo motors of discrete equipment, characterized in that, Includes the following steps: Step 1, Data Acquisition and Preprocessing: Real-time acquisition of the effective value of the phase current from the servo driver at a sampling frequency of 100Hz, and simultaneous acquisition of the period boundary marker signal output by the PLC; Step 2, Period Analysis: The period is automatically divided based on the period boundary marker signal, and then the average duration μ of the historical periods is calculated. T and historical periodic standard deviation σ T Elimination time not in [μ T −3σ T μ T +3σ T Abnormal cycles within the range; Step 3, Periodic Feature Alignment: For the current signal of each effective period, align the time of the current signal to ensure that the features are comparable; Step 4: Perform real-time single-point anomaly detection and periodic anomaly detection.
2. The method for detecting periodic anomalies in servo motors of discrete equipment according to claim 1, characterized in that: In step 3, periodic feature alignment is performed using linear interpolation, cubic spline interpolation, or dynamic time warping (DTW).
3. The method for detecting periodic anomalies in servo motors of discrete equipment according to claim 2, characterized in that: The linear interpolation method is as follows: Based on linear interpolation, the collected values are converted from the original duration T. raw Align to standard duration T norm Generate a sequence of equal length x aligned (t), enabling flexible alignment of the time series, and using linear interpolation to unify periodic signals of different durations into a fixed number of points, formula: x aligned (t)=interpolate(x raw (t i ),t i ∈[0,T raw ],t∈[0,T norm ]); where x raw This is a linear interpolation.
4. The method for detecting periodic anomalies in servo motors of discrete equipment according to claim 1, characterized in that: The real-time single-point anomaly detection includes the following steps: Step (1): For each collection point x(t), calculate its value compared to the historical normal data mean μ. norm and the standard deviation σ of historical normal data norm ; Step (2): Calculate the Z-score for each sampling point, based on the 3σ principle for Z-score detection, formula: Z(t)=(x (t)−μ norm )) / σ norm ; Step (3): When the calculated Z score exceeds the threshold, a real-time alarm is triggered.
5. The method for detecting periodic anomalies in servo motors of discrete equipment according to claim 1, characterized in that: The periodic anomaly detection includes the following steps: Step a: Extract 8-dimensional statistical features, normalize the 8-dimensional features, and construct a periodic feature vector f=[f1,f2,…,f8]; Step b: Calculate the Euclidean distance between the current cycle and the historical normal cycle eigenvectors. If the actual Euclidean distance d > λ⋅mean(d) normal If λ is the confidence coefficient, then it is determined to be a periodic anomaly. normal This is the normal Euclidean distance.
6. The method for detecting periodic anomalies in servo motors of discrete equipment according to claim 1, characterized in that: The eight statistical features include mean, standard deviation, maximum value, minimum value, area of integration, skewness, kurtosis, and waveform factor.