diff options
author | Christoph Krey <krey.christoph@gmail.com> | 2017-06-25 08:10:20 +0200 |
---|---|---|
committer | Christoph Krey <krey.christoph@gmail.com> | 2017-06-25 08:10:20 +0200 |
commit | e450c36389fed6e32a6b7e9fb47c739a425e4df2 (patch) | |
tree | 82daf3cda9a259c19a3256da8e0df800ab3e978e /src/org | |
parent | 6790c1b7e78543d427d8b93105e56e719f8ab6af (diff) | |
download | trackermap-server-e450c36389fed6e32a6b7e9fb47c739a425e4df2.tar.gz trackermap-server-e450c36389fed6e32a6b7e9fb47c739a425e4df2.tar.bz2 trackermap-server-e450c36389fed6e32a6b7e9fb47c739a425e4df2.zip |
style fixes
Diffstat (limited to 'src/org')
-rw-r--r-- | src/org/traccar/protocol/Tk103ProtocolEncoder.java | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/src/org/traccar/protocol/Tk103ProtocolEncoder.java b/src/org/traccar/protocol/Tk103ProtocolEncoder.java index 66cfc8dd2..9e49b6ff1 100644 --- a/src/org/traccar/protocol/Tk103ProtocolEncoder.java +++ b/src/org/traccar/protocol/Tk103ProtocolEncoder.java @@ -28,30 +28,21 @@ public class Tk103ProtocolEncoder extends StringProtocolEncoder { switch (command.getType()) { case Command.TYPE_GET_VERSION: return formatCommand(command, "({%s}AP07)", Command.KEY_UNIQUE_ID); - case Command.TYPE_REBOOT_DEVICE: return formatCommand(command, "({%s}AT00)", Command.KEY_UNIQUE_ID); - case Command.TYPE_SET_ODOMETER: return formatCommand(command, "({%s}AX01)", Command.KEY_UNIQUE_ID); - case Command.TYPE_POSITION_SINGLE: return formatCommand(command, "({%s}AP00)", Command.KEY_UNIQUE_ID); - case Command.TYPE_POSITION_PERIODIC: - return formatCommand(command, "({%s}AR00%s0000)", - Command.KEY_UNIQUE_ID, + return formatCommand(command, "({%s}AR00%s0000)", Command.KEY_UNIQUE_ID, String.format("%04X", command.getInteger(Command.KEY_FREQUENCY))); - case Command.TYPE_POSITION_STOP: return formatCommand(command, "({%s}AR0000000000)", Command.KEY_UNIQUE_ID); - case Command.TYPE_ENGINE_STOP: return formatCommand(command, "({%s}AV011)", Command.KEY_UNIQUE_ID); - case Command.TYPE_ENGINE_RESUME: return formatCommand(command, "({%s}AV010)", Command.KEY_UNIQUE_ID); - default: Log.warning(new UnsupportedOperationException(command.getType())); break; |