Security Access Control System Based On Radio Frequency Identification (RFID) and Arduino Technologies
Security Access Control System Based On Radio Frequency Identification (RFID) and Arduino Technologies
Certified by:
_____________________ _______________________
(Student’s Signature) (Supervisor’s Signature)
I hereby declare that I have read this thesis and in my opinion this thesis/report is
sufficient in terms of scope and quality for the award of the degree of Bachelor of
Computer Science (Graphics & Multimedia Technology)
_______________________________
(Supervisor’s Signature)
Full Name : DR MOHAMMED FALAH MOHAMMED
Position :
Date :
STUDENT’S DECLARATION
I hereby declare that the work in this thesis entitled “SECURITY ACCESS CONTROL
SYSTEM BASED ON RADIO FREQUENCY IDENTIFICATION (RFID) AND
ARDUINO TECHNOLOGIES” is the result of my own research except as summaries
and cited which have been duly acknowledged.
_______________________________
(Student’s Signature)
Full Name : AMMAR FAEZ BIN MOHAMAD AZUDIN
ID Number : CD15029
Date :
SECURITY ACCESS CONTROL SYSTEM BASED ON
RADIO FREQUENCY IDENTIFICATION (RFID) AND
ARDUINO TECHNOLOGIES
JUNE, 2018
ACKNOWLEDGEMENTS
First and foremost, Alhamdulillah for all His blessing for giving me patience to
complete my project successfully. I am also would like to thanks to my supervisor, Dr
Mohammed Falah Mohammed for his encouragement, guidance and help in making this
project possible. Besides, I also would like to express my appreciation towards my
parents Mohamad Azudin bin Hussain and Rashadah binti Idris, family, not forget to
my friends who have always been my supporter in order to finish my project titled
“Security Access Control System Based On Radio Frequency Identification (RFID)
And Arduino Technologies”.
I am very grateful towards all the lecturers of Faculty Computer Science and
Software Engineering (FSKKP) who has been directly or indirectly helped me to
prepare this proposal.
ii
ABSTRACT
In this project, a study on the latest technologies that can be used to generate an
automatic access control has been done. The aim was to create an automatic door access
control system in order to solve the manual door access problem at Kolej Kediaman 2.
Based on study and investigation, as mentioned in the literature review, Radio Frequency
Identification (RFID) technology is chosen to be used in this proposed system based on
Arduino. The RFID is an alternative technology with a potential that can replace the
traditional manual door access. By using RFID technology and Arduino, the proposed
system will enable students to automatically access the room using their ID card. Besides,
this system also comes with warning SMS notification’s feature using GSM Modem. The
advantage of the proposed system is to avoid intruders from entering owner’s room
without owner’s permission. The system has been tested and show the ability to solve the
manual door access control problems.
iii
ABSTRAK
Dalam projek ini, satu kajian mengenai teknologi terkini yang boleh digunakan
untuk menghasilkan kawalan akses automatik telah dilakukan. Tujuannya adalah untuk
mewujudkan sistem kawalan akses pintu automatik untuk menyelesaikan masalah akses
pintu manual di Kolej Kediaman 2. Berdasarkan kajian dan penyiasatan, seperti yang
disebutkan dalam kajian literatur, Teknologi Pengenalan Frekuensi Radio (RFID) dipilih
untuk digunakan dalam sistem yang dicadangkan ini berdasarkan Arduino. RFID adalah
teknologi alternatif dengan potensi yang dapat menggantikan akses pintu manual
tradisional. Dengan menggunakan teknologi RFID dan Arduino, sistem yang
dicadangkan akan membolehkan pelajar mengakses bilik secara automatik dengan
menggunakan kad ID mereka. Selain itu, sistem ini juga dilengkapi dengan ciri
pemberitahuan SMS amaran menggunakan Modem GSM. Kelebihan sistem yang
dicadangkan adalah untuk mengelakkan penyerang memasuki bilik pemilik tanpa izin
pemilik. Sistem ini telah diuji dan menunjukkan keupayaan untuk menyelesaikan
masalah kawalan akses pintu manual.
iv
TABLE OF CONTENT
DECLARATION
TITLE PAGE
ACKNOWLEDGEMENTS ii
ABSTRACT iii
ABSTRAK iv
TABLE OF CONTENT v
LIST OF FIGURES ix
LIST OF ABBREVIATIONS xi
CHAPTER 1 INTRODUCTION 1
1.1 INTRODUCTION 1
1.3 OBJECTIVES 4
1.4 SCOPE 5
2.1 INTRODUCTION 6
v
2.4 SUMMARY 15
CHAPTER 3 METHODOLOGY 16
3.1 INTRODUCTION 16
3.5.1 Hardware 26
4.1 INTRODUCTION 35
CHAPTER 5 CONCLUSION 48
5.1 INTRODUCTION 48
vi
5.3 FUTURE WORK 49
REFERENCES 50
APPENDICES 52
vii
LIST OF TABLES
viii
LIST OF FIGURES
Figure 2.1 DM1 Installation Diagram (Soyal, DM1 Door access package,
2016) 8
Figure 2.3 DR2 Installation Diagram (Soyal, DR2 Door access package, 2016) 12
ix
Figure 4.10 Result in Physical Side 47
x
LIST OF ABBREVIATIONS
ABBREVIATION TITLE
AC Alternating Current
DC Direct Current
ID Identification
xi
CHAPTER 1
INTRODUCTION
1.1 INTRODUCTION
Nowadays, the living cost of the citizens is increasing in tandem with the
improvement of technology and economy. Therefore, some people tried several ways in
order to secure their life even though sometimes it violates national regulations and norms
of life. Based on that, the security level of many human life’s aspect have been improved
that covers different topics including personal security for example Mini Foaming
Defence Spray UK (UK, 2014). This security product is designed for females to defence
them if they got confronted. They just need to spray out to the attacker’s eyes and then
they got time to get away from the attacker.
Besides, there is also car security like Viper LCD 2-Way Security System. This
system has 2-way security which protect the vehicle. The electronic technologies used in
this system including Stinger® DoubleGuard® shock sensor, Revenger® six-tone siren
and Failsafe® Starter Kill (Viper, 2009). For home security there is an example of system
which is Vivint Smart Home. The system works when there is fire, smoke, or carbon
monoxide that can threat house owner’s life. User are just need to click a one-touch
callout button on the control panel then it will automatically direct contact with
monitoring teams (Vivint, 2012).
Even in university residential college also have security system. For example, in
University of Yale, there is central alarm station that provides 24-hour monitoring of the
University’s integrated security system such as fire, burglar, duress alarms, and video.
The central alarm station also receives request for security services likes residential
college alarms (University, 2006).
1
Therefore, many organizations come out with different technology of
authentication and security to meet regulatory demands of compliance. For example,
IDtech company release UNIPASS Access Control System which a security system for
door’s access. The system used a biometric technology which is fingerprint recognition
access control system (IDtech, 2016). Another existing system is DR2-Standalone Card
and Pin. The system which is released by Soyal’s company is build for accessing the door
that used both card and PIN. The technology used is Radio Frequency Identification
(RFID) (Waxton, 2016).
RFID technology currently have been applied in many aspect of life in different
applications for example in library system to improves the efficiency of circulation
operations and also to enhance the process of individual’s checkout and check-in
2
(Thrasher, 2013), storage system to track the returnable items (Långström, 2013),
attendance system to record the data when the employee enter or exits the office and
calculate the total of person staying in the office by using an RFID card (Chudasma,
2014), as well as, in access control system which is cover different areas like Biometric
Access Control System Proximity Access Control System (Agarwal, 2012). The focus of
this work is on the security door access control system.
The other component that used in this project is Arduino. Basically, Arduino is
known as an open-source platform that used specially for developing various kind of
electronics projects. Arduino can be divided to two things which is consist of a physical
programmable circuit board and a piece of software which is called IDE (Integrated
Development Environment) that function on computer. The computer code is wrote and
upload to the physical board by using this IDE (Arduino, 2003). The Arduino IDE
(Arduino program’s name) contains an editor that able us to write sketches in simple
programming language. It will convert to C language and then compiled using avr-gcc.
The microcontroller on the Arduino board will be able to understand and execute because
this process produced binary code. First, connect the Arduino board to a computer using
USB cable then IDE is used in order to compile and upload the board to the program
(Fabio, 2006).
There are several systems that has been used Arduino likes Arduino Alarm
System. This alarm system uses a motion sensor to detect movement and emit a high
pitched tone. It also emits visual display consisting of flashing LED lights. The other one
example is Arduino Light Sensor which is a device that functioning as to detect light.
This system is using Light Dependent Resistor (LDR) and then will be controlled using
Arduino (Administrator, 2016).
The reasons why Arduino is used in this project for example it is simple, clear
programming environment. For beginner, it is easier to use the Arduino software (IDE),
as well as, it is good cross-platform device as the IDE able to runs on typical operating
systems such as Linux, Macintosh OSX and Windows. In addition, Arduino boards are
relatively inexpensive compared to other microcontroller platforms as it can reduce the
cost of materials while completing this project (Arduino, 2003).
3
In this project, the RFID reader module uses the SPI protocol for communication
with the Arduino board. The Arduino board need to connect with the RFID reader module
then the coding process will take place in Arduino IDE software in order to connect the
RFID with Arduino. This Arduino IDE contains all the software which will run a
computer in order to program and communicate with an Arduino board (Mukherjee,
2016).
Nowadays, there are many students who stay in residential college complaints
that the security level of their room or house is not very satisfied. This is due to the theft
case that often happens for example in Kolej Kediaman 2. One of the factor why this
incident keep occur is because lack of security of door’s access control. The manual
access door that currently used in college is actually not really secure as they are easily
broken into. Besides, students need to carry around those keys and sometime the keys
will likely to be lost. Other problem while using manual door access is students need to
store a duplicate or spare key somewhere on their property like many houseowners
currently do. However, this method still does not guarantee safety as most criminals are
used to looking around to find a spare key. In addition, the quality of the door knob is
low of usability and easy to be damaged by others. Lastly, there is no unique identification
of the user for each of the door knob on manual door access.
1.3 OBJECTIVES
The aim of this project is to design a secure automatic door access system for
Kolej Kediaman 2. While the objectives are
4
1.4 SCOPE
Chapter 1 is discuss in the introduction of the project. In this chapter will shows
a rough overview about the RFID concept and why the system is going to purposed.
Moreover, in this stage, the problem statement, objective and scope of the entire project
are defined here.
Chapter 3 is discuss about the flow of the system process and the selected
methodology that will be used in this project. On the other hand, the software and
hardware specification also will explain here in more details. Besides, the flowchart, use
case digram also explained here.
Chapter 4 is show about the development of the project. Besides, this chapter
also will describe about the steps of the system implementation. The testing and coding
implementation will be elaborated here.
Chapter 5 is discuss about the final result of the project. Other than that, the
conclusion for entire development will be discussed here and will explain the challenges
of this system.
5
CHAPTER 2
LITERATURE REVIEW
2.1 INTRODUCTION
Over the years, access control systems have become more and more advanced.
Security access control system serves security by giving flexible control over who is
allowed to enter the room. These access control systems basically invented as security
purposes. Access control system recognizes authenticates and authorizes entry of a
person to enter into the room. At the same time, the security of the room will ensured as
it gives complete protection.
Vandal Resistant Slim Reader or also known as DM1 is a door access control
system that developed by Soyal. DM1 is a device that provides vandal resistant function
and water splash proof (Soyal, DM1 Door access package, 2016). The technology used
in this system is RFID technology as it used card reader as medium to access the door.
6
On 2 April 2015, DM1 was released under the Silver Black Series. This product
was implemented with SoyalEtegra Access Control Management System that allows
personnel maintenance. Besides, the product allowed users remotely the view within the
LAN. Furthermore, this product give comfort to the user as the access card reader is
designed with a slim body which make it easy to fit into narrow door frame. In addition,
DM1 can perform monitoring and CCTV picture capturing.
However, there are some weaknesses in this product. The first problem is there is
only one method to access the room at a time. For example, if users choose the card as a
medium to unlock the door, then the reader will set up to read the card only. On the other
hand, if the users choose the tag to be a medium to unlock the door, the reader will set up
to read the tag only. Thus, at this point the card could not be used as a key anymore.
Consequently, users must have in their mind first which method they want as medium to
unlock the door to access the room.
The basic process on how to access the room is firstly user needs to scan their
card in front of the reader. After the card is verified successfully by the reader, the
electromagnetic door will automatically release the door. At the same time, a single beep
will be heard as notifier to user that the card was successfully being identified. On the
contrary, double beep will sound out if there is unauthorized issue because of the card is
rejected by the reader. With the result that, the data from verified identity will save to the
PC for record purpose. The picture below shows how the installation of DM1:
7
Figure 2.1 DM1 Installation Diagram (Soyal, DM1 Door access package, 2016)
8
fingerprint scanner in order to get the input from user. Next, the process of identification
and verification will take place. The identification or also can be called authentication
process is about to identify who is the user and at the same time used to establish user’s
identity. Conversely, verification process is about to affirm identity of user. Hence, there
is two major process which are used to accepting and rejecting the user’s identity. So, the
biometric system process need to starts with enrollment after that followed by
identification and verification process. In the enrollment phase, user will scanned their
characteristic using biometric reader for getting a raw digital data. To facilitate matching,
the raw data will processed by feature extractor in order to generate a compact but costly
representation, also called as template.
Identification : In this phase, the identification of user will occur here. The process
runs by comparing the trial template with the stored reference template in order to find
a match. This identification process is declared as one-to-many matching because the
user’s biometric will be compared with others multiple biometric templates in the
database. Currently the two types of identification system available are positive and
negative which are the positive one is about to make sure that the biometric characteristic
is already enrolled in the database. The expect result for this search is there is a match.
The other one which is negative identification systems are used as to ensure that an
individual’s information is not exist in a database. The results expectation for this search
is a no match.
9
presented, generating a trial template that is based on an algorithm. Then, the trial
template will be compared with user’s reference template that already exist in the system
in enrollment phase before. This process function as identify whether the template is
matched or mismatched. Contrary to identification method, verification was referred as
one-to-one matching. The figure 2.2 below is the process of UNIPASS.
Biometric technology also has its own limitation. If the user’s finger have sweat
or injured, it will hard for biometric reader to do the identification. In addition, the system
can make mistakes with the dryness or dirtiness of the finger’s skin. This is because the
system cannot read the finger’s information due mismatch with exist information that
stored in the system.
10
2.2.3 DR2-Standalone Card and Pin
CAC which is also known as Common Access Card is a card that similar like
credit card based on their size. This smart card is used for allowing rapid authentication
and also serve high security for all type of access. With installing secure CAC application,
it can access the information stored. In addition, a Personal Identification Number (PIN)
also needed in order to access the stored data with system access to the secure CAC.
If the person has authorized to the system, then he can perform an identification
process. The example is like only the person who has authorized is allow to access or
review the information data in the card if the card contains user’s information. Besides,
the CAC technology give safety features for example sound criteria for personnel
identification and also resistance to exploitation and identity deception. Despite that all
positive criteria, there is still some lacking that can be found in the system for instance
the chip may be get damaged and the card might be lost.
This DR2 Access Control System which produced by Soyal company is released
on 1 May 2009 (Soyal, DR2 Door access package, 2016). The system is build for
accessing the door that used both card and PIN. DR2 system is very famous among user
as it is low budget application. This DR2 product is recommended for user who want to
11
install auto access control to their door as it was designed to allow high security function
but cost effective.
The process of accessing the door is begin with user needs to flash the card in
front of the reader. If the system is able recognize the card, a blink of green LED will
appear and one beep sound will be heard. On contrary, red LED will blink with two beep
sound as mention to user that there is an invalid reading. If the car is accepted and
verified, then they may enter the pin number on the keypad. Upon identity verification,
the electromagnetic door will automatically open and allow the door to be opened.
However, user need to push the exit button from the inside of the room first manually in
order to lock the door during the exit.
There are few weaknesses in the system for example it is need to keep a hard copy
list of the name, user number, and card number programmed into the reader for future
maintenance. While using this system, a software need to be added so that all user profile
can be stored in PC. The function of this software is for allowing easy add, edit or delete
of user profile. The Figure 2.3 below shows the diagram of the DR2.
Figure 2.3 DR2 Installation Diagram (Soyal, DR2 Door access package, 2016)
12
2.3 COMPARISON EXISTING SYSTEMS
The three existing systems which are DM1-Vandal Resistant Slim Reader,
UNIPASS–The Simple, Efficient Access Control Solution, and DR2-Standalone Card
and Pin have been studied and compared. Based on these three systems, there are some
differences that can be summarize as shown in the Table 2.1.
- If the data is
verified, it
then will
send to the
PC
13
include from dirtiness) of
the user’s finger
enrollment skin
phase,
identification
phase and
verification
phase
- Manually
programmed
the reader
through the
keypad
14
2.4 SUMMARY
Kolej Kediaman 2 at present used manual key for lock and unlock the door. The
key is made by metal that have incisions cut to fit the wards of a particular lock, to open
or close the door. As we know, the key is actually the traditional way and only operate in
offline state.
The benefit while individual use this traditional method is they no need to use
electrical supply if compared to nowadays advance technology method. This method is
the cheaper way compare to the method that technology invented. Besides, the key is easy
to bring and also easy to take care of. However, the key of course has their own weakness
for example users may lost their key due to misplace because they need to bring the key
together everywhere they go.
Therefore, for this project, the features of security access system that used is RFID
technology. This technology is more suitable compare to fingerprint or password access
because it is more safe and more convenient for students. Another reason why RFID
technology is chosen because users do not have to bring a key with them anymore and
the problem of missing key also can be solved. As conclusion, in order to find the solution
to this problem, the Security Access Control System with warning SMS notification will
be developed.
15
CHAPTER 3
METHODOLOGY
3.1 INTRODUCTION
16
3.2 RAPID APPLICATION DEVELOPMENT METHODOLOGY
To ensure the project is successful, the right and suitable methodology should be
considered. The methodology that will be used to develop this system is Rapid
Application Development (RAD). Basically, RAD is a software development
methodology. Iterative development and constructed technique are the things that
involve in RAD. Figure 3.1 shows the process of RAD methodology.
By using this method, a clear idea on what should be or should not be built in this
system will be obtained. If there are any problems regarding the system, it can be solved
first before any implementation is done. Hence, the system can be developed faster and
at the same time consuming with low cost. The analysis, design, build and test phase was
combined by RAD in the traditional SDLC into the iterative process in order to produce
efficient development technique. RAD basically has 4 phases which are requirement
planning, user design, construction and cutover.
Requirement planning is a phase that require the end user determine what the
function of the system. In this phase, the objective and scope of Security Access Control
System will be identified and clarified. The requirement for the system will be discussed
and also define the project methodology, technique and tools.
17
The next phase is user design. In this phase, user needs to participate with the
developer as to create the system’s prototype. The user will participate under guidance
provided by the developer. The prototyping process is created to assist in requirement
specification and design.
For construction phase, the Security Control Access System will be developed
and also implementing the elementary modules. Here, all the codes will be generated to
the prototype. To enhance the performance of generated code, code optimizer may be
used. In this phase, the end user ID will involve as the testing will take place all the way
through the process of construction.
The last phase of RAD is cutover. In cutover phase, it will present the new system
to the end user. Here, comprehensive testing, end user training and implementation the
system will occur. This phase is basically consist of implementation and maintenance
phase.
Therefore, in this phase, the Gantt chart is created. This Gantt chart shows the
overall schedule of the project development and function as to ensure the project
development delivered on time. Furthermore, this Gantt chart will assist in order to plan,
manage and track the task development. The project schedule’s detail refers to Appendix
A.
18
3.3.2 User Design Phase
After identify all the tools and requirement needed from previous phase, hence
the analysis is made. While using this RAD methodology, in order to minimize the time
consuming for completing this project, analysis and design are combined together.
In analysis phase, the information that needed for this system was analysed to
make sure that the goals of the system are achieved. The current existing systems in the
market also must be studied in finding the solution of project’s problem. Therefore, it
helps in order to design and enhance the proposed system and also to reach the project’s
objectives.
In design phase, the RFID technology that used in this system will go through
some steps to establish the access control process. These steps are shown like the Figure
3.7 below.
RFID is a technology that used radio waves in order to transmit the identity of the
individual. This RFID used waves as to recognize and capture the data stored in a card or
tag. The typical RFID consist of two main components. The first one is the tags or
transponder and the other one is reader or interrogator. For the RFID tags, it consists of
two main parts which are 12 byte unique ID Microchip that used to store and process the
19
information. The second one is the antenna that used to receive and transmit the signal.
For the reader hardware, it is used to detect radio waves and receive the signal from the
tag whenever the tag is brought or scan around the reader’s range.
For the reader to read the information in the tags, the reader will emit a signal to
the tag through an antenna. Then, it will convert the energy into radio frequency waves.
Next, after the tag is read by the reader, the antenna from the tag draws in energy from
the radio waves. The energy moves from the antenna belong to tag to the IC then will
power the chip which produced a signal back to the waves. The ID or information that
embedded in the tag will read by the reader whenever the RFID tag is brought near the
specific range of the reader. Thereafter, these information and ID will pass onto a
controller or processor.
Nowadays, several types of RFID tags have been used in many aspect. In this
project, in order to develop the Security Access Control System, the passive RFID tag is
used. Passive tags did not have power source so this tag need to derive the power from
the incident electromagnetic field that generated by the reader. The passive tag used the
radio waves from the reader to relay its stored information back to the reader. However,
the passive RFID tag operates in different frequency. Based on the system that will be
developed, the 125-134 KHz of frequency is used because it is the lower frequency. The
range for lower frequency is about 1–10 cm (Smiley, 2016). This type of lower frequency
is better for this system as it is long wavelength but has a short read range.
Whenever RFID system operate with low frequency, the range covered is short
and also the rate of data being read is slower. The reason why this type of tag is used is
its abilities to read the data near the liquid surfaces. On the contrary, if the system operates
using high frequency, the range of the radio waves is longer and also it has a faster rate
of data transfer. However, it is not suitable to use high frequency tags for this system
because is the tag is sensitive to the metals and liquid surfaces. Therefore, the passive tag
is chosen and used in this system as this passive tag is commonly used for most of
application like access control, smart label and file tracking.
20
3.3.3 Construction Phase
The figure below shows the rough process of developing and how the security
Access Control System. This system works where it can detect intruders or anyone who
try attempts to access the owner’s room without permission. When the system has
detected there is intruder, it will generate the notification to the owner by sending the
SMS through the phone. The general flow of the proposed project is showed in the Figure
3.3 below.
21
3.3.4 Cutover Phase
After all the phase is going through, in this final phase which is cutover phase,
the system will deliver to the end user which is college’s students. This phase is basically
a combination of the implementation and maintenance phase. Here, testing, training to
the user and implementation should be done in this phase. After that, if there are any
errors or mistakes, this system needs to be improved and upgraded to meet the user
requirement.
22
Figure 3.4 Flowchart of the Security Access Control System
23
3.4.2 Context Diagram
The context diagram of this Security Access Control System is shown in the figure
below. It defines the system’s boundary and the entities that interact with it also shown.
24
3.4.3 Use Case Diagram
Use case diagram is a representation of the interaction of user with the system that
shows the relationship among the user and the different use cases in which the user is
involved. The use case diagram for this system is developed in order to show the
interaction and relationship between user and the system. This diagram is useful to
analyse the effect or influence that could come from this system as shown in Figure 3.10
below. This system will be analysed with list of all functions it could perform. Besides,
any actors involve will have to be identified as shown in figure below.
25
3.5 HARDWARE AND SOFTWARE
In this section, the type of hardware and software that have been used during the
development of the system are described. The hardware that I use are Arduino UNO R3,
RFID MIFAIR RC522 IC Card Induction Module, 12VDC Solenoid Electromagnetic,
5V Single Relay Module, SIM900 GSM Modem. The software that I use while
developing this system are Arduino IDE and Fritzing.
3.5.1 Hardware
a. Arduino UNO R3
The type of Arduino that will be used is Arduino UNO R3 because in the Arduino
family, it is the most commonly used and documented board. Besides, UNO is relatively
cheap and easy to setup. It also has own IDE software which is run on developer
computer. Using Arduino UNO, it can be directly upload the program into the physical
board.
Nowadays, Arduino has become popular as it is an open source platform and also
this device unnecessary separated pieces of hardware or programmer to load the source
26
code onto the board. By referring to Figure 3.2 above, Arduino UNO is hardware used to
build electronic projects and could be explained as platform based on easy to use
hardware and software. This is due to the Arduino used C++ and C language which is
easy for beginner or novice user to learn.
The Arduino board is really advanced as it able read inputs, sending and
transmitting the signal by just set the instructions to the microcontroller that attached on
the Arduino board. By using Arduino programming language which based on the wiring
and Arduino software (IDE) based on the processing, it will tell the board what to do. In
addition, this devices source codes are easy to find over the internet. The Arduino will
operate as a centre of operation as the other components and wired will be connecting
through it. Based on all the fact and reason, this device has been selected as one of main
hardware component in order to develop the Security Access Control System.
Microcontroller ATmega2560
Operating Voltage 5V
27
DC Current per I/O Pin 50 mA
SRAM 2 KB (ATmega328)
EEPROM 1 KB (ATmega328)
28
This device which launched by the NXP Company is a low cost, low voltage, and small
sized non-contact card chip. Hence, it is the best choice for portable handheld device.
The RFID Mifare RC522 communicates with cards up to 1cm using a 13.56MHz
electromagnetic field. Then, it sends the data to the Arduino board via SPI
communication. This device supports rapid CRTPTO1 encryption algorithm. It is for
verifying MIFARE products. It also supports MIFARE series with a two-way data
transmission rate of up to 424kbit/s of high-speed non-contact communication.
In this MF522 module, it used original Philips MFRC522 chip. This card reader
not only low cost but it also easy to use and applies to the user equipment development.
Furthermore, this reader is really good because it can be directly loaded into the variety
of the reader mold. To ensure that the module is stable and reliable work, the reader must
utilised with voltage 3.3V through the SPI interface simple lines. Then, directly connect
with any user CPU motherboard to the communication. The MIFAIR RC522
specification is shown in the Table 3.2 below.
29
Environmental Storage -40 to +85 C
Teperature
Solenoid is basically electromagnetic hardware that made from high quality iron,
which is strong and durable, secure and safe. The solenoid works when the power is
generated to the coil, the slug is pulled inside. The figure 3.4 above shows the 12VDC
Solenoid Electromagnetic device.
The typical solenoid basically has a slug with a slanted cut and a mounting
bracket. Normally this solenoid is used for a basic cabinet or door. For this project, this
solenoid will be attached at the prototype door for lock and unlock process as it has a
good mounting bracket. At first, the slug is already outside the body as it means that it is
in a lock state. After the 12VDC is connected to the solenoid, the slug will pull inside the
body as it means that the door is already unlock. Table 3.3 shows the details of the device.
30
Voltage 12VDC
Weight 97g
31
d. 5V Single Relay Module
In developing this system, the 5V relay single module was used to remotely the
electrical device switching. Relays normally used electromagnet in order to operate
between two circuits. The relay works when the coil of relay is energized, the magnet
will change the position of the switch. The function of this relay in this system is to
remotely control devices, control the peripherals or other powered devices over a
network. Therefore, this relay can be remotely powered to switch whether to turn on or
off the system.
This relay was operated when the input (IN) is HIGH (+5V). This relay actually
is an optical isolator. It separate connectors for the IN ground (COM) and used 5V supply
ground (GND). In this system, the 5V single relay that used is consist of Normally Closed
(NC), Normally Open (NO) and Common connection (COM). In order to make this relay
worked, the relay must connect to the 5V pins of Arduino device. Figure 3.5 shows the
image of Single Relay Module and the specification of the Relay 5V module that will be
used in the project is shown in the Table 3.4 below.
32
Power Supply 5V
GSM modem is a modem that accepts a SIM card and work over a subscription
to a mobile operator likes mobile phone. A GSM modem is capable to work with multiple
type of Arduino such as Arduino Mega, Mega ADK, Leonardo and YUN. This device
exposes an interface which allows application to send and receive message or SMS and
also make voice call through General Packet Radio Service (GPRS) using the GSM
library.
33
The first thing that should be noted is user must subscribe a mobile phone operator
either postpaid or prepaid in order to get the connection while using GSM modem.
Besides, user also needs a simcard that include information likes mobile phone number
and also can store limited amounts of contact and SMS. The SIM900a GSM Modem
specification is shown in the Table 3.5 below.
Enhanced commands :
SIMCOM AT Commands
34
CHAPTER 4
4.1 INTRODUCTION
This chapter basically will explain and describe the function of every part of the
model after the implementation. To prepare this process, all part is combined together in
a circuit in order to make the system works. The sketch that show the process of
combining all the part in one circuit by using Fritzing software will help as reference to
build the physical prototype. The last step in order to make the system function, all the
codes are write in Arduino IDE then compiled and uploaded the code to the Arduino Uno.
In this project, the main component is Arduino Uno. This device is known as a
component that acts like a motherboard for this project. It also has its own Integrated
Development Environment (IDE) which is can perform on a computer. This IDE is
powerful as it can compile and upload the code into physical Arduino’s board. Therefore,
all the components must be set up similar to the sketch in Fritzing to make this project
run according to what has been set. The steps and guides for the implementation of the
components are explained as below.
35
Figure 4.1 Arduino and GSM Modem
In the Figure 4.1 above, the first step that must be taken is connecting GSM
modem with Arduino. Since this modem can support the SMS text mode, therefore the
GSM can send and receive the SMS using AT commands. This modem also can get the
signal and at the same time it can receive message’s notification. This is because it has
an active simcard that installed in the modem.
The process of embedding the simcard into the GSM modem actually is not too
complicated. The step is by inserting the simcard in the slot available on GSM and then
carefully lock it. The next step is connecting the adapter to the GSM then turn it on. Then,
wait for a while and let the power supply flow to the board. After a few minutes, the LED
of GSM modem will blink. Actually the blinking LED means that the modem is already
successfully connected with Arduino. In order to connected with the RFID, identify first
the connection of the RFID pins to the Arduino. The circuit’s connection between the
Arduino and the RFID module can be shown as in Figure 4.2 below.
36
Figure 4.2 RFID and Arduino Circuit
SDA 10
SCK 13
MOSI 11
MISO 12
GND GND
RST 9
3.3V 3V3
37
In this system, relay is used so the system will more efficiently function. This
relay must attach together into the modem which RFID connected. This is to show the
action of the lock and unlock of the door. Figure 4.3 below shows the process of the signal
from RFID in order to unlock the door. The detail description about the relay and what
pins that must be connected to the board are shown below.
Basically, the implementation of this program is the door will always in closed
state. In order to unlock the door, we must trigger the relay module. Hence, it will unlock
the solenoid for a few seconds based on the program coded. Basically, the COM part of
the relay module is actually function as a switch. The lock and unlock process can be
done by plugging the relay with the solenoid. Besides, to make the system running
properly, the relay and solenoid should be connected to the power supply.
38
The connected pins:
DC+ 5V
NO Power
supply
COM Solenoid
Then, the next process is done by combining all the circuit. Before combining all
the part together in a 1 complete design, all the connection of pins must be checked that
it connects with right connection. After all the parts are combined, then the codes of the
program can be uploaded into the board. Figure 4.4 shows the complete design for
Security Access Control System based on Radio Frequency Identification (RFID) and
Arduino Technologies.
Arduino
SIM900a
Uno R3
GSM
RFID
Reader
Relay
Module
39
In the Figure 4.4 above, the actual design of the system is shown to test the contact
of solenoid with the relay through Arduino board, GSM and RFID module. Before
connect all the components to the power supply, all the pins must be properly connected
based on the complete circuit designed. Then, the program code can be uploaded to the
board. For this system, the solenoid is basically in a lock state. This can be seen where
the plunger of solenoid is currently outside of the component’s body. When the RFID
module reads the tag, the door will unlock as the connected pin to relay sent the signal to
the solenoid.
In this system, the Arduino IDE is used in order to build the code and run the
program. The Figure 4.5 below shows the Arduino IDE Software. As mention before, the
coding must be write in this IDE then compiled and upload it to the Arduino board. Before
begin the coding implementation, firstly the main board must be connected to the PC or
laptop. This can be done by plugging the board to the USB cable then connect the cable
to PC. The power from this PC will flow to the board to make this system working.
40
Before testing the code for GSM to trigger the SMS, the Arduino board should be
set up properly first and must function well. The Arduino IDE needs to be ready with
GSM library that can be get at the example provided by Arduino program. If the codes
are successfully work, then combine it with the RFID codes in order to get complete code
of the system. Figure 4.6 below shows the codes to generate the warning notification to
the owner.
41
The connection pin for relay then can be done after the function for generating
message is works. The codes to implement the pins that connected to the relay to unlock
the door is tested. Figure 4.7 below shows the codes.
void setup() {
digitalWrite(RELAY, HIGH);
void loop() {
digitalWrite(RELAY, LOW);
delay(ACCESS_DELAY);
digitalWrite(RELAY, HIGH);
In this system, the crucial part is the process of scanning the RFID card.
Therefore, the code that have been implemented in the system is to detect the card’s ID
and also to trigger the pin 3. If there is unauthorized user try to scan their card to the
RFID reader, the message will be automatically generated and send to the owner of the
room. The Figure 4.8 below shows the RFID code and main code for generate the
warning message.
42
#include <SPI.h>
#include <MFRC522.h>
#include <SoftwareSerial.h>
String textForSMS;
SoftwareSerial SIM900(7,8);
void setup() {
pinMode(LED_G, OUTPUT);
pinMode(LED_R, OUTPUT);
pinMode(RELAY, OUTPUT);
pinMode(BUZZER, OUTPUT);
noTone(BUZZER);
digitalWrite(RELAY, HIGH);
Serial.println(F(""));
Serial.println(F(""));
Serial.println(F("WELCOME TO SECURITY ACCESS CONTROL SYSTEM"));
Serial.println(F(" by @ammarfaez11"));
Serial.println(F(""));
Serial.println(F(""));
Serial.println(F("Put your card to the reader..."));
Serial.println(F(""));
}
43
void loop() {
// Look for new cards
if ( ! mfrc522.PICC_IsNewCardPresent()) {
return;
}
digitalWrite(RELAY, LOW);
digitalWrite(LED_G, HIGH); //green led turn on
tone(BUZZER, 2000 , 500); //buzzer sound on
//delay(500);
delay(ACCESS_DELAY);
digitalWrite(RELAY, HIGH);
digitalWrite(LED_G, LOW); //green led off
noTone(BUZZER); //buzzer off
44
else{
}
}
45
4.4 RESULTS AND DISCUSSION
For this section, all the results of this Security Access Control System Based on
RFID and Arduino Technology are covered and discussed. After all the system’s code
are implemented and tested, then uploaded to the Arduino Board, the program can be
run according to the requirement needed and meet the objectives of the project.
Based on Figure 4.9 above, it shows the result in logical side. When user scan
their card to the reader, then in this serial monitor, it shows the user’s ID card number.
Besides, the message also will be print there which show whether user can access the
room or not. Here, the error message is displayed if unauthorized user scanned their
card. Then, the system will trigger a warning notification that automatically sent to
owner’s mobile phone.
46
Figure 4.10 Result in Physical Side
From the Figure 4.10 above, it shows the results of the physical side of this
system. It shows that the message has been triggered by the Arduino through the signal
that the RFID rejected. This happen whenever the RFID could not read the cards which
leads to the Arduino board triggered a warning notification as a SMS to owner’s mobile
phone.
47
CHAPTER 5
CONCLUSION
5.1 INTRODUCTION
In the previous chapter, there is multiple of phase that has been going through in
order to complete this project. For this chapter, it will conclude that this Security Access
Control System based on Radio Frequency Identification (RFID) and Arduino
Technologies was a success as it achieves the objectives of this project. The final result
of this project is the warning notification will send to the room’s owner as an alert based
on certain condition that has been programmed. In this project, a Short Message Service
(SMS) will be sent to the owner as a notification.
For a conclusion, the Security Access Control System based on Radio Frequency
Identification (RFID) and Arduino Technologies capable to inform owner if the outsiders
are attempting to breaking into the owner’s room without authorize. The essential thought
of this system is the entryway at the room’s college will continuously in locked state. In
order to make the door unlocked, the first thing to do is the user’s card must be scanned
around the RFID reader. Next, the RFID reader will read the ID whether it is available in
system or not, then the signal will send to the Arduino board. The Arduino then process
the instruction to make the door unlock. This can be done when Arduino send the signal
to the relay that connected to solenoid lock. On contrary, the GSM will execute the
notification whenever the RFID reader cannot find ID match with the unauthorized user’s
card.
Honestly there are a few constraints that had been face during completion of this
project. One of the problem that had been identified is the problem with the RFID reader.
This is because during the scanning process, the RFID reader cannot function well. The
RFID reader sometimes hard to detect the scanned card. As we know, the cards must be
48
scanned using wave that RFID provided. The problem comes when user needs to scan
the card for a few times before it successfully read because the reader cannot detect the
card. Hence, this situation gives a worried feeling to the user because they afraid if the
message will generate and send to the room’s owner.
Besides, the other constraint that comes was problem in handling the
communication between Arduino and GSM modem. Sometimes the notification message
was error because the signal that GSM provided to trigger the notification is failed. In
addition, the GSM modem that had been used for the project is currently lack of some
function for example for this version of GSM modem, it only allows the notification to
be sent to one person or one number only at a time. The solution for an alternative way
to solve this problem will explain later on which another device that can be used instead
of Arduino Uno.
Once the project has been completed, there are some aspects that can still be
improved in the future. These suggestions to ensure that this project can be enhanced
even the project’s goals and objectives of the project have been achieved. For example,
the warning notification message. As we know, the warning message notification
implemented in this system is still lacking because it is only able to send a message to
only one recipient at a time. Therefore, other ways should be considered to improve this
shortcoming. One of the best way to solve this lack is by using Arduino Mega or advance
GSM modem as this device is able to send messages to multiple recipients at a time.
49
REFERENCES
Administrator. (2016). 10 Simple Arduino Projects For Beginners with Code. Retrieved from
Electronics Hub.
Agarwal, T. (2012). Know about Access Control Systems and Their Types with Features.
Astc. (2016). Advantages and disadvantages of RFID Door Locks. Retrieved from Astclocks.
Chudasma, S. (2014). RFID Based Attendance System using 8051 Microcontroller. Retrieved
from EngineerGarage.
Fabio. (2006). What is Arduino, Why we choose it, what can we do with it? Retrieved from
varesano.net.
Ishabakaki, P. (2015). Radio Frequency Identification based Drug Management and Monitoring
Långström, H. (2013). Grocery industry operations are facing a real paradigm shift. Retrieved
Mukherjee, A. (2016). Security Access Using RFID Reader © GPL3+. Retrieved from Project
Hub.
Rouse, M. (2006). RFID (radio frequency identification). Retrieved from IoT Agenda.
50
Smiley, S. (2016). Active RFID vs. Passive RFID: What’s the Difference? Retrieved from RFID
Thrasher, J. (2013). How is RFID Used in Real World Applications? Retrieved from RFID INSIDER
UK, M. F. (2014). Personal Alarm Mini Foaming Defence Spray UK. Retrieved from Crime
Prevention Products.
Viper. (2009). Viper LCD 2-Way Security System. Retrieved from Viper.
51
APPENDICES
APPENDIX A
Gantt Chart
52