A low cost Internet-based attendance record embedded system for students which uses wireless technology to
transfer data between the client and server is designed. The proposed system consist of a Raspberry Pi which acts as a
client which stores the details of the students in the database by using user login system using web. When the user logs
into the database the data is sent through GPRS to the server machine which maintains the records of the employees and
the attendance is updated in the server database. The GPRS module provides a bidirectional real-time data transfer
between the client and server. This system can be implemented to any real time application so as to retrieve information
from a data source of the client system and send a file to the remote server through GPRS. The main aim is to avoid the
limitations in Ethernet connection and design a low cost and efficient attendance record system where the data is
transferred in a secure way from the client database and updated in the server database using GPRS technology
Z Score,T Score, Percential Rank and Box Plot Graph
Raspberry Pi Based Client-Server Synchronization Using GPRS
1. INTERNATIONAL JOURNAL FOR TRENDS IN ENGINEERING & TECHNOLOGY
VOLUME 5 ISSUE 2 – MAY 2015 - ISSN: 2349 - 9303
94
Raspberry Pi Based Client-Server Synchronization
Using GPRS
Geraldine Shirley N 1
Dr. S. Jayanthy2
Sri Ramakrishna Engineering College, Sri Ramakrishna Engineering College
M.E. Embedded Systems Technologies Professor, Department of ECE
geraldine.shirley31@gmail.com jayanthy.s@srec.ac.in
Abstract— A low cost Internet-based attendance record embedded system for students which uses wireless technology to
transfer data between the client and server is designed. The proposed system consist of a Raspberry Pi which acts as a
client which stores the details of the students in the database by using user login system using web. When the user logs
into the database the data is sent through GPRS to the server machine which maintains the records of the employees and
the attendance is updated in the server database. The GPRS module provides a bidirectional real-time data transfer
between the client and server. This system can be implemented to any real time application so as to retrieve information
from a data source of the client system and send a file to the remote server through GPRS. The main aim is to avoid the
limitations in Ethernet connection and design a low cost and efficient attendance record system where the data is
transferred in a secure way from the client database and updated in the server database using GPRS technology.
Keywords- Embedded system, Raspberry Pi, GSM/GPRS, Client-Server database, Attendance record
1. INTRODUCTION
Wireless networking technology enables two or more computers
to communicate and relay data using standard network protocols,
without the hassle of network wiring and cabling. It is now not just
limited to wireless telephony but there is now a huge demand of
wireless technology for many types of applications like Internet and
web browsing, video and other text and multimedia based
application. GPRS stands out as one major development in the GSM
standard that benefits from packet switched techniques to provide
mobile subscribers with the much needed high bit rates for bursty
data transmissions.
Security is an important issue in mobile networks and has gained
a special attention in the GSM world. GPRS provides a security
function similar to that of GSM. It is responsible for authentication
and service request validation to prevent unauthorized service usage.
User confidentiality is also protected using temporary identification
during connections to the GPRS network.
Attendance Management System (AMS) is the easiest way to
assist the faculty and the lecturer for this time-consuming process.
There are various attendance management systems based on RFID,
Finger print modules and face detection schemes. But most of these
systems use Ethernet connection to connect to their server machines
to update the attendance and are expensive ones. This limitation is
overcome by this system which consists of Raspberry Pi (ARM11)
processor with GSM/GPRS SIM900 module interfaced with it which
acts as a client and through wireless connection it is connected with
the remote server where the data gets updated automatically in the
server database when the user logs in the client system using login
id.
The client transmits the valid information at periodic intervals to
the server. Thus the information of the student updated in the client
database is transferred in a secured way to the server system
database. Synchronization between the client and the server is done
GPRS connectivity.
Wireless automatic attendance management system that authenticates
using the login id of the individuals is a reliable scheme than other
systems.
2. RELATED WORKS
The main objective of Attendance Management System in PHP is
to check and prepare report or attendance for any particular
organizations such as for hospitals, schools, colleges, shopping mall
etc. With the help of attendance management system, it will
eliminate the manual calculation of working days for each and every
employees, its admin will easily analyze the result based on their
requirement such as number of absentees per day, number of
employees required to handle their tasks etc. Nithyappriya et al has
proposed a system using SSH connection to connect with the client
and server [1]. The main advantage in this is it uses client server
synchronization using GPRS and secured SSH connection. Some
drawbacks are only when the Ethernet connection fails the message
is transferred to the server from the client. Bala Saidulu et al has
proposed a low-cost Internet-based data processing system for real
time application so as to retrieve information from a data source of
the server system using GPRS module [2]. The drawback in this
system is it uses FTP server which is not a secured transmission.
Shraddha S. Chawhan at al has proposed a Mobile Phone Based
Attendance System (MPBAS) a phone application which gets
connected with the server through GPRS [3]. It is an efficient system
but it requires a smart phone for login and to connect for each user.
Implementing a web server on an embedded system having limited
resources to serve embedded web page to a web browser and which
can be accessed by the client and server by synchronization [4].
Efficient and effective management system with centralized
connection along with ease to manage it from remote servers to
transfer the information [5]. Attendance and monitoring students
Using mobile technology along with tracking system in rural places
where no internet and advanced technology is available [6]. Web-
Based Student Attendance System where no specific software
installation is required and automatically data updated to server with
2. INTERNATIONAL JOURNAL FOR TRENDS IN ENGINEERING & TECHNOLOGY
VOLUME 5 ISSUE 2 – MAY 2015 - ISSN: 2349 - 9303
95
less risk of data loss, compared to a manual filing approach [7]. A
web server can be embedded into a device which can be accessed
remotely from a web browser. This embedded system can serve the
web documents on request by a client from other system. Such type
of a web server is called as Embedded Web Server (EWS).
To overcome the drawbacks of the existing systems a low cost
real time client server synchronization based on Raspberry Pi
embedded system using wireless GPRS connection is established in
a secured way for data transmission between them.
3. PROPOSED SYSTEM DESIGN
The system consists of Raspberry Pi board interfaced with
GPRS SIM900 module which acts as a client. In the remote the
server consists of windows system with a 3G modem connection.
The Raspberry Pi board is the central module with Broadcom
BCM2835 system-on-chip multimedia processor at 700MHz in
which CPU core is a 32 bit ARM1176JZF-S RISC processor.
SIM900 is a Quad-band GSM/GPRS module designed with a power
full single chip processor. The database used is PostgreSQL along
with PHP code for Login Web page.
3.1 BLOCK DIAGRAM
The Raspberry Pi is interfaced with the SIM900 GSM/GPRS
module via the USB port. A 3G sim is inserted in the GPRS module
for data connectivity. Figure 1 shows the block diagram of the
proposed system.
Fig.1. Block Diagram of the Proposed System
3.2 RASPBERRY PI
Hardware is a physical device that can be touched or held, like a
hard drive or a mobile phone. Software can be thought of as a
program or a collection of programs that instruct a computer on what
to do and how to do it. Below is an image of the Raspberry Pi which
describes some of the components that make up the hardware.
The hardware description of Raspberry Pi which is shown in
Figure 2 consists of the GPIO pin, SD slot, USB port and Micro
USB connector. The GPIO pins are used for serial communication
for interfacing GSM and GPS etc. It uses 16GB SD for installing the
Raspbian OS and for storage. The USB port is used for connecting
keyboard, mouse, dongle and pen drive. The power supply is given
through USB connector.
Fig.2. Hardware Components of Raspberry Pi
3.3 GSM/GPRS SIM900 MODULE
SIM900 is a complete Quad-band GSM/GPRS module designed
by SIMCom. Featuring an industry-standard interface, the SIM900
delivers GSM/GPRS 850/900/1800/1900MHz performance for
voice, SMS and data in a small form factor and with low power
consumption. It is designed as a DCE (Data Communication
Equipment). It provides a full modem serial port, which is used for
data transmission and for sending AT commands.
The SIM900 is integrated with the TCP/IP protocol along with
extended TCP/IP AT commands are developed for customers to use
the TCP/IP protocol easily, which is very useful for data transfer
applications. Figure 3 shows the SIM900 Evaluation board.
Fig 3. SIM900 Evaluation board.
3.4 HARDWARE INTERFACING
The Raspberry Pi is interfaced with the SIM900 GSM/GPRS
module through the USB port. Separate power supply is given to the Pi
and the GPRS module. Figure 4 shows the hardware interfacing of the Pi
and the GPRS module.
Fig 4. Hardware interfacing
4. SYSTEM IMPEMENTATION
Based on the system design the system implementation is done
3. INTERNATIONAL JOURNAL FOR TRENDS IN ENGINEERING & TECHNOLOGY
VOLUME 5 ISSUE 2 – MAY 2015 - ISSN: 2349 - 9303
96
and the required software’s are downloaded for the web-based login
system. Raspberry Pi is installed with Raspbian OS along with a 16
GB memory card. The web page is created using PHP and html. The
database used is PostgreSQL which save all the students records.
Finally the GPRS is initialized and connected to the server by python
code using AT commands.
4.1 POSTGRESQL
PostgreSQL is a powerful, open source object-relational database
system. It allows to extend the database with user-defined functions
by using various procedural languages, which often referred to as
stored procedures. Reduce the number of round trips between
application and database server. A database is created in the client
system which contains all the details about the students and their
unique login ids. Apache web server is installed in the client system
to view the web page created using PHP script.
4.2 PHPAND HTML
The PHP Hypertext Pre-processor (PHP) is a programming
language that allows web developers to create dynamic content that
interacts with databases. It is basically used for developing web
based software applications and also to manage database, dynamic
content, session tracking, even build entire e-commerce sites. PHP5
version was used in this project.
HyperText Markup Language is the standard markup
language used to create web pages. Html Form is embedded with
PHP script to develop a Login webpage for the student’s attendance
management system. When the Id is typed the information about the
user is fetched from the database and shown in the webpage.
4.3 PYTHON IDLE
The Raspberry Pi is a Linux based operating system
environment with python as the main programming language. To
initialize the GPRS module AT commands are used in the python
code. In the terminal of the Raspberry Pi using Minicom we can
view the messages sent and received by the SIM900 module.
When the user logs in the webpage using the login id the
information about the user is fetched from the client database and
it is shown in the webpage and at the same time the GPRS python
code is executed and the data is sent to the remote server through
TCP/IP connection. When the Login Id is typed, automatically
the PHP post function will transfer the Id to the server and the
python script is called inside the PHP code to initialize the GPRS
in order to transfer the data.
4.4 REMOTE SERVER
A windows system with a 3G modem is used as a remote server
which accepts the data from the client through GPRS. Here the data
obtained is updated to the database where the attendance is marked
for each student when he/she logs in the client side. PgAdmin III is
used to see the updated data in the server database. To view the data
sent from the client through GPRS SocketTester is used. PHP script
is written in the server side to get the data from the client and to
update the attendance in the database. Periodically the database is
updated and the attendance is marked when user logs in the client
side.
4.5 SOFTWARE ALGORITHM
The software algorithm of client-server
synchronization with attendance management system is described
below.
ALGORITHM:
Step 1 : Boot the Raspberry Pi and Login as the user.
Step 2 : Open the Login webpage created in the web browser.
Step 3 : Type the User Id and press the submit button.
Step 4 : When the submit button is pressed automatically the
GPRS module is initialized.
Step 5 : In the client side when the data is fetched from its
Database the user Id is sent to the server system.
Step 6 : In the server side the data is received and viewed in
SocketTester.
Step 7 : The PHP code in the server side automatically gets the
data and compares it with the server database and if a
match exists automatically the attendance is updated.
Step 8 : Using PgAdmin III we can view the updated records
in the server database.
5. EXPERIMENTAL RESULTS
5.1 HARDWARE SETUP
The Raspberry Pi is interfaced with the SIM900 GSM/GPRS
module. Figure 5 shows the Pi interfaced with Sim900 module.
Fig 5. Raspberry Pi interfaced with SIM900 module
5.2 LOGIN WEBPAGE
The Login web page for the students is written in PHP code and
in the client side. Figure 6 shows the Login web page of the
attendance management system.
Fig. 6 Login web page
Now when the user types the unique Id the PHP post request fetches
the data from the database and displays the information about that
4. INTERNATIONAL JOURNAL FOR TRENDS IN ENGINEERING & TECHNOLOGY
VOLUME 5 ISSUE 2 – MAY 2015 - ISSN: 2349 - 9303
97
particular user who logged into the client system.
Figure 7 and 8 shows the Login Id typed in the web page and when
the submit button is clicked the data from the database about the
particular user is shown.
Fig. 7 User typing the Login Id
Fig. 8 Information about the user fetched from the database
When the user types the wrong Id the system will show an error
message. Figure 9 shows the error message when user Id is wrong.
Fig.9 Error message when Login Id is wrong
When the information is shown in the web page automatically the
user id of that user is sent as post request from PHP script to the
python code where automatically when the id is received the GPRS
module is initialized and the data is sent to the server side using AT
commands in python script. Figure 10 shows the AT commands
executed in the terminal when the python script runs and the data is
sent to the remote system.
Fig. 10 Executing of AT commands in terminal by running python script
The received data can be viewed in the server side by using
SocketTester. Figure 11 shows the data received from GPRS in the
SocketTester application running in the server system. Once when
the data is received the PHP code in the server automatically verifies
the user id and updates the attendance in the database.
Fig. 11 Data received from GPRS in the SocketTester
Similarly for each users a unique Id will be provided and on entering
the Id they can view the details and at the same time the attendance
will be updated in the server. Figure 12 shows the details of another
user when the Id is submitted.
Fig. 12 Details of another user when the Login Id is submitted
In the server side the PHP code is written where it compares the user
Id received from the client with the Id in the server database and
when it matches automatically the attendance is updated in the server
5. INTERNATIONAL JOURNAL FOR TRENDS IN ENGINEERING & TECHNOLOGY
VOLUME 5 ISSUE 2 – MAY 2015 - ISSN: 2349 - 9303
98
database. Figure 13 shows the updated attendance in the server
database for two users.
Fig. 13 Updated attendance record in the server system
Thus the attendance management system is designed by
synchronizing the client and the server using GPRS wireless
connection.
6. CONCLUSION AND FUTURE WORK
In this project Raspberry Pi acts as a client system which stores
the details of users in database and a server machine is maintained to
administrate the databases in client machine. GPRS/GSM SIM900
module is used to synchronize the client with the server and to
transfer the data from client to server. It is a low cost attendance
management embedded system which uses wireless connection.
It can be used in rural areas for attendance system and when
there is a failure in the cabled Ethernet connection GPRS wireless
connection can be used. For future enhancement biometrics
fingerprint module can be used with Raspberry Pi for attendance
management.
REFERENCES
[1] P.Suvitha Vani, Nithyappriya.G “Establishing SSH Connection and
Interfacing GSM/GPRS Functionality with Raspberry Pi”, in Proc.
International Journal of Innovative Research in Computer and
Communication Engineering, Vol.2, Special Issue 1, March 2014.
[2] N. Bala Saidulu, V.Rajasree, “An Ftp Implementation with ARM
Processor and GPRS for Real Time Applications” in Proc. IOSR
Journal of Electronics and Communication Engineering, Vol 3,
Issue 2, pp 27-31, September 2012.
[3] Shraddha S. Chawhan, Mangesh P. Girhale, Gunjan Mankar,
“Mobile Phone Based Attendance System”, in Proc. IOSR Journal
of Computer Engineering, Vol 10, Issue 3, pp 48-50 March 2013.
[4] Girish Birajdar, “Implementation of Embedded Web Server Based
on ARM11 and Linux using Raspberry Pi”, in Proc. International
Journal of Recent Technology and Engineering, Vol 3 Issue-3, July
2014.
[5] Tinashe Nyabako, Emmanuel Manzungu, “Development of a GPRS
Internet Based Data Management System for Effective Dam
Operation in Zimbabwe”, in Proc. International Journal of
Business, Humanities and Technology, Vol. 1 No. 3; November
2011.
[6] Shivakumara M, Venkateswarlu, Shiva Yellampalli, “GPS and
GPRS based smart school management and child monitoring
system using mobile phones”, in Proc. International Journal of
Advanced Technology in Engineering and Science, Vol 3, Issue 1,
January 2015.
[7] Abdul Aziz Mohammed, Jyothi Kameswari U, “Web-Server based
Student Attendance System using RFID Technology”, in Proc.
International Journal of Engineering Trends and Technology, Vol
4, Issue 5, May 2013.
[8] Ankita Agrawal and Ashish Bansal, “Online Attendance
Management System Using RFID with Object Counter”, in Proc.
International Journal of Information and Computation Technology,
Vol 3, No 3, pp. 131-138, May 2013.
[9] http://www.raspberrypi.org
[10] http://www.tutorialpoint.com