aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/org/traccar/model/Command.java5
-rw-r--r--src/org/traccar/protocol/Gps103ProtocolEncoder.java4
2 files changed, 7 insertions, 2 deletions
diff --git a/src/org/traccar/model/Command.java b/src/org/traccar/model/Command.java
index 4558d31ce..842cceac4 100644
--- a/src/org/traccar/model/Command.java
+++ b/src/org/traccar/model/Command.java
@@ -27,10 +27,11 @@ public class Command implements Factory {
public static final String TYPE_POSITION_STOP = "positionStop";
public static final String TYPE_ENGINE_STOP = "engineStop";
public static final String TYPE_ENGINE_RESUME = "engineResume";
-
+ public static final String TYPE_ALARM_ARM = "alarmArm";
+ public static final String TYPE_ALARM_DISARM = "alarmDisarm";
+
public static final String KEY_UNIQUE_ID = "uniqueId";
public static final String KEY_FREQUENCY = "frequency";
public static final String KEY_DEVICE_PASSWORD = "devicePassword";
-
}
diff --git a/src/org/traccar/protocol/Gps103ProtocolEncoder.java b/src/org/traccar/protocol/Gps103ProtocolEncoder.java
index df0b50954..147451e3b 100644
--- a/src/org/traccar/protocol/Gps103ProtocolEncoder.java
+++ b/src/org/traccar/protocol/Gps103ProtocolEncoder.java
@@ -51,6 +51,10 @@ public class Gps103ProtocolEncoder extends StringProtocolEncoder implements Stri
return formatCommand(command, "**,imei:{%s},J;", Command.KEY_UNIQUE_ID);
case Command.TYPE_ENGINE_RESUME:
return formatCommand(command, "**,imei:{%s},K;", Command.KEY_UNIQUE_ID);
+ case Command.TYPE_ALARM_ARM:
+ return formatCommand(command, "**,imei:{%s},L;", Command.KEY_UNIQUE_ID);
+ case Command.TYPE_ALARM_DISARM:
+ return formatCommand(command, "**,imei:{%s},M;", Command.KEY_UNIQUE_ID);
}
return null;