fixed some code format issue; changed connectingToLaptop to false; corrected the onStop to onDestroy
fixed layout indentation issue; fixed bug of crashing due to unregistered receiver