diff options
Diffstat (limited to 'src/org/traccar/protocol/MeiligaoProtocolDecoder.java')
-rw-r--r-- | src/org/traccar/protocol/MeiligaoProtocolDecoder.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/org/traccar/protocol/MeiligaoProtocolDecoder.java b/src/org/traccar/protocol/MeiligaoProtocolDecoder.java index 72c28297c..2b1ea9434 100644 --- a/src/org/traccar/protocol/MeiligaoProtocolDecoder.java +++ b/src/org/traccar/protocol/MeiligaoProtocolDecoder.java @@ -59,7 +59,7 @@ public class MeiligaoProtocolDecoder extends BaseProtocolDecoder { "\\|(\\p{XDigit}{2})" + // GSM "\\|(\\p{XDigit}{8})|" + // Odometer "(\\p{XDigit}{9})" + // Odometer - "(?:\\|(\\p{XDigit}{5}))?)?)?)?)?" + // RFID + "(?:\\|(\\p{XDigit}{5,}))?)?)?)?)?" + // RFID ".*"); private static final int MSG_HEARTBEAT = 0x0001; @@ -279,7 +279,10 @@ public class MeiligaoProtocolDecoder extends BaseProtocolDecoder { } // RFID - position.set(Event.KEY_RFID, parser.group(index++)); + String rfid = parser.group(index++); + if (rfid != null) { + position.set(Event.KEY_RFID, Integer.parseInt(rfid, 16)); + } return position; } |