Ep. 60 - Arduino RFID Tutorial & Implementation, RC522 Module Read Example Project
HTML-код
- Опубликовано: 14 июл 2024
- Contribute to the channel:
/ ee_enthusiast
In this tutorial we are playing with the RFID-RC522 Module in order to implement an RFID tag scanner / reader. I walk you through an example which allows the user to create an array of “master” cards which would open the door. Other cards are read by the system and give an appropriate output as well, indicating that the card was not correct for this door.
Get in touch:
Facebook: / eeenthusiast
Twitter: / ee_enthusiast
Website: eeenthusiast.com
GitHub: github.com/VRomanov89
Personal website: vladromanov.com
Software:
github.com/VRomanov89/EEEnthu...
Relevant Links:
RFID Arduino Library: github.com/miguelbalboa/rfid
Relevant Search Terms:
EEEnthusiast, Vlad Romanov, Volodymyr Romanov, Arduino, Arduino, arduino rfid, arduino rfid tutorial, arduino rfid reader, arduino rfid project, arduino rfid reader writer, arduino rfid rc522, arduino rfid code, arduino rfid tracking, arduino rc522, arduino rc522 library, arduino rc522 tutorial, arduino rc522 example
Good example of using the rfid.
When using multiple rfid tags in your example, you must have a break statement in the code.
if (strID == RFID_Correct[i]) {
scanStateFlag = 1;
found = 1;
}
Should be:
if (strID == RFID_Correct[i]) {
scanStateFlag = 1;
found = 1;
break;//(Important to have if we use more than 1 rfid tag)
}
Defining more than 1 rfid tag:
//Using 2 rfid tags
#define RFID_AccessCards 2
String RFID_Correct[RFID_AccessCards] = {"2c:d7:c3:a5", "2c:d7:c3:b8"};
//Using 4 rfid tags
#define RFID_AccessCards 4
String RFID_Correct[RFID_AccessCards] = {"2c:d7:c3:a5", "2c:d7:c3:b8""1c:d7:c3:a5", "1c:d7:c3:b8"};
very good nice one
Great tutorial thanks, Its very helpful
Just a quick bug-fix
I think that the"int found = 0;" needs to be before the "for" loop when using an array with more than one element. In your example code 'found' gets reset on each cycle of the for loop, consequently only the last string in the array is considered.
You can add a break statment to if you use more than 1 rfid tag.
Like this:
if (strID == RFID_Correct[i]) {
scanStateFlag = 1;
found = 1;
break;//(Important to have if we use more than 1 rfid tag)
}
There is a typo on your blog.The link to RFIDScanner.ino. It says...Arduino LCD Menu.
Blog site:
eeenthusiast.com/arduino-rfid-tutorial-implementation-rc522-module-read-example-project/
Typo:
The full program we will be implementing in this project is available here: Arduino LCD Menu. The Arduino IDE used is version 1.6.9.
Hey look Java! (On the whiteboard in the background)
Java is terrible
What does this line do? What is it supposed to do?
MFRC522::MIFARE_Key key;
I not see any reference in your code to "key".
Hola amigo, pero tengo un problema al compilar la biblioteca de Miguel Balboa, y me sale este error no sé cómo resolverlo, el agradecimiento a alguien que me ayude
MFRC522 clase no tiene un elemento llamado 'PICC_Halta'
Idea,
Export the rfid's codes to an EXCEL file with check in and out time.
how to import this data on excel