From ba7185395e518a127cfbf4c3fa8f882f82a8efc1 Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Wed, 6 Feb 2013 13:14:49 +1300 Subject: Fix H02 protocol pattern --- src/org/traccar/protocol/H02ProtocolDecoder.java | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) (limited to 'src/org/traccar') diff --git a/src/org/traccar/protocol/H02ProtocolDecoder.java b/src/org/traccar/protocol/H02ProtocolDecoder.java index d09343bcd..1163ac75d 100644 --- a/src/org/traccar/protocol/H02ProtocolDecoder.java +++ b/src/org/traccar/protocol/H02ProtocolDecoder.java @@ -1,5 +1,5 @@ /* - * Copyright 2012 Anton Tananaev (anton.tananaev@gmail.com) + * Copyright 2012 - 2013 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. @@ -26,14 +26,8 @@ import org.traccar.ServerManager; import org.traccar.helper.Log; import org.traccar.model.Position; -/** - * H02 tracker protocol decoder - */ public class H02ProtocolDecoder extends BaseProtocolDecoder { - /** - * Initialize - */ public H02ProtocolDecoder(ServerManager serverManager) { super(serverManager); } @@ -47,7 +41,7 @@ public class H02ProtocolDecoder extends BaseProtocolDecoder { "V\\d," + // Version? "(\\d{2})(\\d{2})(\\d{2})," + // Time (HHMMSS) "([AV])," + // Validity - "(\\d{2})(\\d{2}.\\d{4})," + // Latitude (DDMM.MMMM) + "(\\d+)(\\d{2}.\\d{4})," + // Latitude (DDMM.MMMM) "([NS])," + "(\\d+)(\\d{2}.\\d{4})," + // Longitude (DDMM.MMMM) "([EW])," + @@ -56,9 +50,7 @@ public class H02ProtocolDecoder extends BaseProtocolDecoder { "(\\d{2})(\\d{2})(\\d{2})," + // Date (DDMMYY) ".*"); - /** - * Decode message - */ + @Override protected Object decode( ChannelHandlerContext ctx, Channel channel, Object msg) throws Exception { -- cgit v1.2.3