###### Abstract  
In this paper, a current-error-based iterative learning controller (ILC) with a nonlinear controller is proposed to improve the position-tracking performance in permanent-magnet (PM) stepper motors. Our proposed method comprises a current-error-based ILC for mechanical dynamics and a nonlinear controller for current dynamics. A nonlinear controller using a variable structure is designed to obtain the field-oriented control. This nonlinear controller can cause the PM stepper motor become a single-input single-output linear system after finite time. The add-on-type ILC with proportional-integral control is designed to improve the position-tracking performance as the systems repeatedly perform the same operation. To increase the rate of error convergence, the current-error-based ILC is designed using the plant inversion method. The condition that the error converges to zero is mathematically derived. Thus, the proposed method can reduce the position-tracking error as the systems repeatedly perform the same operation. Furthermore, the proposed method can be easily plugged into the pre-designed controller. The performance of our proposed method was evaluated via simulations. In simulations, it is observed that the proposed method reduces the position-tracking error compared to the previous methods. permanent-magnet stepper motor; position control +
Footnote †: 2021: 11, 587. [[https://doi.org/10.3390/app11020587](https://doi.org/10.3390/app11020587)]([https://doi.org/10.3390/app11020587](https://doi.org/10.3390/app11020587))
field-oriented control (FOC) and FWC without direct-quadrature (DQ) transformation, and an integrator reset control was designed in [9] to improve transient response with position control of the PM stepper motor. An enhanced nonlinear damping controller was proposed to reduce the position-tracking error [10]. Furthermore, a nonlinear \(H_{2}\) control with varying linear parameters was developed to optimize control performance [11]. In [12], an effective closed-loop control comprising motor parameter identification, closed-loop current control, closed-loop position control, and damping control was proposed. A model predictive controller was designed for external periodic disturbance attenuation in PM stepper motors [13]. Robust speed control using two-degrees-of-freedom control was developed to guarantee the exponential stability for PM synchronous motors(PMSMs) [14]. A discrete-time fast terminal sliding mode control was developed to improve the position tracking performance in PM linear stepper motors [15]. In [16], a finite-time control algorithm was designed to improve PMSM system's dynamical performance and disturbance rejection ability. An internal model principle-based controller was proposed to reduce sideband harmonics for PM stepper motors with low-switching-frequency inverters in [17]. PM stepper motors are usually operated with a repetitive desired position trajectory. This case was not considered in the previous methods, although previous methods improved the position/velocity performance. Iterative learning controllers (ILCs) have been applied to improve the performance of systems that repeat periodic movements [18], such as hard disk drives and scanners [19; 20; 21]. In previous methods, past-error-based ILCs were used; thus, the convergence of the tracking errors was slow. Several ILC methods were developed for the PM stepper motors and the PMSMs [22; 23]. However, the current dynamics were not considered in those methods. In this paper, a current-error-based ILC with a nonlinear controller is proposed to improve the position-tracking performance of the PM stepper motors. The proposed method consists of the current-error-based ILC for mechanical dynamics and a nonlinear controller for current dynamics. A nonlinear controller using a variable structure is designed to obtain FOC. This nonlinear controller can make the PM stepper motor become a single-input single-output (SISO) linear system after a finite time.