Abstract
This paper proposes a low-complexity, fast sensorless collision detection method for permanent-magnet synchronous motors (PMSMs) based on a forgetting-factor recursive least-squares (FFRLS) estimator. The method estimates the load torque from the motor motion equations and detects collisions by monitoring abrupt changes in a processed load-torque metric. The algorithm is tailored for resource-constrained embedded controllers: it avoids high-order matrix operations and the use of external sensors while achieving rapid detection. Experimental results under constant speed, acceleration, and time-varying load conditions demonstrate fast and repeatable detection performance. The approach provides a practical trade-off between computational cost and detection reliability for embedded motor drives.
Keywords: Sensorless collision detection, PMSM, FFRLS, Load torque identifier
Subject terms: Engineering, Mathematics and computing
Introduction
Permanent magnet synchronous motors (PMSMs) provide multiple pole pairs, enabling high torque density while maintaining a low overall mass. With the advances in permanent magnet materials, power electronics, and position sensing technologies, the performance of PMSMs has been continuously improved. Nonlinearity, coupling, and multivariable dynamics are typical features of PMSMs, and their control systems are prone to disturbances–including external disturbances and internal parameter variations. As PMSMs gain widespread application in robotics, electric vehicles, and industrial automation, research interest in sensorless collision detection for PMSMs has grown rapidly–particularly for collaborative robots1.
In recent years, collision detection research has increasingly emphasized sensorless approaches. Such methods aim to reduce the added cost and complexity associated with physical sensors while enhancing overall system robustness. For robotic arms, classical studies on collision detection traditionally begin with robot kinematics and dynamics: collisions are treated as fault behaviors of the drive system, and detection is achieved using actuator fault detection and isolation (FDI) techniques2. However, this approach may fail to detect transient collisions occurring over very short time intervals. In addition, some works employ the modified extended state observer (MESO) to provide a natural and efficient framework for collision detection and identification in robot systems–without requiring joint acceleration estimation or inversion of the inertia matrix. Compared with the well-established generalized momentum-based (GM) method, MESO yields more accurate collision force estimates under comparable noise levels in practice, albeit at the cost of a slightly higher computational load and increased observation delay3. Under a similar paradigm, high-order sliding mode observers4 and generalized momentum-based observers5 have also demonstrated strong performance in estimating joint motor load torque; however, their model construction processes remain relatively complex. Other studies achieve collision detection, impact point localization, and classification of collision nature—using either classical analytical methods or neural-network-based learning approaches6—though these typically demand substantial computing resources from the host computer.
A more concise alternative focuses directly on the joint drive motors of robots, inferring collision risk by analyzing motor current7. A collision is flagged upon detecting a sudden change in current; yet in practice, current-based methods suffer from poor accuracy due to measurement noise. Regardless of the specific technique employed, sensorless strategies share a common simplifying assumption: approximating the load torque as the motor’s electromagnetic torque. While this approximation streamlines implementation, it introduces modeling error. To address this limitation, certain studies adopt the model reference adaptive system (MRAS) to identify key parameters and construct a load torque observer using the Kalman filter—starting with estimation of load torque variations8. This improves fidelity over the electromagnetic-torque approximation, but the resulting algorithm involves multi-step iterative computations, rendering it unsuitable for low-cost, resource-constrained motor controllers.
In summary, although existing sensorless collision detection methods offer notable accuracy benefits, they face practical challenges in broader PMSM applications—such as conventional motion control scenarios in industrial automation, conveyor systems, and cost-sensitive controller deployments. In engineering practice, most robotic motor drives operate under strict cost constraints, relying on embedded controllers with limited word length and processing capability. Under such constraints, large-scale matrix operations, optimization algorithms, and AI-driven methods become infeasible. Hence, there is a clear need for a lightweight, fast response, low-complexity collision detection algorithm. The method proposed in this paper effectively addresses these requirements and is especially well-suited for embedded processors with limited computational resources.
The structure of this paper is as follows: Section “Methods” presents the theoretical foundation; Section “Experiments” details the experimental setup and validates the performance advantages of the proposed method; and Section “Conclusions” summarizes the work and outlines directions for future research.
Modeling and collision detection strategy
Mathematical model of the PMSM
For a real-time embedded controller that has a clear sample-time, we usually use a discrete model. The mechanical equation of the PMSM is:
![]() |
1 |
where J is the inertia.
is the mechanical velocity.
is the electromagnetic torque.
is the load torque, which includes the possible collision torque. B is the viscosity coefficient. The complete mechanical model of a PMSM includes Coulomb friction and quadratic friction terms. However, for the purpose of estimator derivation and given the operating speed range considered in this study, a simplified linear viscous-friction model is adopted as shown in (1).
By performing a Laplace transform on (1), we have the following equation 2.
![]() |
2 |
Let the above equation be expressed as:
, then the open-loop pulse transfer function of the mechanical motion equation (2) is as follows:
![]() |
3 |
Performing the
transform on the open-loop pulse transfer function (3) gives:
![]() |
4 |
In addition, the transfer function of the zero-order holder is:
. On the basis of the equivalence principle, the open-loop pulse transfer function with the zero-order holder can be derived as:
![]() |
5 |
Taking the inverse
transform of (5), the corresponding discrete-time difference equation can be written as
![]() |
6 |
In discrete-time systems, the angular velocity increment at time step k is defined as
![]() |
7 |
For sufficiently small sampling periods, the exponential term in (6) can be approximated using a first-order Taylor expansion as
![]() |
8 |
Substituting (8) into (6), rearranging terms, and neglecting higher-order terms yield,
![]() |
9 |
which represents a first-order discrete-time approximation of the exact model in (6) and is equivalent to a forward Euler discretization of the continuous-time mechanical dynamics.
The above equation (9) is adopted for real-time implementation due to its simplicity. It can be rewritten in matrix form:
![]() |
10 |
For most surface-mounted PMSMs, since they lack salient pole characteristics, we can approximately assume that the rotor d-axis inductance is equal to the q-axis inductance in the stationary coordinate system, thus deriving the electromagnetic torque equation9:
![]() |
11 |
Based on the motor’s known physical parameters–including the number of poles P and the armature flux linkage
–and by sampling and transforming the phase currents to obtain the q-axis current
in the rotor-fixed rotating reference frame, the electromagnetic torque can be calculated using the torque equation (11).
Parameter identification using FFRLS
This method employs the forgetting-factor recursive least-squares (FFRLS) algorithm to estimate the load torque. The principle of FFRLS is that the system continuously acquires new data and performs recursive parameter estimation; when the sum of squared errors is minimized, accurate estimation of the target parameters is achieved. FFRLS has been proven to guarantee exponential convergence of the parameter estimation error under the persistence-of-excitation condition and is applicable to multiple-input–multiple-output (MIMO) systems10.
As a mathematical identification method, FFRLS does not impose strict physical constraints; therefore, reducing the dimensionality of the estimated parameter vector generally enhances estimation accuracy. Moreover, it is essential to set physically meaningful bounds on the parameters to be estimated–consistent with the definition and physical range of the corresponding quantity.
Based on the FFRLS algorithm and Equation (10), define the input parameter sequence
, the parameter vector to be estimated
, and the output parameter sequence y(k) as follows:
![]() |
12 |
![]() |
13 |
![]() |
14 |
For (13) we have:
![]() |
15 |
It follows from the physical definition of the moment of inertia that parameter
; furthermore, the physical quantity to be estimated can be calculated from the above equation (15):
![]() |
16 |
The specific iterative update equations of the FFRLS algorithm are as follows:
![]() |
17 |
Here, P(k) denotes the covariance matrix, K(k) the gain vector (or gain matrix), and
the forgetting factor. The value of the forgetting factor must be tuned according to the specific implementation; it is typically chosen within the range
. In each sampling period, substituting Equations (12), (13), and (14) into the FFRLS update equation (17) yields the estimated parameter vector, from which the target physical quantity is then derived. Typically, the algorithm is initialized as follows:
![]() |
18 |
In Equation (18),
is typically chosen as a sufficiently large positive real number, while
is set to a sufficiently small positive real number or zero–yielding improved estimation performance.
Fig. 1.
The parameter vector estimation process based on FFRLS.
Collision detection
In the previous section, the load torque estimate
was obtained. In this work, a collision is detected when
exhibits a sudden change. Under ideal conditions, the forward difference could serve directly as the variation criterion–introducing an algorithmic delay of only two sampling periods. However, in practical embedded systems, various noise sources degrade the reliability of using this raw difference as the variation indicator. To suppress noise, we combine the central difference method with a moving-average filter to estimate abrupt load-torque changes. The discrete-time variation of the estimated load torque, denoted
, is defined as:
![]() |
19 |
Because motors in applications such as robotics and robotic-arm joints frequently alternate between forward and reverse rotation, a speed-dependent correction term is introduced to prevent false positives. Let D(k) denote the evaluation value at discrete time step k. Since the raw metric has small magnitude, a numerical scaling factor
is applied to enhance interpretability and simplify threshold tuning. The expression for D(k) is given by:
![]() |
20 |
The corresponding dynamic thresholds are defined as follows:
![]() |
21 |
where
and
denote the upper and lower threshold values, respectively.
is the base threshold–set to a small positive value that can be tuned according to the motor’s rated torque. The coefficient m quantifies the speed-dependent scaling of the threshold: higher rotational speeds necessitate proportionally larger thresholds. This parameter is application-specific; it is typically set to a relatively small value in high-speed, low-sensitivity applications (e.g., conveyor belts, fans), whereas in low-speed, high-precision scenarios (e.g., robotic arms, robotic-joint drives), a larger m is used to enhance robustness against false positives.
To summarize, the judgment formula for collision detection is as follows:
![]() |
22 |
A transition of the Flag bit from 0 to 1 indicates that a collision has occurred.
Experiments
Introduction to the experimental platform and dataset
The experimental platform comprises the following components: (1) a PMSM (model: 42JSF630AS-1000, equipped with a 1000-line absolute encoder); (2) a DC power supply (model: RIGOL DP711); (3) a PMSM drive system based on a DSP controller (Texas Instruments TMS320F28335PGFA); (4) an elastic coupling; (5) an adjustable magnetic damper; and (6) a serial-to-USB adapter. The adjustable magnetic damper is a permanent-magnet brake that delivers an approximately constant braking torque across a wide speed range. Owing to its speed-independent torque characteristic, the damper is used to impose a stable and repeatable external load torque on the motor shaft. By adjusting the damper setting, various baseline load conditions can be established without modifying the control structure or operating mode of the drive system. See Table 1 for the PMSM’s detailed specifications. The experimental setup is illustrated in Fig. 2.
Table 1.
Motor specification.
| Specifications | Value | Specifications | Value |
|---|---|---|---|
| Phase | 3 | Motor Pole Pairs | 4 |
| Rated DC Voltage | 24 V | PM Flux Linkage | 7.797 Wb |
| Rated Torque | 0.2 N m |
Viscous Damping | 4.37 N ms/rad |
| Rated Power | 64 W | Rotor Inertia | 2.8 kg m2
|
| Rated Current | 4.0 A | Phase Resistance | 0.54
|
| Rated Speed | 3000 r/min | Phase Inductance | 0.62 H
|
Fig. 2.
Experimental platform.
The sampling frequency of the embedded controller is set to 12500 Hz, and it communicates with the host computer via the SCI (Serial Communication Interface) port. Due to hardware limitations of the host computer’s experimental equipment, the real-time serial communication rate is limited to 2500 Hz to prevent loss of synchronization. The motor experimental platform employs a PI-based closed-loop control structure, with the speed loop operating at 2500 Hz. In conjunction with space vector pulse width modulation (SVPWM), the PMSM is driven. All experiments were conducted using a unified cascaded speed–current control architecture. No external torque or current reference was injected during the tests; the q-axis current reference was generated solely by the speed controller based on the speed tracking error.
Through repeated experiments, the algorithm parameters are determined as follows: the forgetting factor
is set to 0.95;
; and
. Based on the magnitude of
in (20), a scaling factor
is adopted to facilitate observation and threshold tuning. Additionally, the window length of the moving average filter applied to the estimated load torque
is set to
, which provides a favorable trade-off between noise suppression and time delay.
The initial value of the speed influence factor m is determined via a speed step-response experiment. After system power-up and initialization, the controller operates until the FFRLS algorithm achieves steady-state convergence. Subsequently, a step command is applied to the speed reference, starting from an initial operating point corresponding to the rated speed. During this transient process, the time interval from the onset of rotor acceleration
to the moment
when the rotational speed reaches the rated value
(within a tolerance of
) is recorded. Concurrently, the evaluation value D(k) is monitored, and its maximum value
within this interval–along with the corresponding time instant
–is extracted. A margin coefficient
is introduced to adjust the sensitivity of collision detection. In this work,
is used, although a practical range of
is recommended. Based on these measurements, the initial value
of the speed influence factor is computed using Equation (23).
![]() |
23 |
The base threshold
is obtained during steady-state operation at rated speed. After the motor has operated at rated speed for a sufficiently long duration, the evaluation value D(k) is monitored over a short time window (typically
). The maximum peak value observed within this interval can be selected as
, representing the basic value of normal operating variations in the absence of external disturbances. The base threshold
also serves as a robustness margin to suppress false detections caused by measurement noise and normal dynamic load variations. In this study, the speed influence factor after amplification is set to
, and the minimum basic threshold
.
Note that, because FFRLS is an estimation algorithm, residual estimation errors may persist even after convergence. However, motor parameters have well-defined physical meanings; therefore, it is essential to impose physically meaningful bounds on the estimated parameters at each iteration in practical implementations. The covariance update P(k) involves computationally expensive matrix operations and is not required in all deployment scenarios. In practice, P(k) is primarily used as a convergence diagnostic during algorithm debugging. In a fully debugged system, the computation of P(k) can be omitted, which enhances the practicality and usability of the proposed method.
Collision test
To verify the effectiveness of the proposed collision detection algorithm, the following experiments were conducted on the experimental platform: (1) constant-speed loaded collision test; (2) accelerated-speed loaded collision test; and (3) variable-load collision test.
In all collision tests, the term “initial load torque” refers to the steady-state external torque applied by the magnetic damper prior to collision onset. This torque constitutes a constant mechanical disturbance acting on the motor shaft–compensated by the cascaded speed–current control loop during normal operation–and serves as the baseline operating condition for collision detection.
In the experiments, friction pads were used to simulate sudden load changes during collision. Collision events were emulated by applying a short-duration additional torque to the shaft coupling via a friction pad. This method introduces an abrupt and irregular external disturbance that approximates the stochastic nature of real physical collisions. The magnitude of the applied collision torque was estimated–based on repeated experimental observations–to range from approximately 0.004 N
m to 0.015 N
m. The torque pulse duration was less than 0.1 s, after which it was fully removed. During the collision tests, both the initial load torque and the applied collision torque were purely external mechanical disturbances–not control inputs–and were compensated by the speed controller through corresponding adjustments of the q-axis current reference.
For each experiment, two collision events were induced to improve result reliability, with an interval of at least 1 second between them. For test (1), the motor’s mechanical speed reference is held constant at 2000 r/min, and the initial load torque is set to 0.1 N
m. For test (2), the speed reference starts at 1000 r/min and ramps linearly to 2000 r/min, while the initial load torque remains constant at 0.1 N
m. For test (3), the speed reference is held constant at 2000 r/min, and the load torque is varied sinusoidally between 0.05 N
m and 0.1 N
m at a frequency of approximately 1.5 Hz. In Figures 3, 4, and 5, motor mechanical speed is reported in r/min for clarity; all analytical derivations in this work use angular speed
expressed in rad/s.
Fig. 3.
Waveforms of rotational speed and evaluation value under sudden load application in collision test (1).
Fig. 4.
Waveforms of rotational speed and evaluation value under sudden load application when accelerating in collision test (2).
Fig. 5.
Waveforms of rotational speed and evaluation value under sudden load application when accelerated in collision test (3).
The detection time of the algorithm is defined as the interval from the onset of speed decrease (
) to the first instant when the evaluation value exceeds the threshold (
), as observed in the speed and evaluation-value waveforms on the host computer.
The collision test results obtained from experimental data analysis are summarized in Table 2. The results show that, in Test (1), the controller detected the collision within 1.6 ms and 0.8 ms, respectively–fast detection times that provide additional time redundancy for post-collision protection measures. In Test (2), the strategy also exhibited rapid response during motor acceleration, with detection times of 1.2 ms and 2 ms for the two collisions. In Test (3), even under continuously varying load torque, the strategy achieved a detection time of 3.6 ms for the first, milder collision, whereas the detection time was only 0.8 ms for the second, more severe collision.
Table 2.
Collision test results.
| Collision test | Additional collision Torque (N m) |
Detection time (ms) |
|---|---|---|
| Test (1) | 0.0135 | 1.6 |
| 0.0144 | 0.8 | |
| Test (2) | 0.0081 | 1.2 |
| 0.0064 | 2.0 | |
| Test (3) | 0.0046 | 3.6 |
| 0.0083 | 0.8 |
To evaluate the robustness of the proposed collision detection strategy against temperature-induced parameter variations, additional experiments were conducted under different thermal conditions using the constant-speed loaded collision test (Test (1)). This test was selected as a representative scenario because it effectively isolates thermal effects from acceleration-related dynamics.
Collision Tests (4) and (5) were performed under near-room-temperature and elevated-temperature conditions, respectively. In the near-room-temperature case, the measured motor surface temperature was approximately 34.8
C. For the elevated-temperature case, the experiment was conducted after the motor reached a steady thermal state with a maximum surface temperature of approximately 80.8
C, as measured using an infrared thermal imaging camera. The corresponding thermal images are available in the Supplementary Materials. In both experiments, the motor was operated at a constant speed of 2000 r/min with an initial load torque of 0.1 N
m.
All control parameters and experimental conditions were kept identical. The detection thresholds used in these experiments were identified based on the upgraded motor drive hardware platform and were kept unchanged across both temperature conditions, with
and
.
Figures 6 and 7 show the measured rotational speed and evaluation value under sudden load application at approximately 30
C and 80
C, respectively. As shown in Fig. 6, two collision events were detected within 5.6 ms and 4.8 ms under near-room-temperature conditions. In the elevated-temperature case shown in Fig. 7, the corresponding detection times were 4.0 ms and 5.6 ms.
Fig. 6.
Waveforms of rotational speed and evaluation value under sudden load application when accelerated in collision test (4) at approximately 30
C.
Fig. 7.
Waveforms of rotational speed and evaluation value under sudden load application when accelerated in collision test (5) at approximately 80
C.
These results demonstrate that the proposed collision detection method maintains reliable and timely detection performance over a wide temperature range. The method is therefore robust against moderate temperature-induced variations in motor parameters, such as permanent-magnet flux linkage and viscous damping, which are commonly encountered in practical industrial applications.
The experiments were designed to evaluate the algorithm’s ability to detect the onset of abrupt external disturbances; precise measurement of collision torque was outside the scope of this study. The proposed detector identified collisions induced by additional torques as small as 0.0046 N
m, which is substantially lower than the initial load torque used in the tests. Moreover, repeated experiments and data analysis show that larger applied collision torques correlate with shorter algorithmic detection times. The detector exhibits robust detection speed across diverse motor operating conditions and provides a rapid, reliable trigger signal for post-collision control strategies.
Conclusion
This paper proposes a sensorless collision detection strategy for PMSMs based on the FFRLS algorithm. The proposed method requires neither additional sensors nor a state observer model. By performing iterative updates on low-dimensional matrices derived from discretized motor motion equations, it achieves accurate and responsive tracking of load torque variations. Consequently, the method is well suited for embedded processors with limited word length and computational resources. In this study, collision tests were conducted under three operating conditions: constant-speed, variable-speed, and variable-load-torque scenarios. These experiments validate the high performance and robustness of the proposed approach. FFRLS serves as the core load torque estimator; its theoretical minimum detection time in simulation is only two sampling periods. Due to hardware limitations of the experimental platform, digital filters were employed to suppress signal noise–introducing a small but non-negligible delay. Therefore, we expect superior detection performance on a well-engineered drive system platform.
Discussion
The experimental setup does not include an independent torque sensor for direct measurement of the external load torque. Therefore, the absolute accuracy of the estimated torque
cannot be quantitatively validated. However, the objective of the proposed strategy is reliable collision detection rather than precise torque identification. The detection mechanism depends on transient variations of the estimated torque and its evaluation metric, rather than on the exact steady-state value of
. Future work may incorporate high-precision torque sensing to further evaluate estimation accuracy.
Because convergence of parameter estimation errors in the FFRLS algorithm requires persistent excitation and sufficient time, accumulated excitation is insufficient during system initialization–leading to a non-negligible risk of false detection at the initial stage. To prevent unreliable decisions during this phase, collision judgment is temporarily inhibited, introducing a short initialization “blind spot”. However, the algorithm achieves rapid convergence shortly after system startup. Experimental results indicate that convergence is achieved within approximately 120 ms on the experimental platform.
In practical applications, additional disturbances–including current-sampling noise, inverter switching harmonics, encoder quantization effects, and temperature-dependent parameter variations–may affect estimation accuracy. Although the proposed method demonstrates robustness under the tested conditions, further enhancement could be achieved by integrating adaptive or hybrid estimation frameworks, such as combining FFRLS with an extended Kalman filter, to improve disturbance rejection capability.
Supplementary Information
Author contributions
D.Z. supervised the study; T.R. proposed this strategy, designed the experiments and wrote the manuscript; GK.H. and MY.L. participated in part of the experimental work. All authors reviewed the manuscript.
Funding
This work was supported by the National Natural Science Foundation of China under Grant No. 62173279 (Project: Multi-level Federated/Migration Learning for Fault Diagnosis of Train Bogies on Sichuan-Tibet Railway).
Data availability
All data generated or analysed during this study are included in this published article and its supplementary information files. A simulation model for strategy verification is also included in the supplementary information files.
Declarations
Competing interests
The authors declare no competing interests.
Footnotes
Publisher’s note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
These authors contributed equally to this work: Ganke Huang and Minyu Liu.
Supplementary Information
The online version contains supplementary material available at 10.1038/s41598-026-43846-5.
References
- 1.Tonti, G., Shakourzadeh, S. & Bianco, C. G. L. A fast collision detection system based on an extended state observer. In 2024 20th IEEE/ASME International Conference on Mechatronic and Embedded Systems and Applications (MESA), 1–8 (IEEE, 2024).
- 2.De Luca, A. & Mattone, R. Sensorless robot collision detection and hybrid force/motion control. In Proceedings of the 2005 IEEE international conference on robotics and automation, 999–1004 (IEEE, 2005).
- 3.Ren, T., Dong, Y., Wu, D. & Chen, K. Collision detection and identification for robot manipulators based on extended state observer. Control Eng. Pract.79, 144–153 (2018). [Google Scholar]
- 4.Kommuri, S. K., Han, S. & Lee, S. External torque estimation using higher order sliding-mode observer for robot manipulators. IEEE/ASME Trans. Mechatron.27, 513–523 (2021). [Google Scholar]
- 5.Wu, J., Liao, Z., Han, Y. & Xiong, Z. An integral design for high performance sensor-less collision detection of serial robots. In 2022 IEEE/ASME International Conference on Advanced Intelligent Mechatronics (AIM), 1714–1721 (IEEE, 2022).
- 6.Popov, D., Klimchik, A. & Mavridis, N. Collision detection, localization & classification for industrial robots with joint torque sensors. In 2017 26th IEEE international symposium on robot and human interactive communication (RO-MAN), 838–843 (IEEE, 2017).
- 7.Ye, X. Research on Control and Collision Detection Technology of Robotic Manipulator Joint Motors. Master’s thesis, Southwest Jiaotong University (2022).
- 8.Yuyang, S., Xiao, X. & Wenzhong, X. Sensorless collision detection for robots based on load torque observer. In 2019 22nd International Conference on Electrical Machines and Systems (ICEMS), 1–5 (IEEE, 2019).
- 9.Krishnan, R. Permanent Magnet Synchronous and Brushless DC Motor Drives , 1st edn. Chapter 3, Sections 3.1 and 3.6 (CRC Press, 2010).
- 10.Brüggemann, S. & Bitmead, R. R. Exponential convergence of recursive least squares with forgetting factor for multiple-output systems. Automatica124, 109389 (2021). [Google Scholar]
Associated Data
This section collects any data citations, data availability statements, or supplementary materials included in this article.
Supplementary Materials
Data Availability Statement
All data generated or analysed during this study are included in this published article and its supplementary information files. A simulation model for strategy verification is also included in the supplementary information files.









































