From d01c0acb499555ab1e5fc1592a3dced5cce2a677 Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Tue, 24 Sep 2013 23:16:26 +1200 Subject: Fix globalsat decoder (fix #397) --- src/org/traccar/protocol/GlobalSatProtocolDecoder.java | 2 +- test/org/traccar/protocol/GlobalSatProtocolDecoderTest.java | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/org/traccar/protocol/GlobalSatProtocolDecoder.java b/src/org/traccar/protocol/GlobalSatProtocolDecoder.java index 3d3ecd02e..2e0cb4ca6 100644 --- a/src/org/traccar/protocol/GlobalSatProtocolDecoder.java +++ b/src/org/traccar/protocol/GlobalSatProtocolDecoder.java @@ -187,7 +187,7 @@ public class GlobalSatProtocolDecoder extends BaseProtocolDecoder { "(\\d{2})(\\d{2}\\.\\d+)," + // Latitude (DDMM.MMMM) "(\\d+\\.?\\d*)," + // Altitude "(\\d+\\.?\\d*)," + // Speed - "(\\d+)," + // Course + "(\\d+\\.?\\d*)," + // Course "(\\d+)," + // Satellites "(\\d+\\.?\\d*)"); // HDOP diff --git a/test/org/traccar/protocol/GlobalSatProtocolDecoderTest.java b/test/org/traccar/protocol/GlobalSatProtocolDecoderTest.java index 35822fb91..22c8d5439 100644 --- a/test/org/traccar/protocol/GlobalSatProtocolDecoderTest.java +++ b/test/org/traccar/protocol/GlobalSatProtocolDecoderTest.java @@ -26,6 +26,12 @@ public class GlobalSatProtocolDecoderTest { assertNotNull(decoder.decode(null, null, "$355632000959420,9,3,160413,230536,E03738.4906,N5546.3148,00000,0.3870,147,07,2.4")); + + assertNotNull(decoder.decode(null, null, + "$353681041893264,9,3,240913,100833,E08513.0122,N5232.9395,181.3,22.02,251.30,9,1.00")); + + /*assertNotNull(decoder.decode(null, null, + "$353681041893264,9,4,230913,052449,\"250,99,B443,422E,42,37\",\"250,99,B443,4232,43,44\",\"250,99,B443,7910,40,32\",\"250,99,B443,B456,40,28\",\"250,99,B443,B455,40,27\""));*/ } -- cgit v1.2.3