Bluetooth: host: direction: Add public API to set CTE TX params for adv.
Add publicly accessible function to set Constant Tone Extension parameters for CTE transmission with periodic advertising. Signed-off-by: Piotr Pryga <piotr.pryga@nordicsemi.no>
This commit is contained in:
parent
098f767298
commit
1c493b4a77
3 changed files with 69 additions and 42 deletions
40
include/bluetooth/direction.h
Normal file
40
include/bluetooth/direction.h
Normal file
|
@ -0,0 +1,40 @@
|
|||
/*
|
||||
* Copyright (c) 2020 Nordic Semiconductor ASA
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
#ifndef ZEPHYR_INCLUDE_BLUETOOTH_DF_H_
|
||||
#define ZEPHYR_INCLUDE_BLUETOOTH_DF_H_
|
||||
|
||||
/** @brief Constant Tone Extension parameters for connectionless
|
||||
* transmission.
|
||||
*
|
||||
* The structure holds information required to setup CTE transmission
|
||||
* in periodic advertising.
|
||||
*/
|
||||
struct bt_df_adv_cte_tx_param {
|
||||
/** Length of CTE in 8us units */
|
||||
uint8_t cte_len;
|
||||
/** CTE Type: AoA, AoD 1us slots, AoD 2us slots */
|
||||
uint8_t cte_type;
|
||||
/** Number of CTE to transmit in each periodic adv interval */
|
||||
uint8_t cte_count;
|
||||
/** Number of Antenna IDs in the switch pattern */
|
||||
uint8_t num_ant_ids;
|
||||
/** List of antenna IDs in the pattern */
|
||||
uint8_t *ant_ids;
|
||||
};
|
||||
|
||||
/** @brief Set or update the Constant Tone Extension parameters for periodic
|
||||
* advertising set.
|
||||
*
|
||||
* @param[in] adv Advertising set object.
|
||||
* @param[in] params Constant Tone Extension parameters.
|
||||
*
|
||||
* @return Zero on success or (negative) error code otherwise.
|
||||
*/
|
||||
int bt_df_set_adv_cte_tx_param(struct bt_le_ext_adv *adv,
|
||||
const struct bt_df_adv_cte_tx_param *params);
|
||||
|
||||
#endif /* ZEPHYR_INCLUDE_BLUETOOTH_DF_H_ */
|
Loading…
Add table
Add a link
Reference in a new issue