A Direct-Drive Permanent-Magnet Motor Selective Compliance Assembly Robot Arm: Modeling, Motion Control, and Trajectory Optimization Based on Direct Collocation Method

Most selective compliance assembly robot arms (SCARAs) adopt a conventional indirect-drive structure consisting of servo motors and gearings, which presents drawbacks, including low precision, limited lifespan, and complex structure. In contrast, a direct-drive SCARA (DDSCARA) is compact and delivers superior positioning accuracy and velocity. However, the direct-drive structure is more prone to resonance. In this article, we use real-time filters to eliminate resonance and add the dynamics feedforward (DFF) obtained by decoupling the DDSCARA’s dynamics into the control system to improve position accuracy. The experimental results show that the DFF reduces the position error by about ten times. In addition, a key contribution of this article is the comparison of the DDSCARA with SCARA. The general kinematic and dynamic models of both robot arms are established. They verify the strong coupling of the DDSCARA. We use the direct collocation method (DCM) to optimize the trajectory of both SCARA with reducers and the DDSCARA. We show that for SCARA with reducers, the impact of DCM is limited compared to trajectories widely used. On the contrary, for the DDSCARA, the DCM reduces the power losses significantly. This is validated by experiments that reveal a reduction of the power loss by 50.3% for a motion time of 0.3 s, and a decrease in the mean absolute error of both rotor joints’ position by 52.4% and 67.8%, respectively.


I. INTRODUCTION
Industrial robots have significantly contributed to manufacturing by enhancing production efficiency and promoting societal development [1].The automotive industry, 3C (computer, communications, and consumer electronics) industry, metallurgy industry, logistics industry, and other The associate editor coordinating the review of this manuscript and approving it for publication was Yangmin Li .
sectors have leveraged robots to achieve their rapid growth.As the capabilities of robots continue to advance, higher performance requirements emerge [2].Among the various industrial robots, the selective compliance assembly robot arm (SCARA) stands out due to its simple structure, small footprint, fast movement speed, and high positioning accuracy.SCARA plays an important role in the process flow of the electronic manufacturing industry, particularly in tasks such as component surface mounting and integrated circuit packaging, where operational accuracy requirements are stringent [3].Additionally, SCARA is used in point-to-point (PTP) tasks such as assembly, packaging, palletizing, and welding [4], [5].SCARAs generally have two rotary joints to achieve position determination in the plane range, and the third joint is a moving joint in the vertical direction [6].
SCARAs can be classified into two types based on their drive mode: direct-drive SCARA (DDSCARA) and indirect-drive SCARA with a reducer.Indirect-drive SCARA typically relies on servo motors with reducers or belt drives to increase the torque and achieve the desired transmission [7].Several factors, such as the stiffness of the reducer shaft, gear meshing, gaps, and friction, may contribute to the compliance of SCARA joints [8].Additionally, transmission gaps in the structure may result in cumulative errors, which is especially problematic in high-precision applications.Moreover, reducers have a limited lifespan, and harmonic transmissions may lead to failure, while gears are susceptible to recoil.The primary types of reducers include harmonic reducers, planetary reducers, and rotate vector (RV) reducers.For instance, when harmonic reducers are employed at the joints of a SCARA robot, its compliant characteristics become more prominent [9].At high speeds, the large inertia of the robot leads to significant residual vibrations at the end when the motion stops, thereby decreasing machining accuracy and increasing positioning time [10].Furthermore, mechanical transmission mechanisms like gearboxes are susceptible to mechanical fatigue at very high acceleration and deceleration, and their use can reduce the stiffness of the mechanical structure, thereby reducing the bandwidth of the position loop and potentially causing resonance issues.
Compared to indirect-drive SCARA, the DDSCARA connects the load directly to the motor without any intermediary transmission device [11], [12], [13].This structure offers several advantages, including fewer parts, a compact design, the absence of transmission gaps, high reliability, high speed, and high positioning accuracy, and they ultimately improve the dynamic response of the system gain.The torque motor located at joints serves as the core component of the DDSCARA and uses a surface-mounted permanent-magnet (PM) machine.This type of motor is highly advantageous due to its high peak torque-to-inertia ratio [14], making it particularly well-suited for use in the DDSCARA compared to other motor types.Despite its advantages, the directdrive structure in the DDSCARA yields a lower moment of inertia ratio between the motor and the load compared with that with reducers, making it more susceptible to resonance [15].In [16], the dynamic model of a flexible manipulator with N elastic links and actuators is established.Its vibration is analyzed considering revolute and prismatic joints, illustrating structural vibration and interaction between joints and links' fluctuations.Besides, the moment of inertia of the DDSCARA varies with changes in posture, leading to changes in resonance frequencies, amplitudes, and phases.
The primary cause of resonance in the DDSCARA is the compliant coupling between the motor and load, particularly the joint compliance [17].Several techniques can mitigate resonance, such as increasing the inertia ratio between motors and loads, stiffening the transmission, increasing damping, and incorporating filters.In [18], for PM-motor-driven elevators, a frequency component proportionally modulated with the disturbance of the rotor acceleration torque and speed error was added to the control system to eliminate the vibration caused by resonance, and this method does not analyze how to tune the control gains and lacks experimental verification [18].Sliding mode control has been used to eliminate vibration in a single DC motor, but it requires an accurate plant model and cannot allow fast disturbance [19].In [20], an accurate compliance analysis and finite-element analysis model of a nanopositioning stage is conducted, and natural frequencies are obtained.It uses a second-order lowpass filter to suppress vibration.For the DDSCARA, its resonance frequency changes with postures, so it is difficult to establish an accurate model of the natural frequencies.If only a second-order low pass filter is used to suppress the vibration, it dramatically reduces the bandwidth and phase margin of the system, which can make the system unstable.
Based on [21], we propose the addition of real-time filters to eliminate resonance.We measure resonance points in different postures of the DDSCARA, adding Bi-Quad filters that vary with postures into the velocity loop to eliminate resonance.
As the direct-drive system lacks mechanical transmission, the dynamic coupling between components intensifies, resulting in a complex drive current waveform during motion.This strong coupling in direct-drive motion systems presents new challenges and difficulties in design and optimization.The general dynamics model of SCARA is used to decouple the dynamics to achieve dual-axis coordinated control [22] and demonstrate the strong coupling of the DDSCARA compared with the structure using reducers.In [23] and [24], Euler-Lagrange and Gibbs-Appell methods provide dynamic models of elastic manipulators with flexible revolute and prismatic joints and telescopic joints.The Euler-Lagrange equation facilitates calculations for obtaining their torque vectors.We obtained the dynamics equation [25] using the Euler-Lagrange equation and derived the feedforward for the DDSCARA's decoupling control.We used dynamics feedforward (DFF), which can enhance the control accuracy [10], [26].In the existing literature, we have not found a comparison between the DDSCARA and SCARA with reducers concerning the impact of coupling.Therefore, we aim to compare the two types of SCARAs in this article.
Trajectory planning can improve the speed, accuracy, and dynamic performance of robots [27], [28].Numerous trajectory planning algorithms have been developed, including cubic polynomial, quintic polynomial, cubic spline, parabola, and other interpolation algorithms [29].The integral of squared jerk is used as the objective function in [30], VOLUME 11, 2023 123863 Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.
focusing only on trajectories generated by a fifth-order B-spline curve with uncertain motion time.Its efficacy for other trajectory types remains unconfirmed.In [31], it combines spline interpolation in Cartesian and joint space for jerk-continuous, time-optimal trajectory planning and only considers kinematic constraints.Its effectiveness for energy optimization is unproven.
Other trajectory planning algorithms, such as the genetic algorithm [32], neural networks [33], and particle swarm optimization, have been proposed for optimal trajectory planning.The probabilistic roadmap method algorithm obtains the shortest path for SCARA to complete the motion task in the presence of obstacles [34].The optimization problem of hyper-redundant manipulators in 3D workspaces is solved by using a Genetic Algorithm with multiple populations [35].Particle swarm optimization can achieve minimal total power losses and distance [36].However, both do not consider the dynamic constraints.Furthermore, genetic and neural network algorithms require complex programming and high computing power, with particle swarm optimization also necessitating strict constraints and being susceptible to locally optimal solutions.
In [37], an indirect method for trajectory optimization is given.It is based on the resolution of the Riccati equation, which requires a large amount of calculation, and the initial value of the shooting method is difficult to suppose [38].Another method called the direct collocation method (DCM) features simple constraints and fast operation speed.The method discretizes the corresponding control variables and state variables according to the time interval distribution.Both variables are used as optimization variables.The state and control variables are approximated by piecewise continuous polynomials, which are used to simplify the integral calculation involved.When integrals and other calculations are converted into algebraic equations, the computation time is significantly reduced [39], [40].Since the motion tasks of SCARA mainly involve PTP motion, we use the direct collocation method (DCM) for trajectory optimization, with the lowest power loss as the optimization objective.This method considers the system dynamics equations, the appropriate initial conditions, and the optimization objective.It solves nonlinear planning problems by discretizing the time domain.A key contribution of our research is to use the DCM for DDSCARA and evaluate its impact on power losses and position accuracy.Besides, we compare the DCM optimization results of the DDSCARA and SCARA with reducers.Lastly, this article provides a theoretical analysis and a model simulation and verifies the results through an experimental platform.
In this article, Section II establishes the general kinematic and dynamic models of SCARA.In Section III, the control system of the DDSCARA is analyzed.Section IV presents the optimization model, and trajectory optimization of the DDSCARA is conducted to obtain the optimization results.Section V describes the experimental platform implemented  to verify the theoretical results.Finally, the conclusions are given in Section VI.

