0% found this document useful (0 votes)
95 views5 pages

A Smart Bus Tracking System Based On Location-Aware Services and QR Codes 4

Uploaded by

Amanuel Seid
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
95 views5 pages

A Smart Bus Tracking System Based On Location-Aware Services and QR Codes 4

Uploaded by

Amanuel Seid
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

A Smart Bus Tracking System Based on Location-

Aware Services and QR Codes


Süleyman Eken Ahmet Sayar
Department of Computer Engineering Department of Computer Engineering
Kocaeli University Kocaeli University
Kocaeli, Turkey Kocaeli, Turkey
[email protected] [email protected]

Abstract—When it comes to taking the public transportation, Real-time vehicle tracking and management system has
time and patience are of essence. In other words, many people been the focus of many researchers, and several studies have
using public transport buses have experienced time loss because been done in this area. Verma and Bhatia [2] stated in their
of waiting at the bus stops. In this paper, we proposed smart bus study that GPS could be used in many applications and it is
tracking system that any passenger with a smart phone or mobile possible to follow routes and locations driven a vehicle by
device with the QR (Quick Response) code reader can scan QR means of GPS. They develop a web based system presenting
codes placed at bus stops to view estimated bus arrival times, vehicles’ locations to the user. Gong et al. [3] improved
buses’ current locations, and bus routes on a map. Anyone can approach to predict the public bus arrival time based on
access these maps and have the option to sign up to receive free
historical and real-time GPS data. After analyzing the
alerts about expected bus arrival times for the interested buses
and related routes via SMS and e-mails. We used C4.5 (a
components of bus arrival time systematically, the bus arrival
statistical classifier) algorithm for the estimation of bus arrival time and dwell time at previous stops are chosen as the main
times to minimize the passengers waiting time. GPS (Global input variables of the prediction model. They concluded that
Positioning System) and Google Maps are used for navigation their model outperforms the historical data based model in
and display services, respectively. terms of prediction accuracy. Guo et al. [4] integrated the
Victoria Regional Transit System with appropriate
Keywords— QR codes; GPS; Smart bus stops; C4.5 algorithm; communication technologies to develop a corresponding
Smart phones, Interactive maps Smartphone application. In this smart bus system, users can
access real-time passenger information such as schedules, trip
I. INTRODUCTION planners, bus capacity estimates, bike rack availability and bus
Public transport has become a part of live. Most people stop locations, via Smartphone, on computers and at bus stops.
reach from homes to workplace or school using public El-Medany et al. [5] supposed cost effective real time tracking
transportation. People can lose time in transportation because system that provides accurate localizations of the tracked
of unwanted waiting. Also, people have the right to know vehicle by using GPS and GPRS modules. By means of GPS
where the bus is now and how long time it takes bus to reach receiver, proposed system has ability of tracking current
bus stop. The services provided to passengers by transport position of the vehicle in any specific time. They tested
systems are very important. There are two kinds of service that efficiency of the system in different areas on Kingdom of
all transport systems must provide: (i) route and schedule Bahrain using Google maps. There are relevant works not only
information (maps, schedules, and information on connections) highway transit systems, but also other tracking systems for
(ii) basic information (fare policy, stop locations, etc.). These ships, flights trains, and etc. Flightradar24 [6] is a flight tracker
types of information are delivered in a variety of ways: (a) showing live air traffic from all over the world. Flightradar24
traditional delivery methods include printed maps and schedule combines data from several data sources including ADS-B
cards, and “rider guides.” These are often distributed physically (Automatic dependent surveillance-broadcast), MLAT
onboard buses and at key transit locations. (b) As with other (Multilateration) and FAA (Federal Aviation Administration).
types of information, the majority of distribution has moved to The ADS-B, MLAT and FAA data is aggregated together with
the Internet. Nearly all transport systems now provide service schedule and flight status data from airlines and airports to
information on their websites where users can either view it create a unique flight tracking experience. The National Rail
electronically or print it at home or in their office. (c) Third- Enquiries train timetable site [7] shows all trains currently on
party distribution systems have also become increasingly approach to a particular station. Trains and stations are shown
common. Most major transport systems now present route and in different colours. Trains move in approximately real time, or
schedule information through Google Transit, and smaller rather quicker if user checks the speed-up box. Marine Traffic
transit systems are also moving in this direction. Many project [8] provides free real-time information to the public,
transport systems are also now making their Google Transit about ship movements and ports, mainly across the coast-lines
data publicly available for use in the development of third party of many countries around the world. The initial data collection
smartphone applications [1]. If we look in terms of delivering is based on the Automatic Identification System (AIS). Similar
service information, our study is included in the last way. systems have been developed for purposes of monitoring and

