Using Beacons on Buses

Some of the first uses of beacons was on buses. For example, in 2015 in London, 500 buses sent targeted in-app messages to passengers. It didn’t work, Proxama ceased to be in business and thankfully the use of beacons for spamming went away. Today, the use of beacons has matured as has their use on buses.

There’s a useful presentation by Texas A&M Transportation Institute and Houston METRO on Bus Stop Beacons: Transit Wayfinding for People with Visual Impairments (pdf). They classify accessibility challenges as locating stops, knowing which routes serve stops, obtaining real-time information and boarding the vehicle. They conclude that multiple location sources, using Bluetooth with GPS, work better than a single source alone. Also, sound shouldn’t be the only way riders receive information from an app because noisy environments make listening difficult. Vibrations can be used to provide additional notifications.

There are insights from Connecthings/CTS in Strasbourg on helping the blind catch the right bus. There’s also guidance in In–Vehicle Positioning for Public Transit Using BLE Beacons that shows locating a passenger to at least 1 meter across the length of the bus vehicle is possible using Bluetooth beacons. This can be used to assess crowding.

The current state of the art is using beacons with ticketless payment and automatic boarding and un-boarding detection. The pioneer in this area is one of our consultancy clients, UrbanThings, who has an article on Increase ridership through mobile ticketing and case studies.

Another one of our customers, Lothian buses, uses beacons to aid accessibility:

Next Stop Announcements: when on a bus, the customer can select which bus route they are on and the app will announce the name of the next stop as the bus approaches (with buses fitted with Bluetooth beacons, the customer doesn’t even need to select which bus route they are on – the app knows automatically)

Read about Beacons in Transportation

CoreHW AoA Hardware

CoreHW in Finland is a new entrant in the Bluetooth direction finding ecosystem. Their main product is the CHW10x0 chip that supports switching of complex antenna arrays needed for Bluetooth direction finding. It allows designs with only one component where three to five are usually required. The switch has a fast settling time for RF signals and a good phase balance between antenna ports providing better position accuracy.

CoreHW also has reference antenna arrays and 2D software for angle and position estimation to shorten time-to-market for AoA locator and AoD beacon manufacturers. They have a demo kit including 4 locators, 2 tags, a CorePatch antenna array board with CHW1010 chip, a Bluetooth T5.1 chip for IQ sampling and a USB interface (Ethernet) to connect locators with a Windows PC.

The CoreHW reference boards have some intriguing Medusa-type printed circuit board (PCB) tracks, presumably to keep the track length the same to each antenna to normalise RF signal delays.

We look forward to seeing CoreHW components in their customers’ production devices.

TRBOnet Beacon Setting Tips

TRBOnet is Motorola MOTOTRBO 2-way radio control room software. The system uses GPS outside and beacons indoors. The handsets detect iBeacon advertising that shows on TRBOnet plans or maps in the control room.

Here are some tips for setting up beacons for TRBOnet:

  • Each beacon has a unique UUID, major and minor values. Change the UUID from the default to prevent overlap with someone else’s iBeacon network. The actual values you should use are ‘invented’ by you. We have an article on Choosing UUID, Major, Minor and Eddystone-UID For Beacons.
  • Set the beacons to ONLY send out iBeacon advertising. This shows in the manufacturer configuration app as using just one channel for iBeacon. If extra channels such as Eddystone or ‘info’ are enabled, the beacon will still be detected but the beacon battery will be depleted much sooner.
  • Motorola has a useful table that specifies the recommended beacon advertising interval based on the handset scan interval. See our post on Why Bluetooth LE Scanning Doesn’t Always See Devices to better understand this mechanism.
  • When the beacon device is configured for a lower advertising interval it consumes more power. There is a roughly 1:1 correlation between beacon advertising interval and battery life. Longer scan interval ON times increase the probability of beacons being detected but increase the time (latency) to detect beacons and report new positions in the control room.
  • Some radio vendor guides mention a specific to-the-millisecond advertising period so as to prevent beacon advertising and handset scanning from being permanently out of sync. This is a misleading information. All Bluetooth advertising includes a small randomisation in time between successive advertising to prevent this situation.
  • Use standard 0dbm transmit power unless you have special need to boost or reduce the beacon range. We have an article on Choosing the Transmitted Power. See our post on Testing if a Beacon is Working that shows how to measure the received signal strength (RSSI). This allows you to determine the area covered by a beacon and detect areas that are not covered.