II. THE KINEMATIC AND DYNAMIC MODEL A. KINEMATIC MODEL
The kinematic model of SCARA primarily elucidates the correlation between joint variables and end coordinates in a Cartesian coordinate system [41].According to the structure of the DDSCARA examined in this article (Fig. 1), the kinematic model and reference frames are established.The convention of reference frames is the Denavit-Hartenberg convention (DH), which is commonly adopted in robotics.
Table 1 presents the DH parameters of the DDSCARA, with L 1 and L 2 denoting the length of links 1 and 2, respectively, θ 1 and θ 2 representing the joint rotation angle, and h 1 and h 2 are respectively the height of motors 1 and 2. Under the DH convention, the homogeneous transformation matrix that characterizes the position and orientation of o i x i y i z i relative to o j x j y j z j can be determined using where 123864 VOLUME 11, 2023 Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.Subsequently, the product of and yields the position and orientation (5) of the end with respect to the inertial frame o 0 x 0 y 0 z 0 , which is attached to the base of motor 1: with The purpose of the inverse kinematics of SCARA is to obtain joint variables θ 1 and θ 2 through the known terminal coordinate (x, y, z).In this article, SCARA studied does not move in the z-axis direction, and the equivalent motion model in the o 0 x 0 y 0 plane is shown in Fig. 2. We use the algebraic method to solve the inverse kinematics: θ 2 is given by the cosine law Figure 2 illustrates that two θ 2 values, corresponding to two distinct gestures, can be derived from the same coordinate, namely θ ′ 2 = −θ 2 .The calculation of θ 1 involves variable substitution, as described by where k 1 = L 1 + L 2 cos θ 2 and k 2 = L 2 sin θ 2 , and the function arctan(y, x) gives the arc tangent of y x , taking into account which quadrant the point (x, y) is in.The function arctan(k 2 , k 1 ) is defined similarly.

