Electronic – mV difference not detected by LM741 opamp comparator

operational-amplifierphotodiode

I've made this comparator circuit, it has a changing current going through the photodiode and when lighting changes sufficiently it should trigger a 5V signal at the opamp output terminal.

When the photodiode is in low light conditions the non-inverting opamp input terminal has a voltage of 2mV. When I illuminate the photodiode I get a voltage of 20mV. I've adjusted R2 so that the inverting input terminal of the opamp is set to 10mV.

When I illuminate or darken the photo diode nothing changes to the output voltage of this opamp. Also nothing changes when I disconnect or switch the input terminals. It remains high (4.7V) at all times.

(I've measured all voltages directly to the opamp pins)

Is there a design error? Or is the voltage difference too small?

schematic

simulate this circuit – Schematic created using CircuitLab

Best Answer

There's an error in observing the valid electrical parameter for Vin CM range (common-mode) on the datasheet.

The input transitors need this to bias the NPN differential input amplifier.

You need a ground sensing comparator like the quad-LM339 (PNP inputs) or a negative Vee supply of at least 2V on the 741.