From b04758893af970e7954571771c1e6c136d472f20 Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Wed, 14 Mar 2018 07:11:35 +1300 Subject: Additional Xirgo events --- src/org/traccar/protocol/XirgoProtocolDecoder.java | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) (limited to 'src') diff --git a/src/org/traccar/protocol/XirgoProtocolDecoder.java b/src/org/traccar/protocol/XirgoProtocolDecoder.java index 1a753cb3e..461503af1 100644 --- a/src/org/traccar/protocol/XirgoProtocolDecoder.java +++ b/src/org/traccar/protocol/XirgoProtocolDecoder.java @@ -100,6 +100,18 @@ public class XirgoProtocolDecoder extends BaseProtocolDecoder { position.set(Position.KEY_EVENT, event); switch (event) { + case 4001: + case 4003: + case 6011: + case 6013: + position.set(Position.KEY_IGNITION, true); + break; + case 4002: + case 4004: + case 6012: + case 6014: + position.set(Position.KEY_IGNITION, false); + break; case 4005: position.set(Position.KEY_CHARGE, false); break; @@ -121,14 +133,6 @@ public class XirgoProtocolDecoder extends BaseProtocolDecoder { case 6010: position.set(Position.KEY_ALARM, Position.ALARM_POWER_RESTORED); break; - case 6011: - case 6013: - position.set(Position.KEY_IGNITION, true); - break; - case 6012: - case 6014: - position.set(Position.KEY_IGNITION, false); - break; case 6016: position.set(Position.KEY_ALARM, Position.ALARM_IDLE); break; -- cgit v1.2.3