RFID Card reader Library for Arduino
What is it?
This library (with examples) is designed to be integrated in projects using RFID Card or Tag reader. It retrieves the card ID. It is also possible to attach your own function to be launched every time a card or tag is detected (asynchronously with interrupt).
This library has been tested with 125KHz devices but it should be usable with any kind of RFID Card reader.
How to install
Download latest release
On your Arduino IDE, click "Sketch" menu and then "Include Library > Add .ZIP Libraries"
You can now use the library for your project or launch an example ("File > Examples")
How to connect the RFID Card Reader to your Arduino
RFID Card Readers have a lot of pins but only 5 are really important:
|RFID Card Reader||Arduino|
|Tx||Rx (For Arduino Mega, use Rx1)|
On most RFID card reader, it is also needed to attach antenna pins to your antenna.
Important note: Since Arduino Mega supports 3 UART channels, it is possible to select the one you want by changing "RFIDCardReaderPort1" to "RFIDCardReaderPort2" or "RFIDCardReaderPort3" in RFIDCardReader.h.
Two examples are provided with this library:
Check if a tag or card has been detected every second (synchronous)
Show tag or card when detected (asynchronous with interrupt)
This project is under MIT license. This means you can use it as you want (just don't delete the library header).
If you want to add more examples or improve the library, just create a pull request with proper commit message and right wrapping.