Abstract
Ubiquitous computing and contextual services have growing importance in nowadays literature due to the current availability of smart personal devices like smartphones. It is becoming increasingly important to have a reliable way to localize users in any possible scenario. In outdoor it’s possible to use GNSS based systems like GPS or GLONASS, but for indoor scenarios a low-energy and affordable positioning system is still under heavy research. In this setting, wireless-based techniques like WiFi fingerprinting allow exploiting of currently available infrastructures to allow reasonable positioning accuracy while keeping power consumption at a minimum.
WiFi fingerprinting systems operate in two phases: one training phase, in which signals are collected with regards to different spots in the interesting area, and one usage or tracking phase in which recorded data are used to localize users in space.
The usage phase is effective and reliable, but the training phase can be very time consuming for large areas and it has to be repeated over time in order to maintain localization accuracy, in case of network structure changes or to adapt to environmental changes (like humidity, pressure or temperature).
In this paper we propose a novel framework which makes use of an appropriate Wireless Sensor Network (WSN) which allows continuous training over time, in order to achieve real-time updating of the fingerprints database with no human intervention.
Introduction
Indoor localization methodology are currently under heavy research due to chance of offering location-contextual services to users [7,9,11,12,14,19,21–23,25], and its popularity is mostly due to the availability of personal devices like smartphones which allow pervasive use of these technologies.
While in outdoor environments it’s affordable and common to detect user location using Global Navigation Satellite Systems (GNSS) like GPS or GLONASS, in indoor localization these systems are unavailable since they require direct sky visibility. Many solutions have been proposed in the latest years with regards to room-level positioning, but most have low accuracy and reliability.
Several technologies leverage wireless networks and GSM cells, or body mounted sensors arrays (accelerometers and gyroscopes) to detect user movement in space [24]. Moreover, hybrid solutions which use combined data from multiple sensors and receivers have been proposed [1–3,10].
Nowadays, widespread solutions mostly exploit range-based wireless solutions for indoor user positioning [5,7] with regards to a set of fixed sensors whose position is known beforehand. One of the most popular and reliable solutions in this setting is wireless fingerprinting [6,8], which grants accurate position accuracy while making use of currently available wireless transmitters. Position calculation is not geometrical, and does not rely on angles or distances but only on Received Signal Strength (RSS). In each spot, the set of all access point BSSIDs (which is the MAC address of the wireless transmitter) and their RSS form a unique fingerprint. All fingerprints generate a database which is called RadioMap, used to localize the users.
In this paper we present SNOT-WiFi, a framework which allows automatic and continuous training for wireless fingerprinting, using a network of wireless-enabled sensors. Any network variation triggers a fingerprint update in the database, allowing better accuracy by exploiting an always-updated RadioMap.
Related works
Indoor localization methodologies are receiving a lot of attention in the current literature. Widespread mobile devices like smartphone strongly stimulated the research in these fields. Here we report some projects closely related to our project approach.
In SMARTPOS [13] the authors describe a positioning system which combines use of WiFi fingerprinting and digital compass. The compass is used in both phases. During the training phase, each position fingerprint is recorded in four different directions. During the usage phase, this information is used to constrain database search in order to limit the effect of user body mitigation.
In A system for LEASE: Location Estimation Assisted by Stationary Emitters for IndoorRF Wireless networks [15], authors developed an algorithm which generates a radio model using sniffer and transmitters modules, deployed in the interesting area, used to analyze wireless signals behavior and generate a dynamic RadioMap which relies on the existing signal infrastructure.
In SurroundSense (mobile phone localization via ambience fingerprinting) [4] authors explore logical localization via ambience fingerprinting, using sounds, lighting and wireless networks.
Sometimes, fingerprinting systems may be also used in outdoor scenarios, aiming to reduce battery consumption with regards to satellite systems while still maintaining good accuracy. Several projects make use of GSM cells (which are however quite inaccurate), and nearby wireless networks. Since it’s very important to keep energy consumption as low as possible, several methodologies have been developed in this direction. In ZiLoc: energy efficient WiFi-fingerprinting based localization with low-power radio [20], authors use an interesting approach which is based on IEEE 802.15-4 ZigBee networks, which use little energy (around 66% less than normal 802.11 receivers) while still allowing to build an accurate localization system. However, due to the nature of networks based on this protocol, training phase is much more complex as it requires recognition and comparison of values based on beacon phases and nearest neighbor methodology.
WiFi fingerprinting based systems
Here we describe the main space of current WiFi fingerprinting systems used for indoor localization [8].
Wireless fingerprinting systems exploit local wireless networks in an interesting area to offer location-based services. In each location, the set of the detected access points and the related signal strength form an unique fingerprint that can be stored in a database for subsequent matching.
Two different fingerprints stored in a RadioMap
Two different fingerprints stored in a RadioMap
WiFi fingerprinting systems normally have two phases: one training phase and one usage phase.
During the training phase, a user records and associates several fingerprints to their physical location. Such information is stored in a database named RadioMap (see Table 1).
During the usage phase, the clients read the RSSs of nearby networks and relays these informations to a localization server which applies a matching algorithm against the RadioMap to evaluate most probable user location.
The training phase is manual and may often require several hours to properly track the interesting area, especially if the zone to be covered is large. The quality of the fingerprint largely depends on the amount of spots analyzed by the operator, which in turns lengthen the amount of time needed for training.
Additionally, it’s mandatory to recalibrate the area over time, since signals tend to change in response to network changes and/or environmental alteration like temperature, humidity and atmospheric pressure.
There are several algorithms which allows to find the most probable position from a low-definition RadioMap. It’s possible to simply use a closest match algorithm like
If the RadioMap is dense, a simple algorithm like the one above is enough to determine a good user position. Otherwise, it’s possible to approximate the position via interpolation between known positions.
Considering data from Table 1, the three records with location A represent three different hotspots which are transmitting. Over time their RSSs will change due to environmental changes and network modifications, and the fingerprints stored in the RadioMap will become stale. To refresh the fingerprints and restore system accuracy, a new training phase is needed.
We considered three main characteristics for determination of the quality of a fingerprinting based localization system: density of the RadioMap, precision and accuracy of each fingerprint.
Density is a property of the whole RadioMap, and directly depends on the number of fingerprints recorded in different spots. Using a higher density RadioMap reduces the need for interpolation in order to determine user location, but requires more work during the training phase. In Fig. 1, first column, each dot represents a fingerprint in the RadioMap.
Precision is a property of the single fingerprint, and directly depends on the number of samples recorded in a single spot. Increasing the number of samples reduces the chance of errors in readings which lead to poor system performances. In Fig. 1, second column, the circle around the dot represent the positioning error. Having higher precision leads to smaller error range.
Finally, accuracy is a property of the single fingerprint, and represents the distance between the true recording point and the associated spot on the map. If each fingerprint is well placed during the training phase, the system will have higher accuracy. In Fig. 1, third column, dots represent the recording places, stars the selected map positions.

