Arduino Attendence Logger





Introduction: Arduino Attendence Logger

I am always wondering how many hours per month I spend working on my projects. Hopfully I was designing atendance logger for local company and imidiatelly saw potential in this simple logger. First prototype was made with Arduino and was only a proof of concept. Becouse of that company allowed me to share this project.

System that company is using today grew up Arduino's performance and got many more features today.

RFID module was used in initial phase of development. NFC module could be used instead.

Step 1: What You'll Need?

We will need:

- Arduino Mega 2560

- Ethernet Shield W5100 with microSD slot

- Tiny RTC module

- RFID module RC522 with some tags

- 9V PSU and project housing

- Ethernet cable, breadboard and some wires

- LED (green and red or double colored) with 220 ohm resistor

- 8 ohm speaker (or buzzer)

Step 2: Plans

Before westarted with designing our system we set some demands:

- Every employee must be able to have his own tag and must be identified with it.

- For every employee there displaying history must be enabled.

- Hour or arrival and departure from work must be saved. In addition working hours must be calculated from time of arrival and time of departure.

Defining a problem

We can divide problem into three sub problems: identifying employee, saving history and calculating working hours, display of history. First sub problem can be tackled with RFID reader and some tags. Second sub problem, saving history, can be resolved with some kind of external memory module, like SD card. Third one is composed from communication and GUI. These can be resolved with simple Web Server.


Bloc diagram of our solution is presented in picture above. Central part is Arduino Mega 2560 platform. RFID reader, Ethernet shield and microSD card are connected to Arduino via SPI communication.Tiny RTC module is connected via I2C communication interface. Also we added LED and small speaker for indicating successful card read.

Step 3: Hardware Setup

Picture above is presenting connections among modules. For SPI communication we are using hardware SPI (MISO, MOSI and CLK are all the same, SS pin for Ethernet is on pin 10, for SD card is on pin 4 and for RFID reader is pin 6, and RST pin for RFID is on pin 7). LED is connected to pin 2 and 3, and speaker is connected to pin. Tiny RTC module is connected via I2C module to pins 20 and 21. 9V PSU is connected to Arduino’s external PSU connector. Ethernet shield is connected to computer (or router) via UTP cable.

Step 4: Arduino Code

Flowchart above is presenting, how code should work. We wrote Web Server from examples in Ethernet library. The rest of the code is from RFID library example, SD library example and RTC library example.

We designed web interface in Notepad++ using HTML and some CSS code. Code is well documented, therefore I won’t do this once again.

Step 5: Testing RFID Data Logger With Web Server

We tested all three desired functions: we can now read RFID tag, identify it, store time of arrival, time of departure and working hours of an employee. We made a short video of our system in action.

Step 6: Conclusion

In the end we made a validation of our demands. Here are results:

- We can identify an employee with a RFID tag.

- We can display history for employees.

- We can store time of arrival, time of departure and working hours within a month.

From results from validation we can conclude that project was carried out successfully. Project served us as a platform for application that is daily in use in local company.



  • Epilog Challenge 9

    Epilog Challenge 9
  • Sew Warm Contest 2018

    Sew Warm Contest 2018
  • Gluten Free Challenge

    Gluten Free Challenge

We have a be nice policy.
Please be positive and constructive.




Can you help with more rfid cards to be logged in SD card.

Hi guys, i need help for arduino UNO. i can't use this script

It is too big for Arduino Uno. My initial plan was to use Uno, but there was not enough Flash memory.

Hi Guys,
I've been searching for a totorial of an portable RFID attendance logger, with obviously only SD card for storing data. Any help or suggestions?

Hi sir, I think this schematic is wrong? Why is the 3.3v on the mega is connected to the grounds of rfid and ethernet sd shield?

how do i get the website up?

I've tried to do the same with uno but when i plug the rc522 as spi slave, nothing rfid readings...any help ?

The Ethernet and the RFID reader are using the same pins( 50, 51,52) which are somewhere in the library. I gave up trying to find them so, I plugged the Ethernet Shield into a Uno and used a mega for the RFID reader. But to connect these two boards together you need to use pins 20 and 21 of the Mega which are used by the RTC module, which i gave up using as well. Unless you can find where you can change the pins, 50, 51 and 52 in the library, I have no idea how else this will work. As for the library for the RFID reader, I just created and Integer that reads and remembers the chip data, if you want to print them you have to manually enter the 8 digit number it will give you to the serial monitor or were ever else you want it. I hope this helped a little, but its all i got.

They both should use SPI pins (those that you have listed). Only difference is Chip Select pins (Ethernet is using pin 10 and RFID is using pin 6). There is no need to change them since both Ethernet Shield and RFID module are using SPI library.

How did you get your RFID reader to work? also were do you enter the library for the RFID chips? Please help