B. DYNAMIC MODEL
The robot dynamics primarily focuses on investigating the impact of force or torque exerted on each joint on the overall motion of the robot.Therefore, the dynamics equations of robots play a critical role in the system's design and optimization of robot control.The link of SCARA is motivated by the force or torque exerted by the joint.In the case of the DDSCARA, the motor directly connects links and loads.Therefore, the coupling increases.The links and loads add additional inertia that varies with the joint configuration.Each link in SCARA is supported by the reaction force of adjacent links and the torque generated by the joint.The dynamics equation of SCARA is a set of coupled dynamics equations that specify the joint torques required to achieve a desired manipulator state, providing insight into how the motion of joints exerts a disturbing force on other joints.This article employs the Euler-Lagrange equation to derive the dynamics equation of SCARA [42].The Euler-Lagrange approach is a dynamic method based on energy principles, which establishes the dynamic model by considering the system's kinetic energy and potential energy.As the motion of the DDSCARA is confined to the horizontal plane, there is no gravitational potential energy involved.In the modeling, we regard links and loads that make up the manipulator arm as rigid bodies, and if we know the position of their center of mass and moment of inertia, then their mass distribution characteristics are determined.Finally, the torque required for the link motion is a function of acceleration, velocity, angle, and mass distribution.
To obtain the dynamics equation, the first step is deriving the inertia matrix with and where m i is the mass of link i, L ci is the distance between the axis of rotation of link i and its center of mass, whereas I i is the moment of inertia of link i with respect to the z-axis passing through its center of mass, i = 1, 2.
According to the inertia matrix, we can get the elements of the Christoffel symbol In the models, the reduction ratio is denoted by N i , i = 1, 2. To keep derivations general, we include the reducer in both DDSCARA and SCARA models, assuming N i = 1 for the DDSCARA.The torque produced by the motor at the joint can be divided into three components: the torque required for the rotation of the motor and the load (τ mi ), the torque needed to overcome friction (τ fi ), and the disturbance torque arising from the coupling of the dynamics (τ di ).The torque τ mi can be obtained from where q i is the motor rotation angle and q i = N i θ i , J i is the moment of inertia of the motor itself, and qi is the second derivative of q i with respect to time, i = 1, 2.
Using the Coulomb and viscous friction model to calculate the τ fi , and considering only the friction at the joints, the model can be expressed as follows: where B vi is the viscous friction coefficient, F ci is the Coulomb friction coefficient, and qi is the first derivative of q i with respect to time, i = 1, 2. Finally, according to the Euler-Lagrange equation, we express the disturbance torque arising from the coupling of the dynamics of the two rotating joints, denoted as τ d1 and τ d2 , respectively: where θi is the first derivative of θ i with respect to time, and θi is the second derivative of θ i with respect to time, i = 1, 2.
Then we derive output torque of both motors: 2 ), ( 21) To gain a more intuitive understanding of the decoupling effect of the reducer and the strong coupling between the  two direct-drive motors in the DDSCARA, a motion task was devised, which involved keeping axis 0 of SCARA stationary while allowing axis 1 to rotate 90 degrees within 400 ms.More precisely, this entailed maintaining θ 1 = 0 • while θ 2 changed from 0 degrees to 90 degrees in Fig. 1, with both axis 0 and axis 1 adopting the same reduction ratio.By comparing the reduction ratio of 20 and 100, Fig. 3 shows that with the increase in reduction ratio, the torque of the axis 0 motor gradually decreases, and the disturbance of axis 1 to axis 0 gradually diminishes during the motion.Therefore, the dynamics relationship between axis 0 and axis 1 of SCARA with reducers is approximately decoupled particularly at high reduction ratios.For the DDSCARA, it can be seen from Fig. 4 that to achieve this motion, axis 0 requires a larger and irregular torque output to maintain θ 1 = 0 • , which shows the strong coupling of the DDSCARA.

III. CONTROL SYSTEM AN OVERVIEW OF THE OVERALL CONTROL SYSTEM
SCARA is a time-varying, nonlinear, and strongly coupled system with multiple inputs and outputs [43].Traditional single-control methods often struggle to meet the demanding requirements for both accuracy and speed.Generally, the proportional-integral-derivative (PID) controller serves as the fundamental controller of robots due to its high stability 123866 VOLUME 11, 2023 Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.[44], simple parameter adjustment, and excellent robustness.Dynamic parameter optimization strategy and compensation strategy are supplemented, which can realize high-precision trajectory tracking at certain conditions.The control system of the DDSCARA is shown in Fig. 5, which adopts a compound control method of feedback and feedforward.Specifically, feedback is used to ensure transient stability, while feedforward is employed to achieve steady-state nonlinear dynamic compensation.The feedback adopts the three-loop series control method of position loop, velocity loop, and current loop.The position loop adopts P controller, and the velocity loop adopts the combination of real-time filters and PI controller to address the issues of mechanical system resonance and external interference.The rotational speed control strategy is adopted in the current loop to realize the maximum torque output of the surface-mounted permanent-magnet synchronous motor, and the space vector pulse width modulation (SVPWM) is used to improve the utilization rate of the bus voltage.
Furthermore, we add velocity feedforward and acceleration feedforward into the control system.The acceleration feedforward control differs from simply multiplying by a constant coefficient to obtain the current feedforward value but adopts the decoupling of dynamics to achieve coordinated control of the two axes, that is, dynamics feedforward (DFF).Due to the significant coupling between the two axes, the time-varying joint inertia coupling and the constant current feedforward may result in large current overshoots.To address this, we establish the dynamics equation of the DDSCARA using the Euler-Lagrange Equation for the decoupling of dynamics and provide the real-time current feedforward (I 1 FF , I 2 FF ) that varies with the posture of the DDSCARA.

