A mechatronic leveling control system is presented in this paper, which is constituted with Programmable Logic Controller (PLC), Permanent-magnet synchronous motor (PMSM), high precise level obliquity sensor and mechanical drive system. A hybrid closed loop control structure of AC servo is proposed for this system, and the mathematical model is built. A kind of P-fuzzy-PID control, which includes proportional control, fuzzy control and Proportional-Integral-Differential (PID) control adopted respectively according to different level error, is brought forward and the fuzzy controller is designe...