Intermittent 555 trouble??

Thread Starter

OneEarWillie

Joined Oct 23, 2010
6
Disclaimer – I do not, normally, dabble with electronics on a component level. I recently purchased a breadboard JUST so I could build and test the project described below. I have been working on this circuit in the evenings for a month now… and I think I’ve almost got it. What you are about to read is the culmination of my scouring the internet trying to “invent” a circuit for a specific need. Ultimately, I have joined this forum seeking help and advice. My terminology might be a little off, so I will be as descriptive as I can please bear with me.

I have built a circuit which triggers a relay upon a change-of-state of the light sensed, by a photo-resistor. The intent is that a motor should run for approximately .25 to .75 seconds each time the trigger light is switched ON or OFF. The timing really isn't important... It's driving an external momentary contact activated circuit.

On my breadboard, the circuit appeared to be functioning perfectly. However, now that I have soldered the components to a small PCB, I seem to be having intermittent trouble. Occasionally, the relay (driven by a 555 in monostable mode) does not stay latched. According to my O-scope (at the moment that this occurs), the output of the 555 is too short. I've monitored to capacitor's charge as well. During normal operation, I can see the capacitor's charge build up and discharge... as expected (see 7 in waveforms). But, when this "glitch" happens, It appears as though the capacitor is not charging (or charges instantly). It looks like I'm just getting a quick spike (*7 failed)... discharging the 555 almost as soon as it's triggered.

I would like this circuit to be sitting, waiting to be triggered. Its usage could be very erratic. It could get activated several times in a minute. Or, it might only get activated once in several hours. Right now, it just isn't reliable. Sometimes it will work 10-12 times in a row, without failing. Then sometimes it will fail 10-12 times in a row (during testing). It seems as though testing the circuit aggravates the problem.

It is my guess that I have been too conservative with my component usage. I didn’t include any “unnecessary” parts. If I didn’t notice a significant change in operation with or without a filter capacitor or resistor, then I didn’t include it in the final circuit. I think, I may be getting some sort of inductive feedback from the relay coil? Could that be the cause? Do any of you know what I’ve got wrong or what I should do differently?



Circuit Explanation: As the photo-resistor's value (2) changes it enters a pair of 741 Op-Amps (comparators)... one inverting and the other non-inverting, each with a mid-range threshold. Each Op-Amp's output [(4) and (5)] is rectified and the outputs are combined (6). The result is a negative pulse each time the photo-resistor senses a change from dark to light or light to dark (1). This negative pulse is sent to a 555 timer. The timer is configured as a monostable and using a 15KΩ resistor and a 47μF capacitor, I have achieved an output pulse (8) that is sufficient to activate a relay and begin driving a motor. Only a small amount of motor rotation is needed to ensure the sustaining contacts are made and the remainder of my contraption can function.
 
Last edited:

Wendy

Joined Mar 24, 2008
23,421
A 741 is a very old op amp, if you read the specs it has no minimum power supply voltage. You are at the very bottom of where it might work. Good use of the ± power supplies though.

A 555 monostable timer also requires a signal conditioner. If you leave the input pin 2 low this is an illegal condition for the timer, and the output pin 3 will stay high until pin 2 is fixed. You are also feeding the negative power supply to the 555. Basically you are right, you left off a few parts for the 555 timer. A input signal conditioner described in the link below should fix the problem.

I have written several articles covering the basics of 555s, I tend to be the 555 go to person around here.

555 Monostable (use the full circuit shown in this link)

The 555 Projects

My Cookbook
 

Thread Starter

OneEarWillie

Joined Oct 23, 2010
6
Thank you so much for your reply, Bill... those links are all familiar to me. I didn't realize it (until now) but in the process of researching/building this project, I have happened on a wealth of information shared by YOU. Thanks for making it all available for people like me to find and use. This has been a wonderful learning experience for me. I'm proud of what I've accomplished... but I couldn't have come close without the information you have shared.

I am confused by the 3rd paragraph of your Monostable instruction. It's the part about R3 and C1 and the connection(s) occurring at point(s) A and/or B. Perhaps using actual switches would help people like me to "see" it. If there were switches there... would any of them be momentary contact?

I will go add in the 0.1μF caps (that I left out) right now. I'll let you know how it turns out.

Should I add anything to dissipate the charge on the relay coil?