A. RESONANCE
Multiple factors contribute to the resonance of the DDSCARA, but the primary cause is the compliance of its components.To better understand the resonance in the DDSCARA, a model for a compliant joint (Fig. 6) was established and analyzed [8], [15], [17].The model analysis is based on the following assumptions: the reducer is a whole, all the other components are rigid, and there is no compliance between them except the transmission compliance between reducers and loads.Therefore, the transfer function from the output electromagnetic torque T E of the motor to the position P M is obtained by Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.where J T = J M + J R + J L , J M , J R , and J L respectively denote the of inertia of the motor, the reducer, and the load, K S is the transmission compliance coefficient.It represents the proportion between the torque generated at the load and the difference between the reducer and load position.The parameter K CV is the cross-coupled viscous damping and represents the proportion between the torque generated at the load and the difference between the reducer and load velocity.

B. REAL-TIME FILTER AND DYNAMICS FEEDFORWARD
The control system consists of real-time filters, including a low-pass filter, a Notch filter, and two Bi-Quad filters [10].The parameters of Notch filters and Bi-Quad filters, the P controller of the position loop, and the PI controller of velocity and the current loop will change in realtime according to the frequency, amplitude, and phase of resonance.For the Bi-Quad filter, its transfer function is as follows where ω Z and ω P represent the natural frequency of the zero and pole, respectively, while ξ Z and ξ P denote the damping ratio of the zero and pole, respectively.As Notch filters can be considered a specific instance of Bi-Quad filters, and when ω Z = ω P and ξ Z = 0, the analysis of the latter is sufficient.Since resonance points of the DDSCARA are at specific frequencies, as shown in Fig. 13, BiQuad filters adopting the form of Notch filters are more effective in eliminating the resonance.The Bode plot of the Bi-Quad filter with different damping ratios is shown in Fig. 7.
To enhance control accuracy, the DFF calculated by joint angles, velocities, accelerations, structural parameters, and dynamics model of the DDSCARA are added into the control system.In addition, unlike velocity feedforward, the DFF does not affect the gain of the position loop and can also eliminate overshoot caused by velocity feedforward and coupling and improve the response speed.Through the derivation of the dynamics model in Section II, according to the torque constant K 1 t and K 2 t of the direct-drive motors 1 and 2, the current feedforward can be obtained:

