How to discharge a capacitor