nrfxlib API 2.8.99
Loading...
Searching...
No Matches
sdc.h File Reference
#include <stdint.h>
#include <stdbool.h>
#include "nrf.h"
#include "nrf_errno.h"

Go to the source code of this file.

Data Structures

struct  sdc_cfg_role_count_t
 Role count. More...
 
struct  sdc_cfg_buffer_cfg_t
 Buffer configuration. More...
 
struct  sdc_cfg_buffer_count_t
 Buffer count configuration. More...
 
struct  sdc_cfg_adv_buffer_cfg_t
 
struct  sdc_cfg_periodic_adv_rsp_buffer_cfg_t
 
struct  sdc_cfg_iso_buffer_cfg_t
 
union  sdc_cfg_t
 SoftDevice Controller configuration.
More...
 

Macros

#define SDC_DEFAULT_RESOURCE_CFG_TAG   0
 Default resource configuration tag.
 
#define SDC_DEFAULT_ADV_COUNT   1
 Default maximum number of concurrent advertisers.
 
#define SDC_DEFAULT_PERIODIC_ADV_COUNT   0
 Default maximum number of concurrent periodic advertisers.
 
#define SDC_DEFAULT_PERIODIC_SYNC_COUNT   0
 Default maximum number of concurrent synchronizations to periodic advertisers.
 
#define SDC_DEFAULT_PERIODIC_ADV_RSP_COUNT   0
 Default maximum number of concurrent periodic advertisers with responses.
 
#define SDC_DEFAULT_PERIODIC_ADV_RSP_TX_BUFFER_COUNT   1
 Default number of buffers for subevent data.
 
#define SDC_DEFAULT_PERIODIC_ADV_RSP_MAX_TX_DATA   73
 Default maximum data size for subevent data.
 
#define SDC_DEFAULT_PERIODIC_ADV_RSP_RX_BUFFER_COUNT   0
 Default number of buffers for response reports.
 
#define SDC_DEFAULT_PERIODIC_SYNC_RSP_TX_BUFFER_COUNT   1
 Default number of buffers for response data.
 
#define SDC_DEFAULT_PERIPHERAL_COUNT   1
 Default maximum number of concurrent peripheral links.
 
#define SDC_DEFAULT_CENTRAL_COUNT   1
 Default maximum number of concurrent central links.
 
#define SDC_DEFAULT_TX_PACKET_SIZE   27
 Default maximum Link Layer TX packet size.
 
#define SDC_DEFAULT_RX_PACKET_SIZE   27
 Default maximum Link Layer RX packet size.
 
#define SDC_DEFAULT_TX_PACKET_COUNT   3
 Default maximum Link Layer TX packet count per connection.
 
#define SDC_DEFAULT_RX_PACKET_COUNT   2
 Default maximum Link Layer RX packet count per connection.
 
#define SDC_DEFAULT_FAL_SIZE   8
 Default maximum size of the Filter Accept List.
 
#define SDC_DEFAULT_SCAN_BUFFER_COUNT   3
 Default maximum number of advertising reports available in the scanner.
 
#define SDC_DEFAULT_PERIODIC_SYNC_BUFFER_COUNT   2
 Default maximum number of periodic advertising reports available.
 
#define SDC_DEFAULT_ADV_BUF_SIZE   31
 Default advertising data size when legacy advertising is supported.
 
#define SDC_DEFAULT_PERIODIC_ADV_LIST_SIZE   0
 Default number of devices that can be added to the periodic advertiser list.
 
#define SDC_DEFAULT_CIG_COUNT   0
 Default maximum number of concurrent Connected Isochronous Groups.
 
#define SDC_DEFAULT_CIS_COUNT   0
 Default maximum number of concurrent Connected Isochronous Streams.
 
#define SDC_DEFAULT_BIG_COUNT   0
 Default maximum number of concurrent Broadcast Isochronous Groups.
 
#define SDC_DEFAULT_BIS_SINK_COUNT   0
 Default maximum number of concurrent Sink Broadcast Isochronous Streams.
 
