• No results found

To confirm the findings of the simulation, a low power Buck converter has been built to closely match the one in simulation. Special consideration has been made when selecting components to account for parasitics. Each passive component is measured with an Agilent U1733C LCR meter over a range of frequencies with the average results found in Table 5.1.

Table 5.1 Actual Component Values for Buck Converter

Component Rated Value Measured Value

Inductor 330µH 333µH

Inductor DC Resistance N/A 0.54Ω

Capacitor 470µF 420µF

Capacitor ESR N/A 0.23Ω

Load Resistor 10Ω 10.1Ω

The controller used is the PIC32MX460F512L-80I/PT from Microchip built on a custom carrier board. This particular controller can operate up to 80 MHz which will allow for finer resolution of the generated RPWM. The onboard ADCs will not be used as the excess overhead necessary would quickly outpace the abilities of the controller. Instead, the necessary measurements are made using a Labview NI-USB-6009 14-bit data

rate of 24 kHz which is in line with the simulations. The use of the data acquisition unit has the added benefit of being able to easily export the measured data in a format that can be read by MATLAB. This means that the same fitting code used for the simulations can be used on the measured data. Voltage is measured directly while the current is measured using the ACS712ELCTR-30A current sensor on a custom made sensor board. (Figure 5.1)

Figure 5.1 Current sensor schematic

To match the simulations, the first impedance measured is the parallel combination of the output capacitor and load resistor. The following plots show the measured reconstruction of the selected impedance versus the actual impedance for two different capacitor values. (Figure 5.2 and Figure 5.3)

Figure 5.2 Hardware validation C = 470µF

Figure 5.3 Hardware Validation C = 800µF

Much like the simulations, both reconstructions follow the actual impedance very closely. The change in corner frequency as well as the difference in ESR is clearly

be noted that while there is a spike on the frequency spectrum, its magnitude is relatively small and is most likely caused by the limited resolution of the controller’s RPWM sequence. In terms of impedance measurement, its presence goes unnoticed.

Figure 5.4 Measured current frequency spectrum

Next, the previous methods for inductor estimation are used to calculate the value of the real components. It is important to note that while the inductor voltage could be determined by the known converter switch states and output voltage, here a differential voltage measurement is made across the inductor. For the particular data acquisition unit used, the sampling frequency for three channels (current, output voltage, and switched voltage) reduces the maximum sampling frequency to 16kHz. This in turn limits the maximum identifiable frequency to 8kHz. Below are the impedance reconstructions using two separate inductor values, showing just the range of injected frequencies. (Figure 5.5 and Figure 5.6)

Figure 5.5 Impedance reconstruction with L=330µH

These impedance reconstructions show a close matching to the expected actual values. When numeric values for inductance are calculated, the results are very

promising. (Table 5.2) Factors such as measurement error have been eliminated as much as possible by calibrating the sensors against known voltage and current sources.

Table 5.2 Calculated Inductance Values

Rated Inductance Calculated Without Fitting (percent error)

Calculated With Fitting (percent error)

330µH 372µH (12.6) 367µH (11.3)

CHAPTER6

P

RACTICAL

C

ONSIDERATIONS FOR IDENTIFICATION

The goal of this thesis is to develop a method for impedance identification for real systems. That makes it necessary to consider practical limitations of the system when developing these procedures.

6.1 Sampling Time and Frequency

As the DFT is a summation of multiplications, it can quickly become

computationally taxing. For this reason, fast Fourier transforms will be used. The FFT is able to reduce the number of operations to as opposed to for the more general Fourier transform. [18] Most modern digital signal processors contain highly efficient FFT functions that simplify the implementation of these techniques. The total execution time of the FFT algorithm is determined by the processor execution time, and the length of the sampled data. Table 6.1 demonstrates the time savings possible by using the FFT over the standard Fourier transform.

Table 6.1 Execution Comparison Between Fourier Transform and FFT Number of Samples Fourier Transform

Number of cycles FFT Number of cycles 128 16384 621 256 65536 1420 512 262144 3194 1024 1048576 7098

The FFT length is determined by both the system sampling frequency, and the length of the sampling period. The sampling frequency and the sampling period both play a role in the final resolution in the frequency domain. This resolution is the maximum number of Hz between any two given samples after preforming the FFT and is calculated by (19)

number of samples frequency resolution

sample frequency

 (19)

This frequency resolution is important as it is one of the determining factors in the final quality of the system identification. If we consider a simple RL circuit, the

