Accurate Bluetooth Ranging (ABR)#

Accurate Bluetooth Ranging.

These functions are related to the phase-based estimation of distance from I/Q-samples. The distances can be calculated following these steps:

  1. Initialize a sl_rtl_abr_libitem instance

  2. Set up the calculation parameters

  3. Create the estimator

  4. Process the I/Q data into a distance

  5. Get distance estimate

Modules#

sl_rtl_abr_rtt_data

sl_rtl_abr_parameters

sl_rtl_abr_rtp_data

Enumerations#

enum
SL_RTL_ABR_ALGO_MODE_REAL_TIME_BASIC = 1
SL_RTL_ABR_ALGO_MODE_STATIC
SL_RTL_ABR_ALGO_MODE_LAST
}

ABR estimator mode.

enum
SL_RTL_ABR_CS_MODE_RTP = 0
SL_RTL_ABR_CS_MODE_RTT = 1
SL_RTL_ABR_CS_MODE_LAST
}
enum
SL_RTL_ABR_TONE_QUALITY_GOOD = 0
SL_RTL_ABR_TONE_QUALITY_MEDIUM = 1
SL_RTL_ABR_TONE_QUALITY_LOW = 2
SL_RTL_ABR_TONE_QUALITY_UNAVAILABLE = 3
}

Typedefs#

typedef void *

ABR library item.

Functions#

sl_rtl_abr_init(sl_rtl_abr_libitem *item)
sl_rtl_abr_deinit(sl_rtl_abr_libitem *item)
sl_rtl_abr_set_algo_mode(sl_rtl_abr_libitem *item, enum sl_rtl_abr_algo_mode mode)
sl_rtl_abr_set_cs_mode(sl_rtl_abr_libitem *item, enum sl_rtl_abr_cs_mode cs_mode)
sl_rtl_abr_set_parameters(sl_rtl_abr_libitem *item, sl_rtl_abr_parameters *parameters)
sl_rtl_abr_create_estimator(sl_rtl_abr_libitem *item)
sl_rtl_abr_process_rtp(sl_rtl_abr_libitem *item, sl_rtl_abr_rtp_data *rtp_data)
sl_rtl_abr_process_rtt(sl_rtl_abr_libitem *item, sl_rtl_abr_rtt_data *rtt_data)
sl_rtl_abr_get_distance(sl_rtl_abr_libitem *item, float *distance)
sl_rtl_abr_get_distance_likeliness(sl_rtl_abr_libitem *item, float *distance_likeliness)

Enumeration Documentation#

sl_rtl_abr_algo_mode#

sl_rtl_abr_algo_mode

ABR estimator mode.

Enumerator
SL_RTL_ABR_ALGO_MODE_REAL_TIME_BASIC

Medium filtering, medium response, medium CPU cost. Suitable for real-time tracking.

SL_RTL_ABR_ALGO_MODE_STATIC

TODO add description,.

SL_RTL_ABR_ALGO_MODE_LAST

Placeholder.


Definition at line 723 of file /mnt/raid/workspaces/ws.pYEvgD5Jt/overlay/gsdk/util/silicon_labs/aox/inc/sl_rtl_clib_api.h

sl_rtl_abr_cs_mode#

sl_rtl_abr_cs_mode
Enumerator
SL_RTL_ABR_CS_MODE_RTP

Round-trip phase based estimation (RTP)

SL_RTL_ABR_CS_MODE_RTT

Round-trip time based estimation (RTT)

SL_RTL_ABR_CS_MODE_LAST

Placeholder.


Definition at line 731 of file /mnt/raid/workspaces/ws.pYEvgD5Jt/overlay/gsdk/util/silicon_labs/aox/inc/sl_rtl_clib_api.h

sl_rtl_abr_tone_quality#

sl_rtl_abr_tone_quality
Enumerator
SL_RTL_ABR_TONE_QUALITY_GOOD
SL_RTL_ABR_TONE_QUALITY_MEDIUM
SL_RTL_ABR_TONE_QUALITY_LOW
SL_RTL_ABR_TONE_QUALITY_UNAVAILABLE

Definition at line 739 of file /mnt/raid/workspaces/ws.pYEvgD5Jt/overlay/gsdk/util/silicon_labs/aox/inc/sl_rtl_clib_api.h

Typedef Documentation#

sl_rtl_abr_libitem#

typedef void* sl_rtl_abr_libitem

ABR library item.


Definition at line 775 of file /mnt/raid/workspaces/ws.pYEvgD5Jt/overlay/gsdk/util/silicon_labs/aox/inc/sl_rtl_clib_api.h

Function Documentation#

sl_rtl_abr_init#

enum sl_rtl_error_code sl_rtl_abr_init (sl_rtl_abr_libitem * item)
Parameters
[in]item

Pointer to the libitem to be initialized

Initialize the ABR libitem instance.

Returns


Definition at line 783 of file /mnt/raid/workspaces/ws.pYEvgD5Jt/overlay/gsdk/util/silicon_labs/aox/inc/sl_rtl_clib_api.h

sl_rtl_abr_deinit#

enum sl_rtl_error_code sl_rtl_abr_deinit (sl_rtl_abr_libitem * item)
Parameters
[in]item

Pointer to the libitem to be deinitialized

Deinitialize a libitem instance of the ABR estimator.

Returns


