Bluetooth: host: Add CTE reports receive cb API for per sync
Add new callback to periodic advertising sync callback. The callback may be used to receive notification about CTE reports in connectionless mode (periodic advetising sync). Signed-off-by: Piotr Pryga <piotr.pryga@nordicsemi.no>
This commit is contained in:
parent
64c359bcef
commit
105a85cdf5
2 changed files with 32 additions and 0 deletions
|
@ -57,6 +57,9 @@ struct bt_conn;
|
|||
/* Don't require everyone to include iso.h */
|
||||
struct bt_iso_biginfo;
|
||||
|
||||
/* Don't require everyone to include direction.h */
|
||||
struct bt_df_per_adv_sync_iq_samples_report;
|
||||
|
||||
struct bt_le_ext_adv_sent_info {
|
||||
/** The number of advertising events completed. */
|
||||
uint8_t num_sent;
|
||||
|
@ -1243,6 +1246,16 @@ struct bt_le_per_adv_sync_cb {
|
|||
*/
|
||||
void (*biginfo)(struct bt_le_per_adv_sync *sync, const struct bt_iso_biginfo *biginfo);
|
||||
|
||||
/**
|
||||
* @brief Callback for IQ samples report collected when sampling
|
||||
* CTE received with periodic advertising PDU.
|
||||
*
|
||||
* @param sync The periodic advertising sync object.
|
||||
* @param info Information about the sync event.
|
||||
*/
|
||||
void (*cte_report_cb)(struct bt_le_per_adv_sync *sync,
|
||||
struct bt_df_per_adv_sync_iq_samples_report const *info);
|
||||
|
||||
sys_snode_t node;
|
||||
};
|
||||
|
||||
|
|
|
@ -88,6 +88,25 @@ struct bt_df_per_adv_sync_cte_rx_param {
|
|||
const uint8_t *ant_ids;
|
||||
};
|
||||
|
||||
struct bt_df_per_adv_sync_iq_samples_report {
|
||||
/** Channel index used to receive PDU with CTE that was sampled. */
|
||||
uint8_t chan_idx;
|
||||
/** The RSSI of the PDU with CTE (excluding CTE). */
|
||||
int16_t rssi;
|
||||
/** Id of antenna used to measure the RSSI. */
|
||||
uint8_t rssi_ant_id;
|
||||
/** Type of CTE (@ref BT_DF_CTE_TYPE). */
|
||||
uint8_t cte_type;
|
||||
/** Duration of slots when received CTE type is AoA (@ref BT_DF_ANTENNA_SWITCHING_SLOT). */
|
||||
uint8_t slot_durations;
|
||||
/** Status of received PDU with CTE (@ref BT_DF_RX_POCKET_STATUS). */
|
||||
uint8_t packet_status;
|
||||
/** Number of IQ samples in report. */
|
||||
uint8_t sample_count;
|
||||
/** Pinter to IQ samples data. */
|
||||
struct bt_hci_le_iq_sample const *sample;
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Set or update the Constant Tone Extension parameters for periodic advertising set.
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue