$ 0 0 Make sure your brown out detector is set to at least 2.7 V, better 4.3 V. Without BOD, ATmegas tend to corrupt their brain at power loss.