A few bug fixes w.r.t the GPS and logging