Sei sulla pagina 1di 6

Control of Dynamic Voltage Restorer using

TMS320F2812

Agileswari Ramasamy, Vigna Kumaran Ramachandaramurthy, Rengan Krishna Iyer, Liew Zhan Liu.
Power Quality Research Group,
Electrical Engineering Department, University Tenaga Nasional,
Malaysia
agileswari@uniten.edu.my

Abstract— Dynamic Voltage Restorer (DVR) is a custom power Controllers (PLCs) thus causing them to malfunction. This
device that is used to compensate voltage sag. The DVR generally will lead to increase in both production and monetary loss for
consists of voltage source inverter (VSI), injection transformers, industries. As a result, it is vital to mitigate voltage sag.
passive filters and energy storage (battery). The efficiency of the Static Compensators (STATCOM) and Dynamic Voltage
DVR depends on the efficiency of the control technique involved
Restorers are two major power electronic devices that are
in switching the inverters. The inverters are switched using Space
Vector Pulse Width Modulation pulses (SVPWM) to maximize currently used to compensate voltage sag. The Dynamic
the usage of DC link voltage. The control strategy that is used to Voltage Restorer (DVR) is a power electronic device that is
generate the pulses will be illustrated in this paper. The flow used to inject 3-phase voltage in series and in synchronism
chart of the program and the modules involved in the with the distribution feeder voltages in order to compensate
implementation of the control algorithm using DSP board for voltage sag. The DVR consists of Voltage Source Inverter
TMS320F2812 will be described in detail. The implementation of (VSI), injection transformers, passive filters and energy
the control using TMS320F2812 is tested using a 3kVA lab storage [1],[2]. The inverters have low voltage ratings and
prototype and the results are presented. high current ratings as step up transformers are used to boost
up the injected voltage. The harmonics are filtered using
Keywords-Dynamic voltage restorer; voltage sag; filters. These filters are placed at the high voltage side to avoid
TMS320F2812 introductions in phase angle shift, which can disrupt the
control algorithm. In this project, compensation technique
I. INTRODUCTION which utilizes both real and reactive power, is used and lead
Power quality problems like voltage sag, harmonic and flicker acid batteries are used to provide the real power.
are major concern of industries due to enormous loss in terms Control techniques that utilize real and reactive power
of time and money. Therefore, there is an increasing compensation are generally classified as pre-sag
requirement for good power quality nowadays, which compensation, in-phase compensation and energy optimization
positively resulting in reduction of power quality problems technique [3]. For our study, pre-sag compensation is used
like voltage sag, harmonic and flicker. Voltage sag is where the load voltage is restored to its pre-sag magnitude and
considered as one of the major power quality problems as the phase. Therefore, this method is suitable for loads, which are
frequency of occurrence is very high. Voltage sag is defined as sensitive to magnitude and also phase angle shift.
a momentary decrease in rms voltage lasting between half a This paper will describe in detail the control system of the
cycle to a few seconds. The common causes of voltage sag are DVR and also the implementation of the control algorithm
faults or short circuit in the system, starting of large loads and using Texas Instrument Microcontroller (TMS320F2812).
faulty wiring. Voltage sag effect sensitive devices like TMS320F2812 is a new generation of controller with a main
Adjustable Speed Drives (ASDs) and Programmable Logic frequency of 150 MHz. The speed and the features of this DSP
make it an excellent choice for the digital control III. SPACE VECTOR PULSE WIDTH MODULATION
implementation of the Dynamic Voltage Restorer. The ( SVPWM)
modules that are used in implementing the control of the DVR This is a technique of determining the switching sequence of
and the steps involved in programming the control algorithm the upper three transistors of the three phase Voltage Source
will also be explained. Experimental results obtained from a 3 Inverter. There are eight possible output voltage states. Two
kVA lab prototype will be presented.
of the output states are null vector ( V0 and V7 ) whereas the
II. CONTROL STRATEGY other six output vectors are spatially spaced 60° apart as
shown in Fig. 2 [7].
Open loop or closed loop control algorithm can be used for the
DVR. Closed loop control gives better performance but it is
more difficult and expensive to implement. In this paper, open
loop control is used. Voltage drop across the transformer, the
switching losses and voltage drop due to line impedance is V3 V2
taken into consideration while designing the open loop control
system in order to give a more accurate compensation. Three T
2
V2
phase supply voltages (Vsa, Vsb and Vsc) are converted to T
S v( t )
stationary reference frame Vsα and Vsβ. Vsα and Vsβ are then
converted to rotating reference frame Vsd and Vsq using the V0 V1
angle obtained from the SPLL [1][4],[5]-[6]. Vsd and Vsq are V4
V7 T
dc values. During a fault, these dc values will drop and the T
1
V1

