Discharging capacitor through transistor - Page 1
Forum section: electronics / beginners

author: rahulb
author_rank: Contributor
timestamp: April 08, 2025, 03:34:43 pm
content: hi Everyone,Can anyone help me with an RC circuit in which capacitor discharges only when transistor is on.The base of transistor is connected to a switch using which transistor can be set on or off.I want to use NPN transistors like BC547.please help me.Thanks

author: UnijunctionTransistor
author_rank: Frequent Contributor
timestamp: April 08, 2025, 03:56:26 pm
content: First question; what is the capacitance value and the voltage to which it will be charged?Discharging capacitors with transistors is very common, and as long as the capacitor’s energy doesn’t exceed the transistor’s safe operating area you’ll be fine.

author: TimFox
author_rank: Super Contributor
timestamp: April 08, 2025, 04:11:19 pm
content: You need a base resistor between the switched input voltage and the base to limit the base current when the transistor is switched ON.Real transistors have a roughly constant ratio between collector current and base current called "beta", but there is a wide spread of beta values between individual transistors manufactured with the same part number.For design, you can compute the actual base current from the input voltage, base-emitter voltage = 0.7 V, and the base resistor.If you then apply the manufacturer'sminimumspecified beta, you obtain an estimate of theminimumcollector current.That current will discharge the capacitor; the collector current and collector-emitter voltage must be within the SOA discussed by Unijunction Transistor above.The time required to discharge the capacitor will be the total charge (Q = CV) originally in the capacitor divided by the collector current.

author: rahulb
author_rank: Contributor
timestamp: April 08, 2025, 04:46:16 pm
content: hi,capacitance value 470uf and voltage 12vthanks

author: TimFox
author_rank: Super Contributor
timestamp: April 08, 2025, 04:47:10 pm
content: What collector current do you estimate?

author: rahulb
author_rank: Contributor
timestamp: April 08, 2025, 05:29:38 pm
content: 100 ma will be enough

author: TimFox
author_rank: Super Contributor
timestamp: April 08, 2025, 05:47:47 pm
content: So, if beta > 50 and the input voltage is 5.0 V, for a base current = (100 mA)/50 = 2 mA, you need a base resistor ofRb= (5 - 0.7) V / (2 mA) = 2 k\$\Omega\$, and the total time to discharge 470 uF from 12 V will beT= (12 V) x (470 uF) / (100 mA) = 56.4 ms. Is that fast enough?

author: rahulb
author_rank: Contributor
timestamp: April 08, 2025, 05:59:03 pm
content: hi,I need more time like 2 or 3 seconds.Is the value of the base resistor responsible for total discharge time?

author: TimFox
author_rank: Super Contributor
timestamp: April 08, 2025, 06:09:57 pm
content: The base resistor is only one of the parameters that determines the collector current, which determines the discharge time in the simple circuit.If you want to discharge more slowly, then you should add a resistor between the collector and capacitor: the transistor will switch ON (saturated) and the capacitor will discharge through the resistor with a time constantRC.Do you need an accurate timing?

author: SteveThackery
author_rank: Super Contributor
timestamp: April 08, 2025, 06:50:32 pm
content: What is the context? Is it part of a bigger circuit or system?

author: Picuino
author_rank: Super Contributor
timestamp: April 08, 2025, 06:53:41 pm
content: You can edit this circuit changing values as you want.https://www.falstad.com/circuit/circuitjs.html?ctz=CQAgjCAMB0l2BOJyWoBzgMywQdgCxgCsmATGJGmGgGwT40hEj6ZMCmAtGGAFAAuUcGFIsMPUZHBRoRRLUhI0uaogYyaRPJsg9cpUjVy5mpOCAAm7AGYBDAK4AbfrwDG4GlLIepYTyxk4SHxcGTBMJGDdTDh8fDQ2GHgoXgA3EG5ScX9MjE5vKSl8X0khGCJeAHcxcCyav0Kq+v8GnxTq+LbctsheACchCSEC8CC4XgBnDJp8EBGRqTtHCfYmzhm50XXZ-Mk1kTzvbYyC-rbvVt3BoLWNq8vTjowERk7Hmov-b0xeAHtpDZSAAeWQo4TCRBopGYSSC2kh0MG4GYEE4CAgADVXLwgA