IV. TRAJECTORY OPTIMIZATION
The direct collocation method (DCM) is a numerical approach that addresses continuous dynamic optimization problems by transforming them into static problems through time domain discretization and then solves them with corresponding methods [40].This method involves discretizing the control and state variables.To ensure accurate fitting of these variables in the time domain, interpolation polynomials are employed.By differentiating the polynomials, we approximate the differential values of the state variables at discrete nodes, thereby obtaining the static optimization problem known as the nonlinear programming (NLP) problem.In contrast to the direct shooting method, which applies polynomial fitting across the entire time domain, the DCM employs polynomial fitting within individual discrete segments.The DCM is favored for its computational simplicity and fast operation speed, making it a widely adopted method.This article uses Hermite-Simpson collocation to construct the nonlinear program for the problem.The second-order dynamics equations of the DDSCARA are derived from ( 21) and ( 22) for the DCM: where )N 2 and k 3 = It is necessary to represent the system dynamics in firstorder form for all standard trajectory optimization methods, and it is achieved by including both the minimal coordinates (θ 1 and θ 2 ) and their derivatives in the state.Note that θ1 and θ2 are defined in ( 26) and ( 27): The optimization objective in this article is to minimize the power loss for a given motion time.We establish the following objective function: where i 1 and i 2 represent the input currents of motors 1 and 2, R 1 and R 2 denote the single-phase resistance of motors 1 and 2, and t m represents the motion time.
The objective function (29) takes the form of quadratic polynomials, which tend to produce smooth trajectories that can solve optimization problems faster and more accurately.Moreover, traditional controllers find it easier to stabilize the system when dealing with smooth trajectories.The boundary constraints of the motion system are both the initial points (d i1 and d i2 ) and final points (d f1 and d f2 ) of the trajectory.The velocity is zero at the initial and final points, and the boundary constraints for this system are given by The constraints imposed on the state variables are as follows: (32) where 1 = |d f1 − d i1 |, 2 = |d f2 − d i2 |, and τ max1 and τ max2 are the maximum torque output of motors 1 and 2.
To ensure that the solver reaches a fast convergence to the global optimal solution, trajectory optimization must entail a well-defined initial guess.A simplified initial guess assumes linear motion between the initial and final states, with zero applied torque, which is valid for the problem in this article, although it fails to satisfy the system dynamics: The subsequent investigation focused on the impact of the DCM applied to the DDSCARA and SCARA with reducers (N=100).The designated motion task entailed moving from point A (0.18 m, 0.1 m) to point B (0.275 m, 0.27 m) on the plane within 400 ms.Subsequently, the optimized trajectory was compared with that generated by the S-curve (Fig. 8) [45].

TABLE 2.
Power loss comparison of optimization and S-curve for the DDSCARA and SCARA with reducers and power loss is calculated by (29).
Figure 9 shows that when the trajectory adopts the S-curve, the axis 0 current of SCARA with reducers is close to that of the DDSCARA, while its axis 1 current is somewhat different from that of the DDSCARA in the second half of the motion.The reason is the coupling between the two axes of the DDSCARA.Upon optimization by the DCM, the current of both axes decreases and is more linear.However, the current of the DDSCARA is lower than that of SCARA with reducers, which is more notable in axis 1.
In Fig. 10, we can see that the motion trajectory of SCARA with reducers after optimization remains almost the same as that generated by the S-curve (before optimization).This is why the S-curve has been widely used for SCARA with reducers and achieves good results in that case.Notably, for the DDSCARA, this is different.The optimization of the trajectory through DCM gives a trajectory that is significantly different from the original S-curve trajectory.This emphasizes the need to use DCM to optimize the trajectory of DDSCARAs.As shown in Table 2, the DCM can also optimize the trajectory of SCARA with reducers to reduce the power loss, but the optimization effect on the DDSCARA is more significant.

V. EXPERIMENTAL VERIFICATION A. EXPERIMENTAL SETUP
The 3D model of the DDSCARA is established in SolidWorks (Fig. 11) and imported into MATLAB Simulink for simulation, which provides motions generated by the S-curve and the DCM.According to the simulation model, the prototype of the DDSCARA shown in Fig. 12 was designed and equipped with the servo driver, and the motors used in the prototype are surface-mounted permanent-magnet machines.The communication between the computer and the servo driver adopts the EtherCAT Protocol, with the servo driver given in [46].The computer generates motion information and transmits it to the servo driver.At the same time, encoders embedded within the motors convey the motion information of the DDSCARA back to the computer through the servo drive, forming a closed-loop control.Detailed parameters of the experimental platform and the two motors are given in Table 3 and Table 4. Affected by the gravity and loads, links will deform, which affects the position accuracy of the DDSCARA.The weight variation of the end load also causes the change of the moment of inertia of the DDSCARA, then affects the output torque of the direct drive motor required by the DDSCARA, and its resonance points will also change, which will affect the design of the DDSCARA robotic arm.In addition, the weight variation of the end load also causes the change of power loss.

