diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2011-01-20 02:19:21 -0500 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2011-01-20 02:19:21 -0500 |
commit | 267d7ae36bf6786629a3892ec9870e1e4095dd9d (patch) | |
tree | a3034d62eeb24884dc407a163e8cb364bb7737e7 /monitor_sirf.c | |
parent | fb63018f46b92129ab8ef4cfc6d0cd996429fd41 (diff) | |
download | gpsd-267d7ae36bf6786629a3892ec9870e1e4095dd9d.tar.gz |
Add explantory comments.
Diffstat (limited to 'monitor_sirf.c')
-rw-r--r-- | monitor_sirf.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/monitor_sirf.c b/monitor_sirf.c index 03bbab68..8c26f58f 100644 --- a/monitor_sirf.c +++ b/monitor_sirf.c @@ -217,14 +217,18 @@ static void decode_time(int week, int tow) m = (m - s) / 6000; + /* week + tow */ (void)wmove(mid2win, 3, 10); (void)wprintw(mid2win, "%4d+%9.2f", week, (double)tow / 100); + /* day and h:m:s within week */ (void)wmove(mid2win, 3, 30); (void)wprintw(mid2win, "%d %02d:%02d:%05.2f", day, h, m, (double)s / 100); + /* skew from leap-seconds */ (void)wmove(mid2win, 4, 8); (void)wattrset(mid2win, A_UNDERLINE); (void)wprintw(mid2win, "%f", timestamp() - gpstime_to_unix(week, tow / 100.0)); + /* offset from gmt in seconds */ (void)wmove(mid2win, 4, 29); (void)wprintw(mid2win, "%d", gmt_offset); (void)wattrset(mid2win, A_NORMAL); @@ -263,6 +267,7 @@ static void decode_ecef(double x, double y, double z, if (heading < 0) heading += 2 * GPS_PI; + /* North and East position fields */ (void)wattrset(mid2win, A_UNDERLINE); (void)wmove(mid2win, 1, 40); (void)wprintw(mid2win, "%9.5f %9.5f", (double)(RAD_2_DEG * phi), @@ -272,11 +277,13 @@ static void decode_ecef(double x, double y, double z, (void)wmove(mid2win, 1, 61); (void)wprintw(mid2win, "%8d", (int)h); + /* North and East velocity fields */ (void)wmove(mid2win, 2, 40); (void)wprintw(mid2win, "%9.1f %9.1f", vnorth, veast); (void)wmove(mid2win, 2, 61); (void)wprintw(mid2win, "%8.1f", vup); + /* heading and speed fields */ (void)wmove(mid2win, 3, 54); (void)wprintw(mid2win, "%5.1f", (double)(RAD_2_DEG * heading)); (void)mvwaddch(mid2win, 3, 59, ACS_DEGREE); |