Definition at line 791 of file /mnt/raid/workspaces/ws.pYEvgD5Jt/overlay/gsdk/util/silicon_labs/aox/inc/sl_rtl_clib_api.h

sl_rtl_abr_set_algo_mode#

enum sl_rtl_error_code sl_rtl_abr_set_algo_mode (sl_rtl_abr_libitem * item, enum sl_rtl_abr_algo_mode mode)
Parameters
[in]item

Pointer to the initialized ABR libitem

[in]mode

Estimator mode as sl_rtl_abr_algo_mode

Set the estimation mode.

Returns

Set the estimation mode. For example, ::SL_RTL_ABR_ALGO_MODE_BASIC sets medium filtering. For further description of the modes, see the documentation of sl_rtl_abr_algo_mode.


Definition at line 804 of file /mnt/raid/workspaces/ws.pYEvgD5Jt/overlay/gsdk/util/silicon_labs/aox/inc/sl_rtl_clib_api.h

sl_rtl_abr_set_cs_mode#

enum sl_rtl_error_code sl_rtl_abr_set_cs_mode (sl_rtl_abr_libitem * item, enum sl_rtl_abr_cs_mode cs_mode)
Parameters
[in]item

Pointer to the initialized ABR libitem

[in]cs_mode

cs_mode as sl_rtl_abr_cs_mode

Set the estimation cs_mode.

Returns

Set the desired cs_mode. For example, SL_RTL_ABR_CS_MODE_RTP uses round-trip phase based cs_mode.


Definition at line 816 of file /mnt/raid/workspaces/ws.pYEvgD5Jt/overlay/gsdk/util/silicon_labs/aox/inc/sl_rtl_clib_api.h

sl_rtl_abr_set_parameters#

enum sl_rtl_error_code sl_rtl_abr_set_parameters (sl_rtl_abr_libitem * item, sl_rtl_abr_parameters * parameters)
Parameters
[in]item

Pointer to the initialized ABR libitem

[in]parameters

Data structure with CS initialisation parameters for the estimator

Set parameters for estimation. Must be called before sl_rtl_abr_create_estimator.

Returns


Definition at line 825 of file /mnt/raid/workspaces/ws.pYEvgD5Jt/overlay/gsdk/util/silicon_labs/aox/inc/sl_rtl_clib_api.h

sl_rtl_abr_create_estimator#

enum sl_rtl_error_code sl_rtl_abr_create_estimator (sl_rtl_abr_libitem * item)
Parameters
[in]item

Pointer to the initialized and configured ABR libitem

Create the estimator after initializing the libitem and setting parameters.

Returns


Definition at line 833 of file /mnt/raid/workspaces/ws.pYEvgD5Jt/overlay/gsdk/util/silicon_labs/aox/inc/sl_rtl_clib_api.h

sl_rtl_abr_process_rtp#

enum sl_rtl_error_code sl_rtl_abr_process_rtp (sl_rtl_abr_libitem * item, sl_rtl_abr_rtp_data * rtp_data)
Parameters
[in]item

Pointer to the initialized and configured ABR libitem

[in]rtp_data

Data structure with the RTP measurement data

Calculate distance estimate based on RTP.

Returns

Calculate the distance estimate from the given I/Q samples captured at the given frequencies. Use sl_rtl_abr_get_distance to fetch the latest distance estimate.


Definition at line 850 of file /mnt/raid/workspaces/ws.pYEvgD5Jt/overlay/gsdk/util/silicon_labs/aox/inc/sl_rtl_clib_api.h

sl_rtl_abr_process_rtt#

enum sl_rtl_error_code sl_rtl_abr_process_rtt (sl_rtl_abr_libitem * item, sl_rtl_abr_rtt_data * rtt_data)
Parameters
[in]item

Pointer to the initialized and configured ABR libitem

[in]rtt_data

Data structure with the RTT measurement data

Calculate distance estimate based on RTT.

Returns

Calculate the distance estimate from the given device time samples. Use sl_rtl_abr_get_distance to fetch the latest distance estimate.


Definition at line 865 of file /mnt/raid/workspaces/ws.pYEvgD5Jt/overlay/gsdk/util/silicon_labs/aox/inc/sl_rtl_clib_api.h

sl_rtl_abr_get_distance#

enum sl_rtl_error_code sl_rtl_abr_get_distance (sl_rtl_abr_libitem * item, float * distance)
Parameters
[in]item

Pointer to the initialized ABR libitem

[out]distance

Distance out in meters.

Get likeliness of the distance estimate.

Returns


Definition at line 876 of file /mnt/raid/workspaces/ws.pYEvgD5Jt/overlay/gsdk/util/silicon_labs/aox/inc/sl_rtl_clib_api.h

sl_rtl_abr_get_distance_likeliness#

enum sl_rtl_error_code sl_rtl_abr_get_distance_likeliness (sl_rtl_abr_libitem * item, float * distance_likeliness)
Parameters
[in]item

Pointer to the initialized ABR libitem

[out]distance_likeliness

Likeliness between 0.0 - 1.0 (unlikely - likely) of the estimated distance

Get distance estimate.

Returns


Definition at line 885 of file /mnt/raid/workspaces/ws.pYEvgD5Jt/overlay/gsdk/util/silicon_labs/aox/inc/sl_rtl_clib_api.h