741 problem in light sensitive switch

Thread Starter

RodneyB

Joined Apr 28, 2012
698
Here is a better circuit:

View attachment 80749

I believe that the resistance of the LDR near where you want things to happen is about 5 to 10KΩ, so I reconfigured the bridge so that the trip point is closer to the full sunlight resistance. That might in-and-of-itself cure the cloudy day problem. I also reduced the current through the two arms of the bridge, to reduce the standby current.

I also greatly increased the amount of the hysteresis by increasing the positive feedback around the opamp.

Finally, I took a look at the output circuit, and because the '741 doesn't pull all the way to 0V when low, with the 1K base resistor, I had to add the LED in series. The LED lights up when the relay is pulled in, but more importantly, its forward voltage drop (~2.2V for a red LED) subtracts from V(out) of the opamp to guarantee that the NPN turns off. That is further improved by the 10K from base to gnd.

Hi

I have built this circuit.

When I cover the LDR the LED goes off. When the LDR is uncovered the LED comes on but does not switch on the relay. The voltage after the LED is 9.7 volts but after the 1 K resistor there is no voltage. I tested the Resistor and it was fine.

Not really sure what to do.

Thanks

Rodney
 
Last edited:

Thread Starter

RodneyB

Joined Apr 28, 2012
698
Here is a better circuit:

View attachment 80749

I believe that the resistance of the LDR near where you want things to happen is about 5 to 10KΩ, so I reconfigured the bridge so that the trip point is closer to the full sunlight resistance. That might in-and-of-itself cure the cloudy day problem. I also reduced the current through the two arms of the bridge, to reduce the standby current.

I also greatly increased the amount of the hysteresis by increasing the positive feedback around the opamp.

Finally, I took a look at the output circuit, and because the '741 doesn't pull all the way to 0V when low, with the 1K base resistor, I had to add the LED in series. The LED lights up when the relay is pulled in, but more importantly, its forward voltage drop (~2.2V for a red LED) subtracts from V(out) of the opamp to guarantee that the NPN turns off. That is further improved by the 10K from base to gnd.

Hi

I have at last built this circuit. When there is light on the LDR the LED is on, when the LDR is covered the LED goes out. When the LED is on I assume that the relay should come on. The relay does not come on under any conditions
 

MikeML

Joined Oct 2, 2009
5,444
If there is no voltage after the 1K, then the transistor has a Vbe short. Take it out and Ohm it, or try another...
 

Thread Starter

RodneyB

Joined Apr 28, 2012
698
If there is no voltage after the 1K, then the transistor has a Vbe short. Take it out and Ohm it, or try another...
I took the transistor out and tested it and it was not faulty. I tested the voltage with the transistor out. after the LED is 9.62 Volts. On the other side of the 1K resistor, nothing. I fitted a new transistor and still got the same result.
 

MikeML

Joined Oct 2, 2009
5,444
What does "after the LED" mean? Are you measuring from LED cathode to gnd?

If there is 9.62V on the end of the 1K closest to the LED, the only way there is (nearly) zero on the end away from the LED is if the resistor is not 1K. Measure it in circuit.

What is the voltage at the anode of the LED to gnd with LDR illuminated? LDR not illuminated?

What LED did you use? I was expecting that you use a standard RED 30mA indicator LED that has a forward drop of ~2V
 

Thread Starter

RodneyB

Joined Apr 28, 2012
698
What does "after the LED" mean? Are you measuring from LED cathode to gnd?

If there is 9.62V on the end of the 1K closest to the LED, the only way there is (nearly) zero on the end away from the LED is if the resistor is not 1K. Measure it in circuit.

What is the voltage at the anode of the LED to gnd with LDR illuminated? LDR not illuminated?

What LED did you use? I was expecting that you use a standard RED 30mA indicator LED that has a forward drop of ~2V
Hi Mike

Sorry about the vague answers. I hope this time I am more accurate.

I have attached the datasheet of the LED I have used.

"after the LED I meant from Cathode to ground.

I have followed your instructions and below are the results.

Measuring R1 (1K) in circuit the value of the resistor is 989R

With the LDR covered, Anode to Ground = 1.93V

With the LDR NOT covered Anode to ground = 11.63 Volts.

I then measure R1(1K) and R2(10k) in circuit and the result was 1K. I then measure R2(10k) a reading of 0R.

Removing R2(10k) from the circuit and measuring it =9.8K

I then replaced R2(10k) with a new resistor. Measured it in circuit. And still had 0R.

Then on careful inspection of the PCB there was a very small bridge from the base to the emitter on the transistor Q1. I removed the bridge, measured the resistor in circuit with a result of 9.8K.

When then tested it again it works perfectly switching on and off. It does not chatter but I feel that the time it switches on the light level may be to light still.

How would I be able to make it only switch when it is slightly darker.

Thank you for all your help and assistance and a working project.

Best wishes

Rodney.
 

Attachments

MikeML

Joined Oct 2, 2009
5,444
Glad it was a solder bridge and not my circuit... ;) The LED is perfect.

To adjust the circuit posted in #11 to trip when it is darker, increase my R1 from 10K to about 22K and try that. You could go all the way to 47K or 100K, if 22K is not enough...

The running sim is on another computer. I will rerun the sim with the higher values tomorrow when I am over there.
 

MikeML

Joined Oct 2, 2009
5,444
Here is a re-sim with stepped values for R1. The progression is Grn, Red, LtBlu, DkBlu, Violet, at 10K, 15K, 18K, 22K, and 27K, respectively.

Note the effective resistance of the LDR at each of the new trip points. (Divide KV by V to get KOhms). Match the Grn trip point downwards to the Grn trip point upwards, for example.

11a.gif
 

Thread Starter

RodneyB

Joined Apr 28, 2012
698
Here is a re-sim with stepped values for R1. The progression is Grn, Red, LtBlu, DkBlu, Violet, at 10K, 15K, 18K, 22K, and 27K, respectively.

Note the effective resistance of the LDR at each of the new trip points. (Divide KV by V to get KOhms). Match the Grn trip point downwards to the Grn trip point upwards, for example.

View attachment 81721
Thanks very much for all the help
 
Top