aboutsummaryrefslogtreecommitdiff
path: root/src/org
diff options
context:
space:
mode:
Diffstat (limited to 'src/org')
-rw-r--r--src/org/traccar/protocol/Gt06ProtocolDecoder.java11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/org/traccar/protocol/Gt06ProtocolDecoder.java b/src/org/traccar/protocol/Gt06ProtocolDecoder.java
index 3bbc09e2a..9431af030 100644
--- a/src/org/traccar/protocol/Gt06ProtocolDecoder.java
+++ b/src/org/traccar/protocol/Gt06ProtocolDecoder.java
@@ -739,23 +739,22 @@ public class Gt06ProtocolDecoder extends BaseProtocolDecoder {
getLastLocation(position, null);
if (subType == 0x00) {
-
position.set(Position.KEY_POWER, buf.readUnsignedShort() * 0.01);
return position;
-
} else if (subType == 0x05) {
-
int flags = buf.readUnsignedByte();
position.set(Position.KEY_DOOR, BitUtil.check(flags, 0));
position.set(Position.PREFIX_IO + 1, BitUtil.check(flags, 2));
return position;
-
+ } else if (subType == 0x0a) {
+ buf.skipBytes(8); // imei
+ buf.skipBytes(8); // imsi
+ position.set("iccid", ByteBufUtil.hexDump(buf.readSlice(8)));
+ return position;
} else if (subType == 0x0d) {
-
buf.skipBytes(6);
return decodeFuelData(position, buf.toString(
buf.readerIndex(), buf.readableBytes() - 4 - 2, StandardCharsets.US_ASCII));
-
}
} else if (type == MSG_X1_PHOTO_DATA) {