# HG changeset patch # User mkanning@CL-SEC241-10.cedarville.edu # Date 2012-11-15 11:39:24 # Node ID 6a57c40fdde25a0fe71815e3de17d098780fcd18 # Parent 3a560af409fa3ef7ca44d6a84d67fbcb01e8c477 gps.c and gps.h changes diff --git a/master/master/lib/trackuinoGPS/gps.c b/master/master/lib/trackuinoGPS/gps.c --- a/master/master/lib/trackuinoGPS/gps.c +++ b/master/master/lib/trackuinoGPS/gps.c @@ -82,11 +82,7 @@ static const int NUM_OF_UNK_PARSERS = (s static const int NUM_OF_GGA_PARSERS = (sizeof(gga_parsers) / sizeof(t_nmea_parser)); static const int NUM_OF_RMC_PARSERS = (sizeof(rmc_parsers) / sizeof(t_nmea_parser)); -enum t_sentence_type { - SENTENCE_UNK, - SENTENCE_GGA, - SENTENCE_RMC -}; + // Module variables static t_sentence_type sentence_type = SENTENCE_UNK; @@ -256,6 +252,7 @@ void gps_setup() { strcpy(gps_aprs_lat, "0000.00N"); strcpy(gps_aprs_lon, "00000.00E"); } + /// MKa GPS transmission parser void parse_gps_transmission(char c){ // i think c is the most recent character of transmission and is constantly @@ -264,9 +261,10 @@ void parse_gps_transmission(char c){ // $--GGA,hhmmss.ss,llll.ll,a,yyyyy.yy,a,x,xx,x.x,x.x,M,x.x,M,x.x,xxxx if(c == '\n') //end of transmission sentence. may need more checks { - + } } + /// process gps transmission bool gps_decode(char c) { diff --git a/master/master/lib/trackuinoGPS/gps.h b/master/master/lib/trackuinoGPS/gps.h --- a/master/master/lib/trackuinoGPS/gps.h +++ b/master/master/lib/trackuinoGPS/gps.h @@ -34,7 +34,14 @@ extern float gps_course; extern float gps_speed; extern float gps_altitude; + + void gps_setup(); bool gps_decode(char c); #endif +enum t_sentence_type { + SENTENCE_UNK, + SENTENCE_GGA, + SENTENCE_RMC +}; \ No newline at end of file