B. EXPERIMENTAL RESULTS
Because the resonance frequency, the phase, and the amplitude of the DDSCARA change with its postures, specifically the variation of θ 2 , measuring the resonance characteristics at different θ 2 values is necessary.To eliminate the resonance, appropriate filters are incorporated, and the parameters of these filters, such as the natural frequency and damping coefficient of the zero and pole, are recorded.Notch and Bi-Quad filters are added according to the frequency and amplitude of resonance obtained by the Bode plot, and two Bi-Quad filters are applied to the resonance with high amplitude to eliminate it.Under the premise of ensuring the bandwidth and phase margin, the amplitude is reduced by -15 dB to -25 dB to ensure stability.Experimental measurement is conducted to obtain data, which is subsequently used for fitting to obtain the function between the filter parameters and θ 2 , then the real-time filter is obtained.Considering θ 2 = 47 • as an example, it can be seen from the open-loop Bode plot (Fig. 13) of the system that there are four resonance points below 300 Hz, among which the resonance with frequencies of 73.7 Hz, 20 Hz, and 271.7 Hz exert a significant influence on the motion system.With the addition of the filters, their amplitude is all lower than -20 dB, their amplitude above 300 Hz is also lower than -10 dB, and the system can gain a phase margin of about 35 • .123870 VOLUME 11, 2023 Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.Figure 14 shows that the DFF prompts a remarkable reduction in position error during motion, approximately ten times lower than without the DFF.Moreover, the DFF significantly reduces the current overshoot and almost eliminates it at some time points.Consequently, the DFF brings the experimental results closer to the analytical results, indicating that the DFF achieves a more accurate and precise motion control.Although the DFF can improve the control accuracy, there are still errors between the actual motion and simulation.One source of error comes from the small difference between design parameters and actual prototype parameters of both motors and links.Also, it is difficult to establish a completely accurate dynamics feedforward model.In addition, the interference of external environment mechanical parameters and the change in motors' temperature affect the accuracy of the dynamics model.
To verify the effectiveness of the optimization method applied to the DDSCARA, the trajectory generated by the DCM is compared with that generated by the S-curve.As shown in Fig. 15, the motion task consists of four PTP motion segments within the square range of 200 mm × 200 mm.The motion points are A, B, C, and D, and the PTP motion duration is t m , with a rest period of 100 ms for each segment.The other parameters of this motion task are shown in Table 5.This motion task simulates the assembly operations typically encountered in industrial applications involving SCARA.
Because the changing trend of experimental results obtained by different t m values from 0.3 s and 0.45 s is the  same, only the position error, velocity, and current figures when t m is 0.3 s and 0.4 s are shown here.From Fig. 16, the current for the motion generated by the S-curve is smaller than that generated by the DCM, and the optimized current is approximately linear in motion segments.Moreover, the current fluctuation after optimization is also smaller than that of the S-curve, which is more noteworthy from 0.5 s to 0.6 s for the t m = 0.3 s motion.With the increase of t m , the current decreases, the current fluctuation diminishes, and the  experimental results are more consistent with the analytical results.
The velocity results are shown in Fig. 17.Compared with the S-curve, the velocity maximum for the motion generated by the DCM is lower, and the experimental results of both methods are highly consistent with the analytical results.In motion segments from B to C and D to A, the motion generated by the S-curve differs from that generated by the DCM.The two axes of S-curve motion rotate in the same direction, while the two axes of the DCM motion have both same and opposite direction rotation.Due to the strong coupling between the two axes of the DDSCARA, when two axes rotate in the same direction, axis 0 needs to generate more torque to counteract the axis 1 effect.However, the opposite-direction motion leverages the coupling effect, making the motion more stable with less torque.
Figure 18 and Table 6 show that the position error of motion generated by the DCM is lower compared with the S-curve, which is more remarkable on axis 1.For t m = 0.3 s, the mean absolute error (MAE) of axis 1 position error after optimizing is reduced by 67.8%, which shows that the DCM also improves positioning accuracy.The improvement in accuracy is because the trajectory optimization (DCM) takes into account the dynamics of the DDSCARA, which allows motion tasks to be accomplished with lower currents and more reasonable postures.Furthermore, regardless of the motion generation methods employed, the position error of axis 1 is consistently higher than that of axis 0. This discrepancy can be primarily due to the coupling effect of 123872 VOLUME 11, 2023 Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.Figure 19 shows trajectories generated by the DCM and S-curve, revealing differences.This is because the motion profiles of each segment generated by the S-curve are similar according to fixed mathematical algorithms without considering other factors.However, the DCM considers the dynamics model of the DDSCARA and takes the minimum power loss as the objective to generate motion profiles.For the DCM, even if the distance between two points is the same, the DDSCARA will have different motion trajectories with varying postures at the starting and ending points.Finally, Fig. 20 shows the comparison of power losses.The power losses are deduced from the measured current and (29).We find a significant reduction in power loss after applying  the DCM for different t m values.Notably, for t m = 0.3 s, the power loss is reduced by as much as 50.3%.These results demonstrate the effectiveness of the DCM in minimizing the power loss of the DDSCARA.

