Share this

Phase compensation method and device for motor zero position and encoder zero position

2026-04-06 05:58:40 · · #1

introduction

In the era of Industry 4.0, the nation is focusing on upgrading and transforming the manufacturing industry and developing high-end intelligent equipment. Servo control systems , as direct executors in automation and high-end intelligent equipment, play a crucial role. Permanent magnet synchronous motors (PMSMs), with their advantages of high efficiency, high air gap magnetic density, high power factor, compact and simple structure, and linear response, have been widely used in CNC machine tools , robots, manned spacecraft, and variable frequency air conditioners. In servo drive control systems, the accurate acquisition of the phase relationship between the servo motor's zero position and the encoder's zero position is crucial for the servo motor's normal startup. Incorrect phase relationships will cause PMSM startup failure, resulting in rotor reversal, vibration, and other adverse phenomena.

To accurately obtain the phase relationship between the servo motor zero position and the encoder zero position, Liu Jianwen summarized various phase alignment methods for different encoders. These methods mainly involve manual alignment, and the basic alignment steps are as follows:

(1) Direct current is directly applied to any two phases of the motor to lock the motor rotor in a fixed position. The electrical angle of the locked position of the motor rotor can be determined according to the phase sequence and direction of the current. For example, if the direct current enters from the a-phase winding and exits from the b-phase winding of the motor, the motor rotor will be locked at a position with an electrical angle of -30°.

(2) Manually adjust the relative position of the encoder and the motor rotor while using debugging tools, such as oscilloscopes or devices that can display encoder feedback data, to observe the encoder zero position mark. When the zero position mark appears on the debugging tool, fix the encoder shaft on the motor rotor to complete the phase alignment.

This manual search and calibration of the zero position is very laborious and affects the consistency of the zero position calibration accuracy of the corresponding encoder. As a result, various zero adjustment devices designed for different encoders have emerged. Wang Xinshe et al. designed a dedicated phase alignment servo driver for incremental encoders with UVW Hall signals. Multiple selection switches are used to control the phase alignment steps, and multiple LEDs are used to display the signal status. The encoder phase and rotor magnetic pole phase can be adjusted arbitrarily, and the motor can be driven to run. The operation is relatively simple, which improves production efficiency and phase accuracy. However, the encoder signals are not verified before zero position calibration, and the zero position calibration results are not verified. Zhang Jingbo et al. designed a dedicated zero adjustment device that supports incremental and absolute encoders. The interface is user-friendly and the parameters can be set. However, the encoder signals are not verified before zero position calibration, and the zero position calibration results are not verified [5]. Therefore, the existing zero adjustment devices still have room for improvement. This paper mainly improves the phase compensation method between the motor zero position and the encoder zero position of the absolute encoder.

1. Working principle

Vector control of AC servo motors requires accurate electrical angles to achieve optimal power output. For incremental encoders, the rising edge of the Hall U signal is usually aligned with the motor's zero position, or the index Z signal is aligned with the motor's zero position. For absolute encoders, since each output value corresponds to a unique position in one revolution, the zero position of the absolute encoder is usually aligned with the motor's zero position.

The manual zero-alignment method involves first aligning the zero point and then fixing the absolute encoder to the motor shaft. The method described in this paper first arbitrarily installs the absolute encoder on the motor, then uses the device described in this paper to obtain the compensation angle between the absolute encoder's zero point and the motor's zero point, verifies the correctness of this compensation angle, and finally saves the compensation angle to the absolute encoder's built-in EEPROM. During servo driver power-on initialization, the compensation angle is read from the EEPROM and then superimposed on the real-time feedback angle of the absolute encoder to obtain the accurate electrical angle. This method eliminates the need for manual zeroing, improving the efficiency of motor encoder installation.

To ensure the accuracy of the entire process of acquiring the compensation angle, writing the compensation angle to the EEPROM, and reading the EEPROM, consider the following four points:

(1) For some single-turn absolute encoders, after power-on, they need to rotate a certain angle α to output the nominal resolution value. The output value within α has a relatively low resolution. However, after the motor is powered on with DC, the angle of rotation of the motor is less than α. Therefore, the absolute encoder value read by the CPU has low accuracy, resulting in a large zero-position correction error, which will reduce the performance of the servo driver. Therefore, during zero-position correction, the motor rotor must rotate through an angle α.

(2) For the split-type absolute encoder, due to assembly reasons, the feedback data may be incorrect. Therefore, the feedback data must be checked before obtaining the compensation angle.

(3) After calculating the compensation angle, the correctness of the compensation angle is verified by trial operation.

