aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/org/traccar/ServerManager.java12
-rw-r--r--src/org/traccar/protocol/MeitrackFrameDecoder.java49
-rw-r--r--src/org/traccar/protocol/MeitrackProtocolDecoder.java110
-rw-r--r--test/org/traccar/protocol/MeitrackProtocolDecoderTest.java52
4 files changed, 189 insertions, 34 deletions
diff --git a/src/org/traccar/ServerManager.java b/src/org/traccar/ServerManager.java
index 1a3cf0a00..6d65dad18 100644
--- a/src/org/traccar/ServerManager.java
+++ b/src/org/traccar/ServerManager.java
@@ -519,17 +519,15 @@ public class ServerManager {
private void initMeitrackServer(String protocol) throws SQLException {
if (isProtocolEnabled(properties, protocol)) {
- serverList.add(new TrackerServer(this, new ServerBootstrap(), protocol) {
+ TrackerServer server = new TrackerServer(this, new ServerBootstrap(), protocol) {
@Override
protected void addSpecificHandlers(ChannelPipeline pipeline) {
- byte delimiter[] = { (byte) '\r', (byte) '\n' };
- pipeline.addLast("frameDecoder",
- new DelimiterBasedFrameDecoder(1024, ChannelBuffers.wrappedBuffer(delimiter)));
- pipeline.addLast("stringDecoder", new StringDecoder());
- pipeline.addLast("stringEncoder", new StringEncoder());
+ pipeline.addLast("frameDecoder", new MeitrackFrameDecoder());
pipeline.addLast("objectDecoder", new MeitrackProtocolDecoder(ServerManager.this));
}
- });
+ };
+ server.setEndianness(ByteOrder.LITTLE_ENDIAN);
+ serverList.add(server);
}
}
diff --git a/src/org/traccar/protocol/MeitrackFrameDecoder.java b/src/org/traccar/protocol/MeitrackFrameDecoder.java
new file mode 100644
index 000000000..f7dda10e2
--- /dev/null
+++ b/src/org/traccar/protocol/MeitrackFrameDecoder.java
@@ -0,0 +1,49 @@
+/*
+ * Copyright 2014 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.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.traccar.protocol;
+
+import java.nio.charset.Charset;
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.jboss.netty.channel.Channel;
+import org.jboss.netty.channel.ChannelHandlerContext;
+import org.jboss.netty.handler.codec.frame.FrameDecoder;
+import org.traccar.helper.ChannelBufferTools;
+
+public class MeitrackFrameDecoder extends FrameDecoder {
+
+ @Override
+ protected Object decode(
+ ChannelHandlerContext ctx,
+ Channel channel,
+ ChannelBuffer buf) throws Exception {
+
+ if (buf.readableBytes() < 10) {
+ return null;
+ }
+
+ Integer index = ChannelBufferTools.find(buf, 0, buf.readableBytes(), ",");
+ if (index != null)
+ {
+ int length = index + Integer.valueOf(buf.toString(3, index - 3, Charset.defaultCharset()));
+ if (buf.readableBytes() >= length) {
+ return buf.readBytes(length);
+ }
+ }
+
+ return null;
+ }
+
+}
diff --git a/src/org/traccar/protocol/MeitrackProtocolDecoder.java b/src/org/traccar/protocol/MeitrackProtocolDecoder.java
index e2f31b207..ab12d510b 100644
--- a/src/org/traccar/protocol/MeitrackProtocolDecoder.java
+++ b/src/org/traccar/protocol/MeitrackProtocolDecoder.java
@@ -15,14 +15,20 @@
*/
package org.traccar.protocol;
+import java.nio.charset.Charset;
import java.util.Calendar;
+import java.util.Date;
+import java.util.LinkedList;
+import java.util.List;
import java.util.TimeZone;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
+import org.jboss.netty.buffer.ChannelBuffer;
import org.jboss.netty.channel.Channel;
import org.jboss.netty.channel.ChannelHandlerContext;
import org.traccar.BaseProtocolDecoder;
import org.traccar.ServerManager;
+import org.traccar.helper.ChannelBufferTools;
import org.traccar.helper.Log;
import org.traccar.model.ExtendedInfoFormatter;
import org.traccar.model.Position;
@@ -61,13 +67,10 @@ public class MeitrackProtocolDecoder extends BaseProtocolDecoder {
"(\\p{XDigit}+)," + // Power
".*"); // TODO: parse other stuff
- @Override
- protected Object decode(
- ChannelHandlerContext ctx, Channel channel, Object msg)
- throws Exception {
+ private Position decodeRegularMessage(ChannelBuffer buf) {
// Parse message
- String sentence = (String) msg;
+ String sentence = buf.toString(Charset.defaultCharset());
Matcher parser = pattern.matcher(sentence);
if (!parser.matches()) {
return null;
@@ -79,7 +82,7 @@ public class MeitrackProtocolDecoder extends BaseProtocolDecoder {
Integer index = 1;
- // Get device by IMEI
+ // Identification
String imei = parser.group(index++);
try {
position.setDeviceId(getDataManager().getDeviceByImei(imei).getId());
@@ -149,4 +152,99 @@ public class MeitrackProtocolDecoder extends BaseProtocolDecoder {
return position;
}
+ private List<Position> decodeBinaryMessage(ChannelBuffer buf) {
+ List<Position> positions = new LinkedList<Position>();
+
+ Integer index = ChannelBufferTools.find(buf, 0, buf.readableBytes(), ",");
+
+ // Identification
+ long deviceId;
+ String imei = buf.toString(index + 1, 15, Charset.defaultCharset());
+ try {
+ deviceId = getDataManager().getDeviceByImei(imei).getId();
+ } catch(Exception error) {
+ Log.warning("Unknown device - " + imei);
+ return null;
+ }
+
+ buf.skipBytes(index + 1 + 15 + 1 + 3 + 1 + 2 + 2 + 4);
+
+ while (buf.readableBytes() >= 0x34) {
+
+ Position position = new Position();
+ ExtendedInfoFormatter extendedInfo = new ExtendedInfoFormatter("meitrack");
+ position.setDeviceId(deviceId);
+
+ // Event
+ extendedInfo.set("event", buf.readUnsignedByte());
+
+ // Location
+ position.setLatitude(buf.readInt() * 0.000001);
+ position.setLongitude(buf.readInt() * 0.000001);
+
+ // Time (946684800 - timestamp for 2000-01-01)
+ position.setTime(new Date((946684800 + buf.readUnsignedInt()) * 1000));
+
+ // Validity
+ position.setValid(buf.readUnsignedByte() == 1);
+
+ // Satellites
+ extendedInfo.set("satellites", buf.readUnsignedByte());
+
+ // GSM Signal
+ extendedInfo.set("gsm", buf.readUnsignedByte());
+
+ // Speed
+ position.setSpeed(buf.readUnsignedShort() * 0.539957);
+
+ // Course
+ position.setCourse((double) buf.readUnsignedShort());
+
+ // HDOP
+ extendedInfo.set("hdop", buf.readUnsignedShort() * 0.1);
+
+ // Altitude
+ position.setAltitude((double) buf.readUnsignedShort());
+
+ // Other
+ extendedInfo.set("milage", buf.readUnsignedInt());
+ extendedInfo.set("runtime", buf.readUnsignedInt());
+ extendedInfo.set("cell",
+ buf.readUnsignedShort() + "|" + buf.readUnsignedShort() + "|" +
+ buf.readUnsignedShort() + "|" + buf.readUnsignedShort());
+ extendedInfo.set("state", buf.readUnsignedShort());
+
+ // ADC
+ extendedInfo.set("adc1", buf.readUnsignedShort());
+ extendedInfo.set("battery", buf.readUnsignedShort() * 0.01);
+ extendedInfo.set("power", buf.readUnsignedShort());
+
+ buf.readUnsignedInt(); // geo-fence
+
+ position.setExtendedInfo(extendedInfo.toString());
+ positions.add(position);
+ }
+
+ return positions;
+ }
+
+ @Override
+ protected Object decode(
+ ChannelHandlerContext ctx, Channel channel, Object msg)
+ throws Exception {
+
+ ChannelBuffer buf = (ChannelBuffer) msg;
+
+ // Find type
+ Integer index = ChannelBufferTools.find(buf, 0, buf.readableBytes(), ",");
+ index = ChannelBufferTools.find(buf, index + 1, buf.readableBytes(), ",");
+
+ String type = buf.toString(index + 1, 3, Charset.defaultCharset());
+ if (type.equals("CCC")) {
+ return decodeBinaryMessage(buf);
+ } else {
+ return decodeRegularMessage(buf);
+ }
+ }
+
}
diff --git a/test/org/traccar/protocol/MeitrackProtocolDecoderTest.java b/test/org/traccar/protocol/MeitrackProtocolDecoderTest.java
index 57a496798..43a2fbe95 100644
--- a/test/org/traccar/protocol/MeitrackProtocolDecoderTest.java
+++ b/test/org/traccar/protocol/MeitrackProtocolDecoderTest.java
@@ -1,8 +1,12 @@
package org.traccar.protocol;
+import java.nio.ByteOrder;
+import java.nio.charset.Charset;
+import org.jboss.netty.buffer.ChannelBuffers;
import org.traccar.helper.TestDataManager;
-import static org.traccar.helper.DecoderVerifier.verify;
import org.junit.Test;
+import org.traccar.helper.ChannelBufferTools;
+import static org.traccar.helper.DecoderVerifier.verify;
public class MeitrackProtocolDecoderTest {
@@ -12,36 +16,42 @@ public class MeitrackProtocolDecoderTest {
MeitrackProtocolDecoder decoder = new MeitrackProtocolDecoder(null);
decoder.setDataManager(new TestDataManager());
- verify(decoder.decode(null, null,
- "$$X138,862170010187175,AAA,35,-29.960365,-51.655455,130507201625,A,8,9,0,107,0.9,7,169322,126582,724|6|0547|132B,0000,0009|000A||0278|0000,*BE"));
+ verify(decoder.decode(null, null, ChannelBuffers.copiedBuffer(
+ "$$X138,862170010187175,AAA,35,-29.960365,-51.655455,130507201625,A,8,9,0,107,0.9,7,169322,126582,724|6|0547|132B,0000,0009|000A||0278|0000,*BE", Charset.defaultCharset())));
- verify(decoder.decode(null, null,
- "$$X138,862170010187175,AAA,35,-29.960365,-51.655455,130507201625,A,8,9,0,107,0.9,-7,169322,126582,724|6|0547|132B,0000,0009|000A||0278|0000,*BE"));
+ verify(decoder.decode(null, null, ChannelBuffers.copiedBuffer(
+ "$$X138,862170010187175,AAA,35,-29.960365,-51.655455,130507201625,A,8,9,0,107,0.9,-7,169322,126582,724|6|0547|132B,0000,0009|000A||0278|0000,*BE", Charset.defaultCharset())));
- verify(decoder.decode(null, null,
- "$$]138,012896000475498,AAA,35,-6.138255,106.910545,121205074600,A,5,18,0,0,0,49,3800,24826,510|10|0081|4F4F,0000,0011|0012|0010|0963|0000,,*94"));
+ verify(decoder.decode(null, null, ChannelBuffers.copiedBuffer(
+ "$$]138,012896000475498,AAA,35,-6.138255,106.910545,121205074600,A,5,18,0,0,0,49,3800,24826,510|10|0081|4F4F,0000,0011|0012|0010|0963|0000,,*94", Charset.defaultCharset())));
- verify(decoder.decode(null, null,
- "$$d138,012896000475498,AAA,35,-6.138255,106.910545,121205074819,A,7,18,0,0,0,49,3800,24965,510|10|0081|4F4F,0000,000D|0010|0012|0963|0000,,*BF"));
+ verify(decoder.decode(null, null, ChannelBuffers.copiedBuffer(
+ "$$d138,012896000475498,AAA,35,-6.138255,106.910545,121205074819,A,7,18,0,0,0,49,3800,24965,510|10|0081|4F4F,0000,000D|0010|0012|0963|0000,,*BF", Charset.defaultCharset())));
- verify(decoder.decode(null, null,
- "$$j138,012896000475498,AAA,35,-6.138306,106.910655,121205103708,A,3,11,0,0,1,36,4182,35025,510|10|0081|4F4F,0000,000A|000C|000A|0915|0000,,*BF"));
+ verify(decoder.decode(null, null, ChannelBuffers.copiedBuffer(
+ "$$j138,012896000475498,AAA,35,-6.138306,106.910655,121205103708,A,3,11,0,0,1,36,4182,35025,510|10|0081|4F4F,0000,000A|000C|000A|0915|0000,,*BF", Charset.defaultCharset())));
- verify(decoder.decode(null, null,
- "$$m139,012896005334567,AAA,35,-33.866423,151.190060,121208020649,A,7,27,0,32,4,13,6150,49517,505|2|0B67|5A6C,0000,0000|0000|0000|0977|0000,,*F1"));
+ verify(decoder.decode(null, null, ChannelBuffers.copiedBuffer(
+ "$$m139,012896005334567,AAA,35,-33.866423,151.190060,121208020649,A,7,27,0,32,4,13,6150,49517,505|2|0B67|5A6C,0000,0000|0000|0000|0977|0000,,*F1", Charset.defaultCharset())));
- verify(decoder.decode(null, null,
- "$$A141,012896005334567,AAA,35,-33.866543,151.190148,121209081758,A,6,27,0,16,1,48,65551,152784,505|2|0B5F|D9D3,0000,0000|0000|0000|0A39|0000,,*5B"));
+ verify(decoder.decode(null, null, ChannelBuffers.copiedBuffer(
+ "$$A141,012896005334567,AAA,35,-33.866543,151.190148,121209081758,A,6,27,0,16,1,48,65551,152784,505|2|0B5F|D9D3,0000,0000|0000|0000|0A39|0000,,*5B", Charset.defaultCharset())));
- verify(decoder.decode(null, null,
- "$$_128,861074020109479,AAA,34,22.512618,114.057065,090215000318,V,0,31,0,0,0,0,0,733,302|720|3EE4|BBB5,0000,0006|0006||028C|0000,*E3"));
+ verify(decoder.decode(null, null, ChannelBuffers.copiedBuffer(
+ "$$_128,861074020109479,AAA,34,22.512618,114.057065,090215000318,V,0,31,0,0,0,0,0,733,302|720|3EE4|BBB5,0000,0006|0006||028C|0000,*E3", Charset.defaultCharset())));
- verify(decoder.decode(null, null,
- "$$K146,013227004985762,AAA,35,28.618005,-81.246783,131101213828,A,9,22,0,209,1.1,23,80974,1187923,310|260|2A13|634E,0000,0000|0000|0000|09DA|0B34,,*51"));
+ verify(decoder.decode(null, null, ChannelBuffers.copiedBuffer(
+ "$$K146,013227004985762,AAA,35,28.618005,-81.246783,131101213828,A,9,22,0,209,1.1,23,80974,1187923,310|260|2A13|634E,0000,0000|0000|0000|09DA|0B34,,*51", Charset.defaultCharset())));
- verify(decoder.decode(null, null,
- "$$E150,013777001165479,AAA,35,10.296601,123.872115,140501161505,A,4,22,1,170,1.4,77,39097,393563,515|3|A0CC|ED96,0000,0008|0003|0000|09D5|0000,,,1,0009*1E"));
+ verify(decoder.decode(null, null, ChannelBuffers.copiedBuffer(
+ "$$E150,013777001165479,AAA,35,10.296601,123.872115,140501161505,A,4,22,1,170,1.4,77,39097,393563,515|3|A0CC|ED96,0000,0008|0003|0000|09D5|0000,,,1,0009*1E", Charset.defaultCharset())));
+ int[] buf1 = {0x24,0x24,0x47,0x39,0x37,0x30,0x2c,0x33,0x36,0x39,0x38,0x30,0x30,0x30,0x31,0x33,0x34,0x36,0x30,0x36,0x37,0x34,0x2c,0x43,0x43,0x43,0x2c,0x02,0x01,0x34,0x00,0x5b,0x00,0x00,0x00,0x01,0x0c,0xe3,0x04,0x03,0x5d,0xb9,0xe0,0x00,0xec,0x6f,0x59,0x1a,0x00,0x00,0x13,0x00,0x00,0x00,0x00,0x0c,0x00,0x18,0x01,0xed,0xb7,0x02,0x00,0xc9,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x01,0x00,0x03,0x00,0xa1,0x01,0xc2,0x04,0x00,0x00,0x00,0x00,0x01,0x0c,0xe3,0x04,0x03,0x5d,0xb9,0xe0,0x00,0xee,0x6f,0x59,0x1a,0x00,0x00,0x13,0x00,0x00,0x00,0x00,0x0c,0x00,0x18,0x01,0xed,0xb7,0x02,0x00,0xca,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x01,0x00,0x03,0x00,0xa1,0x01,0xc2,0x04,0x00,0x00,0x00,0x00,0x01,0x0c,0xe3,0x04,0x03,0x5d,0xb9,0xe0,0x00,0xef,0x6f,0x59,0x1a,0x00,0x00,0x13,0x00,0x00,0x00,0x00,0x0c,0x00,0x18,0x01,0xed,0xb7,0x02,0x00,0xcc,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x01,0x00,0x03,0x00,0xa1,0x01,0xc2,0x04,0x00,0x00,0x00,0x00,0x02,0x0c,0xe3,0x04,0x03,0x5d,0xb9,0xe0,0x00,0xf7,0x6f,0x59,0x1a,0x00,0x00,0x16,0x00,0x00,0x00,0x00,0x0c,0x00,0x18,0x01,0xed,0xb7,0x02,0x00,0xd3,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x02,0x00,0x03,0x00,0xa1,0x01,0xbf,0x04,0x00,0x00,0x00,0x00,0x0a,0x0c,0xe3,0x04,0x03,0x5d,0xb9,0xe0,0x00,0xf7,0x6f,0x59,0x1a,0x00,0x00,0x16,0x00,0x00,0x00,0x00,0x0c,0x00,0x18,0x01,0xed,0xb7,0x02,0x00,0xd4,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x00,0x00,0x03,0x00,0xa1,0x01,0xbf,0x04,0x00,0x00,0x00,0x00,0x02,0x0c,0xe3,0x04,0x03,0x5d,0xb9,0xe0,0x00,0xfb,0x6f,0x59,0x1a,0x00,0x00,0x16,0x00,0x00,0x00,0x00,0x0c,0x00,0x18,0x01,0xed,0xb7,0x02,0x00,0xd8,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x02,0x00,0x03,0x00,0xa1,0x01,0x76,0x04,0x00,0x00,0x00,0x00,0x18,0x0c,0xe3,0x04,0x03,0x5d,0xb9,0xe0,0x00,0xfc,0x6f,0x59,0x1a,0x00,0x00,0x12,0x00,0x00,0x00,0x00,0x00,0x00,0x8c,0x00,0xed,0xb7,0x02,0x00,0xd9,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x02,0x00,0x03,0x00,0xa1,0x01,0x76,0x04,0x00,0x00,0x00,0x00,0x19,0xb1,0xe2,0x04,0x03,0x23,0xb9,0xe0,0x00,0x0b,0x70,0x59,0x1a,0x01,0x05,0x15,0x06,0x00,0xbb,0x00,0x12,0x00,0x29,0x01,0xed,0xb7,0x02,0x00,0xe7,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x02,0x00,0x03,0x00,0xa2,0x01,0x70,0x05,0x00,0x00,0x00,0x00,0x20,0x23,0xe3,0x04,0x03,0x1f,0xb9,0xe0,0x00,0x10,0x70,0x59,0x1a,0x01,0x06,0x15,0x07,0x00,0x27,0x01,0x0d,0x00,0x16,0x01,0xfc,0xb7,0x02,0x00,0xec,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x02,0x00,0x03,0x00,0xa2,0x01,0x80,0x05,0x00,0x00,0x00,0x00,0x20,0x1f,0xe3,0x04,0x03,0x02,0xb9,0xe0,0x00,0x11,0x70,0x59,0x1a,0x01,0x06,0x15,0x09,0x00,0x19,0x01,0x0d,0x00,0x15,0x01,0xfe,0xb7,0x02,0x00,0xed,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x02,0x00,0x03,0x00,0xa2,0x01,0x80,0x05,0x00,0x00,0x00,0x00,0x20,0x18,0xe3,0x04,0x03,0xdc,0xb8,0xe0,0x00,0x12,0x70,0x59,0x1a,0x01,0x06,0x15,0x0b,0x00,0x11,0x01,0x0d,0x00,0x15,0x01,0x00,0xb8,0x02,0x00,0xee,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x02,0x00,0x03,0x00,0xa2,0x01,0x80,0x05,0x00,0x00,0x00,0x00,0x20,0x36,0xe3,0x04,0x03,0x45,0xb8,0xe0,0x00,0x15,0x70,0x59,0x1a,0x01,0x07,0x15,0x0b,0x00,0x2d,0x01,0x0b,0x00,0x13,0x01,0x0a,0xb8,0x02,0x00,0xf1,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x02,0x00,0x03,0x00,0xa2,0x01,0x80,0x05,0x00,0x00,0x00,0x00,0x20,0x53,0xe3,0x04,0x03,0x26,0xb8,0xe0,0x00,0x16,0x70,0x59,0x1a,0x01,0x07,0x15,0x0d,0x00,0x41,0x01,0x0b,0x00,0x13,0x01,0x0e,0xb8,0x02,0x00,0xf2,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x02,0x00,0x03,0x00,0xa2,0x01,0x80,0x05,0x00,0x00,0x00,0x00,0x20,0x70,0xe3,0x04,0x03,0x10,0xb8,0xe0,0x00,0x17,0x70,0x59,0x1a,0x01,0x07,0x15,0x0e,0x00,0x4f,0x01,0x0b,0x00,0x13,0x01,0x11,0xb8,0x02,0x00,0xf3,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x02,0x00,0x03,0x00,0xa2,0x01,0x80,0x05,0x00,0x00,0x00,0x00,0x20,0x95,0xe3,0x04,0x03,0x06,0xb8,0xe0,0x00,0x18,0x70,0x59,0x1a,0x01,0x07,0x15,0x0d,0x00,0x5a,0x01,0x0b,0x00,0x14,0x01,0x15,0xb8,0x02,0x00,0xf4,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x02,0x00,0x03,0x00,0xa2,0x01,0x80,0x05,0x00,0x00,0x00,0x00,0x20,0xb3,0xe3,0x04,0x03,0x05,0xb8,0xe0,0x00,0x19,0x70,0x59,0x1a,0x01,0x07,0x15,0x0b,0x00,0x60,0x01,0x0b,0x00,0x14,0x01,0x18,0xb8,0x02,0x00,0xf5,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x02,0x00,0x03,0x00,0xa2,0x01,0x83,0x05,0x00,0x00,0x00,0x00,0x20,0xcf,0xe3,0x04,0x03,0x08,0xb8,0xe0,0x00,0x1a,0x70,0x59,0x1a,0x01,0x07,0x15,0x0b,0x00,0x66,0x01,0x0b,0x00,0x14,0x01,0x1b,0xb8,0x02,0x00,0xf6,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x02,0x00,0x03,0x00,0xa2,0x01,0x83,0x05,0x00,0x00,0x00,0x00,0x20,0xee,0xe3,0x04,0x03,0x0c,0xb8,0xe0,0x00,0x1b,0x70,0x59,0x1a,0x01,0x06,0x17,0x0b,0x00,0x04,0x00,0x0d,0x00,0x14,0x01,0x1e,0xb8,0x02,0x00,0xf7,0x6d,0x01,0x00,0xe6,0x00,0x01,0x00,0x48,0x38,0x57,0x65,0x02,0x00,0x03,0x00,0xa2,0x01,0x83,0x05,0x00,0x00,0x00,0x00,0x2a,0x62,0x35,0x0d,0x0a};
+ verify(decoder.decode(null, null, ChannelBuffers.wrappedBuffer(ByteOrder.LITTLE_ENDIAN, ChannelBufferTools.convertArray(buf1))));
+
+ //int[] buf2 = {0x24,0x24,0x47,0x39,0x37,0x30,0x2C,0x33,0x36,0x39,0x38,0x30,0x30,0x30,0x31,0x33,0x32,0x32,0x30,0x30,0x32,0x30,0x2C,0x43,0x43,0x43,0x2C,0x02,0x01,0x34,0x00,0x54,0x00,0x00,0x00,0x1F,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0xF5,0x74,0xA4,0x19,0x00,0x06,0x14,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0x81,0x08,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x00,0x00,0x00,0x00,0x79,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x04,0x00,0x00,0x80,0x04,0x00,0x00,0x80,0x04,0x00,0x00,0x80,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFE,0xEE,0x00,0x00,0x1F,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0xCD,0x7A,0xA4,0x19,0x00,0x06,0x14,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0x26,0x0D,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x00,0x00,0x00,0x00,0x78,0x01,0xA4,0x03,0x00,0x00,0x00,0x00,0x1F,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0x25,0x7D,0xA4,0x19,0x00,0x06,0x17,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0x7E,0x0F,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x00,0x00,0x00,0x00,0x77,0x01,0xA4,0x03,0x00,0x00,0x00,0x00,0x1F,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0x7E,0x7F,0xA4,0x19,0x00,0x00,0x16,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0xD6,0x11,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x00,0x00,0x00,0x00,0x77,0x01,0xA6,0x03,0x00,0x00,0x00,0x00,0x1F,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0xD6,0x81,0xA4,0x19,0x00,0x00,0x17,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0x2E,0x14,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x00,0x00,0x00,0x00,0x76,0x01,0xA6,0x03,0x00,0x00,0x00,0x00,0x1F,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0x2E,0x84,0xA4,0x19,0x00,0x00,0x15,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0x86,0x16,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x00,0x00,0x00,0x00,0x75,0x01,0xA6,0x03,0x00,0x00,0x00,0x00,0x1F,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0x7A,0x83,0xA5,0x19,0x00,0x06,0x0E,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0x65,0x19,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0xEA,0xB7,0x00,0x00,0x00,0x00,0x73,0x01,0xA4,0x03,0x00,0x00,0x00,0x00,0x1F,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0xD2,0x85,0xA5,0x19,0x00,0x06,0x0E,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0xBD,0x1B,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x00,0x00,0x00,0x00,0x71,0x01,0xA2,0x03,0x00,0x00,0x00,0x00,0x1F,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0x2B,0x88,0xA5,0x19,0x00,0x06,0x0F,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0x15,0x1E,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x00,0x00,0x00,0x00,0x70,0x01,0xA2,0x03,0x00,0x00,0x00,0x00,0x1F,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0x83,0x8A,0xA5,0x19,0x00,0x06,0x13,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0x6D,0x20,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x00,0x00,0x00,0x00,0x70,0x01,0xA6,0x03,0x00,0x00,0x00,0x00,0x1F,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0xDB,0x8C,0xA5,0x19,0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0xC5,0x22,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x00,0x00,0x00,0x00,0x6E,0x01,0xA6,0x03,0x00,0x00,0x00,0x00,0x1F,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0x34,0x8F,0xA5,0x19,0x00,0x00,0x16,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0x1D,0x25,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x00,0x00,0x00,0x00,0x64,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0xD9,0xD9,0xA5,0x19,0x00,0x06,0x00,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0x78,0x28,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x54,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0x2D,0xDC,0xA5,0x19,0x00,0x06,0x16,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0xCC,0x2A,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x02,0x00,0x00,0x00,0x7B,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x0A,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0x5B,0xDD,0xA5,0x19,0x00,0x06,0x13,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0xF9,0x2B,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x00,0x00,0x00,0x00,0x7C,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0x5C,0xDD,0xA5,0x19,0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0xFB,0x2B,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x02,0x00,0x00,0x00,0x7C,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x1F,0x0E,0x88,0x57,0x01,0x22,0x5F,0xCC,0x06,0x85,0xDE,0xA5,0x19,0x00,0x00,0x13,0x00,0x00,0x00,0x00,0x12,0x00,0x28,0x00,0x12,0x39,0x0C,0x00,0x24,0x2D,0x00,0x00,0xCC,0x01,0x00,0x00,0x62,0x30,0x54,0x46,0x02,0x00,0x00,0x00,0x7D,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x2A,0x35,0x62,0x0D,0x0A};
+ //verify(decoder.decode(null, null, ChannelBuffers.wrappedBuffer(ByteOrder.LITTLE_ENDIAN, ChannelBufferTools.convertArray(buf2))));
+
}
}