<< Chapter < Page Chapter >> Page >
In this lab you will explore DSP FFT implementations and power spectral density (PSD) estimators. You will also learn how to write DSP code in C and the trade-offs between writing in C versus assembly.

Introduction

In this lab you are going to apply the Fast Fourier Transform ( FFT ) to analyze the spectral content of an input signal in real time. You will alsoexplore algorithms that estimate a stationary random signal's Power Spectral Density ( PSD ). Finally, you will be introduced to using the C environment and codeoptimization in a practical application. This knowledge will be applied in optimizing a reference implementation of a PSD estimator.

Fast fourier transform

First, samples of the power spectrum of a deterministic signal will be calculated via the magnitude squared of the FFT of the windowedsignal. You will transform a 1024-sample block of input data and send the power spectrum to the output for display on theoscilloscope. After computing the FFT of a 1024-sample block of input data, you will thencompute the squared magnitude of the sampled spectrum and send it to the output for display on the oscilloscope. In contrastto the systems you have implemented in the previous labs, the FFT is an algorithm that operates on blocks of samples at atime. In order to operate on blocks of samples, you will need to use interrupts to halt processing so that samples can betransferred.

The FFT can be used to analyze the spectral content of a signal. Recall that the FFT is an efficient algorithm forcomputing the Discrete Fourier Transform ( DFT ), a frequency-sampled version of the DTFT .

DFT:

X k n 0 N 1 x n 2 N n k
where n k 0 1 N 1

Your implementation will include windowing of the input data prior to the FFT computation. This is simple a point-by-pointmultiplication of the input with an analysis window. As you will explore in the prelab exercises, the choice of windowaffects the shape of the resulting spectrum.

A block diagram of the spectrum analyzer you will implement in the lab, including the required input andouput locations, is depicted in .

FFT-based spectrum analyzer

Pseudo-noise sequence generator

Second, you will generate a colored, psuedo-noise (PN) sequence as input to the power spectrum algorithm. The noise sequence will begenerated with a linear feedback shift register, whose operation is as shown in . This PN generator is simply a shift-register and an XOR gate. Bits 0, 2, and 15 of the shift-registerare XORed together and the result is shifted into the lowest bit of the register. This lowest bit is the output of the PN generator,and the highest bit is discarded in the shift process. The LSB is used to generate avalue of M and this sequence will repeat with a period of 2 B 1 , where B is the width in bits of the shift register and M is a constant. The power spectral density of this sequence is flat(white) and it will be "colored" via a fourth-order IIR filter. PN generators ofthis type are a useful source of random data bits for system testing. They are especially useful as a data model in simulating communicationsystems as these systems tend to randomize the bits seen by the transmission scheme so that bandwidth can be efficiently utilized.However, this method will not produce very "random" numbers. For more on this, see Pseudorandom number generator , Linear feedback shift register , and chapter 7, section 4 of Numerical Recipes .

Pseudo-noise generator

Power spectral density estimation

The direct-power-spectrum (DPS) algorithm outlined above is insufficient for estimating the PSD of a stationary noisesignal because the variance of the estimated PSD is proportional to the value of the actual PSD. For the third part of this lab you will try toreduce the variance of the PSD estimate by windowing the autocorrelation of the noise signal and computing the fft.

The autocorrelation of a sequence is the correlation of the sequence with itself:

R m i 0 N 1 m x i x i m
where m N 1 N 2 N 1

For random signals, the autocorrelation here is an estimate of the actual autocorrelation.As m is increased, the number of samples used in the autocorrelation decreases.The windowed-DPS algorithm is equivalent to taking the FFT of the autocorrelation of the windowed data. Windowing of the dataadds even more noise to the autocorrelation estimate, since the autocorrelation is performed on a distorted version of the originalsignal. An improvement can be made by constructing an accurate estimate of the autocorrelation (using a rectangular window),applying a window and computing the FFT. The motivation for applying the window at the latter stage is that emphasis should be given toaccurate autocorrelation values while less accurate values should be de-emphasized or discarded.

A good empirical characterization of a random process requires sufficient data, and both of the PSD-estimation algorithms definedabove can be extended to accomodate more data. There is one caveat, however: manyreal-world processes are modeled as short-time stationary processes (non-stationary models are hard to deal with), so there is a practical limit to how much data is available for a PSDestimate. Additional data is added to the direct-PSD estimation algorithm byadding multiple spectra together, thereby smoothing the PSD estimate. Additional data is added to the windowed-autocorrelation methodby computing the autocorrelation of the total data set before windowing. You will explore the windowed-autocorrelation method onthe DSP.

