diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2018-07-02 00:56:11 -0700 |
---|---|---|
committer | Anton Tananaev <anton.tananaev@gmail.com> | 2018-07-02 00:56:11 -0700 |
commit | 3ceee5bc5d3d5c94045e1f2ff14e0cd801bfa5d4 (patch) | |
tree | 8648e2ca9ee736374684f1c825027cf6160d41eb /src/org | |
parent | b2a95573bd75e8fac4f44c7bfebf353df89976f3 (diff) | |
download | traccar-server-3ceee5bc5d3d5c94045e1f2ff14e0cd801bfa5d4.tar.gz traccar-server-3ceee5bc5d3d5c94045e1f2ff14e0cd801bfa5d4.tar.bz2 traccar-server-3ceee5bc5d3d5c94045e1f2ff14e0cd801bfa5d4.zip |
Decode Aplicom event data
Diffstat (limited to 'src/org')
-rw-r--r-- | src/org/traccar/protocol/AplicomProtocolDecoder.java | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/org/traccar/protocol/AplicomProtocolDecoder.java b/src/org/traccar/protocol/AplicomProtocolDecoder.java index 54b15700a..14ab83788 100644 --- a/src/org/traccar/protocol/AplicomProtocolDecoder.java +++ b/src/org/traccar/protocol/AplicomProtocolDecoder.java @@ -102,6 +102,18 @@ public class AplicomProtocolDecoder extends BaseProtocolDecoder { buf.readUnsignedInt(); buf.readUnsignedByte(); break; + case 119: + StringBuilder sb = new StringBuilder(); + while (buf.isReadable()) { + char c = (char) buf.readByte(); + if (c >= 0x20) { + sb.append(c); + } else { + break; + } + } + position.set("eventData", sb.toString()); + break; case 121: case 142: buf.readLong(); |