diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/org/traccar/model/Command.java | 1 | ||||
-rw-r--r-- | src/org/traccar/protocol/Gps103Protocol.java | 3 | ||||
-rw-r--r-- | src/org/traccar/protocol/Gps103ProtocolEncoder.java | 2 |
3 files changed, 5 insertions, 1 deletions
diff --git a/src/org/traccar/model/Command.java b/src/org/traccar/model/Command.java index 99525a02b..abca811a2 100644 --- a/src/org/traccar/model/Command.java +++ b/src/org/traccar/model/Command.java @@ -25,6 +25,7 @@ public class Command extends Extensible implements Factory { public static final String TYPE_ALARM_ARM = "alarmArm"; public static final String TYPE_ALARM_DISARM = "alarmDisarm"; public static final String TYPE_SET_TIMEZONE = "setTimezone"; + public static final String TYPE_REQUEST_PHOTO = "requestPhoto"; public static final String KEY_UNIQUE_ID = "uniqueId"; public static final String KEY_FREQUENCY = "frequency"; diff --git a/src/org/traccar/protocol/Gps103Protocol.java b/src/org/traccar/protocol/Gps103Protocol.java index dcac04c5b..35515e2e7 100644 --- a/src/org/traccar/protocol/Gps103Protocol.java +++ b/src/org/traccar/protocol/Gps103Protocol.java @@ -35,7 +35,8 @@ public class Gps103Protocol extends BaseProtocol { Command.TYPE_POSITION_PERIODIC, Command.TYPE_POSITION_STOP, Command.TYPE_ENGINE_STOP, - Command.TYPE_ENGINE_RESUME); + Command.TYPE_ENGINE_RESUME, + Command.TYPE_REQUEST_PHOTO); } @Override diff --git a/src/org/traccar/protocol/Gps103ProtocolEncoder.java b/src/org/traccar/protocol/Gps103ProtocolEncoder.java index 9f0df8761..23942e554 100644 --- a/src/org/traccar/protocol/Gps103ProtocolEncoder.java +++ b/src/org/traccar/protocol/Gps103ProtocolEncoder.java @@ -57,6 +57,8 @@ public class Gps103ProtocolEncoder extends StringProtocolEncoder implements Stri 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); + case Command.TYPE_REQUEST_PHOTO: + return formatCommand(command, "**,imei:{%s},160", Command.KEY_UNIQUE_ID); default: Log.warning(new UnsupportedOperationException(command.getType())); break; |