difference between the pre-sag value and sagged value will S

form an error signal. The block diagram of the control system


used is shown in Fig.1.

The delta-open injection transformer introduces a 30º phase V5 V6

shift, the error is also shifted by 30 º. This error signal is then


converted back to form Vsα_error and Vsβ_error which is then
Figure 2. Voltage space vectors representing eight possible switching states
modulated using Space Vector Modulation to produce the
required pulses to switch on the inverter, thus restoring the
load voltage [6]. Space Vector Pulse Width Modulation is
The voltage space vector is synthesized by time-weighted
used to switch on the inverters as it is easily programmable
averaging of the two adjacent basic non-zero voltage vectors
using DSP and it fully utilizes the DC link voltage [5].
that form the sector in which the reference voltage space
vector to be synthesized lies. Thus if the reference voltage
space vector lies in the first sector, voltage space vector V1 is

Vsd-ref

Vsa Vsd - Vsd-error


Vsα Vsα -error
Vsb abc αβ Vsq + dq to SVPVM
Pulses to
to Vsβ Vsq-error αβ Vsβ -error the inverter
Vsc to dq
+
αβ -

θ Vsq-ref
SPLL

shifted

Figure 1. Block diagram of the control system


active for duration T1 and voltage space vector V2 is active
for duration T2 within the switching period, TS as shown in Fig
3. The switching sequence is arranged following the sequence
V0 - V1 - V2 - V7 - V7 - V2 - V1 - V0 [7]. The reference vector
v(t ) can be described equations (1) to (4).
Ta

[v(t )] = TT1
V1 +
T2
TS
T
TS
T
V2 + 0 V0 + 7 V7
TS
(1) Tb
S

where T1 =
2 TS
[
0.866Vα − 0.5Vβ ] (2) Tc
3 VDC
Figure 4. Switching pattern of sector one

T2 =
2 TS
Vβ [ ] (3)
3 V DC IV. TMS320F2812
TMS320F2812 is a new generation controller with a main
frequency of 150MHz. It has 12 Pulse Width Modulation
and T0 + T7 = Ts − T1 − T2 (4) (PWM) outputs and 12–bit analog to digital converter. The
fast conversion period, which is about 80ns, is very suitable
for real time sampling. The speed and the features of this DSP
make it an excellent choice for the digital control
implementation of the Dynamic Voltage Restorer. In this
project, A/D conversion, implementation of the control
algorithm, which includes Software Phase Locked Loop to
detect the angle and generation of Space Vector Pulse Width
Modulation, are implemented using DSP. The two major
modules that are used in this project are the ADC module and
the Event Manager Module.
A. ADC Module
The ADC module has sixteen channels and takes in input
between 0 to 3V. The conversion time is 12.5 MSPS, which is
very suitable for real time sampling as it has high accuracy.
The ADC can operate either in simultaneous or sequential
Figure 3. Synthesizing reference voltage space vector in sector one
sampling mode. Furthermore, the start-of –conversion (SOC)
sequence can be triggered by software, event manager or by
external pin [8].
Based on the switching time of each sequence, the duty cycle
B. Event Manager Module
to generate the SVPWM for sector 1 can be obtained using
the following equations. The Event Manager (EV) module consists of general purpose
(GP) timers. Full-compare/PWM units, capture units, and
T0 quadrature pulse (QEP) circuits [9]. There are two general
Ta = (5) purpose timers in each EV module. In this project both timers
4 of Event Manager A (EVA) are used.
T1
Tb = Ta + (6) V. PROGRAMMING TMS320F2812
2
T2 The program is divided into modules where in the main()
Tc = Tb + (7) program all system initializations are carried out and then it
2
enters an endless loop that waits for the ADC interrupt. Two
timers of Event Manager A is used. GpTimer1 is used to
This switching pattern is illustrated in Fig. 4 below. trigger the PWM signals whereas GpTimer2 is used to trigger
the ADC. When the ADC interrupt is received which is
triggered by GPtimer 2 of Event Manager A, the following
processes takes place:-
a) The values of three phase voltages are read from the ADC Vref and Vsd value form an error signal. This error signal is
registers. The supply voltages are connected to ADCIN_A0, used as the control signal to generate the Space Vector Pulse
ADCIN_A1 and ADCIN_A2. The results are read from three Width Modulation signal. The flow chart of the control
registers, which are AdcRegs.ADCRESULT0, algorithm is shown in Fig. 7.
AdcRegs.ADCRESULT1 and AdcRegs.ADCRESULT2 . The
A. Generation of SVPWM in TMS320F2812
ADC results for a few samples are shown in Fig. 5, which
matches the supply voltage. This indicates the ADC operation The flow chart for programming the SVPWM in DSP is
is working as desired. shown in Fig. 8 [10]. The calculation of T1, T2, T0 and Ta, Tb
and Tc are following equations (5) - (7). CMPR1, CMPR2 and
CMPR3 are compare registers in the Event Manager module.
Three phase voltage values obtained from Pulses are generated by comparing these values with the GP
ADC Timer1. GPTimer1 is set to continuous up/down mode and the
values of Ta,Tb and Tc are loaded into CMPR1,CMPR2 and
3 CMPR3 respectively. The generation of the space vector pulse
by this method is illustrated in Fig. 9.
Voltage

