summaryrefslogtreecommitdiff
path: root/cgps.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2006-08-18 22:36:29 +0000
committerEric S. Raymond <esr@thyrsus.com>2006-08-18 22:36:29 +0000
commit4bf8bd5599e2dc58477b399fdb102252a197f69e (patch)
tree2a52a12261b27c533acdcfc639b5affc09dcbaeb /cgps.c
parentb62c70817d406b8cbc3cca8dbb85b73e3cb9c12b (diff)
downloadgpsd-4bf8bd5599e2dc58477b399fdb102252a197f69e.tar.gz
Enable 'j' command in cgps.
Diffstat (limited to 'cgps.c')
-rw-r--r--cgps.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/cgps.c b/cgps.c
index a5726d03..2611ad64 100644
--- a/cgps.c
+++ b/cgps.c
@@ -55,6 +55,9 @@ static char *speedunits = "mph";
static WINDOW *datawin, *satellites, *messages, *command, *status;
int silent_flag=0;
+#ifndef WIRED_POLICY
+int fixclear_flag=0;
+#endif /* WIRED_POLICY */
int ops_flag=0;
/* Function to call when we're all done. Does a bit of clean-up. */
@@ -481,6 +484,19 @@ int main(int argc, char *argv[])
}
break;
+#ifndef WIRED_POLICY
+ /* Toggle fix clear. */
+ case 'j':
+ if(fixclear_flag==0) {
+ fixclear_flag=1;
+ (void)gps_query(gpsdata, "j1\n");
+ } else {
+ fixclear_flag=0;
+ (void)gps_query(gpsdata, "j0\n");
+ }
+ break;
+#endif /* WIRED_POLICY */
+
/* Clear the spewage area. */
case 'c':
(void)werase(messages);