Arduino Projects    |   Raspberry Pi  |     Electronic Circuits   |   Electronics Reference Design Library  |   AVR    |    PIC    |    8051    |    Electronic Projects

Interfacing ADC0808 with microcontroller 8051


Table of Contents:

  1. Interfacing ADC0808 with microcontroller 8051
  2. Features of ADC 0808
  3. Algorithm
  4. Steps to Program ADC 0808
Udit Chandra, Bhavnagar, India
ADC0808 is one of the useful chips from National Semiconductor. See in figure given aside. In lot of embedded systems micro controllers needs to take analog input. Most of the sensors AND transducers such as temperature, humidity, pressure, are analog. For interfacing these sensors to micro controllers we require to convert the analog output of these sensors to digital so that the controller can read it. Some micro controllers have built in Analog to Digital Converter (ADC) so there is no      need of external ADC. For controllers that don’t have internal ADC external ADC is used.
One of the most commonly used ADC is ADC0808. ADC 0808 is a Successive approximation type with 8 channels i.e. it can directly access 8 single ended analog signals. ADC0808 has an 8-bit data output just like the ADC804. The 8 analog input channels are multiplexed and selected according to table given below I/O pins using three address pins A, B, and C.

In the ADC0808, Vref(+) and Vref(-) set the reference voltage. If Vref(-)=Gnd and Vref(+)=5V, the step size is 5V/256 = 19.53mV. Therefore, to get a 10mV step size we need to set Vref(+)=2.56V and Vref(-)=Gnd. From figure given below of ADC0808, notice the ALE pins. We use A, B, and C addresses to select IN0 – IN7, and activate ALE to latch in the address. SC is for the start conversion. SC is same as the WR pin in other ADC chips. EOC is for end-of-conversion, and OE is for output enable (READ). The EOC and OE are the same as the INTR and RD pins respectively.

Source Code

This Code is only visible to Registered users. Please Login/Register


Comments (11)

how to send adc reading to

how to send adc reading to 16x2 lcd and simultaneuosly serial port............

Just initialize rs rw and en

Just initialize rs rw and en as with any of the port and then make two functions for LCD command and LCD data..

If anybody have this

If anybody have this programme then Give me full programme of lm35-adc0808 yar.

send me on my id

did u got full programme of

did u got full programme of lm35-adc0808 ????????

we are facing problems in

we are facing problems in adc0808 ...our vcc is 5v ..what will be our vref?.... 

Hey man i m trying to

Hey man i m trying to interface pressure sensor with adc0808. namely honeywell sscdann030paaa5 it has a range of 0-30 psi with min v0 = 0.5v and max 4.5v with resolution of 12 bits(analog) means i think it has a stepsize of (4.5-0.5)/2^12 = 0.97mV.


m i doing correctly?


and secondly if m doing correctly then what voltages i put on both vref pins.


i m currently giving 0.5 at vref(-) and 4.5 at vref(+)


will it show me correct value on lcd interfaced with at89c51?


i m little confused here i hope u'll reply as soon as possible. and thanks for your lm35 tutorial now i dont need to multiply adc value with constant to get correct value :-)


just as like as lm35 i want to do it for pressure sensor too...... m confused alot :-(

how to read battery

how to read battery voltage(9v) using ADC and 8051?

I want lm 35, adc0808

I want lm 35, adc0808 temperature control full assembly code.plz send at

hey anybody can tell me how

hey anybody can tell me how much delay time in above assembly programme


sir what about clock signal

sir what about clock signal pin 


This code is copied and

This code is copied and pasted from microcontroller and embedded system by mazidi


Learn about the latest applications and industry trends with tutorials and white paper design resources on vertical markets.

Energy Harvesting
MEMS Technology
OpenSource Hardware
RF Wireless
Wireless Charging


You are here