diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2011-03-29 08:39:56 -0400 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2011-03-29 08:39:56 -0400 |
commit | 5f2026dae224c38b6f725e9697626edf989698eb (patch) | |
tree | 00669a230af25e66de1189bb28914bb8baec45fb /lcdgps.c | |
parent | 4873e25e90661026c16aa169096ca94254389f16 (diff) | |
download | gpsd-5f2026dae224c38b6f725e9697626edf989698eb.tar.gz |
Make the Maidenhead convrter available in Python.
Diffstat (limited to 'lcdgps.c')
-rw-r--r-- | lcdgps.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -181,11 +181,11 @@ static void update_lcd(struct gps_data_t *gpsdata) { char tmpbuf[255]; int n; - char *s, *maidenhead; + char *s, *gridsquare; int track; /* Get our location in Maidenhead. */ - maidenhead = latlon2maidenhead(gpsdata->fix.latitude,gpsdata->fix.longitude); + gridsquare = maidenhead(gpsdata->fix.latitude,gpsdata->fix.longitude); /* Fill in the latitude and longitude. */ if (gpsdata->fix.mode >= MODE_2D) { @@ -223,7 +223,7 @@ static void update_lcd(struct gps_data_t *gpsdata) for(n=0;n<CLIMB;n++) avgclimb+=climb[n]; avgclimb/=CLIMB; snprintf(tmpbuf, 254, "widget_set gpsd four 1 4 {%d %s %s %d fpm }\n", - (int)(gpsdata->fix.altitude*altfactor), altunits, maidenhead, (int)(avgclimb * METERS_TO_FEET * 60)); + (int)(gpsdata->fix.altitude*altfactor), altunits, gridsquare, (int)(avgclimb * METERS_TO_FEET * 60)); } else { snprintf(tmpbuf, 254, "widget_set gpsd four 1 4 {n/a}\n"); } |