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. After computing the FFT of a 1024-sample block of input data, you will then compute the squared magnitude of the sampled spectrum and send it to the output for display on the oscilloscope. In contrast to the systems you have implemented in the previous labs, the FFT is an algorithm that operates on blocks of samples at a time. In order to operate on blocks of samples, you will need to use interrupts to halt processing so that samples can be transferred.
The FFT can be used to analyze the spectral content of a signal. Recall that the FFT is an efficient algorithm for computing the Discrete Fourier Transform (DFT), a frequency-sampled version of the DTFT.
DFT:
Your implementation will include windowing of the input data prior to the FFT computation. This is simple a point-by-point multiplication of the input with an analysis window. As you will explore in the prelab exercises, the choice of window affects the shape of the resulting window.
A block diagram representation of the spectrum analyzer you will implement in the lab, including the required input and ouput locations, can be found depicted in Figure 1.
![]() |





