diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2016-12-30 22:47:25 +1300 |
---|---|---|
committer | Anton Tananaev <anton.tananaev@gmail.com> | 2016-12-30 22:47:25 +1300 |
commit | de60cf9d75d669a8078df32f7e11bf7af1970777 (patch) | |
tree | 16378c05ad2d716c4768f1f9209f8e4e12534053 /src/org/traccar/protocol | |
parent | 3d9499fab03dc616d060c00047ec24a6163ea2fa (diff) | |
download | trackermap-server-de60cf9d75d669a8078df32f7e11bf7af1970777.tar.gz trackermap-server-de60cf9d75d669a8078df32f7e11bf7af1970777.tar.bz2 trackermap-server-de60cf9d75d669a8078df32f7e11bf7af1970777.zip |
Add more MiniFinder commands
Diffstat (limited to 'src/org/traccar/protocol')
-rw-r--r-- | src/org/traccar/protocol/MiniFinderProtocol.java | 4 | ||||
-rw-r--r-- | src/org/traccar/protocol/MiniFinderProtocolEncoder.java | 4 |
2 files changed, 7 insertions, 1 deletions
diff --git a/src/org/traccar/protocol/MiniFinderProtocol.java b/src/org/traccar/protocol/MiniFinderProtocol.java index 71a956d0f..3bbdc1beb 100644 --- a/src/org/traccar/protocol/MiniFinderProtocol.java +++ b/src/org/traccar/protocol/MiniFinderProtocol.java @@ -35,11 +35,13 @@ public class MiniFinderProtocol extends BaseProtocol { Command.TYPE_VOICE_MONITORING, Command.TYPE_ALARM_SPEED, Command.TYPE_ALARM_GEOFENCE, + Command.TYPE_ALARM_VIBRATION, Command.TYPE_SET_AGPS, Command.TYPE_ALARM_FALL, Command.TYPE_MODE_POWER_SAVING, Command.TYPE_MODE_DEEP_SLEEP, - Command.TYPE_SOS_NUMBER); + Command.TYPE_SOS_NUMBER, + Command.TYPE_SET_INDICATOR); } @Override diff --git a/src/org/traccar/protocol/MiniFinderProtocolEncoder.java b/src/org/traccar/protocol/MiniFinderProtocolEncoder.java index 96079745c..e5c43e29a 100644 --- a/src/org/traccar/protocol/MiniFinderProtocolEncoder.java +++ b/src/org/traccar/protocol/MiniFinderProtocolEncoder.java @@ -58,6 +58,8 @@ public class MiniFinderProtocolEncoder extends StringProtocolEncoder implements return formatCommand(command, "{%s}J1{%s}", Command.KEY_DEVICE_PASSWORD, Command.KEY_DATA); case Command.TYPE_ALARM_GEOFENCE: return formatCommand(command, "{%s}R1{%s}", Command.KEY_DEVICE_PASSWORD, Command.KEY_RADIUS); + case Command.TYPE_ALARM_VIBRATION: + return formatCommand(command, "{%s}W1,{%s}", Command.KEY_DEVICE_PASSWORD, Command.KEY_DATA); case Command.TYPE_SET_AGPS: return formatCommand(command, "{%s}AGPS{%s}", this, Command.KEY_DEVICE_PASSWORD, Command.KEY_ENABLE); case Command.TYPE_ALARM_FALL: @@ -69,6 +71,8 @@ public class MiniFinderProtocolEncoder extends StringProtocolEncoder implements case Command.TYPE_SOS_NUMBER: return formatCommand(command, "{%s}{%s}1,{%s}", this, Command.KEY_DEVICE_PASSWORD, Command.KEY_INDEX, Command.KEY_PHONE); + case Command.TYPE_SET_INDICATOR: + return formatCommand(command, "{%s}LED{%s}", Command.KEY_DEVICE_PASSWORD, Command.KEY_DATA); default: Log.warning(new UnsupportedOperationException(command.getType())); return null; |