Kconfig.in 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367
  1. choice BT_NIMBLE_MEM_ALLOC_MODE
  2. prompt "Memory allocation strategy"
  3. default BT_NIMBLE_MEM_ALLOC_MODE_INTERNAL
  4. help
  5. Allocation strategy for NimBLE host stack, essentially provides ability to
  6. allocate all required dynamic allocations from,
  7. - Internal DRAM memory only
  8. - External SPIRAM memory only
  9. - Either internal or external memory based on default malloc()
  10. behavior in ESP-IDF
  11. - Internal IRAM memory wherever applicable else internal DRAM
  12. Recommended mode here is always internal, since that is most preferred
  13. from security perspective. But if application requirement does not
  14. allow sufficient free internal memory then alternate mode can be
  15. selected.
  16. config BT_NIMBLE_MEM_ALLOC_MODE_INTERNAL
  17. bool "Internal memory"
  18. config BT_NIMBLE_MEM_ALLOC_MODE_EXTERNAL
  19. bool "External SPIRAM"
  20. depends on ESP32_SPIRAM_SUPPORT
  21. config BT_NIMBLE_MEM_ALLOC_MODE_DEFAULT
  22. bool "Default alloc mode"
  23. config BT_NIMBLE_MEM_ALLOC_MODE_IRAM_8BIT
  24. bool "Internal IRAM"
  25. depends on ESP32_IRAM_AS_8BIT_ACCESSIBLE_MEMORY
  26. help
  27. Allows to use IRAM memory region as 8bit accessible region.
  28. Every unaligned (8bit or 16bit) access will result in an exception
  29. and incur penalty of certain clock cycles per unaligned read/write.
  30. endchoice #BT_NIMBLE_MEM_ALLOC_MODE
  31. config BT_NIMBLE_MAX_CONNECTIONS
  32. int "Maximum number of concurrent connections"
  33. range 1 9
  34. default BTDM_CTRL_BLE_MAX_CONN
  35. depends on BT_NIMBLE_ENABLED
  36. help
  37. Defines maximum number of concurrent BLE connections
  38. config BT_NIMBLE_MAX_BONDS
  39. int "Maximum number of bonds to save across reboots"
  40. default 3
  41. depends on BT_NIMBLE_ENABLED
  42. help
  43. Defines maximum number of bonds to save for peer security and our security
  44. config BT_NIMBLE_MAX_CCCDS
  45. int "Maximum number of CCC descriptors to save across reboots"
  46. default 8
  47. depends on BT_NIMBLE_ENABLED
  48. help
  49. Defines maximum number of CCC descriptors to save
  50. config BT_NIMBLE_L2CAP_COC_MAX_NUM
  51. int "Maximum number of connection oriented channels"
  52. range 0 9
  53. depends on BT_NIMBLE_ENABLED
  54. default 0
  55. help
  56. Defines maximum number of BLE Connection Oriented Channels. When set to (0), BLE COC is not compiled in
  57. choice BT_NIMBLE_PINNED_TO_CORE_CHOICE
  58. prompt "The CPU core on which NimBLE host will run"
  59. depends on BT_NIMBLE_ENABLED && !FREERTOS_UNICORE
  60. help
  61. The CPU core on which NimBLE host will run. You can choose Core 0 or Core 1.
  62. Cannot specify no-affinity
  63. config BT_NIMBLE_PINNED_TO_CORE_0
  64. bool "Core 0 (PRO CPU)"
  65. config BT_NIMBLE_PINNED_TO_CORE_1
  66. bool "Core 1 (APP CPU)"
  67. depends on !FREERTOS_UNICORE
  68. endchoice
  69. config BT_NIMBLE_PINNED_TO_CORE
  70. int
  71. depends on BT_NIMBLE_ENABLED
  72. default 0 if BT_NIMBLE_PINNED_TO_CORE_0
  73. default 1 if BT_NIMBLE_PINNED_TO_CORE_1
  74. default 0
  75. config BT_NIMBLE_TASK_STACK_SIZE
  76. int "NimBLE Host task stack size"
  77. depends on BT_NIMBLE_ENABLED
  78. default 5120 if BLE_MESH
  79. default 4096
  80. help
  81. This configures stack size of NimBLE host task
  82. config BT_NIMBLE_ROLE_CENTRAL
  83. bool "Enable BLE Central role"
  84. depends on BT_NIMBLE_ENABLED
  85. default y
  86. config BT_NIMBLE_ROLE_PERIPHERAL
  87. bool "Enable BLE Peripheral role"
  88. depends on BT_NIMBLE_ENABLED
  89. default y
  90. config BT_NIMBLE_ROLE_BROADCASTER
  91. bool "Enable BLE Broadcaster role"
  92. depends on BT_NIMBLE_ENABLED
  93. default y
  94. config BT_NIMBLE_ROLE_OBSERVER
  95. bool "Enable BLE Observer role"
  96. depends on BT_NIMBLE_ENABLED
  97. default y
  98. config BT_NIMBLE_NVS_PERSIST
  99. bool "Persist the BLE Bonding keys in NVS"
  100. depends on BT_NIMBLE_ENABLED
  101. default y
  102. help
  103. Enable this flag to make bonding persistent across device reboots
  104. config BT_NIMBLE_SM_LEGACY
  105. bool "Security manager legacy pairing"
  106. depends on BT_NIMBLE_ENABLED
  107. default y
  108. help
  109. Enable security manager legacy pairing
  110. config BT_NIMBLE_SM_SC
  111. bool "Security manager secure connections (4.2)"
  112. depends on BT_NIMBLE_ENABLED
  113. default y
  114. help
  115. Enable security manager secure connections
  116. config BT_NIMBLE_DEBUG
  117. bool "Enable extra runtime asserts and host debugging"
  118. default n
  119. depends on BT_NIMBLE_ENABLED
  120. help
  121. This enables extra runtime asserts and host debugging
  122. config BT_NIMBLE_SM_SC_DEBUG_KEYS
  123. bool "Use predefined public-private key pair"
  124. default n
  125. depends on BT_NIMBLE_SM_SC
  126. help
  127. If this option is enabled, SM uses predefined DH key pair as described
  128. in Core Specification, Vol. 3, Part H, 2.3.5.6.1. This allows to
  129. decrypt air traffic easily and thus should only be used for debugging.
  130. config BT_NIMBLE_SVC_GAP_DEVICE_NAME
  131. string "BLE GAP default device name"
  132. depends on BT_NIMBLE_ENABLED
  133. default "nimble"
  134. help
  135. The Device Name characteristic shall contain the name of the device as an UTF-8 string.
  136. This name can be changed by using API ble_svc_gap_device_name_set()
  137. config BT_NIMBLE_GAP_DEVICE_NAME_MAX_LEN
  138. int "Maximum length of BLE device name in octets"
  139. depends on BT_NIMBLE_ENABLED
  140. default 31
  141. help
  142. Device Name characteristic value shall be 0 to 248 octets in length
  143. config BT_NIMBLE_ATT_PREFERRED_MTU
  144. int "Preferred MTU size in octets"
  145. depends on BT_NIMBLE_ENABLED
  146. default 256
  147. help
  148. This is the default value of ATT MTU indicated by the device during an ATT MTU exchange.
  149. This value can be changed using API ble_att_set_preferred_mtu()
  150. config BT_NIMBLE_SVC_GAP_APPEARANCE
  151. hex "External appearance of the device"
  152. depends on BT_NIMBLE_ENABLED
  153. default 0
  154. help
  155. Standard BLE GAP Appearance value in HEX format e.g. 0x02C0
  156. config BT_NIMBLE_ACL_BUF_COUNT
  157. int "ACL Buffer count"
  158. depends on BT_NIMBLE_ENABLED
  159. default 12
  160. help
  161. The number of ACL data buffers.
  162. config BT_NIMBLE_ACL_BUF_SIZE
  163. int "ACL Buffer size"
  164. depends on BT_NIMBLE_ENABLED
  165. default 255
  166. help
  167. This is the maximum size of the data portion of HCI ACL data packets.
  168. It does not include the HCI data header (of 4 bytes)
  169. config BT_NIMBLE_HCI_EVT_BUF_SIZE
  170. int "HCI Event Buffer size"
  171. depends on BT_NIMBLE_ENABLED
  172. default 70
  173. help
  174. This is the size of each HCI event buffer in bytes
  175. config BT_NIMBLE_HCI_EVT_HI_BUF_COUNT
  176. int "High Priority HCI Event Buffer count"
  177. depends on BT_NIMBLE_ENABLED
  178. default 30
  179. help
  180. This is the high priority HCI events' buffer size. High-priority
  181. event buffers are for everything except advertising reports. If there
  182. are no free high-priority event buffers then host will try to allocate a
  183. low-priority buffer instead
  184. config BT_NIMBLE_HCI_EVT_LO_BUF_COUNT
  185. int "Low Priority HCI Event Buffer count"
  186. depends on BT_NIMBLE_ENABLED
  187. default 8
  188. help
  189. This is the low priority HCI events' buffer size. Low-priority event
  190. buffers are only used for advertising reports. If there are no free
  191. low-priority event buffers, then an incoming advertising report will
  192. get dropped
  193. config BT_NIMBLE_MSYS1_BLOCK_COUNT
  194. int "MSYS_1 Block Count"
  195. depends on BT_NIMBLE_ENABLED
  196. default 12
  197. help
  198. MSYS is a system level mbuf registry. For prepare write & prepare
  199. responses MBUFs are allocated out of msys_1 pool. For NIMBLE_MESH
  200. enabled cases, this block count is increased by 8 than user defined
  201. count.
  202. config BT_NIMBLE_HS_FLOW_CTRL
  203. bool "Enable Host Flow control"
  204. depends on BT_NIMBLE_ENABLED
  205. default y
  206. help
  207. Enable Host Flow control
  208. config BT_NIMBLE_HS_FLOW_CTRL_ITVL
  209. int "Host Flow control interval"
  210. depends on BT_NIMBLE_HS_FLOW_CTRL
  211. default 1000
  212. help
  213. Host flow control interval in msecs
  214. config BT_NIMBLE_HS_FLOW_CTRL_THRESH
  215. int "Host Flow control threshold"
  216. depends on BT_NIMBLE_HS_FLOW_CTRL
  217. default 2
  218. help
  219. Host flow control threshold, if the number of free buffers are at or
  220. below this threshold, send an immediate number-of-completed-packets
  221. event
  222. config BT_NIMBLE_HS_FLOW_CTRL_TX_ON_DISCONNECT
  223. bool "Host Flow control on disconnect"
  224. depends on BT_NIMBLE_HS_FLOW_CTRL
  225. default y
  226. help
  227. Enable this option to send number-of-completed-packets event to
  228. controller after disconnection
  229. config BT_NIMBLE_RPA_TIMEOUT
  230. int "RPA timeout in seconds"
  231. range 1 41400
  232. depends on BT_NIMBLE_ENABLED
  233. default 900
  234. help
  235. Time interval between RPA address change. This is applicable in case of
  236. Host based RPA
  237. menuconfig BT_NIMBLE_MESH
  238. bool "Enable BLE mesh functionality"
  239. select BT_NIMBLE_SM_SC
  240. depends on BT_NIMBLE_ENABLED
  241. default n
  242. help
  243. Enable BLE Mesh functionality
  244. config BT_NIMBLE_MESH_PROXY
  245. bool "Enable mesh proxy functionality"
  246. default n
  247. depends on BT_NIMBLE_MESH
  248. help
  249. Enable proxy. This is automatically set whenever NIMBLE_MESH_PB_GATT or
  250. NIMBLE_MESH_GATT_PROXY is set
  251. config BT_NIMBLE_MESH_PROV
  252. bool "Enable BLE mesh provisioning"
  253. default y
  254. depends on BT_NIMBLE_MESH
  255. help
  256. Enable mesh provisioning
  257. config BT_NIMBLE_MESH_PB_ADV
  258. bool "Enable mesh provisioning over advertising bearer"
  259. default y
  260. depends on BT_NIMBLE_MESH_PROV
  261. help
  262. Enable this option to allow the device to be provisioned over
  263. the advertising bearer
  264. config BT_NIMBLE_MESH_PB_GATT
  265. bool "Enable mesh provisioning over GATT bearer"
  266. default y
  267. select BT_NIMBLE_MESH_PROXY
  268. depends on BT_NIMBLE_MESH_PROV
  269. help
  270. Enable this option to allow the device to be provisioned over the GATT
  271. bearer
  272. config BT_NIMBLE_MESH_GATT_PROXY
  273. bool "Enable GATT Proxy functionality"
  274. default y
  275. select BT_NIMBLE_MESH_PROXY
  276. depends on BT_NIMBLE_MESH
  277. help
  278. This option enables support for the Mesh GATT Proxy Service,
  279. i.e. the ability to act as a proxy between a Mesh GATT Client
  280. and a Mesh network
  281. config BT_NIMBLE_MESH_RELAY
  282. bool "Enable mesh relay functionality"
  283. default n
  284. depends on BT_NIMBLE_MESH
  285. help
  286. Support for acting as a Mesh Relay Node
  287. config BT_NIMBLE_MESH_LOW_POWER
  288. bool "Enable mesh low power mode"
  289. default n
  290. depends on BT_NIMBLE_MESH
  291. help
  292. Enable this option to be able to act as a Low Power Node
  293. config BT_NIMBLE_MESH_FRIEND
  294. bool "Enable mesh friend functionality"
  295. default n
  296. depends on BT_NIMBLE_MESH
  297. help
  298. Enable this option to be able to act as a Friend Node
  299. config BT_NIMBLE_MESH_DEVICE_NAME
  300. string "Set mesh device name"
  301. default "nimble-mesh-node"
  302. depends on BT_NIMBLE_MESH
  303. help
  304. This value defines Bluetooth Mesh device/node name
  305. config BT_NIMBLE_CRYPTO_STACK_MBEDTLS
  306. bool "Override TinyCrypt with mbedTLS for crypto computations"
  307. default y
  308. depends on BT_NIMBLE_ENABLED
  309. select MBEDTLS_ECP_RESTARTABLE
  310. select MBEDTLS_CMAC_C
  311. help
  312. Enable this option to choose mbedTLS instead of TinyCrypt for crypto
  313. computations.