Anda di halaman 1dari 48

Mini Project 2011

ACKNOWLEDGEMENT

The project report entitled AUTOMATIC LIQUID LEVEL CONTROLLERR USING 8051 MICROCONTROLLER, has been undertaken under the table guidance of Sri. Retheep Raj, Lecturer, Dept of Instrumentation and Control Engineering. We are deeply grateful to him, without whose advice, guidance and encouragement, the venture would not have been successful.

We are grateful to Prof. Seethalekshmi Amma, HOD, IC Dept. for her timely support.

We are also thankful to all our classmates, friends and non teaching staff members who helped us immensely in the preparation of this project.

Project Team Remya Ramakrishnan Vishnu P Pavithra U Pretheesh Jose Athul P Kumar 1
NSS COLLEGE OF ENGINEERING PALAKKAD IC DEPARTMENT

Mini Project 2011

ABSTRACT
This Project presents a working model of an Automatic Liquid Level Controller using 8051 microcontroller. This controller makes use of a pressure sensor which senses the pressure of the liquid in the tank and then converts this pressure signal into a voltage signal that is picked up by the microcontroller.

Here the upper and lower limits can be set and there is also an LCD which will show the amount of liquid in the tank in liters. In this project the upper limit is set to a particular value of 1000 litres but the lower set point can be adjusted according to the need of the user. There is also a provision to detect the dry run of the pump and in such a situation will give a warning signal.

This liquid level controller employs an eight channel ADC in which only the first two channels are used. The first one is for the upper set point and the second one is for the lower set point.

This microcontroller gives the input to an on-off relay which then actuates the motor. When the liquid reaches the upper set point the motor is automatically cut off and when it reaches the lower set point the motor is automatically switched on thereby pumping the liquid from the sump into the tank.

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

CONTENTS

1. Introduction 2. Level Sensing Unit

a. Pressure Sensor b. ADC c. Instrumentation Amplifier

3. Controller Unit a. 8051 microcontroller b. Relays 4. Design and Development a. Circuit Diagram b. Description

5. Reference

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

INTRODUCTION
The control of the water level in the overhead tank is a serious problem usually encountered. This problem leads to the overflow of water and in turn a drastic wastage of water and electricity.

The above problem is resolved by installing an automatic level controller in the tank at a position (level) at which the level of the water is said to be maintained. Here the sensing unit comprises of a pressure sensor rather than a mechanical float due to greater accuracy and a lesser tendency of errors since less mechanical parts are involved. This pressure sensor senses the pressure and then converts it to a voltage signal which is then conveyed to the microcontroller.

The ADC used in this project is an eight channel ADC out of which only 2 channels are used here- one for the upper set point and one for the lower set point and an additional feature is the LED screen which indicates the level of the liquid in litres and whether there is a dry run of the pipe in which case it makes the safety of the motor it s first priority.

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

LEVEL SENSING UNIT

a. PRESSURE SENSOR
The pressure sensor used in this project is the MOTOROLLA MPX10 Series. The MPX10 series device is a silicon piezoresistive pressure sensor providing a very accurate and linear voltage output directly proportional to the applied pressure. This standard, low cost, uncompensated sensor Permits manufacturers to design and add their own external temperature compensating and signal conditioning networks.

The output voltage of the differential or gauge sensor increases with increasing pressure applied to the pressure side (P1) relative to the vacuum side (P2). Similarly, output voltage increases as increasing vacuum is applied to the vacuum side (P2) relative to the pressure side (P1).

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

b. 0808 ADC

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

The ADC is the analog and digital converter and this particular project uses the 0808 ADC as shown in the figure above. This ADC has 8 channels and out of these 8 multiplexer channels this level controller uses the first two channels using the address latch and decoder (ALD). When you apply 000 to the ALD then the first channel is selected and when 001 is applied to the ALD then the 2nd channel is selected. The first channel is used to set the upper set point of the tank and the 2nd channel is used to set the lower set point. In this project, the upper set point is fixed in the program and the lower set point can be adjusted.

