cleaning up the code

I am cleaning up the code which is messed up by me and uploading single
module at a time in working condition.
In this commit:
1. onPause and OnResume method are implemented to improve the lifecycle
of android app.
2. GPS data is stored into the exif header.(all the data writing is
happening in background to reduce the lag that camera has to face)