#define SDC_DEFAULT_BIS_SOURCE_COUNT   0
 Default maximum number of concurrent Source Broadcast Isochronous Streams.
 
#define SDC_DEFAULT_ISO_RX_PDU_BUFFER_PER_STREAM_COUNT   0
 Default ISO RX PDU buffer per stream count.
 
#define SDC_DEFAULT_ISO_RX_SDU_BUFFER_COUNT   0
 Default ISO RX SDU buffer count.
 
#define SDC_DEFAULT_ISO_RX_SDU_BUFFER_SIZE   251
 Default ISO RX SDU buffer size.
 
#define SDC_DEFAULT_ISO_TX_SDU_BUFFER_COUNT   0
 Default ISO SDU TX buffer count.
 
#define SDC_DEFAULT_ISO_TX_SDU_BUFFER_SIZE   247
 Default ISO SDU TX buffer size.
 
#define SDC_DEFAULT_ISO_TX_PDU_BUFFER_PER_STREAM_COUNT   0
 Default ISO TX PDU buffer per stream count.
 
#define SDC_DEFAULT_CS_COUNT   0
 Default maximum number of concurrent connections supporting CS procedure.
 
#define SDC_BUILD_REVISION_SIZE   20
 Size of build revision array in bytes.
 
#define SDC_MEM_PER_CENTRAL_LINK(tx_size, rx_size, tx_count, rx_count)
 Maximum memory required per central link.
 
#define SDC_MEM_PER_PERIPHERAL_LINK(tx_size, rx_size, tx_count, rx_count)
 Maximum memory required per peripheral link.
 
#define SDC_MEM_CENTRAL_LINKS_SHARED   17
 
#define SDC_MEM_PERIPHERAL_LINKS_SHARED   17
 
#define SDC_MEM_LE_POWER_CONTROL(num_links)
 Maximum memory required when supporting LE Power Control.
 
#define SDC_MEM_SUBRATING(num_links)
 Maximum memory required when supporting subrating.
 
#define SDC_MEM_SYNC_TRANSFER(num_links)
 Maximum memory required when supporting periodic advertising sync transfer.
 
#define SDC_MEM_QOS_CHANNEL_SURVEY   (40)
 
#define SDC_MEM_SCAN(buffer_count)
 
#define SDC_MEM_SCAN_EXT(buffer_count)
 
#define SDC_MEM_INITIATOR   (320)
 
#define SDC_MEM_FAL(max_num_entries)
 
#define SDC_MEM_PER_ADV_SET(max_adv_data)
 Maximum required memory for a given advertising buffer size.
 
#define SDC_MEM_PER_PERIODIC_ADV_SET(max_adv_data)
 Additional memory required for periodic advertising.
 
#define SDC_MEM_PER_PERIODIC_SYNC(buffer_count)
 
#define SDC_MEM_PER_PERIODIC_SYNC_RSP(tx_buffer_count, rx_buffer_count)
 
#define SDC_MEM_PERIODIC_ADV_LIST(list_size)
 
#define SDC_MEM_PER_PERIODIC_ADV_RSP_SET(max_adv_data, tx_buffer_count, rx_buffer_count, max_tx_data_size, failure_reporting_enabled)
 
#define SDC_MEM_PER_CIG(count)
 Maximum memory required per CIG.
 
#define SDC_MEM_PER_CIS(count)
 Maximum memory required per CIS. Buffer and CIG memory comes in addition.
 
#define SDC_MEM_PER_BIG(count)
 Maximum memory required per BIG.
 
#define SDC_MEM_PER_BIS(count)
 Maximum memory required per BIS. Buffer and BIG memory comes in addition.
 
#define SDC_MEM_ISO_RX_PDU_POOL_PER_STREAM_SIZE(rx_pdu_buffer_per_stream_count, cis_count, bis_sink_count)
 Maximum memory required for the ISO RX PDU pool per stream.
 