2D vs 3D Bluetooth AoA Direction Finding

Current AoA locators only have antennas in one plane which means they can only provide angles in two (elevation and azimuth) dimensions. A locator therefore sees assets as being somewhere along an imaginary line or ray emanating from the locator.

If the height, perhaps of a worn lanyard, is known and tends to not change much then it’s possible to estimate the 3D location. Obviously, if the person climbs some steps for kneels down then the location becomes less accurate in all dimensions.

The other solution is to use multiple locators to triangulate two or more locator lines. This is more accurate because it doesn’t rely on a known average height and provides the opportunity to use more than two locators to increase accuracy still further.

3D provides the best accuracy. 2D location allows use of fewer locators with the trade off of less accuracy. For example, the four locators in the Minew AoA kit can be placed in different rooms or areas rather than covering an overlapping area. 2D location also has the implicit advantage of supporting more beacons because the locators and subsequent systems are doing less work.

Read about PrecisionRTLS™

Aging in Place Assisted by Bluetooth Beacons

There’s recent research on Active Aging in Place Supported by a Caregiver-Centered Modular Low-Cost Platform (pdf) by João Paulo Rangel Marques Capinha of Nova School Of Science And Technology, Portugal. Aging in place is where the elderly reside in their own homes rather than being taken into care.

A platform is proposed that supports aging in place with a focus on Ambient Assisted Living (AAL), the use of Information and Communication Technologies (ICT) to stimulate the elderly to remain active for longer, remain in society and live independently.

The paper describes beacon advertising protocols, received signal strength (RSSI), real time location systems (RTLS), trilateration and fingerprinting. It lists similar projects such as CarePredict, SANITAG, DOMO, 2PCS, CARU, LIFEPOD.

Knowing the routine of daily activities allows detection of activities, critical situations and vocal calls for assistance.

The system uses Bluetooth beacons, Bluetooth temperature/humidity sensors, ESP32-based gateways and Bluetooth wearables. It uses machine learning techniques to identify situations of potential risk, triggering triage processes and consequently any necessary actions so that a caregiver can intervene in a timely manner.

A receiver within Bluetooth bracelets detects beacons in rooms. When in a room, sensors in the room are triggered by the platform through the gateway located in the room.

Bluetooth Direction Finding Antenna Arrays

Bluetooth direction finding Angle of Arrival (AoA) uses multiple antenna in one device that uses the phase difference of signals received at different antenna to determine the angle and hence location of a beacon.

We are seeing a variety of designs but most use printed circuit board patches for antennas for reasons of cost and compactness.

All these designs use a radio frequency switch that switches each antenna, in turn, to just one Bluetooth chip to save cost and complexity. You can see this in some of the designs as tracks leading from each antenna to one chip and then one track from that chip to the Bluetooth system on a chip (SoC). The switch is very fast, of the order of 1 microsecond, to capture the same origin signal across all antennas.

Take care to purchase production-ready hardware. While there are currently many antenna array designs, some are just prototype or reference boards not intended for production. The software accompanying prototype or reference boards also tends to be non-existent and in cases where it does exist, it won’t scale to more than a few beacons.

In practice, a location engine employing AoA radiogoniometry is required to process the radio signals from the Bluetooth SoC. The radio signals are also wirelessly noisy and have to be processed to mitigate reflections, interference and signal spread delays. Additional processing is needed to triangulate the angles from multiple locators. All this isn’t trivial given that the algorithms are computationally expensive and have to be executed extremely quickly to support a large number of beacons.

