November 25, 2019
Would you like to know more about a real experience with mesh networks? We are happy to tell you about Bluetooth mesh network configuration, provide our own experience with this technology, and compare it with other wireless networks, such as Zigbee and Thread. Also, this tutorial will help you get an idea of where this type of network is applicable.
As with every other relatively new piece of technology, Bluetooth mesh networking raises more questions than it answers. It is not a problem to find solid Bluetooth mesh documentation or a good explanation of how it works.
However, when it comes to details and specifics, such as, what is the real amount of data that can be transferred? What is the proven working distance between the nodes? How is traffic reduced in the network and is there, in fact, a way to manage this? The most common answer is “Well, I don’t know. No one has tried it yet, but theoretically...” At Integra Sources, we have tried it, and have been successful. We are ready to provide a more practical guide to Bluetooth mesh networking based on our experience.
What is a mesh network, broadly speaking? A mesh network (or simply meshnet) is a local network topology in which the infrastructure nodes (i.e. bridges, switches, and other infrastructure devices) connect directly, dynamically and non-hierarchically to as many other nodes as possible and cooperate with one another to efficiently route data from/to clients. Bluetooth low energy mesh network is a meshnet based on BLE technology.
Bluetooth Low Energy, or BLE, was first introduced by the Bluetooth Special Interest Group (Bluetooth SIG) in 2009 and it was completely integrated into Bluetooth 4.0 in early 2010. The new technology was designed for smart connectivity systems with low power requirements. However, the abilities of BLE networks were quite limited. Bluetooth Low Energy allowed for one-to-one communication and the devices within a network could communicate only via the central hub.
The release of the Bluetooth mesh networking standard became a game-changer in 2017. The Mesh Profile specification, introduced by Bluetooth SIG, together with the standard, provides the possibility for many-to-many communication and is intended for networks with a large number of nodes - mesh devices that broadcast messages. It targets the growing IoT market which continuously demands new solutions, more bandwidth, more communicating devices, and more flexible technologies.
What differentiates the Bluetooth LE mesh network from ZigBee/other forms of technology, in the first place, is broadcasting messages. Unlike the other wireless networks based on routing, the BLE mesh protocol applies the managed flood principle. This approach provides for a peer-to-peer communication model in which every node, or device, communicates directly with each other. Managed flooding makes messaging efficient - messages are relayed to the right nodes with no need for the central hub to be used and without interruptions.
The self-sufficiency of the nodes, coupled with multipath messaging, facilitates the scalability of BLE mesh networking. You get an opportunity to create countless networks with innumerable nodes.
Due to the publish/subscribe messaging system, devices connected to a BLE mesh network may be configured to form segments of different scale and purpose. As a consequence of this configuring, the technology is made even more flexible and manageable.
BLE mesh architecture has a multi-layer structure. Messages are encrypted and authenticated at the network and application layers. The security keys protect messages from being read and ensure sensitive communication between the nodes. A new device, or node, added or provisioned on the network, gets access to the security keys.
All Bluetooth low energy networks have low power consumption (unlike “classic” Bluetooth networks), and BLE mesh is no exception. So, low energy and large areas, clearly makes a substantial difference.
Compared to the connection-based Bluetooth network, mesh technology does not require a connection between two nodes or a configured route to be stable. Should the closest devices in the network be disconnected, the initial node continues to broadcast the packet with no issue, and, eventually, reaches the recipient with just a few seconds delay. Most of the standard implementations provide no guarantee of this. However, the mesh network is different, it reconfigures itself; it is flexible – which is sometimes more important than a guaranteed speed and shorter delays.
Nodes in a Bluetooth mesh network may change their position without breaking the whole network structure and could lose some transferred data. Thus, it is possible that they might become part of an object constantly or periodically moving within the network perimeter.
A compelling feature of Bluetooth mesh networking is its interoperability. It is compatible with Bluetooth 4.x and 5.0 devices. If a device does not support the Bluetooth 5.0 protocol, you can still add it to the mesh network. A Bluetooth 4.x compatible device will be able to receive messages, but it will not become a full-fledged node of the network since it can broadcast messages only to the paired device.
Now, there is a growing number of devices that support BLE mesh. One of the most promising areas for Bluetooth mesh networking is mobile communication because of smartphones` compatibility with Bluetooth 4.0 and BLE.
BLE mesh technology is closely connected with beacons. BLE beacons are broadly used in sensor networks, indoor and outdoor positioning, and other low-power connected systems.
As a highly flexible, reliable, and secure solution, BLE mesh networking technology can be used not only in traditional applications, such as smart lighting, home automation or asset tracking, but also in a number of other fields. Further, in our Bluetooth mesh tutorial, we`ll give an example of a BLE mesh network that turned out to be a creative solution for its application.
Working with any new technology is always challenging for a developer. When the technology is young, it may lack the necessary documentation and use cases available online. In this situation, every issue is resolved by trial and error.
One of the non-standard commercial projects based on Bluetooth mesh and realized by Integra Sources is a network of Bluetooth devices for restaurants and bars. The standard BLE Mesh network realization fits the project well. However, in this project, we had to manage some compatibility issues: devices using different Bluetooth protocols, and the system backend created for Bluetooth 4.x.
The devices in this network (very stylish cubes) are located on the tables with NFC tags but are not tied to them: they can be relocated in any order as the network is absolutely flexible. They are used to call a waiter, ask for the check, they also inform the waiting staff how long the guest has been kept waiting and the devices work as a table lamp.
The staff receive the data from the cubes using iOS smartphones and tablets that connect to the closest Bluetooth device so it becomes a gateway. This connection, however, does not affect the whole network configuration. Data accumulated from the devices generate comprehensive statistics that can be used for staff optimization and improving the quality of service in the restaurants.
Since nodes can be placed arbitrarily, completely different Bluetooth mesh network configurations are possible. On the schemes below you can see just some of the situations.
This network is automatically configured with the algorithms we had to find over the course of several experiments performed on about 100 Bluetooth nodes. In the restaurants, the cubes are constantly relocated, some of them may be off, they may be used in facilities with several rooms, and the human factor has a constant effect on the physical topology of the network. Integra Sources had to spend several hundred hours creating methods and rules for the graph to be built and rebuilt in real time. That was very worthwhile - now the system is reliable and flexible at the same time. Using our deep experience in mesh networks, we can develop the required mesh architecture and build a BLE mesh network of diverse complexity for your system.
As long as there is no routing in the standard implementation of a BLE mesh network, the total number of nodes and data transfer operations between them decreases the network performance. The nodes broadcast all data they receive from the beacons - and receive all the packets - and rebroadcast them, and so on. Even with a low message time-to-live (TTL), it is easy to imagine the broadcast storm that could be generated by a 1000-node mesh network. The delays and latency only grow with the number of nodes and the number of packets sent between them. Bluetooth mesh networking technology allows more than 30 thousand devices to be connected at once, but in our experience, even a mere hundred of them can create the amount of spam that could seriously threaten the whole ecosystem.
For the restaurant cubes project, we had to find a way to reduce the effect of this storm. Depending on the network and the node status, each node only sends the packet to a number of selected devices, and each packet has a certain TTL. This has decreased the traffic in the network but also increased the load on the nodes themselves; as a consequence, we were dangerously close to their RAM limit. Nevertheless, we managed to solve the issue and significantly reduce the storm.
With a maximum physical speed of 2 Mbit per second (in theory for Bluetooth 5.0 devices, but impossible to reach for real data transmission), including the service data on the beacon, packet type, etc, the potential of using the Bluetooth mesh networks is still not that great yet. In order to estimate the real bandwidth of data transfer within a mesh network, you should take into account a lot of variables, such as the number of devices, the distance between them and the BLE network topology, and whether it needs to reconfigure itself automatically. Thus, in one of our asset tracking projects, as well as in a restaurant mesh network project, the data throughput rate was about 80 kbit/s. However, this data rate allows for timely notifications and even imaging with low power consumption.
One of our customers wanted to implement a mesh network for an industrial company to track employees and transport movement within a facility. However, they needed a high bandwidth and the highest reliability at the same time, while transferring data for quite a long distance, about one kilometer. All the devices, aside from one gateway, were battery powered.
Taking this into account, we were unable to guarantee reliable data delivery and high throughput by implementing a BLE mesh. As a consequence, we recommended using non-mesh Bluetooth network technology that would not cause a broadcast storm. A direct connection between the neighboring nodes and routing the data to the gateway proved to be more effective for guaranteed message delivery in this complicated industrial space, with a good deal of transport and equipment coursing around it, and many beacons used.
Mesh networks can be created using literally any low energy Bluetooth chip or microcontroller that supports the technology. The hardware is now produced by all the major manufacturers - Nordic Semiconductors, Texas Instruments, STMicroelectronics, Silicon Labs, Cypress Semiconductor, Qualcomm, and others.
Every manufacturer provides SDK to create custom mesh networks and build BLE applications.
The main challenge now is not choosing hardware but creating a viable network graph. We at Integra think ahead about each nuance before building a mesh network topology to make your project graph efficient.
For one of the projects, we have compared the main characteristics of BLE 5.0 Mesh, ZigBee, Thread, and our own Integra BLE networks. BLE mesh network had the lowest bandwidth, less than 1.5 kbit/sec for 100 bytes packet on six hops, and the largest delay (640 ms for the same packet and four hops). It has no guaranteed data delivery, unlike ZigBee or Thread.
However, for a mesh network, one will need no routers, and the security of the technology is high. So, for a small amount of data that does not require fast and guaranteed delivery, it might be a very good option.
Bluetooth LE transceivers are generally cheaper than their analogs for the other technologies. As Bluetooth is widely supported by consumer electronics (smartphones, tablets, etc.), Bluetooth networks are easily integrated into the existing environment. These two factors make the implementation costs lower; the prototyping and obtaining an MVP could be performed faster.
With the Bluetooth network projects realized, we have completed all the necessary types of tasks: creating firmware for the nodes and the gateway, providing a gateway developed by the Integra Sources team, creating a mesh network topology and optimizing it and making it compatible with the existing devices and system. So if you need a low power wireless system with scalable connectivity and secure data transfer, we will create a BLE mesh network for your particular project.
In spite of its undeniable benefits, Bluetooth mesh networks technology is not universal. Its scope of use is limited and even if it fits the company needs the system requires a fine setup and much experimentation and tests.
However, our experience proves that this technology is reliable, especially for the Internet of Things solutions. BLE mesh meets the latest requirements of smart connectivity - it is low-power, large-scale, reliable, and secure.
We hope that our BLE mesh tutorial gave you an idea of Bluetooth mesh networking, but if you still have doubts about using BLE mesh technology for your product, we`ll be happy to get details and give our professional advice.
Share this article