updated code to check for connection and to allow manifest file to have permission to access gps svcs.