I have some troubles to understand the above circuit :


simulate this circuit – Schematic created using CircuitLab

The goal is to discharge the capacitor which was previously charged to 20V the most rapidly. (At least I think). The collector emitter voltage drop of the phototransitor and the forward diode voltage have to share the voltage of the discharging capacitor. At the beginning of the discharge, ie when the voltage of the capacitor is equal to 20V, the diode forward voltage is equal to Vf (lower than 1V), so VCE has to be equal to at least 19V ! So if VCE is high, the collector current Ic of the phototransitor is limited by the gain of the phototransitor and the forward current of the emitter diode $$If*CTR = Ic$$ where CTR is the current transfer ratio. So for discharging the most rapidly the capacitor, we have to have a high collector current, ie a high forward current flowing through the emmitter diode. What do you think ? Wouldn't be better if a resistor would be added in series with the phototransitor ? It will allow to saturate the photransitor without necessary diminishing the collector current if the forward current is high.

By the way I did not get why there is a shunt resistor R2. It will reduce If. Nevertheless it could help to reduce noise problem. (leakage current will not be a problem, isn't it ?) Wouldn't be better if the shunt resistor would be placed as a pull down resistor. Same thing for the capacitor next to the shunt resistor? This capacitor will slow down the discharge of the capacitor charged to 20V. What do you think ?

Thank you very much and have a nice day :)

  • \$\begingroup\$ Why there needs to be an optocoupler to begin with? You could discharge the capacitor with a BJT or FET, that is controlled directly with the MCU. You also need to limit current, but big FETs can take tens of amps. How fast it needs to discharge, and what is the capacitance? It determines how long the current will flow and how slowly the voltage discharges. \$\endgroup\$
    – Justme
    Apr 29, 2020 at 14:24
  • \$\begingroup\$ You re right. I will edit the post ! \$\endgroup\$
    – Jess
    Apr 29, 2020 at 14:34

1 Answer 1


This depends largely on what size capacitor you're discharging and how long you have to discharge it, as well as the residual voltage you can tolerate. If it's a 100pF cap you're discharging, I'd say you can do it with the schematic above; there will be a high peak current, but not long enough to significantly heat the driver. If it's a 100uF cap, you'll probably want to include additional drive or add a series resistor (which will slow the discharge rate). "The most rapidly" isn't a workable spec unless you're doing high energy EMP research, which is far more expensive than this; you need a number to work to.

  • \$\begingroup\$ Thank you for your explanation ! \$\endgroup\$
    – Jess
    May 1, 2020 at 15:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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