# Voltage divider sensor range

**URL:** <https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680>\
**Category:** Sensors\
**Created:** [May 3, 2025, 4:25am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680 "2025-05-03T04:25:30Z")\
**Posts on this page:** 17\
**Page:** 1

<div class="post-metadata">

**Author:** ![c-compute](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/c-compute/32/1151590_2.png) [@c-compute](https://forum.arduino.cc/u/c-compute)\
**Post date:** [May 3, 2025, 4:25am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/1 "2025-05-03T04:25:30Z")

</div>

I'm working on an Arduino project using a voltage divider to read a photodiode. Currently, I'm using a 2kΩ resistor, but I'm not getting full dynamic range—a lack sensitivity to lower light levels. I want to expand the voltage response to detect dimmer conditions more effectively. Should I increase or decrease the resistor value to achieve better sensitivity to low-light inputs? I'd love to hear recommendations. Any insights would be appreciated.

To get the range, we need to use very bright lights. The kit I've already built it. So a bit of a pain to open up the box. So need a game plan.

_Update_: This video explains the circuit. Looks like 1k resistor would be best. Also the addition of a smoothing capacitor to handle the flickering AC lights.

[![](https://europe1.discourse-cdn.com/arduino/original/4X/d/8/c/d8c9450a068191c58b0bbf66fd2da1e1207bb149.jpeg "Simple DIY light meter using photodiode resistor voltage divider learning electronics lesson 0061") ](https://www.youtube.com/watch?v=MNYzjE8m4yY)

P.S. I don't know why the distracted post about the RGB LED was considered the solution. The RGB LED has nothing to do with the question about photodiodes.

---

<div class="post-metadata">

**Author:** ![LarryD](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/larryd/32/215550_2.png) [@LarryD](https://forum.arduino.cc/u/LarryD)\
**Post date:** [May 3, 2025, 4:49am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/2 "2025-05-03T04:49:58Z")

</div>

- Add op-amp to the divider output, the gain of the amplifier can be adjusted to suit your needs.  
example: **LMV321**

---

<div class="post-metadata">

**Author:** ![Wawa](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/wawa/32/1211303_2.png) [@Wawa](https://forum.arduino.cc/u/Wawa)\
**Post date:** [May 3, 2025, 4:50am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/3 "2025-05-03T04:50:14Z")

</div>

What are you measuring.  
A **[digital light sensor](https://www.adafruit.com/product/1980)** could have a higher dynamic range.  
Leo..

---

<div class="post-metadata">

**Author:** ![Grumpy\_Mike](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/grumpy_mike/32/213521_2.png) [@Grumpy\_Mike](https://forum.arduino.cc/u/Grumpy_Mike)\
**Post date:** [May 3, 2025, 6:54am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/4 "2025-05-03T06:54:01Z")

</div>

I have used the digital light sensor recommended by Leo, to make a system for detecting how photo florescence (glow in the dark stuff) decays with time. It is very sensitive.

However:-

> [@c-compute](#):
>
> using a voltage divider to read a photodiode.

Can you show the wiring of this please as there are several ways you can wire this up. Also what sort of photo diode are you using? Normally these sort of things are IR sensitive and not sensitive to normal visible light. What sort of light are you using?

You might be better off using a light dependent resistor (LDR) instead.

> [@c-compute](#):
>
> The kit I've already built it. So a bit of a pain to open up the box.

No pain, no gain.

---

<div class="post-metadata">

**Author:** ![PaulRB](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/paulrb/32/216330_2.png) [@PaulRB](https://forum.arduino.cc/u/PaulRB)\
**Post date:** [May 3, 2025, 8:37am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/5 "2025-05-03T08:37:47Z")

</div>

> [@c-compute](#):
>
> using a voltage divider to read a photodiode

That doesn't make any sense. The voltages produced by photodiodes are pretty small. They need boosting up, not reducing down.

Can you post a link to the data sheet for the photodiode? Also your schematic showing how it is wired to the Arduino, and a link to this "kit" you mentioned and how that is involved.

---

<div class="post-metadata">

**Author:** ![c-compute](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/c-compute/32/1151590_2.png) [@c-compute](https://forum.arduino.cc/u/c-compute)\
**Post date:** [May 3, 2025, 9:52am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/6 "2025-05-03T09:52:52Z")

</div>

Photodiode Specification: Receive Wave Range : 400-1100 nm Response Peak Wavelength：940 nm Receiving Angle : 40° Material：Si, Plastic, Metal Head Color : Clear Head Size : 3 x 4mm / 0.12 x 0.16 inch (D\*H) Pin Dia : 0.4 mm / 0.016 inch Total Length: 33mm / 1.3 inch

---

<div class="post-metadata">

**Author:** ![c-compute](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/c-compute/32/1151590_2.png) [@c-compute](https://forum.arduino.cc/u/c-compute)\
**Post date:** [May 3, 2025, 9:58am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/7 "2025-05-03T09:58:28Z")

</div>

![wiringlooms](https://europe1.discourse-cdn.com/arduino/original/4X/1/8/2/18284fddc4ba746a8c1b4509f65f5acdf8eba8ec.jpeg)

In the above chart, photodiodes can replace the LDR's but keep in mind that polarity matters. Photodiodes must be installed with reverse bias. As for the RGB LED, there are 4 leads: a ground, red, green, and blue. Please see the next image for complete details. The 2k resistors can be higher ohms for increased photosensitivity.

Using a **photodiode in reverse bias** within a **voltage divider** setup on an Arduino is a great way to measure light intensity with improved sensitivity and faster response times. Here’s how it works:

### **Understanding Reverse Bias Photodiodes**

- In **reverse bias mode** , the cathode (negative) is connected to a higher voltage, and the anode (positive) to a lower voltage (typically ground).
- The diode does **not conduct** like a regular diode unless light strikes it, generating a **small photocurrent** proportional to the light intensity.
- This configuration **reduces capacitance** , making the response faster.

* * *

### **Setting Up the Voltage Divider**

A **voltage divider** transforms the photocurrent into a voltage signal that the Arduino can read. Here's a basic setup:

1. **Connect the Photodiode in Reverse Bias** :

2. **Selecting the Resistor Value** :

3. **Reading the Voltage with Arduino** :

* * *

### **Arduino Code Example**

```cpp
const int sensorPin = A0; // Photodiode voltage divider junction
void setup() {
    Serial.begin(9600);
}
void loop() {
    int sensorValue = analogRead(sensorPin); // Read voltage level
    float voltage = sensorValue * (5.0 / 1023.0); // Convert ADC value to volts
    Serial.println(voltage); // Print voltage to monitor
    delay(500);
}

```

This setup allows you to track changes in light levels and adjust the resistor value for better sensitivity.

---

<div class="post-metadata">

**Author:** ![c-compute](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/c-compute/32/1151590_2.png) [@c-compute](https://forum.arduino.cc/u/c-compute)\
**Post date:** [May 3, 2025, 10:03am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/8 "2025-05-03T10:03:03Z")

</div>

Asking copilot, it suggests 10k. Perhaps I could use little pots (like the little screw driver kind) to tune the resistance.

On my project, I wired it wiring loom style (like a automobile) rather than a daughter board "shield", so it's easier to swap out. I was just wondering what humans had to say.

---

<div class="post-metadata">

**Author:** ![Grumpy\_Mike](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/grumpy_mike/32/213521_2.png) [@Grumpy\_Mike](https://forum.arduino.cc/u/Grumpy_Mike)\
**Post date:** [May 3, 2025, 5:16pm UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/9 "2025-05-03T17:16:38Z")

</div>

> [@c-compute](#):
>
> I was just wondering what humans had to say.

Humans can tell you the truth and point out your inconsistencies.

First of all in your diagram you call it a light dependant resistor. Then you call it a photo diode.  
**these are two different things**  
So what do you actually have?

The diagram also shows all the wires to the RGB going into one connector. That is not how it is wired.

Schematics are important things to get right, otherwise they just no help at all.

---

<div class="post-metadata">

**Author:** ![c-compute](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/c-compute/32/1151590_2.png) [@c-compute](https://forum.arduino.cc/u/c-compute)\
**Post date:** [May 3, 2025, 6:36pm UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/10 "2025-05-03T18:36:08Z")

</div>

I have made 3 devices, the first two used LDR's, the last one I am trying photodiodes.

As for the RGB LED diode, there are 4 leads, a ground and a red, green, and blue. I thought that was common knowledge and hence didn't bother to go into greater detail. In the documentation, I have added a note for future readers. Also the RGB LED is outside the scope of this inquiry.

---

<div class="post-metadata">

**Author:** ![kmin](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/kmin/32/1147370_2.png) [@kmin](https://forum.arduino.cc/u/kmin)\
**Post date:** [May 3, 2025, 7:28pm UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/11 "2025-05-03T19:28:58Z")

</div>

> [@c-compute](#):
>
> the first two used LDR's the last one I trying photodiodes

They both sense light and have two legs.  
Which one you are referring here on your post.

---

<div class="post-metadata">

**Author:** ![c-compute](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/c-compute/32/1151590_2.png) [@c-compute](https://forum.arduino.cc/u/c-compute)\
**Post date:** [May 4, 2025, 1:07am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/12 "2025-05-04T01:07:33Z")

</div>

As per the first post, I am asking about photodiodes.

---

<div class="post-metadata">

**Author:** ![Wawa](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/wawa/32/1211303_2.png) [@Wawa](https://forum.arduino.cc/u/Wawa)\
**Post date:** [May 4, 2025, 1:21am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/13 "2025-05-04T01:21:01Z")

</div>

And I was asking what you are measuring.  
Leo..

---

<div class="post-metadata">

**Author:** ![anon94801460](https://avatars.discourse-cdn.com/v4/letter/a/278dde/32.png) [@anon94801460](https://forum.arduino.cc/u/anon94801460)\
**Post date:** [May 4, 2025, 1:28am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/14 "2025-05-04T01:28:06Z")

</div>

Forget about the voltage divider. Here is what the pros use (introductory overview):

[https://www.allaboutcircuits.com/technical-articles/design-tips-for-photodiode-amplifiers/](https://www.allaboutcircuits.com/technical-articles/design-tips-for-photodiode-amplifiers/)

---

<div class="post-metadata">

**Author:** ![Grumpy\_Mike](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/grumpy_mike/32/213521_2.png) [@Grumpy\_Mike](https://forum.arduino.cc/u/Grumpy_Mike)\
**Post date:** [May 4, 2025, 7:39am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/15 "2025-05-04T07:39:11Z")

</div>

Read this:-  
[Wikipedia - Transimpedance amplifier](https://en.wikipedia.org/wiki/Transimpedance_amplifier)

This type of amplifier is much beloved by people who make voltage controlled oscillators when reproducing the original Moog modular sound synthesisers. Unfortunately they are getting increasingly rare / expensive as a quick look at eBay will show you.

Also you will need to add a range of resistors into your collection of 1MΩ to 10MΩ to design things. Values you would not normally use with most Arduino circuits.

WokeNote:-  
Transimpedance amplifiers are not amplifiers that self identify as voltage driven amplifiers.

---

<div class="post-metadata">

**Author:** ![Grumpy\_Mike](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/grumpy_mike/32/213521_2.png) [@Grumpy\_Mike](https://forum.arduino.cc/u/Grumpy_Mike)\
**Post date:** [May 4, 2025, 10:49am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/16 "2025-05-04T10:49:32Z")

</div>

> [@c-compute](#):
>
> Also the RGB LED is outside the scope of this inquiry.

Absolutely _nothing_ is outside the scope of asking for help here. We show you and tell you what is wrong. If we just concentrated on the specifics of an inquire we would never be able to solve half the problems we do. The point is that you don't know, so you don't know what to ask.

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/system/32/1140315_2.png) [@system](https://forum.arduino.cc/u/system)\
**Post date:** [October 31, 2025, 10:49am UTC](https://forum.arduino.cc/t/voltage-divider-sensor-range/1378680/17 "2025-10-31T10:49:39Z")

</div>

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.