Compiling and optimization

A second objective of this lab exercise is to introduce the TMS320C549 C environment in a practical DSP application. The Cenvironment provides a fast and convenient way to implement a DSP system using C and assembly modules. You will also learn howto optimize a program and when to use C or assembly. In future labs, the benefits of using the C environment will become clear as largersystems are developed.

Questions & Answers

where we get a research paper on Nano chemistry....?
Maira Reply
nanopartical of organic/inorganic / physical chemistry , pdf / thesis / review
Ali
what are the products of Nano chemistry?
Maira Reply
There are lots of products of nano chemistry... Like nano coatings.....carbon fiber.. And lots of others..
learn
Even nanotechnology is pretty much all about chemistry... Its the chemistry on quantum or atomic level
learn
Google
da
no nanotechnology is also a part of physics and maths it requires angle formulas and some pressure regarding concepts
Bhagvanji
hey
Giriraj
Preparation and Applications of Nanomaterial for Drug Delivery
Hafiz Reply
revolt
da
Application of nanotechnology in medicine
what is variations in raman spectra for nanomaterials
Jyoti Reply
ya I also want to know the raman spectra
Bhagvanji
I only see partial conversation and what's the question here!
Crow Reply
what about nanotechnology for water purification
RAW Reply
please someone correct me if I'm wrong but I think one can use nanoparticles, specially silver nanoparticles for water treatment.
Damian
yes that's correct
Professor
I think
Professor
Nasa has use it in the 60's, copper as water purification in the moon travel.
Alexandre
nanocopper obvius
Alexandre
what is the stm
Brian Reply
is there industrial application of fullrenes. What is the method to prepare fullrene on large scale.?
Rafiq
industrial application...? mmm I think on the medical side as drug carrier, but you should go deeper on your research, I may be wrong
Damian
How we are making nano material?
LITNING Reply
what is a peer
LITNING Reply
What is meant by 'nano scale'?
LITNING Reply
What is STMs full form?
LITNING
scanning tunneling microscope
Sahil
how nano science is used for hydrophobicity
Santosh
Do u think that Graphene and Fullrene fiber can be used to make Air Plane body structure the lightest and strongest. Rafiq
Rafiq
what is differents between GO and RGO?
Mahi
what is simplest way to understand the applications of nano robots used to detect the cancer affected cell of human body.? How this robot is carried to required site of body cell.? what will be the carrier material and how can be detected that correct delivery of drug is done Rafiq
Rafiq
if virus is killing to make ARTIFICIAL DNA OF GRAPHENE FOR KILLED THE VIRUS .THIS IS OUR ASSUMPTION
Anam
analytical skills graphene is prepared to kill any type viruses .
Anam
Any one who tell me about Preparation and application of Nanomaterial for drug Delivery
Hafiz
what is Nano technology ?
Bob Reply
write examples of Nano molecule?
Bob
The nanotechnology is as new science, to scale nanometric
brayan
nanotechnology is the study, desing, synthesis, manipulation and application of materials and functional systems through control of matter at nanoscale
Damian
Is there any normative that regulates the use of silver nanoparticles?
Damian Reply
what king of growth are you checking .?
Renato
What fields keep nano created devices from performing or assimulating ? Magnetic fields ? Are do they assimilate ?
Stoney Reply
why we need to study biomolecules, molecular biology in nanotechnology?
Adin Reply
?
Kyle
yes I'm doing my masters in nanotechnology, we are being studying all these domains as well..
Adin
why?
Adin
what school?
Kyle
biomolecules are e building blocks of every organics and inorganic materials.
Joe
Got questions? Join the online conversation and get instant answers!
Jobilize.com Reply

Get Jobilize Job Search Mobile App in your pocket Now!

Get it on Google Play




Source:  OpenStax, Digital signal processing laboratory (ece 420). OpenStax CNX. Sep 27, 2006 Download for free at http://cnx.org/content/col10236/1.14
Google Play and the Google Play logo are trademarks of Google Inc.

Notification Switch

Would you like to follow the 'Digital signal processing laboratory (ece 420)' conversation and receive update notifications?

Ask