1 Determination of the
sector
0
4]

1]
8]

5]

2]
9]

6]

3]
0]

7]
]
]
[0
[7
[1

[2
[2

[3

[4
[4

[5

[6
[7

[7

Sam ples Calculation of T1, T2


and T0.

Figure 5. Three phase supply voltage obtained from the ADC


Determination of duty
b) These values are then converted to two phase stationary cycle Ta, Tb and Tc
reference frame, Vsα and Vsβ using Clark’s transformation and
then converted to two phase rotating reference frame, Vsd and
Vsq using Park’s Transformation. The angle of the system is
obtained from the Software Phase Lock Loop that is also Assigning
chart for programming theduty cycle in DSP is shown in Fig.
SVPWM
programmed in the DSP.. The plot of Vsd and Vsq are shown in to CMPR1,
8 [10]. The calculation of T1, T2, T0 and Ta, Tb and Tc are CM
Fig.6. These plots clearly indicate that the SPLL is working as CMPR2 and CMPR3
desired. Vsd is a dc value whereas the Vsq is zero. This dc value
is then compared with a reference value Vref.. When there is
sag.Vsd’s value will drop and the difference between Figure 8. Flow chart for programming SVPWM

Figure 6. Plot of Vsd and Vsq versus time


Figure 9. Generation of SVPWM pulse by timer
comparison
B. SVPWM pulses obtained from TMS320F2812 The SPVWM pulses for sector 5, captured using an
The full control algorithm was programmed using the DSP oscilloscope is shown in Fig. 10. The pulses clearly illustrates
and the output from pin PWM1, pin PWM3 and pin PWM 5 the program is working as desired
was observed for few scenarios using the oscilloscope.

a) When there is no sag, there are no pulses seen on the


scope. This is as desired as the inverters should only be on
when there is sag.

b) When there is sag, the pulses are formed depending on


the magnitude of the sag. The width of the pulses
changes as the magnitude of the error signal changes. This
clearly indicates the control algorithm is working as
desired.

Figure 10. SVPWM pulse for sector 5

Start
ADC ISR

System
Read three phase voltage
initialization
values

Initialize timer Convert to two phase


stationary reference frame

Convert to two phase


Enable global rotating reference frame
interrupts

Determine modulating signal for Space Vector


Pulse Width Modulation (SVPWM)

Wait for ADC Implement SVPWM


interrupt

Determine toggling
sequence

Enable
Interrupt
return

Figure 7. Flow chart of the control implementation


VI. EXPERIMENTAL RESULTS The waveform clearly illustrates that there is only injection
A 3 kVA lab prototype was successfully commissioned in the when there is drop in supply voltage and the DVR is able to
lab. The block diagram of the lab prototype is shown in Fig.11 restore the load voltage to nominal value when there is a sag.
below. The incoming three phase supply voltage is fed into the
voltage sag generator unit. The output of the voltage sag VII. CONCLUSION
generator unit is connected to the Delta / Wye isolation This paper presented the detailed implementation of the DVR
transformer. The DVR injects active and reactive power into control algorithm using DSP board TMS320F2812. The
the system via three series injection transformers. The DVR operating principle of the DSP board and also the generation
obtains its active power from a lead acid battery bank. The of the SVPWM pulses are discussed. A general overview of
supply voltage used was 415V. A sag generator was used to the DVR lab prototype is also presented. The experimental
initiate a sag. results clearly indicate the successful implementation of the
control algorithm using TMS320F2812.

REFERENCES
[1] Zhan, V. K Ramachandaramurthy, A. Arulampalam,C. Fitzer,. Barnes,
S. Kromlidis, N. Jenkins, “Dynamic Voltage Restorer based on voltage
space vector PWM control”, Sixteenth Annual IEEE, Applied Power
Electronics Exposition, 2001, APEC 2001, Volume: 2, 4-8 March 2001,
pp. 1301 – 1307.
[2] A. Ramasamy, K.I Rengan, V. K Ramachandaramurthy, “Dynamic
Voltage Restorer for Voltage Sag Compensation”, International
Conference on Power Electronics and Drive Systems(PEDS) 2005,
Volume 2, 28-01, Nov. 2005, pp.1289-1294.
[3] J. G. Nielsen, F. Blaabjerg, N. Mohan, “Control strategies for dynamic
voltage restorer compensating voltage sag with phase jump”, Sixteenth
Figure 11. Block diagram of the experimental setup Annual IEEE, Applied Power Electronics Conference and Exposition,
2001, APEC 2001, Volume: 2, 4-8 March 2001, pp. 1267 – 1273.
[4] Gu. H. Jung, Guk C. Cho, Soon W. Hong, Gyu H. Cho, “DSP based
The waveform of the supply, load and injection voltage when control of high power static VAR compensator using novel vector
there is no sag (no fault) is shown in Fig.12 whereas for the product phase locked loop”, 27th Annual IEEE Power Electronics
case when there is a sag is shown in Fig.13. Specialists Conference, 1996. PESC '96 Record, Volume: 1, 23-27 June
1996, pp. 238 – 243.
[5] C. Zhan, C. Fitzer, V. K Ramachandaramurthy, A. Arulpalam, M.
Vsupply Vload Barnes, S. Kromlidis, N.Jenkins, “Software Phase-Locked Loop applied
to a Dynamic Voltage Restorer (DVR)”, Proceedings of IEEE Power
Engineering Society Winter Meeting, 2001, Volume 3,pp. 1033-1038.
[6] V. K Ramachandaramurthy, C. Fitzer, A. Arulampalam, C. Zhan, M.
Barnes, N. Jenkins, “Control of Battery Supported Dynamic Voltage
Restorer”, IEE Proceedings on Generation, Transmission and
Distribution, Volume: 149, Issue:5, Sept. 2002, pp. 533 – 542.
Vinjection [7] C. Zhan, A.Arulampalam, V. K Ramachandaramurthy, M. Barnes, C.
Fitzer, M. Barnes, N.Jenkins, “Dynamic Voltage Restorer based on 3-
dimensional voltage space vector PWM algorithm”, Proceedings of
IEEE 32 nd Power Electronics Specialist Conference(PESC) 2001,
Figure 12. Plot of Vsupply,Vload and Vinjection when there is no sag
Vancouver, Canada. 2001.
Vsupply Vload [8] TMS320C281x Event Manager Reference Guide (SPRU065), Texas
Instrument.
[9] TMS320C281x Analog to Digital Converter Reference Guide
(SPRU060), Texas Instrument.
Vinjection [10] Ying-Shieh Kung; Pin-Ging Huang, “High performance position
controller for PMSM drives based on TMS320F2812 DSP”, Proceedings
of the 2004 IEEE International Conference on Control Application,
Volume: 1, 2-4 Sept. 2004, pp. 290-295

Figure 13. Plot of Vsupply,Vload and Vinjection when there is sag

Potrebbero piacerti anche