1. change the orientation threshold to 5
2. change the MSG_MAX_ATTEMP to 5