From 5c7b1668d524aee47885caa90740b72395b6f6d6 Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Sat, 20 Dec 2014 11:00:56 +1300 Subject: Fix T55 identification (fix #1008) --- src/org/traccar/protocol/T55ProtocolDecoder.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/org') diff --git a/src/org/traccar/protocol/T55ProtocolDecoder.java b/src/org/traccar/protocol/T55ProtocolDecoder.java index 0f2da7d65..25b7f367f 100644 --- a/src/org/traccar/protocol/T55ProtocolDecoder.java +++ b/src/org/traccar/protocol/T55ProtocolDecoder.java @@ -101,7 +101,11 @@ public class T55ProtocolDecoder extends BaseProtocolDecoder { if (!sentence.startsWith("$") && sentence.contains("$")) { int index = sentence.indexOf("$"); - identify(sentence.substring(0, index)); + String id = sentence.substring(0, index); + if (id.endsWith(",")) { + id = id.substring(0, id.length() - 1); + } + identify(id); sentence = sentence.substring(index); } -- cgit v1.2.3