summaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2005-02-11 04:27:00 +0000
committerEric S. Raymond <esr@thyrsus.com>2005-02-11 04:27:00 +0000
commitd312a9156901cf213bac99a43252886e8d6fc4a8 (patch)
tree53973f31474ef5abb1e8da138d430c6ef436f2f9 /contrib
parent4c3cf58f512ca29f8d8ef482dd419c8f3046943c (diff)
downloadgpsd-d312a9156901cf213bac99a43252886e8d6fc4a8.tar.gz
This version, modified to look at ttyUSB0, works if you answer 'y' to
the restart question.
Diffstat (limited to 'contrib')
-rw-r--r--contrib/gpsread.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/contrib/gpsread.c b/contrib/gpsread.c
index f92cfeea..e7182530 100644
--- a/contrib/gpsread.c
+++ b/contrib/gpsread.c
@@ -56,7 +56,7 @@
** set for all users. E.g. set permission from root with command
** `chmod 666 /dev/ttyS?`
*/
-#define MODEMDEVICE "/dev/ttyS2" /* COM1 */
+#define MODEMDEVICE "/dev/ttyUSB0" /* COM1 */
#define _POSIX_SOURCE 1 /* POSIX compliant source */
#define FALSE 0
@@ -121,12 +121,7 @@ main(int argc, char *argv[])
if (START)
{
- fprintf(stderr,"now waiting for serial NMEA data at 4800 baud from ");
- if (strstr(MODEMDEVICE,"ttyS0")) fprintf(stderr,"COM1");
- if (strstr(MODEMDEVICE,"ttyS1")) fprintf(stderr,"COM2");
- if (strstr(MODEMDEVICE,"ttyS2")) fprintf(stderr,"COM3");
- if (strstr(MODEMDEVICE,"ttyS3")) fprintf(stderr,"COM4");
- fprintf(stderr," ...\n");
+ fprintf(stderr,"now waiting for serial NMEA data at 4800 baud from " MODEMDEVICE "\n");
/* Open modem device for reading and writing and not as controlling
tty because we don't want to get killed if linenoise sends CTRL-C.