Analog to Digital Converter & Its Working
Almost every environmental measurable parameter is in analog form like temperature, sound, pressure, light, etc. Consider a temperature monitoring system wherein acquiring, analyzing, and processing temperature data from sensors is not possible with digital computers and processors. Therefore, this system needs an intermediate device to convert the analog temperature data into digital data in order to communicate with digital processors like microcontrollers and microprocessors. Analog to Digital Converter (ADC) is an electronic integrated circuit used to convert the analog signals such as voltages to digital or binary form consisting of 1s and 0s. Most of the ADCs take a voltage input as 0 to 10V, -5V to +5V, etc., and correspondingly produces digital output as some sort of a binary number.
What is Analog to Digital Converter?
A converter that is used to change the analog signal to digital is known as an analog to digital converter or ADC converter. This converter is one kind of integrated circuit or IC that converts the signal directly from continuous form to discrete form. This converter can be expressed in A/D, ADC, A to D. The inverse function of DAC is nothing but ADC. The analog to digital converter symbol is shown below.
The process of converting an analog signal to digital can be done in several ways. There are different types of ADC chips available in the market from different manufacturers like the ADC08xx series. So, a simple ADC can be designed with the help of discrete components.
The main features of ADC are sample rate and bit resolution.
- The sample rate of an ADC is nothing but how fast an ADC can convert the signal from analog to digital.
- Bit resolution is nothing but how much accuracy can an analog to digital converter can convert the signal from analog to digital.
One of the major benefits of ADC converter is the high data acquisition rate even at multiplexed inputs. With the invention of a wide variety of ADC integrated circuits (IC’s), data acquisition from various sensors becomes more accurate and faster. Dynamic characteristics of the high-performance ADCs are improved measurement repeatability, low power consumption, precise throughput, high linearity, excellent Signal-to-Noise Ratio (SNR), and so on.
A variety of applications of the ADCs are measurement and control systems, industrial instrumentation, communication systems, and all other sensory-based systems. Classification of ADCs based on factors like performance, bit rates, power, cost, etc.
ADC Block Diagram
The block diagram of ADC is shown below which includes sample, hold, quantize, and encoder. The process of ADC can be done like the following.
First, the analog signal is applied to the first block namely a sample wherever it can be sampled at an exact sampling frequency. The amplitude value of the sample like an analog value can be maintained as well as held within the second block like Hold. The hold sample can be quantized into discrete value through the third block like quantize. Finally, the last block like encoder changes the discrete amplitude into a binary number.
In ADC, the conversion of the signal from analog to digital can be explained through the above block diagram.
Sample
In the sample block, the analog signal can be sampled at an exact interval of time. The samples are used in continuous amplitude and hold real value however they are discrete with respect to time. While converting the signal, the sampling frequency plays an essential role. So it can be maintained at a precise rate. Based on the system requirement, the sampling rate can be fixed.
Hold
In ADC, HOLD is the second block and it doesn’t have any function because it simply holds the sample amplitude till the next sample is taken. So the value of hold doesn’t change until the next sample.
Quantize
In ADC, this is the third block which is mainly used for quantization. The main function of this is to convert the amplitude from continuous (analog) into discrete. The value of continuous amplitude within hold block moves throughout quantize block to turn into discrete in amplitude. Now, the signal will be in digital form because it includes discrete amplitude as well as time.
Encoder
The final block in ADC is an encoder that converts the signal from digital form to binary. We know that a digital device works by using binary signals. So it is required to change the signal from digital to binary with the help of an encoder. So this is the entire method to change an analog signal to digital using an ADC. The time taken for the entire conversion can be done within a microsecond.
Analog to Digital Conversion Process
There are many methods to convert analog signals to digital signals. These converters find more applications as an intermediate device to convert the signals from analog to digital form, display output on LCD through a microcontroller. The objective of an A/D converter is to determine the output signal word corresponding to an analog signal. Now we are going to see an ADC of 0804. It is an 8-bit converter with a 5V power supply. It can take only one analog signal as input.
The digital output varies from 0-255. ADC needs a clock to operate. The time taken to convert the analog to digital value depends on the clock source. An external clock can be given to CLK IN pin no.4. A suitable RC circuit is connected between the clock IN and clock R pins to use the internal clock. Pin2 is the input pin – High to low pulse brings the data from the internal register to the output pins after conversion. Pin3 is a Write – Low to high pulse is given to the external clock. Pin11 to 18 are data pins from MSB to LSB.
Analog to Digital Converter samples the analog signal on each falling or rising edge of the sample clock. In each cycle, the ADC gets the analog signal, measures it, and converts it into a digital value. The ADC converts the output data into a series of digital values by approximates the signal with fixed precision.
In ADCs, two factors determine the accuracy of the digital value that captures the original analog signal. These are quantization level or bit rate and sampling rate. The below figure depicts how analog to digital conversion takes place. Bit rate decides the resolution of digitized output and you can observe in the below figure where 3-bit ADC is used for converting the analog signal.
Assume that one-volt signal has to be converted from digital by using 3-bit ADC as shown below. Therefore, a total of 2^3=8 divisions are available for producing 1V output. This results 1/8=0.125V is called as minimum change or quantization level represented for each division as 000 for 0V, 001 for 0.125, and likewise upto 111 for 1V. If we increase the bit rates like 6, 8, 12, 14, 16, etc. we will get a better precision of the signal. Thus, bit rate or quantization gives the smallest output change in the analog signal value that results from a change in the digital representation.
Suppose if the signal is about 0-5V and we have used 8-bit ADC then the binary output of 5V is 256. And for 3V it is 133 as shown below.
There is an absolute chance of misrepresenting the input signal on the output side if it is sampled at a different frequency than the desired one. Therefore, another important consideration of the ADC is the sampling rate. The Nyquist theorem states that the acquired signal reconstruction introduces distortion unless it is sampled at (minimum) twice the rate of the largest frequency content of the signal as you can observe in the diagram. But this rate is 5-10 times the maximum frequency of the signal in practice.
Factors
The ADC performance can be evaluated through its performance based on different factors. From that, the following two main factors are explained below.
SNR (Signal-to-Noise Ratio)
The SNR reflects the average number of bits without noise in any particular sample.
Bandwidth
The bandwidth of an ADC can be determined by estimating the sampling rate. The analog source can be sampled per second to produce discrete values.
Types of Analog to Digital Converters
ADC is available in different types and some of the types of analog to digital converters include:
- Dual Slope A/D Converter
- Flash A/D Converter
- Successive Approximation A/D Converter
- Semi-flash ADC
- Sigma-Delta ADC
- Pipelined ADC
Dual Slope A/D Converter
In this type of ADC converter, comparison voltage is generated by using an integrator circuit which is formed by a resistor, capacitor, and operational amplifier combination. By the set value of Vref, this integrator generates a sawtooth waveform on its output from zero to the value Vref. When the integrator waveform is started correspondingly counter starts counting from 0 to 2^n-1 where n is the number of bits of ADC.
When the input voltage Vin equal to the voltage of the waveform, then the control circuit captures the counter value which is the digital value of the corresponding analog input value. This Dual slope ADC is a relatively medium cost and slow speed device.
Flash A/D Converter
This ADC converter IC is also called parallel ADC, which is the most widely used efficient ADC in terms of its speed. This flash analog to digital converter circuit consists of a series of comparators where each one compares the input signal with a unique reference voltage. At each comparator, the output will be a high state when the analog input voltage exceeds the reference voltage. This output is further given to the priority encoder for generating binary code based on higher-order input activity by ignoring other active inputs. This flash type is a high-cost and high-speed device.
Successive Approximation A/D Converter
The SAR ADC a most modern ADC IC and much faster than dual slope and flash ADCs since it uses a digital logic that converges the analog input voltage to the closest value. This circuit consists of a comparator, output latches, successive approximation register (SAR), and D/A converter.
At the start, SAR is reset and as the LOW to HIGH transition is introduced, the MSB of the SAR is set. Then this output is given to the D/A converter that produces an analog equivalent of the MSB, further it is compared with the analog input Vin. If comparator output is LOW, then MSB will be cleared by the SAR, otherwise, the MSB will be set to the next position. This process continues till all the bits are tried and after Q0, the SAR makes the parallel output lines to contain valid data.
Semi-flash ADC
These types of analog to digital converts mainly works approximately their limitation size through two separate flash converters, where each converter resolution is half of the bits for the semi-flush device. The capacity of a single flash converter is, it handles the MSBs (most significant bits) whereas the other handles the LSB (least significant bits).
Sigma-Delta ADC
Sigma Delta ADC (ΣΔ) is fairly a recent design. These are extremely slow as compared to other kinds of designs however they offer the maximum resolution for all kinds of ADC. Thus, they are extremely compatible with high-fidelity based audio applications, however, they are normally not utilizable wherever high BW (bandwidth) is required.
Pipelined ADC
Pipelined ADCs are also known as sub ranging quantizers which are related in concept to successive approximations, even though more sophisticated. While successive approximations grow through every step by going to the next MSB, this ADC uses the following process.
- It is used for a coarse conversion. After that, it evaluates that change toward the input signal.
- This converter acts as a better conversion by allowing for a temporary conversion with a range of bits.
- Usually, pipelined designs offer a center ground among SARs as well as flash analog to digital converters by balancing its size, speed & high resolution.
Analog to Digital Converter Examples
The examples of analog to digital converter are discussed below.
ADC0808
ADC0808 is a converter that has 8 analog inputs and 8 digital outputs. ADC0808 allows us to monitor up to 8 different transducers using only a single chip. This eliminates the need for external zero and full-scale adjustments.
ADC0808 is a monolithic CMOS device, offers high speed, high accuracy, minimal temperature dependence, excellent long-term accuracy and repeatability and consumes minimal power. These features make this device ideally suited to applications from process and machine control to consumer and automotive applications. The pin diagram of ADC0808 is shown in the figure below:
Features
The main features of ADC0808 include the following.
- Easy interface to all microprocessors
- No zero or full-scale adjust required
- 8-channel multiplexer with address logic
- 0V to 5V input range with single 5V power supply
- Outputs meet TTL voltage level specifications
- Carrier chip package with 28-pin
Specifications
The specifications of ADC0808 include the following.
- Resolution: 8 Bits
- Total Unadjusted Error: ±½ LSB and ±1 LSB
- Single Supply: 5 VDC
- Low Power: 15 mW
- Conversion Time: 100 μs
Generally, the ADC0808 input which is to be changed over to digital form can be selected by using three address lines A, B, C which are pins 23, 24, and 25. The step size is chosen dependent upon the set reference value. Step size is the change in analog input to cause a unit change in the output of ADC. ADC0808 needs an external clock to operate, unlike ADC0804 which has an internal clock.
The continuous 8-bit digital output corresponding to the instantaneous value of analog input. The most extreme level of the input voltage must be reduced proportionally to +5V.
The ADC 0808 IC requires a clock signal of typically 550 kHz, ADC0808 is used to convert the data into digital form required for the microcontroller.
Application of ADC0808
The ADC0808 has got many applications; here we have given some application on ADC:
From the below circuit the clock, start, and EOC pins are connected to a microcontroller. Generally, we have 8 inputs; here we are using only 4 inputs for the operation.
- The LM35 temperature sensor is using which is connected to the first 4 inputs of the analog to digital converter IC. The sensor has got 3 pins i.e., VCC, GND, and output pins when the sensor heated the voltage at output increases.
- The address lines A, B, C are connected to the microcontroller for the commands. In this, the interrupt follows the low to high operation.
- When the start pin is held high no conversion begins, but when the start pin is low the conversion will start within 8 clock periods.
- At the point when the conversion is completed the EOC pin goes low to indicate the finish of conversion and data ready to be picked up.
- The output enables (OE) is then raised high. This enables the TRI-STATE outputs, allowing the data to be read.
ADC0804
We already know that analog-to-digital (ADCs) converters are the most widely used devices for information securing to translate the analog signals to digital numbers so the microcontroller can read them easily. There are many ADC converters like ADC0801, ADC0802, ADC0803, ADC0804, and ADC080. In this article, we are going to discuss the ADC0804 converter.
ADC0804 is a very commonly used 8-bit analog to digital converter. It works with 0V to 5V analog input voltage. It has single analog input and 8-digital outputs. Conversion time is another major factor in judging an ADC, in ADC0804 conversion time varies depending on the clocking signals applied to CLK R and CLK IN pins, but it cannot be faster than 110 μs.
Pin Description of ADC804
Pin 1: It is a chip select pin and activates ADC, active low
Pin 2: It is an input pin; high to low pulse brings the data from internal registers to the output pins after conversion
Pin 3: It is an input pin; low to high pulse is given to start the conversion
Pin 4: It is a clock input pin, to give the external clock
Pin 5: It is an output pin, goes low when the conversion is complete
Pin 6: Analog non-inverting input
Pin 7: Analog inverting input, it’s normally ground
Pin 8: Ground (0V)
Pin 9: It is an input pin, sets the reference voltage for analog input
Pin 10: Ground (0V)
Pin 11 – Pin 18: It is an 8-bit digital output pin
Pin 19: Is used with Clock IN pin when internal clock source is used
Pin 20: Supply voltage; 5V
Features of ADC0804
The main features of ADC0804 include the following.
- 0V to 5V analog input voltage range with single 5V supply
- Compatible with microcontrollers, access time is 135 ns
- Easy interface to all microprocessors
- Logic inputs and outputs meet both MOS and TTL voltage level specifications
- Works with 2.5V (LM336) voltage reference
- On-chip clock generator
- No zero adjust required
- 0.3[Prime] standard width 20-pin DIP package
- Operates ratio metrically or with 5 VDC, 2.5 VDC, or analog span adjusted voltage reference
- Differential analog voltage inputs
It is an 8-bit converter with a 5V power supply. It can take only one analog signal as input. The digital output varies from 0-255. ADC needs a clock to operate. The time taken to convert the analog to digital value depends on the clock source. An external clock can be given to CLK IN. Pin2 is the input pin – High to low pulse brings the data from the internal register to the output pins after conversion. Pin3 is a Write – Low to high pulse is given to the external clock.
Application
From the simple circuit, pin 1 of ADC is connected to GND where pin4 is connected to GND through a capacitor; pin 2, 3, and 5 of ADC are connected to 13, 14, and 15 pins of the microcontroller. Pin 8 and 10 are shorted and connected to GND, 19 pins of ADC is to 4th pin through resistor 10k. Pin 11 to 18 of ADC are connected to 1 to 8 pins of the microcontroller which belongs to port1.
When the logic high is applied to CS and RD, input has been clocked through the 8-bit shift register, completing the specific absorption rate (SAR) search, on the next clock pulse; the digital word is transferred to the tri-state output. The output of the interrupt is inverted to provide an INTR output that is high during conversion and low when the conversion is completed. When a low is at both CS and RD, an output is applied to the DB0 through DB7 outputs and the interrupt is reset. When either the CS or RD inputs return to a high state, the DB0 through DB7 outputs are disabled (returned to the high-impedance state). Thus depending on the logic the voltage various from 0 to 5V which is transformed to a digital value of 8-bit resolution, being fed as an input to the microcontroller port 1.
ADC0804 Component Used Projects
ADC0808 Component Used Projects
ADC Testing
The testing of analog to digital converter mainly needs an analog input source as well as hardware to transmit the control signals as well as to capture digital data o/p. Some kinds of ADCs need a precise reference signal source. The ADC can be tested by using the following key parameters
- DC Offset Error
- Power Dissipation
- DC Gain Error
- Spurious Free Dynamic Range
- SNR (Signal to Noise Ratio)
- INL or Integral Nonlinearity
- DNL or Differential Nonlinearity
- THD or Total Harmonic Distortion
The testing of ADCs or Analog-to-digital converters is mainly done for several reasons. Apart from the reason, the society of IEEE Instrumentation & Measurement, the waveform generation & analysis committee was developed the IEEE Standard for ADC for Terminology as well as Test Methods. There are different general test setups which include Sine Wave, Arbitrary Waveform, Step Waveform & Feedback Loop. To determine analog to digital converters’ stable performance, then different methods are used like the servo based, ramp based, the ac histogram technique, the triangle histogram technique & the physical technique. The one technique that is used for dynamic testing is the sine wave test.
Applications of Analog to Digital Converter
The applications of ADC include the following.
- At present, the usage of digital devices is increasing. These devices work based on the digital signal. An analog to digital converter plays a key role in such kind of devices to convert the signal from analog to digital. The applications of analog to digital converters are limitless which are discussed below.
- AC (air conditioner) includes temperature sensors to maintain the temperature within the room. So this conversion of temperature can be done from analog to digital with the help of ADC.
- It is also used in a digital oscilloscope to convert the signal from analog to digital to display.
- ADC is used to convert the analog voice signal to digital in mobile phones because mobile phones use digital voice signals but actually, the voice signal is in the form of analog. So ADC is used to convert the signal before sending the signal toward the transmitter of the cell phone.
- ADC is used in medical devices like MRI and X-Ray to convert the images from analog to digital before alteration.
- The camera in the mobile mainly used for capturing images as well as videos. These are stored in the digital device, so these are converted to digital form using ADC.
- The cassette music can also be changed into a digital like CDS & thumb drives use ADC.
- At present ADC is used in every device because almost all devices available in the market are in digital version. So these devices use ADC.
Successive Approximation ADC Introduction
It is the most frequently used ADC technique for general applications. The ADC comprises a comparator, digital to analog converter, register, and a control circuit. The schematic is shown below:
At the point when the new conversion begins, the sample and hold circuit samples the input voltage and then this sampled signal is compared with the output signal of the digital to analog converter.
4-bit Successive Approximation ADC Example
To grasp the concept, consider a 4-bit ADC with a sampling rate i.e Vin to be 11.2 Volts. We take the comparator reference voltage as16 Volts. Whenever the new transformation begins, the successive approximation register sets the most significant bit to 1 and all others to zero. As the register is followed by the DAC, the input to the DAC is 1000. So the output voltage of the DAC corresponding to the stated digital code and reference voltage of 16 turns out to be
Vout = – Vref { B0 (1/16) + B1 (1 /8) + B2 (1/4) + B3(1/2) } Vout = 8 Volts
This is the threshold voltage to which the input voltage will be compared. Thus, the output voltage of the comparator will change the output value of the successive register.
This sets two conditions:
When Vdac < Vin
If the output voltage of DAC is lesser than the input voltage then the most significant bit remains intact and the next bit will be changed to 1 for new comparison.
When Vdac > Vin
On the other hand, if the output DAC voltage is greater than the input voltage then the MSB is transformed to zero but the next bit is pulled high for the new comparison.
Working of Successive Approximation ADC
As we have calculated, the output voltage of DAC is 8 Volts and Vin is 11.2 volts. So, the condition Vin>Vdac is satisfied which results in unchanged most significant bit and successive bit is set to 1. Now, the code has become 1100. So, the output of DAC corresponding to this binary code is 12 Volts measured using the same output voltage formula. This is the new DAC voltage set to be compared with.
Once more, the input voltage is compared with the DAC voltage. If again, the latter is lesser, then the second bit remains the same while the third bit is made 1 for the new comparison. But if vice versa happens then the second bit is changed to zero and the third bit to 1 for the next comparison. It means that the current input code for the DAC is 1010. We will deduce the output voltage which is updated to 10 Volts. Repeat the same process again.
If Vin is less than 10 Volts then the third bit is kept as it is and the least significant bit is made high. For vice versa, the third bit is turned to 0 and LSB alters to 1 to compare with the input voltage. The input is for sure greater than the Vdac so, the next input code is 1011. The corresponding output voltage becomes 11 Volts. It is again compared and the final code is 1011.
Below is the tree hierarchy that depicts all the possibilities that occur during the iterations. Hence, based on the comparison, only one code is selected in the end.
Time Domain Representation
The four-cycle time domain representation of the sequence for the visual is shown below:
Conversion Time
It is the time needed by analog to digital converter to completely convert continuous signals to digital signals. The conversion time is based on the number of bits because the N number of bits takes N number of clock cycles. Each bit iteration takes one cycle. So, the general conversion time formula is
Tc = N x Tclk
We can see that the conversion time is independent of the input voltage which is not the case in the majority of the other ADCs.
Conversion Speed
The speed with which the conversion of the signal takes place is called conversion speed. Successive Approximation ADC typical conversion speed is between 2-10 Mega Samples Per Second. (MSPS).
Successive Approximation ADC Resolution
Talking about the resolution, it is the number of bits utilized by the analog to digital converter to discrete the analog inputs. The typical resolution of the successive approximation analog to digital converter is in a wide range starting from 8-bits to 16-bits. Still, some exceptions can resolve up to 20-bits.
SA DAC Latency
Data latency is the time taken by the converter to make the data available for the download. It is measured in either time or conversion cycles. If the data is available after a single conversion cycle then it is called a Zero latency ADC. The successive approximation is a zero-latency ADC. So, it is used in applications where data is required immediately.
Advantages
- They output the binary representation serially.
- They are highly accurate due to their high-resolution power.
- Successive Approximation ADCs are reliable and power effective.
Disadvantages
- As the resolution increases, the ADC slows down.
Comments
Post a Comment