So it seems that cordova is having issue with settimeout.. or perhaps there are some scope problems.. Either way i fixed the transition between location and draw views with an explicit button tap. Added a pubsub messaging system so the views can talk to each other. Fixed scope issue on draw view so that the accelerometer turns off after a certain period of time