Thoughts on circuit safety:
The high voltage capacitor has the potential to fail, as it’s under the most stress. It can fail open, which will stop the high voltage, or it can fail as a dead short, which could potentially cause a lot of damage to the inductor as well as the source of VCC (the Raspberry Pi) and, by extension, perhaps even the batteries.
One way to prevent catastrophic damage would be to put a fuse (say 500 mA) in series with the output of the 3.3V regulator. That would limit the total current that could be demanded by the circuit in the event of a short circuit.
In addition, the Raspberry Pi could potentially monitor the voltage just past the fuse. 3.3V = all systems okay. 0V = fuse blown. (I never had time to implement this feature.)
Thoughts on circuit stability:
Using an NPO capacitor for the high voltage capacitor would probably result in the least drift of high voltage over a range of temperatures.
A fuse (represented here with a giant fuse holder) has now been placed from the Raspberry Pi’s 5V output to the input of the voltage regulator. The value is yet undetermined.
A 1MΩ resistor to ground has been placed at the entry point of the 3V gate signal to the MOSFET. It may not be needed, but it can prevent capacitive coupling from driving the MOSFET when it is not connected (for example: if the 3V pin on the Pi goes open).
The 220Ω resistor in series is the gate resistor, and its purpose is to dampen any ringing when the gate signal goes high.
Comments