summaryrefslogtreecommitdiff
path: root/lcdgps.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2011-03-05 01:22:44 -0500
committerEric S. Raymond <esr@thyrsus.com>2011-03-05 01:22:44 -0500
commit3b5fc9c5dc35b47a82a08555e91f4d0a97f2c6ab (patch)
tree9b2e6434e128451ecfa3cca06b4383b6a6fa8dd7 /lcdgps.c
parent3921cfe10b5a291e833cd47821b95d621655874d (diff)
downloadgpsd-3b5fc9c5dc35b47a82a08555e91f4d0a97f2c6ab.tar.gz
Un-botch the #ifdef CLIMB removal.
Diffstat (limited to 'lcdgps.c')
-rw-r--r--lcdgps.c11
1 files changed, 0 insertions, 11 deletions
diff --git a/lcdgps.c b/lcdgps.c
index 8ae63184..1719fc33 100644
--- a/lcdgps.c
+++ b/lcdgps.c
@@ -211,14 +211,9 @@ static enum deg_str_type deg_type = deg_dd;
static void update_lcd(struct gps_data_t *gpsdata)
{
char tmpbuf[255];
-#ifdef CLIMB
char maidenhead[5];
maidenhead[4]=0;
int n;
-#else
- char maidenhead[7];
- maidenhead[6]=0;
-#endif
char *s;
int track;
@@ -255,7 +250,6 @@ static void update_lcd(struct gps_data_t *gpsdata)
/* Fill in the altitude and fix status. */
if (gpsdata->fix.mode == MODE_3D) {
-#ifdef CLIMB
for(n=0;n<CLIMB-2;n++) climb[n]=climb[n+1];
climb[CLIMB-1]=gpsdata->fix.climb;
avgclimb=0.0;
@@ -263,9 +257,6 @@ static void update_lcd(struct gps_data_t *gpsdata)
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));
- snprintf(tmpbuf, 254, "widget_set gpsd four 1 4 {%.1f %s %s}\n",
- gpsdata->fix.altitude*altfactor, altunits, maidenhead);
-#endif
} else {
snprintf(tmpbuf, 254, "widget_set gpsd four 1 4 {n/a}\n");
}
@@ -303,10 +294,8 @@ int main(int argc, char *argv[])
fd_set rfds;
int data;
-#ifdef CLIMB
int n;
for(n=0;n<CLIMB;n++) climb[n]=0.0;
-#endif
/*@ -observertrans @*/
switch (gpsd_units())