CIRCUITKAR
ProductsBlogToolsAboutContact
CIRCUITKAR

Components for Builders.

IG

Explore

  • Products
  • Blog
  • Tools & Calculators
  • About
  • Contact
  • Track Order

Payments

Secured by Razorpay

UPI, Cards, Net Banking & Wallets supported at launch.

© 2025 Circuitkar. GST Registered. Silvassa, India.

All articles
attendance-systemrfidrc522ds3231esp32iotproject

Attendance System Hardware Guide

Circuitkar Team · 24 May 2026

Attendance System Hardware Guide

An RFID-based attendance system is one of the most commonly built electronics projects — for good reason. It is practical, demonstrable, and teaches RFID, real-time clocking, data logging, and network communication in one build. Here is the hardware breakdown.

The Core Hardware Stack

RFID Module: RC522

The RC522 (MFRC522) reads 13.56 MHz Mifare cards and key fobs. Each card has a unique 4-byte UID that identifies the cardholder. SPI interface to ESP32. Supply: 3.3V (important — do not connect to 5V). Price: ₹70–120 per module. Include a pack of 10 Mifare 1K cards (₹20–40 each) or key fobs for cardholders.

Wiring to ESP32: SDA→GPIO5, SCK→GPIO18, MOSI→GPIO23, MISO→GPIO19, RST→GPIO22, 3.3V→3.3V, GND→GND.

Real-Time Clock: DS3231

The DS3231 is a temperature-compensated RTC (TCXO) with an I2C interface and a battery backup CR2032 coin cell. Accuracy: ±2 ppm (about ±1 minute per year). Far more accurate than software-only RTC implementations. Price: ₹80–150 per module.

Without a DS3231, your attendance timestamps will drift significantly, especially after power cuts. The coin cell keeps time for 3–5 years without mains power. Wiring: SDA→GPIO21, SCL→GPIO22 (shared I2C bus with other devices). I2C address: 0x68.

Microcontroller: ESP32

ESP32 handles SPI (for RC522), I2C (for DS3231 and LCD), and WiFi for cloud logging. The dual-core architecture lets you handle card reads on one core and WiFi communication on the other without blocking. Price: ₹280–350.

SD Card Module (Offline Logging)

A microSD card module (SPI interface, ₹60–100) stores attendance records locally. Essential for systems where WiFi connectivity is unreliable — data syncs to the cloud when connectivity is restored. Use a 2–8 GB microSD card formatted as FAT32.

Note: SD card uses SPI — the same bus as RC522. Both can share SCK, MOSI, MISO lines but need separate SS (Chip Select) pins. RC522 → GPIO5, SD → GPIO4 (or any free GPIO).

Display: 16×2 I2C LCD

Shows real-time clock, "Card Detected", and cardholder name after a successful card read. I2C interface uses only GPIO21 and GPIO22 (shared with DS3231 — I2C allows multiple devices). Price: ₹80–120. Address: 0x27 or 0x3F (use I2C scanner sketch to confirm).

Buzzer and LED Feedback

Active buzzer (₹15–30): short beep for successful card read, long beep for unknown card. Green LED for access granted, red LED for denied. Simple transistor drivers (BC547 + 1kΩ base resistor) for buzzer; direct GPIO drive for LEDs with 330Ω current-limiting resistors.

Cloud Logging Options

Google Sheets via Apps Script: Free, no server needed. ESP32 sends HTTP POST to Google Apps Script webhook, which appends a row to a spreadsheet. Works well for 1–50 card swipes per day. Latency: 1–3 seconds per log.

MQTT to local server: Raspberry Pi or VPS running Mosquitto MQTT broker and Node-RED. Attendance records stored in InfluxDB or SQLite. Better for high-volume systems.

Firebase Realtime Database: Free tier supports up to 1 GB storage and 10 GB/month transfer. Good for real-time dashboards visible to teachers or HR.

Full Component List

  • ESP32 DevKit V1 — ₹280–350
  • RC522 RFID module — ₹70–120
  • Mifare 1K cards × 10 — ₹200–400
  • DS3231 RTC module with CR2032 cell — ₹80–150
  • microSD card module + 4 GB card — ₹60–100
  • 16×2 I2C LCD — ₹80–120
  • Active buzzer — ₹15–30
  • Green + Red LED, 330Ω resistors — ₹20
  • 5V/1A power supply — ₹100–150
  • Enclosure — ₹150–250

Total: ₹1,100–1,700

All components available at Circuitkar. Order the RC522 + Mifare card combo for the best value.

Share: X LinkedIn

Related Articles

ESP32 for Small Factory Automation: A Practical Starter Guide

How small Indian manufacturers are using ESP32 for basic factory monitoring and control — real use cases, limitations, and what it costs to get started.

Home Automation Bill of Materials: Complete Component List with Prices

Full BOM for a 3-room smart home — every component, quantity, price range, and total cost estimate for a DIY home automation installation.

Why Cheap Components Fail and What to Buy Instead

The real reasons why no-name ESP32s, clone sensors, and unbranded relay boards fail — and how to identify quality components before buying.