Frequency counter using GPS 1PPS signal and temperature controlled 50MHz Base clock. Ported from F411 Frequency Counter.
Dependencies: QEI DRV8830 PID ADT7410 TextLCD Frq_cuntr_Nucleo-F746ZG RingBuffer
Fork of Frequency_Counter_w_GPS_1PPS by
Please refer following.
/users/kenjiArai/notebook/frequency-counters/
GPS_rcvr/GPSrcvr.h@15:ae0413277bc6, 2019-12-22 (annotated)
- Committer:
- kenjiArai
- Date:
- Sun Dec 22 06:29:39 2019 +0000
- Revision:
- 15:ae0413277bc6
- Parent:
- 13:1041596c416c
Update os5 -> 0s5.15.0
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
kenjiArai | 13:1041596c416c | 1 | /* |
kenjiArai | 13:1041596c416c | 2 | * mbed Application program / GPS receiver control and 1PPS output |
kenjiArai | 13:1041596c416c | 3 | * |
kenjiArai | 13:1041596c416c | 4 | * Copyright (c) 2004,'09,'10,'16 Kenji Arai / JH1PJL |
kenjiArai | 13:1041596c416c | 5 | * http://www.page.sannet.ne.jp/kenjia/index.html |
kenjiArai | 13:1041596c416c | 6 | * http://mbed.org/users/kenjiArai/ |
kenjiArai | 13:1041596c416c | 7 | * Created: March 28th, 2004 Kenji Arai |
kenjiArai | 13:1041596c416c | 8 | * updated: July 25th, 2009 for PIC24USB |
kenjiArai | 13:1041596c416c | 9 | * updated: January 16th, 2010 change to GPS-GM318 |
kenjiArai | 13:1041596c416c | 10 | * updated: April 24th, 2010 for mbed / NXP LPC1768 |
kenjiArai | 15:ae0413277bc6 | 11 | * Revised: Nomeber 22nd, 2016 |
kenjiArai | 13:1041596c416c | 12 | */ |
kenjiArai | 13:1041596c416c | 13 | |
kenjiArai | 13:1041596c416c | 14 | // Definition ----------------------------------------------------------------- |
kenjiArai | 13:1041596c416c | 15 | // GPS data selection & buffer size |
kenjiArai | 13:1041596c416c | 16 | /* $GPGAA,hhmmss.sss,ddmm.mmmmmm,N,dddmm.mmmmmm, |
kenjiArai | 13:1041596c416c | 17 | E,1,xx,xx.xx,xx.xxx,M,xx.xxx,M,s.ss,xxxx*sum<CR><LF> |
kenjiArai | 13:1041596c416c | 18 | ex. $GPGGA,060306.00,4344.77894,N,14223.38857, |
kenjiArai | 13:1041596c416c | 19 | E,2,11,0.9,128.4,M,28.8,M,5.0,0129*4C<CR><LF> |
kenjiArai | 13:1041596c416c | 20 | # of data (ex.) = 81 |
kenjiArai | 13:1041596c416c | 21 | */ |
kenjiArai | 13:1041596c416c | 22 | #define SIZE_BUF_GGA 96 |
kenjiArai | 13:1041596c416c | 23 | /* |
kenjiArai | 13:1041596c416c | 24 | $GPGSA,A,3,xx,xx,,,xx,xx,,,,,xx.x,xx.x,xx.x*sum<CR><LF> |
kenjiArai | 13:1041596c416c | 25 | ex. $GPGSA,A,3,03,06,13,16,21,23,24,25,29,31,42,50,1.9,0.9,1.7*3C |
kenjiArai | 13:1041596c416c | 26 | # of data (ex.) = 63 |
kenjiArai | 13:1041596c416c | 27 | */ |
kenjiArai | 13:1041596c416c | 28 | #define SIZE_BUF_GSA 80 |
kenjiArai | 13:1041596c416c | 29 | /* |
kenjiArai | 13:1041596c416c | 30 | $GPGSV,x,x,xx*sum<CR><LF> |
kenjiArai | 13:1041596c416c | 31 | ex. $GPGSV,3,1,12,03,39,225,47,06,55,217,48,13,21,314,48,16,74,342,50*76 |
kenjiArai | 13:1041596c416c | 32 | $GPGSV,3,2,12,21,33,095,50,23,32,280,50,24,18,049,42,25,12,315,43*7E |
kenjiArai | 13:1041596c416c | 33 | $GPGSV,3,3,12,29,12,047,45,31,49,146,49,42,39,183,46,50,39,176,42*7C |
kenjiArai | 13:1041596c416c | 34 | # of data (ex.) = 70 |
kenjiArai | 13:1041596c416c | 35 | */ |
kenjiArai | 13:1041596c416c | 36 | #define SIZE_BUF_GSV 80 |
kenjiArai | 13:1041596c416c | 37 | /* |
kenjiArai | 13:1041596c416c | 38 | $GPRMC,hhmmss.sss,V,ddmm.mmmm,N,dddmm.mmmm,E,k.kkk,x.xx,ddmmyy,,,N*sum<CR><LF> |
kenjiArai | 13:1041596c416c | 39 | ex. $GPRMC,060309.00,A,4344.77571,N,14223.38879, |
kenjiArai | 13:1041596c416c | 40 | E,0.03,210.32,190808,06.2,W,D*51 |
kenjiArai | 13:1041596c416c | 41 | # of data (ex.) = 84 |
kenjiArai | 13:1041596c416c | 42 | */ |
kenjiArai | 13:1041596c416c | 43 | #define SIZE_BUF_RMC 96 |
kenjiArai | 13:1041596c416c | 44 | /* |
kenjiArai | 13:1041596c416c | 45 | $GPVTG,xx.xx,T,,M,x.xx,N,x.xx,K,A*sum<CR><LF> |
kenjiArai | 13:1041596c416c | 46 | ex. $GPVTG,210.32,T,204.30,M,0.03,N,0.06,K,D*3F |
kenjiArai | 13:1041596c416c | 47 | # of data (ex.) = 43 |
kenjiArai | 13:1041596c416c | 48 | */ |
kenjiArai | 13:1041596c416c | 49 | #define SIZE_BUF_VTG 64 |
kenjiArai | 13:1041596c416c | 50 | /* |
kenjiArai | 13:1041596c416c | 51 | $GPZDA,hhmmss.sss,dd,mmm,yyyy,hh,mm*sum<CR><LF> |
kenjiArai | 13:1041596c416c | 52 | ex. $GPZDA,060307.00,19,08,2008,13,26*6E |
kenjiArai | 13:1041596c416c | 53 | # of data (ex.) = 36 |
kenjiArai | 13:1041596c416c | 54 | */ |
kenjiArai | 13:1041596c416c | 55 | #define SIZE_BUF_ZDA 48 |
kenjiArai | 13:1041596c416c | 56 | /* |
kenjiArai | 13:1041596c416c | 57 | $GPGLL,ddmm.mmmmmm,N,dddmm.mmmmmm,E,hhmmss.sss,V,D*sum<CR><LF> |
kenjiArai | 13:1041596c416c | 58 | ex. $GPGLL,4344.77956,N,14223.38863,E,060305.00,A,D*61 |
kenjiArai | 13:1041596c416c | 59 | # of data (ex.) = 52 |
kenjiArai | 13:1041596c416c | 60 | */ |
kenjiArai | 13:1041596c416c | 61 | #define SIZE_BUF_GLL 64 |
kenjiArai | 13:1041596c416c | 62 | |
kenjiArai | 13:1041596c416c | 63 | #define ERR 0xff |
kenjiArai | 13:1041596c416c | 64 | |
kenjiArai | 13:1041596c416c | 65 | //------------------------------------------------------------------------------ |
kenjiArai | 13:1041596c416c | 66 | |
kenjiArai | 13:1041596c416c | 67 | #ifndef _IGPSRCV_H |
kenjiArai | 13:1041596c416c | 68 | #define _IGPSRCV_H |
kenjiArai | 13:1041596c416c | 69 | |
kenjiArai | 13:1041596c416c | 70 | void gps_data_rcv(void); // make sure !! infinit loop on RTOS |
kenjiArai | 13:1041596c416c | 71 | bool check_gps_is_okay(void); |
kenjiArai | 13:1041596c416c | 72 | uint8_t check_gps_3d(void); |
kenjiArai | 13:1041596c416c | 73 | |
kenjiArai | 13:1041596c416c | 74 | #endif /* _IGPSRCV_H */ |