Through the comparison and analysis of the current design methods of active filter and power quality controller, a design scheme of power quality controller with DSP chip TMS320LF407 as microcontroller is proposed. The powerful computing function of the chip and the integrated event manager peripheral can easily realize real-time harmonic suppression, reactive power compensation, load balancing and voltage reduction flicker. In addition, using the rich internal and external peripherals of the chip and the intelligent driver chip selected in the circuit, many auxiliary functions such as overvoltage, overcurrent, serial communication, etc. are extended for the controller. This scheme reduces the design complexity and design cost of power quality controller, and has reference significance for the productized design of power quality controller.