The address latch enable pin of the ALD is short circuited to the start pin of the control and tuning block. The tristate buffer is used to output the value from the ADC in the digital form, but it only acts as an output if the output pin is enabled (active high). When the ADC is done with the conversion, it gives an end of conversion signal (EOC) which is taken to be the interrupt sent out by the ADC and when that interrupt is received by the microcontroller then it sends an interrupt acknowledge. Once the interrupt has been read and the data has been outputted, the output pin again goes low. The Converter The heart of this single chip data acquisition system is its 8-bit analog-to-digital converter. The converter is designed to give fast, accurate, and repeatable Conversions over a wide range of temperatures. The converter is partitioned into 3 major sections: the 256R ladder network, the successive approximation register, and the comparator. The converter s digital outputs are positive true. The 256R ladder network approach (Figure 1) was chosen over the conventional R/2R ladder because of its inherent monotonicity, which guarantees no missing digital codes. Monotonicity is particularly important in closed loop feedback control systems. A non-monotonic relationship can cause oscillations that will be catastrophic for the system. Additionally, the 256R network does not cause load variations on the reference voltage. The bottom resistor and the top resistor of the ladder network in Figure 1 are not the same value as the remainder of the network. The difference in these resistors causes the output characteristic to be symmetrical with the zero and full-scale

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

points of the transfer curve. The first output transition occurs when the analog signal has reached +1 2 LSB and succeeding output transitions occur every 1 LSB later up to full-scale. The successive approximation register (SAR) performs 8 iterations to approximate the input voltage. For any SAR type converter, n iterations are required for an n-bit converter. Figure 2 shows a typical example of a 3-bit converter. In the ADC0808, ADC0809, the approximation technique is extended to 8 bits using the 256R network. The A/D converter s successive approximation register (SAR) is reset on the positive edge of the start conversion (SC) pulse. The conversion is begun on the falling edge of the start conversion pulse. A conversion in process will be interrupted receipt of a new start conversion pulse. Continuous conversion may be accomplished by tying the endof-conversion (EOC) output to the SC input. If used in this mode, an external start conversion pulse should be applied after power up. End-of-conversion will go low between 0 and 8 clock pulses after the rising edge of start conversion. The most important section of the A/D converter is the comparator. It is this section which is responsible for the ultimate accuracy of the entire converter. It is also the comparator drift which has the greatest influence on the repeatability of the device. A chopper-stabilized comparator provides the most effective method of satisfying all the converter requirements. The chopper-stabilized comparator converts the DC input signal into an AC signal. This signal is then fed through a high gain AC amplifier and has the DC level restored. This technique limits the drift component of the amplifier since the drift is a DC component which is not passed by the AC amplifier. This makes the entire A/D converter extremely insensitive to temperature, long term drift and input offset errors.

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

ADC 0804
General Description The ADC0801, ADC0802, ADC0803, ADC0804 and ADC0805 are CMOS 8-bit successive approximation A/D converters that use a differential potentiometric ladder similar to the 256R products. These converters are designed to allow operation with the NSC800 and INS8080A derivative control bus with TRI-STATE output latches directly driving the data bus. These A/Ds appear like memory locations or I/O ports to the microprocessor and no interfacing logic is needed. Differential analog voltage inputs allow increasing the common-mode rejection and offsetting the analog zero input voltage value. In addition, the voltage reference input can be adjusted to allow encoding any smaller analog voltage span to the full 8 bits of resolution. Features y n Compatible with 8080 P derivatives y no interfacing logic needed y access time - 135 ns n Easy interface to all microprocessors, or operates stand alone y n Differential analog voltage inputs y n Logic inputs and outputs meet both MOS and TTL y voltage level specifications y Works with 2.5V (LM336) voltage reference y On-chip clock generator y 0V to 5V analog input voltage range with single 5V y supply y No zero adjust required y 0.3" standard width 20-pin DIP package y 20-pin molded chip carrier or small outline package y Operates ratiometrically or with 5 VDC, 2.5 VDC, or y analog span adjusted voltage reference y Key Specifications y n Resolution 8 bits y n Total error 1 4 LSB, 1 2 LSB and 1 LSB

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

10

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

11

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

Instrumentation Amplifier

