Files

317 lines
8.7 KiB
Plaintext
Raw Permalink Normal View History

2025-07-22 11:15:46 +08:00
# Kconfig file for package NimBLE
menuconfig LPKG_USING_NIMBLE
bool "NimBLE:An open-source Bluetooth 5.0 stack porting on RT-Thread"
select RT_USING_MESSAGEQUEUE
default n
if LPKG_USING_NIMBLE
config LPKG_NIMBLE_PATH
string
default "/packages/third-part/nimble"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
menu "Bluetooth Role support"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_ROLE_PERIPHERAL
bool "Peripheral Role support"
select LPKG_NIMBLE_ROLE_BROADCASTER
default y
help
Select this for LE Peripheral role support.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_ROLE_CENTRAL
bool "Central Role support"
select LPKG_NIMBLE_ROLE_OBSERVER
default y
help
Select this for LE Central role support.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_ROLE_BROADCASTER
bool "Broadcaster Role support"
default y
help
Select this for LE Broadcaster role support.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_ROLE_OBSERVER
bool "Observer Role support"
help
Select this for LE Observer role support.
endmenu
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
menu "Host Stack Configuration"
config LPKG_NIMBLE_HOST
bool "Bluetooth Host Stack support"
default y
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
if LPKG_NIMBLE_HOST
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_HOST_THREAD_STACK_SIZE
int "The thread stack Size of Host Stack"
default 1536
help
Set Host thread stack size.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_HOST_THREAD_PRIORITY
int "The thread priority of Host Stack"
default 8
help
Set Host Stack thread priority.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
endif
endmenu
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
menu "Controller Configuration"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_CTLR
bool "Bluetooth Controller support"
2025-10-21 13:59:50 +08:00
default n
2025-07-22 11:15:46 +08:00
help
Enable support for nordic controller implementations.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
if LPKG_NIMBLE_CTLR
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_CTLR_THREAD_STACK_SIZE
int "The thread stack Size of Controller"
default 1024
help
Set Controller thread stack size.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_CTLR_THREAD_PRIORITY
int "The thread priority of Controller"
default 7
help
Set Controller thread priority.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
choice
prompt "Bluetooth device support"
default LPKG_NIMBLE_BSP_NRF52
help
Select the device controller layer support.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_BSP_NRF51
bool "NRF51xxx"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_BSP_NRF52
bool "NRF52xxx"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_BSP_NRF52840
bool "NRF52840"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
endchoice
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
endif
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
endmenu
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
menu "Bluetooth Mesh support"
config LPKG_NIMBLE_MESH
bool "Bluetooth Mesh support"
default n
depends on LPKG_NIMBLE_ROLE_BROADCASTER && LPKG_NIMBLE_ROLE_OBSERVER
help
This option enables Bluetooth Mesh support. The specific
features that are available may depend on other features
that have been enabled in the stack, such as GATT support.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
if LPKG_NIMBLE_MESH
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_MESH_DEVICE_NAME
string "BLE Mesh device/node name"
default "nimble-node"
help
This value defines BLE Mesh device/node name.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_MESH_ADV_THREAD_STACK_SIZE
int "The thread stack Size of Mesh advertising"
default 1024
help
Set Mesh advertising thread stack size.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_MESH_ADV_THREAD_PRIORITY
int "The thread priority of Mesh Advertising"
default 9
help
Set Mesh Advertising thread priority.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_MESH_CFG_CLI
bool "Support for Configuration Client Model"
help
Enable support for the configuration client model.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
endif
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
endmenu
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
menu "HCI Transport support"
config LPKG_NIMBLE_HCI_USING_RTT_UART
bool "HCI Transport using rt-thread uart"
default n
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
if LPKG_NIMBLE_HCI_USING_RTT_UART
config LPKG_NIMBLE_HCI_UART_DEVICE_NAME
string "The uart for HCI Transport"
default "uart1"
endif
2025-10-21 13:59:50 +08:00
endmenu
menu "HCI Protocol support"
choice
prompt "Select HCI Protocol"
default LPKG_NIMBLE_HCI_H5
config LPKG_NIMBLE_HCI_H4
bool "HCI Protocol using H4"
config LPKG_NIMBLE_HCI_H5
bool "HCI Protocol using H5"
endchoice
2025-07-22 11:15:46 +08:00
endmenu
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
menu "Device Driver support"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
endmenu
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
choice
prompt "NimBLE log level"
default LPKG_NIMBLE_DEBUG_LEVEL_INFO
help
select the NIMBLE log level
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_DEBUG_LEVEL_NONE
bool "none"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_DEBUG_LEVEL_ERR
bool "error"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_DEBUG_LEVEL_WARN
bool "warn"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_DEBUG_LEVEL_INFO
bool "info"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_DEBUG_LEVEL_DEBUG
bool "debug"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
endchoice
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_DEBUG_LEVEL
int
default 0 if LPKG_NIMBLE_DEBUG_LEVEL_NONE
default 3 if LPKG_NIMBLE_DEBUG_LEVEL_ERR
default 4 if LPKG_NIMBLE_DEBUG_LEVEL_WARN
default 6 if LPKG_NIMBLE_DEBUG_LEVEL_INFO
default 7 if LPKG_NIMBLE_DEBUG_LEVEL_DEBUG
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
choice
prompt "Bluetooth Samples"
default LPKG_NIMBLE_SAMPLE_DISABLE
help
select the NimBLE samples
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_SAMPLE_DISABLE
bool "Not enable sample"
2025-10-21 13:59:50 +08:00
config LPKG_NIMBLE_SAMPLE_BLUFI
bool "BLE Assisted WiFi provisioning"
select NIMBT_ROLE_PERIPHERAL
config LPKG_NIMBLE_SAMPLE_SELFIE
bool "BLE selfie sample"
select NIMBT_ROLE_PERIPHERAL
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_SAMPLE_PER_HR
bool "BLE peripheral heartrate sensor"
select NIMBT_ROLE_PERIPHERAL
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_SAMPLE_BLECSC
bool "BLE peripheral cycling speed and cadence sensor"
select NIMBT_ROLE_PERIPHERAL
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_SAMPLE_BLEUART
bool "BLE uart sample"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_SAMPLE_BTSHELL
bool "BLE Shell sample exposing the nimble GAP and GATT"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_SAMPLE_PERIPHERAL
bool "BLE peripheral role sample"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_SAMPLE_CENTRAL
bool "BLE central role sample"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_SAMPLE_BEACON
bool "BLE beacon sample"
select NIMBT_ROLE_BROADCASTER
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_SAMPLE_ADVERTISER
bool "BLE advertiser sample"
select NIMBT_ROLE_BROADCASTER
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_SAMPLE_EXT_ADVERTISER
bool "BLE external advertiser sample"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_SAMPLE_BLEMESH
bool "BLE Mesh sample"
select LPKG_NIMBLE_MESH
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
endchoice
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_MAX_CONNECTIONS
int "Maximum number of concurrent connections"
range 1 32
default 1
help
Maximum number of concurrent Bluetooth connections supported.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_WHITELIST
bool "Device Whitelist Support"
default y
help
Enables the BLE whitelist for controlling who to connect to
oraccept a connection from.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_MULTI_ADV_INSTANCES
int "The number of multi-advertising instances"
default 0
depends on LPKG_NIMBLE_ROLE_BROADCASTER
help
This is the number of multi-advertising instances. This is NOT
the total number of advertising instances. The total number of
advertising instances is this number plus 1.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_EXT_ADV
bool "Extended Advertising Feature Support"
default n
depends on LPKG_NIMBLE_ROLE_BROADCASTER
help
This enables extended advertising feature.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_EXT_ADV_MAX_SIZE
int "The number of multi-advertising instances"
range 31 1650
default 31
depends on LPKG_NIMBLE_EXT_ADV
help
This allows to configure maximum size of advertising data and scan
response data used in LE Advertising Extensions. Valid range 31-1650.
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
choice
prompt "Version"
default LPKG_USING_NIMBLE_V180
help
Select the package version
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_USING_NIMBLE_V180
bool "v1.8.0"
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_USING_NIMBLE_LATEST_VERSION
bool "latest"
endchoice
2025-10-21 13:59:50 +08:00
2025-07-22 11:15:46 +08:00
config LPKG_NIMBLE_VER
string
default "v1.8.0" if LPKG_USING_NIMBLE_V180
default "latest" if LPKG_USING_NIMBLE_LATEST_VERSION
endif