aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/protocol/MeiligaoProtocolDecoder.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2015-07-31 16:52:22 +1200
committerAnton Tananaev <anton.tananaev@gmail.com>2015-07-31 16:52:22 +1200
commit43181f1ddd7cb1f4162e5b24988a0c442aca14a3 (patch)
tree6dcc4f8138488d2db15da15d7a6796fad0c22271 /src/org/traccar/protocol/MeiligaoProtocolDecoder.java
parentc65c1876c0186ee5d4f88b81300e28f89a3d5597 (diff)
downloadtrackermap-server-43181f1ddd7cb1f4162e5b24988a0c442aca14a3.tar.gz
trackermap-server-43181f1ddd7cb1f4162e5b24988a0c442aca14a3.tar.bz2
trackermap-server-43181f1ddd7cb1f4162e5b24988a0c442aca14a3.zip
Support multiple rfid cards
Diffstat (limited to 'src/org/traccar/protocol/MeiligaoProtocolDecoder.java')
-rw-r--r--src/org/traccar/protocol/MeiligaoProtocolDecoder.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/org/traccar/protocol/MeiligaoProtocolDecoder.java b/src/org/traccar/protocol/MeiligaoProtocolDecoder.java
index 07209a046..43142744c 100644
--- a/src/org/traccar/protocol/MeiligaoProtocolDecoder.java
+++ b/src/org/traccar/protocol/MeiligaoProtocolDecoder.java
@@ -199,7 +199,9 @@ public class MeiligaoProtocolDecoder extends BaseProtocolDecoder {
for (int i = 0; i < 15; i++) {
long rfid = buf.readUnsignedInt();
if (rfid != 0) {
- position.set(Event.KEY_RFID, String.format("%010d", rfid));
+ String card = String.format("%010d", rfid);
+ position.set("card" + (i + 1), card);
+ position.set(Event.KEY_RFID, card);
}
}
}