diff options
Diffstat (limited to 'src/org/traccar/protocol/NoranProtocol.java')
-rw-r--r-- | src/org/traccar/protocol/NoranProtocol.java | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/org/traccar/protocol/NoranProtocol.java b/src/org/traccar/protocol/NoranProtocol.java index 6c16fe6bc..6bc15296e 100644 --- a/src/org/traccar/protocol/NoranProtocol.java +++ b/src/org/traccar/protocol/NoranProtocol.java @@ -19,6 +19,7 @@ import org.jboss.netty.bootstrap.ConnectionlessBootstrap; import org.jboss.netty.channel.ChannelPipeline; import org.traccar.BaseProtocol; import org.traccar.TrackerServer; +import org.traccar.model.Command; import java.nio.ByteOrder; import java.util.List; @@ -27,6 +28,12 @@ public class NoranProtocol extends BaseProtocol { public NoranProtocol() { super("noran"); + setSupportedCommands( + Command.TYPE_POSITION_SINGLE, + Command.TYPE_POSITION_PERIODIC, + Command.TYPE_POSITION_STOP, + Command.TYPE_ENGINE_STOP, + Command.TYPE_ENGINE_RESUME); } @Override @@ -34,6 +41,7 @@ public class NoranProtocol extends BaseProtocol { TrackerServer server = new TrackerServer(new ConnectionlessBootstrap(), this.getName()) { @Override protected void addSpecificHandlers(ChannelPipeline pipeline) { + pipeline.addLast("objectEncoder", new NoranProtocolEncoder()); pipeline.addLast("objectDecoder", new NoranProtocolDecoder(NoranProtocol.this)); } }; |