diff options
author | Frédéric Christ <dev@ntr.li> | 2024-06-12 19:23:27 +0200 |
---|---|---|
committer | Frédéric Christ <dev@ntr.li> | 2024-06-12 21:01:07 +0200 |
commit | 42eb4009587bb654d60abe2eed499259f20bbb2f (patch) | |
tree | 2891b9eacc8407342e2c0c22387c186ffb39f96d | |
parent | 0bb9e28cf771a60db06a33b4967a2049bea72af5 (diff) | |
download | trackermap-server-42eb4009587bb654d60abe2eed499259f20bbb2f.tar.gz trackermap-server-42eb4009587bb654d60abe2eed499259f20bbb2f.tar.bz2 trackermap-server-42eb4009587bb654d60abe2eed499259f20bbb2f.zip |
tlt2h protocol: Enable UDP
I verified this successfully working with a Mictrack MT700 set to UDP.
-rw-r--r-- | src/main/java/org/traccar/protocol/Tlt2hProtocol.java | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/main/java/org/traccar/protocol/Tlt2hProtocol.java b/src/main/java/org/traccar/protocol/Tlt2hProtocol.java index 6763e9b6b..4f306bcf5 100644 --- a/src/main/java/org/traccar/protocol/Tlt2hProtocol.java +++ b/src/main/java/org/traccar/protocol/Tlt2hProtocol.java @@ -38,6 +38,14 @@ public class Tlt2hProtocol extends BaseProtocol { pipeline.addLast(new Tlt2hProtocolDecoder(Tlt2hProtocol.this)); } }); + addServer(new TrackerServer(config, getName(), true) { + @Override + protected void addProtocolHandlers(PipelineBuilder pipeline, Config config) { + pipeline.addLast(new StringDecoder()); + pipeline.addLast(new StringEncoder()); + pipeline.addLast(new Tlt2hProtocolDecoder(Tlt2hProtocol.this)); + } + }); } } |