diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2023-05-10 09:27:31 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-10 09:27:31 -0700 |
commit | 73e9051548baacda28e3ccd827c260da484f1b0c (patch) | |
tree | 3e548550659de142005514657f20de62f14cd14f /src/main/java | |
parent | ae1205dfdded530e4cdf7bb665fe52cf197c33be (diff) | |
parent | c3fe534d28c35d252ca97d99ae1b4d1fbe87d2f0 (diff) | |
download | trackermap-server-73e9051548baacda28e3ccd827c260da484f1b0c.tar.gz trackermap-server-73e9051548baacda28e3ccd827c260da484f1b0c.tar.bz2 trackermap-server-73e9051548baacda28e3ccd827c260da484f1b0c.zip |
Merge pull request #5083 from zeustd/patch-1
Add VL502 Alarms
Diffstat (limited to 'src/main/java')
-rw-r--r-- | src/main/java/org/traccar/protocol/HuabaoProtocolDecoder.java | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/main/java/org/traccar/protocol/HuabaoProtocolDecoder.java b/src/main/java/org/traccar/protocol/HuabaoProtocolDecoder.java index ed71861a5..e6980dc28 100644 --- a/src/main/java/org/traccar/protocol/HuabaoProtocolDecoder.java +++ b/src/main/java/org/traccar/protocol/HuabaoProtocolDecoder.java @@ -934,6 +934,12 @@ public class HuabaoProtocolDecoder extends BaseProtocolDecoder { int id = buf.readUnsignedByte(); int length = buf.readUnsignedByte(); switch (id) { + case 0x01: + position.set(Position.KEY_ALARM, Position.ALARM_POWER_RESTORED); + break; + case 0x02: + position.set(Position.KEY_ALARM, Position.ALARM_POWER_CUT); + break; case 0x1A: position.set(Position.KEY_ALARM, Position.ALARM_ACCELERATION); break; @@ -951,6 +957,15 @@ public class HuabaoProtocolDecoder extends BaseProtocolDecoder { case 0x23: position.set(Position.KEY_ALARM, Position.ALARM_FATIGUE_DRIVING); break; + case 0x26: + case 0x27: + case 0x28: + position.set(Position.KEY_ALARM, Position.ALARM_ACCIDENT); + break; + case 0x31: + case 0x32: + position.set(Position.KEY_ALARM, Position.ALARM_DOOR); + break; default: break; } |