Light Detecting Auto LED Lighting... (RC Truck)

Thread Starter

NFA Fabrication

Joined Aug 12, 2012
112
OK, I am trying to make automated lighting for an RC truck. I have figure out a basic design that I like and have it tested, but it still has one glitch. I built and tested this light detecting circuit, added a 555 timer circuit to keep the LED's on for a while after triggered (So they would not flicker). I then drew it out after I had it tested, and liked it:



I am new to 555's, and thought that with each trigger, the 555's timer would "Start over". I have figure out how to manipulate the 555 "On time", but if I set if for 30 sec's or so, I don;t want to have the lights glitching on/off every 30 secs as the timer resets, as the LDR circuit will have slightly varying input as it gradually gets dark.

I would basically like to have the timer on the 555 reset everytime the LDR circuit goes low, instead of just taking input at the end of the cycle. I hope that makes sense! Thanks!

Here is the truck (The front one):



If this can't be done, I am considering using the light detecting circuit to charge a large capacitor that drives a transistor that will run the LED's. I like the elegance of the 555 timer idea if it can be accomplished. I had something like this working, but did not like how the LED's dimmed at the end of the triggering cycles, it appeared half ass'd to me. Thanks for any assistance!
 

wayneh

Joined Sep 9, 2010
17,498
I suppose you could add another 555, or use a 556. You could use the existing circuit for, say, a 5 second pulse and the second timer for a 30 second pulse. This way, a low-light detection within a 5 second window before the end of the 30-second cycle would ensure that the trigger was there and waiting to reset another 30 second cycle without a visible delay.

Does your current circuit work fine once it's dark enough?
 

BMorse

Joined Sep 26, 2009
2,675
Instead of a 555, why not use an op-amp (set up as a comparator) as the trigger for the LED's..... then you wont have to deal with the LED's flickering.... basically once the CDS triggers the comparator, it will stay on until it gets into a bright enough area for the lights to turn off.... something similar to this >> http://www.morse-code.com/9125cf00.png
 

Thread Starter

NFA Fabrication

Joined Aug 12, 2012
112
I suppose you could add another 555, or use a 556. You could use the existing circuit for, say, a 5 second pulse and the second timer for a 30 second pulse. This way, a low-light detection within a 5 second window before the end of the 30-second cycle would ensure that the trigger was there and waiting to reset another 30 second cycle without a visible delay.

Does your current circuit work fine once it's dark enough?
I may play around with that idea. Overall it works great, but I am fairly new to electronics, and made the assumption that the trigger would restart the timing cycle, which would make this work perfect.

I also played with using the above circuit set to 5 seconds, and had it charge a capacitor, and then used a 2222/2907 transistor combo after the capacitor to run the LED's. This made it better, but the LED's would eventually dim out, instead of cutting off, which I'd prefer.

Instead of a 555, why not use an op-amp (set up as a comparator) as the trigger for the LED's..... then you wont have to deal with the LED's flickering.... basically once the CDS triggers the comparator, it will stay on until it gets into a bright enough area for the lights to turn off.... something similar to this >> http://www.morse-code.com/9125cf00.png
I will have to do some reading on this, I am new to this, but eagerly learning!
 

wayneh

Joined Sep 9, 2010
17,498
... once the CDS triggers the comparator, it will stay on until it gets into a bright enough area for the lights to turn off...
I must be dense but I don't see how this would be different than his existing sensor, as neither has any hysteresis. I thought his problem was that the ambient light level - when it's near the switching point - may not stay low enough to maintain the low trigger for the 555 monostable.

I agree that using a comparator with hysteresis would probably be the simplest solution.
 

BMorse

Joined Sep 26, 2009
2,675
A LM324 may work to add hysteresis to the output, something like this:
oops, wrong diagram..... will have to locate right one and post it... :)

everything from pin 8 of the comparator can be ignored for this purpose......
 

Thread Starter

NFA Fabrication

Joined Aug 12, 2012
112
I must be dense but I don't see how this would be different than his existing sensor, as neither has any hysteresis. I thought his problem was that the ambient light level - when it's near the switching point - may not stay low enough to maintain the low trigger for the 555 monostable.

I agree that using a comparator with hysteresis would probably be the simplest solution.
I will be looking into that as well now. But I have a question, what happens if you pull pin 4 low, with the 555 reset when brought back to power? Also as far using a capacitor on the output before a transistor (Or 2), is there a simply way to make the power cut off sharper, as opposed to tapering off? Here is basically what I have now:

 

Ron H

Joined Apr 14, 2005
7,063
Do you really want the lights to go off after 30 seconds, or do you want them to stay on until it gets light again outside?
 

Thread Starter

NFA Fabrication

Joined Aug 12, 2012
112
Do you really want the lights to go off after 30 seconds, or do you want them to stay on until it gets light again outside?
The idea here is that I don't want the lights on the truck to be turning on and off a lot when the outdoor light is just on the borderline of triggering my system. The truck gets driven on trails in the woods, and going under trees and other overhead stuff can make the lights go on/off a bunch making the truck look likes it's having a seizure.

You need retriggerable monostable 555. One solution is in this site http://www.doctronics.co.uk/555.htm#retriggering
This is sounding more like what I was looking for. I will read up on this. I am somewhat new to the 555 and basic electronics, and did not realize the the 555 would not restart it's "Timer" with each trigger. Thanks!

Edit: Just read up on this, I think this is exactly what I am looking for!

Also, if this works, it is only a very slight modification to my existing circuit! I do not have any BC557B PNP transistors though. I wonder if I could substitute a 2N2907 PNP? I have plenty of those!
 
Last edited:

Thread Starter

NFA Fabrication

Joined Aug 12, 2012
112
Well, I have re-worked the plan with the new information, and have the revised diagram. I just ordered BC557's, as I have none. Any ideas of what may be able to be substituted in it's place for now? I have plenty of 2N2222's, 2N2907's, BC547's...

 
Last edited:
Top