diff options
author | Keith Packard <keithp@keithp.com> | 2012-12-05 20:10:54 -0800 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2012-12-05 20:10:54 -0800 |
commit | 8b1f186a574c22cebd9daba9d352ec82556c3b28 (patch) | |
tree | 059ebb6575e79befcc60b9eae22c964d21a43206 /src/drivers/ao_aprs.c | |
parent | 0c2c47dd7af2fc95de852178c4244daba02f44ed (diff) |
altos: Generate all of the APRS messages
Note that two of them are in NMEA form, which some receivers appear
not to parse
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'src/drivers/ao_aprs.c')
-rw-r--r-- | src/drivers/ao_aprs.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/drivers/ao_aprs.c b/src/drivers/ao_aprs.c index df68278c..0a41d5fd 100644 --- a/src/drivers/ao_aprs.c +++ b/src/drivers/ao_aprs.c @@ -395,7 +395,7 @@ const uint32_t freqTable[256] = void ddsSetFTW (uint32_t ftw) { int x = ftw - freqTable[0]; - putchar (x > 0 ? 0xff : 0x0); + putchar (x > 0 ? 0xc0 : 0x40); } /** @@ -1243,6 +1243,10 @@ tncPrintf(char *fmt, ...) va_start(ap, fmt); c = vsprintf((char *) tncBufferPnt, fmt, ap); + if (*fmt == '\015') + fprintf (stderr, "\n"); + else + vfprintf(stderr, fmt, ap); va_end(ap); tncBufferPnt += c; tncLength += c; @@ -1378,7 +1382,7 @@ void tncStatusPacket(int16_t temperature) tncPrintf (">ANSR "); // Display the flight time. - tncPrintf ("%02U:%02U:%02U ", timeHours, timeMinutes, timeSeconds); + tncPrintf ("%02u:%02u:%02u ", timeHours, timeMinutes, timeSeconds); // Altitude in feet. tncPrintf ("%ld' ", gpsPosition.altitudeFeet); |