Parallel Diode in RC charging circuit
The diode is there so that when the supply switches off it discharges the capacitor C1 via the collapsing supply rail at the top of R3.


  Which loop capacitor discharges when button is pushed ?


C1 is discharged by the switch and ideally (to prevent large current spikes potentially upsetting the MCU) there should be a 100 ohm resistor in series with the switch.