aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/org
diff options
context:
space:
mode:
authorjfunston83 <jfunston@gmail.com>2019-10-26 16:25:15 -0600
committerGitHub <noreply@github.com>2019-10-26 16:25:15 -0600
commit1a2c46e6f3d95babd6c4f41f6e1a6f8700390352 (patch)
tree510ab259a33a1b5130f198e4df4c86236dca945f /src/main/java/org
parentb5814bb9a2bd9f29bda1ece1bd51ae0ad07c076d (diff)
downloadtrackermap-server-1a2c46e6f3d95babd6c4f41f6e1a6f8700390352.tar.gz
trackermap-server-1a2c46e6f3d95babd6c4f41f6e1a6f8700390352.tar.bz2
trackermap-server-1a2c46e6f3d95babd6c4f41f6e1a6f8700390352.zip
Update DmtProtocolDecoder.java
Diffstat (limited to 'src/main/java/org')
-rw-r--r--src/main/java/org/traccar/protocol/DmtProtocolDecoder.java21
1 files changed, 10 insertions, 11 deletions
diff --git a/src/main/java/org/traccar/protocol/DmtProtocolDecoder.java b/src/main/java/org/traccar/protocol/DmtProtocolDecoder.java
index 63c120eed..c49f06d65 100644
--- a/src/main/java/org/traccar/protocol/DmtProtocolDecoder.java
+++ b/src/main/java/org/traccar/protocol/DmtProtocolDecoder.java
@@ -188,17 +188,6 @@ public class DmtProtocolDecoder extends BaseProtocolDecoder {
position.set(Position.KEY_OUTPUT, output);
position.set(Position.KEY_STATUS, status);
- } else if (fieldId == 27) {
-
- position.set(Position.KEY_ODOMETER, buf.readUnsignedIntLE());
- position.set(Position.KEY_HOURS, buf.readUnsignedIntLE() * 1000);
-
-
- } else if (fieldId == 26) {
-
- position.set(Position.KEY_ODOMETER_TRIP, buf.readUnsignedIntLE());
- position.set("TripHours", buf.readUnsignedIntLE() * 1000);
-
} else if (fieldId == 6) {
while (buf.readerIndex() < fieldEnd) {
@@ -223,6 +212,16 @@ public class DmtProtocolDecoder extends BaseProtocolDecoder {
}
}
+ } else if (fieldId == 26) {
+
+ position.set(Position.KEY_ODOMETER_TRIP, buf.readUnsignedIntLE());
+ position.set("tripHours", buf.readUnsignedIntLE() * 1000);
+
+ } else if (fieldId == 27) {
+
+ position.set(Position.KEY_ODOMETER, buf.readUnsignedIntLE());
+ position.set(Position.KEY_HOURS, buf.readUnsignedIntLE() * 1000);
+
}
buf.readerIndex(fieldEnd);