INA122

FEATURES
y y y y y y y y y y y LOW QUIESCENT CURRENT: 60mA WIDE POWER SUPPLY RANGE Single Supply: 2.2V to 36V Dual Supply: 0.9/+1.3V to 18V COMMON-MODE RANGE TO (V ) 0.1V RAIL-TO-RAIL OUTPUT SWING LOW OFFSET VOLTAGE: 250mV max LOW OFFSET DRIFT: 3mV/C max LOW NOISE: 60nV/Hz LOW INPUT BIAS CURRENT: 25nA max 8-PIN DIP AND SO-8 SURFACE-MOUNT

DESCRIPTION
The INA122 is a precision instrumentation amplifier for accurate, low noise differential signal acquisition. Its two-op-amp design provides excellent performance with very low quiescent current, and is ideal for portable instrumentation and data acquisition systems. The INA122 can be operated with single power supplies from 2.2V to 36V and quiescent current is a mere 60mA. It can also be operated from dual supplies. By utilizing an input level-shift network, input commonmode range extends to 0.1V below negative rail (single supply ground). A single external resistor sets gain from 5V/V to 10000V/V. Laser trimming provides very low offset voltage (250mV max), offset voltage drift (3mV/C max) and excellent common-mode rejection. Package options include 8pin plastic DIP and SO-8 surface-mount packages. Both are specified for the 40C to +85C extended industrial temperature range.

12

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

13

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

14

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

CONTROLLER UNIT
a. AT89S52 MICROCONTROLLER
Features Compatible with MCS-51 Products 8K Bytes of In-System Programmable (ISP) Flash Memory Endurance: 1000 Write/Erase Cycles 4.0V to 5.5V Operating Range Fully Static Operation: 0 Hz to 33 MHz Three-level Program Memory Lock 256 x 8-bit Internal RAM 32 Programmable I/O Lines Three 16-bit Timer/Counters Eight Interrupt Sources Full Duplex UART Serial Channel Low-power Idle and Power-down Modes Interrupt Recovery from Power-down Mode Watchdog Timer Dual Data Pointer Power-off Flag

Description The AT89S52 is a low-power, high-performance CMOS 8-bit microcontroller with 8K bytes of in-system programmable Flash memory. The device is manufactured using Atmel s high-density nonvolatile memory technology and is compatible with the industry- standard 80C51 instruction set and pinout. The on-chip Flash allows the program memory to be reprogrammed in-system or by a conventional nonvolatile memory programmer. By combining a versatile 8-bit CPU with insystem programmable Flash on a monolithic chip, the Atmel AT89S52 is a powerful microcontroller which provides a highly-flexible and cost-effective solution to many embedded control applications The AT89S52 provides the

15

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

following standard features: 8K bytes of Flash, 256 bytes of RAM, 32 I/O lines, Watchdog timer, two data pointers, three 16-bit timer/counters, a six-vector twolevel interrupt architecture, a full duplex serial port, on-chip oscillator, and clock circuitry. In addition, the AT89S52 is designed with static logic for operation down to zero frequency and supports two software selectable power saving modes. The Idle Mode stops the CPU while allowing the RAM, timer/counters, serial port, and interrupt system to continue functioning. The Power-down mode saves the RAM contents but freezes the oscillator, disabling all other chip functions until the next interrupt or hardware reset.

16

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

Relays Most of the relays used in the power system operate by the virtue of the current and / or voltage supplied by the current and the voltage transformer connected in various combinations to the system that is to be protected. Through the individual or relative changes in thse two quantities, fault signals presents type and location to the protective relay. Having detected the fault, the relay trip circuit which results in the opening of the circuit breaker and hence in the disconnection of the faulty line. 1. Fundamental Requirements of Protective relay y Selectively: It is the ability of the protective system to select correctly that part of the system in trouble and disconnect the faulty part without disturbing the rest of the system. y Sensitivity: it is the ability of the relay system to operate with low value of actuating quantity. y Reliabity: it ks the ability of the relay system under the pretermined conditions. Without reliability the protection would be rendered largely ineffective and could even become a liabilty. y Simplicity: the relaying system should be simple so that it can easily be maintained. y Economy: It is the most important factor, since cost may depending on size and capability from about 10$ to 100$. 2. Principle Most of the realys in service on electrical power systemtoday use of electro-mechanical type. They work on the following two main operation principles. 1. Electro-magnetic attraction. 17
NSS COLLEGE OF ENGINEERING PALAKKAD IC DEPARTMENT

