add gps update and fix some bugs