iBeacon RSSI Anomaly Detection for Indoor Positioning

There’s new research on iBeacon Indoor Positioning Method Combined with Real-Time Anomaly Rate to Determine Weight Matrix that uses a weighted Levenberg-Marquadt (LM) algorithm to determine the location of ibeacons.

The solution processes the received signal strength (RSSI) to determine anomaly rates of beacons and hence filter out abnormal signals. This helps to overcome the problems of unreliable signal strength in indoor locations due to reflections and obstacles.

The system achieves an average positioning error of 1.5m.

Read about Using Beacons, iBeacons for Real-time Locating Systems (RTLS)

What is iBeacon Measured Power?

Most beacons’ configuration app have a setting for iBeacon ‘measured power’ or ‘RSSI at 1m’. This doesn’t change the power output by the beacon. Instead, it’s a value that’s put into the advertising data that declares to receiving devices what the power should be at a distance of 1 meter from the beacon. Receiving devices such as smartphones and gateways can use this to help calibrate a calculation to determine the rough distance from the beacon.

iBeacon Measured power setting

You don’t usually change this value and it’s actually rarely used. In most cases the value is irrelevant and can be ignored. However, if your app or receiving device does use this value, it’s best to first do some tests to see what the power level is in your particular situation. Things like the physical environment, blocking and beacon orientation can affect the actual power level at 1m. Set the value according to your particular scenario.

Read more about transmitted power (as opposed to measured power)

iBeacon Deployment Parameters for Locating

Researchers from the The Hong Kong Polytechnic University have a new paper on Performance Evaluation of iBeacon Deployment for Location-Based Services in Physical Learning Spaces (pdf) that tests environmental and deployment factors, indoors and outdoors, related to using ibeacons for locating. It provides recommendations for iBeacon deployment in terms of location, density, transmission interval, fingerprint space interval and collection time.

iBeacon deployment

The paper provides a great introduction to positioning using beacon received signal strength (RSSI). It describes trilateration and fingerprinting methods for determining location.

Key insights are:

  • High temperature, strong wind and blocking by pedestrians degraded the signal strength.
  • Pedestrians traffic blocking the line of sight caused the most signal attenuation and variation.
  • High air temperature caused significant increase of packet loss that affected the RSSI.
  • Strong wind reduced the signal strength but didn’t affect the stability of signals.
  • Trees and nearby vehicle traffic didn’t have any negative effects on signals.
  • Lower error rates were observed when beacons were deployed on the ceiling as opposed to on the wall.
  • Positioning accuracy improved with ceiling placement due to the reduction of obstructions.
  • If ceilings are too high or ceiling deployment is impracticable wall mounted iBeacons should be placed as high as possible.
  • For fingerprinting, sample at 2m grid intervals for 6s to 10s at each point. Avoid having too many beacons as this won’t improve the positioning accuracy. A transmission interval of 100ms is detrimental to the positioning accuracy. 417ms is better.
  • For fingerprinting, positioning accuracy varies greatly according to the what is in the room.

The paper mentions that beacon UUID, major and minor are used to uniquely identify beacons. While this is true in the context of detecting using apps, most locating systems use gateways. Gateways use the Bluetooth MAC address to uniquely identify beacons and the advertising type, iBeacon, Eddystone or other, is irrelevant. Using gateways as receivers is also a solution to the problem of variability in receiving capability across smartphones.

The study only considered one beacon type and two receiving smartphones. At Beaconzone, we recommend experimenting with the actual hardware in the actual environment as, being wireless radio, optimum settings and can vary considerably.

Read about location accuracy

Read about Using Beacons, iBeacons for Real-time Locating Systems (RTLS)

Social Distancing Bluetooth RSSI Calibration

We previously described how social distance beacons differ from ordinary beacons. Devices advertise AND scan rather than just advertise OR scan. The principle is the same with with smartphones using the Apple/Google Exposure Notification API.

The problem with smartphones is that their transmit and receive capabilities vary widely. The received signal strength (RSSI) is inconsistent across types of smartphone and you can’t determine distance reliably. Apple and Google have mitigated this problem by attempting to create a database of calibration values (csv).

The calibration data is useful for Bluetooth developers creating solutions across devices. However, it’s of no use for 3rd party contact tracing as only Government agencies can use the Exposure Notification API and Apple is banning Covid related apps.

Read about Beacons for Workplace Social Distancing and Contact Tracing.

Using AI Machine Learning to Infer Distance

There’s new research by Guglielmo Marconi University and University of Rome “Tor Vergata”, Italy on Indoor Localization System Based on Bluetooth Low Energy for Museum Applications.

The use of location in museums allows personalised tour guidance and on-demand exhibit information to be provided. Location also allows analysis of visitor flows to better design spaces through the identification of choke points and redundant areas.

Museum Bluetooth Location

The system had visitors emit Eddystone beacon advertising received by ESP32-based devices acting as gateways to a server.

Museum Bluetooth Location System

The research is novel in that it uses AI machine learning on the received signal strength (RSSI) to infer location. This helps overcome the problems of variable signal strength experienced in indoor locations due to reflections and obstacles. It also prevents the need for fingerprinting the entire area which is time consuming and fails when the physical situation changes.

RSSI Location for Museum

The method achieved accuracy of the order of 2m and this improved to 1m with the use of more receivers.

