Showing posts with label AT89C51. Show all posts
Showing posts with label AT89C51. Show all posts

Sunday, 23 February 2014

Temperature sensor (engineering project) digital thermometer


A digital thermometer can be made by interfacing a temperature sensor to a micro controller AT89C51, the temperature sensor used in this project is LM35. the variation in temperature is converted into to 10mV voltage signal that is received by analogue to digital convertor IC ADC0804 which convert it into 8-bit binary data, and serves as an input to the AT89C51. the LCD interfaced with other port of micro controller display the temperature in Fahrenheit.
project layout and the use of ic


LM35:

It is basically a transducer – a device used to convert some physical quantity in to some measurable electrical quantity for example current, voltage, capacitance or inductance depending on the circumstances. LM35 that is used in this project comes in an IC package. It has 3 pins. 2 are used for the power supply while the remaining one is used to pass on the voltage difference of 10mV produced by varying quantity. So its resolution is 10mV. The temperature in it directly proportional to change in temperature so any change in temperature is only detected if it hits the 10mV limit otherwise no change is experienced.

ADC0804:

 is a very commonly used 8-bit analog to digital convertor. It is a single channel IC, i.e., it can take only one analog signal as input. The digital outputs vary from 0 to a maximum of 255. The step size can be adjusted by setting the reference voltage at pin9. When this pin is not connected, the default reference voltage is the operating voltage, i.e., Vcc. The step size at 5V is 19.53mV (5V/255), i.e., for every 19.53mV rise in the analog input, the output varies by 1 unit. To set a particular voltage level as the reference value, this pin is connected to half the voltage. For example, to set a reference of 4V (Vref), pin9 is connected to 2V (Vref/2), thereby reducing the step size to 15.62mV (4V/255). ADC0804 needs a clock to operate. The time taken to convert the analog value to digital value is dependent on this clock source. An external clock can be given at the Clock IN pin. ADC 0804 also has an inbuilt clock which can be used in absence of external clock. A suitable RC circuit is connected between the Clock IN and Clock R pins to use the internal clock.

16x2 LCD Display:

CD (Liquid Crystal Display) screen is an electronic display module and find a wide range of applications. A 16x2 LCD display is very basic module and is very commonly used in various devices and circuits. These modules are preferred over seven segments and other multi segment LEDs. The reasons being: LCDs are economical; easily programmable; have no limitation of displaying special & even custom characters (unlike in seven segments), animations and so on.

A 16x2 LCD means it can display 16 characters per line and there are 2 such lines. In this LCD each character is displayed in 5x7 pixel matrix. This LCD has two registers, namely, Command and Data.
The command register stores the command instructions given to the LCD. A command is an instruction given to LCD to do a predefined task like initializing it, clearing its screen, setting the cursor position, controlling display etc. The data register stores the data to be displayed on the LCD. The data is the ASCII value of the character to be displayed on the LCD. Click to learn more about internal structure of a LCD.


Working: 

AT89C51 from the family of 8051 is used as a microcontroller in this embedded system application. Its port 1 is used an input port in order to fetch data from ADC0804. The received data is then converted into ASCII in order to be displayed at the 16x2 LCD which is interfaced at the port 2 of the AT89C51.

Links for detail 

digital thermometer
2  google images of digital thermometer
list of temperature sensor