Spectrum analyzers are used to output the frequency content of an arbitrary input signal. It was our opinion that such a system could be implemented on a microcontroller, almost fully in software. Doing this, however, necessitated some knowledge of standard Digital Signal Processing techniques, namely sampling, analog-to-digital conversion and most importantly constructing digital filters. We believed that a spectrum analyzer could be fully described by providing and/or implementing three main components: sampling & A/D conversion, filtering and output.
Hardware was essential to our project. The ATMEL AT90S8535 provided a sampling and Analog-to-Digital module which greatly facilated the capturing of analog signal for subsequent processing. Of course, using this particular microcontroller put constraints on the capacity and capability of our spectrum analyzer. Due to these constraints, we had to design the analyzer within the appropriate limits. The main constraints imposed by the microcontroller were the maximum sampling frequency (of approximately 9 kHz), RAM and Program Memory. All three factors contributed to limiting the bandwidth, performance and resolution of the analyzer.
In essence, we believed that a spectrum analyzer could be realized through chaining a series of bandpass filters, through which an input signal would traverse during the filtering process. Hence, the major portion of this project involved coding up and testing the various filters that later become the 'frequency points of interest' of our analyzer. We tried several filter design techniques to implement a reliable bandpass filter, i.e. a filter with a relatively short passband and sharp roll-off. The two main classes of filters we explored were IIR and FIR filters (please see section entitled 'Filter Concepts' for futher detail). However, progressively filtering an input signal was insufficient to establish the presence of a particular frequency (or range of frequencies). Therefore, we had to include some thresholding on the final filtered output to determine the presence of a specific frequency.
Nevertheless, we managed to
implement a spectrum analyzer that can process and output the frequencies
present in an input signal, with reasonable accuracy. Further issues regarding
the consequences of hardware constraints, FIR bandpass filter effects and
thresholding will be discussed in subsequent sections.