Smartphone Indoor Positioning System based on BLE iBeacon and Reliable region-based position correction algorithm Thai-Mai Dinh and Ngoc-Son Duong Department of Telecommunications System
Trang 1Smartphone Indoor Positioning System based on BLE iBeacon and Reliable region-based position
correction algorithm
Thai-Mai Dinh and Ngoc-Son Duong
Department of Telecommunications Systems, Faculty of Electronics and Telecommunications
University of Engineering and Technology, Vietnam National University
Ha Noi, Viet Nam Email: dttmai@vnu.edu.vn, duongson.vnu@gmail.com
Abstract—In the near future, indoor localization will become
one of the essential parts of the IoT ecosystem Accuracy in
indoor positioning is always a big challenge that requires the
endeavor of researchers Without any extra cost, Trilateration
is considered a feasible method to be able to build an indoor
positioning system In this paper, we introduce an
iBeacon-based smartphone indoor positioning system using Pedestrian
Dead Reckoning (PDR) and Trilateration method We propose
a Reliable region-based position correction method to reduce
the cumulative error caused by PDR The proposed system is
implemented on an iPhone as an application In order to evaluate
the performance of the proposed method, we perform some
real experiments in two cases: 1 only use PDR, 2 use our
proposed method The results showed that the accuracy improved
markedly
Index Terms—Bluetooth Low Energy, trilateration, iBeacon,
indoor positioning system, iOS, pedestrian dead reckoning,
smartphone sensor
I INTRODUCTION
Since its inception, Global Positioning System (GPS)
tech-nology [1] has really changed the way people pinpoint the
location and find their path on the planet The ideal condition
for GPS to achieve the highest accuracy is the
Line-of-Sight (LOS) or less obstructive object However, the rapid
development of the construction architecture somewhat hinders
the reception of GPS signals, especially in the basement or
deep hall Position errors in these cases can be up to hundreds
of meters Therefore, Indoor Positioning System (IPS) was put
into the study to be able to locate objects or people in the
in-door environment Basically, the concept of Inin-door Positioning
System inherits the characteristics of the Global Positioning
System Receivers gathering information from the transmitter
to get the location The thing makes IPS different from GPS
is the transmitter technology Instead of use satellites, IPS use
other technology based on radio frequency such as Wifi [2],
Radio Frequency Identification (RFID) [3] or Ultra-wideband
(UWB) [4] To yield the benefits as much as possible, not
only for indoor localization, a protocol running on Bluetooth
Low Energy (BLE) platform was introduced by Apple called
iBeacon Compared to previous technologies, BLE brings back
significant benefits such as low energy consumption, lowcost
hardware, and ease of deployment We can make it possible
to perform indoor positioning through received signal strength (RSS) based approach of Bluetooth signals By using iBeacon technology, researchers around the world have made concerted efforts to reduce the position error to a minimum An extensive study using iBeacon and Fingerprinting as the main approach
is presented in [5] The study looked at most of the factors that could affect the system such as beacon density, transmit power, and BLE frequency A good idea in the study is present
in [6] Group of author constructed an efficient fingerprint map that can generate and update the fingerprint database for the inaccessible region by adopting a Kriging-based interpolation method and build a multi-fingerprint database for different time periods To achieve higher accuracy, the hardware in the phone is fully utilized to combine with iBeacon technology Sensors embedded in phones are now available to compute the position of the object when knowing the initialization point A framework for combining smartphone sensors and iBeacons is presented in [7] In this work, particle filter is applied as the fusion algorithm In the prediction phase, the user position is anticipated based on PDR In the observation phase, iBeacon coordinates are used to correct the drifting position caused by PDR The error correction procedure occurs when the user enters the 4m-calibration ranges of iBeacon Another favored iBeacon-based approach is Trilateration It can help implement indoor localization without any extra requirements However, Trilateration itself has its difficulties The dilemma of this technique is the fluctuation of RSSI and distance estimation
To cope with this problem, we propose an algorithm called
”Reliable region-based position correction” Principally, we adopt a smart phone sensor-based positioning method to enhance system accuracy In the short travel distance, PDR shows a quite high accuracy We exploit the advantage of this feature to identify a reliable region around users Whenever Trilateration returns the position in this zone, that position will
be used to correct the PDR error
The remainder of paper is organized as follows After this short introduction, we describe the model of the proposed indoor tracking system in Section II Section III will present
in details the method and positioning algorithms Section IV
Trang 2provides system parameters and experimental results Finally,
Section V concludes this paper
II SYSTEMDESIGN
A Proposed System
The proposed model is described in detail in Fig 1 All
data sources are provided by the modules and sensors built
in the phone In this system, the information of interest
is the received signal strength read from the BLE chip,
acceleration on three phone axes taken from accelerometer
and orientation taken from magnetometer At first, the RSS
information from the three nearest beacons that read by BLE
chip is used in Trilateration module to estimate the position
At every step, both the step length and heading angle that
obtained from the built-in sensor are used to calculate the
user displacement in prediction phase of particle filter Then, if
the conditions of “Region-based position correction” module
is satisfied, the error correction procedure will take place
in correction/observation phase of particle filter Finally, the
estimated position will continue to be used to calculate the
position in the next step
Fig 1 System design
B iBeacon and iOS indoor positioning application
iBeacon is an Apple trademark that was introduced at
WWDC in June 2013 By using Bluetooth Low Energy
(BLE),iBeacon opens up many opportunities for the Internet
of Things (IoT) Messages from iBeacon are divided into
nested classes including UUID, Major, and Minor We can
take advantage of these classes to identify real objects such as
product groups, shops, building floors, etc With smaller size
and cheaper price, it makes more advantage for LocationBased
Services [8] than Wifi, NFC or RFID There are a number of
beacon manufacturer has deployed their beacon across various
verticals, from proximity marketing to museums (Brooklyn Museum), airlines (Luton Airport) or zoos (Los Angeles Zoo) Moreover, BLE signals from iBeacon can broadcast in an area with a radius of 100m [9] That makes it ideal for indoor positioning An indispensable thing to bring iBeacon into reality is the smartphone application Currently, iBeacon compatible with both Android and iOS OS In this study, we build an app that runs on the iOS platform To collect iBeacon signals, we use the CoreLocation framework [10] provided by Apple
III POSITIONINGALGORITHMS
A Trilateration
In our study case, Trilateration is defined as a method for obtaining the position of an object or people under an indoor environment based on RSSI information of at least 3 beacons Received signal strengths from these beacons are calculated via the formula:
P L (d) = P L (d0) + 10η log
d
d0
where, P L (d) and P L (d0) are RSSI at Euclidean distance
d and reference distance d0, respectively (in dBm). d0 is
usually chosen equal to 1 meter for the indoor environment
η represents the path loss exponent and χ ∼ N (0, σ2) The distance from the smart phone to theith beacon can be
expressed as:
d i = d P L(di)10η −P L(d0)
Unlike fingerprinting, Trilateration method does not have an offline phase However, it still requires a database of the beacons coordinate Let (u i , v i ) be the coordinates of ith
beacon The equation for each circle is represented by (z = 0):
(u − u i)2+ (v − v i)2= d2
Then, the user position is determined by the intersection of the three circles
B 1 (u 1 ,v 1 )
B 2 (u 2 ,v 2 )
B 3 (u 3 ,v 3 )
Fig 2 Trilateration Technique
Trang 3B Smartphone-Based Pedestrian Dead-Reckoning
1) Sensor–based positioning method: The development of
Micro-Electro-Mechanical Systems (MEMS) allows the
fabri-cation and embedding of very small sensors into smartphones
including accelerometers, gyroscopes and magnetometers, etc
Information from these sensors is used to detect the human
movement The solution only requires these inertial sensors
called is Pedestrian Dead-Reckoning or PDR This method
computes the user’s displacement using the previous position,
step length, and the current direction through the equation as
follow:
x k
y k
=
x k−1
y k−1
+ L k
cos θ k
sin θ k
(4)
where, [x k , y k]T is the coordinates of the position in
two-dimensional space,L is the step length and θ k the direction of
the user at timek The factors that directly affect the accuracy
of this method will be presented below
2) Step Length Estimation: In order to predict the next
step, information of the step length must be known In this
paper, step length is defined as the distance from the top of
the foot to the other In practice, the length of a step definitely
depends on many factors Walking speed and personal height
is the most impact The step length will change if the user
changes speed This problem can be solved by integrating
the acceleration to update speed, thereby updating footsteps
Other factors influence to step length is gender and personal
height The solution to this problem is to set the average
step length According to statistics, the average step length of
women is 0.67m, this number is 0.75m for men [11] However,
adding this factor to calculate the length of footstep will
make the system more complicated To reduce the complexity
of calculations, we propose to set the value of footsteps to
average value between men and women that fixed and equals
to 0.71m
3) Real-time Step Event Dectection: Errors due to
over-counting or underover-counting a step will be worse than accurately
determining the length of a step Detecting a step can be
determined by information from the accelerometer Basically,
the sign to detect a step is the change in acceleration on the
vertical axis Accordingly, in a one-step cycle, when the user
lifts the foot and moves forward, this acceleration will reach
the maximum and decrease to a minimum when the foot hit
to the ground So, a step is detected when:
where, P p and P n are maximum and minimum peak at time
t, respectively and δ is the threshold level.
C Region-based position correction method
Based on actual testing and previous studies, when knowing
the initial point, PDR technology shows very high accuracy
in short-range movement The accuracy of this technique will
be diminished when the user moves in a long distance This
phenomenon occurs due to noise from the sensor, so the
error correction procedure needs to be done to bring the
0 100 200 300 400 500 600 700 800 900 1000
Time (1/50s) -0.3
-0.2 -0.1 0 0.1 0.2
2 )
Fig 3 Change of vertical acceleration.
user position to the right trajectory In order to solve this problem, we introduce a method that corrects the error by using Trilateration We determined that, after a short time of moving, the position error caused by PDR is not too much,
so a region with a radius equal to D is drawn to indicate the area where the user is likely to be in there The error correction procedure occurs when the position calculated by the Trilateration technique located inside the circle Fig 4 describes in detail the proposed correction method Normally,
D 2L with the reason that the PDR module can count
missing or redundant one or two steps
True path
Drifted path
T
P
Fig 4 Visualized view of proposed correction method
D Particle filter – based position fusion
Due to the drift caused by the noise in the sensors, PDR only achieves high accuracy in short distances This error will
be very serious if not corrected To ensure accuracy for the entire system, we decided to utilize particle filter [12] as the fusion algorithm Assume each particle is defined by:
p i =
x i
y i
, w i
, i = 1, 2, , N (6)
where [x i , y i]T is the coordinates in the two-dimensional space
of the ith particle, w i is the weight and N is the number of
particles
1) Initialization: At time t = 0, the position of the particles
are randomly selected around the point [x0, y0]T:
x i0
y i0
=
N (x0, σ2)
N (y0, σ2)
(7)
Trang 42) Prediction: In each step, movement state and heading
direction observed from the sensor is used to predict the
position of the particles in the next step:
x i k
y k i
=
x i k−1
y i k−1
+ L k
cos θ k
sin θ k
(8)
3) Correction: Suppose at time t, Trilateration returns
positionT = [u t , v t]T Then, the distanced tbetween current
position and T can be calculated If d t > T , this mean
the estimated position of Trilateration is not reliable enough
to correct errors for PDR On the contrary, T will be used
to correct errors for PDR Distance from particles to T is
determined by:
d i t=
(u t − x i
The weight of particles is then updated via the SIR method:
ˆ
w t i= ˆw i
t
(10) whereP
d t |d i
t
is important density and:
P
d t |d i
t
= √1 2πσexp
− (d t − d i t)2
2σ2
(11) Then, the weight of each particle is normalized as follows:
w i t= N wˆi t
t
(12)
4) Position Updating: Finally, the user position is
x t
y t
= N i=1 N x i t w i t
(13)
5) Sampling: The generality of the particle filter will be
lost due to degradation of samples This phenomenon occurs
when the variance of the weights increase over time Then,
weight distribution becomes progressively more skewed So,
effort in updating particles whose contribution to final estimate
is almost 0 and the position after updating depends only on
the sample with the largest weight Therefore, the re-sampling
procedure should be performed when the total weight of the
particles is less than a certain threshold The re-sampling
procedure replaces the entire old sample with the new N
weighted samples and equals N1
IV EVALUATION
A Experiment Setup
The experiment was carried out on the 1st floor of G2
building, University of Engineering and Technology
(UET-VNU), that is a semi-open indoor environment with three open
entrances, rooms and some of the tree The size of the test
area is 25m x 15m The location of the experiment and the
position of the beacons are shown in Fig 5 In this work,
we use beacon produced by Estimote Beacon is designed as
a miniature computer that builds on a 32-bit ARM Cortex
M0 CPU with an nRF51822 BLE chip The distance between
beacons is approximately 6 m, the beacon was mounted at a
TABLE I
S YSTEM PARAMETERS
Opera System iOS 12.1.2 Beacon 6 Proximity Estimote Beacons Bluetooth Interface BLE v4.0/ 2.4 GHz
Advertising Interval 100 ms Broadcasting Power 0 dBm Broadcasting Range 50 m Path loss exponentη 2.42
3
8S
6WDUW3RLQW
8S
\
Fig 5 The position of beacons and true path on the testbed
height of 1.4 m above the ground The detailed parameters of the system are given by Table I Then, the user holds the phone close to the body and moves around the experimental area following the true path in order to the application to record the position This app applies the Root Mean Square Error criterion to evaluate the performance of the proposed method Suppose (x tp , y tp ) and (x est , y est) are the true positions and the estimated position by the proposed method at time t,
respectively Then the error is defined by:
RM SE =
N
i=1
(x tp − x est)2+ (y tp − y est)2
B Experiment Results
In Fig 6, we easily see the drift of PDR trajectory The cause of this situation is due to sensor noise or over-counting
or under-counting a step In the case of using only PDR, since
no error correction method is applied, the cumulative error increases sharply after the PDR module count excess a step
As a result, the final position is far from the starting point Our proposal shows the effectiveness when occasionally dragging the wrong to the near true position Errors in two cases is shown in Fig.7
V CONCLUSION AND FUTURE WORK
In this paper, an indoor positioning system based on iBeacon and phone sensors was presented In particular, the embedded sensor is utilized to calculate user displacement In order to correct the trajectory drift from PDR, we propose a Trilater-ation based error correction method Due to the instability of RSS, the estimated position by Trilateration is not completely reliable To be able to correct the error of PDR by Trilateration
Trang 50 2 4 6 8 10 12 14 16 18 20
x-Axis 1
2
3
4
5
6
7
8
9
10
11
Proposed Method PDR True Path
Overcounting
Correct Point
Fig 6 Trajectories of true path and tracked path in two experiments
&
&
&
&
&
&
&
&
#(
Fig 7 Cumulative error of proposed method and PDR
method, we use a limit of a circle with the center is the user to
indicate the reliable region The error correction procedure will
[3] Gharat, V., Colin, E., Baudoin, G and Richard, D “Indoor performance
analysis of LF-RFID based positioning system: Comparison with
UHF-RFID and UWB,” 2017 International Conference on Indoor Positioning
and Indoor Navigation (IPIN), Sapporo, 2017.
take place whenever the user position returned by Trilateration lie in this circle In addition, we choose particle filter as the fusion algorithm to cope with the non-linearity of the system
We have built an application to test the correctness of the system The results show that the accuracy is clearly improved compared to PDR
ACKNOWLEDGMENT
This work has been supported/partly supported by Viet-nam National University, Hanoi (VNU), under Project No QG.19.25
REFERENCES
[1] B Hofmann-Wellenhof, James Collins, Herbert Lichtenegger Global
Positioning System: Theory and Practice Springer-Verlag GmbH 2000.
[2] Zhuang, Y., Li, Y., Qi, L., Lan, H., Yang, J and El-Sheimy, N “A
Two-Filter Integration of MEMS Sensors and WiFi Fingerprinting for Indoor Positioning,” IEEE Sensors Journal, vol 16, pp 5125-5126, Jul 2016.
[4] Ren, A., Zhou, F., Rahman, A., Wang, X., Zhao, N and Yang, X “A
study of indoor positioning based on UWB base-station configurations,”
2017 IEEE 2nd Advanced Information Technology, Electronic and Automation Control Conference (IAEAC), China, 2017.
[5] Faragher, R and Harle, R “Location Fingerprinting With Bluetooth Low
Energy Beacons.” IEEE Journal on Selected Areas in Communications,
vol 33, pp 2418-2428, Nov 2016.
[6] Zuo, J., Liu, S., Xia, H and Qiao, Y “Multi-Phase Fingerprint Map
Based on Interpolation for Indoor Localization Using iBeacons,” IEEE
Sensors Journal, vol 18, pp 3351-3359, Apr 2018.
[7] Chen, Z., Zhu, Q., Jiang, H and Soh, Y “Indoor localization using
smartphone sensors and iBeacons,” 2015 IEEE 10th Conference on
Industrial Electronics and Applications (ICIEA), New Zealand, 2015.
[8] Dey, A., Hightower, J., de Lara, E and Davies, N “Location-Based
Services,” IEEE Pervasive Computing, vol 9, pp 11-12, Mar 2010.
[9] Estimote, Inc (2019) Estimote (Version 2.42.5) [Mobile application software] Retrieved from https://apps.apple.com/us/app/estimote/id686915066
[10] Developer.apple.com (2019) Core Location — Ap-ple Developer Documentation [online] Available at: https://developer.apple.com/documentation/corelocation [Accessed
17 Jul 2019]
[11] Tianjian Ji, “Frequency and velocity of people walking,” Institution of
Structural Engineers, vol.83, pp 36 - 40, Mar 2005.
[12] Gustafsson, F., Gunnarsson, F., Bergman, N., Forssell, U., Jansson,
J., Karlsson, R and Nordlund, P “Particle filters for positioning,
navigation, and tracking,” IEEE Transactions on Signal Processing, vol.
50, pp 425 - 437, Feb 2002.
... cases is shown in Fig.7V CONCLUSION AND FUTURE WORK
In this paper, an indoor positioning system based on iBeacon and phone sensors was presented In particular, the... International Conference on Indoor Positioning< /small>
and Indoor Navigation (IPIN), Sapporo, 2017.
take place whenever the user position returned by Trilateration lie... Jiang, H and Soh, Y ? ?Indoor localization using
smartphone sensors and iBeacons,” 2015 IEEE 10th Conference on< /small>
Industrial Electronics and Applications