Understanding Bluetooth LE Advertising

There’s a new video of the Nordic Semiconductor webinar on Everything you need to know about Bluetooth LE advertising. It covers the basics of Bluetooth LE including advertising and data formats. It explains how to use the nRF Connect SDK API and provides a demo. It also shows how to use nRF Sniffer to examine Bluetooth LE data packets.

Bluetooth LE Advertising Channels

The presentation and Q&A are also available.

The video mentions advertising extensions. These are only in Bluetooth 5. Most current devices only support Bluetooth 4.2 legacy advertising. Growth in numbers Bluetooth 5 devices has been limited due to the non-compatibility with the majority of smartphones. It’s for this reason that devices that are Bluetooth 5 usually communicate using, backward compatible, legacy advertising. Extended advertising is also an optional feature of Bluetooth 5.

iBeacon Scanning and Region Monitoring on iOS 14

On iOS 14, Apple has changed the permissions required for iBeacon region ranging and monitoring. There’s a new Precise Location permission that needs to be set to ON for the app to continue to work. Apps that granted location permissions prior to iOS 14 default to Precise Location ON after upgrading so as not to break old code.

Apps should now detect if Precise Location is enabled. Apple has unfortunately deprecated the class function authorizationStatus(). The best way of determining whether you can detect iBeacons is to examine the location accuracy.

There’s an explanation on Medium by Nick Patrick and there’s a post on StackOverflow with an example how to detect whether Precise Location is on by examining the location accuracy.

Bluetooth App Insights from VMWare Pivotal Labs

VMware Pivotal Labs recently released Herald open source contact tracing for iOS and Android. Pivotal Labs was previously awarded three contracts worth £4.8m to develop a contact tracing app for the United Kingdom only for it to be abandoned for a new app based on the Google/Apple contact tracing mechanism.

Herald can’t be used for contact tracing unless you are a government agency because 3rd parties can’t publish such apps on the Apple app store. However, Pivotal Lab’s deep work in this area provides many insights into the use of Bluetooth on smartphones. The library itself also has other uses other than contact tracing:

  • Communication apps
  • File sharing between Android and iOS devices, reliably
  • Local ‘same location’ peer to peer applications, such as instant messaging or gaming apps
  • Safety apps
  • Using beacons in high-risk areas, an employee exposure app could accurate record exact exposure to hazardous environments
  • Also using beacons, know where to deep clean if an employee does fall ill at your large campus
  • Check in app – Walk around and be let in to secure areas automatically
  • Rescue app – e.g. for skiing/snowboarding avalanche rescue – find the hidden/non visible person. Could be fire in a large building, or rescue on a tube train

The documentation provides some useful information on technology approaches and OS specific issues.

Some insights:

  • Using scanning for 1-3 seconds with a gap of a few seconds between scanning uses 6-11% battery over 8 hours
  • Android phones’ speed when reading characteristics is significantly slower than write and acknowledge. Using write instead of read reduces the mean window times from above 8 seconds (minutes for some phones) to 0.5 – 4 seconds, depending on the handset. Use write characteristics wherever possible, and cache data to remove any redundant reads.
  • Apple iOS has a bug with background Bluetooth advertising where applications on two backgrounded iOS devices are not notified about each other. Two backgrounded iPhones cannot detect one other.
  • The background timer on Android sometimes gets stuck and might not wake for many minutes.
  • The way smartphones interpret Bluetooth signals to determine RSSI varies across Bluetooth chipsets. Some such as the iPhone 7 use a log approach while others use an inverse distance-squared scale. This affects accuracy if you subsequently use a common formula to derive distance from RSSI.

Read about Beacons for Workplace Social Distancing and Contact Tracing

Visitor Spaces Using Beacons

Fulham Palace and Norwegian National Museum have recently starting using Bluetooth beacons.

Norwegian Museum

Fulham Palace is using iBeacon with visitor guides. The Covid pandemic has accelerated the trend for iBeacon driven visitor guides. Using visitors’ own devices rather venue-supplied devices removes concerns regarding decontaminating shared devices. Smartphone driven guides also tend to be more interactive and allow visitors to continue to engage with content and venues after they have left the visitor space.

Norwegian National Museum is using beacons to detect the location of museum staff. Staff carry SC21 TETRA hand held radios detect beacons and upload data back to a control room.

Read about Beacons in Visitor Spaces

View iBeacons

Workplace Office Software Using iBeacons

Robin is workplace software that allows teams to manage meeting space and desk inventory via an office map. It uses iBeacons to determine worker presence.

People can book meeting rooms, move desks and find their teammates quicker. Analytics allow better understanding of space usage, identification of under-utilized areas and discovery of patterns in occupancy to proactively improve the office layout.

Robin has features that provide for return to work during the Covid pandemic with facilities to set up socially distanced seating plans that allow for your ideal capacity.

View iBeacons

In-Vehicle Bluetooth Sensing

Teltonika have an innovative range of advanced vehicle trackers that include Bluetooth. The tracker can scan for other nearby Bluetooth devices and send sensor data to a server.

FMB120 Telematics Tracker

There’s a getting started guide that explains how this is setup and provides screens showing how it works.

This allows not just for sensing telematics about the vehicles themselves but also about other assets or people. For example, if people carry beacons it’s possible to know who is driving or is in a vehicle. If you tag equipment usually stored in a vehicle you can determine where it is or if it is about to be removed from a vehicle. For temperature sensitive goods, such as medicines, you can continuously audit temperature compliance. It’s also possible to provide for location specific triggering, for example, producing work orders when a vehicle reaches an exact point whether or not there’s GPS coverage.

Read more about sensor beacons

Bluetooth Sensors for the Smart Home

Karl Wachs, author of the pibeacon plugin for indigo domotics Mac-based smart home software, has a new release on GitHub that includes many INGICS and Minew sensor beacons on our web store.

Indigo domotics provides complex conditions and advanced scheduling via an intuitive interface. The detection of Bluetooth sensors greatly expands the capabilities of the system.

Apple Mac Smart Home
Smart Home on the Apple Mac – Indigo also provide iOS and Web based interfaces.

The plugin tracks iBeacons using multiple Raspberry Pis. Sensor data is read and sent to a variety of output devices.

The use of the system isn’t just limited to the smart home. The system can be used in offices and industry SMEs to provide for arbitrary sensor based detection and triggering.

Please note BeaconZone only supplies Business to Business.