Files
@ dd3b59fcb7a7
Branch filter:
Location: FeatherHAB/wsprhab/inc/gps.h - annotation
dd3b59fcb7a7
1.8 KiB
text/plain
Added code to handle GPS fix acquisition. Hot reaq time is around 3-4s. WSPR currently disabled.
0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 dd3b59fcb7a7 dd3b59fcb7a7 0d9900312165 dd3b59fcb7a7 dd3b59fcb7a7 dd3b59fcb7a7 dd3b59fcb7a7 dd3b59fcb7a7 dd3b59fcb7a7 dd3b59fcb7a7 ddd34459834e 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 0d9900312165 dd3b59fcb7a7 0d9900312165 0d9900312165 0d9900312165 dd3b59fcb7a7 dd3b59fcb7a7 dd3b59fcb7a7 ddd34459834e 0d9900312165 0d9900312165 0d9900312165 | /*
* Master Firmware: NMEA Parser
*
* This file is part of OpenTrack.
*
* OpenTrack is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* OpenTrack is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with OpenTrack. If not, see <http://www.gnu.org/licenses/>.
*
* Ethan Zonca
* Matthew Kanning
* Kyle Ripperger
* Matthew Kroening
*
*/
#ifndef GPS_H_
#define GPS_H_
#include <stdint.h>
// Duration before GPS fix is declared stale
#define GPS_STALEFIX_MS 60000
enum gps_state
{
GPS_STATE_ACQUIRING = 0,
GPS_STATE_FRESHFIX,
GPS_STATE_STALEFIX,
GPS_STATE_NOFIX
};
// Messages (REMOVEME?)
#define GGA_MESSAGE
#define RMC_MESSAGE
#define UKN_MESSAGE
void gps_poweron(void);
void gps_poweroff(void);
void gps_init(void);
void gps_sendubx(uint8_t* data, uint8_t size);
char* get_longitudeTrimmed(void);
char* get_longitudeLSBs(void);
char* get_latitudeTrimmed(void);
char* get_latitudeLSBs(void);
char* get_timestamp(void);
char* get_gpsaltitude(void);
char* get_speedKnots(void);
char* get_course(void);
char* get_hdop(void);
uint16_t get_hdop_int_tenths(void);
char* get_sv(void);
char* get_dayofmonth(void);
uint8_t gps_hasfix(void);
void gps_process(void);
uint8_t gps_getstate(void);
void gps_acquirefix(void);
void parse_gps_transmission(void);
void XORbyteWithChecksum(uint8_t byte);
#endif /* GPS_H_ */
|