From b5814bb9a2bd9f29bda1ece1bd51ae0ad07c076d Mon Sep 17 00:00:00 2001 From: jfunston83 Date: Sat, 26 Oct 2019 16:09:40 -0600 Subject: Update DmtProtocolDecoder.java Fixed to use engine hours attribute. DMT devices send these values in seconds, converted to ms for the Hours values. --- src/main/java/org/traccar/protocol/DmtProtocolDecoder.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/main/java/org/traccar/protocol/DmtProtocolDecoder.java b/src/main/java/org/traccar/protocol/DmtProtocolDecoder.java index 1dfa6bcd7..63c120eed 100644 --- a/src/main/java/org/traccar/protocol/DmtProtocolDecoder.java +++ b/src/main/java/org/traccar/protocol/DmtProtocolDecoder.java @@ -191,13 +191,13 @@ public class DmtProtocolDecoder extends BaseProtocolDecoder { } else if (fieldId == 27) { position.set(Position.KEY_ODOMETER, buf.readUnsignedIntLE()); - position.set("DeviceRunTime", buf.readUnsignedIntLE()); + position.set(Position.KEY_HOURS, buf.readUnsignedIntLE() * 1000); } else if (fieldId == 26) { position.set(Position.KEY_ODOMETER_TRIP, buf.readUnsignedIntLE()); - position.set("TripRunTime", buf.readUnsignedIntLE()); + position.set("TripHours", buf.readUnsignedIntLE() * 1000); } else if (fieldId == 6) { -- cgit v1.2.3