# Capacitor not charging?

I am yet another software developer trying to step into the world of electronics... (so sorry for the basic questions...)

I am trying to understand how a capacitor works, but obviously I am missing a crucial part from all the helpful websites like sparkfun and adafruit.

I failed to solve an issue I currently have in a pretty basic project that reads a temperature from a thermocouple and displays the value on an LCD. An electrical engineer at work pointed me in the direction of adding a capacitor to filter the noise I introduce when I touch the thermocouple. Long story short; the capacitor doesn't seem to charge, no matter how I add the capacitor to the circuit, almost no voltage comes out; ever.

So I thought to be smart, and make a new circuit of:

• a battery supply (9.6V)
• an LED
• a capacitor "104"

The circuit is simple, all components are in series, so I expected that my LED would light up, and when I disconnect the battery, the LED would fade out. But again... nothing happens. The LED never lights up, and my multi meter measures 0.8V after the capacitor. But also, when I hold the multimeter probes to the leg of the capacitor, the measured voltage drops from 0.8V to close to zero in no time.

Please forgive me if this drawing is wrong (and please do tell me what is wrong so that I can learn from it): • Why doesn't the capacitor charge up to the voltage of 9V (but seem to stop charging at 0.8V?)?
• Why does it discharge when I measure the voltage with a multi meter?

PS: there is no resistor between in the circuit limiting the current, and the batteries are 8x 1.2V rechargeables = 9.6V

• You must put a resistor in series. You might have damaged the LED due to this circuit. Use a 1 K resistor and a fresh LED. – Whiskeyjack Jul 2 '18 at 19:49
• Are you looking to understand how to approach designing a circuit that would gradually increase the LED current (LED current is associated with brightness, though the human eye has a logarithmic response) when the power is applied and would gradually decrease the LED current when the power is removed? Or just why your circuit isn't a well-managed one and why it doesn't work the way you think it should? – jonk Jul 2 '18 at 19:59
• A larger comment, although the question (as posed) has been answered. A thermocouple will not produce enough voltage to light an LED. If you connect a whole lot of thermocouples in series, unless you have a relatively high-power temperature differential, you won't get enough current, either. You should look in to learning about op amps to amplify the thermocouple output. – WhatRoughBeast Jul 2 '18 at 23:38

Your circuit should look like this: simulate this circuit – Schematic created using CircuitLab

Also, if the value of your capacitor is small, when you disconnect the power source, the led might go out very quickly. Are you sure your capacitor is 104F?

edit: as G36 points out, you probably meant it was marked 104, which means 100nF (except for with aluminium capacitors). To see any afterglow, you'll probably need at least 1000uF

• But 104 capacitor is 100nF. So, it will be hard to see anything. – G36 Jul 2 '18 at 19:56
• aha, well it states "104". I didn't realize it meant 100nf. Thanks for that too – bas Jul 2 '18 at 20:01
• @bas 104 = 100000pF = 100nF electronics.stackexchange.com/questions/338838/… – G36 Jul 2 '18 at 20:03
• Thanks for helping me out. I have both the LED working as my original project. Learned something today. Thanks again – bas Jul 2 '18 at 20:18

First of all you have to know the working voltage of your LED, if the LED requires a 5V input, applying 9.6V will damage your LED and you will get a no response result. So you have to add a resistor in series to drop the extra 4.6 Volts from the circuit.

Since your battery rated at 9.6V and assuming you have a LED that works on 5V as input and consumes 20mA of current, the required series resistance value can be calculated using kirchhoff's voltage law, which states that "for a closed loop series path the algebraic sum of all the voltages around any closed loop in a circuit is equal to zero" this means Vs ( Battery ) = V ( LED ) + V ( Resistor )

where V ( Resistor ) = I ( current ) x R ( resistor value )

By Substitution 4.6v = 20mA x R , so R = 230 Ohms. So you need a resistor of at least 230 Ohms. So the next higher popular standard resistor is 330 ohms.

Its not necessary to connect a capacitor to this circuit, the main purpose of a capacitor is to smooth the voltage generated from the power source and to eliminate voltage ripples. But if you intend to add a capacitor it should be connected in parallel with the LED. Because all the loads are designed to function optimally when connected to rated supply voltage. When capacitor is connected in parallel, full supply voltage is available to the load. However when it is connected in series, it drops the supply voltage, resulting in altered performance of the load.

• An LED does not work optimally when connected to the rated voltage, it should be driven with the rated current. When a capacitor is connected in series in a dc circuit it doesn't "drop the voltage", it blocks the current entirely so the load gets no current. I'm not aware of any bare LED with a forward voltage close to 5V, and the purpose of the resistor is not to drop the voltage but to limit the current. – Elliot Alderson Jul 2 '18 at 21:26
• So how could you calculate the resistor required value? – Ahmed M.Zahran Jul 2 '18 at 21:28
• Your method is correct but your description of why is misleading. It's important that beginners don't try to connect an LED to a constant voltage supply (unless the "LED" is really an LED with a built-in series resistor). – Elliot Alderson Jul 2 '18 at 22:00
• Can't the LED be really an LED?! It might be confusing to me why begginers shouldn't try to connect a LED to a constant voltage supply such as a battery? – Ahmed M.Zahran Jul 2 '18 at 22:14
• The current through a forward-biased diode is exponentially related to the forward voltage, so small changes in voltage can cause very large changes in current, which either damage the LED or leave it dark. To properly use an LED you must design a circuit that controls the current, although you can recognize that the datasheet provides a typical value for the forward voltage. – Elliot Alderson Jul 2 '18 at 22:18