Change mode with button not working properly, can't see why

so the board is power by a battery and there is no programmer connected to it?