1# Bluetooth Classic configuration options
2
3# Copyright (c) 2016-2020 Nordic Semiconductor ASA
4# Copyright (c) 2015-2016 Intel Corporation
5# SPDX-License-Identifier: Apache-2.0
6
7menu "Bluetooth Classic Options"
8
9config BT_CLASSIC
10	bool "Bluetooth BR/EDR support [EXPERIMENTAL]"
11	depends on BT_HCI_HOST
12	select BT_PERIPHERAL
13	select BT_CENTRAL
14	select BT_SMP
15	select BT_L2CAP_DYNAMIC_CHANNEL
16	select CRC
17	select EXPERIMENTAL
18	help
19	  This option enables Bluetooth BR/EDR support
20
21if BT_CLASSIC
22config BT_LIMITED_DISCOVERABLE_DURATION
23	int "Maximum duration that a device is in limited discoverable mode in seconds"
24	default 60
25	range 31 60
26	help
27	  This option sets the maximum duration that a device is in limited discoverable mode in
28	  seconds.
29
30config BT_BR_MIN_ENC_KEY_SIZE
31	int
32	prompt "Minimum encryption key size accepted in octets" if !BT_SMP_SC_ONLY
33	default BT_SMP_MIN_ENC_KEY_SIZE
34	range 7 16
35	help
36	  This option sets the minimum encryption key size accepted during pairing
37	  for classic.
38
39config BT_MAX_SCO_CONN
40	int "Maximum number of simultaneous SCO connections"
41	default 1
42	range 1 3
43	help
44	  Maximum number of simultaneous Bluetooth synchronous connections
45	  supported. The minimum (and default) number is 1.
46
47config BT_L2CAP_CONNLESS
48	bool "Bluetooth L2CAP connectionless data reception [EXPERIMENTAL]"
49	select EXPERIMENTAL
50	help
51	  This option enables Bluetooth L2CAP connectionless data reception
52
53config BT_L2CAP_RET
54	bool "Bluetooth L2CAP retransmission mode [EXPERIMENTAL]"
55	select EXPERIMENTAL
56	help
57	  This option enables Bluetooth L2CAP retransmission mode
58
59config BT_L2CAP_FC
60	bool "Bluetooth L2CAP flow control mode [EXPERIMENTAL]"
61	select EXPERIMENTAL
62	help
63	  This option enables Bluetooth L2CAP flow control mode
64
65config BT_L2CAP_ENH_RET
66	bool "Bluetooth L2CAP enhance retransmission [EXPERIMENTAL]"
67	select EXPERIMENTAL
68	help
69	  This option enables Bluetooth L2CAP enhance retransmission
70
71config BT_L2CAP_STREAM
72	bool "Bluetooth L2CAP streaming mode [EXPERIMENTAL]"
73	select EXPERIMENTAL
74	help
75	  This option enables Bluetooth L2CAP streaming mode
76
77config BT_L2CAP_RET_FC
78	def_bool BT_L2CAP_RET || BT_L2CAP_FC || BT_L2CAP_ENH_RET || BT_L2CAP_STREAM
79
80if BT_L2CAP_RET_FC
81config BT_L2CAP_FCS
82	bool "Bluetooth L2CAP FCS Option [EXPERIMENTAL]"
83	select EXPERIMENTAL
84	depends on BT_L2CAP_STREAM || BT_L2CAP_ENH_RET
85	help
86	  This option enables Bluetooth L2CAP FCS Option
87
88config BT_L2CAP_EXT_WIN_SIZE
89	bool "Bluetooth L2CAP Extended window size Option [EXPERIMENTAL]"
90	select EXPERIMENTAL
91	depends on BT_L2CAP_STREAM || BT_L2CAP_ENH_RET
92	help
93	  This option enables Bluetooth L2CAP Extended window size Option
94
95config BT_L2CAP_MPS
96	int "Bluetooth L2CAP MPS for retransmission and Flow control"
97	default 48
98	range 48 BT_L2CAP_TX_MTU
99	help
100	  Bluetooth L2CAP MPS for retransmission and Flow control
101
102config BT_L2CAP_MAX_WINDOW_SIZE
103	int "Maximum Windows Size of Retransmission and Flow Control"
104	default 1
105	range 1 32
106	help
107	  Maximum Windows Size of Retransmission and Flow Control.
108	  The minimum (and default) number is 1.
109
110config BT_L2CAP_BR_RET_TIMEOUT
111	int "Retransmission timeout (milliseconds)"
112	default 2000
113	range 1000 2000
114	help
115	  The Retransmission timeout shall be three times the value of flush timeout,
116	  subject to a minimum of 1000 milliseconds and maximum of 2000 milliseconds.
117
118config BT_L2CAP_BR_MONITOR_TIMEOUT
119	int "Monitor timeout (milliseconds)"
120	default 12000 if BT_L2CAP_ENH_RET
121	default BT_L2CAP_BR_RET_TIMEOUT
122	range BT_L2CAP_BR_RET_TIMEOUT 12000
123	help
124	  If a flush timeout exists on the link for Enhanced Retransmission mode and
125	  both sides of the link are configured to the same flush timeout value then the
126	  monitor timeout shall be set to a value at least as large as the Retransmission
127	  timeout otherwise the value of the Monitor timeout shall be six times the value
128	  of flush timeout, subject to a minimum of the retransmission timeout value and
129	  a maximum of 12000 milliseconds.
130endif # BT_L2CAP_RET_FC
131
132config BT_RFCOMM
133	bool "Bluetooth RFCOMM protocol support [EXPERIMENTAL]"
134	select EXPERIMENTAL
135	help
136	  This option enables Bluetooth RFCOMM support
137
138config BT_RFCOMM_L2CAP_MTU
139	int "L2CAP MTU for RFCOMM frames"
140	depends on BT_RFCOMM
141	default BT_BUF_ACL_RX_SIZE
142	range 23 $(INT16_MAX)
143	help
144	  Maximum size of L2CAP PDU for RFCOMM frames.
145	  RX MTU will be truncated to account for the L2CAP PDU header.
146
147config BT_RFCOMM_TX_MAX
148	int "Maximum number of pending TX buffers for RFCOMM"
149	default BT_BUF_ACL_TX_COUNT
150	range BT_BUF_ACL_TX_COUNT $(UINT8_MAX)
151	help
152	  Maximum number of pending TX buffers that have an associated
153	  sending buf. Normally this can be left to the default value, which
154	  is equal to the number of session in the stack-internal pool.
155
156config BT_HFP_HF
157	bool "Bluetooth Handsfree profile HF Role support [EXPERIMENTAL]"
158	depends on PRINTK
159	select BT_RFCOMM
160	select EXPERIMENTAL
161	help
162	  This option enables Bluetooth HF support
163
164config BT_HFP_AG
165	bool "Bluetooth Handsfree profile AG Role support [EXPERIMENTAL]"
166	depends on PRINTK
167	select BT_RFCOMM
168	select EXPERIMENTAL
169	help
170	  This option enables Bluetooth AG support
171
172if BT_HFP_HF
173config BT_HFP_HF_CLI
174	bool "CLI presentation capability for HFP HF [EXPERIMENTAL]"
175	default y
176	help
177	  This option enables CLI presentation capability for HFP HF
178
179config BT_HFP_HF_VOLUME
180	bool "Remote audio volume control for HFP HF [EXPERIMENTAL]"
181	default y
182	help
183	  This option enables Remote audio volume control for HFP HF
184
185config BT_HFP_HF_CODEC_NEG
186	bool "Codec Negotiation for HFP HF [EXPERIMENTAL]"
187	help
188	  This option enables Codec Negotiation for HFP HF
189
190config BT_HFP_HF_ECNR
191	bool "EC and/or NR function for HFP HF [EXPERIMENTAL]"
192	help
193	  This option enables EC and/or NR function for HFP HF
194
195if BT_HFP_HF_CODEC_NEG
196config BT_HFP_HF_CODEC_MSBC
197	bool "Support Codec mSBC for HFP HF [EXPERIMENTAL]"
198	help
199	  This option enables Codec mSBC for HFP HF
200
201config BT_HFP_HF_CODEC_LC3_SWB
202	bool "Support Codec LC3 SWB for HFP HF [EXPERIMENTAL]"
203	help
204	  This option enables Codec LC3 SWB for HFP HF
205endif # BT_HFP_HF_CODEC_NEG
206
207config BT_HFP_HF_3WAY_CALL
208	bool "Three-way calling for HFP HF [EXPERIMENTAL]"
209	help
210	  This option enables Three-way calling for HFP HF
211
212config BT_HFP_HF_ECS
213	bool "Enhanced Call Status for HFP HF [EXPERIMENTAL]"
214	default y if BT_HFP_HF_3WAY_CALL
215	help
216	  This option enables Enhanced Call Status for HFP HF
217
218config BT_HFP_HF_ECC
219	bool "Enhanced Call Control for HFP HF [EXPERIMENTAL]"
220	default y if BT_HFP_HF_3WAY_CALL
221	help
222	  This option enables Enhanced Call Control for HFP HF
223
224config BT_HFP_HF_MAX_CALLS
225	int "Maximum supported calls for HFP HF [EXPERIMENTAL]"
226	default 2 if BT_HFP_HF_3WAY_CALL
227	default 1
228	range 1 2
229	help
230	  This option sets maximum supported calls for HFP HF
231
232config BT_HFP_HF_VOICE_RECG
233	bool "Voice recognition activation for HFP HF [EXPERIMENTAL]"
234	help
235	  This option enables Voice recognition activation for HFP HF
236
237config BT_HFP_HF_ENH_VOICE_RECG
238	bool "Enhanced Voice Recognition Status for HFP HF [EXPERIMENTAL]"
239	select BT_HFP_HF_VOICE_RECG
240	help
241	  This option enables Enhanced Voice Recognition Status for HFP HF
242
243config BT_HFP_HF_VOICE_RECG_TEXT
244	bool "Voice Recognition Text for HFP HF [EXPERIMENTAL]"
245	select BT_HFP_HF_ENH_VOICE_RECG
246	help
247	  This option enables Voice Recognition Text for HFP HF
248
249config BT_HFP_HF_HF_INDICATORS
250	bool "HF Indicators for HFP HF [EXPERIMENTAL]"
251	help
252	  This option enables HF Indicators for HFP HF
253
254config BT_HFP_HF_HF_INDICATOR_ENH_SAFETY
255	bool "HF Indicator Enhanced Safety for HFP HF [EXPERIMENTAL]"
256	select BT_HFP_HF_HF_INDICATORS
257	help
258	  This option enables HF Indicator Enhanced Safety for HFP HF
259
260config BT_HFP_HF_HF_INDICATOR_BATTERY
261	bool "HF Indicator Battery level for HFP HF [EXPERIMENTAL]"
262	select BT_HFP_HF_HF_INDICATORS
263	help
264	  This option enables HF Indicator Battery level for HFP HF
265
266endif # BT_HFP_HF
267
268if BT_HFP_AG
269config BT_HFP_AG_EXT_ERR
270	bool "Extended Error Result Codes for HFP AG [EXPERIMENTAL]"
271	default y
272	help
273	  This option enables Extended Error Result Codes for HFP AG
274
275config BT_HFP_AG_CODEC_NEG
276	bool "Codec Negotiation for HFP AG [EXPERIMENTAL]"
277	help
278	  This option enables Codec Negotiation for HFP AG
279
280config BT_HFP_AG_ECNR
281	bool "EC and/or NR function for HFP AG [EXPERIMENTAL]"
282	help
283	  This option enables EC and/or NR function for HFP AG
284
285config BT_HFP_AG_3WAY_CALL
286	bool "Three-way calling for HFP AG [EXPERIMENTAL]"
287	help
288	  This option enables Three-way calling for HFP AG
289
290config BT_HFP_AG_MAX_CALLS
291	int "Maximum supported calls for HFP AG [EXPERIMENTAL]"
292	default 2 if BT_HFP_AG_3WAY_CALL
293	default 1
294	range 1 2
295	help
296	  This option sets maximum supported calls for HFP AG
297
298config BT_HFP_AG_ECS
299	bool "Enhanced call status for HFP AG [EXPERIMENTAL]"
300	default y if BT_HFP_AG_3WAY_CALL
301	help
302	  This option enables Enhanced call status for HFP AG
303
304config BT_HFP_AG_ECC
305	bool "Enhanced call control for HFP AG [EXPERIMENTAL]"
306	default y if BT_HFP_AG_3WAY_CALL
307	help
308	  This option enables Enhanced call control for HFP AG
309
310config BT_HFP_AG_TX_BUF_COUNT
311	int "Maximum number of TX buffers for HFP AG [EXPERIMENTAL]"
312	default BT_RFCOMM_TX_MAX
313	range BT_RFCOMM_TX_MAX $(UINT8_MAX)
314	help
315	  Maximum number of pending TX buffers that have an associated
316	  sending buf. Normally this can be left to the default value, which
317	  is equal to the number of session in the stack-internal pool.
318
319config BT_HFP_AG_THREAD_STACK_SIZE
320	int "Size of the HFP AG thread stack [EXPERIMENTAL]"
321	default 1024
322	help
323	  Stack size needed for executing thread for HFP AG.
324
325config BT_HFP_AG_THREAD_PRIO
326	# Hidden option for HFP AG thread priority
327	int
328	default 6
329
330config BT_HFP_AG_OUTGOING_TIMEOUT
331	int "Call outgoing timeout value for HFP AG [EXPERIMENTAL]"
332	default 3
333	range 1 10
334	help
335	  The option sets the timeout of call outgoing. If the call does
336	  not switch to alerting state before timeout, it will be
337	  stopped by the HFP AG. The unit is seconds.
338
339config BT_HFP_AG_INCOMING_TIMEOUT
340	int "Incoming call timeout value for HFP AG [EXPERIMENTAL]"
341	default 3
342	range 1 10
343	help
344	  The option sets the timeout of incoming call. If the call does
345	  not switch to ringing state before timeout, it will be
346	  stopped by the HFP AG. The unit is seconds.
347
348config BT_HFP_AG_ALERTING_TIMEOUT
349	int "Call alerting/ringing timeout value for HFP AG [EXPERIMENTAL]"
350	default 60
351	range 10 60
352	help
353	  The option sets the timeout of call alerting/ringing. If the
354	  call is not active before timeout, it will be stopped
355	  by the HFP AG. The unit is seconds.
356
357config BT_HFP_AG_PHONE_NUMBER_MAX_LEN
358	int "Supported max length of phone number for HFP AG [EXPERIMENTAL]"
359	default 32
360	range 1 $(UINT8_MAX)
361	help
362	  Supported max length of phone number for HFP AG.
363
364config BT_HFP_AG_RING_NOTIFY_INTERVAL
365	int "Ring notification interval [EXPERIMENTAL]"
366	default 3
367	help
368	  Ring notification interval if the call is in alert state.
369	  The unit is seconds.
370
371config BT_HFP_AG_VOICE_RECG
372	bool "Voice recognition activation for HFP AG [EXPERIMENTAL]"
373	help
374	  This option enables Voice recognition activation for HFP AG
375
376config BT_HFP_AG_ENH_VOICE_RECG
377	bool "Enhanced Voice Recognition Status for HFP AG [EXPERIMENTAL]"
378	select BT_HFP_AG_VOICE_RECG
379	help
380	  This option enables Enhanced Voice Recognition Status for HFP AG
381
382config BT_HFP_AG_VOICE_RECG_TEXT
383	bool "Voice Recognition Text for HFP AG [EXPERIMENTAL]"
384	select BT_HFP_AG_ENH_VOICE_RECG
385	help
386	  This option enables Voice Recognition Text for HFP AG
387
388config BT_HFP_AG_VOICE_TAG
389	bool "Attach a phone number for a voice tag for HFP AG [EXPERIMENTAL]"
390	select BT_HFP_AG_VOICE_RECG
391	help
392	  This option enables Attach a phone number for a voice tag for HFP AG
393
394config BT_HFP_AG_HF_INDICATORS
395	bool "HF Indicators for HFP AG [EXPERIMENTAL]"
396	help
397	  This option enables HF Indicators for HFP AG
398
399config BT_HFP_AG_HF_INDICATOR_ENH_SAFETY
400	bool "HF Indicator Enhanced Safety for HFP AG [EXPERIMENTAL]"
401	select BT_HFP_AG_HF_INDICATORS
402	help
403	  This option enables HF Indicator Enhanced Safety for HFP AG
404
405config BT_HFP_AG_HF_INDICATOR_BATTERY
406	bool "HF Indicator Battery level for HFP AG [EXPERIMENTAL]"
407	select BT_HFP_AG_HF_INDICATORS
408	help
409	  This option enables HF Indicator Battery level for HFP AG
410
411config BT_HFP_AG_REJECT_CALL
412	bool "Ability to reject a call for HFP AG [EXPERIMENTAL]"
413	default y
414	help
415	  This option enables ability to reject a call for HFP AG
416
417config BT_HFP_AG_GET_ONGOING_CALL_TIMEOUT
418	int "Timeout after the get ongoing calls callback notified (milliseconds) [EXPERIMENTAL]"
419	default 10000
420	range 1000 10000
421	help
422	  This option sets the timeout after the get ongoing calls callback notified
423
424endif # BT_HFP_AG
425
426config BT_AVDTP
427	bool "Bluetooth AVDTP protocol support [EXPERIMENTAL]"
428	select EXPERIMENTAL
429	help
430	  This option enables Bluetooth AVDTP support
431
432config BT_A2DP
433	bool "Bluetooth A2DP Profile [EXPERIMENTAL]"
434	select BT_AVDTP
435	select EXPERIMENTAL
436	help
437	  This option enables the A2DP profile
438
439if BT_AVDTP
440
441config BT_AVDTP_RTP_VERSION
442	int "Bluetooth AVDTP RTP version"
443	default 2
444	help
445	  This option sets the AVDTP RTP protocol version
446
447endif # BT_AVDTP
448
449if BT_A2DP
450
451config BT_A2DP_SOURCE
452	bool "Bluetooth A2DP Profile Source Function"
453	help
454	  This option enables the A2DP profile source function
455
456config BT_A2DP_SINK
457	bool "Bluetooth A2DP Profile Sink Function"
458	help
459	  This option enables the A2DP profile sink function
460
461endif # BT_A2DP
462
463config BT_AVCTP
464	bool "Bluetooth AVCTP protocol support [EXPERIMENTAL]"
465	select EXPERIMENTAL
466	help
467	  This option enables Bluetooth AVCTP support
468
469config BT_AVRCP
470	bool "Bluetooth AVRCP Profile [EXPERIMENTAL]"
471	select BT_AVCTP
472	select EXPERIMENTAL
473	help
474	  This option enables the AVRCP profile
475
476if BT_AVRCP
477
478config BT_AVRCP_TARGET
479	bool "Bluetooth AVRCP Profile Target Function"
480	help
481	  This option enables the AVRCP profile target function
482
483config BT_AVRCP_CONTROLLER
484	bool "Bluetooth AVRCP Profile Controller Function"
485	help
486	  This option enables the AVRCP profile controller function
487
488endif # BT_AVRCP
489
490config BT_PAGE_TIMEOUT
491	hex "Bluetooth Page Timeout"
492	default 0x2000
493	range 0x0001 0xffff
494	help
495	  This option sets the page timeout value. Value is selected as
496	  (N * 0.625) ms.
497
498config BT_COD
499	hex "Bluetooth Class of Device(CoD)"
500	default 0
501	help
502	  This option sets the class of device.For the list of possible values please
503	  consult the following link:
504	  https://www.bluetooth.com/specifications/assigned-numbers
505
506config BT_DEFAULT_ROLE_SWITCH_ENABLE
507	bool "Default Bluetooth Role Switch Enable/Disable State"
508	help
509	  This option sets the controller's default link policy to
510	  enable/disable the role switch.
511
512config BT_GOEP
513	bool "Bluetooth GOEP Profile [EXPERIMENTAL]"
514	select BT_RFCOMM
515	select BT_L2CAP_ENH_RET
516	select EXPERIMENTAL
517	help
518	  This option enables the GOEP profile
519
520if BT_GOEP
521config BT_GOEP_RFCOMM_MTU
522	int "RFCOMM MTU for GOEP"
523	default BT_RFCOMM_L2CAP_MTU
524	# For GOEP over RFCOMM, including,
525	# 255 bytes - the minimum MTU of GOEP,
526	# 4 bytes - L2CAP Header,
527	# 5 bytes - 4 bytes for RFCOMM header with extended length, 1 byte for FCS.
528	range 264 BT_RFCOMM_L2CAP_MTU
529	help
530	  Maximum size of RFCOMM MTU for GOEP.
531	  RX MTU will be truncated to account for ACL data and type overhead, the L2CAP PDU header,
532	  and the RFCOMM header.
533
534config BT_GOEP_L2CAP_MTU
535	int "L2CAP MTU for GOEP"
536	default BT_BUF_ACL_RX_SIZE
537	# For GOEP over L2CAP, including,
538	# 255 bytes - the minimum MTU of GOEP,
539	# 4 bytes - L2CAP Header,
540	range 259 BT_BUF_ACL_RX_SIZE
541	help
542	  Maximum size of L2CAP MTU for GOEP.
543	  RX MTU will be truncated to account for ACL data and type overhead, and the L2CAP PDU
544	  header.
545
546config BT_OEBX_RSP_CODE_TO_STR
547	bool "Print OBEX response code as strings"
548	help
549	  This configuration enables printing of OBEX response
550	  codes represented as strings.
551	  See bt_obex_rsp_code_to_str() for more details.
552
553endif # BT_GOEP
554
555endif # BT_CLASSIC
556
557endmenu
558