Adafruit: Engineer Question

Post here about your Arduino projects, get help - for Adafruit customers!

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
davidh
 
Posts: 155
Joined: Sat Feb 25, 2012 12:32 am

Adafruit: Engineer Question

Post by davidh »

HI,

I bought 'Beginning Ardunio Programming and had a question regarding digital and analog signals. It says that,
"The Arduino ADC has a 10-bit resolution, meaning that it will return a linear value from 0 to 1023 corresponding to 0v and +5v respectively. With this resolution, the Arduino ADC can read levels of voltage down to 4.88 millivolts per level."

I am not sure how the first sentence (in blue) relates to the second sentence (in red).

Thanks
David

User avatar
john444
 
Posts: 443
Joined: Sun Mar 04, 2012 2:42 pm

Re: Adafruit: Engineer Question

Post by john444 »

Hi David H,

It means that each binary step represents 4.88-mV.
When you ask the Arduino what value is on a analog pin it reports back a number between 0 and 1023.
To determine the actual voltage on the analog pin, you need to multiply it by .00488.
It is just the Full-scale value (5.0-V) divided by 1023.
If you used the 3.3-V voltage reference then each step would be 3.23-mV (3.3 / 1023).

John

davidh
 
Posts: 155
Joined: Sat Feb 25, 2012 12:32 am

Re: Adafruit: Engineer Question

Post by davidh »

Thanks John,

So each step for 3.3v is .00322? Appreciate the help


Cheers
David

User avatar
adafruit_support_bill
 
Posts: 88093
Joined: Sat Feb 07, 2009 10:11 am

Re: Adafruit: Engineer Question

Post by adafruit_support_bill »

So each step for 3.3v is .00322?
That is correct. :)

davidh
 
Posts: 155
Joined: Sat Feb 25, 2012 12:32 am

Re: Adafruit: Engineer Question

Post by davidh »

Thanks.

I guess this works the same way with pulse width modulation. It
says the resolution is 8 bit giving values between 0 and 255. So I guess
the read level for 5v would be 5/255?

Cheers
David

thefatmoop
 
Posts: 352
Joined: Tue Aug 19, 2008 4:36 pm

Re: Adafruit: Engineer Question

Post by thefatmoop »

pwm makes a signal which will average to analog levels. Not sure what you mean by "the read level for 5v would be 5/255"

User avatar
pburgess
 
Posts: 4161
Joined: Sun Oct 26, 2008 2:29 am

Re: Adafruit: Engineer Question

Post by pburgess »

0V = 0
5V = 1023

Everything in-between scales roughly linearly; e.g. a reading of 512 equals about 2.5V.

Locked
Please be positive and constructive with your questions and comments.

Return to “Arduino”