cleaned gps/map code part1