Mini Project 2011

2. Electro-magnetic induction. 1. Electro-magnetic attraction relay operate by virtue of an armature being attracted to the poles of an electro-magnet or a plunger being drawn into a solenoid. Such relays may be activated by DC or AC quantities. 2. Electro-magnetic induction relays operate on the principle of induction motor and are widely used for protecting relay purpose involving AC quantities. They are not used with the DC quantities owing to the principle of operation. 3. Important Terms 1. Pick Up Current: It is the minimum current in the relay coil at which the relay starts to operate. So long as the current in the relay is less the relay does not operate and breaker controlled by it remains in the closed position. If the relay coil current is greater than the pickup current the relay operates to energise the trip coil which open the circuit breaker. 2. Current Setting: Its often desirable to adjust the pickup current to any required value. This is known as current setting and usually achived by the use of tapings on the relay-operating coil. 3. Plug Setting Multiplier (PSM): It is the ratio of the fault current in relay coil to the pickup current PSM = Fault current in relay coil/ pickup current. 4. Time Setting Multiplier (TSM): Adjust the time of the operation. This is known as TSM. Time setting dial is calibrated from 0 to 1 in steps of 0.05.

18

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

4. Types of Relay 1. Ordinary electro-magnetic relays. 2. Electro magnetic induction or simply induction relays. 3. Electro thermal relays. 4. Physico electrical relays. 5. Static relays. 6. Electro dynamic relays.

5.Types of Protection When fault occurs on any part of the electrical power system, it must be cleared quickly in order to avoid damage and interference with rest of the system. Protection scheme divided into two classes. Primary protection: To protect the component part of the power system it is called primary or main protection. Backup protection: Second line of defence in case of failure of when backup relay functions, a larger part is disconnected than when primary relaying functions correctly.

19

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

Circuit Description and development

20

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

21

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

ST
SP
    

ADC SE ADC
    

C


P
F
' 2   $ $    %  

A C

TIMER
&

SEN > SET PT

22

NSS COLLEGE OF ENGINEERING PALAKKAD

$ ) ' $  %  ( ((  %

P
IC DEPARTMENT

'

LOOP

#"!

SEN < S
3 

1' 0   (

Mini Project 2011

Programming the 8051 microcontroller


#include reg52.h
4

#define uc unsigned char

sbit rs=P3^0; sbit en=P3^1; sbit start=P3^2; sbit eoc=P3^3; sbit oe=P3^4; sbit adda=P3^5; sbit addb=P3^6; sbit addc=P3^7; sbit relay0=P3^5; sbit relay1=P2^6; sbit buzzer=P2^5; sbit forcestart=P2^4;

void delay(unsigned int y); void delay1(unsigned int z); void lcd_com(uc command_word); void lcd_data(uc value); void display(uc *s); void lcd_init(); void converta(unsigned int z); void convertb(unsigned int y);

23

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 void convertt(unsigned int x); void buzzer_pump(); void buzzer_warning(); void buzzer_error(); unsigned int getadcdatatank(); unsigned int getadcdataset(); unsigned int adctank,adcset;

