Author Topic: arduino photo resistor readings questions  (Read 91 times)

sstavrou

  • Newbie
  • *
  • Posts: 2
    • View Profile
arduino photo resistor readings questions
« on: June 14, 2017, 08:44:31 AM »
hi all, im new to all this so i got some noob questions

so in a voltage divider with a photo resistor:

1 what difference would a 300Ω resistor have in my analog readings in an ardouino in contrast with a say 10kΩ resistor?
2 would my readings theoretically range from 0 to 1023 regardless of the resistor used?
3 why is 1023 the limit?

thx in advance ;)

VladRomanov

  • Administrator
  • Newbie
  • *****
  • Posts: 6
    • View Profile
Re: arduino photo resistor readings questions
« Reply #1 on: June 14, 2017, 10:53:26 PM »
hi all, im new to all this so i got some noob questions

so in a voltage divider with a photo resistor:

1 what difference would a 300Ω resistor have in my analog readings in an ardouino in contrast with a say 10kΩ resistor?
2 would my readings theoretically range from 0 to 1023 regardless of the resistor used?
3 why is 1023 the limit?

thx in advance ;)

Hi sstavrou,

The 300 ohm resistor would draw more current as opposed to the 10k ohm resistor, so I would recommend using the 10k ohm one. It would not impact your readings at all.

The readings would range from 0 to 1023.

1023 comes from the 10 bit Analog-Digital converter the Arduino (Atmega328) uses. 2 to the power 10 = 1024 which is the full resolution of the conversion.

Cheers,
Vlad

sstavrou

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: arduino photo resistor readings questions
« Reply #2 on: June 20, 2017, 01:39:33 AM »
Hi,

Thanks for your reply,

Yes I figured out that the answer was in the analogread method description. I also made some more research on the voltage divider and now it all makes a bit more sense!

thx again and great work!

VladRomanov

  • Administrator
  • Newbie
  • *****
  • Posts: 6
    • View Profile
Re: arduino photo resistor readings questions
« Reply #3 on: June 20, 2017, 12:32:35 PM »
Hi,

Thanks for your reply,

Yes I figured out that the answer was in the analogread method description. I also made some more research on the voltage divider and now it all makes a bit more sense!

thx again and great work!
Awesome! The only real limitation here is if you have too great of a resistance value, the analog pin won't be able to read the signal. I'f I'm not mistaken it's in the 1uA range, so you don't need to worry until you are in the billions of ohms or so.

Cheers,
Vlad