VI. CONCLUSION
This article introduces the DCM as a trajectory optimization approach for the DDSCARA, with the objective of minimizing power loss.The general kinematic and dynamic model established applies not only to the DDSCARA but also to SCARA with reducers.The strong coupling of the DDSCARA compared with the structure with reducers is verified.In addition, the model of compliant joins of the DDSCARA is also provided, the reason for resonance is analyzed, and adding real-time filters eliminates the resonance from the level of the motion control system.Decoupling the DDSCARA's dynamics is carried out according to the system dynamics equation to add the DFF to improve the position control accuracy.The results of experiments demonstrate that real-time filters eradicate resonance, and the DFF can diminish the position error by approximately tenfold, resulting in an enhancement in control accuracy.
The DCM is used to establish the optimized trajectory of both DDSCARA and SCARA with reducers.Notably, because of the coupling, the DCM has a much more significant effect on reducing the DDSCARA power loss compared with SCARA with reducers.Also, the optimized trajectory found using DCM differs from the S-curve for DDSCARA.On the contrary, for SCARA with reducers, the optimized trajectory found using DCM is not significantly different than the S-curve.This confirms that the coupling not only impacts the control of the DDSCARA but also significantly impacts the optimized trajectory.
For the DDSCARA, motions generated by the S-curve and the DCM are compared on the experimental platform, considering different t m values.The application of the DCM to the DDSCARA trajectory optimization can reduce the axes 0 and 1 position error (MAE) by 52.4% and 67.8%, and the power loss by 50.3% for the motion task with t m = 0.3 s, which proves that this optimization method can improve the performance of the motion system while reducing the power loss.
In future research, more advanced optimization algorithms can be used to impose more stringent constraints on the DDSCARA motion trajectories and the comparison of different control methods to enhance the reliability, making them applicable to more complex application scenarios.

FIGURE 5 .
FIGURE 5. Control system of the DDSCARA.

FIGURE 7 .
FIGURE 7. Bode plot of the Bi-Quad filter.

FIGURE 8 .
FIGURE 8.The trajectory profiles generated by the S-curve include jerk and acceleration curves.The variable tm is the motion time, while αs and βs are the time proportion of jerk and constant velocity, respectively.

FIGURE 9 .
FIGURE 9. Calculated current comparison of optimization and S-curve for the DDSCARA and SCARA with reducers (N = 100), the axis 0 on the left and the axis 1 on the right.

FIGURE 10 .
FIGURE 10.Trajectory comparison of optimization and S-curve for the DDSCARA and SCARA with reducers.

VOLUME 11, 2023 123869
Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.

FIGURE 12 .TABLE 3 .
FIGURE 12. Experimental platform of the DDSCARA.TABLE 3. Parameters of the experimental platform.

FIGURE 14 .
FIGURE 14.Comparison between analytical and experimental results with and without DFF.

FIGURE 16 .
FIGURE 16.DDSCARA's current of axis 0 and axis 1 for different tm values.

FIGURE 17 .
FIGURE 17. DDSCARA's velocity of axis 0 and axis 1 for different tm values.

FIGURE 18 .
FIGURE 18. DDSCARA's position error of axis 0 and axis 1 for different tm values.

VOLUME 11, 2023 123873
Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.

FIGURE 20 .
FIGURE 20.DDSCARA's power loss measurements of motions generated by the DCM and S-curve for different tm.

TABLE 1 .
Denavit-Hartenberg convention parameters of the DDSCARA.The parameters a, α, d , and θ are the link length, link twist, link offset, and joint angle, respectively.

TABLE 4 .
Electrical performance parameters of the two motors at a temperature equal to 20℃.

TABLE 6 .
Axis 0 and 1 position error (MAE), and percentage decrease in error (MAE) of S-curve compared with optimization.