author: rahulb
author_rank: Contributor
timestamp: April 09, 2025, 05:20:23 pm
content: thanks everyone.I made a circuit on the breadboard and it is working.I am using circuit given below:But, the problem is that the capacitor is discharging too fast. I used a calculator available on net to calculate the discharge time. they are giving about 5 seconds but the capacitor is discharging in milliseconds. I don't know why.I am using a darlington transistor TIP122 as it is available for testing. Is the transistor responsible for too fast discharging?thanks

author: Grandchuck
author_rank: Super Contributor
timestamp: April 09, 2025, 05:52:32 pm
content: try a resistor in the collector leadi.e. a 10k ohm resistorin the collector leadwould give an RC time constant of 4.7 s

author: Picuino
author_rank: Super Contributor
timestamp: April 09, 2025, 06:50:54 pm
content: I think if you want a transistor-based timer, this circuit may be more useful to you:https://www.falstad.com/circuit/circuitjs.html?ctz=CQAgjCAMB0kWBmWBOA7AFjAVgQJjJABxiEBsE6pIWI6C1ApgLRhgBQAxiE3iKeiF79aUWJEjpU4MNASZSuBKmypCZCaPERIbAG7cwuQuFKQDR7rzNn0Zw1AcwsbAO6Xc4Czw9hTUV+4mdqhUvtYB3kHmxmH+bixevJGROgBOgh7CSVbg4nkR2R6FcYHIVJHCOgAuJtIekawedgZY0Mj4WJ0hEnDIhPQ8bR1daliEWCFouWYAJgwAZgCGAK4ANlVs6RUCyTkE4pt1fAKNgXZ5B25gISBl4DeVAacNNymH11TCH2fTOlc3hhiAL8Oi4py+DwEAhgeUk3HQ0FQCGQYEkEywyEgmOQ0LE2jYNUBR2+p2aTBg2Ha2BwhmQE0Q9BgpDGSgUWFMuBCBGQ0xAcyWaw2bmKzysTwspyE0Ke9i+oXsOgAHtxFCBCPVEGqaCdjAAdAAObGVKjVPlIUnGIhIIANbAA9g5KiBFUYCJqKezcDQYXk0My2Q54DQIEwUSAAGocNhAA

author: TimFox
author_rank: Super Contributor
timestamp: April 09, 2025, 09:09:51 pm
content: Quote from: rahulb on April 09, 2025, 05:20:23 pmIn that position, R2 will control thechargingof the capacitor, but the discharge through the transistor is controlled by the collector current as in my previous post.

author: watchmaker
author_rank: Unknown
timestamp: April 09, 2025, 11:26:31 pm
content: I am added your site to my STEM resources. Thanks!

author: Zero999
author_rank: Super Contributor
timestamp: April 10, 2025, 10:37:41 am
content: Quote from: Picuino on April 09, 2025, 06:50:54 pmThat's an astable.I think the original poster needs a monostable.

author: SteveThackery
author_rank: Super Contributor
timestamp: April 10, 2025, 12:01:05 pm
content: Quote from: rahulb on April 09, 2025, 05:20:23 pmLook at your schematic. Can you see that the transistor is connected straight across the capacitor? The transistor acts like a switch: when it is "closed" it puts a direct short circuit across the capacitor. The charge in the capacitor flows out of the positive end, through the transistor and then to the negative end of the capacitor. There is nothing to limit the current so the capacitor will discharge almost instantly.To make it work you need a resistor in the discharge circuit to limit the current. That will lengthen the time it takes to discharge the capacitor. The easiest approach is to put a resistor (start with 10k) in series with the transistor collector, such that the current from the capacitor goes through the resistor first, then the transistor.

author: SteveThackery
author_rank: Super Contributor
timestamp: April 10, 2025, 12:04:07 pm
content: I hope this makes it clearer.

author: CaptDon
author_rank: Super Contributor
timestamp: April 10, 2025, 12:35:22 pm
content: Relying purely on the beta to predict circuit behaviour is a bad design. Far better to push the transistor to a predicted saturation current and use resistance in the collector path to control the discharge time. Beta varies widely across the same part number even from the same batch. This means with 5 transistors of the same part number, and using representative beta values from one sample your discharge times could vary by a factor of 2X or 3X and may also show a change of 20% across a temperature spread. Is this a school or college project??? This is beginner basic stuff you should get from any textbook covering transistor theory.

author: rahulb
author_rank: Contributor
timestamp: April 15, 2025, 02:00:14 pm
content: Quote from: SteveThackery on April 10, 2025, 12:04:07 pmhi,thanks for the info.I will try the circuit with this new resistor .thanks