I'm new to this Forum but not to Electronic community!
I designed a PCB based on an ATmega128 and it was working fine until recently where I had unwanted resets!
First I thought it's a problem with my code but then I checked the connections and measured ohmic resistance and it turned out there is an unwanted resistance from RESET pin to ground! something around 9kΩ and it makes a voltage divider circuit with the 10k pull-up resistor!! the voltage on the reset pin flows around 3 V and it causes unwanted reset!
here is the schematic
the reset pin is also connected to IDC connector for programmer as well as a connector to interface.