i am controlling high voltage loads through relay from my controller, some times in high voltage switching micro controller(ATMEGA32) get hangout..i enabled my watch dog timer to solve this.i tested the watch dog timer using while(1) loop in program, and its working..but in high voltage switching still controller get hangout, watch dog is not resetting.why this is happening..
may be reverse voltage coming to controller .
Put a Diode in input to make unidirectional current flow and opto coupler is must when you go on with high voltage.
Creating voltage spikes in MCu core is injurious. ANd nothing can be said of its consequences. Watchdog timer will help only when you are stuck in endless look. It cannot help when u corrupt its core by undervoltage or voltage spikes.