Bluetooth Mesh Networking

Ericsson has a recent white paper on Bluetooth Mesh where it’s explained how Bluetooth Mesh extends Bluetooth into IoT usecases.

The paper describes how Bluetooth Mesh works including the publish/subscribe model, two-layer security, managed flooding model, friendship nodes and proxy nodes. It’s explained how, after provisioning, the network ‘simply starts working’ and does not require any centralized operation:

No coordination is required and there is no single point of failure

A building automation usecase is described and modelled to determine the Quality of Service (QoS) which they define as the ratio of transmitted packets that reach the end destination within human perceivable time (300ms in this case).

They conclude that higher relay densities result in higher channel congestion. Bluetooth Mesh systems need to be individually configured in terms of the number of relays, use of acknowledged or unacknowledged transmissions, message repetition schemes and transmission randomization.

While the paper provides a good introduction, it doesn’t address the more pragmatic aspects of implementing Bluetooth Mesh networks. For example, the paper states:

The design of Bluetooth mesh has been driven by a desire to create a simple, efficient and flexible wireless mesh networking solution

In our opinion it is not that simple nor specially efficient. The Mesh standard and implementations are relatively complex leading to the need for complex provisioning and setup. It’s for this reason we only supply our SensorMesh™ component as part of larger solutions where we, as opposed by our clients, provision and setup. Mesh is also not as efficient as we have come to expect from Bluetooth in that devices can’t be battery powered over long periods of time. This is because, unlike most Bluetooth devices, mesh devices are scanning for others for a large proportion of the time.

Also, the paper’s claim that “it works on existing devices after a simple firmware update” isn’t always true as mesh devices need much more memory that’s only available on newer Bluetooth SoCs.

There’s no mention of throughput which we considered in a previous post. Mesh is good for solutions requiring low throughput. Real time and higher throughput scenarios require gateways.

Read about SensorMesh™

Understanding Bluetooth LE Reliability

We have previously written about Bluetooth LE on the Factory Floor and Why Bluetooth LE Scanning Doesn’t Always See Devices (the First Time).

There’s a new informative paper by Martin Woolley of the Bluetooth SIG on How Bluetooth® Technology Makes Wireless Communication Reliable. It describes in detail how radio collisions, multi-path propagation, time-dispersion, transmitter-receiver synchronisation, signal strength, receiver sensitivity and buffer overflow can collude to make radio communications unreliable.

The paper explains how Bluetooth modulation schemes, CRC checks, multiple channels, coded PHY, adaptive frequency hopping, flow control and the ATT protocol work to make Bluetooth LE reliable.

The paper also takes a look how Bluetooth Mesh has been designed to achieve reliable communication.

Advanced Bluetooth on Android

Martin Woolley of the Bluetooth SIG was a recent speaker at Droidcon EMEA where he spoke about Advanced Bluetooth for Android Developers (slides).

Android Bluetooth LE Stack

Martin covered scanning, GATT, how to maximise data rates, speed vs reliability and using different PHY for enhanced range or data rates. The second part of the talk covers Bluetooth Mesh and proxy nodes.

One thing not mentioned in the slides, to be careful of, is that connection via a proxy node is relatively slow because it’s limited by the GATT connection. Proxy nodes are good for controlling (sending small amounts of data into) a Bluetooth Mesh but poor if you want to use the connected Android device as a gateway for all outgoing data.

Martin also has a blog where you can also learn about his past talks and he will be part of the new Bluetooth Developer Meetup.

Read about Beacons and the Bluetooth Mesh

Bluetooth Developer Meetup

There’s a new (virtual) Bluetooth Developer Meetup group.

Developers will share their knowledge and tell their stories of working with everybody’s favourite low power wireless communication technology

The first event will be on 15th October 2020 at 17:30 UK time (UTC+1) and will include the following speakers:

  • Jacky Cheung, Google
  • Kevin Picchi, Samsung
  • Thea Aldrich, Foundries IO
  • Martin Woolley, Bluetooth SIG

Bluetooth Market Update

The Bluetooth SIG has recently released a 2020 Bluetooth® Market Update identifying new trends and forecasts from ABI Research and other analyst firms.

The use of Bluetooth for location is expected to achieve 32% compound annual growth (CAGR):

Obviously, these and other numbers in the report were analysed prior to the coronavirus crisis.

For Bluetooth Mesh, 90% of end-product Bluetooth® mesh qualifications are lighting focused. As with the introduction of iBeacon, which initially focused on marketing messages, the wider capabilities and opportunities are initially not being fully exploited. Part of the problem is that the standard models that come with Bluetooth Mesh are more lighting focused because the standard was driven by individuals from the lighting industry. Custom models, such used by our SensorMesh™, are possible but take more effort.

App-based Bluetooth Mesh

