Interface of ADC0804 with 8051 Microcontroller |Keil C – AT89C51| Assembly Language|

 Interface ADC0804 with 8051, get Convert+ed Data from Port 1 and Display on LEDs of Port 3 Connect Data Pins (DB0-DB7) of ADC0804 with Port 1 of Microcontroller RD Pin of ADC0804 with P2.5. WR Pin of ADC0804 with P2.6. INTR Pin of ADC0804 with P2.7 Apply 2.5 Volts on Vref or Leave it Unconnected 

If Input Analog Value on VIN+ of ADC is 1.28 , Digital Value ________________ 

If Input Analog Value on VIN+ of ADC is 3.52 , Digital Value ________________ 

If Input Analog Value on VIN+ of ADC is 4.75 , Digital Value ________________ 

If Input Analog Value on VIN+ of ADC is 5.00 , Digital Value ________________

Source code:

ORG 00H

ADC:

SETB P2.5

CLR P2.6

NOP

NOP

NOP

SETB P2.6

EOC: JB P2.7 ,EOC

SETB P2.7

CLR P2.5

CLR A

MOV A ,P1

MOV P3,A

SJMP ADC

END

 

Result:

Apply 2.5 Volts on Vref or Leave it Unconnected

If Input Analog Value on VIN+ of ADC is 1.28 , Digital Value ________________

Calculation:

Vref is Unconnected

RANGE=0-5

VIN+=1.28

Value Required= 1.28 x  =  65.5

Which is 01000001 in Binary



Result:

Apply 2.5 Volts on Vref or Leave it Unconnected

If Input Analog Value on VIN+ of ADC is 3.52 , Digital Value ________________

Calculation:

Vref is Unconnected

RANGE=0-5

VIN+=3.52

Value Required= 3.52 x  =  180.2

Which is 10110100 in Binary



Result:

Apply 2.5 Volts on Vref or Leave it Unconnected

If Input Analog Value on VIN+ of ADC is 4.75, Digital Value ________________

Calculation:

Vref is Unconnected

RANGE=0-5

VIN+=4.75

Value Required= 4.75 x  =  243.2

Which is 11110010 in Binary

 


Result:

Apply 2.5 Volts on Vref or Leave it Unconnected

If Input Analog Value on VIN+ of ADC is 5 , Digital Value ________________

Calculation:

Vref is Unconnected

RANGE=0-5

VIN+=5

Value Required= 5 x  =  256

Which is 11111111 in Binary



Post a Comment

0 Comments