In UPS, Battery mode and electric mode usually use a common boost converter to translate different input voltage into a same DC bus voltage. In this paper, the mathematic model of the boost converter based on PWM three-terminal switch device is derived. To obtain good dynamic performance during the input voltage changes, a directly digital dual-loop controller design method based on Matlab/Simulink is proposed and the universal calculation formulae are derived. Experimental results of a 3.3 kW boost converter used in 380V UPS show that the controller has good dynamic performance.