IJCST Vo l 1, Is s u e 2, De ce m b e r 2010 Design and Simulation of Digital PID Controller for Open loop and Closed Loop Control of Buck Converter 1 P Geethanjali, 2 P Vijaya Priya, 3 M Kowsalya, 4 J Raju 1,2,3,4 VIT University, Vellore E-mail : 1 pganjali78@hotmailcom, 2 pvijayapriya@vitacin, 3 mkowsalya@vitacin, 4 jraju@vitacin Abstract This paper presents an implementation of an open loop and closed loop digital PID controller using microcontroller, 8051 for control of buck converter The controller is used to change the duty cycle of the converter and thereby, the voltage is regulated The buck converter, P, PI and PID controller are modeled and are evaluated by computer simulations It has been found that the transient performance and steady state performance is improved using PID controller The simulated open loop and closed loop PID controller performance is verified experimentally The experimental system is found to be more advantageous and cost effective with microcontroller Keywords Buck converter, PI controller, Microcontroller, Open loop, Closed loop I Introduction To produce quality goods in any industry, the process necessarily require the use of variable speed drives Variable speed dc and ac drives are being increasingly used in all industries These drives and process take power from dc voltage sources In many cases, conversion of the dc source voltage to different levels is required Until eighties, the simulation programs developed for the study of converters in open loop control were sufficient to establish the general behaviour of the system and make the design of the circuit possible Liping Guo [3] explained implementation of digital PID controllers for DC-DC converters The primary advantages of digital control over analog control are higher increased flexibility by changing the software, more advanced control techniques and reduced number of components [10] Analog converters were first designed using frequency response techniques and converted into digital controllers [7] Dusan Gleich et al [1] explained digital controlled buck converter with different control algorithms All control algorithms are performed at a continuous current mode of operation The state controller eliminates the overshoot at startup, but the steady state error appears The steady state error is eliminated using a discrete PID controller [7] This discrete PID controller has faster response and smaller overshoots under the load change condition [3-5] Vahid Yousefzadeh and Shamim Choudhury [2] explained an approach for the design and implementation of a non-linear digital PID controller It shows that the Proportional, Integral and Differential gains of a PID controller can be selected based on the input error signal value to achieve significantly improved dynamic response A PID controller is designed using MATLAB functions to generate a set of coefficients associated with controller characteristics and implemented in microcontroller To assure a constant output voltage, a classical linear design of a control is frequently used The regulation is achieved by pulse width modulation (PWM), technique at a fixed frequency The switching device is a power MOSFET The paper is organized as follows Mathematical modeling of dc-dc converter and digital controller is given in section 2 Section 3 describes implementation of MATLAB based controller Experimental results are obtained for both open loop and closed loop for P, PI and PID controller Microcontroller based implementation is presented in section 4 Concluding remarks are given in section 5 II Mathematical Modelling of Buck Converter and Digital Controller A Mathematical Modelling of Buck Converter The buck converter consists of linear elements L, C, R as well as non linear switch S as shown in Fig1 The converter is not a linear system Dynamic equation of the converter is written with the assumption that switch is a linear element [6] Fig1: Buck Converter The output equation of the circuit for the ON period is The output equation of the circuit for the OFF period is V o = V c (6) 202 International Journal of Computer Science and Technology
IJCST Vo l 1, Is s u e 2, De ce m b e r 2010 Where i 1 is current through the inductor V c is voltage across the capacitor V d is DC input voltage The above equations are in state-space model form (14) During ON-time During OFF-time Where, x = A1 x + b1v d ; V o = q 1 x x = A2 x + b2vd ; V o = q 2 x (7) (8) For simulation, the following values are used to simulate the buck converter R = inf Ω, L = 4215mH, C = 1000μF, RL = 11 Ω and Vd = 24 V B Mathematical Modelling of PID Controller The PI controller in the continuous time domain is described by u( s) Ki Gc ( s) = = K p + + K d s E( s) s (15) The proportional constant K p is implemented digitally by a constant gain Since a digital computer or processor has finite word length, the constant can not be realized with infinite resolution The numerical integration technique ie trapezoidal rule of integration can be used to digitally approximate The above representation is in standard state space form for each interval A representation of the buck converter through a single equivalent dynamic equation is obtained, combining 27 and 28 as given below Where, xavg is the average rate of change of dynamic variables over a full switching period The above equivalent description is valid if xdts and x (1-d) T s are constant during the ON and OFF duration respectively The averaged dynamic equation is x = Ax + Bv d (10) The linear model of 210 is given below (9) the integral controller K i /s The time derivative can be approximated by backward difference rule Transfer function of the PID controller is obtained by taking z-transform of the difference equation as given below (16) III Simulation of Open Loop and Closed loop Control of Buck Converter using MATLAB Open loop and closed control of buck converter is analyzed in MATLAB for the model discussed in section 2 Open loop simulink model of buck converter is shown in Fig 2 and the results of buck converter for duty ratio of 065 are shown in Fig 3 x = A x+ b v g + [( A1 + A2 ) x + ( b1+ b2 ) vg ] d = A x + b v g + f d (11) From the above linear model of the converter we may define the transfer function of the converter as follows Input Transfer function: ( d =0) Fig 2: Open loop simulink model of buck converter (12) (13) Simulink model of closed loop PID control of buck converter is shown in Fig 4 The performance of controller with P, PI, PID controller is shown in Fig 5, Fig 6 and Fig 7 respectively Fig 3: Output Voltage open loop buck converter for Vref = 15V Control Transfer function: ( v g (s) =0) International Journal of Computer Science and Technology 203
IJCST Vo l 1, Is s u e 2, De ce m b e r 2010 Fig 7: Output Voltage of buck converter for Kp = 6, Ki =1, Kd = 00001, Vref = 15V From the performance of open loop and closed loop control of buck converter, it is clear that closed loop controlled buck converter outperform the open loop controlled buck converter In closed loop control of buck converter, PID controller gives improved transient and steady state performance compared to other controller IV Hardware Implementation Buck converter and digital PID controller modeled in MATLAB has been experimentally verified Fig 8 and Fig 9 show the schematic diagram of open loop and closed loop control of buck converter with 8051 microcontroller Fig 4: Closed loop simulink model PID of buck converter Voltage Time (Sec) Fig 5: Output Voltage of buck converter for Kp = 6, Ki =0, Kd = 0, Vref = 15V V Re Fig 8: Schematic diagram of open loop control of buck converter with microcontroller Voltage Time (Sec) Fig 6: Output Voltage of buck converter for Kp = 6, Ki =1, Kd = 0, Vref = 15V Fig 9: Schematic diagram of closed loop control of buck converter with microcontroller 204 International Journal of Computer Science and Technology
IJCST Vo l 1, Is s u e 2, De ce m b e r 2010 8051 microcontroller has two 16-bit timer/counter registers namely timer 1 and timer 2 Both can be configured to operate either as timers or event counters In this work timer 1 is configured to generate PWM pulses in TCON register For closed loop control, ADC0808 is used for interfacing analog circuit and comparator circuit Fig 10 show the interfacing of ADC with microcontroller Port 0 is used as input port to read data Port 3 is used for getting output To isolate power circuit and control circuit optocoupler is used This symmetric PWM output is not capable of driving the MOSFET Driver is used to amplify the output of the optocoupler and is connected to the gate of the MOSFET Fig 11 show the laboratory set up of closed control of buck converter Fig 12 and Fig 13 show the open loop and closed loop control flow chart Fig 14 shows the driver circuit output and output of the buck converter Fig 10: Interfacing of microcontroller with ADC0808 Fig 12: Flow chart for open loop control of buck converter Fig 11: Laboratory set up of closed loop control of buck converter Fig 13: Flow chart for open loop control of buck converter International Journal of Computer Science and Technology 205
IJCST Vo l 1, Is s u e 2, De ce m b e r 2010 Fig 14: Output of driver (CRO) and buck converter (Multimeter) V Conclusion As concluding remark, the performance of the open loop and closed performance is analysed using MATLAB and found that the performance of closed loop controller gives satisfactory response with buck converter It is found that the step response of digital PID controller implementation in microcontroller 8051 is simple and can implement in cost-effectively In future it can be extended to study the performance of intelligent controller References [1] Dusan Gleich, Mira Milanovic, Suzana Uran, Franic Mihalic Digitally controlled buck converter IEEE power electronics society ISCAS-2004, pp-v944-v947 [2] Vahid Yousefzadeh and Shamim Choudhury Nonlinear Digital PID Controller for DC-DC Converters Texas Instruments, Digital Power, pp-1704-1709 [3] Liping Guo Implementation of Digital PID Controllers for DC-DC Converters using Digital Signal Processors IEEE power electronic society EIT-2007,pp-306-311 [4] Jianxin Tang PID controller using the TMS320C31 DSK with on-line parameter adjustment for real time dc motor speed and position control IEEE-ISIE-2001, pp- 786-791 [5] SumantGKadwane, Someswara Phani Vepa, BMKaran, T Ghose, Converter Based DC Motor Speed Control Using TMS320LF2407A DSK, IEEE-ICIEA-2006 [6] Mohan, Underland, Robbins Power Electronics converters applications and design John Wiley & sons, inc 2003 pp- 231-303 [7] M Gopal, Digital control and state variable methods, M Gopal, TATA McGraw Hill edition [8] httpwwwmicrochipcom [9] Chin Chang, Robust control of DC-DC converters-the Buck Converter, Power Electronics Specialists Conference- PESC, 26th Annual IEEE-1995 [10] Tarun Gupta, RR Boudreaux, RM Nelms and John Y Hung, Implementation of a fuzzy controller for DC-DC converters using an inexpensive 8-b Microcontroller, IEEE Transactions on Industrial Electronics, Vol 44, No5, October 1997 P Geethanjali received the BTech degree in Electrical and Electronics engineering from Vellore Engineering College in 2001, M Tech degree in Electrical drives and control from Pondicherry Engineering College in 2004 She is doing research in the area of is control of prosthetic hand from VIT University She has published papers in various journals and international conferences Her interest includes pattern recognition, softcomputing, and controller design using DSP Ms Geethanjali is IEEE Member and Associate member of IE(I) and member in SSI MKowsalya was born in India in 1974 She received BE degree in Electrical and Electronics Engineering and ME degree in Power Systems from Annamalai University in the year 1995 and 1997 Her research interests are power system stability and power electronics applications in power systems She has published papers in international journals and international conferences MKowsalya is a member in institute of Engineers (India) [AMIE] and Life member in ISTE and SSI Vijayapriya Tamilmaran was born in India in 1976 and obtained her bachelors degree in Vellore Engineering College, Vellore, Tamilnadu, India in the field of Electrical and electronics Engineering in 1998 and M Tech from Vellore Institute of Technology in 2006 in Power system She has published paper in various international conferences and also in International Journal of Engineering and Technology and her current area of interest is on UPFC and Smart Grid Mrs Vijayarpiya is a Associate member of IE and member in SSI J Raju obtained his bachelors degree in Government college of Engineering, Bargur, Tamilnadu, India in the field of Electrical and Electronics Engineering in 1998 and M Tech from Vellore Institute of Technology in 2004 in Power Electronics He has published paper in various international conferences and also in International Journal of Engineering and Technology and his current area of interest is on FACTS controller Mr J Raju is a member of ISTE and member in SSI 206 International Journal of Computer Science and Technology