Audio Basics Analog to Digital Conversion Sampling Rate
Audio Basics ¨ Analog to Digital Conversion ¨ Sampling Rate ¨ Quantization ¨ Aliasing ¨ Digital to Analog Conversion Fall 2004 EE 3563 Digital Systems Design
Audio Basics - Analog to Digital Conversion ¨ Process of digitizing a signal (such as music) Music LPF ADC Quantizer Samples Clock – Sampling Rate ¨ Human hearing range is roughly 20 Hz to 20 KHz ¨ CD’s are sampled at 44, 100 Hz – that’s no coincidence ¨ Nyquist Theorem – Must sample at a minimum of twice the highest frequency – If not, undesirable aliasing will occur Fall 2004 EE 3563 Digital Systems Design
Audio Basics - Analog to Digital Conversion Music LPF ADC Quantizer Samples Clock – Sampling Rate ¨ LPF – Low Pass Filter – used to remove frequencies higher than the Nyquist rate – It’s like turning down the treble on your stereo ¨ Clock is the sampling rate ¨ If clock is 44. 1 KHz, then the LPF should remove all frequencies above 22. 05 KHz – In practice, you need a little extra removed, so 20 KHz is the cutoff ¨ Sampling rate determines the frequency response – Too low and it will sound like an AM radio – Tradeoff is in data storage space Fall 2004 EE 3563 Digital Systems Design
Audio Basics - Analog to Digital Conversion Music LPF ADC Quantizer Samples Clock – Sampling Rate ¨ The Analog to Digital Converter gets a sample every time the ¨ ¨ ¨ clock ticks The sample is passed on to a quantizer The quantizer outputs a number corresponding to the amplitude of the music at that point The range of values depends upon how many bits per sample For CD quality, 16 bits are used (-32768 to +32767) For voice quality, 8 bits are used (-128 to +127) Fall 2004 EE 3563 Digital Systems Design
Audio Basics - Analog to Digital Conversion Music LPF ADC Quantizer Samples Clock – Sampling Rate ¨ The fewer the bits, the larger the quantization error, resulting in lower quality ¨ Suppose you gave the teller $93 and asked for change – Suppose she only had twenties (5 steps) – the “quantization” error would be $13 – Suppose she had tens (10 steps) – the error would be $3 ¨ The tradeoff is in the amount of data to store ¨ CD Quality: 2 channels * 16 bits/sample * 44100 samples/sec – = 176400 bytes/sec ¨ Voice Quality: 1 channel * 8 bits/sample * 8000 samples/sec – = 8000 bytes/sec Fall 2004 EE 3563 Digital Systems Design
Audio Basics - Analog to Digital Conversion Music LPF ADC Quantizer Samples Clock – Sampling Rate ¨ The sampling rate and the number of bits/sample together determine the overall fidelity Fall 2004 EE 3563 Digital Systems Design
Audio Basics - Aliasing ¨ Aliasing occurs when the sampling frequency is below the Nyquist rate ¨ It manifests itself as low frequency noise ¨ Sampling at Nyquist frequency ¨ Sampling below Nyquist frequency Fall 2004 EE 3563 Digital Systems Design
Audio Basics – Example Waveform Fall 2004 EE 3563 Digital Systems Design
Audio Basics – Example Waveform Fall 2004 EE 3563 Digital Systems Design
Audio Basics – Example Waveform Note the “squareness” 1/5000 th second Fall 2004 EE 3563 Digital Systems Design
Audio Basics – Analog to Digital Converter • A basic Analog to Digital Converter (ADC) is shown • Note that these comparators are ANALOG comparators • The voltage at each point along the ladder drops • The comparator output is high when analog input voltage exceeds the reference voltage • There is an 8 -bit priority encoder internally to produce the digital output Fall 2004 EE 3563 Digital Systems Design
Audio Basics - Digital to Analog Conversion Samples DAC LPF Music Clock – Sampling Rate ¨ For converting back to music, the process is reversed ¨ The LPF is required on the output because it has a staircase shape – In reality, a staircase shape is composed of an infinite number of sine waves of increasing frequency – These frequencies must be removed or the output will be noisy Fall 2004 EE 3563 Digital Systems Design
Digital to Analog Converter ¨ There is a resistive ladder that must be very precise ¨ Each of the switches is essentially a mux that switches between the reference voltage and ground ¨ The final output is called a summing amplifier – it is simply an analog adder Fall 2004 EE 3563 Digital Systems Design
- Slides: 13