what is Analog to digital converter ?

What is an analog-to-digital converter (ADC)?
An ADC converts an analog signal into digital codes. It lets a processor read the voltage produced by a sensor. An ADC may be a separate integrated circuit or built into a microcontroller. It converts the electrical representation of temperature, sound or pressure, rather than the physical quantity itself.
How does it work?
Sampling measures the input at specific times. Quantization assigns each measurement to one of a finite number of code intervals. The result is delivered as a binary code. An analog input module, for example, converts a sensor signal into a raw value for a PLC. The raw number is not yet a value in bar or °C; it must be scaled to the measurement range.
Bits and resolution
An N-bit ADC provides 2N distinct codes: 8 for 3 bits and 4096 for 12 bits. The ideal quantization step is 1 LSB = input span / 2N. For a 12-bit converter spanning 0–10 V, this is about 2.44 mV. Resolution does not guarantee accuracy: reference error, noise, offset and nonlinearity affect the result.
Sampling and coding demonstration
This teaching model takes 8 samples/s from a 1 Hz input, at intervals of 0.125 s. The green curve is the continuous input; blue dots mark sampling instants. The orange ring highlights the selected sample. Playback is slowed down. Frequency and sampling rate describe different things.
The demonstration uses 0–4 V, 3 bits and 0.5 V/code. It selects a code by rounding V / 0.5 down and limiting the result to 0–7. For example, 2.00 V → 4 → 100. This ideal teaching model defines intervals from their lower boundaries; actual transition thresholds and coding formats depend on the ADC data sheet.
Why does sampling rate matter?
For conventional baseband sampling of a band-limited input, the sampling rate must be greater than twice the highest signal frequency. Practical designs need filter transition bandwidth and margin. An anti-alias filter attenuates unwanted high frequencies before sampling. Otherwise, those components may appear as different frequencies in the measurement. Digital filtering afterwards cannot generally undo aliasing that has already occurred.
Connecting industrial signals to an ADC
0–10 V and 4–20 mA are not automatically compatible with an ADC pin. Voltage inputs may need a divider, buffer and protection; a current signal may need a suitable measurement resistor or input circuit. Signal conditioning brings the signal into the required range. Check input limits, reference, common-mode range and any required isolation together.
What are the main ADC types?
SAR uses successive comparisons and is common in measurements requiring low latency. Sigma-delta uses oversampling, noise shaping and digital filtering; it offers high resolution, with filter latency to consider. Flash is very fast; a conventional N-bit design needs 2N − 1 comparators. Pipeline converters use multiple stages for high throughput. Dual-slope converters suit precise measurements of slowly changing signals.
Applications and selection
Load cells and Wheatstone bridges, Pt100 inputs, pressure sensors and dataloggers can use ADCs. Slow temperature measurements and fast vibration measurements have different speed requirements. Consider input range, effective resolution, per-channel rate, latency and reference stability. In a multichannel controller, distinguish total conversion rate from the rate available to each channel. The analog sensor range must also match the input.