Push button flashing light circuit

Thread Starter

christiannielsen

Joined Jun 30, 2019
380
Hi,

This project is for hobby use only = just for the fun.

I made this circuit which make the LED (D3) flash 9 times when pushing the push button (SW1). Afterwards D3 is illuminated constantly until next time the button is pushed. It seems to be working just fine.

My questions is:

1. The circuit draws 0,12 watt according to my power supply. I have no idea if this is too much. If so, what can I do to optimize?
2. I haven't put too much thoughts into the LED driver (U1). I merely put in resistors and caps until the D3 illuminated. According to my cheap multimeter the duty cycle is 50% and the frequency is around 160hz. Is there a proper way to illuminate a LED?

From Christian
 

Attachments

dl324

Joined Mar 30, 2015
16,654
Cropped schematic without the gaudy colors and whitespace trimmed:
croppedLedCkt.jpg
Is there a proper way to illuminate a LED?
Normally we use PNP transistors when driving high side.
I haven't put too much thoughts into the LED driver (U1). I merely put in resistors and caps until the D3 illuminated. According to my cheap multimeter the duty cycle is 50% and the frequency is around 160hz.
You don't need 3 IC's to flash the LED at 160Hz with a 50% duty cycle. That can be done with a single 555 timer.

This gives about 150Hz at about 50% duty cycle:
1698511970247.png

Here's a nomograph from National Semiconductor to simplify determining component values for astable timers:
1698512387426.png
 
Last edited:

sghioto

Joined Dec 31, 2017
5,368
I made this circuit which make the LED (D3) flash 9 times when pushing the push button (SW1). Afterwards D3 is illuminated constantly until next time the button is pushed. It seems to be working just fine.
It does work but seems to be over complicated.
Here's a version using 2, 555 chips.
U1 is a timer activated by SW1 which enables U2 to pulse the LED 9 times before timing out. R1 may need to be adjusted slightly depending on component tolerances to complete the 9 pulses.
On the bench it worked fine with the values listed with the same pulse rate as your circuit.
1698522956861.png
 

AnalogKid

Joined Aug 1, 2013
10,943
In the post #1 / #3 schematic -

There needs to be a pull-down resistor from the cathode of D2 to GND. Otherwise, the OR gate and CLK inputs are floating when U2 pin3 is high.

BUT - why is D2 in there?

ak
 

Thread Starter

christiannielsen

Joined Jun 30, 2019
380
Normally we use PNP transistors when driving high side.
I appreciate your feedback, thank you. I am not sure I know what "driving high" means in this case. Is it on which side of the transistor the LED is positioned?

Do you mean I should replace the OR gate with a NOR gate and the NPN with a PNP?
If so, I would love to learn why that is an advantage. If it is not too much trouble.
 
Last edited:

Thread Starter

christiannielsen

Joined Jun 30, 2019
380
In the post #1 / #3 schematic -

There needs to be a pull-down resistor from the cathode of D2 to GND. Otherwise, the OR gate and CLK inputs are floating when U2 pin3 is high.

BUT - why is D2 in there?

ak
Check! thanks! Oh, the D2 is a left over from another take. Thanks for pointing it out.
 

Thread Starter

christiannielsen

Joined Jun 30, 2019
380
In your original circuit, the capacitors on the 555 oscillators are connected to the wrong place and D2 should be replaced by a piece of wire.
You are right! Thank you. Luckily I remembered the right connection on the breadboard. I will replace the D2 with a wire also. The D2 was a left over from an earlier try.
 

dl324

Joined Mar 30, 2015
16,654
I am not sure I know what "driving high" means in this case. Is it on which side of the transistor the LED is positioned?
High or low side driving means which side of the "load" you're driving:
1698592773422.png
When you drive this way, the voltage drop of the load doesn't affect base current in the transistor (being used as a switch).

In both of these cases, I assumed that the voltage driving the bases was 12V. These transistors specify that base current be 10% of the collector current for saturation mode. Assuming a 2V forward voltage for the LEDs, 1k would establish a current of 10mA in either LED. Allowing for a 0.7V drop for the base-emitter junctions, base current in both cases would be just over 1mA.
1698593026869.png
1698593087076.png
Other transistors have different ratios for saturation mode. BC547 specify a ratio of 20, Darlington transistors are around 250.
1698593113802.png
1698593134208.png
1698593153168.png
 

Thread Starter

christiannielsen

Joined Jun 30, 2019
380
High or low side driving means which side of the "load" you're driving:
....
I have never understood on which side of a transistor or a mosfet the load should be. I just put them in and switched them over if it didn't work because I haven't found the right video explainer for me I guess. All I know about circuits is pretty much what I picked up from YT-videos.
 

Thread Starter

christiannielsen

Joined Jun 30, 2019
380
I have updated the circuit.

I have put in RV1 to be able to dim the LED.
I have put in pull-down resistor R3 at U3-2 (why shouldn't U3-1 have the same?)
I have put in 104 caps for decoupling at every IC although it is not in the diagram.

After these changes the circuit is having issues with counting correctly. It's pretty random what it counts to. Can anyone see what the problem is?

I am also not sure still if I am driving the LED well enough concerning the high/low side issue. I have a 1m resistor to the base of Q1 and this limited the current draw for the circuit by a lot.

Thank you for all inputs!
 

Attachments

AnalogKid

Joined Aug 1, 2013
10,943
Schematic #19 - U3A can be replaced by two small signal diodes (1N914, 1N4148, etc.), eliminating an entire IC.

Also, in all of the schematics posted so far, both chips need power supply decoupling - especially the bipolar 555/556. It is notorious for putting spikes and brownouts on its supply net, large enough to cause problems with itself and the counter.

ak
 
Top