978-1-4799-3020-3/14/$31.00 ©2014 IEEE


Authorized licensed use limited to: University of Manchester. Downloaded on December 02,2022 at 20:52:01 UTC from IEEE Xplore. Restrictions apply.
management of vehicles, protection against the thefts and subsidiary, Denso Wave in 1994. Data is encoded in QR
reducing the probability of loss [9-11]. optically readable format using QR code generators. So, QR
code can be captured and decoded by smart phones. It is
In this paper, we proposed a location-aware smart bus stop capable of handling up to several hundred times more
system that any passenger with a smart phone or mobile device information than the traditional bar codes unlike conventional
can scan QR codes placed at bus stops to view bus arrival bar codes are only capable of storing twenty digits. According
times, and buses current locations on the maps. Users can also to different versions of QR code, distinct information storage
view bus routes on the map with their geographic and non- capacity may be used (see Fig. 2). The cost of information
geographic attributes. We used C4.5 algorithm for estimation transfer via QR code is extremely low as compared with other
of bus arrival time. GPS and Google Maps are used for technologies where specific hardware is always required [12].
displaying current locations of buses on the maps, together Consequently, QR code is the most widely used information
with the related route information. If users are registered to the container that can be applied to different printed materials (e.g.,
system, they can be informed of routes and bus arrival times posters, books or magazines) and places (e.g. bus stops, store
via SMS and e-mails. windows, etc.).
The rest of the article is structured as follows. In the second
section, system architecture is proposed. Third section presents
user services and user interfaces in the proposed system.
Conclusion and some future enhancements are given at the last
section.
II. SYSTEM ARCHITECTURE
The components and architecture of the proposed system
consists of four stages as shown in Fig. 1. These are (i)
scanning QR codes placed at bus stops and listing buses
according to passengers’ desires, (ii) searching buses and/or (a) 10 alphanumeric characters (b) 100 alphanumeric characters
bus stops and showing timetables, (iii) showing bus stops and
Fig. 2. QR codes with respect to the number of modules in symbol area
routes on the Google map, and (iv) estimating bus interval time
with machine learning algorithms and finally sending this There are many different applications [13-17] in different
information to users via SMS and/or e-mails. Each stage is areas built based on QR codes. It is initially developed as an
detailed in the following subsections. alternative technology to UPC bar codes. However, its
applications include product tracking, item identification, time
Scanning QR codes
and listing buses
tracking, document management, general marketing, and much
more. Raj et al. [18] proposed a cost effective and 3D (latitude,
longitude and altitude) smart phone solution which helps in
indoor navigation with the help of QR codes. Accuracy of
Searching buses/stops proposed system is high and compared with Bluetooth, AGPS
and showing timetable (Assisted Global Positioning System) and RFID (Radio-
frequency identification). Costa-Montenegro et al. [19] present
QR-Maps, a simple and efficient tool that can be used in
smartphones to obtain accurate indoor user locations. This tool
Showing bus stops and employs QR-Codes containing a short text which indicates
routes on the Google locations shown within a custom Google map.
map
We use QR codes for the purpose of providing locations of
bus stops. QR codes contain bus stop location information such
as latitude and longitude (see Fig. 3). When QR codes, which
Estimating Bus arrival
time and sending to are placed at bus stops, are scanned by passengers, they can
interested passengers view estimated bus arrival time, and bus’s current location.
Users can also view routes of selected buses on the map.

