aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/protocol/SuntechProtocolDecoder.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2015-01-10 10:11:55 +1300
committerAnton Tananaev <anton.tananaev@gmail.com>2015-01-10 10:11:55 +1300
commitab0e4b7519890aa5b1d38f9ea62868ec23239d0d (patch)
tree3cf08ca40d097e71f4c97d2ab53fddc66f1714fb /src/org/traccar/protocol/SuntechProtocolDecoder.java
parent9c6511f387e8e58d086fa45663478394a31eaf9e (diff)
parent88cce4463160d31923d3be2ad893a436a8aef8cf (diff)
downloadtrackermap-server-ab0e4b7519890aa5b1d38f9ea62868ec23239d0d.tar.gz
trackermap-server-ab0e4b7519890aa5b1d38f9ea62868ec23239d0d.tar.bz2
trackermap-server-ab0e4b7519890aa5b1d38f9ea62868ec23239d0d.zip
Merge branch master of github
Diffstat (limited to 'src/org/traccar/protocol/SuntechProtocolDecoder.java')
-rw-r--r--src/org/traccar/protocol/SuntechProtocolDecoder.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/org/traccar/protocol/SuntechProtocolDecoder.java b/src/org/traccar/protocol/SuntechProtocolDecoder.java
index 868425e8d..cdfca7905 100644
--- a/src/org/traccar/protocol/SuntechProtocolDecoder.java
+++ b/src/org/traccar/protocol/SuntechProtocolDecoder.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2013 Anton Tananaev (anton.tananaev@gmail.com)
+ * Copyright 2013 - 2015 Anton Tananaev (anton.tananaev@gmail.com)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -39,7 +39,8 @@ public class SuntechProtocolDecoder extends BaseProtocolDecoder {
static private Pattern pattern = Pattern.compile(
"S.\\d{3}(?:\\w{3})?;" + // Header
"(?:[^;]+;)?" +
- "(\\d{6});" + // Device ID
+ "(\\d{6,});" + // Device ID
+ "(?:\\d+;)?" +
"(\\d+);" + // Version
"(\\d{4})(\\d{2})(\\d{2});" + // Date (YYYYMMDD)
"(\\d{2}):(\\d{2}):(\\d{2});" + // Time (HH:MM:SS)