| With the development of the textile industry step by step, The research and application of automatic computer flat knitting machine come to be the new hot spot. Servo drive system as the main execution mechanism of flat knitting machine, Which working as a key role to improve the work efficiency of the flat knitting machine. This paper have designed the knitting machine AC servo system,Which was based on permanent magnet synchronous motor. With STM32F407ZGT6 microcontroller as the control core, using vector control combine with space vector pulse width modulation technology, through the design of system hardware and software, eventually realize the goal of current, speed, position three close-loop control system.First of all, Reading a lot of relevant data of AC servo system, by fully understand AC permanent magnet synchronous model and characteristics, using Hall current sensor to detect the real-time current of stator, using incremental photoelectric encoder for detect rotor speed and position information, vector control was used to realize the application of stator current coordinate transformation, Which was combined the space vetor pulse width modulation technique to generate PWM pulse drives the moter, so as to form three closed loop control scheme of AC servo system.Secondly, By the performance requirements of knitting machine servo system, This paper has designed servo system hardware circuit and software program.The design of hardware circuit mainly have rectification circuit,IPM inverter circuit, the stator current and bus voltage detection circuit, switching power supply circuit, CPU circuit, CAN communication circuit, the encoder interface circuit, servo control signal circuit and sero alarm circuit design. Research on the software design mainly include the main program, the main servo interrupt service program, the protect of int errupt service program, CAN communication program, system design of regulator design, the rotor speed and position calculation,some research of servo key technology.Finally, using the Matlab/Simulink environment for simulation of the servo system to verify the rationality of the design, and build the test platform of servo system. At last, the experimental results were analyzed and summarized. |