free 8051 Microcontroller Projects AVR PIC Microcontroller Projects Tutorials Ebooks Libraries, interfacing tutorials, lcd tutorial, stepper motor, dc motor 8051 assembly language programming electronics and communication ECE CSE pdf ebooks library BE final year project ideas Embedded systems

 
8051 microcontroller 8051 microcontroller
Forums

Moderators: Ajay, Junied , abbas1707, Arun Kumar V, pdi33, Shailesh NAYAK, ۞ TPS ۞, shyam, sashijoseph
Author Post
anjel
Wed Aug 20 2008, 10:00PM
 User Offline
Registered Member #9904
Joined: Mon Aug 18 2008, 12:18AM

Posts: 4
Thanked 0 times in 0 posts
hey cud you tell me what is the output of of ADC in terms of? Like as binary data or wt? Hw does controller recognize it? In my application i have to compare the output data of ADC with a reference value so m confused like will MC recognize data as HEX no or BINARY data.................or wt??

Back to top


sashijoseph
Wed Aug 20 2008, 10:23PM

 User Offline
Registered Member #5870
Joined: Mon Feb 04 2008, 06:26PM

Posts: 649
Thanked 138 times in 131 posts
The ADC's output is a binary representation of the input signal.
For eg if you have a 8-bit parallel adc configured for an input analog range of 0 to 5v,then for an input voltage of 0v you'll get as 00000000(00h) the binary value at the data pins.For 5v input you'll get 11111111 (0FFh).
So just read in the binary data into a variable and compare it directly with your reference hex value.
for eg if the data pins are connected to port P1...
ADCval = P1;
if (REFval == ADCval)
{....
}

Let there be music........
Back to top


 

Jump:     Back to top

Syndicate this thread: rss 0.92 Syndicate this thread: rss 2.0 Syndicate this thread: RDF
Powered by e107 Forum System

8051 Microcontroller Projects 8051 AVR tutorials PIC microcontroller, 8051 assembly language programming electronics and communication ECE CSE pdf ebooks library BE final year project ideas Embedded systems