Fig. 1. Architecture of web based smart bus stop system Bus stop location details QR code
(latitude and longitude) encoder
A. Usage of QR Codes in the System
With the increasing usage of smart phones and wireless
network infrastructures, passengers are getting acquainted with Fig. 3. Contents of QR codes placed at bus stops
obtaining information about timetables, bus arrival time and
etc. by means of mobile phones. QR code was created as an
information container forming of two-dimensional by Toyota

Authorized licensed use limited to: University of Manchester. Downloaded on December 02,2022 at 20:52:01 UTC from IEEE Xplore. Restrictions apply.
B. Google Map API and GPS 4. Recur on the sub-lists obtained by splitting on best
To locate any bus on a map, its location in latitude and attribute, and add other nodes as children of best attribute
longitude (lat, long) coordinate values have to be obtained. node
These values are obtained from GPS receiver in each bus. In the proposed system, C4.5 algorithm is used for
Google serves its map images via a simple REST estimation of bus arrival times. In order to use this algorithm,
(Representational State Transfer) API enhanced with Java training data set reflecting past experiences is prepared as seen
Script and AJAX technologies. The system utilizes map API in in Fig. 4. Columns of the data set are as follows: data id, late
open source JAVA framework with the standard libraries. A time (how long time a bus is late), reason for being late
sample http query to request a map is given below. (breakdown, traffic accident, and passenger density), weather
http://maps.google.com/maps/api/staticmap? condition (rainy, normal, and snowy), scheduled time table,
route number and bus stop id.
After the question mark, query parameters and their
constraints are appended. Parameters’ numbers and their values
change depending on what users need from map services. The
parameter lists are separated by the ampersand (&) symbol. An
example query for a specific map is given below.
http://maps.google.com/maps/api/staticmap?center=Kocaeli
+University,+İzmit,+Turkey&zoom=14&size=512x512&map
zmit,+Turkey&zoom=14&size=512x512&map
type=roadmap

C. Estimation of Bus Arrival Time


