Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Dusk - Dawn Switch (LDR)

Status
Not open for further replies.

ThomsCircuit

Well-Known Member
I know there is a great deal of poor schematics available but I have been doing a good deal of research before i settled on this one to build from.

So I found a 12 year old article from EEWeb showcasing a D2D switch using a popular (They say) ORP12 LDR. I do not have that LDR. what I have is a KE10720 If you could help me determine if my LDR is a suitable replacement for the ORP12
The SR of the ORP is 515 to 730ns with a peak of 515. The KE10720 SR is 550 - 650ns with an unknown peak. >KE107 Datasheet<

I also do not have the UA741 or the BC109.
I do have the LM311 & the BC547. I'm pretty sure the NPN is a good substitution but unsure of the OpAmp

I will be using this to drive about 24 white LED's (FV 2.5 current 20ma) in series of 3 each from a 12 volt 1AMP transformer. The same transformer will be used to power the circuit. Could you please help me modify this circuit to work with my LDR and OpAmp?

Dusk to Dawn Switch
LDR-switch-EEEWeb.gif
 
I am assuming that ve+ is pin4
I have looked for clarification (google) but found nothing definitive

No, that's ground - not the +input, which is pin 2.

There's plenty of info out there, such as this:


Even the datasheet for the LM311 shows how to do it, although be aware that there's an error on the version I looked at (attached below), with figure 16 (the relevant one) having the input pins labelled the wrong way round, +/- are swapped.
 

Attachments

  • LM311.pdf
    174.6 KB · Views: 178
Last edited:
Thank you. I meant what ve+ stood for. I thought i could find an article that referred to it. But I do appreciate you getting me so far with this.

Don't use that old 741...

Here is the circuit with an LM311.
I reduced VR1 to 50k. You'll have to experiment with the setting.
The LDR is a minimum of 10k when fully exposed to light and as much as 500k when dark.
The bulb is shown lit when exposed to light in the sim below.

1657492328246.png
 
Don't use that old 741...

Here is the circuit with an LM311.
I reduced VR1 to 50k. You'll have to experiment with the setting.
Awesome! Thank you so much. Im patting myself on the back here cause I was able to swap the 741 with the 311 and i got all but the hysteresis connection correct! (see post #11) Your schematic added some fine details and that is very much appreciated.

I did read that LDR OLP12 is popular but im using a different one. >KE107 Datasheet< If you think that would be an issue please let me know.
 
I did read that LDR OLP12 is popular but im using a different one. >KE107 Datasheet< If you think that would be an issue please let me know.

The ORP12 was basically the only LDR you ever heard of, and like the 741 it's 40+ years old, and probably long obsolete?. There are a wide variety of Chinese LDR's available, essentially the differences between them are there resistance values and ranges.
 
The ORP12 was basically the only LDR you ever heard of, and like the 741 it's 40+ years old, and probably long obsolete?. There are a wide variety of Chinese LDR's available, essentially the differences between them are there resistance values and ranges.
Components come and go. Its something how the circuit itself remaind the same after all these years.
I can see the 741 being outdated because of its specs but the LDR of today does not appear much different than that of 40 years ago. I did see that the ORP had a wider range though.
515-730 ORP
550-650 KE107
 
Components come and go. Its something how the circuit itself remaind the same after all these years.
I can see the 741 being outdated because of its specs but the LDR of today does not appear much different than that of 40 years ago. I did see that the ORP had a wider range though.
515-730 ORP
550-650 KE107
Makes no difference, particularly for such a simple application - you merely adjust the pot to suit.
 
SCH & PCB COMPLETE
EDIT. My diode D1 was backwards
View attachment 137800
40X40MM
-----------------------------------------

Hi

Assuming you want the LED to indicate when the relay is energized, move the LED and R7 so it is in parallel with the relay coil.

1657642833123.png


Also -

On the PCB,
1. The green traces appear much thinner than the red traces.
Hard to tell if that's a concern or not but I thought I mention it.
2. The traces connected to R2 should really connect at the pad, not to each other.
 
Hi
Assuming you want the LED to indicate when the relay is energized, move the LED and R7 so it is in parallel with the relay coil.

Also -
On the PCB,
1. The green traces appear much thinner than the red traces.
Hard to tell if that's a concern or not but I thought I mention it.
2. The traces connected to R2 should really connect at the pad, not to each other.
Thank you E for the LED fix.
The geeen (gnd) traces are on the bottom plane and will be flooded with a copper pour so I did not think it mattered.

As for the R2 traces I dont understand but as I look at the board I can do better with all the resistors on the left side. I'll post an updated board soon.

In my defense I had just returned from a night of beer induced Karaoke yodeling at my favorite watering hole. Thought I was doing a pretty good job. :facepalm:
 
A dimming pot should have a series resistor to set the maximum brightness but the high current will fry an ordinary pot. The pot and resistor must feed a little power transistor emitter-follower that feeds the LEDs.
HI, I put together what i think you are recommending. This is what the D2D circuit will be powering.
please let me know if I got this right.
LED SERIES.png
 
That's not an emitter follower - the LED's need to be in the emitter - you also need a current limiting resistor in series with the LED's.

However, it's a pretty poor circuit, and will generate plenty of heat.
Ok I done some reading and this is an emitter follower circuit.
Resistors added to each series set. They represent the max brightness of the leds
I set the pot is 50K.
Im not clear on what value the resistor at the base of TIP122 (R1) should be but I set it at 1K
LED SERIES.png
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top