Read RFID Cards Using Android Device, Arduino and MFRC522 Module, Part 1 : Hardware

Droiduino Blog
4 min readSep 21, 2020

--

Update : We’ve been compiling this series in Chronopad. It is presented in chronological order so that you know the correct sequence of the stories.

MFRC522 module is an RFID reader module that can be used with an Arduino Board. It can be used to read RFID cards, tags, or stickers with a working frequency of 13.56Mhz. It means this reader can also read from NFC tags and stickers since they have the same working frequency. You can get the detailed specifications on this website.

But before that, some disclaimers: I am using a clone Arduino board , HC05 and MFRC522 module of unknown Chinese manufacturers. Since the quality may vary between manufacturers, the tutorial below may or may not work for you.

MFRC522 RFID Module

The goal of this project is to read information from RFID tags and send it via Bluetooth to a paired Android phone to display the RFID information (UID). This post will explain how to assemble the hardware and the next post will describe how to create a custom Android app to display RFID information.

Architecture and Data Flow

RFID information will be read by MFRC522 module and the Arduino board will convert the information into a data sequence that can be parsed by an Android phone. This Arduino board will also send the sequence to a paired Android phone via Bluetooth using HC05 module.

Components

The required components to assembly the hardware are as follows:

  1. Arduino Uno (Arduino Mega ADK can also be used, however, the pinout connections are different from Uno’s)
  2. MFRC522 module
  3. HC05 module
  4. Some jumper cables
  5. Arduino IDE and connection cable

Pinout Connections

The connections between Uno and both MFRC522 and HC05 module can be seen in the illustration below. One pin on MFRC522 (IRQ) does not need to be connected.

This is the connection that works for me. You might want to experiment a bit if this connection doesn’t work for you (please see the disclaimer above).

Arduino Code

For the code, we will use an open source library called MFRC522 which documentation and source code can be found in Github. This library does all the heavy lifting to initialize an MFRC522 module and read information from RFID tags. We only need to process the information into something readable. Library implementation is shown in the code below which is also available in Github.

Making Sure It is Working

We will use Arduino IDE’s Serial Monitor to make sure everything works. If the reading is successful and Arduino can process the information, then the UID sequence will be printed to Serial Monitor. At the same time, if the HC05 Bluetooth module is connected, it also transmits the se

The characters “<” and “>” each mark the beginning and end of the UID sequence. This will be used later when our <custom app> is parsing the UID sequence for display.

Compatible RFID Tags

This RFID reader project has successfully read various forms of RFID tags, as long as the working frequency is 13.56Mhz.

These are various RFID tags that can be read by this project. It ranges from RFID Cards to RFID Stickers.

What’s Next

This hardware needs to have some kind of display to process and show RFID information, and then use that information to do further functions. For that, we will use a custom Android app. Udemy offers a great lesson for creating your own Android based Bluetooth app that can talk with your Arduino projects, even if you don’t have prior knowledge on Android programming.

--

--

Droiduino Blog
Droiduino Blog

Written by Droiduino Blog

Droiduino is about sharing knowledge in the realm of Android app programming, Arduino project creation and using R for processing data.

No responses yet