Not able to read cards (specifically) unless a card/tag is present while the board starts
Opened this issue · 6 comments
Step 1: Describe your environment
- OS version: W10 (latest)
- Arduino IDE version: 1.8.15
- MFRC522 Library version: 1.4.x
- Arduino device: nano v3 (clone)
- MFRC522 device: firmware is 2.0
Step 2: Describe the problem
Cards won't be read unless one is present when the program starts, if trying to read a card after some times it won't detect anything.
It works fine when using older versions (1.3.6 is the last to work)
Affected file(s) or example(s):
*All examples/any code using this library
*DumpInfo
Steps to reproduce:
- Reset the board
- Wait ~10-15s
- Place a card in front of the reader
Observed Results:
Nothing happens and it won't read anything until the board is reseted.
It works fine if only using tags or if a card/tag is present while it's rebooting.
Expected Results:
- Detect/dump the card informations to serial
Did you test 1.4.0
?
Yes, 1.3.6 was the last to work
Can you test current version without connected reset pin and replace code with:
MFRC522 mfrc522(SS_PIN, UNUSED_PIN); // Create MFRC522 instance
The arduino IDE and platformio won't build with UNUSED_PIN
Sry, ofc with scope MFRC522 mfrc522(SS_PIN, MFRC522::UNUSED_PIN);
Well I think I found the culprit, since then I bought a few more nano clones and it seems to work ok with them.
I was kind of freaking out trying to figure out what had changed since march until I realized it.
I still don't get why it's working only with 1.3.6 and earlier, but unplugging rst and putting MFRC522::UNUSED_PIN didn't do anything
edit: unfortunately trying to flash the bootloader from the other boards I didn't pay attention and blocked the nano, I remember it was quite an adventure to get them to work when new so I won't try today