Professional Documents
Culture Documents
OBJECT: - To design IIR filter using TMS320C6713 Digital Signal Processing Starter Kit
(DSK)
APPARATUS REQUIRED:
Fig 1.1
THEORY: - IIR filter Designing
GENERAL CONSIDERATIONS:
In the design of frequency. Selective filters, the desired filter characteristics are specified
in the frequency domain in terms of the desired magnitude and phase response of the filter.
In the filter design process, we determine the coefficients of a causal IIR filter that
closely approximates the desired frequency response specifications.
An Infinite impulse response (IIR) filter possesses an output response to an impulse
which is of an infinite duration. The impulse response is "infinite" since there is feedback
in the filter, that is if you put in an impulse ,then its output must produced for infinite
duration of time.
ALGORITHM TO IMPLEMENT:
We need to realize the Butter worth band pass IIR filter by implementing the difference
equation y[n] = b0x[n] + b1x[n-1]+b2x[n-2]-a1y[n-1]-a2y[n-2] where b0 . b2, a0-a2 are feed
forward and feedback word coefficients respectively [Assume 2nd order of filter]. These
coefficients are calculated using MATLAB.A direct form I implementation approach is
taken.
• Step 1 - Initialize the McBSP, the DSP board and the on board codec.
. Kindly refer the Topic Configuration of 6713Codec using BSL.
• Step 2 - Initialize the discrete time system, that is, specify the initial conditions.
Generally zero initial conditions are assumed.
• Step 3 - Take sampled data from codec while input is fed to DSP kit from the signal
generator. Since Codec is stereo, take average of input data read from left and right
channel. Store sampled data at a memory location.
• Step 4 - Perform filter operation using above said difference equation and store
filter Output at a memory location.
• Step 5 - Output the value to codec (left channel and right channel) and view the
output at Oscilloscope.
• Step 6 - Go to step 3.
FLOW CHART
SOURCE CODE
#include "dsk6713.h"
#include "dsk6713_aic23.h"
};
/*
* main() - Main code routine, initializes BSL and generates tone
*/
void main()
{
DSK6713_AIC23_CodecHandle hCodec;
DSK6713_AIC23_setFreq(hCodec, 3);
while(1)
{ /* Read a sample to the left channel */
while (!DSK6713_AIC23_read(hCodec, &l_input));
l_output=IIR_FILTER(&filter_Coeff ,l_input);
r_output=l_output;
return (temp<<2);
}
PROCEDURE:-
10. Vary the frequency on function generator to see the response of filter
WAVEFORMGENERATED
RESULT :- Using TMS320C6701 DSK and Code Composer Studio V 3.1 IIR filter is designed
and waveforms are verified
PRECAUTIONS:-