Quality evaluation methodologies for wireless localization. Density depends on the number of fingerprints recorded in the interesting area, precision depends on the samples recorded in each place (which in turn allows more reliable values), accuracy depends on the distance between the position chosen on the map and the true position of the recording.

WSN distribution on a large area using a mesh topology. The diamond indicates the network coordinator, black dots are routers, white dots are end devices. The solid links indicate established connections while the dashed lines indicate potential connections in case of failure. The S point indicates the server which is cable connected to the coordinator. This sample structure can be superimposed to any kind of building plan or area to be monitored.
Here we introduce SNOT-WiFi system, composed of a user-segment used for localization similar to other fingerprinting-based systems, and a network of wireless receivers which are interconnected via WSN, used for real-time tracking of network status.
Sensor network
For the WSN we decided to use XBee transmitters based on the Zigbee protocol (IEEE 802.15.4) managed by an Arduino microcontroller. There are three kind of nodes in the network:
Network structures can be very simple or very complex, and it’s important to choose a proper structure in relation to the size of area to be covered. There are several topologies available:
As mentioned before, our sensor network is based on ZigBee, which is a set of network protocols [16] based on IEEE 802.15.4 protocol. It uses small and low-powered digital antennas to implement wireless personal area networks (WPAN). This protocol is normally used to implement WSNs due to its reliability, low cost per module and reduced power consumption. The protocol guarantees automatic routing optimization for information through the WSN, automatic network creation and mesh self-healing. This healing ability intervenes whenever a node suffers a failure: connections are reconfigured in order to restore connectivity and functionality.
SNOT-WiFi network for training segment
The implementation of SNOT-WiFi comes in two phases: a distribution phase and a tracking phase.
Distribution and configuration of WSN
Distribution phase is fundamental to obtain higher accuracy and precision. An appropriate network topology (star, cluster tree or mesh) must be considered in relation to the area to be covered.
Deciding network coordinator position is also important. If possible it should be positioned near the center of the WSN in order to connect to all possible routers to reduce data relays. If possible, it should be connected via cable to the database server. If the server is inside a peripheral room, it is also possible to use a simple router for relaying data.
Other modules should be distributed in the area as evenly as possible and must be linked to a physical position, which can be a room or a set of coordinates on a floor plan. Moreover, every node must be able to connect to at least another module in the WSN. Reachability of more than one node is desirable, since WSN networks are redundant, which in turn allows better system reliability.
Whenever a module needs to be moved, its position and identifying name must be immediately updated.
Tracking phase
After distribution, each sensor starts sending his detected wireless data via the WSN. All the data are gathered in the main transmission node which is connected to the database server and relays information. The server filters the incoming data in order to remove outliers and reduce jittering, and integrates the new data to obtain a new and more accurate RadioMap. If the received data is too different from the ones present in the RadioMap, the filtering algorithm may decide to completely discard old data and replace it with new ones.
This structure allows fast detection of network failures and adaptation to any environmental or structural changes.
An overlying infrastructure: Advantages and drawbacks
As explained before, SNOT-WiFi uses a separate sensors network for tracking of wireless conditions. While this may seem excessive and unnecessary, it brings several advantages:
the sensor network is totally independent from the existing network infrastructure. Any failure in the underlying network does not impact the functionality of the sensor network, and vice-versa; the sensor network ignores the network infrastructure and is therefore able to use any AP visible, without any limit or need for human intervention; modules are low powered, can be powered by batteries and last for weeks or months. This allows deployment even if there is no electricity available.
Automatic network extension
SNOT-WiFi modules, based on ZigBee protocol, are able to automatically establish new connections as soon as new modules are deployed in the interesting area. While this mostly applies to mesh topology, it’s in fact reasonable considering a network extension in order to improve tracking density (which in turns increases reliability and accuracy) in some areas or to extend the coverage to new rooms and/or structures nearby.
User segment
The proposed system only covers training phase, which is present and mandatory in every fingerprinting based systems. For the user segment, used for localization, is therefore possible to use any previously determined algorithm [14,17–19,26] without any modification.
Testing and system evaluation
For testing purposes, we built an Android app to gather wireless data every 2 seconds, simulating the WSN behavior via WiFi.

