Two ways to measure light

by ourcircuits

8 parts

Two light sensors share one 5 V rail. The LDR is a resistance law — R = R₁₀·(lux/10)^−γ, with the illuminance a number you set, because nothing on the canvas actually senses light — and it forms the upper leg of a divider feeding an 8-segment bar readout: at the shipped 100 lx it measures 1995 Ω and the divider settles at 4.161 V, lighting 7 of the 8 segments. The photodiode beside it is a real Shockley junction model, reverse-biased from the same rail and pushing its parameter-set photocurrent of resp × irr = 50.0 µA into a 22 kΩ load, measured at 1.100 V. The bar graph is a behavioural display — one real input resistance, eight thresholds evaluated only for the picture — and both readings land inside the default window, node A within 0.76 ms and node B within 0.48 ms.