This is the open source code for the paper accepted by IEEE INFOCOM 2023: RT-BLE: Real-time Multi-Connection Scheduling for Bluetooth Low Energy
This work is based on the RIOT OS and Apache NimBLE. This repository include the RIOT OS and the NimBLE is a third-party package of the RIOT. Our modified NimBLE can be find here. Each modification should have a comment starting with "RT-BLE:"
.
The main part of the RT-BLE is implemented as a system module name rt_ble
. The code is located in sys/rt_ble
, header file is located in sys/include/rt_ble.h
We use the Nordic nRF52840DK compatible boards. SEGGER RTT is recommended to be used as the standard output method. The makefile has already modified to use the RTT. We have a simple CMD line tool for RTT log reading and mass flash. The code may be ugly, but really useful. Hope it is helpful for you too :-)
- First, you should install the required tool chains. Normally on Ubuntu, these two commands can install all the requirements.
sudo apt install build-essential
sudo apt install gcc-arm-none-eabi
- Then pull this repository (The NimBLE can be automatically downloaded when you first time make any application). After this, enter the
rt_ble_evaluation
directory. - Each test has two folders, the one ended with
_client
should be burned to the Central node (Master), and the one ended with_server
should be burned to the Peripheral node (Slave). For the first time, you should change the MAC address inmain.c
to the MAC address of your boards. - The following command can be used to make the application and then you can burn the binary file in
./bin/nrf52840dk/exp_<NAME>_<ROLE>.bin
to your boards with official JLink tools or the cmd line tool mentioned above.
make TARGET=nrf52840dk all -j16
Folder Name | Description |
---|---|
exp_rtble_*, exp_blex_*, exp_nf_* | This is the basic test to measure the delay of RT-BLE, BLEX and TL-BLE. |
exp_rtble_critical_*, exp_blex_critical_* | This is the test to get the worst-case latency during requirement changes (enter or leave the critical mode) |
exp_rtble_moveanchor_*, exp_blex_moveanchor_* | This is the test to get the connection reschedule time for RT-BLE and BLEX |
exp_rtble_cap_*, exp_blex_cap_* | This is the test to get the system capacity of the RT-BLE and BLEX |
For the TL-BLE, we should first measure the average retransmission time
Packet Loss Rate (%) | |
---|---|
0 | 1.0 |
10 | 1.1395 |
20 | 1.3239 |
30 | 1.5297 |
40 | 1.7577 |