Protesters in Hong Kong have been using Bluetooth mesh to communicate with one another so as to avoid using the Internet and therefore making it difficult for the Chinese authorities to intercept. However, this isn’t standard Bluetooth mesh as defined by the Bluetooth SIG. It’s a proprietary mesh protocol over standard Bluetooth.

The app used is Bridgefy and there many such peer to peer apps such as FireChat (server has been turned off and no longer works), Signal Offline and Briar that use Bluetooth and WiFi direct.

The use of stand-alone Bluetooth mesh networks isn’t limited to protesters. A growing number of SDKs allow mesh networks to used by companies and organisations. When used with iOS and Android devices (which don’t necessary have to be smartphones) these provide for WiFi-less and Internet-less communication. This allows use, for example, in emergency situations when cellular and Internet goes down. Alternatively, they can simply provide connectivity across a site where there’s no cellular coverage or WiFi.

SDKs include Bridgefy, Hype the open source android-ble-mesh, Ubudu Android Mesh, and a newer open source iOS library by Zsombor Szabo, called Berkanan SDK.

Wireshark Supports Bluetooth Mesh

Wireshark has announced support for the Bluetooth Mesh Beacon, PB-ADV, Provisioning PDU and Proxy Bluetooth mesh protocols.

Wireshark is a protocol analyser that takes packets and decodes into human readable data. It’s usually used with other hardware and software as the last stage in processing captured data. For example, you can use Wireshark with the Nordic nRF sniffer, on Adafruit hardware and on Linux.

In the case of Bluetooth mesh, data packets are encrypted. In fact, data is double encrypted in that first the data is encrypted and then the packets. This means that while you can capture packets you can only see the packet types and Bluetooth mesh metadata. You won’t be able to decrypt the actual data. It’s more useful for determining the type and size of traffic for mesh traffic optimisation.

Read about Beacons and the Bluetooth Mesh

What’s Wrong with Bluetooth Mesh?

Researchers from TU Darmstadt, Germany have a new paper Toxic Friends in Your Network: Breaking the Bluetooth Mesh Friendship Concept that looks into weaknesses in the security model underlying the Bluetooth mesh friendship mechanism.

Friendship allows a low-power IoT device to go to sleep with a separate higher-power node caching packets until the lower power device wakes up. The paper provides an overview of friendship and the Friendship Security Material(FSM) unique to this type of communication.

The researchers found three flaws in the Bluetooth friendship mechanism related to:

  • The possibility of eavesdropping on communication and selectively jamming based on size of the control messages.
  • The lack of protection of the friend security keys against an insider attack.
  • The possibility of misuse of Friend Clear messages to cause a form of denial of service attack through flattening the battery.

The paper includes a reference to tools that demonstrate these problems and discusses possible mitigations.

The Bluetooth SIG responded:

Compromise of the friendship relationship results only in a compromise of the availability of the low power node to the other nodes in the subnet.

It is the conclusion of the working group that the friendship relationship between an LPN and its friend within a mesh subnet is not intended to be secured against attack by a party already in possession of the network key.

It is the position of the Mesh Working Group and the Bluetooth SIG that neither scenario provides additional security risk for a user of the Mesh profile

In other words, the risks are appropriate to the level to which the mesh is expected to be used or attacked.

We have yet to come across any devices using friendship. Friendship is an edge case that isn’t required in most instances. Also, most existing low power devices can’t be upgraded to use mesh due to the higher memory requirement of Bluetooth Mesh.

Read about Beacons and the Bluetooth Mesh

New SensorMesh™ Gateway Box

We have a new SensorMesh™ Gateway Box that takes mesh data from a USB COM port and sends it to your server, BeaconServer™ or BeaconRTLS™.

It reads data from a COM port and uploads it to a server defined by a URL in the box’s web UI:

The web UI also shows the latest data received and the response from the server

Use of the Gateway Box is optional. We also have a Windows 10 service should you wish to do a similar thing on your PC/server or you can process the COM port data yourself for a more bespoke solution.

Read more about SensorMesh™

Survey of Mesh Technologies

There’s useful new research on Wireless Mesh Networking: An IoT-Oriented Perspective Survey on Relevant Technologies by Antonio Cilfone, Luca Davoli, Laura Belli and Gianluigi Ferrari of University of Parma, Italy. It covers how various communication technologies are suitable for mesh networking.

The paper explains mesh topologies and routing protocols. It describes Bluetooth:

“BLE is presently raising more and more attention and is becoming one of the leading technologies for both IoT-oriented and industrial scenarios”

The authors provide an in-depth introduction to SIG Bluetooth Mesh. (Note that an excellent higher level overview also very recently became available from InsightSIP). The research paper also mentions other Bluetooth mesh implementations such as the draft IETF Bluetooth Mesh for IPv6.

Applications such as smart city, industrial monitoring and smart agriculture are considered and factors such as interoperability and security are mentioned. Finally, the paper compares other protocols such as Thread, ZigBee and LoRaWAN.

Read about Beacons and the Bluetooth Mesh