Every LED is fundamentally a PN junction diode. While we typically forward-bias them to emit photons, exposing that same junction to light while reverse-biased or zero-biased generates a measurable photocurrent. Using an LED as a photodetector allows smart lighting designers to eliminate external photodiodes or ambient light sensors (ALS), saving BOM costs and simplifying optical alignment. However, integrating this dual-mode operation into a 120V/240V mains-powered, dimmable lighting circuit introduces severe challenges regarding driver inrush, power factor, and dimmer minimum-load thresholds.
Emission vs. Detection: Efficacy and Spectral Overlap
To use an LED as a light sensor, you must understand the relationship between its emission efficacy and its absorption quantum efficiency. An LED detects light most efficiently at the exact wavelength corresponding to its bandgap energy. For phosphor-converted white LEDs, the underlying blue die (typically ~450nm) acts as the primary sensor, while the broad-spectrum yellow phosphor emission is largely ignored by the junction.
| LED Type | Nominal Wattage | Lumen Output | Efficacy (lm/W) | Peak Detection Wavelength |
|---|---|---|---|---|
| Warm White (2700K Phosphor) | 9.0W | 800 lm | 88 lm/W | ~450nm (Blue Die) |
| Cool White (5000K Phosphor) | 9.0W | 1100 lm | 122 lm/W | ~450nm (Blue Die) |
| Bare Blue (InGaN) | 3.0W | N/A (Radiometric) | N/A | 450nm |
| Bare Red (AlGaInP) | 2.5W | N/A (Radiometric) | N/A | 630nm |
As shown above, efficacy (lm/W) is not just a measure of brightness; it is a proxy for the junction's radiative efficiency. When designing a circuit to read this photocurrent, expect micro-ampere (µA) ranges under indoor lighting conditions. According to All About Circuits, measuring the discharge time of the LED's inherent junction capacitance is often more reliable on a microcontroller than trying to read the raw analog photocurrent via an ADC, as it eliminates the need for high-gain transimpedance amplifiers.
Mains Circuit Impact: Dimmers, Inrush, and Power Factor
Switching an LED between emission mode (forward bias via the driver) and detection mode (high-impedance via the MCU) requires interrupting the driver circuit. This rapid switching interacts violently with mains dimmers and driver bulk capacitors.
Circuit Impact Math: Inrush and Power Factor
When the MCU reconnects the LED to the driver after a sensing cycle, the driver's bulk input capacitor is often partially discharged. The resulting inrush current can destroy the switching MOSFETs in the driver if not managed.
The peak inrush current is calculated as:
I_peak = V_peak / (ESR_capacitor + R_trace)
For a 120VAC mains circuit, V_peak is approximately 170V. If the driver's equivalent series resistance (ESR) and trace resistance total 1.5Ω, the instantaneous inrush current spikes to 113A. To mitigate this, your driver must include an NTC thermistor or an active inrush current limiter (ICL). Furthermore, commercial smart fixtures in 2026 require a Power Factor (PF) >0.9 to comply with DesignLights Consortium (DLC) standards. A low PF causes phase shifts that confuse trailing-edge dimmers, leading to erratic sensing baselines.
Dimmer Compatibility and Minimum Load Criteria
Which dimmer and driver should you use for a dual-mode fixture count? If you are deploying a single 10W smart fixture that uses its main LED for sensing, you face the minimum-load problem. Standard TRIAC (leading-edge) dimmers require a 25W to 40W minimum load to keep the internal TRIAC latched. A 10W fixture will cause the dimmer to misfire, injecting high-frequency noise that completely drowns out the LED's micro-ampere photocurrent.
- Required Dimmer Type: Trailing-edge (ELV) electronic dimmer. Trailing-edge dimmers use MOSFETs/IGBTs and switch at zero-cross, drastically reducing electromagnetic interference (EMI) that corrupts the sensor reading.
- Minimum Load Check: You must select a dimmer explicitly rated for a <5W minimum load. The Lutron Diva DVCLV or Lutron Caseta PD-5NE are industry standards here, as documented in Lutron's LED compatibility matrix.
- Driver Selection: Use a constant-current driver with a dedicated 0-10V or PWM dimming input (like the Mean Well LCM-40) rather than a phase-cut AC driver. This allows the MCU to drop the driver output to zero for sensing without cutting mains power to the driver's logic.
Troubleshooting Flicker, Heat, and Enclosure Constraints
Integrating a photodetector function into a primary illumination source introduces physical and perceptual failure modes that must be engineered out of the final product.
Why Flicker Happens and the Fix
The Symptom: A faint, high-frequency strobe or 120Hz flicker is visible when the fixture is actively sensing ambient light.
The Cause: To measure light, the MCU must switch the LED to a high-impedance state to allow the junction capacitance to discharge. The human eye integrates light over approximately 13 milliseconds. If the MCU holds the LED in "sense mode" for longer than 3ms, the brain perceives the dark gap as flicker. Furthermore, trailing-edge dimmers often bleed a small continuous current to power their internal electronics; this bleed current can inadvertently forward-bias the LED during the sensing window, corrupting the data.
The Fix: Limit the capacitance-discharge sensing window to <500µs (0.5ms). This is well below the human flicker fusion threshold. To handle dimmer bleed current, place a 100kΩ bleeder resistor in parallel with the LED string to shunt the dimmer's leakage current away from the sensing junction.
Heat and Enclosure Constraints
Using an LED as a sensor is highly temperature-dependent. The junction's "dark current" (the reverse leakage current present even in total darkness) doubles for every 10°C rise in junction temperature ($T_j$). If your fixture's thermal management is poor, the dark current will exceed the photocurrent generated by indoor ambient light, rendering the sensor useless.
Optically, the enclosure lens must pass the target wavelength. Polycarbonate lenses naturally block UV but pass visible light, making them ideal for white-LED sensors. However, if the enclosure uses a UV-stabilized acrylic that happens to absorb heavily at 450nm (the blue die's peak sensitivity), your sensor will read artificially low lux values. Always verify the lens transmission spectrum against the LED's bandgap wavelength.
Frequently Asked Questions
Can I use a standard 120V LED bulb as a photodetector?
No, not without heavy modification. Standard off-the-shelf 120V LED bulbs contain integrated AC-DC drivers with rectifier bridges and bulk capacitors that block the microcontroller from accessing the raw LED junction. To use an LED as a photodetector, you need access to the DC side of the LED string, which requires a custom driver board or a low-voltage (12V/24V DC) MR16-style fixture where the LED pins are directly accessible to your sensing circuit.
What microcontroller ADC resolution is needed for an LED as a photodetector?
If you are measuring raw photocurrent via a shunt resistor, a standard 10-bit or 12-bit ADC is insufficient because the voltage drop across the shunt will be in the microvolt range, lost in the noise floor. Instead, use the capacitive discharge method. Connect the LED's cathode to a standard GPIO pin, charge the junction capacitance to 3.3V, reverse-bias it (or leave it in high-Z), and use the MCU's internal timer to measure how many microseconds it takes for the voltage to drop below the GPIO's logical '0' threshold (typically ~0.8V). This requires no ADC at all, only a high-resolution hardware timer, making even an inexpensive ESP32-S3 or ATtiny85 highly effective.
Does using an LED as a light sensor reduce its lighting lifespan?
Paradoxically, it can slightly extend the LED's lifespan, provided the thermal design is adequate. When the MCU switches the LED into high-impedance sensing mode for 500µs intervals, it is effectively applying a microscopic duty-cycle reduction. This gives the phosphor layer and the InGaN crystal lattice brief thermal relaxation periods. However, if the sensing circuit accidentally applies a reverse voltage exceeding the LED's maximum reverse breakdown voltage (typically 5V to 12V for standard illumination LEDs), it will cause avalanche breakdown and permanently degrade the lumen output.