frequency resolution determines the change in inductor value it would be possible to identify under ideal conditions. (Figure 6.1) In this example, a fixed resistance of 10Ω is used while the inductor value is changed from 1mH to 1.5mH. At the 3dB point of each graph, there is a difference of approximately 50Hz between the two plots. Therefore, if the goal was to distinguish between inductances of 1mH and 1.5mH at their

corresponding corner frequencies, the frequency resolution would need to be at least 50Hz.

Figure 6.1 Importance of frequency resolution

Ideally, one would use the longest sample period possible to provide for the highest possible frequency resolution. Practically speaking, this sampling period is limited by two factors; how frequently identification is needed, and memory restrictions of the controller. Consequently, physical parameters of the controller as well as desired identification resolution determine the sample period length and in turn, the maximum frequency resolution.

6.2 Sampling Resolution

Another factor in determining the accuracy of identification is the precision of the measuring devices. Possible measurement error falls under two main categories:

or ADC. Much like the aforementioned frequency resolution, the ability to discern between two possible impedance values is limited by the measurement resolution. The Bode plot of two simple RL circuits is shown below. (Figure 6.2) For both plots, the inductance is held constant at 1mH while the resistance is changed from 5Ω to 7Ω. It is clear to see that for frequencies in the region of 250Hz, the two magnitudes differ by only 3dB. This requires that the ADC be able to discern at least this 3dB difference to be able to identify a change in resistance of 2Ω.

Figure 6.2 Importance of ADC resolution to identification

Not only is the relative accuracy of the measurement important, but so too is the linearity of the sensor and ADC. For simple control systems, it is often assumed that the feedback system is purely a frequency independent gain block. In reality, feedback networks contain several frequency dependent components including the sensor,

amplifiers, filters, and any system parasitics. Because the final goal of identification is to gather frequency dependent information, it is crucial that any frequency distortion introduced by the feedback network be well above the range of frequencies of interest. If the feedback loop attenuates frequencies within the identification band, the values may become too small to discern from the existing noise. For example, the ADS7863 from Texas Instruments is a dual, 12-bit ADC capable of sampling rates up to 2MSPS. From the datasheet it can be seen that with an increase in frequency there is also a decrease in the signal to noise ratio and an increase in total harmonic distortion. (Figure 6.3)

Figure 6.3 Typical ADC frequency characteristics (TI ADS7863) When selecting components for such systems, it is important to ensure that nothing in the sensing loop will add unknown frequency distortion. As the region of interest is below the switching frequency, the feedback loop should already meet these requirements, but it is still good practice to ensure there will not be any unnecessary error introduced by the sensing loop.

CHAPTER7

C

ONCLUSION AND FUTURE WORK

The objective of this work is to show the viability of using Randomized Pulse Width Modulation as a means of impedance identification in switching power converters while also minimizing the amount of harmonic noise. By monitoring the impedance of elements within the control loop, digital controllers can adapt and perform a better job of regulating the outputs. This in turn can lead to more efficient controllers, as well as the use of cheaper components that have a higher variation from their normal value as well as a greater degree of non-linearity.

The use of RPWMII as a source of accurate impedance estimation while also reducing injected harmonics has been demonstrated. Using the power converter’s existing voltage and current sensors, the necessary values are sampled at a fixed frequency. Fast Fourier transforms are then used to convert this time domain data into the frequency domain. A complex impedance value can then be calculated using these voltage and currents and Ohm’s law. Next, a trend line is created using the least squares fitting algorithm to help eliminate any spurious noise present in the measurements. The

parameter value in question can then be solved for using the known impedance equation and the measured complex impedance over the range of injected frequencies. These methods have proven to be accurate in the estimation of impedances with DC as well as AC systems. Simulations have shown a percent error of less than 10 percent when estimating the inductance within a Buck converter and a grid tied inverter. These

simulation findings have also been validated through hardware testing on a low powered Buck converter. The concept of harmonic reduction through the use of RPWMII has also been confirmed. By spreading injected noise over a wider frequency spectrum, the large spikes common with standard switching techniques can be greatly reduced. This achieves the desired goal of converter element impedance estimation while simultaneously

reducing harmful harmonic injections. Future Work

As the main focus of this research is on the development of the use of RPWMII for impedance estimation, a smaller amount of time has been spent on implementing the results of such measurements. Future work could use these measured impedances to update closed loop control systems in real time. To implement these techniques into a final physical device would require careful attention to the abilities of the controller as well as the structure of the overall program. As great quantities of sampled data are being stored locally, large amounts of robust, fast memory would be necessary. The feasibility of such systems should only improve with time as the cost of more capable devices and memory are trending downwards. Also, ongoing developments in the field of Digital Signal Processing have shown the possibility of even more efficient FFT algorithms. [19] Such “sparse” FFT implementations could lessen the requirements of the identification system.

