diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2021-02-28 16:40:39 -0800 |
---|---|---|
committer | Anton Tananaev <anton.tananaev@gmail.com> | 2021-02-28 16:40:39 -0800 |
commit | b2f389803ffaed47082a6f770c5b19df98cecac2 (patch) | |
tree | daa6023b153cc2e7625e0a884ea2ee4c524393e8 /src/main/java/org/traccar/protocol/KhdProtocolDecoder.java | |
parent | 166852601ab6b4f0e7917ae7c53a216ce3ffb054 (diff) | |
download | trackermap-server-b2f389803ffaed47082a6f770c5b19df98cecac2.tar.gz trackermap-server-b2f389803ffaed47082a6f770c5b19df98cecac2.tar.bz2 trackermap-server-b2f389803ffaed47082a6f770c5b19df98cecac2.zip |
Commands and result support
Diffstat (limited to 'src/main/java/org/traccar/protocol/KhdProtocolDecoder.java')
-rw-r--r-- | src/main/java/org/traccar/protocol/KhdProtocolDecoder.java | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/main/java/org/traccar/protocol/KhdProtocolDecoder.java b/src/main/java/org/traccar/protocol/KhdProtocolDecoder.java index 16ad616ed..1f3798bd2 100644 --- a/src/main/java/org/traccar/protocol/KhdProtocolDecoder.java +++ b/src/main/java/org/traccar/protocol/KhdProtocolDecoder.java @@ -125,11 +125,15 @@ public class KhdProtocolDecoder extends BaseProtocolDecoder { position.set(Position.KEY_ODOMETER, buf.readUnsignedMedium()); position.set(Position.KEY_STATUS, buf.readUnsignedInt()); - position.set(Position.KEY_HDOP, buf.readUnsignedByte()); - position.set(Position.KEY_VDOP, buf.readUnsignedByte()); - position.set(Position.KEY_SATELLITES, buf.readUnsignedByte()); - buf.skipBytes(5); // other location data + buf.readUnsignedShort(); + buf.readUnsignedByte(); + buf.readUnsignedByte(); + buf.readUnsignedByte(); + buf.readUnsignedByte(); + buf.readUnsignedByte(); + + position.set(Position.KEY_RESULT, buf.readUnsignedByte()); if (type == MSG_PERIPHERAL) { |