Electrical – RFID anticollision with MFRC522

rfid

I'm trying to read multiple tags 'at once' using a LPC1768 mbed board and a RC522 module. I've spent some time reading about anticollision and I'm still confused about how it works and how it could help me achieve this task. I want to be able to read a maximum of 3 tags located near the RC522 module. I only need their IDs. I don't want to actually read them at once, but rather to find a way to make them respond in sequence if possible.

So far I had interesting results. With the mbed library example here that just prints the tag IDs, if I stack 2 tags and put them near the module, I get no IDs printed. However by varying the distance between the tags, I can find a sweet spot where both tags respond randomly. Can anybody tell me why this would happen ?

I want to know if it is possible to read multiple tags reliably with this module or with other technology (tags and readers).

Best Answer

(too long for a comment)

I'm not sure about "reliably". I'm using a cheap MFRC522 module and the antenna matching seems to be dubious. Thus you commonly get timeouts with multiple cards. The situation seems worse if you change the rx gain from the default (which the linked to code does). If I do that I get all sorts of corruption errors.

In addition, I've never gotten the MFRC522 to do anticollision. With two cards in the field I can get it to detect one card, Halt it and then detect the other immediately but it doesn't run any collision code. I thought the collision register setting would "auto-set to zero" any collision bit but changing that makes no difference. It's a mystery.

Edit: I see other people have gotten anticollision to happen. Thus I think it's an antenna issue or something else. With max antenna gain, I have to move the cards further away to get them to read.