aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2017-03-16 01:43:47 +1300
committerAnton Tananaev <anton.tananaev@gmail.com>2017-03-16 01:43:47 +1300
commit37a023ca4db10bc48fcc9eca9daddcf8d2701ef9 (patch)
tree24ace8ac2864b12eb1afeb11e444f7695ac73463 /src
parent38c12eb011e47c131a9b1e47e2b29901270057b1 (diff)
downloadtrackermap-server-37a023ca4db10bc48fcc9eca9daddcf8d2701ef9.tar.gz
trackermap-server-37a023ca4db10bc48fcc9eca9daddcf8d2701ef9.tar.bz2
trackermap-server-37a023ca4db10bc48fcc9eca9daddcf8d2701ef9.zip
Implement H02 power cut alarm
Diffstat (limited to 'src')
-rw-r--r--src/org/traccar/protocol/H02ProtocolDecoder.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/org/traccar/protocol/H02ProtocolDecoder.java b/src/org/traccar/protocol/H02ProtocolDecoder.java
index a717ddc4d..6ab997b86 100644
--- a/src/org/traccar/protocol/H02ProtocolDecoder.java
+++ b/src/org/traccar/protocol/H02ProtocolDecoder.java
@@ -73,6 +73,8 @@ public class H02ProtocolDecoder extends BaseProtocolDecoder {
position.set(Position.KEY_ALARM, Position.ALARM_SOS);
} else if (!BitUtil.check(status, 2)) {
position.set(Position.KEY_ALARM, Position.ALARM_OVERSPEED);
+ } else if (!BitUtil.check(status, 19)) {
+ position.set(Position.KEY_ALARM, Position.ALARM_POWER_CUT);
}
position.set(Position.KEY_IGNITION, BitUtil.check(status, 10));