#define SDC_MEM_ISO_RX_SDU_POOL_SIZE(count, size)
 Maximum memory required for the ISO RX path SDUs.
 
#define SDC_MEM_ISO_TX_PDU_POOL_SIZE(tx_pdu_buffer_per_stream_count, cis_count, bis_source_count)
 Maximum memory required for the ISO TX PDU pool.
 
#define SDC_MEM_ISO_TX_SDU_POOL_SIZE(count, size)
 Maximum memory required for the ISO TX path SDUs.
 
#define SDC_MEM_CS(count)
 Maximum additional memory required to support Channel Sounding.
 
#define SDC_MEM_CS_SETUP_PHASE_LINKS(count)
 Maximum additional memory required to support Channel Sounding setup phase procedures.
 

Typedefs

typedef void(* sdc_fault_handler_t) (const char *file, const uint32_t line)
 Function prototype for the fault handler.
 
typedef void(* sdc_callback_t) (void)
 Function prototype for the SoftDevice Controller callback.
 

Enumerations

enum  sdc_cfg_type {
  SDC_CFG_TYPE_NONE = 0 , SDC_CFG_TYPE_CENTRAL_COUNT , SDC_CFG_TYPE_PERIPHERAL_COUNT , SDC_CFG_TYPE_BUFFER_CFG ,
  SDC_CFG_TYPE_ADV_COUNT , SDC_CFG_TYPE_SCAN_BUFFER_CFG , SDC_CFG_TYPE_ADV_BUFFER_CFG , SDC_CFG_TYPE_FAL_SIZE ,
  SDC_CFG_TYPE_PERIODIC_ADV_COUNT , SDC_CFG_TYPE_PERIODIC_SYNC_COUNT , SDC_CFG_TYPE_PERIODIC_SYNC_BUFFER_CFG , SDC_CFG_TYPE_PERIODIC_ADV_LIST_SIZE ,
  SDC_CFG_TYPE_PERIODIC_ADV_RSP_COUNT , SDC_CFG_TYPE_PERIODIC_ADV_RSP_BUFFER_CFG , SDC_CFG_TYPE_PERIODIC_ADV_RSP_FAILURE_REPORTING_CFG , SDC_CFG_TYPE_PERIODIC_SYNC_RSP_TX_BUFFER_CFG ,
  SDC_CFG_TYPE_CIG_COUNT , SDC_CFG_TYPE_CIS_COUNT , SDC_CFG_TYPE_BIG_COUNT , SDC_CFG_TYPE_BIS_SINK_COUNT ,
  SDC_CFG_TYPE_BIS_SOURCE_COUNT , SDC_CFG_TYPE_ISO_BUFFER_CFG , SDC_CFG_TYPE_CS_COUNT
}
 

Functions

int32_t sdc_init (sdc_fault_handler_t fault_handler)
 Initialize the SoftDevice Controller.
 
int32_t sdc_cfg_set (uint8_t config_tag, uint8_t config_type, sdc_cfg_t const *p_resource_cfg)
 Change or add a SoftDevice Controller configuration.
 
int32_t sdc_enable (sdc_callback_t callback, uint8_t *p_mem)
 Enable the SoftDevice Controller.
 
int32_t sdc_disable (void)
 Disable the SoftDevice Controller.
 
int32_t sdc_build_revision_get (uint8_t *p_build_revision)
 Obtain build revision string.
 
int32_t sdc_support_adv (void)
 Support Advertising State.
 
int32_t sdc_support_ext_adv (void)
 Support extended advertising.
 
int32_t sdc_support_peripheral (void)
 Support Peripheral role.
 
int32_t sdc_support_scan (void)
 Support Scanning state.
 
int32_t sdc_support_ext_scan (void)
 Support scanning for extended advertising PDUs.
 
int32_t sdc_support_central (void)
 Support Scanner, Initiator, and Central role.
 
int32_t sdc_support_ext_central (void)
 Support Extended Scanner, Extended Initiator, and Central role.
 