One interesting possibility is the use of machine learning to improve the

impedance estimations. The methods used here are admittedly simplistic in their attempts at data fitting to a parametric model. The emerging field of machine learning has shown

constantly evolving systems. Such a system could possibly recognize and act on patterns not immediately obvious to the programmer.

R

EFERENCES

[1] Ming-Tsung, "Analysis and Design of Three-Phase AC-to-DC Converters With High Power Factor and Near-Optimim Feedforward," IEEE Transactions on Industrial Electronics, vol. 46, no. 3, pp. 535-543, 1999.

[2] M. P. Kazmierkowski, "Review of Current Regulation Techniques For Three-Phase PWM Inverters," in IEEE ISIE, 1993.

[3] A. L. Trigo, "A Linear Time Model of The Voltage Source Converter for STATCOM Applications," in PSCC, Liege, 2005.

[4] P. Lehn, "Exact Modeling of the Voltage Source Converter," IEEE Transactions on Power Delivery, vol. 17, no. 1, pp. 217-222, 2002.

[5] D. Martin, "Auto Tuning of Digital Deadbeat Current Controller for Grid Tied Inverters Using Wide Bandwidth Impedance Identification," IEEE, pp. 277-284, 2012.

[6] B. Miao, "System Identification of Power Converters With Digital Contol Through Cross-Correlation Methods," IEEE, pp. 1093-1099, 2005.

[7] D. Martin, "Wide Bandwidth System Identification of AC System Impednace by Applying Perturbations to an Existing Converter," IEEE, pp. 2549-2556, 2011. [8] A. Barkley, "Improved Online Identification of Switching Converters Using Digital

Network Analyzer Techniques," in Power Electronics Speacialists Conference,

PESC 2008. IEEE, 2008.

[9] K. Borisov, "Experimental Investigation of Submarine Drive Model With PWM- Based Attenuation of Acoustic and Electromagnetic Noise," University of Nevada, Reno, 2003.

[10] K. Borisov, "Attenuation of Electromagnetic Interference in a Shunt Active Power Filter," IEEE Transactions on Power Electronics , vol. 22, no. 5, pp. 1912-1918,

2007.

[11] L. Ljung, System Identification: Theory for the User, Englewood Cliffs: Prentice- Hall, 1987.

[12] Q. Bi, "Robust Identification of First-order Plus Dead-time Model from Step Response," Control Engineering Practice , vol. 7, pp. 71-77, 1999.

[13] S. Ahmed, "Novel Identification Method from Step Response," Control Engineering Practice, vol. 15, pp. 545-556, 2007.

[14] D. S. Moore, The Basic Practice of Statistics 3rd Edition, New York: W. H. Freeman and Company, 2004.

[15] R. W. Erickson, Fundamentals of Power Electronics Second Edition, Norwell: Kluwer Academic Publishers, 2001.

[16] A. Barkley, "Adaptive Control of Power Converters Using Digital Network Analyzer Techniques," University of South Carolina, Columbia .

[17] D. Martin, "Wide Bandwidth Three-Phase Impedance Identification using Existing Power Electronics Inverter," IEEE, pp. 334-341, 2013.

[18] J. H. McClellan, DSP First, Upper Saddle River: Prentice-Hall, 1999.

[19] H. Hassaneih, "Simple and Practical Algorithm for Sparse Fourier Transform," in

A

PPENDIX

A–RPWMIIMATLABS-F

UNCTION function RPWMtwo(block) setup(block) %endfunction %%

% 1 - Get system parameters % 2 - Enter loop

% 3 - Get system time

% 4 - If system time == n*sample time % - Sample inputs

% - Calculate time delay

% - If system time == calculated time set pwm % - Set sampled outputs

%

%% Function: setup =================================================== %% Abstract:

%% Inputs

% 1 - Duty Cycle Reference % 2 - System Time % 3 - Random Values %

%% Outputs

% 1 - Sampled input data % 2 - Generated PWM % 3 - Generated Frequency %% function setup(block) block.NumInputPorts = 3; block.NumOutputPorts = 3;

% Setup port properties to be inherited or dynamic block.SetPreCompInpPortInfoToDynamic; block.SetPreCompOutPortInfoToDynamic;

% Override input port properties

block.InputPort(1).Dimensions = block.DialogPrm(1).Data; %Reference block.InputPort(1).DatatypeID = 0; % double

block.InputPort(1).Complexity = 'Real'; block.InputPort(1).SamplingMode = 'Sample'; % Override input port properties