Is there another op-amp (besides a 741)... that would be better for me to use?

Am I going about this all wrong? Is there an easier/better way to build a rising AND falling edge triggered circuit?

A side note: I discovered by accident that I needed a resistor (to ground) on the output of the combined diodes (in my circuit). My circuit was only triggering on one edge. However, when I noticed that when I attached my meter to that point... it began working correctly. So I added a 10KΩ resistor... and now it's triggering dual-edge like I want. But I don't know why?? In theory... shouldn't I be able to pull out that resistor and STILL get dual-edge operation? What is happening that I'm missing?
 
Last edited:

Wendy

Joined Mar 24, 2008
23,421
Thank you for including a schematic without being asked, this makes you a rare user indeed. It was also nicely done. I hope to see more of you around here.

I am confused by the 3rd paragraph of your Monostable instruction. It's the part about R3 and C1 and the connection(s) occuring at point(s) A and/or B. Perhaps using actual switches would help people like be to "see" it. If there were swithes there... would any of them be momentary contact?
I was trying to make a point about how the 555 operates with this schematic. Point B may be a valid input (but not in your case), but it has drawbacks and problems. By showing it in the experiment I'd hoped to teach this point about the 555.

Truth, in doing these experiments (and explaining them) I've learned a lot myself. Like the old maxim says, you want to learn, teach.

Point A is the conventional configuration of a 555 monostable.

The thing to remember about these experiments is I follow the KISS principle (Keep It Simple Stupid). A switch or a button can be a simple piece of wire for demonstration principles.

One last suggestion, put a diode across that relay coil. When they turn off they generate a high voltage spike that can damage the device feeding them. Use something like this...



This schematic is for illustration only, it is a power up delay. It does show how the diode is used however.
 

Audioguru

Joined Dec 20, 2007
11,248
The relay coil is an inductor that generates a high voltage spike when it is turned off. the high voltage spike upsets or destroys a 555.
Datasheets or applications notes for the 555 show two diodes (one in series with the output and another parallel to the coil) to arrest the voltage spike.
 

Thread Starter

OneEarWillie

Joined Oct 23, 2010
6
Yeah... I think I should add that also. I guess, when I get done... I should post an updated schematic? So readers can see what was changed.
 

Thread Starter

OneEarWillie

Joined Oct 23, 2010
6
During this process, my learning curve has been quite steep. I'm confident that there is a probably something I overlooked in the early stages of designing this circuit. I don't doubt that there is a better or easier way to accomplish dual-edge triggering. Since I'm going back to the bread-board... I'm curious to try some different methods. If anyone can improve my circuit, but obtain the same end result using the same input... I'd like to know. I'd like to test your ideas also.
 

Wendy

Joined Mar 24, 2008
23,421
No problem, you'll find this site is full of folks that like to help. I tend to go for the 555, others for other items, with a lot of cross talk in between. If you plan on learning electronics you'll like it here. I did.
 

SgtWookie

Joined Jul 17, 2007
22,230
I do not see a capacitor across the Vcc/GND pins of the 555 timer.
This can cause erratic operation.

Use a 0.1uF metal poly film or ceramic cap directly across the 555 pins 1 and 8, and use a 1uF or larger aluminum electrolytic across your +5/GND somewhere in the vicinity of the 555.
 

Thread Starter

OneEarWillie

Joined Oct 23, 2010
6
Sorry so long for the update. I had to take a short "tinkering" break (working on a few side projects - 3 kids).

I finally made the changes that y'all suggested. And I'm proud to report that my circuit is working perfectly now.

For the record... it was the relay-coil-inductive-kick-bypass-diode that actually solved the problem. I think, what was happening is that the relay coil was storing a magnetic field. After heavy usage it would no longer stay latched because the coil had no way to collapse it's field, so it was saturated, and had no room for more field... thus no room for new current flow (I think this is the right theory?). If I let is sit for a while it would dissipate a enough to latch once or twice before it became saturated again. I installed the bypass diode... now there is a path for the coil's field to collapse through, after each use. It now works without any issues.
 

Wendy

Joined Mar 24, 2008
23,421
Glad to hear it is working.

Coils don't care, if they have voltage (and current) then they will energize. The current will be there if the voltage is, it is a given. The only thing the diode does is prevent the coil from blowing the rest of the circuit when they de-energize.
 
Top