(4) After the compensation angle is written to the EEPROM, it needs to be read back to ensure that the data is read and written correctly.

Figure 2. Simplified block diagram of the control system

In Figure 2, the control system is divided into two stages: (1) Stage 1: When the switch S is in the "0" position, the system is locked shaft control and calculates the compensation angle. (2) Stage 2: When the switch S is in the "1" position, the system runs the motor according to the calculated compensation angle to verify the correctness of the compensation angle. Through the trial run, the correctness of the encoder assembly and encoder data feedback can also be verified.

2. Methods and Steps

The simplified operation steps of the compensation method are shown in Figure 3.

Figure 3. Brief operation steps of the compensation method

(S1) Power-on initialization: Based on the motor model and absolute encoder model set in the dedicated servo driver, the functions of each part of the dedicated servo driver are initialized using the motor parameters and absolute encoder parameters stored in the dedicated servo motor.

(S4) Motor test run: Using the obtained compensation angle, test run the motor according to the set method. The set method is: ① Low-speed forward rotation for several revolutions → ② Low-speed reverse rotation for several revolutions → ③ High-speed forward rotation for several revolutions → ④ High-speed reverse rotation for several revolutions. During the test run, detect errors such as absolute encoder data errors, overspeed, and overcurrent.

(S5) Parameter Programming: Proceed to this step when there are no error alarms during motor trial run. In this step, the motor parameters, absolute encoder parameters, and final compensation angle are programmed into the absolute encoder's EEPROM. A readback comparison operation is performed during parameter programming. Alarms for communication errors and programming errors are set.

3. Software Process

Two triggering methods are designed for the phase compensation of motor zero position and encoder zero position: one is through a single switch control method, and the other is through PC debugging software control method.

The flowchart of the single-switch control method is shown in Figure 4. As can be seen from Figure 4, only one switch is needed to control the entire process of motor rotor zero-position correction, trial operation, and EEPROM read/write.

Figure 5 shows the flowchart of the PC software control method. As can be seen from Figure 5, the PC software allows for independent control of the motor shaft locking, compensation angle calculation, parameter programming, and parameter operations. Parameter operations include uploading, modifying, and downloading motor parameters and absolute encoder parameters.

Figure 4 Flowchart of Single Switch Control Method

Figure 5 Flowchart of PC software control method

4. Platform Verification

The experimental platform shown in Figure 6 was constructed for verification.

Figure 6 Verification Platform

The PC software interface is shown in Figure 7.

Figure 7 PC software interface

The experimental results of the single-switch control method are shown in Figures 8 and 9.

Figure 8 shows the current waveforms of phases a/b/c throughout the entire process.

Figure 9a/b/c shows the phase relationship of the three-phase currents.

As shown in Figure 8, when the motor rotor is locked in phases a, b, and c, the current in that phase is at its maximum, satisfying the vector control principle. After the first stage of the single-switch control mode is completed, it automatically enters the second stage for high and low speed test runs. Figure 9 shows the phase relationship of the three-phase currents a/b/c during deceleration and stopping at high speed, showing that a/b/c are 120° out of phase.

5. Conclusion

Based on experimental verification and on-site customer trials, the method and apparatus described in this paper have the following advantages:

(1) Motor manufacturers do not need to pay attention to the relative position of the absolute encoder zero position and the motor rotor zero position. It can be installed arbitrarily. The entire zero position calibration process can be triggered by a single switch. The operation is simple, greatly reducing the zero position calibration process and improving the installation efficiency of the absolute encoder of the motor.

(2) The motor rotor zero-position correction process includes high and low speed test runs of the motor, which can verify whether the compensation angle is correct. At the same time, the motor can be judged whether there is a fault by observing the motor's operating status at high and low speeds, thus reducing the need for the motor manufacturer to conduct separate test runs of the motor.

(3) EEROM read/write verification mechanism to ensure that data is correctly written into EEPROM.

For more information, please follow the Motor Channel.

Read next

CATDOLL 108CM Coco – Natural Tone

Height: 108cm Weight: 14.5kg Shoulder Width: 26cm Bust/Waist/Hip: 51/47/59cm Oral Depth: 3-5cm Vaginal Depth: 3-13cm An...

Articles 2026-02-22
CATDOLL 136CM Vivian

CATDOLL 136CM Vivian

Articles
2026-02-22
CATDOLL Kelsie Hard Silicone Head

CATDOLL Kelsie Hard Silicone Head

Articles
2026-02-22
CATDOLL Diana Soft Silicone Head

CATDOLL Diana Soft Silicone Head

Articles
2026-02-22