From c88ae0f44eefaa6adc0fc941f826d8bf34450649 Mon Sep 17 00:00:00 2001 From: Georg Lukas Date: Thu, 4 Apr 2013 21:24:26 +0200 Subject: [PATCH] kenwood: only send relevant NMEA --- src/backend/KenwoodTnc.scala | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/backend/KenwoodTnc.scala b/src/backend/KenwoodTnc.scala index 695d209..d8b3560 100644 --- a/src/backend/KenwoodTnc.scala +++ b/src/backend/KenwoodTnc.scala @@ -21,9 +21,11 @@ class KenwoodTnc(service : AprsService, prefs : PrefsWrapper) extends BluetoothT } def onNmeaReceived(timestamp : Long, nmea : String) { - Log.d(TAG, "NMEA <<< " + nmea) - if (output != null) + if (output != null && (nmea.startsWith("$GPGGA") || nmea.startsWith("$GPRMC"))) { + Log.d(TAG, "NMEA >>> " + nmea) output.write(nmea) + } else + Log.d(TAG, "NMEA --- " + nmea) } override def stop() {