bluetooth: Split configuration into separated Kconfigs
Extracted new Kconfig file for the Extended Advertising and for the Bluetooth Isochronous Channel from the Bluetooth subsystem Kconfig. Signed-off-by: Kamil Gawor <Kamil.Gawor@nordicsemi.no>
This commit is contained in:
parent
3f09f94bd2
commit
50ff77fa91
|
@ -107,71 +107,7 @@ config BT_BROADCASTER
|
|||
|
||||
endmenu
|
||||
|
||||
config BT_LIM_ADV_TIMEOUT
|
||||
int "Timeout for limited advertising in 1s units"
|
||||
default 30
|
||||
range 1 180
|
||||
help
|
||||
After this timeout is reached, advertisement with BT_LE_AD_LIMITED flag
|
||||
set shall be terminated. As per BT Core Spec 5.2, Vol 3, Part C,
|
||||
Appendix A (NORMATIVE): TIMERS AND CONSTANTS it's required to be no more
|
||||
than 180s.
|
||||
|
||||
config BT_EXT_ADV
|
||||
bool "Extended Advertising and Scanning support [EXPERIMENTAL]"
|
||||
help
|
||||
Select this to enable Extended Advertising API support.
|
||||
This enables support for advertising with multiple advertising sets,
|
||||
extended advertising data, and advertising on LE Coded PHY.
|
||||
It enables support for receiving extended advertising data as a
|
||||
scanner, including support for advertising data over the LE coded PHY.
|
||||
It enables establishing connections over LE Coded PHY.
|
||||
|
||||
if BT_EXT_ADV
|
||||
config BT_EXT_ADV_LEGACY_SUPPORT
|
||||
bool "Support starting advertising through legacy commands"
|
||||
help
|
||||
Select this to enable the use of the Legacy Advertising HCI commands.
|
||||
This option should be used where the capabilities of the controller
|
||||
is not known.
|
||||
If this option is not enabled the controller must support the extended
|
||||
advertising feature.
|
||||
|
||||
config BT_EXT_ADV_MAX_ADV_SET
|
||||
int "Maximum number of simultaneous advertising sets"
|
||||
range 1 64
|
||||
default 1
|
||||
help
|
||||
Maximum number of simultaneous Bluetooth advertising sets
|
||||
supported.
|
||||
|
||||
config BT_PER_ADV
|
||||
bool "Periodic Advertising and Scanning support [EXPERIMENTAL]"
|
||||
help
|
||||
Select this to enable Periodic Advertising API support. This allows
|
||||
the device to send advertising data periodically at deterministic
|
||||
intervals. Scanners can synchronize to the periodic advertisements
|
||||
to periodically get the data.
|
||||
|
||||
config BT_PER_ADV_SYNC
|
||||
bool "Periodic advertising sync support [EXPERIMENTAL]"
|
||||
depends on BT_OBSERVER
|
||||
help
|
||||
Select this to enable Periodic Advertising Sync API support.
|
||||
Syncing with a periodic advertiser allows the device to periodically
|
||||
and deterministic receive data from that device in a connectionless
|
||||
manner.
|
||||
|
||||
if BT_PER_ADV_SYNC
|
||||
config BT_PER_ADV_SYNC_MAX
|
||||
int "Maximum number of simultaneous periodic advertising syncs"
|
||||
range 1 64
|
||||
default 1
|
||||
help
|
||||
Maximum number of simultaneous periodic advertising syncs supported.
|
||||
endif # BT_PER_ADV_SYNC
|
||||
|
||||
endif # BT_EXT_ADV
|
||||
rsource "Kconfig.adv"
|
||||
|
||||
menu "Observer"
|
||||
visible if !BT_CENTRAL
|
||||
|
@ -233,104 +169,7 @@ config BT_DATA_LEN_UPDATE
|
|||
Enable support for Bluetooth v4.2 LE Data Length Update procedure.
|
||||
endif # BT_CONN
|
||||
|
||||
|
||||
config BT_ISO
|
||||
bool # hidden
|
||||
|
||||
config BT_ISO_UNICAST
|
||||
bool "Bluetooth Isochronous Channel Unicast Support [EXPERIMENTAL]"
|
||||
depends on BT_CONN
|
||||
select BT_ISO
|
||||
help
|
||||
This option enables support for Bluetooth Broadcast
|
||||
Isochronous channels.
|
||||
|
||||
# TODO: Split between broadcaster and observer for optimization
|
||||
config BT_ISO_BROADCAST
|
||||
bool "Bluetooth Isochronous Channel Broadcast Support [EXPERIMENTAL]"
|
||||
select BT_ISO
|
||||
select BT_EXT_ADV
|
||||
select BT_PER_ADV
|
||||
select BT_PER_ADV_SYNC
|
||||
help
|
||||
This option enables support for Bluetooth Broadcast
|
||||
Isochronous channels.
|
||||
|
||||
if BT_ISO
|
||||
|
||||
config BT_ISO_MAX_CHAN
|
||||
int "Maximum number of simultaneous ISO channels"
|
||||
depends on BT_ISO
|
||||
default BT_MAX_CONN if BT_CONN
|
||||
default 1
|
||||
range 1 64
|
||||
help
|
||||
Maximum number of simultaneous Bluetooth isochronous channels
|
||||
supported.
|
||||
|
||||
config BT_ISO_TX_BUF_COUNT
|
||||
int "Number of Isochronous TX buffers"
|
||||
default 1
|
||||
range 1 255
|
||||
help
|
||||
Number of buffers available for outgoing Isochronous channel SDUs.
|
||||
|
||||
config BT_ISO_TX_FRAG_COUNT
|
||||
int "Number of ISO TX fragment buffers"
|
||||
default 2
|
||||
range 0 255
|
||||
help
|
||||
Number of buffers available for fragments of TX buffers. Warning:
|
||||
setting this to 0 means that the application must ensure that
|
||||
queued TX buffers never need to be fragmented, i.e. that the
|
||||
controller's buffer size is large enough. If this is not ensured,
|
||||
and there are no dedicated fragment buffers, a deadlock may occur.
|
||||
In most cases the default value of 2 is a safe bet.
|
||||
|
||||
config BT_ISO_TX_MTU
|
||||
int "Maximum supported MTU for Isochronous TX buffers"
|
||||
default 251
|
||||
range 23 4095
|
||||
help
|
||||
Maximum MTU for Isochronous channels TX buffers.
|
||||
|
||||
config BT_ISO_RX_BUF_COUNT
|
||||
int "Number of Isochronous RX buffers"
|
||||
default 1
|
||||
range 1 255
|
||||
help
|
||||
Number of buffers available for incoming Isochronous channel SDUs.
|
||||
|
||||
config BT_ISO_RX_MTU
|
||||
int "Maximum supported MTU for Isochronous RX buffers"
|
||||
default 251
|
||||
range 23 4095
|
||||
help
|
||||
Maximum MTU for Isochronous channels RX buffers.
|
||||
|
||||
if BT_ISO_UNICAST
|
||||
|
||||
config BT_ISO_MAX_CIG
|
||||
int "Maximum number of Connected Isochronous Groups (CIGs) to support"
|
||||
default 1
|
||||
help
|
||||
Maximum number of CIGs that are supported by the host. A CIG can be
|
||||
used for either transmitting or receiving.
|
||||
|
||||
endif # BT_ISO_UNICAST
|
||||
|
||||
if BT_ISO_BROADCAST
|
||||
|
||||
config BT_ISO_MAX_BIG
|
||||
int "Maximum number of Broadcast Isochronous Groups (BIGs) to support"
|
||||
default 1
|
||||
help
|
||||
Maximmum number of BIGs that are supported by the host. A BIG can be
|
||||
used for either transmitting or receiving, but not at the same time.
|
||||
|
||||
endif # BT_ISO_BROADCAST
|
||||
endif # BT_ISO
|
||||
|
||||
rsource "Kconfig.iso"
|
||||
rsource "common/Kconfig"
|
||||
rsource "host/Kconfig"
|
||||
rsource "controller/Kconfig"
|
||||
|
|
73
subsys/bluetooth/Kconfig.adv
Normal file
73
subsys/bluetooth/Kconfig.adv
Normal file
|
@ -0,0 +1,73 @@
|
|||
# Bluetooth LE Advertising and Scanning configuration options
|
||||
|
||||
# Copyright (c) 2016 Intel Corporation
|
||||
# Copyright (c) 2021 Nordic Semiconductor ASA
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
config BT_LIM_ADV_TIMEOUT
|
||||
int "Timeout for limited advertising in 1s units"
|
||||
default 30
|
||||
range 1 180
|
||||
help
|
||||
After this timeout is reached, advertisement with BT_LE_AD_LIMITED flag
|
||||
set shall be terminated. As per BT Core Spec 5.2, Vol 3, Part C,
|
||||
Appendix A (NORMATIVE): TIMERS AND CONSTANTS it's required to be no more
|
||||
than 180s.
|
||||
|
||||
config BT_EXT_ADV
|
||||
bool "Extended Advertising and Scanning support [EXPERIMENTAL]"
|
||||
help
|
||||
Select this to enable Extended Advertising API support.
|
||||
This enables support for advertising with multiple advertising sets,
|
||||
extended advertising data, and advertising on LE Coded PHY.
|
||||
It enables support for receiving extended advertising data as a
|
||||
scanner, including support for advertising data over the LE coded PHY.
|
||||
It enables establishing connections over LE Coded PHY.
|
||||
|
||||
if BT_EXT_ADV
|
||||
|
||||
config BT_EXT_ADV_LEGACY_SUPPORT
|
||||
bool "Support starting advertising through legacy commands"
|
||||
help
|
||||
Select this to enable the use of the Legacy Advertising HCI commands.
|
||||
This option should be used where the capabilities of the controller
|
||||
is not known.
|
||||
If this option is not enabled the controller must support the extended
|
||||
advertising feature.
|
||||
|
||||
config BT_EXT_ADV_MAX_ADV_SET
|
||||
int "Maximum number of simultaneous advertising sets"
|
||||
range 1 64
|
||||
default 1
|
||||
help
|
||||
Maximum number of simultaneous Bluetooth advertising sets
|
||||
supported.
|
||||
|
||||
config BT_PER_ADV
|
||||
bool "Periodic Advertising and Scanning support [EXPERIMENTAL]"
|
||||
help
|
||||
Select this to enable Periodic Advertising API support. This allows
|
||||
the device to send advertising data periodically at deterministic
|
||||
intervals. Scanners can synchronize to the periodic advertisements
|
||||
to periodically get the data.
|
||||
|
||||
config BT_PER_ADV_SYNC
|
||||
bool "Periodic advertising sync support [EXPERIMENTAL]"
|
||||
depends on BT_OBSERVER
|
||||
help
|
||||
Select this to enable Periodic Advertising Sync API support.
|
||||
Syncing with a periodic advertiser allows the device to periodically
|
||||
and deterministic receive data from that device in a connectionless
|
||||
manner.
|
||||
|
||||
if BT_PER_ADV_SYNC
|
||||
|
||||
config BT_PER_ADV_SYNC_MAX
|
||||
int "Maximum number of simultaneous periodic advertising syncs"
|
||||
range 1 64
|
||||
default 1
|
||||
help
|
||||
Maximum number of simultaneous periodic advertising syncs supported.
|
||||
|
||||
endif # BT_PER_ADV_SYNC
|
||||
endif # BT_EXT_ADV
|
102
subsys/bluetooth/Kconfig.iso
Normal file
102
subsys/bluetooth/Kconfig.iso
Normal file
|
@ -0,0 +1,102 @@
|
|||
# Bluetooth Isochronous Channel configuration options
|
||||
|
||||
# Copyright (c) 2016 Intel Corporation
|
||||
# Copyright (c) 2021 Nordic Semiconductor ASA
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
config BT_ISO
|
||||
bool
|
||||
|
||||
config BT_ISO_UNICAST
|
||||
bool "Bluetooth Isochronous Channel Unicast Support [EXPERIMENTAL]"
|
||||
depends on BT_CONN
|
||||
select BT_ISO
|
||||
help
|
||||
This option enables support for Bluetooth Broadcast
|
||||
Isochronous channels.
|
||||
|
||||
# TODO: Split between broadcaster and observer for optimization
|
||||
config BT_ISO_BROADCAST
|
||||
bool "Bluetooth Isochronous Channel Broadcast Support [EXPERIMENTAL]"
|
||||
select BT_ISO
|
||||
select BT_EXT_ADV
|
||||
select BT_PER_ADV
|
||||
select BT_PER_ADV_SYNC
|
||||
help
|
||||
This option enables support for Bluetooth Broadcast
|
||||
Isochronous channels.
|
||||
|
||||
if BT_ISO
|
||||
|
||||
config BT_ISO_MAX_CHAN
|
||||
int "Maximum number of simultaneous ISO channels"
|
||||
depends on BT_ISO
|
||||
default BT_MAX_CONN if BT_CONN
|
||||
default 1
|
||||
range 1 64
|
||||
help
|
||||
Maximum number of simultaneous Bluetooth isochronous channels
|
||||
supported.
|
||||
|
||||
config BT_ISO_TX_BUF_COUNT
|
||||
int "Number of Isochronous TX buffers"
|
||||
default 1
|
||||
range 1 255
|
||||
help
|
||||
Number of buffers available for outgoing Isochronous channel SDUs.
|
||||
|
||||
config BT_ISO_TX_FRAG_COUNT
|
||||
int "Number of ISO TX fragment buffers"
|
||||
default 2
|
||||
range 0 255
|
||||
help
|
||||
Number of buffers available for fragments of TX buffers. Warning:
|
||||
setting this to 0 means that the application must ensure that
|
||||
queued TX buffers never need to be fragmented, i.e. that the
|
||||
controller's buffer size is large enough. If this is not ensured,
|
||||
and there are no dedicated fragment buffers, a deadlock may occur.
|
||||
In most cases the default value of 2 is a safe bet.
|
||||
|
||||
config BT_ISO_TX_MTU
|
||||
int "Maximum supported MTU for Isochronous TX buffers"
|
||||
default 251
|
||||
range 23 4095
|
||||
help
|
||||
Maximum MTU for Isochronous channels TX buffers.
|
||||
|
||||
config BT_ISO_RX_BUF_COUNT
|
||||
int "Number of Isochronous RX buffers"
|
||||
default 1
|
||||
range 1 255
|
||||
help
|
||||
Number of buffers available for incoming Isochronous channel SDUs.
|
||||
|
||||
config BT_ISO_RX_MTU
|
||||
int "Maximum supported MTU for Isochronous RX buffers"
|
||||
default 251
|
||||
range 23 4095
|
||||
help
|
||||
Maximum MTU for Isochronous channels RX buffers.
|
||||
|
||||
if BT_ISO_UNICAST
|
||||
|
||||
config BT_ISO_MAX_CIG
|
||||
int "Maximum number of Connected Isochronous Groups (CIGs) to support"
|
||||
default 1
|
||||
help
|
||||
Maximum number of CIGs that are supported by the host. A CIG can be
|
||||
used for either transmitting or receiving.
|
||||
|
||||
endif # BT_ISO_UNICAST
|
||||
|
||||
if BT_ISO_BROADCAST
|
||||
|
||||
config BT_ISO_MAX_BIG
|
||||
int "Maximum number of Broadcast Isochronous Groups (BIGs) to support"
|
||||
default 1
|
||||
help
|
||||
Maximmum number of BIGs that are supported by the host. A BIG can be
|
||||
used for either transmitting or receiving, but not at the same time.
|
||||
|
||||
endif # BT_ISO_BROADCAST
|
||||
endif # BT_ISO
|
Loading…
Reference in a new issue