Download presentation
Presentation is loading. Please wait.
Published byJob Reynolds Modified over 9 years ago
1
Digital Signal Processing Techniques ECE2799 Lecture Prof. W. Michalson
2
What is Digital Signal Processing? Generically, Digital Signal Processing refers to manipulating analog signals using digital operations. There are special purpose Digital Signal Processors, or DSP chips that are essentially microprocessors that are customized for implementing DSP algorithms. DSP chips, however, are not necessary for performing signal processing in the digital domain.
3
Types of DSP Many things can be called digital signal processing. Often, DSP programs are applications of discrete-time signal processing to do: –Filtering (high-pass, low-pass, band-pass, etc) –Modulation / Demodulation –DFT / Correlation Generically, any operation on a digital signal is DSP.
4
Generic System Model
5
Focus on Analog Input
6
Focus on Analog Output
7
A Simple Example System Let’s suppose we want to design a digital coffee temperature monitor. We need some specifications: –Provide indication of “optimal” drinking temperature. Red LED – Too hot (T > 70 ºC) Green LED – Perfection! ( 50 ≤ T ≤ 70 ºC) Blue LED – Brrrrrrr. Too cold. (T < 50 ºC)
8
Our System
9
We Need REAL Specifications! From a quick search on Digikey I found an NTC thermistor encased in a glass bead. –R25 = 10K –Dissipation factor 0.4 mW/ºC From the thermistor specifications, I found: TRth 504103 553482 602967 652539 702182
10
Avoiding Self Heating In my research, I learned that to minimize self heating, I need to make sure that the current through the thermistor is less than the dissipation factor. Limiting current to 0.2mW means I’ll limit error due to self heating to about 0.5 ºC. If Vcc = 5V, this means that the total resistance must be > 125 K .
11
So, What Will We Measure? Given these specifications, based on the nominal values in the thermistor data sheet, we would expect to see the following: TRthVth 5041030.156 5534820.133 6029670.114 6525390.098 7021820.084
12
Analog Pre-Processing The voltages we expect to see at the thermistor are pretty small. Do we need any analog processing? Maybe, maybe not… –We need to look at the specifications of our ADC. –If the specifications are adequate, we may not have to go any further.
13
Arduino Uno Many people are using the Arduino Uno as the processor in their design. –The processor is an ATMega328. –10-bit ADC –No circuitry between ADC pins and header connectors –Review of the Atmel datasheet shows: 100 MW analog input resistance. A REF is A VCC, 1.1V, or V REF.
14
Arduino Uno Schematic
15
No Analog Processing??? So, what happens if I just drive the Arduino with V TH ? The equation for determining the 10-bit ADC value is ADC = (V in x 1024)/V REF. Thus, we have: TRthVthAvcc1.1 Vref 5041030.15632146 5534820.13327124 6029670.11423106 6525390.0982091 7021820.0841779
16
This Just Might Work!!! If we set up the ATMega328 ADC to use the internal 1.1V reference, we have a pretty reasonable range to operate in with no additional analog components. It would make sense to “low pass” filter the data by averaging over several samples. We’re ignoring “anti aliasing” at our peril!
17
Our Software So, in terms of software: –We need to set up the ADC to use the 1.1 Volt reference (a single 8-bit read is sufficient). –We should average over 5-10 samples to reduce noise (no need for fast sampling). –Decision routine: If ADC < 79, Turn on Red LED, If 79 ≤ ADC ≤ 146, turn on Green LED, If ADC > 146, Turn on Blue LED,
18
Characteristics of A/D Converters An A/D converter translates an analog input voltage into a digital representation. Here we see a ±5V signal being mapped to a 16-bit 2’s complement integer: Source: http://www.audiodesignline.com/showArticle.jhtml?articleID=192200610
19
Word Size and Dynamic Range The number of bits in an A/D converter determines the “dynamic range” of the converter. This “dynamic range” is the ratio of the smallest and largest values that can be represented. DR dB = 20 log (V max /V min ) Different applications require different dynamic ranges. Source: http://www.audiodesignline.com/showArticle.jhtml?articleID=192200610
20
Consider an 8-bit Converter Assume 0-3.3V maps to 00-FF –256 steps means 0.0129 Volts/step –DR dB = 20 log(3.3/0.0129) = 48 dB So, comparing this to the previous slide, we see: –8-bits is about “AM Radio” quality –12-bits is about “FM Radio” quality –16-bits is about “CD” quality But wait, there’s more!
21
Other Issues Selecting a Converter It’s generally good to leave some “headroom” when designing so the system won’t distort. In our example, let’s assume a 0 to 3.3V converter. Let’s also assume some more specifications: –12dB headroom Source: http://www.audiodesignline.com/showArticle.jhtml?articleID=192200610
22
What About Anti-Aliasing? We know that in general we need a band-limited signal as an input to the converter. It doesn’t matter how the signal is band-limited, it just matters that it is band-limited. We have a few choices: –Ignore Nyquist and hope it’s not an issue. –Look at the characteristics of the thermistor and see how susceptible to noise it is. The thermistor may be able to band-limit the signal. –Sample at higher rate and build a separate low-pass filter (and probably gain) prior to the converter.
23
Sample Rate Below Nyquist
24
Sampling Above Nyquist Rate
25
Signal is Misinterpreted!
26
Signal Above Nyquist II Every frequency above Nyquist will get aliased into a frequency below Nyquist and thus will be indistinguishable!
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.