If pin 9 or pin 16 are disconnected from the xbee module then it will function reliably. Switch #4 is connected to those lines and is causing some sort of issue that prevents the xbee from starting up and executing.
There are 4 work-arounds for the issue.
1- On failure, do a quick power cycle and it should start up. This is not an option if you do not have some external logic or method to perform it manually.
2 - Put an external 10K pull-up resistor between terminal 6 and 2,
3 - Disconnect pin 9 from the XBee module,
4- Disconnect pin 16 from the XBee module.
Aug 08, 2017