int32_t sdc_support_parallel_scanning_and_initiating (void)
 Support for scanning and initiating at the same time.
 
int32_t sdc_support_le_power_class_1 (void)
 Support LE Power Class 1.
 
int32_t sdc_support_dle_central (void)
 Support Data Length Extensions for a central device.
 
int32_t sdc_support_dle_peripheral (void)
 Support Data Length Extensions for a peripheral device.
 
int32_t sdc_support_le_2m_phy (void)
 Support LE 2M PHY.
 
int32_t sdc_support_le_coded_phy (void)
 Support LE Coded PHY.
 
int32_t sdc_support_phy_update_central (void)
 Support PHY Update Procedure for central role.
 
int32_t sdc_support_phy_update_peripheral (void)
 Support LE Coded PHY for peripheral role.
 
int32_t sdc_support_le_periodic_adv (void)
 Support LE Periodic Advertising in the Advertising state.
 
int32_t sdc_support_le_periodic_sync (void)
 Support LE Periodic Advertising in the Synchronization state.
 
int32_t sdc_support_le_periodic_adv_with_rsp (void)
 Support LE Periodic Advertising with Responses in the Advertising state.
 
int32_t sdc_support_le_periodic_sync_with_rsp (void)
 Support LE Periodic Advertising with Responses in the Synchronization state.
 
int32_t sdc_support_le_power_control_central (void)
 Support LE Power Control for central role.
 
int32_t sdc_support_le_power_control_peripheral (void)
 Support LE Power Control for peripheral role.
 
int32_t sdc_support_le_path_loss_monitoring (void)
 Support LE Path Loss Monitoring.
 
int32_t sdc_support_sca_central (void)
 Support Sleep Clock Accuracy (SCA) Update procedure for central role.
 
int32_t sdc_support_sca_peripheral (void)
 Support Sleep Clock Accuracy (SCA) Update procedure for peripheral role.
 
int32_t sdc_support_le_conn_cte_rsp_central (void)
 Support LE Connection CTE response for central role.
 
int32_t sdc_support_le_conn_cte_rsp_peripheral (void)
 Support LE Connection CTE response for peripheral role.
 
int32_t sdc_support_periodic_adv_sync_transfer_sender_central (void)
 Support for sending periodic advertising sync transfers as central role.
 
int32_t sdc_support_periodic_adv_sync_transfer_sender_peripheral (void)
 Support for sending periodic advertising sync transfers as peripheral role.
 
int32_t sdc_support_periodic_adv_sync_transfer_receiver_central (void)
 Support for receiving periodic advertising sync transfers as central role.
 
int32_t sdc_support_periodic_adv_sync_transfer_receiver_peripheral (void)
 Support for receiving periodic advertising sync transfers as peripheral role.
 
int32_t sdc_support_cis_peripheral (void)
 Support Connected Isochronous streams in the peripheral role.
 
int32_t sdc_support_cis_central (void)
 Support Connected Isochronous streams in the central role.
 
int32_t sdc_support_bis_source (void)
 Support Broadcast Isochronous streams as a source.
 
int32_t sdc_support_bis_sink (void)
 Support Broadcast Isochronous streams as a sink.
 
int32_t sdc_iso_host_timestamps_ignore (bool ignore)
 Configure the controller to ignore HCI ISO data timestamps from the host.
 
int32_t sdc_support_qos_channel_survey (void)
 Support for Quality of Service (QoS) channel survey module.
 
int32_t sdc_default_tx_power_set (int8_t requested_power_level)
 Support for setting the default radio TX power level.
 
int32_t sdc_support_connection_subrating_central (void)
 Support Connection Subrating for central role.
 
int32_t sdc_support_connection_subrating_peripheral (void)
 Support Connection Subrating for peripheral role.
 
int32_t sdc_support_channel_sounding_test (void)
 Support Channel Sounding test command.
 
int32_t sdc_support_channel_sounding (void)
 Support LE Channel Sounding.