As we know the classes of training set, we can use different
Fig. 4. Data set example used for estimation of bus arrival time
algorithms to estimate the classes of new instance set by
discovering the way the attributes-vector of the instances To estimate expected arrival times at any specific bus stop,
behaves. One of these algorithms is Decision Trees (DT’s). A it is required to make some arrangements on data set.
tree is either a leaf node labeled with a class linked to two or Depending on the schedule and physical conditions for a route,
more sub-trees. If we classify some instance, firstly we have to late times might change in a very large range. Let’s assume it
get its attribute vector and then apply this vector to the tree. To has a range from 1 to 30 minutes, and chunk this range into 6
complete the classification process, the tests are performed into sub-ranges, such as 1-5 min for class 1, 6-10 min for class 2,
these attributes until reaching one or other leaf. etc., Remainder of this section explains the application of C4.5
In early 1980s, a decision tree algorithm called as ID3 algorithm on a given dataset (see Fig. 4) to estimate actual
(Iterative Dichotomiser) was developed by J. Ross Quinlan arrival time.
[20]. This approach is extended by taking into consideration If S is any set of samples, let freq (Ci, S) stand for the
concept learning systems described by E.B. Hunt, J. Marin, and number of samples in S that belong to class Ci (out of k
P. T. Stone [21]. C4.5 algorithm (statistical classifier) possible classes), and S denotes the number of samples in
presented by Quinlan is based on the ID3 algorithm. Its
the set S. Let’s explain C4.5 on our simple data set. According
functionality is to find simple DT’s [22].
to data given Fig. 4, k equals to 6 andSequals to 10. Then
C4.5 algorithm has a few premises cases: the entropy of the set S (Info(S)):
• If all samples (cases) belong to same class, it creates a leaf k
(freq(Ci , S) freq(Ci , S)
and the leaf is returned to choose that class. Info(S)=-  (( ) ⋅ log2 ( )) (1)
S S
• C4.5 creates a decision node higher up the tree using the i=1

expected value of the class; in case of none of the features Info(S)=-(1/10)*log2(1/10)-(4/10)*log2(4/10)-


provide any information gain. (3/10)*log2(3/10)-(1/10)*log2(1/10)-(1/10)*log2(1/10)= 2.046
bits
• In case of instance of previously-unseen class is
encountered; C4.5 creates a decision node higher up the After set T has been partitioned in accordance with n
tree using the expected value. outcomes of one attribute test X:
Ti
Infox(T) =- ∑ni=1 (   .Info(Ti ))
Pseudo-code of C4.5 algorithm is as following: (2)
T
1. Check for premises cases
Gain(X) = Info(T) - Infox(T). It represents information gain.
2. For each attribute, calculate the potential information
provided by a test on the attribute. Also calculate gain Attribute selection is done with the highest gain value.
information that would result from a test on the attribute. Inforeason(S)=(2/10)*(-2/2*log2(2/2))+(6/10)*(1/6*log2(1/6)-
3. Depending on the current selection criterion, find the best 2/6*log2(2/6)-3/6*log2(3/6))+(1/10)*(-1/1*log2(1/1))+(1/10)*
attribute to split on. (-1/1*log2(1/1))= 0.875 bits
Gain(reason) = 2.046-0.875=1.171bits

Authorized licensed use limited to: University of Manchester. Downloaded on December 02,2022 at 20:52:01 UTC from IEEE Xplore. Restrictions apply.
Similarly, Gain(weatherCon) is calculated as 1.010 bits.
Attribute “reason” gives the highest gain of 1.171 bits in
our example, and therefore this attribute will be selected for the
first splitting. After splitting on best attribute, we add other
nodes as children of best attribute node and we do same
operations recursively. Each leaf’s path can be transformed into
an IF-THEN rule to make a decision tree model more readable.
III. USER SERVICES AND INTERFACES
General flow of the proposed application is as follows:
• Passengers with smart phones or mobile devices with the
QR code readers scan QR codes placed at bus stops. After
scanning QR codes, theyare decoded via ZXing (Zebra
Crossing) library [23].
• Route numbers of buses are listed for corresponding bus
stops (see Fig. 5). Passengers choose one or more of them Fig. 7. Viewing bus information
to view interested and estimated bus arrival times and
current location of the selected bus (see Fig. 7). IV. CONCLUSION AND DISCUSSIONS
In this paper, we have presented a smart bus tracking
• Passengers can view routes of buses on maps. As seen in
system. It is based on GPS, GSM, QR coding and Google’s
Fig. 6, the green markers represent buses, the red markers
map technologies. The proposed system, basically tracks the
represent bus stops and the blue line points the route of the
busses, estimates their arrival times at specific bus stops and
bus. Users can utilize Google map’s mapping tools such as
informs the users through e-mails and SMSs. The system
zooming in/out, panning, dragging and dropping to get
prevents passengers unnecessarily to wait at bus stops and
better view for the selected route and buses.
enables them to use their time more efficiently.
• If users are registered to the system, they can be informed In the future, we plan to enhance the system with some
of the routes and the busses they are interested in, through other estimation tools and statistical analysis. This might be
e-mails and SMSs. used not only by public users but also by decision makers in
the local municipalities. Moreover, since the system is
developed with open standards and open sources, it is easily
extended with future technologies according to users’ needs.

REFERENCES
[1] The Official Website of The Massachusetts Department of
Transportation, Enhance Public Information on Existing RTA
Information and Potential Improveents,
http://www.massdot.state.ma.us/, (accessed 19 January 2014).
[2] P. Verma, J.S.Bhatia, “Design and Development of GPS-GSM based
Tracking System with Google Map based Monitoring”, International
Journal of Computer Science, Engineering and Applications (IJCSEA),
vol. 3, no. 3, pp. 33-40, 2013.
[3] J. Gong, M. Liu, S. Zhang, “Hybrid dynamic prediction model of bus
arrival time based on weighted of historical and real-time GPS Data”,
2013 25th Chinese Control and Decision Conference (CCDC), pp. 972-
976, 2013.
Fig. 5. Interface of proposed application [4] X. Guo, E. Huang, B. Hung, L. Juras, Design a Smart Bus System, Dept.
Electrical and Computer Engineering, University of Victoria, Canada,
2012.
[5] W. El-Medany, A. Al-Omary, R. Al-Hakim, S. Al-Irhayim, M.Nusaif,
“A Cost Effective Real-Time Tracking System Prototype Using
Integrated GPS/GPRS Module”, Sixth International Conference on
Wireless and Mobile Communications, pp. 521-525, 20-25 September,
Valencia, 2010.
[6] http://www.flightradar24.com/ (accessed 19 January 2014).
[7] http://traintimes.org.uk/map/tube/ (accessed 19 January 2014).
[8] http://www.marinetraffic.com/ais/home (accessed 20 January 2014).
Fig. 6. Showing bus stops and routes on the Google map [9] S. Pooja, “Vehicle Tracking System Using GPS”, International Journal
of Science and Research (IJSR), vol. 2, no. 9, pp. 128-130, 2013.

Authorized licensed use limited to: University of Manchester. Downloaded on December 02,2022 at 20:52:01 UTC from IEEE Xplore. Restrictions apply.
[10] T. Le-Tien, V. Phung-The, “Routing and Tracking System for Mobile [17] T. Anezaki, K. Eimon, S. Tansuriyavong, and Y. Yagi, “Development of
Vehicles in Large Area”, Fifth IEEE International Symposium on a human-tracking robot using qr code recognition,” in Proc. Korea-
Electronic Design, Test & Applications, pp. 297-300, 2010. Japan JointWorkshop Frontiers of Computer Vision (FCV), pp. 1-6,
[11] F.M. Franczyk, J.D. Vanstone, “Vehicle warning system”, Patent 2011.
number: 7362239, Issue date: 22 April 2008. [18] C.P.R. Raj, S. Tolety, C. Immaculate, “QR code based navigation
[12] Lin Yu-Hsun, Chang Yu-Pei, Wu Ja-Ling, “Appearance- system for closed building using smart phones,” in Proc. International
Based QR Code Beautifier,” IEEE Transactions on Multimedia, vol. 15, Multi-Conference on Automation, Computing, Communication, Control
no. 8, pp. 2198-2207, 2013, and Compressed Sensing (iMac4s), pp. 641-644, 2013.
[13] D. Haisler and P. Tate, “Physical hyperlinks for citizen interaction,” in [19] E. Costa-Montenegro, F. J. González-Castaño, D. Conde-Lagoa, A. B.
Barragáns-Martínez, P. S. Rodríguez-Hernández, F. Gil-Castiñeira,
Proc. ACM MM’10, pp. 1529-1530, 2010.
“QR-Maps: an Efficient Tool for Indoor User Location Based on QR-
[14] T. Nikolaos and T. Kiyoshi, “Qr-code calibration for mobile augmented Codes and Google Maps,” The 8th Annual IEEE Consumer
reality applications: Linking a unique physical location to the digital Communications and Networking Conference - Special Session on
world,” in Proc. ACM SIGGRAPH 2010 Posters, ser. SIGGRAPH ’10, Location Aware Technologies and Applications on Smartphones, 928-
2010. 932, 2011.
[15] B. Erol, J. Graham, J. J. Hull, and P. E. Hart, “A modern day video [20] J.R. Quinlan, “Learning decision tree classifiers,” ACM Computing
flip-book: Creating a printable representation from time-based media,” Surveys (CSUR),” vol. 28, no. 1, pp. 71-72, 1996.
in Proc. ACM MM’07, pp. 819-822, 2007. [21] E.B. Hunt, J. Marin, P.T. Stone, Experiments in Induction. Academic
[16] T.-W. Kan, C.-H. Teng, and W.-S. Chou, “Applying qr code in Press, 1966.
augmented reality applications,” in Proc. ACM VRCAI ’09, pp. 253- [22] J.R. Quinlan, C4.5: Programs for Machine Learning, Morgan Kaufmann
257, 2009. Publishers, 1993.
[23] https://github.com/zxing/zxing (accessed 23 January 2014).

Authorized licensed use limited to: University of Manchester. Downloaded on December 02,2022 at 20:52:01 UTC from IEEE Xplore. Restrictions apply.

You might also like