When the main battery is detached, the device goes to sleep mode. During the main battery replacement, the backup battery is activated to keep the system alive.
However, if the back-up battery is empty or dead, the PDA does not have a backup power to keep it alive, result in restart of the PDA when the main battery is replaced.