A/D 101

Thread Starter

Mazaag

Joined Oct 23, 2004
255
Hey Guys,
Newbie here. Never used ADCs before, so bare with me.

Many PIC Microcontrollers usually include ADCs built-in. Question is, how do I know what the "digital word output" is for each voltage I input ?

I want to be able to convert the voltage across a pot into a digital word (using a Microcontroller with built in ADC), do some other operations using the PIC, and then transmit it across using an RF transmitter, which transmits digital data serially. On the other end, I will be recieving this serial data via a reciever module , which will input into another microcontroller that will control motors according to 5 bit data packages it recieves. I need to know the words that correspond to the different voltage levels, to be able to construct like a lookup table on the recieving end microcontroller.

I hope that made sense.

Thanks
 

n9352527

Joined Oct 14, 2005
1,198
ADC is characterise by it's input voltage range and resolution in bit. A 0-5V input range, 8-bit ADC will convert the full input voltage range to 2^8 (256) distinct values (255 if you omit zero). The relationship should be linear, although there are some linearity error we would ignore it for now.

Each step increase in digital value, therefore, represents 5/255 V. If you have 1V at the input, then the digital representation of that is 1/(5/255) = 51 or 0x33.

You could follow this logic for any different combination of input range and resolution (bit).
 

Thread Starter

Mazaag

Joined Oct 23, 2004
255
Originally posted by n9352527@Feb 3 2006, 11:19 AM
ADC is characterise by it's input voltage range and resolution in bit. A 0-5V input range, 8-bit ADC will convert the full input voltage range to 2^8 (256) distinct values (255 if you omit zero). The relationship should be linear, although there are some linearity error we would ignore it for now.

Each step increase in digital value, therefore, represents 5/255 V. If you have 1V at the input, then the digital representation of that is 1/(5/255) = 51 or 0x33.

You could follow this logic for any different combination of input range and resolution (bit).
[post=13783]Quoted post[/post]​

How is this input voltage range set ? I mean , is there a pin where you input the maximum voltage or something?

Thanks
 

n9352527

Joined Oct 14, 2005
1,198
Originally posted by Mazaag@Feb 3 2006, 08:12 PM
How is this input voltage range set ? I mean , is there a pin where you input the maximum voltage or something?

Thanks
[post=13784]Quoted post[/post]​
There are fixed range and variable range ADCs. Fixed ones can not be set while the variable range ones can be set either through external Vref, mode of operation (through register), span set and depends on Vsupply. You could also have unipolar or bipolar input and differential inputs.

There are too many permutations, so I suggest you refer to the datasheet of the particular device you are working with.
 
Top