Test area map with access points and receiver positions.
The two modules, simulated using a OnePlus 3T (

Signal smoothing using Tikhonov regularization for AP signals as seen by one module.
All data was smoothed using Tikhonov regularization in GNU Octave with a regularization parameter

RSSs of two access points as seen by the two test sensors.
In Fig. 5 it’s possible to see an example of signals as seen by the two test devices. Subfigure a shows a stable AP, which was not moved for the whole test. In subgraph b we can see the signal of the unstable AP: before the network modification it was visible only by
In order to further prove the validity of the model, we conducted several experiments with a tracking device in a fixed spot. We evaluated the localization error with and without our sensors network in order to determine how the system behaves after a major network change. In Fig. 6 we report two graphs which represents localization error in meters over time for one of the aforementioned fixed spots in two distinct experiments. In the initial

Error decay after a major network change. The two graphs represent two distinct experiments, with different variation intensity.
It is worth noting that a stronger error (as in first graph) degrades much faster than a smaller error (second graph) over the first minute, and that in both cases the error returns to
In this paper we presented SNOT-WiFi, a module developed to improve fingerprinting-based localization system, based on the distribution of a wireless sensor network which can be used to rapidly build and maintain a reliable RadioMap of an interesting area. With regards to the evaluation method defined in Section 3.1 we managed to achieve:
Higher precision due to the continuous training which grants a large number of measurement over time for each fingerprint;
Potentially higher accuracy, since the distribution phase only happens once it is possible to be very precise when marking sensors deployment position on the map;
Potentially higher density, since the modules are cheap and is therefore possible to distribute a dense sensor network.
Additionally, it is possible to use different densities in different areas in order to achieve different fingerprinting precision levels.
The initial distribution phase is without any doubt way more complex than a normal training phase but does not need to be repeated over time in order to keep a reasonable precision, and grants automatic adaptation of the recorded fingerprints in case of any network structure change. As already said, having a secondary structure only focused on data gathering has several advantages, like being able to use any AP available in the area and being more reliable in case of an unexpected hardware failure in the main wireless network. The main downside is the deployment cost which is however small since modules are quite cheap and require little maintainance costs.
Future works may include implementing an automatic deployment system for modules to further reduce human error and globally improve module positioning accuracy. Moreover, while the sensor network itself is reliable against failures (since it has self-healing capabilities), the Main Transmission Node is the only one cable-connected to the database server, which of course is a potential point of failure for the entire system. A simple, automatic and reliable failure detection mechanic for this issue is currently under research.
