Bluetooth outdoor positioning

Alex Lehman

Overview

This project is using the BGM-220 explorer kit with the bluetooth radio. The project will implement one device as a 'scanner' that will scan continuously for beacons. The beacons will be filtered such that only beacons of interest will have their RSSI (Received Signal Strength Indication) measured and converted to an estimated distance measurement from the scanner. The single scanner has a daughter board OLED SSD1306 that is used to continuously display the distance and RSSI.

The final demonstration shows scanner displaying the distance and RSSI of up to four beacons on the OLED. The beacons are placed roughly 20 meters apart in each corner of a square topology. The scanner is mobile and is moved clockwise around the perimeter of the square starting at beacon 0 to beacon 3.

General view Video

video

Hardware

The microcontroller used for this project is BGM220-EK4314A from Silicon Labs and the OLED board used was the Makerfocus I2C OLED display module 0.91" I2C SSD1306. The OLED was adapted to the BGM220 on a custom daughter card. The card also has SI7054 temperature sensor which is, however, not used in this project. All devices were powered via their USB port.

Software

BGM-220 Scanner software

The software for the scanner is based on the BT_ Scanner project provided on the course web page. In addition the OLED driver code was provided as an example application. The scanner software was modified to continuously run and look for specific beacons and will capture the RSSI from those beacons estimate their distance and display their distance and associated RSSI on the OLED screen in real time. The formula used to estimate the distance is

10(P - RSSI)/(10*N)

where N is the environmental control variable and P is the measured RSSI of the radio at one meter. The value of N was experimentally set based on testing at various distances in the range 2.0-4.0, but I ended up using N = 2.0 as this was most accurate. I also implemented a moving average filter because the RSSI was very noisy.

The I2C OLED driver was ported to run in the scanner software and required an update to the project configuration to install the silicon labs I2C driver (Simplicity Studio Project -> Software Components -> Platform -> Driver -> I2CSPM).

BGM220 Beacon Software

The software for the beacons used in the project were based on the BT_ Beacon project provided on the course web page. The beacon software was modified to hardcode device names CSCI000, CSCI001, CSCI002 and CSCI003 for each of the beacons to uniquely identify them. The last character in the names above was used to differentiate the reported distance and RSSI.

Test Execution and observations

During field testing it became apparent that the RSSI signal varies significantly sample to sample. In addition the reported RSSI is effected dramatically by pcb board orientation. That said, relative distance measured using RSSI did correlate with physical testing.

Final Thoughts

The hardest part of this project was updating to the correct version of the IDE to get the application code to work. I had to revert to a previous version to get the demos to work. The IDE is complicated and difficult to understand. Overall this project was interesting and I learned a lot about RSSI and embedded devices. The RSSI is very noisy and the distance measure is less accurate because of this noise than I expected.

Downloads


Last modified:Mon, Jan 23, 2023.

00010