block.InputPort(2).Dimensions = 1; %System Time block.InputPort(2).DatatypeID = 0; % double

block.InputPort(2).Complexity = 'Real'; block.InputPort(2).SamplingMode = 'Sample';

block.InputPort(3).Dimensions = block.DialogPrm(6).Data; %Sample inputs block.InputPort(3).DatatypeID = 0; % double

block.InputPort(3).Complexity = 'Real'; block.InputPort(3).SamplingMode = 'Sample';

% Override input port properties

block.OutputPort(1).Dimensions = block.DialogPrm(1).Data; %Sampled data block.OutputPort(1).DatatypeID = 0; % double

block.OutputPort(1).Complexity = 'Real'; block.OutputPort(1).SamplingMode = 'Sample';

% Override input port properties

block.OutputPort(2).Dimensions = block.DialogPrm(6).Data; %Generated PWM block.OutputPort(2).DatatypeID = 0; % double

block.OutputPort(2).Complexity = 'Real'; block.OutputPort(2).SamplingMode = 'Sample';

% Override input port properties

block.OutputPort(3).Dimensions = block.DialogPrm(6).Data; %Generated Frequency block.OutputPort(3).DatatypeID = 0; % double block.OutputPort(3).Complexity = 'Real'; block.OutputPort(3).SamplingMode = 'Sample'; % Register parameters block.NumDialogPrms = 6; % 1 - Number of inputs to sample % 2 - Sample time

% 3 - Simulation time % 4 - Period

% 5 - Max frequency (input as minimum period) % 6 - Number of PWM's to generate

% Register sample times

% [0 offset] : Continuous sample time % [positive_num offset] : Discrete sample time %

% [-1, 0] : Inherited sample time % [-2, 0] : Variable sample time block.SampleTimes = [-1 0]; %block.SimStateCompliance = 'DefaultSimState'; block.RegBlockMethod('PostPropagationSetup', @DoPostPropSetup); block.RegBlockMethod('InitializeConditions', @InitializeConditions); block.RegBlockMethod('Start', @Start);

block.RegBlockMethod('Outputs', @Outputs); % Required block.RegBlockMethod('Update', @Update);

block.RegBlockMethod('Derivatives', @Derivatives);

block.RegBlockMethod('Terminate', @Terminate); % Required %block.RegBlockMethod('GetSimState', @GetSimState); %block.RegBlockMethod('SetSimState', @SetSimState);

%% %% PostPropagationSetup: %% function DoPostPropSetup(block) block.NumDworks = 12; block.Dwork(1).Name = 'Duty_Cycle'; block.Dwork(1).Dimensions = 1; block.Dwork(1).DatatypeID = 0; % double block.Dwork(1).Complexity = 'Real'; % real block.Dwork(1).UsedAsDiscState = true;

block.Dwork(2).Name = 'System_Time'; block.Dwork(2).Dimensions = 1;

block.Dwork(2).DatatypeID = 0; % double block.Dwork(2).Complexity = 'Real'; % real block.Dwork(2).UsedAsDiscState = true;

block.Dwork(3).Name = 'Random_Vals'; block.Dwork(3).Dimensions = 1;

block.Dwork(3).DatatypeID = 0; % double block.Dwork(3).Complexity = 'Real'; % real block.Dwork(3).UsedAsDiscState = true;

block.Dwork(4).Name = 'Output_State'; block.Dwork(4).Dimensions = 1;

block.Dwork(4).DatatypeID = 0; % double block.Dwork(4).Complexity = 'Real'; % real block.Dwork(4).UsedAsDiscState = true;

block.Dwork(5).Name = 'Start_Time'; block.Dwork(5).Dimensions = 1;

block.Dwork(5).DatatypeID = 0; % double block.Dwork(5).Complexity = 'Real'; % real block.Dwork(5).UsedAsDiscState = true;

block.Dwork(6).Name = 'Finish_Time'; block.Dwork(6).Dimensions = 1;

block.Dwork(6).DatatypeID = 0; % double block.Dwork(6).Complexity = 'Real'; % real block.Dwork(6).UsedAsDiscState = true;

block.Dwork(7).Name = 'Period'; block.Dwork(7).Dimensions = 1;

block.Dwork(7).DatatypeID = 0; % double block.Dwork(7).Complexity = 'Real'; % real block.Dwork(7).UsedAsDiscState = true;

block.Dwork(8).Name = 'Flag'; block.Dwork(8).Dimensions = 1;

block.Dwork(8).DatatypeID = 0; % double block.Dwork(8).Complexity = 'Real'; % real

block.Dwork(9).Name = 'Center_Freq'; block.Dwork(9).Dimensions = 1;