void main() { int a=0,b=0,c=0,p=0,n=0,t=120,s=0; P0=0x00; delay(1); P1=0xff; delay(1); P2=0xff; delay(1); buzzer=1; delay(1); relay0=0; delay(1); relay1=0; delay(1); eoc=1;

24

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 delay(1); oe=0; delay(1); lcd_init(); delay(1); lcd_com(0x80); display(" WELCOME delay1(1000); lcd_com(0xc0); display(" AUTOMATIC "); delay1(1000); lcd_com(0x01); delay(1); lcd_com(0x80); display(" LEVEL CONTORL "); delay1(1000); lcd_com(0xc0); display(" SYSTEM "); ");

delay1(1000);

lcd_com(0x80); display("TANK= *** LITERS"); lcd_com(0xc0); display("SET POINT *** Lt"); delay1(1000);

25

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 buzzer_pump(); adctank=getadcdatatank(); delay(1); adcset=getadcdataset(); buzzer_pump(); delay1(500);

while(1) { ac: adctank=getadcdatatank(); delay1(50); adcset=getadcdataset(); delay1(50);

if(c==5) { lcd_com(0x01); lcd_com(0x80); display("****WARNING**** "); lcd_com(0xc0); display("check the motor"); buzzer_error();

26

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 }

if(adctank =adcset) {
6

relay0=1; relay1=1; b=1; a=0; p=1; }

if(forcestart==0) { if(adctank==600) goto ac; s=getadcdatatank(); relay0=1; relay1=1; b=1; a=0; p=1; while(b==1) {

27

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 adctank=getadcdatatank(); delay1(50); adcset=getadcdataset(); delay1(50); a++; buzzer_pump(); delay1(500); if(a==5) { b=0; if(adctank =s) { lcd_com(0x01); lcd_com(0x80); display("****WARNING**** "); lcd_com(0xc0); display("**Dry Pumping** "); buzzer_warning(); c++; p=0; n=1; t=10; lcd_com(0x01); lcd_com(0x80); display("Pumping failed"); lcd_com(0xc0);
7

28

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 display("plz wait....010"); while(n==1) { t--; delay1(550); convertt(t); if(t==0) { lcd_com(0x80); display("Tank= lcd_com(0xc0); display("Level set n=0; } } } } } } Lt"); Liters");

29

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 if(adctank==600) { relay0=0; relay1=0; buzzer=1; p=0; b=0; }

while(b==1) { adctank=getadcdatatank(); delay(1); adcset=getadcdataset(); delay(1); a++; buzzer_pump(); delay1(500); if(a==5) { b=0; if(adctank =adcset) { lcd_com(0x01); lcd_com(0x80); display("****WARNING**** ");
8

30

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 lcd_com(0xc0); display("**Dry Pumping** "); buzzer_warning(); c++; p=0; n=1; t=120; lcd_com(0x01); lcd_com(0x80); display("Pumping failed"); lcd_com(0xc0); display("next try on 120 "); while(n==1) { t--; delay1(550); convertt(t); if(t==0) { lcd_com(0x80); display("Tank= lcd_com(0xc0); display("Level set n=0; } } Lt"); Liters");

31

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 } } }

if(p==1) { buzzer_pump(); }

void delay(unsigned int y) {

32

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 unsigned int k,h; for(h=0;h y;h++) for(k=0;k =50;k++); return; }
9 9

void lcd_init() {lcd_com(0x38); delay(1); lcd_com(0x38); delay(1); lcd_com(0x38); delay(1); lcd_com(0x0c); delay(1); lcd_com(0x01); delay(1); lcd_com(0x02); delay(1); return; }

void lcd_com(uc command_word) { rs=0; P0=command_word;

33

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 en=1; delay(1); en=0; delay(1); return; }

void lcd_data(uc value) { rs=1; P0=value; en=1; delay(1); en=0; delay(1); return; }

void display(uc *s) { while (*s) { lcd_data(*s); delay(1); s++; }

34

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 return; }

void converta(unsigned int z) { unsigned int x; x=z/100; x=x+(0x30); lcd_com(0x86); lcd_data(x);

z=z%100; x=z/10; x=x+(0x30); lcd_com(0x87); lcd_data(x);

x=z%10; x=x+(0x30); lcd_com(0x88); lcd_data(x); return; } void convertb(unsigned int y) { unsigned int x;

35

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 x=y/100; x=x+(0x30); lcd_com(0xca); lcd_data(x);

y=y%100; x=y/10; x=x+(0x30); lcd_com(0xcb); lcd_data(x);

x=y%10; x=x+(0x30); lcd_com(0xcc); lcd_data(x); return; }

unsigned int getadcdatatank() { int adctank; float d; adctank=P2; d=adctank*100; d=d/255;

36

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 d=d*6; return(d); }

unsigned int getadcdataset() { int adcset; float l; start=0; delay(5); start=1; delay(5); while(eoc==1); delay(5); oe=0; delay(5); adcset=P1; delay(5); oe=1; delay(5); l=adcset*100; l=l/255; l=l*6; converta(l); return(l); }

37

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

void delay1(unsigned int y) { unsigned int k,h; for(h=0;h y;h++) for(k=0;k =250;k++); return; }
@ @

void buzzer_pump() { buzzer=0; delay1(100); buzzer=1; delay1(100); return; }

void buzzer_warning() { relay0=0; delay(5); relay1=0; delay(5); buzzer=0; delay1(1000);

38

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 buzzer=1; delay1(1000); buzzer=0; delay1(1000); buzzer=1; delay1(1000); buzzer=0; delay1(1000); buzzer=1; delay1(1000); buzzer=0; delay1(1000); buzzer=1; delay1(1000); buzzer=0; delay1(1000); buzzer=1; delay1(1000); buzzer=0; delay1(1000); buzzer=1; delay1(1000); buzzer=0; delay1(1000); buzzer=1; delay1(1000);

39

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 lcd_com(0x80); display("Tank= lcd_com(0xc0); display("Level set return; } Lt"); Liters");

void buzzer_error() { while(1) { buzzer=0; lcd_com(0x80); display(" delay1(300); lcd_com(0x80); display("****WARNING**** "); delay(600); } } ");

void convertt(unsigned int x) { unsigned int e; e=x/100; e=e+(0x30);

40

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 lcd_com(0xca); lcd_data(e);

x=x%100; e=x/10; e=e+(0x30); lcd_com(0xcb); lcd_data(e);

e=x%10; e=e+(0x30); lcd_com(0xcc); lcd_data(e); return; }

41

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

CONCLUSION The circuit has been soldered to the PCB and found to be working. The above project is an automatic tank filling system that has an LCD display showing the amount of liquid in the tank in litres and it also senses the level of the liquid in the tank and automatically switched the motor on and off. This project has the scope to be expanded to an industrial scenario such as in boiler drum applications by providing the required temperature compensation for the pressure sensor.

42

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

SPECIFICATION SHEETS

43

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

44

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011 NOTES: 1. 1.0 kPa (kiloPascal) equals 0.145 psi. 2. Device is ratiometric within this specified excitation range. Operating the device above the specified excitation range may induce additional error due to device self heating. 3. Full Scale Span (VFSS) is defined as the algebraic difference between the output voltage at full rated pressure and the output voltage at the minimum rated pressure. 4. Offset (Voff) is defined as the output voltage at the minimum rated pressure. 5. Accuracy (error budget) consists of the following: Linearity: Output deviation from a straight line relationship with pressure, using end point method, over the specified pressure range. Temperature Hysteresis: Output deviation at any temperature within the operating temperature range, after the temperature is cycled to and from the minimum or maximum operating temperature points, with zero differential pressure applied. Pressure Hysteresis: Output deviation at any pressure within the specified range, when this pressure is cycled to and from the minimum or maximum rated pressure, at 25C. TcSpan: Output deviation at full rated pressure over the temperature range of 0 to 85C, relative to 25C. TcOffset: Output deviation with minimum rated pressure applied, over the temperature range of 0 to 85C, relative to 25C. TCR: Zin deviation with minimum rated pressure applied, over the temperature range of 40C to +125C, relative to 25C. 6. Response Time is defined as the time for the incremental change in the output to go from 10% to 90% of its final value when subjected to a specified step change in pressure. 7. Common mode pressures beyond specified may result in leakage at the case to lead interface. 8. Exposure beyond these limits may cause permanent damage or degradation to the device. 9. Offset stability is the product s output deviation when subjected to 1000 hours of Pulsed Pressure, Temperature Cycling with Bias Test

45

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

0808

46

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

INA122

47

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Mini Project 2011

48

NSS COLLEGE OF ENGINEERING PALAKKAD

IC DEPARTMENT

Anda mungkin juga menyukai