phoneSAMPLING, QUANTIFICATION AND CODING OF SIGNALS phone



Analog to Digital Conversion : Block Diagram

The elements of the block diagram are :

  • A The microphone : It converts the audio input into an electrical signal vi(t);
  • B Low Pass Filter : It passes low frequencies, in telephony the maximum sampled audio frequency is about fi,max ≅ 3.4 kHz. The purpose of the low pass filter is to prevent aliasing when we attempt to convert back to analog the audio signal. We sometimes refer to the filter as anti aliasing filter;
  • C Sampler : This is an
    electronic switch
    A transistor or an IC.
    . It produces the samples at every Ts seconds, where the sampling frequency in Hz is equal to fs = 1/Ts. The value of fs is dictated by the Nyquist theorem. The voltage values of the produced samples are called V* and the wave is called a PAM signal or Pulse Amplitude Modulated;
  • D Uniform quantizer : It converts the random values of V* to a predetermined ones called Vq. The operation of the uniform quantizer is as follows :
    V* = Vq if Vq ≤ V* < V(q+1). The level value depends on the number of bits per sample called n. A quantizer has a number of levels equal to q = 2n where n is the number of bits per sample;
  • The coder converts Vq values into a binary sequence made of n bits.




Operation of the sampler :
The GUI above is a script i have written to illustrate the relation between the audio frequency fi and the sampler frequency fs. The user can vary fi between 1 and 10 kHz with fs fixed at 50 kHz. When the page is loaded, the number of samples per period will be 50. As soon as the user varies fi the number of samples per period will vary accordingly. Just try it and see the variation in the field next to this line : . Note: I have used the Math.floor() function to obtain an integer value of the sample's number since a decimal value will be a bit absurd.
Example of a uniform quantizer :
The objectives of this exercise is to verify the relation between the number of uniform levels q and the number of bits n per sample produced by the coder.

In the figure above, the number of levels produced by the uniform quantizer D is equal to 4. The number of levels can be calculated by using the following : q = 2n and in our case it is equal to 4 levels. We assume the first sample to be equal to V* = 0.45 V therefore the quantizer will give it a level value Vq = 0.25 V and it will be coded as the binary sequence 01.
Practice :
1- A sample value of 0.74 V will be coded as :
2- Suggest a sample value V* (different than above)if it's binary code is 10 :
3- The number of bits per sample produced by a 512 uniform quantizer is :
4- A coder produces 13 bits/sample, therefore the number of levels of the uniform quantizer is :
5- What is the Vq level of the sample value V* = 0.24 V ?
6- A 5 kHz audio signal is sampled by a 50 kHz sampler. How many samples are produced per period ?
7- Find the bit rate in kbits/sec, at the output of the coder if each sample in question 6 is coded by an 8 bit coder ?

home