The aim of the project was a proof-of-concept (PoC) for asset tracking using a Bluetooth Low Energy Mesh (BLE mesh) network for indoor applications. A BLE mesh offers the advantage that almost no infrastructure is required. The nodes are sometimes so energy-efficient that they can run for several months on a single button cell. The data is transmitted via Bluetooth Low Energy.

For the PoC, Zephyr RTOS was used to create firmware for BLE beacons based on Nordic nRF52 chipsets. RUUVI tags were used in this case. Zephyr’s BLE mesh capabilities, which were rudimentary at the time, were adapted so that queries could be sent from any point within the mesh to all nodes regarding a device being searched for. Each node scans its environment for the requested device and, if successful, sends the signal strength to the requesting node. The requesting node thus receives a list of all nodes in whose vicinity the device is located.

Identical firmware was created for all nodes for the application. One of these nodes is connected to a server (Raspberry Pi), which can trigger requests in the mesh via a serial interface. A backend application based on Node.js was developed for the server, which is connected to a local PostgreSQL database and has access to the connected BLE node via the serial interface. The absolute positions of all fixed nodes in the mesh can be stored in the database. A service in the Node.js application is responsible for determining the location. This forwards location requests to the mesh and receives the reported signal strengths. From this, the service derives approximate distances and carries out triangulation using the position data in the database. A method based on linear regression is used for the calculation.

A cross-platform app with the Ionic framework was developed as the front end for position requests and for creating the positions in the database. The app can make requests to the backend using the REST API. The app also offers the option of placing nodes on the graphic of a building floor plan using drag-and-drop. The scale is defined by determining a reference length, also using drag-and-drop. To assign the nodes, the firmware has been extended to the extent that pressing a button on the beacon disseminates its ID in the mesh. This event is registered by the backend and forwarded to the app. This simplifies the initial setup of the fixed mesh.

With the system, it was possible to determine the position to an accuracy of 5m at the time of completion, although it should be noted that the nodes were approx. 10m apart. Determining the distance on the basis of the signal strength is very error-prone, as this can be strongly influenced by various factors (position of the antenna, objects between the nodes, degree of development, etc.).

The market now offers much more precise concepts such as Angle-Of-Arrival or Angle-Of-Departure.

To summarize, this project was very exciting but also challenging due to its diversity. It gave me the opportunity to gain insights into various software tools, mathematical concepts and mesh networks.