Read about Using Beacons, iBeacons for Real-time Locating Systems (RTLS)

Learn about BeaconRTLS™

Remote Team Management Using iOS as an iBeacon

S Sindhumol of Cochin University of Science and Technology, Kochi, India presents recent research into Implementation and Analysis of a Smart Team Management System using iOS Devices as iBeacon (pdf).

The key thing about this research is that it uses iOS rather than a beacon to advertise iBeacon. The system allows the entire team to determine the location of other members, perform location based tasks, receive announcements and communicate via instant chat.

iBeacon Team Management Screens

The paper contains some useful analysis of accuracy of distance measurement on distance, interference, measured power and obstructions:

Effect of iBeacon distance accuracy with obstructions
Effect of iBeacon distance accuracy with presence of another iBeacon
Effect of measured power variation on proximity and accuracy
Effect of obstructing objects on RSSI and Accuracy

On iOS it’s only possible to advertise iBeacon if the app is in foreground:

The major limitation of the proposed app is battery drainage while keeping the app active all the time in the foreground

A more practical system would have been implemented by having the users carry a separate wearable beacon. This would have allowed presence to be detected when the app isn’t in foreground and there wouldn’t have been a problem with excessive iOS battery use.

England’s Contact Tracing App Now Trying the Apple/Google API

After wasting a lot of money and more importantly time, England has abandoned using the public mobile OS Bluetooth APIs and is now using Apple/Google’s new contact tracing APIs. However, all has not been wasted because the home grown solution included advanced processing of Bluetooth RSSI values that provided for more precise measuring of close contacts.

The problem now is that the Google/Apple solution doesn’t provide access to RSSI and instead makes its own determination of close contact. Developers are forced down the path of a closed solution that can’t be improved upon. The new app is worse at determining distance than the original NHS Covid-19 app:

Engineers are still trying to reduce how often the Bluetooth-based tech wrongly flags people as being within 2m (6.6ft) of each other

RSSI is very noisy due to radio multi-path distortion, reflection, shadowing and fading. It also varies due to differences across devices in transmit and receive capabilities.

Variation of RSSI in devices and due to the environment

We have previously mentioned the use of Kalman filtering to improve the processing of RSSI. A newer research paper by The Alan Turing Institute of University of Oxford Inferring proximity from Bluetooth Low Energy RSSI with Unscented Kalman Smoothers describes the processing of RSSI to infer close contacts. The BBC believes this is what was used in the older NHS app.

The paper shows show how good prediction of proximity and risk can be obtained by using RSSI sequences rather than applying thresholds to single values. This correlates with our findings in that our Bluetooth contact tracing solution uses sequences rather than value thresholds. The paper also mentions that the duration of the risk also makes some close contacts more important to classify correctly. Again, we concur in that our solution has the ability to contact trace based on contact duration.

England’s contact tracing is now heading in a better direction and in the direction we previously advocated. They now need to persuade Apple and Google to improve their solution.

Bluetooth LE Distance Determination Using RSSI

Bluetooth LE can be used to infer distance as is being used in contact tracing and social distancing apps. This is performed from the receiving end using what’s called the Received Signal Strength Indication (RSSI). This is a number, in dBm units produced by the receiving Bluetooth hardware that gives the wireless signal strength.

[dBm stands for Decibel-milliwatt, a unit used to measure radio frequency (RF) power level. dB (without the ‘m’) measures the power of a signal as a function of its ratio to another standardized value and the m in ‘dBm’ indicates we are comparing relative to 1 mW of power.]

RSSI is a negative value where the more negative it is, the further away the Bluetooth device. Close devices are usually in the range -10 dBm to -30 dBm while devices at the limit of detection give values less than -90 dBm.

Our post on Testing if a Beacon is Working shows how to use the nRF Connect app to measure the RSSI of a Bluetooth device.

The relationship between RSSI and distance isn’t linear and also depends on electrical, physical and environmental factors. It also varies slightly, as ‘noise’, over time, even when things don’t move. The largest electrical factor is the transmission power. Physical factors include blocking and reflection.

Some Bluetooth advertising such as iBeacon includes a value, the measured power, in the advertising that can be used to take account of the fact that different beacons have different transmission power and hence different RSSI at the same distance. The measured power is usually the value of the power at 1m from the transmitter.

While there are equations and libraries that attempt to derive distance from RSSI, often the most accurate method is to measure the actual RSSI at various distances and use this calibration data with interpolation to get estimated distances.

Movement Constraint-based Location Tracking

Researchers at the Pusan National University, Korea have a new paper on Applying Movement Constraints to BLE RSSI-Based Indoor Positioning for Extracting Valid Semantic Trajectories.

The received signal strength (RSSI) of beacons is often used to infer location. However, the RSSI is subject to reflection and blocking from walls, people and other obstacles causing the derived locations from the raw data to be ‘jumpy’. There are many ways to process the raw data, such as Hidden Markov Models, k-nearest neighbors and Deep Neural Networks (DNN) to obtain smoother trajectories.

The researchers use movement constraints and sliding-window aggregation to extract invalid trajectories and provide real-time semantic trajectories.

The paper shows the proposed movement constraint-based approach extracts valid trajectories that are comparable to the unconstrained and non-machine language approaches. This new approach is particularly suited to dynamic indoor environments where the reflection and blocking changes over time.