0

At our kids school there was one day when parent go to school and tells kids about their profession. I am working as programmer, so I got to school and tell kids who is doing programmer. Of course in 5th class is not funny to open IDE and write some words, so I took raspberry pi with motion sensors, camera, temperature sensors, ultrasonic and hall effect sensor. So, that kids can touch temperature sensor and picture kids when they moves around motion sensor. It was nice experience. I also made simple led with capacitor, to demonstrate what is capacitor. Capacitor with leds

schematic

simulate this circuit – Schematic created using CircuitLab

But when I applied power to it, Led1 light up bright, but led2 was very dark. See on second picture (Power ON). After I switched power off, led2 now lights bright and led1 is off as expected.

Question: Why booth leds not at same brightness when power is on and what components is missing in schematics so that booth leds will light when power is on and led2 only when power is switched off?

Parts: Capacitor is 6.3v 3300uf, resistor is 670 ohm, diode is 1N5817, 5.9 volts applied. enter image description here

Guntis
  • 207
  • 1
  • 6
  • 14
  • I will add another resistor – Guntis Nov 04 '16 at 17:55
  • It's probably too late to add another resistor since LED2 has nothing to limit the current. It's probably time for a new LED. – owg60 Nov 04 '16 at 17:59
  • 2
    The circuit in the schematic is NOT your actual circuit. Otherwise you would have destroyed LED2. Both LEDs go to the resistor. You've also mixed up the numbers in the description and the voltage is different. Details like this really do matter. – Spehro Pefhany Nov 04 '16 at 17:59
  • @SpehroPefhany led light diode part numbers not as in schemantic. – Guntis Nov 04 '16 at 18:21
  • @Guntis Not so important, we can see they're green LEDs which is enough to get an idea. – Spehro Pefhany Nov 04 '16 at 18:26

3 Answers3

4

I'll address only the title question of why the LEDs do not light equally given the following circuit. I have duplicated your actual circuit below.

schematic

simulate this circuit – Schematic created using CircuitLab

When V2 is high, C1 charges through D3 and the current through D3 due to the capacitor rapidly drops to near zero. D1 is then essentially in parallel with D2+D3. Since D3 provides some voltage drop D2 will be much dimmer than D1. the only way it would be of similar brightness would be if D3 was ideal (0V drop) and it is not (though it's a Schottky so it drops very little- if you replace D3 with a regular diode such as a 1N4004 you will find the brightness difference even greater).

When V2 goes to zero, the voltage at R1 drops and D3 and D1 are reverse-biased, so current flows only through D2 and R1 in series.

You should be able to run the simulation with my shown circuit and see how it behaves as you change parts. If you split the resistor R1 into two, as you've found, it will be much closer in brightness, though one will still see a bit more current than the other. You can even make one resistor a bit lower than the other to equalize the currents at a given input voltage etc.

Spehro Pefhany
  • 376,485
  • 21
  • 320
  • 842
  • Are you sure? According to your picture, I would say if you disconnect power source, only D3 is reverse biased, D1 is disconnected, and current flows through D2 and R1 in series. Maybe the problem is that your first and second paragraph use switched D1/D2 names. – Al Kepp Nov 04 '16 at 21:58
  • @AlKepp Yes, exactly right, thanks- fixed. It's a bit inconvenient that you can't see the schematic when you are editing the text. – Spehro Pefhany Nov 04 '16 at 22:06
1

I made some changes in schema and now it works. Based on this Why exactly can't a single resistor be used for many parallel LEDs? I separated common ground & resistor. Added another resistor and now booth leds are at same brightness when power is on. New schemantics:

schematic

simulate this circuit – Schematic created using CircuitLab

Guntis
  • 207
  • 1
  • 6
  • 14
0

When a capacitor charges up (for the sake of this argument lets assume) it will gain infinite resistance which means no more current can go through it.You have your first LED connected directly to power supply so it lights up.your second LED is in series with the capacitor so it lights up for a fraction of a second before the capacitor is charged and then it draws all the voltage for itself,making the LED to be almost off(if it actually had infinite resistance it would totally shut down the LED). When you disconnect the battery the first LED goes off because it has no power supplied to it but your capacitor discharges over time making the second LED to light up and the LED goes off when the capacitor is discharged below about 1.5(about 1.8 in your case) volts.

I'm not gonna go into detailed maths but the time taken for the capacitor to charge up/discharge is proportional to the resistor which is connected in series with it(in your case its 470 ohms). The higher the resistance,the longer it takes for the cap to charge/discharge and if you completely remove it it will charge/discharge instantly which makes the LED flash brightly for a very short period of time.

I hope this answers your question.

You also CAN USE 1 RESISTOR TO LIGHT UP MORE THAN 1 LED AT A TIME but you should put it in series with the LEDS in parallel.Here is what I mean:

schematic

simulate this circuit – Schematic created using CircuitLab

OM222O
  • 282
  • 2
  • 11