3
\$\begingroup\$

I have a simple circuit, powering an ESP8266, specifically the esp-12-e.

Connected to the 3.3v coming in I have a 1000uF electrolytic capacitor, to help keep things stable (suggested by the esp8266 community)

It's all working well. However when I cut the power to the board, I see my LEDs etc hang around dimly glowing for just less than a second before the board appears to loose all current. I assume this is because of the giant capacitor. I like it :), and have it behaving otherwise very stably.

I hear people talk about bleeder/discharge resistors, normally on DC power supplies. However, if my theory is right, one may help me here, so when I cut the power, everything turns off...more or less instantly.

Thoughts? If my theory is correct, how would I wire the resistor up, how many ohms should it be, and why?

\$\endgroup\$
1
  • 3
    \$\begingroup\$ your ESP module is the bleeder resistor. Additionally, nobody is going to get electrocuted from a 3.3v 1000uf discharge, so there's no need to generate waste heat and lower cap perf. If used, the bleeder is installed parallel to the cap, "shorting" VCC and GND. \$\endgroup\$
    – dandavis
    Commented Jan 30, 2018 at 5:47

1 Answer 1

2
\$\begingroup\$

To start with, you could reduce the decoupling capacitor size. It does seem to be an enormous capacitor for the job it's doing, so you could reduce its value. The size required depends on the decoupling capacitance you already have in your power supply and the length and current capacity of those connections to the power supply. The shorter and thicker the connections (lower resistance, inductance), the better. I previously worked with on of four rigs containing a ESP8266 board which worked reliably with a 100 uF capacitor close to the board supply pins. So it all depends upon your total circuit.

If you have the parts available, you can try 470 uF or 220 uF and see if you notice any difference over time when its operating. If you have access to an oscilloscope, measure the ripple, noise and supply dips across the 1000 uF capacitor and then measure it with the 470 uF in place and again with the 220 uF. If ripple, noise and the supply are not significantly larger with the 470 uF or 220 uF, use that smaller capacitor.

Once you've settled on the capacitor you want to use, you could add a discharge resistor to do what you want.

A discharge resistor would be connected across the supply rail, and therefore the supply decoupling capacitance. Its value is a trade-off between operating power wastage and speed of discharge. When the supply is operating, the resistor will be drawing a continual current and dissipating power as heat. The lower the resistor value, the more power from the supply is wasted as heat in the resistor and the higher its power rating has to be but the faster the capacitor has to be.

The resistor current is found from: I = V/R = 3.3/R Amps

The resistor power is found from: P = V*V/R = 10/R Watts

The 1000 uF capacitor discharge time because of the resistor across it can be taken roughly from: td = 5RC = 0.005 x R secs

For example, a 100 ohm resistor would draw 33 mA, dissipate 0.1 W continually and discharge your 1000 uF capacitor in 0.5 secs. That seems a reasonable trade-off but it depends on your power supply's rating as to how much you want to waste in the resistor. Derate the resistor to 50% so it is not under stress. So for the 100 ohm resistor, use a 200 mW or 500 mW part.

\$\endgroup\$
4
  • \$\begingroup\$ The capacitor (i think) is in parallel to the esp8266 ground and vcc. How would I wire up the resistor? \$\endgroup\$ Commented Jan 29, 2018 at 23:44
  • \$\begingroup\$ The ESP8266 is RF module. You can't reduce the cap size. Usually these RF modules operate in short burst, sucking all power from rails during transmission pulse. I recall some calculations on EE to have tens of thousand of uF to hold the power rail during bursts. electronics.stackexchange.com/a/320283/117785 \$\endgroup\$ Commented Jan 30, 2018 at 4:21
  • \$\begingroup\$ since the spikes last mere ns, a 470 will cut down the spikes, a 1k will eliminate them. \$\endgroup\$
    – dandavis
    Commented Jan 30, 2018 at 5:46
  • \$\begingroup\$ @AliChen, those links only discuss GSM modules at length. But additional decoupling needed depends on existing wiring and decoupling, doesn't it. Thanks for comment, have added detail. \$\endgroup\$
    – TonyM
    Commented Jan 30, 2018 at 7:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.