I am using a Light Dependent Resistor (LDR) and a laser to make an burglar alarm system.

My laser continuously projects beam on LDR and when the beam is interrupted the LDR starts to ring the electric bell.

Now I want the bell to ring as soon as laser is interrupted but to stop after some time. I know its possible but how can I do it? Shall I use IC 55 timer to add a delay, if so how?

• Since you did not specify the "stop after some time" parameter, do not expect an accurate answer. Commented Dec 9, 2014 at 13:07
• Related: Transistor Delay
– user17592
Commented Dec 9, 2014 at 14:41

You can also use a simple RC charging circuit (where R is tunable) outputting on a comparator. This will provide you with a delayed digital signal, and you can use regular logic gates to command your alarm (be sure the end gate/driver is capable of driving your alarm), e.g.:

simulate this circuit – Schematic created using CircuitLab

The duration can be adjusted in many ways, the easiest would be to change R1 and/or R3. The schematic shows an example with approximately 3.8s of delay, from: $$1-e^{-\frac{t}{R1\times C}}=\frac{R3}{R2+R3}$$ You can also chain those delay blocks to get higher delays, if the components values skyrocket.

By the way, this is a simplified schematic that's not immune to noise. If you want to avoid the alarm glitching because of noise you'll have to add some hysteresis (c.f. Schmitt trigger). That's not complicated, only a couple of resistors in addition.

Edit: I'm assuming you already have a comparator/buffer following the LDR.

• The solution with the logic gates will require an insane amount of inverters to give a noticeable delay, unless you put RC elements in between. Commented Dec 9, 2014 at 13:05
• My answer is not about using inverters to accumulate delay, this is only for illustration. Please read my answer above. I have formatted in bold that I would replace those inverters by an RC+comparator. Commented Dec 9, 2014 at 13:08
• @MisterMystère by the way I get what you mean now, but perhaps you could use a different figure since it doesn't match your text (I know it's an example, but not really appropriate). Perhaps you can draw a schematic with the integrated editor. Commented Dec 9, 2014 at 14:11
• OK much better! Yeah I guess the figure is what was bothering me. (There's no reason you couldn't use RC and schmitt trigger inverters either, as opposed to the comparator. (removing down vote.) Commented Dec 9, 2014 at 14:37
• Do you really need a comparator? This answer here (for a slightly different purpose, but with the same idea) uses a transistor.
– user17592
Commented Dec 9, 2014 at 14:40

The simplest way is probably to use a monostable multivibrator, using a 555. You can use a potentiometer to keep some flexibility on the duration of the alarm.

But an alternative that some may suggest is to use a simple microcontroller, that allows you to reconfigure it whenever you want.