Minew AoA Kit

Read about BluetoothLocationEngine™
Read about PrecisionRTLS™

Bluetooth LE in Smart Cities

Researchers from Spain have a recent paper on Experimental Application of Bluetooth Low Energy Connectionless in Smart Cities that considers the increased range and improved robustness provided by Bluetooth 5.x.

The paper describes the various types of communication:

The paper includes a description of Bluetooth LE including advertising and the different physical layer modes.

There’s an experimental evaluation of the new, more-robust, long-range radio mode when used in smart cities scenarios. The I2V scenario is evaluated, where reception is measured against variation in distance and vehicle speed. The I2P scenario is evaluated against interference from WiFi and classic (non LE) Bluetooth.

The researchers found an overall packet loss of 20–30%, regardless of mobility speed, compared to the static scenarios. The classic Bluetooth 4 mode was found to be more immune to coexistence with the WiFi protocol than any BLE 5.x mode. The researchers say this is because Bluetooth 5 extended advertisements 1) make use of more than one channel and 2) have longer data are both can cause more susceptibility to interference. Nevertheless, the updates introduced with Bluetooth 5 allow broadcasting over much longer distances.

The paper concludes the maturity and low cost of the technology could enable fast, easy deployment in smart cities compared to other solutions.

Minew MWL01 AoA Beacon Insights

The MWL01 Beacon is an AoA beacon which means it advertises a constant tone extension (CTS) for angle of arrival detection. An accelerometer detects the degree of movement and adjusts the advertising across three levels between 100ms (fast) -> 250ms (normal) -> 4s (slow) to save battery life. The battery level is provided in the advertising data. Double clicking the button changes the advertising, for example, for SOS notification.

Here are some observations that aren’t immediately obvious in the documentation:

  • While AoA is Bluetooth 5.x, It actually advertises Bluetooth 4.1 rather than 5.x. This makes it suitable for non-AoA applications where it can be detected by non AoA Bluetooth 4.1 receivers. It’s particularly suited for asset tracking because it increases the period between advertising, when not moving, to significantly save battery.
  • You might think the change to 4s advertising isn’t working. Be patient. It takes 5 minutes of normal advertising before it switches to slow advertising. Note that it also takes 5 seconds to go from fast advertising to normal advertising. While the advertising rates can be changed, the times to transition can’t be changed.
  • The beacon that is supplied with the AoA kit is different to that supplied separately. The kit’s MWL01 is fixed to 100ms advertising and can’t be changed. This is because it much easier to evaluate AoA and develop software when the advertising is consistent over time. The kit MWL01 can be upgraded, if necessary, to support the changing advertising period. However, we recommend you keep them as 100ms advertising beacons for ease of testing.
  • The ‘Location Finding’ flag in the AoA advertising is actually an indication of the double button press rather than anything to do with direction finding. This flag stays on for a minute and the blue led flashes during this time. Again, the double button press is only available on the non-kit beacon.
  • The battery level isn’t in the AoA data advertising. The beacon advertises a second connectable broadcast frame that includes the MAC address and battery level every 1s, 1s and 4s in the fast, normal, and slow modes respectively. These times can’t be changed.
  • Unfortunately, Minew are stipulating that the settings and firmware upgrade are only available to people who have signed an NDA with Minew or BeaconZone if you purchased the beacons from us.

Linux, D-Bus and Bluez

Barry Byford has a useful and continually growing introduction to using Bluetooth on Linux. He describes how to use BlueZ, the official Bluetooth stack on Linux, via D-Bus and Python. D-Bus allows communication between multiple processes running concurrently on the same machine. There’s an example how to set up an asynchronous event loop and how to build a Bluetooth Low Energy (BLE) device implementing the Bluetooth Central role.

While you are there, also take a look at Barry’s notes and examples on Creating a BlueZ Pairing Agent and Bluez beacons on the command line.