CS Reflector#
Channel Sounding (CS) Reflector role implementation for all BLE Channel Sounding apps.
Modules#
Functions#
Macros#
Function Documentation#
typedef#
typedef (struct { int8_t max_tx_power_dbm;} )
N/A |
44
of file common/cs_reflector/cs_reflector.h
cs_reflector_identify#
bool cs_reflector_identify (uint8_t conn_handle)
[in] | conn_handle | the connection handle to identify |
Determine whether a connection handle has a reflector associated to it
Returns
true
if the handle has an associated reflector instance,false
otherwise
56
of file common/cs_reflector/cs_reflector.h
cs_reflector_create#
sl_status_t cs_reflector_create (uint8_t conn_handle, cs_reflector_config_t * reflector_config)
[in] | conn_handle | the connection handle for which to create the reflector |
[in] | reflector_config | reflector configuration parameters |
Create a reflector for the given connection handle
Returns
status of the operation
66
of file common/cs_reflector/cs_reflector.h
cs_reflector_get_active_instance_count#
uint8_t cs_reflector_get_active_instance_count (void )
N/A |
Get the number of active reflector instances
Returns
the number of active reflector instances
74
of file common/cs_reflector/cs_reflector.h
cs_reflector_delete#
sl_status_t cs_reflector_delete (uint8_t conn_handle)
[in] | conn_handle | the connection handle for which to delete the reflector |
Delete the reflector associated with the given connection handle
Returns
status of the operation
83
of file common/cs_reflector/cs_reflector.h
cs_reflector_on_bt_event#
bool cs_reflector_on_bt_event (sl_bt_msg_t * evt)
[in] | evt | the Bluetooth stack event to handle |
Handle a Bluetooth stack event
Returns
true to forward the message to the host in NCP case
92
of file common/cs_reflector/cs_reflector.h
cs_rcm_get_connection_ctx#
connection_ctx_t * cs_rcm_get_connection_ctx (const uint8_t conn_handle)
[in] | conn_handle | the connection handle to search for |
Find the pointer to a connection context which belongs to the provided connection handle.
Returns
the pointer of the context corresponding to the provided connection handle, NULL if not found
63
of file common/cs_reflector/cs_reflector_connmanager.h
cs_rcm_add_new_initiator_connection#
sl_status_t cs_rcm_add_new_initiator_connection (const uint8_t conn_handle)
[in] | conn_handle | the connection handle to register |
Register a new initiator connection with the provided handle.
Returns
status of the operation
72
of file common/cs_reflector/cs_reflector_connmanager.h
cs_rcm_remove_initiator_connection#
void cs_rcm_remove_initiator_connection (const uint8_t conn_handle)
[in] | conn_handle | the connection handle to remove |
Remove an initiator connection with the provided handle.
79
of file common/cs_reflector/cs_reflector_connmanager.h
cs_rcm_can_accept_new_connection#
bool cs_rcm_can_accept_new_connection (void )
N/A |
Tell whether an additional connection can be accepted.
Returns
true if an additional connection can be accepted, false otherwise
86
of file common/cs_reflector/cs_reflector_connmanager.h
cs_rcm_get_number_of_connections#
uint8_t cs_rcm_get_number_of_connections (void )
N/A |
Show the number of active connections.
Returns
the number of active connections
93
of file common/cs_reflector/cs_reflector_connmanager.h
cs_reflector_event_buf_clear#
void cs_reflector_event_buf_clear (void )
N/A |
Clear all data from the CS event buffer.
58
of file common/cs_reflector/cs_reflector_event_buf.h
cs_reflector_event_buf_get_free_space#
uint32_t cs_reflector_event_buf_get_free_space (void )
N/A |
Tell the number of free slots available in the CS event buffer.
Returns
the number of free slots available in the CS event buffer
65
of file common/cs_reflector/cs_reflector_event_buf.h
cs_reflector_event_buf_purge_data#
void cs_reflector_event_buf_purge_data (const uint8_t conn_handle)
[in] | conn_handle | the connection handle to erase all data for |
Purge any data from the CS event buffer associated with a connection. Useful when an initiator disconnects and we don't want any leftover measurement data in the buffer.
74
of file common/cs_reflector/cs_reflector_event_buf.h
cs_reflector_event_buf_get_element_for_write#
cs_event_data_t * cs_reflector_event_buf_get_element_for_write (void )
N/A |
Find a pointer to a buffer element which is free to write, yields NULL if no writable elements are available.
Returns
pointer to a free buffer element, NULL if none available
82
of file common/cs_reflector/cs_reflector_event_buf.h
cs_reflector_event_buf_get_next_element#
cs_event_data_t * cs_reflector_event_buf_get_next_element (const uint8_t conn_handle)
[in] | conn_handle | the connection handle for which the data is requested |
Provide a pointer to the next available data for a given connection, yields NULL if no next data is available.
Returns
pointer to the next available data, NULL if none available
92
of file common/cs_reflector/cs_reflector_event_buf.h
cs_reflector_event_buf_find#
cs_event_data_t * cs_reflector_event_buf_find (const uint8_t conn_handle, const uint16_t procedure_index, const uint16_t subevent_index)
[in] | conn_handle | the connection handle for which the data is requested |
[in] | procedure_index | procedure index of requested the result |
[in] | subevent_index | subevent index of requested the result |
Find and return an exact result from the CS event buffer.
Returns
pointer to the result if available, NULL if not found
103
of file common/cs_reflector/cs_reflector_event_buf.h
cs_reflector_event_buf_get_next_unindicated#
cs_event_data_t * cs_reflector_event_buf_get_next_unindicated (const uint8_t conn_handle)
[in] | conn_handle | the connection handle for which the data is requested |
Find a pointer to the next available data which we haven't sent an indication about for a given connection.
Returns
pointer to the result if available, NULL if none available
115
of file common/cs_reflector/cs_reflector_event_buf.h
Macro Definition Documentation#
CS_REFLECTOR_MAX_CONNECTIONS#
#define CS_REFLECTOR_MAX_CONNECTIONSValue:
SL_BT_CONFIG_MAX_CONNECTIONS
41
of file common/cs_reflector/config/cs_reflector_config.h
CS_REFLECTOR_CS_EVENT_BUF_SIZE#
#define CS_REFLECTOR_CS_EVENT_BUF_SIZEValue:
(16)
50
of file common/cs_reflector/config/cs_reflector_config.h
CS_REFLECTOR_MIN_TX_POWER_DBM#
#define CS_REFLECTOR_MIN_TX_POWER_DBMValue:
(-3)
55
of file common/cs_reflector/config/cs_reflector_config.h
CS_REFLECTOR_MAX_TX_POWER_DBM#
#define CS_REFLECTOR_MAX_TX_POWER_DBMValue:
(20)
60
of file common/cs_reflector/config/cs_reflector_config.h
CS_REFLECTOR_ANTENNA_OFFSET#
#define CS_REFLECTOR_ANTENNA_OFFSETValue:
0
66
of file common/cs_reflector/config/cs_reflector_config.h
CS_REFLECTOR_LOG#
#define CS_REFLECTOR_LOGValue:
1
71
of file common/cs_reflector/config/cs_reflector_config.h
CS_REFLECTOR_LOG_PREFIX#
#define CS_REFLECTOR_LOG_PREFIXValue:
"[Reflector]"
76
of file common/cs_reflector/config/cs_reflector_config.h
CS_EVENT_BUF_DATA_MAX_LEN#
#define CS_EVENT_BUF_DATA_MAX_LENValue:
256
43
of file common/cs_reflector/cs_reflector_event_buf.h