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/
User_IF/uif.h@13:1041596c416c, 2016-11-23 (annotated)
- Committer:
- kenjiArai
- Date:
- Wed Nov 23 07:35:20 2016 +0000
- Revision:
- 13:1041596c416c
- Child:
- 14:ba6ea409ab05
Frequency counter using GPS 1PPS signal and temperature controlled 50MHz Base clock. Ported from F411 Frequency Counter.
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 / User Interface subroutines |
kenjiArai | 13:1041596c416c | 3 | * |
kenjiArai | 13:1041596c416c | 4 | * Copyright (c) 2016 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: September 28th, 2016 |
kenjiArai | 13:1041596c416c | 8 | * Revised: Novemeber 23rd, 2016 |
kenjiArai | 13:1041596c416c | 9 | * |
kenjiArai | 13:1041596c416c | 10 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, |
kenjiArai | 13:1041596c416c | 11 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF |
kenjiArai | 13:1041596c416c | 12 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. |
kenjiArai | 13:1041596c416c | 13 | * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, |
kenjiArai | 13:1041596c416c | 14 | * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR |
kenjiArai | 13:1041596c416c | 15 | * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR |
kenjiArai | 13:1041596c416c | 16 | * THE USE OR OTHER DEALINGS IN THE SOFTWARE. |
kenjiArai | 13:1041596c416c | 17 | */ |
kenjiArai | 13:1041596c416c | 18 | |
kenjiArai | 13:1041596c416c | 19 | // Definition ----------------------------------------------------------------- |
kenjiArai | 13:1041596c416c | 20 | typedef struct{ |
kenjiArai | 13:1041596c416c | 21 | double m_frq; // measured freq. data 1sec interval (Raw data) |
kenjiArai | 13:1041596c416c | 22 | double m_frq_10; // same as avove / avarage 10sec |
kenjiArai | 13:1041596c416c | 23 | double m_frq_100; // same as avove / avarage 100sec |
kenjiArai | 13:1041596c416c | 24 | double m_frq_1000; // same as avove / avarage 1000sec |
kenjiArai | 13:1041596c416c | 25 | double m_frq_comp; // same as avove / compensated data |
kenjiArai | 13:1041596c416c | 26 | double m_frq_recipro; // masured freq. by reciprocal way |
kenjiArai | 13:1041596c416c | 27 | double b_1pps_lng; // base clock by 1PPS (avarage data) |
kenjiArai | 13:1041596c416c | 28 | uint32_t b_1pps_new; // same as avobe / newest raw data |
kenjiArai | 13:1041596c416c | 29 | double box_tmp; // temperature of temperature oven |
kenjiArai | 13:1041596c416c | 30 | uint8_t recipro_of; // reciprocal overflow (higher freq) |
kenjiArai | 13:1041596c416c | 31 | uint8_t temp_is_okay; // oven temperature is inside of range |
kenjiArai | 13:1041596c416c | 32 | uint32_t gps_1pps_ave; // GPS 1PPS # of avarage |
kenjiArai | 13:1041596c416c | 33 | uint32_t ready_1pps; // GPS 1PPS is available (none-zero) |
kenjiArai | 13:1041596c416c | 34 | }dispDef; |
kenjiArai | 13:1041596c416c | 35 | |
kenjiArai | 13:1041596c416c | 36 | // Function prototypes -------------------------------------------------------- |
kenjiArai | 13:1041596c416c | 37 | void dispay_LCD_and_UART(dispDef *dt); |
kenjiArai | 13:1041596c416c | 38 | |
kenjiArai | 13:1041596c416c | 39 | void display_clear_all(void); |
kenjiArai | 13:1041596c416c | 40 | void disp_first_msg(void); |
kenjiArai | 13:1041596c416c | 41 | void disp_wait_gps(void); |
kenjiArai | 13:1041596c416c | 42 | void select_input_div_1or10or20(uint8_t div); |