aboutsummaryrefslogtreecommitdiff
path: root/src/org
diff options
context:
space:
mode:
Diffstat (limited to 'src/org')
-rw-r--r--src/org/traccar/Server.java18
-rw-r--r--src/org/traccar/protocol/Avl08ProtocolDecoder.java (renamed from src/org/traccar/protocol/avl08/Avl08ProtocolDecoder.java)7
-rw-r--r--src/org/traccar/protocol/Gl100ProtocolDecoder.java (renamed from src/org/traccar/protocol/gl100/Gl100ProtocolDecoder.java)2
-rw-r--r--src/org/traccar/protocol/Gl200ProtocolDecoder.java (renamed from src/org/traccar/protocol/gl200/Gl200ProtocolDecoder.java)2
-rw-r--r--src/org/traccar/protocol/Gps103ProtocolDecoder.java (renamed from src/org/traccar/protocol/gps103/Gps103ProtocolDecoder.java)2
-rw-r--r--src/org/traccar/protocol/T55ProtocolDecoder.java (renamed from src/org/traccar/protocol/t55/T55ProtocolDecoder.java)2
-rw-r--r--src/org/traccar/protocol/Tk103ProtocolDecoder.java (renamed from src/org/traccar/protocol/tk103/Tk103ProtocolDecoder.java)4
-rw-r--r--src/org/traccar/protocol/Xexun2ProtocolDecoder.java (renamed from src/org/traccar/protocol/xexun2/Xexun2ProtocolDecoder.java)2
-rw-r--r--src/org/traccar/protocol/XexunFrameDecoder.java (renamed from src/org/traccar/protocol/xexun/XexunFrameDecoder.java)2
-rw-r--r--src/org/traccar/protocol/XexunProtocolDecoder.java (renamed from src/org/traccar/protocol/xexun/XexunProtocolDecoder.java)2
10 files changed, 21 insertions, 22 deletions
diff --git a/src/org/traccar/Server.java b/src/org/traccar/Server.java
index a84f8f337..b5e7acdea 100644
--- a/src/org/traccar/Server.java
+++ b/src/org/traccar/Server.java
@@ -39,12 +39,12 @@ import org.jboss.netty.handler.codec.string.StringEncoder;
import org.jboss.netty.handler.codec.frame.DelimiterBasedFrameDecoder;
import org.jboss.netty.buffer.ChannelBuffers;
import org.jboss.netty.handler.logging.LoggingHandler;
-import org.traccar.protocol.xexun.XexunFrameDecoder;
-import org.traccar.protocol.xexun.XexunProtocolDecoder;
-import org.traccar.protocol.gps103.Gps103ProtocolDecoder;
-import org.traccar.protocol.tk103.Tk103ProtocolDecoder;
-import org.traccar.protocol.gl200.Gl200ProtocolDecoder;
-import org.traccar.protocol.t55.T55ProtocolDecoder;
+import org.traccar.protocol.XexunFrameDecoder;
+import org.traccar.protocol.XexunProtocolDecoder;
+import org.traccar.protocol.Gps103ProtocolDecoder;
+import org.traccar.protocol.Tk103ProtocolDecoder;
+import org.traccar.protocol.Gl200ProtocolDecoder;
+import org.traccar.protocol.T55ProtocolDecoder;
import org.jboss.netty.channel.ChannelHandlerContext;
import org.jboss.netty.channel.ChannelPipeline;
import org.jboss.netty.channel.ChannelPipelineFactory;
@@ -52,9 +52,9 @@ import org.jboss.netty.channel.ChannelStateEvent;
import org.jboss.netty.channel.Channels;
import org.jboss.netty.channel.SimpleChannelHandler;
import org.traccar.helper.AdvancedConnection;
-import org.traccar.protocol.gl100.Gl100ProtocolDecoder;
-import org.traccar.protocol.xexun2.Xexun2ProtocolDecoder;
-import org.traccar.protocol.avl08.Avl08ProtocolDecoder;
+import org.traccar.protocol.Gl100ProtocolDecoder;
+import org.traccar.protocol.Xexun2ProtocolDecoder;
+import org.traccar.protocol.Avl08ProtocolDecoder;
/**
* Server
diff --git a/src/org/traccar/protocol/avl08/Avl08ProtocolDecoder.java b/src/org/traccar/protocol/Avl08ProtocolDecoder.java
index 4fb33f5ba..7f564af37 100644
--- a/src/org/traccar/protocol/avl08/Avl08ProtocolDecoder.java
+++ b/src/org/traccar/protocol/Avl08ProtocolDecoder.java
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.traccar.protocol.avl08;
+package org.traccar.protocol;
import java.util.Calendar;
import java.util.GregorianCalendar;
@@ -65,8 +65,9 @@ public class Avl08ProtocolDecoder extends GenericProtocolDecoder {
"(.\\d{3})\\|" + // Temperature
"(\\d+.\\d{4})\\|" + // Mileage
"(\\d{4})\\|" + // Serial
- "(.{10})?\\|" + // RFID
- ".+");
+ "(.{10})?\\|?" + // RFID
+ ".+"); // TODO: Use non-capturing group
+
/**
* Decode message
*/
diff --git a/src/org/traccar/protocol/gl100/Gl100ProtocolDecoder.java b/src/org/traccar/protocol/Gl100ProtocolDecoder.java
index e4c0de38a..4ec41f8c1 100644
--- a/src/org/traccar/protocol/gl100/Gl100ProtocolDecoder.java
+++ b/src/org/traccar/protocol/Gl100ProtocolDecoder.java
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.traccar.protocol.gl100;
+package org.traccar.protocol;
import java.util.Calendar;
import java.util.GregorianCalendar;
diff --git a/src/org/traccar/protocol/gl200/Gl200ProtocolDecoder.java b/src/org/traccar/protocol/Gl200ProtocolDecoder.java
index 4c1149347..a43562eb9 100644
--- a/src/org/traccar/protocol/gl200/Gl200ProtocolDecoder.java
+++ b/src/org/traccar/protocol/Gl200ProtocolDecoder.java
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.traccar.protocol.gl200;
+package org.traccar.protocol;
import java.util.Calendar;
import java.util.GregorianCalendar;
diff --git a/src/org/traccar/protocol/gps103/Gps103ProtocolDecoder.java b/src/org/traccar/protocol/Gps103ProtocolDecoder.java
index f50dfad2a..e9c889af7 100644
--- a/src/org/traccar/protocol/gps103/Gps103ProtocolDecoder.java
+++ b/src/org/traccar/protocol/Gps103ProtocolDecoder.java
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.traccar.protocol.gps103;
+package org.traccar.protocol;
import java.util.Calendar;
import java.util.GregorianCalendar;
diff --git a/src/org/traccar/protocol/t55/T55ProtocolDecoder.java b/src/org/traccar/protocol/T55ProtocolDecoder.java
index 5b1558c00..d1ffc7a4d 100644
--- a/src/org/traccar/protocol/t55/T55ProtocolDecoder.java
+++ b/src/org/traccar/protocol/T55ProtocolDecoder.java
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.traccar.protocol.t55;
+package org.traccar.protocol;
import java.util.Calendar;
import java.util.GregorianCalendar;
diff --git a/src/org/traccar/protocol/tk103/Tk103ProtocolDecoder.java b/src/org/traccar/protocol/Tk103ProtocolDecoder.java
index db3280d91..3eab4a386 100644
--- a/src/org/traccar/protocol/tk103/Tk103ProtocolDecoder.java
+++ b/src/org/traccar/protocol/Tk103ProtocolDecoder.java
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.traccar.protocol.tk103;
+package org.traccar.protocol;
import java.util.Calendar;
import java.util.GregorianCalendar;
@@ -67,8 +67,6 @@ public class Tk103ProtocolDecoder extends GenericProtocolDecoder {
String sentence = (String) msg;
- // TODO: Send response (?)
-
// Parse message
Matcher parser = pattern.matcher(sentence);
if (!parser.matches()) {
diff --git a/src/org/traccar/protocol/xexun2/Xexun2ProtocolDecoder.java b/src/org/traccar/protocol/Xexun2ProtocolDecoder.java
index 62ec432ee..ce530785e 100644
--- a/src/org/traccar/protocol/xexun2/Xexun2ProtocolDecoder.java
+++ b/src/org/traccar/protocol/Xexun2ProtocolDecoder.java
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.traccar.protocol.xexun2;
+package org.traccar.protocol;
import java.util.Calendar;
import java.util.GregorianCalendar;
diff --git a/src/org/traccar/protocol/xexun/XexunFrameDecoder.java b/src/org/traccar/protocol/XexunFrameDecoder.java
index 6fd32a4c5..86f409b3e 100644
--- a/src/org/traccar/protocol/xexun/XexunFrameDecoder.java
+++ b/src/org/traccar/protocol/XexunFrameDecoder.java
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.traccar.protocol.xexun;
+package org.traccar.protocol;
import org.jboss.netty.handler.codec.frame.FrameDecoder;
import org.jboss.netty.channel.Channel;
diff --git a/src/org/traccar/protocol/xexun/XexunProtocolDecoder.java b/src/org/traccar/protocol/XexunProtocolDecoder.java
index 46b88f8a3..398b9a257 100644
--- a/src/org/traccar/protocol/xexun/XexunProtocolDecoder.java
+++ b/src/org/traccar/protocol/XexunProtocolDecoder.java
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package org.traccar.protocol.xexun;
+package org.traccar.protocol;
import java.util.Calendar;
import java.util.GregorianCalendar;