Build Your Own RFID + Fingerprint Attendance Robot!
A fun, step-by-step Arduino robotics project that scans ID cards and fingerprints to mark "Present!" — perfect for science fairs, school clubs, and curious young makers.
Have you ever wondered how your school gate or office door knows exactly who walked in — just by tapping a card or scanning a finger? That's RFID (Radio Frequency Identification) and biometric (fingerprint) technology working together, and today YOU are going to build a mini version of it!
This project combines an RFID card reader and a fingerprint sensor with an Arduino brain to create a smart attendance machine. Tap your card, scan your thumb, and watch your name (or ID) pop up as "Present" — just like magic, except it's science!
①How Does an Attendance Robot Think?
Every RFID card has a tiny chip with a unique number. The RFID reader sends out a radio wave, the card "wakes up," and whispers its secret number back. The Arduino checks if that number is on its friend-list!
Your fingerprint is one-of-a-kind, just like a snowflake! The fingerprint sensor takes a tiny picture of the ridges and swirls on your finger and matches it against fingerprints it has already learned.
When either check matches, the Arduino lights up a green LED, says "Welcome!" on the screen, and logs the attendance. If it doesn't match, a red LED blinks and it asks you to try again. That's the whole brainpower of our robot!
②Parts You'll Need
③The Circuit Diagram
Here's a simplified map of how every part connects to the Arduino Uno. Don't worry — we'll go wire-by-wire in the next section!
Simplified circuit map — exact pins are listed in the wiring table below.
④Let's Connect Everything!
Connect the RFID Reader (RC522)
The RC522 talks to the Arduino using a protocol called SPI. Connect it like this:
SDA → D10 SCK → D13 MOSI → D11 MISO → D12 RST → D9 GND → GND 3.3V → 3.3V
Connect the Fingerprint Sensor
This sensor talks over Serial (TX/RX), so we connect it to two digital pins using "software serial":
TX → D2 RX → D3 VCC → 5V GND → GND
Connect the LCD Display (I2C)
The I2C module makes this super easy — only 4 wires needed!
SDA → A4 SCL → A5 VCC → 5V GND → GND
Connect LEDs and Buzzer
Green LED → D6 (with 220Ω resistor) Red LED → D7 (with 220Ω resistor) Buzzer → D8
Connect the short leg (negative) of each LED to GND on the breadboard.
Power It Up!
Plug your Arduino into the computer using a USB cable. You should see a tiny light turn on — that means it's alive and ready for code!
⑤The Arduino Code
First, open the Arduino IDE and install these libraries via Sketch → Include Library → Manage Libraries: MFRC522, Adafruit Fingerprint Sensor Library, and LiquidCrystal_I2C.
// Smart RFID + Fingerprint Attendance Robot // Beginner-friendly version with comments! #include <SPI.h> #include <MFRC522.h> #include <Wire.h> #include <LiquidCrystal_I2C.h> #include <SoftwareSerial.h> #include <Adafruit_Fingerprint.h> // ----- Pin Setup ----- #define SS_PIN 10 #define RST_PIN 9 #define GREEN_LED 6 #define RED_LED 7 #define BUZZER 8 MFRC522 rfid(SS_PIN, RST_PIN); LiquidCrystal_I2C lcd(0x27, 16, 2); SoftwareSerial fingerSerial(2, 3); // RX, TX Adafruit_Fingerprint finger = Adafruit_Fingerprint(&fingerSerial); // Add your own card's secret ID here! (see Testing section) String knownCardID = "A1 B2 C3 D4"; void setup() { Serial.begin(9600); SPI.begin(); rfid.PCD_Init(); finger.begin(57600); lcd.init(); lcd.backlight(); pinMode(GREEN_LED, OUTPUT); pinMode(RED_LED, OUTPUT); pinMode(BUZZER, OUTPUT); lcd.setCursor(0, 0); lcd.print("Tap Card or"); lcd.setCursor(0, 1); lcd.print("Scan Finger.."); } void loop() { checkRFID(); checkFingerprint(); } // ----- RFID Check ----- void checkRFID() { if (!rfid.PICC_IsNewCardPresent()) return; if (!rfid.PICC_ReadCardSerial()) return; String cardID = ""; for (byte i = 0; i < rfid.uid.size; i++) { cardID += String(rfid.uid.uidByte[i], HEX); cardID += " "; } cardID.toUpperCase(); if (cardID == knownCardID) { showSuccess("Card Verified!"); } else { showFail("Unknown Card"); } rfid.PICC_HaltA(); } // ----- Fingerprint Check ----- void checkFingerprint() { if (finger.getImage() != FINGERPRINT_OK) return; if (finger.image2Tz() != FINGERPRINT_OK) return; if (finger.fingerSearch() == FINGERPRINT_OK) { showSuccess("Finger Match!"); } else { showFail("No Match"); } } // ----- Helper Functions ----- void showSuccess(String msg) { lcd.clear(); lcd.setCursor(0, 0); lcd.print(msg); lcd.setCursor(0, 1); lcd.print("Welcome! :)"); digitalWrite(GREEN_LED, HIGH); tone(BUZZER, 1000, 200); delay(1500); digitalWrite(GREEN_LED, LOW); resetScreen(); } void showFail(String msg) { lcd.clear(); lcd.setCursor(0, 0); lcd.print(msg); lcd.setCursor(0, 1); lcd.print("Try Again!"); digitalWrite(RED_LED, HIGH); tone(BUZZER, 300, 400); delay(1500); digitalWrite(RED_LED, LOW); resetScreen(); } void resetScreen() { lcd.clear(); lcd.setCursor(0, 0); lcd.print("Tap Card or"); lcd.setCursor(0, 1); lcd.print("Scan Finger.."); }
setup() as the robot waking up and getting ready, and loop() as it constantly looking around asking "Did someone tap a card? Did someone scan a finger?" forever and ever, like a never-ending game of "Simon Says, Check Again!"
⑥Finding Your Card's Secret ID
Every RFID card has its own unique ID number, and your code needs to know it! Here's how to find yours:
A1 B2 C3 D4.knownCardID line near the top of the program, then upload again. Now your robot recognizes YOUR card!Enrolling Your Fingerprint
Most fingerprint sensor libraries come with a ready-made example sketch called "enroll" (find it under File → Examples → Adafruit Fingerprint Sensor Library). Run that first, follow the on-screen prompts to scan your finger twice, and it'll save your fingerprint into the sensor's own memory — no extra code needed!
⑦Frequently Asked Questions
Can I use this for my real school attendance?
This is a fantastic learning prototype! For a real classroom, you'd want to add an SD card module or Wi-Fi module (like ESP8266) to save attendance permanently and even send it to a spreadsheet.
What if my LCD shows weird symbols instead of words?
This usually means the I2C address is wrong. Try changing 0x27 in the code to 0x3F — that's the other common address for these modules.
Do I need to know how to code already?
Not at all! This project is designed for beginners. Just copy the code, follow the wiring steps carefully, and read the comments (the green text starting with //) to understand what each part does.
Is it safe to touch the wires and battery?
Yes — Arduino projects use very low, safe voltages (5V and below). Just always have an adult nearby for soldering or using sharp tools, and never connect things while it's plugged into power.

Comments
Post a Comment