aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2019-04-10 23:27:27 -0700
committerAnton Tananaev <anton.tananaev@gmail.com>2019-04-10 23:27:27 -0700
commitffdf0984b87e2ee3154ccb3d013a6bbf2a629783 (patch)
tree551007052049b2691c8eb3944e84d02c7df6145d
parentc6aabdaba867ba2ad408b78a2fe0ec5979b6e1af (diff)
downloadtrackermap-server-ffdf0984b87e2ee3154ccb3d013a6bbf2a629783.tar.gz
trackermap-server-ffdf0984b87e2ee3154ccb3d013a6bbf2a629783.tar.bz2
trackermap-server-ffdf0984b87e2ee3154ccb3d013a6bbf2a629783.zip
Decode digital outputs
-rw-r--r--src/main/java/org/traccar/protocol/T800xProtocolDecoder.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/main/java/org/traccar/protocol/T800xProtocolDecoder.java b/src/main/java/org/traccar/protocol/T800xProtocolDecoder.java
index 28fd7937d..96fb7f96a 100644
--- a/src/main/java/org/traccar/protocol/T800xProtocolDecoder.java
+++ b/src/main/java/org/traccar/protocol/T800xProtocolDecoder.java
@@ -163,6 +163,9 @@ public class T800xProtocolDecoder extends BaseProtocolDecoder {
int io = buf.readUnsignedShort();
position.set(Position.KEY_IGNITION, BitUtil.check(io, 14));
position.set("ac", BitUtil.check(io, 13));
+ for (int i = 0; i <= 2; i++) {
+ position.set(Position.PREFIX_OUT + (i + 1), BitUtil.check(io, 7 + i));
+ }
position.set(Position.PREFIX_ADC + 1, buf.readUnsignedShort());
position.set(Position.PREFIX_ADC + 2, buf.readUnsignedShort());