block.Dwork(9).DatatypeID = 0; % double block.Dwork(9).Complexity = 'Real'; % real block.Dwork(9).UsedAsDiscState = true;

block.Dwork(10).Name = 'PWM_time'; block.Dwork(10).Dimensions = 1;

block.Dwork(10).DatatypeID = 0; % double block.Dwork(10).Complexity = 'Real'; % real block.Dwork(10).UsedAsDiscState = true;

block.Dwork(11).Name = 'temp'; block.Dwork(11).Dimensions = 1;

block.Dwork(11).DatatypeID = 0; % double block.Dwork(11).Complexity = 'Real'; % real block.Dwork(11).UsedAsDiscState = true;

block.Dwork(12).Name = 'PWM'; block.Dwork(12).Dimensions = 1;

block.Dwork(12).DatatypeID = 0; % double block.Dwork(12).Complexity = 'Real'; % real block.Dwork(12).UsedAsDiscState = true; %% %% InitializeConditions: %% function InitializeConditions(block) %end InitializeConditions %% %% Start: %% function Start(block) block.Dwork(1).Data = 0; %Duty block.Dwork(2).Data = 0; %System time block.Dwork(3).Data = 0; %r1

block.Dwork(4).Data = 0; %r2 block.Dwork(5).Data = 0; %t1 block.Dwork(6).Data = 0; %t2

block.Dwork(7).Data = block.DialogPrm(4).Data; %tau block.Dwork(8).Data = block.DialogPrm(4).Data; %tsw block.Dwork(9).Data = 0; %Center Frequency Value block.Dwork(10).Data = 0;

block.Dwork(11).Data = block.DialogPrm(4).Data;

block.Dwork(3).Data = 0 + (1-0).*rand(1,1); %Generate r1 block.Dwork(5).Data = block.Dwork(3).Data * block.Dwork(7).Data; %endfunction %% %% Outputs:

%% function Outputs(block) %end Outputs %% %% Update: %% function Update(block)

%block.Dwork(1).Data = block.InputPort(1).Data; %Read Duty %block.Dwork(2).Data = block.InputPort(1).Data; %Read Clock %block.Dwork(3).Data = block.InputPort(3).Data; %Read Random

%block.OutputPort(3).Data = 2/block.Dwork(12).Data; %Display t_switching %Peaks are freq

block.Dwork(2).Data = block.Dwork(2).Data + block.DialogPrm(3).Data; %Create sample time if(block.Dwork(2).Data>= block.DialogPrm(2).Data)

%Sampling

block.Dwork(2).Data = 0;

%block.OutputPort(1).Data = block.InputPort(1).Data; %RPWM

block.Dwork(4).Data = 0 + (1-0).*rand(1,1); %Gen R2

block.Dwork(6).Data = block.Dwork(4).Data * block.Dwork(7).Data; %Gen t2

block.Dwork(8).Data = block.Dwork(7).Data+block.Dwork(6).Data-block.Dwork(5).Data; if(block.Dwork(8).Data>block.DialogPrm(5).Data) %Do nothing else block.Dwork(6).Data = block.Dwork(6).Data+block.DialogPrm(5).Data-block.Dwork(8).Data; block.Dwork(8).Data = block.DialogPrm(5).Data; end block.Dwork(5).Data = block.Dwork(6).Data; %block.OutputPort(3).Data = 1/block.Dwork(8).Data; end

block.Dwork(10).Data = block.Dwork(10).Data + block.DialogPrm(3).Data; %Create sample time %if(pwm_time >= Tsw) %get new Tsw %reset if(block.Dwork(10).Data >= block.Dwork(11).Data) block.OutputPort(3).Data = 1/block.Dwork(10).Data; block.Dwork(11).Data = block.Dwork(8).Data; block.Dwork(10).Data = 0;

block.Dwork(12).Data = block.InputPort(3).Data * block.Dwork(11).Data; end if(block.Dwork(10).Data < block.Dwork(12).Data) block.OutputPort(2).Data = 1; else block.OutputPort(2).Data = 0; end

block.OutputPort(3).Data = 1/block.Dwork(11).Data; %/block.Dwork(11).Data; %end Update.

%% %% Derivatives: %% function Derivatives(block) %end Derivatives %% %% Terminate: %% function Terminate(block) clc; %end Terminate

A

PPENDIX

B–FFTA

VERAGING

MATLABF

UNCTION

function y = average(array,samples,offset,bits,width) x=0;

offset2=0;

while(x<=samples)

%Offest for taking several samples %offset = width*x;

%Cut into smaller pieces of data

Related documents