1 /****************************************************************************** 2 * 3 * Copyright (C) 1999-2012 Broadcom Corporation 4 * 5 * Licensed under the Apache License, Version 2.0 (the "License"); 6 * you may not use this file except in compliance with the License. 7 * You may obtain a copy of the License at: 8 * 9 * http://www.apache.org/licenses/LICENSE-2.0 10 * 11 * Unless required by applicable law or agreed to in writing, software 12 * distributed under the License is distributed on an "AS IS" BASIS, 13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 * See the License for the specific language governing permissions and 15 * limitations under the License. 16 * 17 ******************************************************************************/ 18 19 #ifndef BT_TARGET_H 20 #define BT_TARGET_H 21 22 #ifndef BUILDCFG 23 #define BUILDCFG 24 #endif 25 #include "data_types.h" 26 27 28 #ifndef BTIF_HSAG_SERVICE_NAME 29 #define BTIF_HSAG_SERVICE_NAME ("Headset Gateway") 30 #endif 31 32 #ifndef BTIF_HFAG_SERVICE_NAME 33 #define BTIF_HFAG_SERVICE_NAME ("Handsfree Gateway") 34 #endif 35 36 37 #ifdef BUILDCFG 38 39 #if !defined(HAS_BDROID_BUILDCFG) && !defined(HAS_NO_BDROID_BUILDCFG) 40 #error "An Android.mk file did not include bdroid_CFLAGS and possibly not bdorid_C_INCLUDES" 41 #endif 42 43 #ifdef HAS_BDROID_BUILDCFG 44 #include "bdroid_buildcfg.h" 45 #endif 46 47 #endif 48 49 /* Include common GKI definitions used by this platform */ 50 #include "gki_target.h" 51 52 #include "bt_types.h" /* This must be defined AFTER buildcfg.h */ 53 #include "dyn_mem.h" /* defines static and/or dynamic memory for components */ 54 55 56 //------------------Added from Bluedroid buildcfg.h--------------------- 57 #ifndef UNV_INCLUDED 58 #define UNV_INCLUDED FALSE 59 #endif 60 61 #ifndef GATT_PTS 62 #define GATT_PTS FALSE 63 #endif 64 65 #ifndef L2CAP_INCLUDED 66 #define L2CAP_INCLUDED TRUE 67 #endif 68 69 #ifndef L2CAP_EXTFEA_SUPPORTED_MASK 70 #define L2CAP_EXTFEA_SUPPORTED_MASK (L2CAP_EXTFEA_ENH_RETRANS | L2CAP_EXTFEA_STREAM_MODE | L2CAP_EXTFEA_NO_CRC | L2CAP_EXTFEA_FIXED_CHNLS) 71 #endif 72 73 #ifndef BTUI_OPS_FORMATS 74 #define BTUI_OPS_FORMATS (BTA_OP_VCARD21_MASK | BTA_OP_ANY_MASK) 75 #endif 76 77 #ifndef BTA_RFC_MTU_SIZE 78 #define BTA_RFC_MTU_SIZE (L2CAP_MTU_SIZE-L2CAP_MIN_OFFSET-RFCOMM_DATA_OVERHEAD) 79 #endif 80 81 #ifndef BTA_DUN_MTU 82 #define BTA_DUN_MTU BTA_RFC_MTU_SIZE 83 #endif 84 85 #ifndef BTA_SPP_MTU 86 #define BTA_SPP_MTU BTA_RFC_MTU_SIZE 87 #endif 88 89 #ifndef BTA_FAX_MTU 90 #define BTA_FAX_MTU BTA_RFC_MTU_SIZE 91 #endif 92 93 #ifndef SDP_RAW_PDU_INCLUDED 94 #define SDP_RAW_PDU_INCLUDED TRUE 95 #endif 96 97 #ifndef GATTS_APPU_USE_GATT_TRACE 98 #define GATTS_APPU_USE_GATT_TRACE FALSE 99 #endif 100 101 #ifndef SMP_HOST_ENCRYPT_INCLUDED 102 #define SMP_HOST_ENCRYPT_INCLUDED FALSE 103 #endif 104 105 #ifndef SAP_INCLUDED 106 #define SAP_INCLUDED FALSE 107 #endif 108 109 #ifndef SBC_NO_PCM_CPY_OPTION 110 #define SBC_NO_PCM_CPY_OPTION FALSE 111 #endif 112 113 #ifndef BTA_INCLUDED 114 #define BTA_INCLUDED TRUE 115 #endif 116 117 #ifndef BTA_AG_INCLUDED 118 #define BTA_AG_INCLUDED TRUE 119 #endif 120 121 #ifndef BTA_CT_INCLUDED 122 #define BTA_CT_INCLUDED FALSE 123 #endif 124 125 #ifndef BTA_CG_INCLUDED 126 #define BTA_CG_INCLUDED FALSE 127 #endif 128 129 #ifndef BTA_DG_INCLUDED 130 #define BTA_DG_INCLUDED FALSE 131 #endif 132 133 #ifndef BTA_FT_INCLUDED 134 #define BTA_FT_INCLUDED FALSE 135 #endif 136 137 #ifndef BTA_OP_INCLUDED 138 #define BTA_OP_INCLUDED FALSE 139 #endif 140 141 #ifndef BTA_PR_INCLUDED 142 #define BTA_PR_INCLUDED FALSE 143 #endif 144 145 #ifndef BTA_SS_INCLUDED 146 #define BTA_SS_INCLUDED FALSE 147 #endif 148 149 #ifndef BTA_DM_INCLUDED 150 #define BTA_DM_INCLUDED TRUE 151 #endif 152 153 154 #ifndef BTA_DI_INCLUDED 155 #define BTA_DI_INCLUDED FALSE 156 #endif 157 158 #ifndef BTA_BI_INCLUDED 159 #define BTA_BI_INCLUDED FALSE 160 #endif 161 162 #ifndef BTA_SC_INCLUDED 163 #define BTA_SC_INCLUDED FALSE 164 #endif 165 166 #ifndef BTA_PAN_INCLUDED 167 #define BTA_PAN_INCLUDED TRUE 168 #endif 169 170 #ifndef BTA_FS_INCLUDED 171 #define BTA_FS_INCLUDED TRUE 172 #endif 173 174 #ifndef BTA_AC_INCLUDED 175 #define BTA_AC_INCLUDED FALSE 176 #endif 177 178 #ifndef BTA_HD_INCLUDED 179 #define BTA_HD_INCLUDED FALSE 180 #endif 181 182 #ifndef BTA_HH_INCLUDED 183 #define BTA_HH_INCLUDED TRUE 184 #endif 185 186 #ifndef BTA_HH_ROLE 187 #define BTA_HH_ROLE BTA_MASTER_ROLE_PREF 188 #endif 189 190 #ifndef BTA_AR_INCLUDED 191 #define BTA_AR_INCLUDED TRUE 192 #endif 193 194 #ifndef BTA_AV_INCLUDED 195 #define BTA_AV_INCLUDED TRUE 196 #endif 197 198 #ifndef BTA_AV_VDP_INCLUDED 199 #define BTA_AV_VDP_INCLUDED FALSE 200 #endif 201 202 #ifndef BTA_AVK_INCLUDED 203 #define BTA_AVK_INCLUDED FALSE 204 #endif 205 206 #ifndef BTA_PBS_INCLUDED 207 #define BTA_PBS_INCLUDED FALSE 208 #endif 209 210 #ifndef BTA_PBC_INCLUDED 211 #define BTA_PBC_INCLUDED FALSE 212 #endif 213 214 #ifndef BTA_FM_INCLUDED 215 #define BTA_FM_INCLUDED FALSE 216 #endif 217 218 #ifndef BTA_FM_DEBUG 219 #define BTA_FM_DEBUG FALSE 220 #endif 221 222 #ifndef BTA_FMTX_INCLUDED 223 #define BTA_FMTX_INCLUDED FALSE 224 #endif 225 226 #ifndef BTA_FMTX_DEBUG 227 #define BTA_FMTX_DEBUG FALSE 228 #endif 229 230 #ifndef BTA_FMTX_FMRX_SWITCH_WORKAROUND 231 #define BTA_FMTX_FMRX_SWITCH_WORKAROUND FALSE 232 #endif 233 234 #ifndef BTA_FMTX_US_FCC_RULES 235 #define BTA_FMTX_US_FCC_RULES FALSE 236 #endif 237 238 #ifndef BTA_HS_INCLUDED 239 #define BTA_HS_INCLUDED FALSE 240 #endif 241 242 #ifndef BTA_MSE_INCLUDED 243 #define BTA_MSE_INCLUDED FALSE 244 #endif 245 246 #ifndef BTA_MCE_INCLUDED 247 #define BTA_MCE_INCLUDED FALSE 248 #endif 249 250 #ifndef BTA_PLAYBACK_INCLUDED 251 #define BTA_PLAYBACK_INCLUDED FALSE 252 #endif 253 254 #ifndef BTA_SSR_INCLUDED 255 #define BTA_SSR_INCLUDED FALSE 256 #endif 257 258 #ifndef BTA_JV_INCLUDED 259 #define BTA_JV_INCLUDED FALSE 260 #endif 261 262 #ifndef BTA_GATT_INCLUDED 263 #define BTA_GATT_INCLUDED FALSE 264 #endif 265 266 #ifndef BTA_DISABLE_DELAY 267 #define BTA_DISABLE_DELAY 200 /* in milliseconds */ 268 #endif 269 270 #ifndef RPC_TRACE_ONLY 271 #define RPC_TRACE_ONLY FALSE 272 #endif 273 274 #ifndef ANDROID_APP_INCLUDED 275 #define ANDROID_APP_INCLUDED TRUE 276 #endif 277 278 #ifndef ANDROID_USE_LOGCAT 279 #define ANDROID_USE_LOGCAT TRUE 280 #endif 281 282 #ifndef LINUX_GKI_INCLUDED 283 #define LINUX_GKI_INCLUDED TRUE 284 #endif 285 286 #ifndef BTA_SYS_TIMER_PERIOD 287 #define BTA_SYS_TIMER_PERIOD 100 288 #endif 289 290 #ifndef GKI_SHUTDOWN_EVT 291 #define GKI_SHUTDOWN_EVT APPL_EVT_7 292 #endif 293 294 #ifndef GKI_PTHREAD_JOINABLE 295 #define GKI_PTHREAD_JOINABLE TRUE 296 #endif 297 298 #ifndef LINUX_DRV_INCLUDED 299 #define LINUX_DRV_INCLUDED TRUE 300 #endif 301 302 #ifndef LINUX_OS 303 #define LINUX_OS TRUE 304 #endif 305 306 #ifndef BTM_APP_DEV_INIT 307 #define BTM_APP_DEV_INIT bte_main_post_reset_init 308 #endif 309 310 #ifndef SBC_FOR_EMBEDDED_LINUX 311 #define SBC_FOR_EMBEDDED_LINUX TRUE 312 #endif 313 314 #ifndef BTA_DM_REMOTE_DEVICE_NAME_LENGTH 315 #define BTA_DM_REMOTE_DEVICE_NAME_LENGTH 248 316 #endif 317 318 #ifndef AVDT_VERSION 319 #define AVDT_VERSION 0x0102 320 #endif 321 322 #ifndef BTA_AG_AT_MAX_LEN 323 #define BTA_AG_AT_MAX_LEN 512 324 #endif 325 326 #ifndef BTA_AVRCP_FF_RW_SUPPORT 327 #define BTA_AVRCP_FF_RW_SUPPORT TRUE 328 #endif 329 330 #ifndef BTA_AG_SCO_PKT_TYPES 331 #define BTA_AG_SCO_PKT_TYPES (BTM_SCO_LINK_ONLY_MASK | BTM_SCO_PKT_TYPES_MASK_EV3 | BTM_SCO_PKT_TYPES_MASK_NO_3_EV3 | BTM_SCO_PKT_TYPES_MASK_NO_2_EV5 | BTM_SCO_PKT_TYPES_MASK_NO_3_EV5) 332 #endif 333 334 #ifndef BTA_AV_MAX_A2DP_MTU 335 #define BTA_AV_MAX_A2DP_MTU 668 336 #endif 337 338 #ifndef BTA_AV_RET_TOUT 339 #define BTA_AV_RET_TOUT 15 340 #endif 341 342 #ifndef PORCHE_PAIRING_CONFLICT 343 #define PORCHE_PAIRING_CONFLICT TRUE 344 #endif 345 346 #ifndef BTA_AV_CO_CP_SCMS_T 347 #define BTA_AV_CO_CP_SCMS_T FALSE 348 #endif 349 350 #ifndef AVDT_CONNECT_CP_ONLY 351 #define AVDT_CONNECT_CP_ONLY FALSE 352 #endif 353 354 #ifndef BT_TRACE_PROTOCOL 355 #define BT_TRACE_PROTOCOL TRUE 356 #endif 357 358 #ifndef BT_USE_TRACES 359 #define BT_USE_TRACES TRUE 360 #endif 361 362 #ifndef BT_TRACE_BTIF 363 #define BT_TRACE_BTIF TRUE 364 #endif 365 366 #ifndef BTTRC_INCLUDED 367 #define BTTRC_INCLUDED FALSE 368 #endif 369 370 #ifndef BT_TRACE_VERBOSE 371 #define BT_TRACE_VERBOSE FALSE 372 #endif 373 374 #ifndef BTTRC_PARSER_INCLUDED 375 #define BTTRC_PARSER_INCLUDED FALSE 376 #endif 377 378 #ifndef MAX_TRACE_RAM_SIZE 379 #define MAX_TRACE_RAM_SIZE 10000 380 #endif 381 382 #ifndef OBX_INITIAL_TRACE_LEVEL 383 #define OBX_INITIAL_TRACE_LEVEL BT_TRACE_LEVEL_ERROR 384 #endif 385 386 #ifndef PBAP_ZERO_VCARD_IN_DB 387 #define PBAP_ZERO_VCARD_IN_DB FALSE 388 #endif 389 390 #ifndef BTA_DM_SDP_DB_SIZE 391 #define BTA_DM_SDP_DB_SIZE 8000 392 #endif 393 394 #ifndef FTS_REJECT_INVALID_OBEX_SET_PATH_REQ 395 #define FTS_REJECT_INVALID_OBEX_SET_PATH_REQ FALSE 396 #endif 397 398 #ifndef HL_INCLUDED 399 #define HL_INCLUDED TRUE 400 #endif 401 402 #ifndef NO_GKI_RUN_RETURN 403 #define NO_GKI_RUN_RETURN TRUE 404 #endif 405 406 #ifndef AG_VOICE_SETTINGS 407 #define AG_VOICE_SETTINGS HCI_DEFAULT_VOICE_SETTINGS 408 #endif 409 410 #ifndef BTIF_DM_OOB_TEST 411 #define BTIF_DM_OOB_TEST TRUE 412 #endif 413 //------------------End added from Bluedroid buildcfg.h--------------------- 414 415 416 417 /* #define BYPASS_AVDATATRACE */ 418 419 /****************************************************************************** 420 ** 421 ** Platform-Specific 422 ** 423 ******************************************************************************/ 424 425 /* API macros for simulator */ 426 427 #define BTAPI 428 429 #ifndef BTE_BSE_WRAPPER 430 #ifdef BTE_SIM_APP 431 #undef BTAPI 432 #define BTAPI __declspec(dllexport) 433 #endif 434 #endif 435 436 #define BT_API BTAPI 437 #define BTU_API BTAPI 438 #define A2D_API BTAPI 439 #define VDP_API BTAPI 440 #define AVDT_API BTAPI 441 #define AVCT_API BTAPI 442 #define AVRC_API BTAPI 443 #define BIP_API BTAPI 444 #define BNEP_API BTAPI 445 #define BPP_API BTAPI 446 #define BTM_API BTAPI 447 #define CTP_API BTAPI 448 #define DUN_API BTAPI 449 #define FTP_API BTAPI 450 #define GAP_API BTAPI 451 #define GOEP_API BTAPI 452 #define HCI_API BTAPI 453 #define HCRP_API BTAPI 454 #define HID_API BTAPI 455 #define HFP_API BTAPI 456 #define HSP2_API BTAPI 457 #define ICP_API BTAPI 458 #define L2C_API BTAPI 459 #define OBX_API BTAPI 460 #define OPP_API BTAPI 461 #define PAN_API BTAPI 462 #define RFC_API BTAPI 463 #define RPC_API BTAPI 464 #define SDP_API BTAPI 465 #define SPP_API BTAPI 466 #define TCS_API BTAPI 467 #define XML_API BTAPI 468 #define BTA_API BTAPI 469 #define SBC_API BTAPI 470 #define MCE_API BTAPI 471 #define MCA_API BTAPI 472 #define GATT_API BTAPI 473 #define SMP_API BTAPI 474 475 476 /****************************************************************************** 477 ** 478 ** GKI Buffer Pools 479 ** 480 ******************************************************************************/ 481 482 /* Receives HCI events from the lower-layer. */ 483 #ifndef HCI_CMD_POOL_ID 484 #define HCI_CMD_POOL_ID GKI_POOL_ID_2 485 #endif 486 487 #ifndef HCI_CMD_POOL_BUF_SIZE 488 #define HCI_CMD_POOL_BUF_SIZE GKI_BUF2_SIZE 489 #endif 490 491 /* Receives ACL data packets from thelower-layer. */ 492 #ifndef HCI_ACL_POOL_ID 493 #define HCI_ACL_POOL_ID GKI_POOL_ID_3 494 #endif 495 496 #ifndef HCI_ACL_POOL_BUF_SIZE 497 #define HCI_ACL_POOL_BUF_SIZE GKI_BUF3_SIZE 498 #endif 499 500 /* Maximum number of buffers available for ACL receive data. */ 501 #ifndef HCI_ACL_BUF_MAX 502 #define HCI_ACL_BUF_MAX GKI_BUF3_MAX 503 #endif 504 505 /* Receives SCO data packets from the lower-layer. */ 506 #ifndef HCI_SCO_POOL_ID 507 #define HCI_SCO_POOL_ID GKI_POOL_ID_6 508 #endif 509 510 /* Not used. */ 511 #ifndef HCI_DATA_DESCR_POOL_ID 512 #define HCI_DATA_DESCR_POOL_ID GKI_POOL_ID_0 513 #endif 514 515 /* Sends SDP data packets. */ 516 #ifndef SDP_POOL_ID 517 #define SDP_POOL_ID 3 518 #endif 519 520 /* Sends RFCOMM command packets. */ 521 #ifndef RFCOMM_CMD_POOL_ID 522 #define RFCOMM_CMD_POOL_ID GKI_POOL_ID_2 523 #endif 524 525 #ifndef RFCOMM_CMD_POOL_BUF_SIZE 526 #define RFCOMM_CMD_POOL_BUF_SIZE GKI_BUF2_SIZE 527 #endif 528 529 /* Sends RFCOMM data packets. */ 530 #ifndef RFCOMM_DATA_POOL_ID 531 #define RFCOMM_DATA_POOL_ID GKI_POOL_ID_3 532 #endif 533 534 #ifndef RFCOMM_DATA_POOL_BUF_SIZE 535 #define RFCOMM_DATA_POOL_BUF_SIZE GKI_BUF3_SIZE 536 #endif 537 538 /* Sends L2CAP packets to the peer and HCI messages to the controller. */ 539 #ifndef L2CAP_CMD_POOL_ID 540 #define L2CAP_CMD_POOL_ID GKI_POOL_ID_2 541 #endif 542 543 /* Sends L2CAP segmented packets in ERTM mode */ 544 #ifndef L2CAP_FCR_TX_POOL_ID 545 #define L2CAP_FCR_TX_POOL_ID HCI_ACL_POOL_ID 546 #endif 547 548 /* Receives L2CAP segmented packets in ERTM mode */ 549 #ifndef L2CAP_FCR_RX_POOL_ID 550 #define L2CAP_FCR_RX_POOL_ID HCI_ACL_POOL_ID 551 #endif 552 553 /* Used by BTM when it sends HCI commands to the controller. */ 554 #ifndef BTM_CMD_POOL_ID 555 #define BTM_CMD_POOL_ID GKI_POOL_ID_2 556 #endif 557 558 /* Sends TCS messages. */ 559 #ifndef TCS_MSG_POOL_ID 560 #define TCS_MSG_POOL_ID GKI_POOL_ID_2 561 #endif 562 563 #ifndef OBX_CMD_POOL_SIZE 564 #define OBX_CMD_POOL_SIZE GKI_BUF2_SIZE 565 #endif 566 567 #ifndef OBX_LRG_DATA_POOL_SIZE 568 #define OBX_LRG_DATA_POOL_SIZE GKI_BUF4_SIZE 569 #endif 570 571 #ifndef OBX_LRG_DATA_POOL_ID 572 #define OBX_LRG_DATA_POOL_ID GKI_POOL_ID_4 573 #endif 574 575 /* Used for CTP discovery database. */ 576 #ifndef CTP_SDP_DB_POOL_ID 577 #define CTP_SDP_DB_POOL_ID GKI_POOL_ID_3 578 #endif 579 580 /* Used for CTP data exchange feature. */ 581 #ifndef CTP_DATA_EXCHG_POOL_ID 582 #define CTP_DATA_EXCHG_POOL_ID GKI_POOL_ID_2 583 #endif 584 585 /* Used to send data to L2CAP. */ 586 #ifndef GAP_DATA_POOL_ID 587 #define GAP_DATA_POOL_ID GKI_POOL_ID_3 588 #endif 589 590 /* Used for SPP inquiry and discovery databases. */ 591 #ifndef SPP_DB_POOL_ID 592 #define SPP_DB_POOL_ID GKI_POOL_ID_3 593 #endif 594 595 #ifndef SPP_DB_SIZE 596 #define SPP_DB_SIZE GKI_BUF3_SIZE 597 #endif 598 599 /* HCRP protocol and internal commands. */ 600 #ifndef HCRP_CMD_POOL_ID 601 #define HCRP_CMD_POOL_ID GKI_POOL_ID_2 602 #endif 603 604 #ifndef HCRP_CMD_POOL_SIZE 605 #define HCRP_CMD_POOL_SIZE GKI_BUF2_SIZE 606 #endif 607 608 #ifndef BIP_EVT_POOL_SIZE 609 #define BIP_EVT_POOL_SIZE GKI_BUF3_SIZE 610 #endif 611 612 #ifndef BIP_DB_SIZE 613 #define BIP_DB_SIZE GKI_BUF3_SIZE 614 #endif 615 616 617 /* BNEP data and protocol messages. */ 618 #ifndef BNEP_POOL_ID 619 #define BNEP_POOL_ID GKI_POOL_ID_3 620 #endif 621 622 /* RPC pool for temporary trace message buffers. */ 623 #ifndef RPC_SCRATCH_POOL_ID 624 #define RPC_SCRATCH_POOL_ID GKI_POOL_ID_2 625 #endif 626 627 /* RPC scratch buffer size (not related to RPC_SCRATCH_POOL_ID) */ 628 #ifndef RPC_SCRATCH_BUF_SIZE 629 #define RPC_SCRATCH_BUF_SIZE GKI_BUF3_SIZE 630 #endif 631 632 /* RPC pool for protocol messages */ 633 #ifndef RPC_MSG_POOL_ID 634 #define RPC_MSG_POOL_ID GKI_POOL_ID_3 635 #endif 636 637 #ifndef RPC_MSG_POOL_SIZE 638 #define RPC_MSG_POOL_SIZE GKI_BUF3_SIZE 639 #endif 640 641 /* AVDTP pool for protocol messages */ 642 #ifndef AVDT_CMD_POOL_ID 643 #define AVDT_CMD_POOL_ID GKI_POOL_ID_2 644 #endif 645 646 /* AVDTP pool size for media packets in case of fragmentation */ 647 #ifndef AVDT_DATA_POOL_SIZE 648 #define AVDT_DATA_POOL_SIZE GKI_BUF3_SIZE 649 #endif 650 651 #ifndef PAN_POOL_ID 652 #define PAN_POOL_ID GKI_POOL_ID_3 653 #endif 654 655 /* UNV pool for read/write serialization */ 656 #ifndef UNV_MSG_POOL_ID 657 #define UNV_MSG_POOL_ID GKI_POOL_ID_2 658 #endif 659 660 #ifndef UNV_MSG_POOL_SIZE 661 #define UNV_MSG_POOL_SIZE GKI_BUF2_SIZE 662 #endif 663 664 /* AVCTP pool for protocol messages */ 665 #ifndef AVCT_CMD_POOL_ID 666 #define AVCT_CMD_POOL_ID GKI_POOL_ID_1 667 #endif 668 669 #ifndef AVCT_META_CMD_POOL_ID 670 #define AVCT_META_CMD_POOL_ID GKI_POOL_ID_2 671 #endif 672 673 /* AVRCP pool for protocol messages */ 674 #ifndef AVRC_CMD_POOL_ID 675 #define AVRC_CMD_POOL_ID GKI_POOL_ID_1 676 #endif 677 678 /* AVRCP pool size for protocol messages */ 679 #ifndef AVRC_CMD_POOL_SIZE 680 #define AVRC_CMD_POOL_SIZE GKI_BUF1_SIZE 681 #endif 682 683 /* AVRCP Metadata pool for protocol messages */ 684 #ifndef AVRC_META_CMD_POOL_ID 685 #define AVRC_META_CMD_POOL_ID GKI_POOL_ID_2 686 #endif 687 688 /* AVRCP Metadata pool size for protocol messages */ 689 #ifndef AVRC_META_CMD_POOL_SIZE 690 #define AVRC_META_CMD_POOL_SIZE GKI_BUF2_SIZE 691 #endif 692 693 694 /* AVRCP buffer size for browsing channel messages */ 695 #ifndef AVRC_BROWSE_POOL_SIZE 696 #define AVRC_BROWSE_POOL_SIZE GKI_MAX_BUF_SIZE 697 #endif 698 699 /* HDP buffer size for the Pulse Oximeter */ 700 #ifndef BTA_HL_LRG_DATA_POOL_SIZE 701 #define BTA_HL_LRG_DATA_POOL_SIZE GKI_BUF7_SIZE 702 #endif 703 704 #ifndef BTA_HL_LRG_DATA_POOL_ID 705 #define BTA_HL_LRG_DATA_POOL_ID GKI_POOL_ID_7 706 #endif 707 708 /* GATT Server Database pool ID */ 709 #ifndef GATT_DB_POOL_ID 710 #define GATT_DB_POOL_ID GKI_POOL_ID_8 711 #endif 712 713 /****************************************************************************** 714 ** 715 ** Lower Layer Interface 716 ** 717 ******************************************************************************/ 718 719 /* Sends ACL data received over HCI to the upper stack. */ 720 #ifndef HCI_ACL_DATA_TO_UPPER 721 #define HCI_ACL_DATA_TO_UPPER(p) {((BT_HDR *)p)->event = BT_EVT_TO_BTU_HCI_ACL; GKI_send_msg (BTU_TASK, BTU_HCI_RCV_MBOX, p);} 722 #endif 723 724 /* Sends SCO data received over HCI to the upper stack. */ 725 #ifndef HCI_SCO_DATA_TO_UPPER 726 #define HCI_SCO_DATA_TO_UPPER(p) {((BT_HDR *)p)->event = BT_EVT_TO_BTU_HCI_SCO; GKI_send_msg (BTU_TASK, BTU_HCI_RCV_MBOX, p);} 727 #endif 728 729 /* Sends an HCI event received over HCI to theupper stack. */ 730 #ifndef HCI_EVT_TO_UPPER 731 #define HCI_EVT_TO_UPPER(p) {((BT_HDR *)p)->event = BT_EVT_TO_BTU_HCI_EVT; GKI_send_msg (BTU_TASK, BTU_HCI_RCV_MBOX, p);} 732 #endif 733 734 /* Macro for allocating buffer for HCI commands */ 735 #ifndef HCI_GET_CMD_BUF 736 #if (!defined(HCI_USE_VARIABLE_SIZE_CMD_BUF) || (HCI_USE_VARIABLE_SIZE_CMD_BUF == FALSE)) 737 /* Allocate fixed-size buffer from HCI_CMD_POOL (default case) */ 738 #define HCI_GET_CMD_BUF(paramlen) ((BT_HDR *)GKI_getpoolbuf (HCI_CMD_POOL_ID)) 739 #else 740 /* Allocate smallest possible buffer (for platforms with limited RAM) */ 741 #define HCI_GET_CMD_BUF(paramlen) ((BT_HDR *)GKI_getbuf ((UINT16)(BT_HDR_SIZE + HCIC_PREAMBLE_SIZE + (paramlen)))) 742 #endif 743 #endif /* HCI_GET_CMD_BUF */ 744 745 /****************************************************************************** 746 ** 747 ** HCI Services (H4) 748 ** 749 ******************************************************************************/ 750 #ifndef HCISU_H4_INCLUDED 751 #define HCISU_H4_INCLUDED TRUE 752 #endif 753 754 #ifdef __cplusplus 755 extern "C" { 756 #endif 757 758 BT_API extern void bte_main_hci_send (BT_HDR *p_msg, UINT16 event); 759 #if (HCISU_H4_INCLUDED == TRUE) 760 BT_API extern void bte_main_lpm_allow_bt_device_sleep(void); 761 #endif 762 763 #ifdef __cplusplus 764 } 765 #endif 766 767 /* Sends ACL data received from the upper stack to the BD/EDR HCI transport. */ 768 #ifndef HCI_ACL_DATA_TO_LOWER 769 #define HCI_ACL_DATA_TO_LOWER(p) bte_main_hci_send((BT_HDR *)(p), BT_EVT_TO_LM_HCI_ACL); 770 #endif 771 772 #ifndef HCI_BLE_ACL_DATA_TO_LOWER 773 #define HCI_BLE_ACL_DATA_TO_LOWER(p) bte_main_hci_send((BT_HDR *)(p), (UINT16)(BT_EVT_TO_LM_HCI_ACL|LOCAL_BLE_CONTROLLER_ID)); 774 #endif 775 776 /* Sends SCO data received from the upper stack to the HCI transport. */ 777 #ifndef HCI_SCO_DATA_TO_LOWER 778 #define HCI_SCO_DATA_TO_LOWER(p) bte_main_hci_send((BT_HDR *)(p), BT_EVT_TO_LM_HCI_SCO); 779 #endif 780 781 /* Sends an HCI command received from the upper stack to the BD/EDR HCI transport. */ 782 #ifndef HCI_CMD_TO_LOWER 783 #define HCI_CMD_TO_LOWER(p) bte_main_hci_send((BT_HDR *)(p), BT_EVT_TO_LM_HCI_CMD); 784 #endif 785 786 /* Sends an LM Diagnosic command received from the upper stack to the HCI transport. */ 787 #ifndef HCI_LM_DIAG_TO_LOWER 788 #define HCI_LM_DIAG_TO_LOWER(p) bte_main_hci_send((BT_HDR *)(p), BT_EVT_TO_LM_DIAG); 789 #endif 790 791 /* Send HCISU a message to allow BT sleep */ 792 #ifndef HCI_LP_ALLOW_BT_DEVICE_SLEEP 793 #define HCI_LP_ALLOW_BT_DEVICE_SLEEP() bte_main_lpm_allow_bt_device_sleep() 794 #endif 795 796 /* If nonzero, the upper-layer sends at most this number of HCI commands to the lower-layer. */ 797 #ifndef HCI_MAX_SIMUL_CMDS 798 #define HCI_MAX_SIMUL_CMDS 0 799 #endif 800 801 /* Timeout for receiving response to HCI command */ 802 #ifndef BTU_CMD_CMPL_TIMEOUT 803 #define BTU_CMD_CMPL_TIMEOUT 8 804 #endif 805 806 /* If TRUE, BTU task will check HCISU again when HCI command timer expires */ 807 #ifndef BTU_CMD_CMPL_TOUT_DOUBLE_CHECK 808 #define BTU_CMD_CMPL_TOUT_DOUBLE_CHECK FALSE 809 #endif 810 811 /* Use 2 second for low-resolution systems, override to 1 for high-resolution systems */ 812 #ifndef BT_1SEC_TIMEOUT 813 #define BT_1SEC_TIMEOUT (2) 814 #endif 815 816 /* Quick Timer */ 817 /* if L2CAP_FCR_INCLUDED is TRUE then it should have 100 millisecond resolution */ 818 /* if none of them is included then QUICK_TIMER_TICKS_PER_SEC is set to 0 to exclude quick timer */ 819 #ifndef QUICK_TIMER_TICKS_PER_SEC 820 #define QUICK_TIMER_TICKS_PER_SEC 10 /* 10ms timer */ 821 #endif 822 823 /****************************************************************************** 824 ** 825 ** BTM 826 ** 827 ******************************************************************************/ 828 /* if set to TRUE, stack will automatically send an HCI reset at start-up. To be 829 set to FALSE for advanced start-up / shut-down procedures using USER_HW_ENABLE_API 830 and USER_HW_DISABLE_API macros */ 831 #ifndef BTM_AUTOMATIC_HCI_RESET 832 #define BTM_AUTOMATIC_HCI_RESET FALSE 833 #endif 834 835 /* Include BTM Discovery database and code. */ 836 #ifndef BTM_DISCOVERY_INCLUDED 837 #define BTM_DISCOVERY_INCLUDED TRUE 838 #endif 839 840 /* Include inquiry code. */ 841 #ifndef BTM_INQUIRY_INCLUDED 842 #define BTM_INQUIRY_INCLUDED TRUE 843 #endif 844 845 /* Cancel Inquiry on incoming SSP */ 846 #ifndef BTM_NO_SSP_ON_INQUIRY 847 #define BTM_NO_SSP_ON_INQUIRY FALSE 848 #endif 849 850 /* Include periodic inquiry code (used when BTM_INQUIRY_INCLUDED is TRUE). */ 851 #ifndef BTM_PERIODIC_INQ_INCLUDED 852 #define BTM_PERIODIC_INQ_INCLUDED TRUE 853 #endif 854 855 /* Include security authorization code */ 856 #ifndef BTM_AUTHORIZATION_INCLUDED 857 #define BTM_AUTHORIZATION_INCLUDED TRUE 858 #endif 859 860 /* Includes SCO if TRUE */ 861 #ifndef BTM_SCO_INCLUDED 862 #define BTM_SCO_INCLUDED TRUE /* TRUE includes SCO code */ 863 #endif 864 865 /* Includes SCO if TRUE */ 866 #ifndef BTM_SCO_HCI_INCLUDED 867 #define BTM_SCO_HCI_INCLUDED FALSE /* TRUE includes SCO over HCI code */ 868 #endif 869 870 /* Includes WBS if TRUE */ 871 #ifndef BTM_WBS_INCLUDED 872 #define BTM_WBS_INCLUDED FALSE /* TRUE includes WBS code */ 873 #endif 874 875 /* Includes PCM2 support if TRUE */ 876 #ifndef BTM_PCM2_INCLUDED 877 #define BTM_PCM2_INCLUDED FALSE 878 #endif 879 880 /* This is used to work around a controller bug that doesn't like Disconnect 881 ** issued while there is a role switch in progress 882 */ 883 #ifndef BTM_DISC_DURING_RS 884 #define BTM_DISC_DURING_RS TRUE 885 #endif 886 887 /************************** 888 ** Initial SCO TX credit 889 *************************/ 890 /* max TX SCO data packet size */ 891 #ifndef BTM_SCO_DATA_SIZE_MAX 892 #define BTM_SCO_DATA_SIZE_MAX 240 893 #endif 894 895 /* maximum BTM buffering capacity */ 896 #ifndef BTM_SCO_MAX_BUF_CAP 897 #define BTM_SCO_MAX_BUF_CAP (BTM_SCO_INIT_XMIT_CREDIT * 4) 898 #endif 899 900 /* The size in bytes of the BTM inquiry database. */ 901 #ifndef BTM_INQ_DB_SIZE 902 #define BTM_INQ_DB_SIZE 40 903 #endif 904 905 /* This is set to enable automatic periodic inquiry at startup. */ 906 #ifndef BTM_ENABLE_AUTO_INQUIRY 907 #define BTM_ENABLE_AUTO_INQUIRY FALSE 908 #endif 909 910 /* This is set to always try to acquire the remote device name. */ 911 #ifndef BTM_INQ_GET_REMOTE_NAME 912 #define BTM_INQ_GET_REMOTE_NAME FALSE 913 #endif 914 915 /* The inquiry duration in 1.28 second units when auto inquiry is enabled. */ 916 #ifndef BTM_DEFAULT_INQ_DUR 917 #define BTM_DEFAULT_INQ_DUR 5 918 #endif 919 920 /* The inquiry mode when auto inquiry is enabled. */ 921 #ifndef BTM_DEFAULT_INQ_MODE 922 #define BTM_DEFAULT_INQ_MODE BTM_GENERAL_INQUIRY 923 #endif 924 925 /* The default periodic inquiry maximum delay when auto inquiry is enabled, in 1.28 second units. */ 926 #ifndef BTM_DEFAULT_INQ_MAX_DELAY 927 #define BTM_DEFAULT_INQ_MAX_DELAY 30 928 #endif 929 930 /* The default periodic inquiry minimum delay when auto inquiry is enabled, in 1.28 second units. */ 931 #ifndef BTM_DEFAULT_INQ_MIN_DELAY 932 #define BTM_DEFAULT_INQ_MIN_DELAY 20 933 #endif 934 935 /* The maximum age of entries in inquiry database in seconds ('0' disables feature). */ 936 #ifndef BTM_INQ_MAX_AGE 937 #define BTM_INQ_MAX_AGE 0 938 #endif 939 940 /* The maximum age of entries in inquiry database based on inquiry response failure ('0' disables feature). */ 941 #ifndef BTM_INQ_AGE_BY_COUNT 942 #define BTM_INQ_AGE_BY_COUNT 0 943 #endif 944 945 /* TRUE if controller does not support inquiry event filtering. */ 946 #ifndef BTM_BYPASS_EVENT_FILTERING 947 #define BTM_BYPASS_EVENT_FILTERING FALSE 948 #endif 949 950 /* TRUE if inquiry filtering is desired from BTM. */ 951 #ifndef BTM_USE_INQ_RESULTS_FILTER 952 #define BTM_USE_INQ_RESULTS_FILTER TRUE 953 #endif 954 955 /* The default scan mode */ 956 #ifndef BTM_DEFAULT_SCAN_TYPE 957 #define BTM_DEFAULT_SCAN_TYPE BTM_SCAN_TYPE_INTERLACED 958 #endif 959 960 /* Should connections to unknown devices be allowed when not discoverable? */ 961 #ifndef BTM_ALLOW_CONN_IF_NONDISCOVER 962 #define BTM_ALLOW_CONN_IF_NONDISCOVER TRUE 963 #endif 964 965 /* When connectable mode is set to TRUE, the device will respond to paging. */ 966 #ifndef BTM_IS_CONNECTABLE 967 #define BTM_IS_CONNECTABLE FALSE 968 #endif 969 970 /* Sets the Page_Scan_Window: the length of time that the device is performing a page scan. */ 971 #ifndef BTM_DEFAULT_CONN_WINDOW 972 #define BTM_DEFAULT_CONN_WINDOW 0x0012 973 #endif 974 975 /* Sets the Page_Scan_Activity: the interval between the start of two consecutive page scans. */ 976 #ifndef BTM_DEFAULT_CONN_INTERVAL 977 #define BTM_DEFAULT_CONN_INTERVAL 0x0800 978 #endif 979 980 /* This is set to automatically perform inquiry scan on startup. */ 981 #ifndef BTM_IS_DISCOVERABLE 982 #define BTM_IS_DISCOVERABLE FALSE 983 #endif 984 985 /* When automatic inquiry scan is enabled, this sets the discovery mode. */ 986 #ifndef BTM_DEFAULT_DISC_MODE 987 #define BTM_DEFAULT_DISC_MODE BTM_GENERAL_DISCOVERABLE 988 #endif 989 990 /* When automatic inquiry scan is enabled, this sets the inquiry scan window. */ 991 #ifndef BTM_DEFAULT_DISC_WINDOW 992 #define BTM_DEFAULT_DISC_WINDOW 0x0012 993 #endif 994 995 /* When automatic inquiry scan is enabled, this sets the inquiry scan interval. */ 996 #ifndef BTM_DEFAULT_DISC_INTERVAL 997 #define BTM_DEFAULT_DISC_INTERVAL 0x0800 998 #endif 999 1000 /* Sets the period, in seconds, to automatically perform service discovery. */ 1001 #ifndef BTM_AUTO_DISCOVERY_PERIOD 1002 #define BTM_AUTO_DISCOVERY_PERIOD 0 1003 #endif 1004 1005 /* The size in bytes of the BTM discovery database (if discovery is included). */ 1006 #ifndef BTM_DISCOVERY_DB_SIZE 1007 #define BTM_DISCOVERY_DB_SIZE 4000 1008 #endif 1009 1010 /* Number of milliseconds to delay BTU task startup upon device initialization. */ 1011 #ifndef BTU_STARTUP_DELAY 1012 #define BTU_STARTUP_DELAY 0 1013 #endif 1014 1015 /* Whether BTA is included in BTU task. */ 1016 #ifndef BTU_BTA_INCLUDED 1017 #define BTU_BTA_INCLUDED TRUE 1018 #endif 1019 1020 /* Number of seconds to wait to send an HCI Reset command upon device initialization. */ 1021 #ifndef BTM_FIRST_RESET_DELAY 1022 #define BTM_FIRST_RESET_DELAY 0 1023 #endif 1024 1025 /* The number of seconds to wait for controller module to reset after issuing an HCI Reset command. */ 1026 #ifndef BTM_AFTER_RESET_TIMEOUT 1027 #define BTM_AFTER_RESET_TIMEOUT 0 1028 #endif 1029 1030 /* Default class of device 1031 * {SERVICE_CLASS, MAJOR_CLASS, MINOR_CLASS} 1032 * 1033 * SERVICE_CLASS:0x5A (Bit17 -Networking,Bit19 - Capturing,Bit20 -Object Transfer,Bit22 -Telephony) 1034 * MAJOR_CLASS:0x02 - PHONE 1035 * MINOR_CLASS:0x0C - SMART_PHONE 1036 * 1037 */ 1038 #ifndef BTA_DM_COD 1039 #define BTA_DM_COD {0x5A, 0x02, 0x0C} 1040 #endif 1041 1042 /* The number of SCO links. */ 1043 #ifndef BTM_MAX_SCO_LINKS 1044 #define BTM_MAX_SCO_LINKS 2 1045 #endif 1046 1047 /* The preferred type of SCO links (2-eSCO, 0-SCO). */ 1048 #ifndef BTM_DEFAULT_SCO_MODE 1049 #define BTM_DEFAULT_SCO_MODE 2 1050 #endif 1051 1052 /* The number of security records for peer devices. */ 1053 #ifndef BTM_SEC_MAX_DEVICE_RECORDS 1054 #define BTM_SEC_MAX_DEVICE_RECORDS 100 1055 #endif 1056 1057 /* The number of security records for services. */ 1058 #ifndef BTM_SEC_MAX_SERVICE_RECORDS 1059 #define BTM_SEC_MAX_SERVICE_RECORDS 32 1060 #endif 1061 1062 /* If True, force a retrieval of remote device name for each bond in case it's changed */ 1063 #ifndef BTM_SEC_FORCE_RNR_FOR_DBOND 1064 #define BTM_SEC_FORCE_RNR_FOR_DBOND FALSE 1065 #endif 1066 1067 /* Maximum device name length used in btm database. */ 1068 #ifndef BTM_MAX_REM_BD_NAME_LEN 1069 #define BTM_MAX_REM_BD_NAME_LEN 248 1070 #endif 1071 1072 /* Maximum local device name length stored btm database. 1073 '0' disables storage of the local name in BTM */ 1074 #ifndef BTM_MAX_LOC_BD_NAME_LEN 1075 #define BTM_MAX_LOC_BD_NAME_LEN 248 1076 #endif 1077 1078 /* TRUE if default string is used, FALSE if device name is set in the application */ 1079 #ifndef BTM_USE_DEF_LOCAL_NAME 1080 #define BTM_USE_DEF_LOCAL_NAME TRUE 1081 #endif 1082 1083 /* Fixed Default String (Ignored if BTM_USE_DEF_LOCAL_NAME is FALSE) */ 1084 #ifndef BTM_DEF_LOCAL_NAME 1085 #define BTM_DEF_LOCAL_NAME "" 1086 #endif 1087 1088 /* Maximum service name stored with security authorization (0 if not needed) */ 1089 #ifndef BTM_SEC_SERVICE_NAME_LEN 1090 #define BTM_SEC_SERVICE_NAME_LEN BT_MAX_SERVICE_NAME_LEN 1091 #endif 1092 1093 /* Maximum number of pending security callback */ 1094 #ifndef BTM_SEC_MAX_CALLBACKS 1095 #define BTM_SEC_MAX_CALLBACKS 7 1096 #endif 1097 1098 /* Maximum length of the service name. */ 1099 #ifndef BT_MAX_SERVICE_NAME_LEN 1100 #define BT_MAX_SERVICE_NAME_LEN 21 1101 #endif 1102 1103 /* ACL buffer size in HCI Host Buffer Size command. */ 1104 #ifndef BTM_ACL_BUF_SIZE 1105 #define BTM_ACL_BUF_SIZE 0 1106 #endif 1107 1108 /* This is set to use the BTM power manager. */ 1109 #ifndef BTM_PWR_MGR_INCLUDED 1110 #define BTM_PWR_MGR_INCLUDED TRUE 1111 #endif 1112 1113 /* The maximum number of clients that can register with the power manager. */ 1114 #ifndef BTM_MAX_PM_RECORDS 1115 #define BTM_MAX_PM_RECORDS 2 1116 #endif 1117 1118 /* This is set to show debug trace messages for the power manager. */ 1119 #ifndef BTM_PM_DEBUG 1120 #define BTM_PM_DEBUG FALSE 1121 #endif 1122 1123 /* This is set to TRUE if link is to be unparked due to BTM_CreateSCO API. */ 1124 #ifndef BTM_SCO_WAKE_PARKED_LINK 1125 #define BTM_SCO_WAKE_PARKED_LINK TRUE 1126 #endif 1127 1128 /* May be set to the the name of a function used for vendor specific chip initialization */ 1129 #ifndef BTM_APP_DEV_INIT 1130 /* #define BTM_APP_DEV_INIT myInitFunction() */ 1131 #endif 1132 1133 /* This is set to TRUE if the busy level change event is desired. (replace ACL change event) */ 1134 #ifndef BTM_BUSY_LEVEL_CHANGE_INCLUDED 1135 #define BTM_BUSY_LEVEL_CHANGE_INCLUDED TRUE 1136 #endif 1137 1138 /* If the user does not respond to security process requests within this many seconds, 1139 * a negative response would be sent automatically. 1140 * It's recommended to use a value between 30 and OBX_TIMEOUT_VALUE 1141 * 30 is LMP response timeout value */ 1142 #ifndef BTM_SEC_TIMEOUT_VALUE 1143 #define BTM_SEC_TIMEOUT_VALUE 35 1144 #endif 1145 1146 /* Maximum number of callbacks that can be registered using BTM_RegisterForVSEvents */ 1147 #ifndef BTM_MAX_VSE_CALLBACKS 1148 #define BTM_MAX_VSE_CALLBACKS 3 1149 #endif 1150 1151 /* Number of streams for dual stack */ 1152 #ifndef BTM_SYNC_INFO_NUM_STR 1153 #define BTM_SYNC_INFO_NUM_STR 2 1154 #endif 1155 1156 /* Number of streams for dual stack in BT Controller */ 1157 #ifndef BTM_SYNC_INFO_NUM_STR_BTC 1158 #define BTM_SYNC_INFO_NUM_STR_BTC 2 1159 #endif 1160 1161 /****************************************** 1162 ** Lisbon Features 1163 *******************************************/ 1164 /* This is set to TRUE if the server Extended Inquiry Response feature is desired. */ 1165 /* server sends EIR to client */ 1166 #ifndef BTM_EIR_SERVER_INCLUDED 1167 #define BTM_EIR_SERVER_INCLUDED TRUE 1168 #endif 1169 1170 /* This is set to TRUE if the client Extended Inquiry Response feature is desired. */ 1171 /* client inquiry to server */ 1172 #ifndef BTM_EIR_CLIENT_INCLUDED 1173 #define BTM_EIR_CLIENT_INCLUDED TRUE 1174 #endif 1175 1176 /* This is set to TRUE if the FEC is required for EIR packet. */ 1177 #ifndef BTM_EIR_DEFAULT_FEC_REQUIRED 1178 #define BTM_EIR_DEFAULT_FEC_REQUIRED TRUE 1179 #endif 1180 1181 /* User defined UUID look up table */ 1182 #ifndef BTM_EIR_UUID_LKUP_TBL 1183 #endif 1184 1185 /* The IO capability of the local device (for Simple Pairing) */ 1186 #ifndef BTM_LOCAL_IO_CAPS 1187 #define BTM_LOCAL_IO_CAPS BTM_IO_CAP_IO 1188 #endif 1189 1190 /* The default MITM Protection Requirement (for Simple Pairing) 1191 * Possible values are BTM_AUTH_SP_YES or BTM_AUTH_SP_NO */ 1192 #ifndef BTM_DEFAULT_AUTH_REQ 1193 #define BTM_DEFAULT_AUTH_REQ BTM_AUTH_SP_NO 1194 #endif 1195 1196 /* The default MITM Protection Requirement for dedicated bonding using Simple Pairing 1197 * Possible values are BTM_AUTH_AP_YES or BTM_AUTH_AP_NO */ 1198 #ifndef BTM_DEFAULT_DD_AUTH_REQ 1199 #define BTM_DEFAULT_DD_AUTH_REQ BTM_AUTH_AP_YES 1200 #endif 1201 1202 /* Include Out-of-Band implementation for Simple Pairing */ 1203 #ifndef BTM_OOB_INCLUDED 1204 #define BTM_OOB_INCLUDED TRUE 1205 #endif 1206 1207 /* TRUE to include Sniff Subrating */ 1208 #ifndef BTM_SSR_INCLUDED 1209 #define BTM_SSR_INCLUDED TRUE 1210 #endif 1211 1212 /************************* 1213 ** End of Lisbon Features 1214 **************************/ 1215 1216 /* Used for conformance testing ONLY */ 1217 #ifndef BTM_BLE_CONFORMANCE_TESTING 1218 #define BTM_BLE_CONFORMANCE_TESTING FALSE 1219 #endif 1220 1221 /* Maximum number of consecutive HCI commands that can time out 1222 * before it gets treated as H/w error*/ 1223 #ifndef BTM_MAX_HCI_CMD_TOUT_BEFORE_RESTART 1224 #define BTM_MAX_HCI_CMD_TOUT_BEFORE_RESTART 2 1225 #endif 1226 1227 /****************************************************************************** 1228 ** 1229 ** L2CAP 1230 ** 1231 ******************************************************************************/ 1232 1233 /* Flow control and retransmission mode */ 1234 1235 #ifndef L2CAP_FCR_INCLUDED 1236 #define L2CAP_FCR_INCLUDED TRUE 1237 #endif 1238 1239 /* The maximum number of simultaneous links that L2CAP can support. */ 1240 #ifndef MAX_ACL_CONNECTIONS 1241 #define MAX_L2CAP_LINKS 7 1242 #else 1243 #define MAX_L2CAP_LINKS MAX_ACL_CONNECTIONS 1244 #endif 1245 1246 /* The maximum number of simultaneous channels that L2CAP can support. */ 1247 #ifndef MAX_L2CAP_CHANNELS 1248 #define MAX_L2CAP_CHANNELS 10 1249 #endif 1250 1251 /* The maximum number of simultaneous applications that can register with L2CAP. */ 1252 #ifndef MAX_L2CAP_CLIENTS 1253 #define MAX_L2CAP_CLIENTS 15 1254 #endif 1255 1256 /* The number of seconds of link inactivity before a link is disconnected. */ 1257 #ifndef L2CAP_LINK_INACTIVITY_TOUT 1258 #define L2CAP_LINK_INACTIVITY_TOUT 4 1259 #endif 1260 1261 /* The number of seconds of link inactivity after bonding before a link is disconnected. */ 1262 #ifndef L2CAP_BONDING_TIMEOUT 1263 #define L2CAP_BONDING_TIMEOUT 3 1264 #endif 1265 1266 /* The time from the HCI connection complete to disconnect if no channel is established. */ 1267 #ifndef L2CAP_LINK_STARTUP_TOUT 1268 #define L2CAP_LINK_STARTUP_TOUT 60 1269 #endif 1270 1271 /* The L2CAP MTU; must be in accord with the HCI ACL pool size. */ 1272 #ifndef L2CAP_MTU_SIZE 1273 #define L2CAP_MTU_SIZE 1691 1274 #endif 1275 1276 /* The L2CAP MPS over Bluetooth; must be in accord with the FCR tx pool size and ACL down buffer size. */ 1277 #ifndef L2CAP_MPS_OVER_BR_EDR 1278 #define L2CAP_MPS_OVER_BR_EDR 1010 1279 #endif 1280 1281 /* This is set to enable host flow control. */ 1282 #ifndef L2CAP_HOST_FLOW_CTRL 1283 #define L2CAP_HOST_FLOW_CTRL FALSE 1284 #endif 1285 1286 /* If host flow control enabled, this is the number of buffers the controller can have unacknowledged. */ 1287 #ifndef L2CAP_HOST_FC_ACL_BUFS 1288 #define L2CAP_HOST_FC_ACL_BUFS 20 1289 #endif 1290 1291 /* The percentage of the queue size allowed before a congestion event is sent to the L2CAP client (typically 120%). */ 1292 #ifndef L2CAP_FWD_CONG_THRESH 1293 #define L2CAP_FWD_CONG_THRESH 120 1294 #endif 1295 1296 /* This is set to enable L2CAP to take the ACL link out of park mode when ACL data is to be sent. */ 1297 #ifndef L2CAP_WAKE_PARKED_LINK 1298 #define L2CAP_WAKE_PARKED_LINK TRUE 1299 #endif 1300 1301 /* Whether link wants to be the master or the slave. */ 1302 #ifndef L2CAP_DESIRED_LINK_ROLE 1303 #define L2CAP_DESIRED_LINK_ROLE HCI_ROLE_SLAVE 1304 #endif 1305 1306 /* Include Non-Flushable Packet Boundary Flag feature of Lisbon */ 1307 #ifndef L2CAP_NON_FLUSHABLE_PB_INCLUDED 1308 #define L2CAP_NON_FLUSHABLE_PB_INCLUDED TRUE 1309 #endif 1310 1311 /* Minimum number of ACL credit for high priority link */ 1312 #ifndef L2CAP_HIGH_PRI_MIN_XMIT_QUOTA 1313 #define L2CAP_HIGH_PRI_MIN_XMIT_QUOTA 5 1314 #endif 1315 1316 /* used for monitoring HCI ACL credit management */ 1317 #ifndef L2CAP_HCI_FLOW_CONTROL_DEBUG 1318 #define L2CAP_HCI_FLOW_CONTROL_DEBUG TRUE 1319 #endif 1320 1321 /* Used for calculating transmit buffers off of */ 1322 #ifndef L2CAP_NUM_XMIT_BUFFS 1323 #define L2CAP_NUM_XMIT_BUFFS HCI_ACL_BUF_MAX 1324 #endif 1325 1326 /* Unicast Connectionless Data */ 1327 #ifndef L2CAP_UCD_INCLUDED 1328 #define L2CAP_UCD_INCLUDED FALSE 1329 #endif 1330 1331 /* Unicast Connectionless Data MTU */ 1332 #ifndef L2CAP_UCD_MTU 1333 #define L2CAP_UCD_MTU L2CAP_MTU_SIZE 1334 #endif 1335 1336 /* Unicast Connectionless Data Idle Timeout */ 1337 #ifndef L2CAP_UCD_IDLE_TIMEOUT 1338 #define L2CAP_UCD_IDLE_TIMEOUT 2 1339 #endif 1340 1341 /* Unicast Connectionless Data Idle Timeout */ 1342 #ifndef L2CAP_UCD_CH_PRIORITY 1343 #define L2CAP_UCD_CH_PRIORITY L2CAP_CHNL_PRIORITY_MEDIUM 1344 #endif 1345 1346 /* Max clients on Unicast Connectionless Data */ 1347 #ifndef L2CAP_MAX_UCD_CLIENTS 1348 #define L2CAP_MAX_UCD_CLIENTS 5 1349 #endif 1350 1351 /* Used for features using fixed channels; set to zero if no fixed channels supported (BLE, etc.) */ 1352 /* Excluding L2CAP signaling channel and UCD */ 1353 #ifndef L2CAP_NUM_FIXED_CHNLS 1354 #define L2CAP_NUM_FIXED_CHNLS 4 1355 #endif 1356 1357 /* First fixed channel supported */ 1358 #ifndef L2CAP_FIRST_FIXED_CHNL 1359 #define L2CAP_FIRST_FIXED_CHNL 3 1360 #endif 1361 1362 #ifndef L2CAP_LAST_FIXED_CHNL 1363 #define L2CAP_LAST_FIXED_CHNL (L2CAP_FIRST_FIXED_CHNL + L2CAP_NUM_FIXED_CHNLS - 1) 1364 #endif 1365 1366 /* Round Robin service channels in link */ 1367 #ifndef L2CAP_ROUND_ROBIN_CHANNEL_SERVICE 1368 #define L2CAP_ROUND_ROBIN_CHANNEL_SERVICE TRUE 1369 #endif 1370 1371 /* Used for calculating transmit buffers off of */ 1372 #ifndef L2CAP_NUM_XMIT_BUFFS 1373 #define L2CAP_NUM_XMIT_BUFFS HCI_ACL_BUF_MAX 1374 #endif 1375 1376 /* Used for features using fixed channels; set to zero if no fixed channels supported (BLE, etc.) */ 1377 #ifndef L2CAP_NUM_FIXED_CHNLS 1378 #define L2CAP_NUM_FIXED_CHNLS 1 1379 #endif 1380 1381 /* First fixed channel supported */ 1382 #ifndef L2CAP_FIRST_FIXED_CHNL 1383 #define L2CAP_FIRST_FIXED_CHNL 3 1384 #endif 1385 1386 #ifndef L2CAP_LAST_FIXED_CHNL 1387 #define L2CAP_LAST_FIXED_CHNL (L2CAP_FIRST_FIXED_CHNL + L2CAP_NUM_FIXED_CHNLS - 1) 1388 #endif 1389 1390 /* used for monitoring eL2CAP data flow */ 1391 #ifndef L2CAP_ERTM_STATS 1392 #define L2CAP_ERTM_STATS FALSE 1393 #endif 1394 1395 /* USED FOR FCR TEST ONLY: When TRUE generates bad tx and rx packets */ 1396 #ifndef L2CAP_CORRUPT_ERTM_PKTS 1397 #define L2CAP_CORRUPT_ERTM_PKTS FALSE 1398 #endif 1399 1400 /* Used for conformance testing ONLY: When TRUE lets scriptwrapper overwrite info response */ 1401 #ifndef L2CAP_CONFORMANCE_TESTING 1402 #define L2CAP_CONFORMANCE_TESTING FALSE 1403 #endif 1404 1405 1406 #ifndef TIMER_PARAM_TYPE 1407 #ifdef WIN2000 1408 #define TIMER_PARAM_TYPE void * 1409 #else 1410 #define TIMER_PARAM_TYPE UINT32 1411 #endif 1412 #endif 1413 1414 /****************************************************************************** 1415 ** 1416 ** BLE 1417 ** 1418 ******************************************************************************/ 1419 1420 #ifndef BLE_INCLUDED 1421 #define BLE_INCLUDED FALSE 1422 #endif 1423 1424 #ifndef LOCAL_BLE_CONTROLLER_ID 1425 #define LOCAL_BLE_CONTROLLER_ID (1) 1426 #endif 1427 1428 /****************************************************************************** 1429 ** 1430 ** ATT/GATT Protocol/Profile Settings 1431 ** 1432 ******************************************************************************/ 1433 #ifndef ATT_INCLUDED 1434 #define ATT_INCLUDED FALSE 1435 #endif 1436 1437 #ifndef ATT_DEBUG 1438 #define ATT_DEBUG FALSE 1439 #endif 1440 1441 #ifndef GATT_SERVER_ENABLED 1442 #define GATT_SERVER_ENABLED FALSE 1443 #endif 1444 1445 #ifndef GATT_CLIENT_ENABLED 1446 #define GATT_CLIENT_ENABLED FALSE 1447 #endif 1448 1449 #ifndef GATT_MAX_SR_PROFILES 1450 #define GATT_MAX_SR_PROFILES 32 /* max is 32 */ 1451 #endif 1452 1453 #ifndef GATT_MAX_APPS 1454 #define GATT_MAX_APPS 10 /* note: 2 apps used internally GATT and GAP */ 1455 #endif 1456 1457 #ifndef GATT_MAX_CL_PROFILES 1458 #define GATT_MAX_CL_PROFILES 4 1459 #endif 1460 1461 #ifndef GATT_MAX_PHY_CHANNEL 1462 #define GATT_MAX_PHY_CHANNEL 4 1463 #endif 1464 1465 /* Used for conformance testing ONLY */ 1466 #ifndef GATT_CONFORMANCE_TESTING 1467 #define GATT_CONFORMANCE_TESTING FALSE 1468 #endif 1469 1470 /* number of background connection device allowence, ideally to be the same as WL size 1471 */ 1472 #ifndef GATT_MAX_BG_CONN_DEV 1473 #define GATT_MAX_BG_CONN_DEV 32 1474 #endif 1475 1476 /****************************************************************************** 1477 ** 1478 ** SMP 1479 ** 1480 ******************************************************************************/ 1481 #ifndef SMP_INCLUDED 1482 #define SMP_INCLUDED FALSE 1483 #endif 1484 1485 #ifndef SMP_DEBUG 1486 #define SMP_DEBUG FALSE 1487 #endif 1488 1489 #ifndef SMP_DEFAULT_AUTH_REQ 1490 #define SMP_DEFAULT_AUTH_REQ SMP_AUTH_NB_ENC_ONLY 1491 #endif 1492 1493 #ifndef SMP_MAX_ENC_KEY_SIZE 1494 #define SMP_MAX_ENC_KEY_SIZE 16 1495 #endif 1496 1497 #ifndef SMP_MIN_ENC_KEY_SIZE 1498 #define SMP_MIN_ENC_KEY_SIZE 7 1499 #endif 1500 1501 /* Used for conformance testing ONLY */ 1502 #ifndef SMP_CONFORMANCE_TESTING 1503 #define SMP_CONFORMANCE_TESTING FALSE 1504 #endif 1505 1506 /****************************************************************************** 1507 ** 1508 ** SDP 1509 ** 1510 ******************************************************************************/ 1511 1512 /* This is set to enable SDP server functionality. */ 1513 #ifndef SDP_SERVER_ENABLED 1514 #define SDP_SERVER_ENABLED TRUE 1515 #endif 1516 1517 /* The maximum number of SDP records the server can support. */ 1518 #ifndef SDP_MAX_RECORDS 1519 #define SDP_MAX_RECORDS 20 1520 #endif 1521 1522 /* The maximum number of attributes in each record. */ 1523 #ifndef SDP_MAX_REC_ATTR 1524 //#if defined(HID_DEV_INCLUDED) && (HID_DEV_INCLUDED==TRUE) 1525 #define SDP_MAX_REC_ATTR 25 1526 //#else 1527 //#define SDP_MAX_REC_ATTR 13 1528 //#endif 1529 #endif 1530 1531 #ifndef SDP_MAX_PAD_LEN 1532 #define SDP_MAX_PAD_LEN 600 1533 #endif 1534 1535 /* The maximum length, in bytes, of an attribute. */ 1536 #ifndef SDP_MAX_ATTR_LEN 1537 //#if defined(HID_DEV_INCLUDED) && (HID_DEV_INCLUDED==TRUE) 1538 //#define SDP_MAX_ATTR_LEN 80 1539 //#else 1540 //#define SDP_MAX_ATTR_LEN 100 1541 //#endif 1542 #define SDP_MAX_ATTR_LEN 400 1543 #endif 1544 1545 /* The maximum number of attribute filters supported by SDP databases. */ 1546 #ifndef SDP_MAX_ATTR_FILTERS 1547 #define SDP_MAX_ATTR_FILTERS 15 1548 #endif 1549 1550 /* The maximum number of UUID filters supported by SDP databases. */ 1551 #ifndef SDP_MAX_UUID_FILTERS 1552 #define SDP_MAX_UUID_FILTERS 3 1553 #endif 1554 1555 /* This is set to enable SDP client functionality. */ 1556 #ifndef SDP_CLIENT_ENABLED 1557 #define SDP_CLIENT_ENABLED TRUE 1558 #endif 1559 1560 /* The maximum number of record handles retrieved in a search. */ 1561 #ifndef SDP_MAX_DISC_SERVER_RECS 1562 #define SDP_MAX_DISC_SERVER_RECS 21 1563 #endif 1564 1565 /* The size of a scratchpad buffer, in bytes, for storing the response to an attribute request. */ 1566 #ifndef SDP_MAX_LIST_BYTE_COUNT 1567 #define SDP_MAX_LIST_BYTE_COUNT 4096 1568 #endif 1569 1570 /* The maximum number of parameters in an SDP protocol element. */ 1571 #ifndef SDP_MAX_PROTOCOL_PARAMS 1572 #define SDP_MAX_PROTOCOL_PARAMS 2 1573 #endif 1574 1575 /* The maximum number of simultaneous client and server connections. */ 1576 #ifndef SDP_MAX_CONNECTIONS 1577 #define SDP_MAX_CONNECTIONS 4 1578 #endif 1579 1580 /* The MTU size for the L2CAP configuration. */ 1581 #ifndef SDP_MTU_SIZE 1582 #define SDP_MTU_SIZE 256 1583 #endif 1584 1585 /* The flush timeout for the L2CAP configuration. */ 1586 #ifndef SDP_FLUSH_TO 1587 #define SDP_FLUSH_TO 0xFFFF 1588 #endif 1589 1590 /* The name for security authorization. */ 1591 #ifndef SDP_SERVICE_NAME 1592 #define SDP_SERVICE_NAME "Service Discovery" 1593 #endif 1594 1595 /* The security level for BTM. */ 1596 #ifndef SDP_SECURITY_LEVEL 1597 #define SDP_SECURITY_LEVEL BTM_SEC_NONE 1598 #endif 1599 1600 /* Device identification feature. */ 1601 #ifndef SDP_DI_INCLUDED 1602 #define SDP_DI_INCLUDED TRUE 1603 #endif 1604 1605 /****************************************************************************** 1606 ** 1607 ** RFCOMM 1608 ** 1609 ******************************************************************************/ 1610 1611 #ifndef RFCOMM_INCLUDED 1612 #define RFCOMM_INCLUDED TRUE 1613 #endif 1614 1615 /* The maximum number of ports supported. */ 1616 #ifndef MAX_RFC_PORTS 1617 #define MAX_RFC_PORTS 30 1618 #endif 1619 1620 /* The maximum simultaneous links to different devices. */ 1621 #ifndef MAX_ACL_CONNECTIONS 1622 #define MAX_BD_CONNECTIONS 7 1623 #else 1624 #define MAX_BD_CONNECTIONS MAX_ACL_CONNECTIONS 1625 #endif 1626 1627 /* The port receive queue low watermark level, in bytes. */ 1628 #ifndef PORT_RX_LOW_WM 1629 #define PORT_RX_LOW_WM (BTA_RFC_MTU_SIZE * PORT_RX_BUF_LOW_WM) 1630 #endif 1631 1632 /* The port receive queue high watermark level, in bytes. */ 1633 #ifndef PORT_RX_HIGH_WM 1634 #define PORT_RX_HIGH_WM (BTA_RFC_MTU_SIZE * PORT_RX_BUF_HIGH_WM) 1635 #endif 1636 1637 /* The port receive queue critical watermark level, in bytes. */ 1638 #ifndef PORT_RX_CRITICAL_WM 1639 #define PORT_RX_CRITICAL_WM (BTA_RFC_MTU_SIZE * PORT_RX_BUF_CRITICAL_WM) 1640 #endif 1641 1642 /* The port receive queue low watermark level, in number of buffers. */ 1643 #ifndef PORT_RX_BUF_LOW_WM 1644 #define PORT_RX_BUF_LOW_WM 4 1645 #endif 1646 1647 /* The port receive queue high watermark level, in number of buffers. */ 1648 #ifndef PORT_RX_BUF_HIGH_WM 1649 #define PORT_RX_BUF_HIGH_WM 10 1650 #endif 1651 1652 /* The port receive queue critical watermark level, in number of buffers. */ 1653 #ifndef PORT_RX_BUF_CRITICAL_WM 1654 #define PORT_RX_BUF_CRITICAL_WM 15 1655 #endif 1656 1657 /* The port transmit queue high watermark level, in bytes. */ 1658 #ifndef PORT_TX_HIGH_WM 1659 #define PORT_TX_HIGH_WM (BTA_RFC_MTU_SIZE * PORT_TX_BUF_HIGH_WM) 1660 #endif 1661 1662 /* The port transmit queue critical watermark level, in bytes. */ 1663 #ifndef PORT_TX_CRITICAL_WM 1664 #define PORT_TX_CRITICAL_WM (BTA_RFC_MTU_SIZE * PORT_TX_BUF_CRITICAL_WM) 1665 #endif 1666 1667 /* The port transmit queue high watermark level, in number of buffers. */ 1668 #ifndef PORT_TX_BUF_HIGH_WM 1669 #define PORT_TX_BUF_HIGH_WM 10 1670 #endif 1671 1672 /* The port transmit queue high watermark level, in number of buffers. */ 1673 #ifndef PORT_TX_BUF_CRITICAL_WM 1674 #define PORT_TX_BUF_CRITICAL_WM 15 1675 #endif 1676 1677 /* The RFCOMM multiplexer preferred flow control mechanism. */ 1678 #ifndef PORT_FC_DEFAULT 1679 #define PORT_FC_DEFAULT PORT_FC_CREDIT 1680 #endif 1681 1682 /* The maximum number of credits receiver sends to peer when using credit-based flow control. */ 1683 #ifndef PORT_CREDIT_RX_MAX 1684 #define PORT_CREDIT_RX_MAX 16 1685 #endif 1686 1687 /* The credit low watermark level. */ 1688 #ifndef PORT_CREDIT_RX_LOW 1689 #define PORT_CREDIT_RX_LOW 8 1690 #endif 1691 1692 /* Test code allowing l2cap FEC on RFCOMM.*/ 1693 #ifndef PORT_ENABLE_L2CAP_FCR_TEST 1694 #define PORT_ENABLE_L2CAP_FCR_TEST FALSE 1695 #endif 1696 1697 /* if application like BTA, Java or script test engine is running on other than BTU thread, */ 1698 /* PORT_SCHEDULE_LOCK shall be defined as GKI_sched_lock() or GKI_disable() */ 1699 #ifndef PORT_SCHEDULE_LOCK 1700 #define PORT_SCHEDULE_LOCK GKI_disable() 1701 #endif 1702 1703 /* if application like BTA, Java or script test engine is running on other than BTU thread, */ 1704 /* PORT_SCHEDULE_LOCK shall be defined as GKI_sched_unlock() or GKI_enable() */ 1705 #ifndef PORT_SCHEDULE_UNLOCK 1706 #define PORT_SCHEDULE_UNLOCK GKI_enable() 1707 #endif 1708 1709 /****************************************************************************** 1710 ** 1711 ** TCS 1712 ** 1713 ******************************************************************************/ 1714 1715 #ifndef TCS_INCLUDED 1716 #define TCS_INCLUDED FALSE 1717 #endif 1718 1719 /* If set to TRUE, gives lean TCS state machine configuration. */ 1720 #ifndef TCS_LEAN 1721 #define TCS_LEAN FALSE 1722 #endif 1723 1724 /* To include/exclude point-to-multipoint broadcast SETUP configuration. */ 1725 #ifndef TCS_BCST_SETUP_INCLUDED 1726 #define TCS_BCST_SETUP_INCLUDED TRUE 1727 #endif 1728 1729 /* To include/exclude supplementary services. */ 1730 #ifndef TCS_SUPP_SVCS_INCLUDED 1731 #define TCS_SUPP_SVCS_INCLUDED TRUE 1732 #endif 1733 1734 /* To include/exclude WUG master role. */ 1735 #ifndef TCS_WUG_MASTER_INCLUDED 1736 #define TCS_WUG_MASTER_INCLUDED TRUE 1737 #endif 1738 1739 /* To include/exclude WUG member role. */ 1740 #ifndef TCS_WUG_MEMBER_INCLUDED 1741 #define TCS_WUG_MEMBER_INCLUDED TRUE 1742 #endif 1743 1744 /* Maximum number of WUG members. */ 1745 #ifndef TCS_MAX_WUG_MEMBERS 1746 #define TCS_MAX_WUG_MEMBERS 7 1747 #endif 1748 1749 /* Broadcom specific acknowledgement message to ensure fast and robust operation of WUG FIMA procedure. */ 1750 #ifndef TCS_WUG_LISTEN_ACPT_ACK_INCLUDED 1751 #define TCS_WUG_LISTEN_ACPT_ACK_INCLUDED TRUE 1752 #endif 1753 1754 /* The number of simultaneous calls supported. */ 1755 #ifndef TCS_MAX_NUM_SIMUL_CALLS 1756 #define TCS_MAX_NUM_SIMUL_CALLS 3 1757 #endif 1758 1759 /* The number of devices the device can connect to. */ 1760 #ifndef TCS_MAX_NUM_ACL_CONNS 1761 #define TCS_MAX_NUM_ACL_CONNS 7 1762 #endif 1763 1764 /* The maximum length, in bytes, of the company specific information element. */ 1765 #ifndef TCS_MAX_CO_SPEC_LEN 1766 #define TCS_MAX_CO_SPEC_LEN 40 1767 #endif 1768 1769 /* The maximum length, in bytes, of the audio control information element . */ 1770 #ifndef TCS_MAX_AUDIO_CTL_LEN 1771 #define TCS_MAX_AUDIO_CTL_LEN 40 1772 #endif 1773 1774 /* (Dis)allow EDR ESCO */ 1775 #ifndef TCS_AUDIO_USE_ESCO_EDR 1776 #define TCS_AUDIO_USE_ESCO_EDR FALSE 1777 #endif 1778 1779 /****************************************************************************** 1780 ** 1781 ** OBX 1782 ** 1783 ******************************************************************************/ 1784 #ifndef OBX_INCLUDED 1785 #define OBX_INCLUDED FALSE 1786 #endif 1787 1788 #ifndef OBX_CLIENT_INCLUDED 1789 #define OBX_CLIENT_INCLUDED TRUE 1790 #endif 1791 1792 #ifndef OBX_SERVER_INCLUDED 1793 #define OBX_SERVER_INCLUDED TRUE 1794 #endif 1795 1796 /* TRUE to include OBEX authentication/MD5 code */ 1797 #ifndef OBX_MD5_INCLUDED 1798 #define OBX_MD5_INCLUDED TRUE 1799 #endif 1800 1801 /* TRUE to include OBEX authentication/MD5 test code */ 1802 #ifndef OBX_MD5_TEST_INCLUDED 1803 #define OBX_MD5_TEST_INCLUDED FALSE 1804 #endif 1805 1806 /* TRUE to include OBEX 1.4 enhancement (including Obex Over L2CAP) */ 1807 #ifndef OBX_14_INCLUDED 1808 #define OBX_14_INCLUDED FALSE 1809 #endif 1810 /* MD5 code is required to use OBEX 1.4 features (Reliable session) */ 1811 #if (OBX_MD5_INCLUDED == FALSE) 1812 #undef OBX_14_INCLUDED 1813 #define OBX_14_INCLUDED FALSE 1814 #endif 1815 1816 /* L2CAP FCR/eRTM mode is required to use OBEX Over L2CAP */ 1817 #if (L2CAP_FCR_INCLUDED == FALSE) 1818 #undef OBX_14_INCLUDED 1819 #define OBX_14_INCLUDED FALSE 1820 #endif 1821 1822 /* The timeout value (in seconds) for reliable sessions to remain in suspend. 0xFFFFFFFF for no timeout event. */ 1823 #ifndef OBX_SESS_TIMEOUT_VALUE 1824 #define OBX_SESS_TIMEOUT_VALUE 600 1825 #endif 1826 1827 /* The idle timeout value. 0 for no timeout event. */ 1828 #ifndef OBX_TIMEOUT_VALUE 1829 #define OBX_TIMEOUT_VALUE 60 1830 #endif 1831 1832 /* Timeout value used for disconnect */ 1833 #ifndef OBX_DISC_TOUT_VALUE 1834 #define OBX_DISC_TOUT_VALUE 5 1835 #endif 1836 1837 /* The maximum number of registered servers. */ 1838 #ifndef OBX_NUM_SERVERS 1839 #define OBX_NUM_SERVERS 12 1840 #endif 1841 1842 /* The maximum number of sessions per registered server. */ 1843 #ifndef OBX_MAX_SR_SESSION 1844 #define OBX_MAX_SR_SESSION 4 1845 #endif 1846 1847 /* The maximum number of sessions for all registered servers. 1848 * (must be equal or bigger than OBX_NUM_SERVERS) */ 1849 #ifndef OBX_NUM_SR_SESSIONS 1850 #define OBX_NUM_SR_SESSIONS 26 1851 #endif 1852 1853 /* The maximum number of sessions per registered server. 1854 * must be less than MAX_BD_CONNECTIONS */ 1855 #ifndef OBX_MAX_SR_SESSION 1856 #define OBX_MAX_SR_SESSION 4 1857 #endif 1858 1859 /* The maximum number of suspended sessions per registered servers. */ 1860 #ifndef OBX_MAX_SUSPEND_SESSIONS 1861 #define OBX_MAX_SUSPEND_SESSIONS 4 1862 #endif 1863 1864 /* The maximum number of active clients. */ 1865 #ifndef OBX_NUM_CLIENTS 1866 #define OBX_NUM_CLIENTS 8 1867 #endif 1868 1869 /* The maximum length of OBEX target header.*/ 1870 #ifndef OBX_MAX_TARGET_LEN 1871 #define OBX_MAX_TARGET_LEN 16 1872 #endif 1873 1874 /* The maximum length of authentication challenge realm.*/ 1875 #ifndef OBX_MAX_REALM_LEN 1876 #define OBX_MAX_REALM_LEN 30 1877 #endif 1878 1879 /* The maximum of GKI buffer queued at OBX before flow control L2CAP */ 1880 #ifndef OBX_MAX_RX_QUEUE_COUNT 1881 #define OBX_MAX_RX_QUEUE_COUNT 3 1882 #endif 1883 1884 /* This option is application when OBX_14_INCLUDED=TRUE 1885 Pool ID where to reassemble the SDU. 1886 This Pool will allow buffers to be used that are larger than 1887 the L2CAP_MAX_MTU. */ 1888 #ifndef OBX_USER_RX_POOL_ID 1889 #define OBX_USER_RX_POOL_ID OBX_LRG_DATA_POOL_ID 1890 #endif 1891 1892 /* This option is application when OBX_14_INCLUDED=TRUE 1893 Pool ID where to hold the SDU. 1894 This Pool will allow buffers to be used that are larger than 1895 the L2CAP_MAX_MTU. */ 1896 #ifndef OBX_USER_TX_POOL_ID 1897 #define OBX_USER_TX_POOL_ID OBX_LRG_DATA_POOL_ID 1898 #endif 1899 1900 /* This option is application when OBX_14_INCLUDED=TRUE 1901 GKI Buffer Pool ID used to hold MPS segments during SDU reassembly 1902 */ 1903 #ifndef OBX_FCR_RX_POOL_ID 1904 #define OBX_FCR_RX_POOL_ID HCI_ACL_POOL_ID 1905 #endif 1906 1907 /* This option is application when OBX_14_INCLUDED=TRUE 1908 GKI Buffer Pool ID used to hold MPS segments used in (re)transmissions. 1909 L2CAP_DEFAULT_ERM_POOL_ID is specified to use the HCI ACL data pool. 1910 Note: This pool needs to have enough buffers to hold two times the window size negotiated 1911 in the L2CA_SetFCROptions (2 * tx_win_size) to allow for retransmissions. 1912 The size of each buffer must be able to hold the maximum MPS segment size passed in 1913 L2CA_SetFCROptions plus BT_HDR (8) + HCI preamble (4) + L2CAP_MIN_OFFSET (11 - as of BT 2.1 + EDR Spec). 1914 */ 1915 #ifndef OBX_FCR_TX_POOL_ID 1916 #define OBX_FCR_TX_POOL_ID HCI_ACL_POOL_ID 1917 #endif 1918 1919 /* This option is application when OBX_14_INCLUDED=TRUE 1920 Size of the transmission window when using enhanced retransmission mode. Not used 1921 in basic and streaming modes. Range: 1 - 63 1922 */ 1923 #ifndef OBX_FCR_OPT_TX_WINDOW_SIZE_BR_EDR 1924 #define OBX_FCR_OPT_TX_WINDOW_SIZE_BR_EDR 20 1925 #endif 1926 1927 /* This option is application when OBX_14_INCLUDED=TRUE 1928 Number of transmission attempts for a single I-Frame before taking 1929 Down the connection. Used In ERTM mode only. Value is Ignored in basic and 1930 Streaming modes. 1931 Range: 0, 1-0xFF 1932 0 - infinite retransmissions 1933 1 - single transmission 1934 */ 1935 #ifndef OBX_FCR_OPT_MAX_TX_B4_DISCNT 1936 #define OBX_FCR_OPT_MAX_TX_B4_DISCNT 20 1937 #endif 1938 1939 /* This option is application when OBX_14_INCLUDED=TRUE 1940 Retransmission Timeout 1941 Range: Minimum 2000 (2 secs) on BR/EDR when supporting PBF. 1942 */ 1943 #ifndef OBX_FCR_OPT_RETX_TOUT 1944 #define OBX_FCR_OPT_RETX_TOUT 2000 1945 #endif 1946 1947 /* This option is application when OBX_14_INCLUDED=TRUE 1948 Monitor Timeout 1949 Range: Minimum 12000 (12 secs) on BR/EDR when supporting PBF. 1950 */ 1951 #ifndef OBX_FCR_OPT_MONITOR_TOUT 1952 #define OBX_FCR_OPT_MONITOR_TOUT 12000 1953 #endif 1954 1955 /****************************************************************************** 1956 ** 1957 ** BNEP 1958 ** 1959 ******************************************************************************/ 1960 1961 #ifndef BNEP_INCLUDED 1962 #define BNEP_INCLUDED TRUE 1963 #endif 1964 1965 /* Protocol filtering is an optional feature. Bydefault it will be turned on */ 1966 #ifndef BNEP_SUPPORTS_PROT_FILTERS 1967 #define BNEP_SUPPORTS_PROT_FILTERS TRUE 1968 #endif 1969 1970 /* Multicast filtering is an optional feature. Bydefault it will be turned on */ 1971 #ifndef BNEP_SUPPORTS_MULTI_FILTERS 1972 #define BNEP_SUPPORTS_MULTI_FILTERS TRUE 1973 #endif 1974 1975 /* BNEP status API call is used mainly to get the L2CAP handle */ 1976 #ifndef BNEP_SUPPORTS_STATUS_API 1977 #define BNEP_SUPPORTS_STATUS_API TRUE 1978 #endif 1979 1980 /* This is just a debug function */ 1981 #ifndef BNEP_SUPPORTS_DEBUG_DUMP 1982 #define BNEP_SUPPORTS_DEBUG_DUMP TRUE 1983 #endif 1984 1985 #ifndef BNEP_SUPPORTS_ALL_UUID_LENGTHS 1986 #define BNEP_SUPPORTS_ALL_UUID_LENGTHS TRUE /* Otherwise it will support only 16bit UUIDs */ 1987 #endif 1988 1989 /* 1990 ** When BNEP connection changes roles after the connection is established 1991 ** we will do an authentication check again on the new role 1992 */ 1993 #ifndef BNEP_DO_AUTH_FOR_ROLE_SWITCH 1994 #define BNEP_DO_AUTH_FOR_ROLE_SWITCH TRUE 1995 #endif 1996 1997 1998 /* Maximum number of protocol filters supported. */ 1999 #ifndef BNEP_MAX_PROT_FILTERS 2000 #define BNEP_MAX_PROT_FILTERS 5 2001 #endif 2002 2003 /* Maximum number of multicast filters supported. */ 2004 #ifndef BNEP_MAX_MULTI_FILTERS 2005 #define BNEP_MAX_MULTI_FILTERS 5 2006 #endif 2007 2008 /* Minimum MTU size. */ 2009 #ifndef BNEP_MIN_MTU_SIZE 2010 #define BNEP_MIN_MTU_SIZE L2CAP_MTU_SIZE 2011 #endif 2012 2013 /* Preferred MTU size. */ 2014 #ifndef BNEP_MTU_SIZE 2015 #define BNEP_MTU_SIZE BNEP_MIN_MTU_SIZE 2016 #endif 2017 2018 /* Maximum size of user data, in bytes. */ 2019 #ifndef BNEP_MAX_USER_DATA_SIZE 2020 #define BNEP_MAX_USER_DATA_SIZE 1500 2021 #endif 2022 2023 /* Maximum number of buffers allowed in transmit data queue. */ 2024 #ifndef BNEP_MAX_XMITQ_DEPTH 2025 #define BNEP_MAX_XMITQ_DEPTH 20 2026 #endif 2027 2028 /* Maximum number BNEP of connections supported. */ 2029 #ifndef BNEP_MAX_CONNECTIONS 2030 #define BNEP_MAX_CONNECTIONS 7 2031 #endif 2032 2033 2034 /****************************************************************************** 2035 ** 2036 ** AVDTP 2037 ** 2038 ******************************************************************************/ 2039 2040 #ifndef AVDT_INCLUDED 2041 #define AVDT_INCLUDED TRUE 2042 #endif 2043 2044 /* Include reporting capability in AVDTP */ 2045 #ifndef AVDT_REPORTING 2046 #define AVDT_REPORTING TRUE 2047 #endif 2048 2049 /* Include multiplexing capability in AVDTP */ 2050 #ifndef AVDT_MULTIPLEXING 2051 #define AVDT_MULTIPLEXING TRUE 2052 #endif 2053 2054 /* Number of simultaneous links to different peer devices. */ 2055 #ifndef AVDT_NUM_LINKS 2056 #define AVDT_NUM_LINKS 2 2057 #endif 2058 2059 /* Number of simultaneous stream endpoints. */ 2060 #ifndef AVDT_NUM_SEPS 2061 #define AVDT_NUM_SEPS 3 2062 #endif 2063 2064 /* Number of transport channels setup per media stream(audio or video) */ 2065 #ifndef AVDT_NUM_CHANNELS 2066 2067 #if AVDT_REPORTING == TRUE 2068 /* signaling, media and reporting channels */ 2069 #define AVDT_NUM_CHANNELS 3 2070 #else 2071 /* signaling and media channels */ 2072 #define AVDT_NUM_CHANNELS 2 2073 #endif 2074 2075 #endif 2076 2077 /* Number of transport channels setup by AVDT for all media streams 2078 * AVDT_NUM_CHANNELS * Number of simultaneous streams. 2079 */ 2080 #ifndef AVDT_NUM_TC_TBL 2081 #define AVDT_NUM_TC_TBL 6 2082 #endif 2083 2084 2085 /* Maximum size in bytes of the codec capabilities information element. */ 2086 #ifndef AVDT_CODEC_SIZE 2087 #define AVDT_CODEC_SIZE 10 2088 #endif 2089 2090 /* Maximum size in bytes of the content protection information element. */ 2091 #ifndef AVDT_PROTECT_SIZE 2092 #define AVDT_PROTECT_SIZE 90 2093 #endif 2094 2095 /* Maximum number of GKI buffers in the fragment queue (for video frames). 2096 * Must be less than the number of buffers in the buffer pool of size AVDT_DATA_POOL_SIZE */ 2097 #ifndef AVDT_MAX_FRAG_COUNT 2098 #define AVDT_MAX_FRAG_COUNT 15 2099 #endif 2100 2101 /****************************************************************************** 2102 ** 2103 ** PAN 2104 ** 2105 ******************************************************************************/ 2106 2107 #ifndef PAN_INCLUDED 2108 #define PAN_INCLUDED TRUE 2109 #endif 2110 2111 /* This will enable the PANU role */ 2112 #ifndef PAN_SUPPORTS_ROLE_PANU 2113 #define PAN_SUPPORTS_ROLE_PANU TRUE 2114 #endif 2115 2116 /* This will enable the GN role */ 2117 #ifndef PAN_SUPPORTS_ROLE_GN 2118 #define PAN_SUPPORTS_ROLE_GN TRUE 2119 #endif 2120 2121 /* This will enable the NAP role */ 2122 #ifndef PAN_SUPPORTS_ROLE_NAP 2123 #define PAN_SUPPORTS_ROLE_NAP TRUE 2124 #endif 2125 2126 /* This is just for debugging purposes */ 2127 #ifndef PAN_SUPPORTS_DEBUG_DUMP 2128 #define PAN_SUPPORTS_DEBUG_DUMP TRUE 2129 #endif 2130 2131 2132 /* Maximum number of PAN connections allowed */ 2133 #ifndef MAX_PAN_CONNS 2134 #define MAX_PAN_CONNS 7 2135 #endif 2136 2137 /* Default service name for NAP role */ 2138 #ifndef PAN_NAP_DEFAULT_SERVICE_NAME 2139 #define PAN_NAP_DEFAULT_SERVICE_NAME "Network Access Point Service" 2140 #endif 2141 2142 /* Default service name for GN role */ 2143 #ifndef PAN_GN_DEFAULT_SERVICE_NAME 2144 #define PAN_GN_DEFAULT_SERVICE_NAME "Group Network Service" 2145 #endif 2146 2147 /* Default service name for PANU role */ 2148 #ifndef PAN_PANU_DEFAULT_SERVICE_NAME 2149 #define PAN_PANU_DEFAULT_SERVICE_NAME "PAN User Service" 2150 #endif 2151 2152 /* Default description for NAP role service */ 2153 #ifndef PAN_NAP_DEFAULT_DESCRIPTION 2154 #define PAN_NAP_DEFAULT_DESCRIPTION "NAP" 2155 #endif 2156 2157 /* Default description for GN role service */ 2158 #ifndef PAN_GN_DEFAULT_DESCRIPTION 2159 #define PAN_GN_DEFAULT_DESCRIPTION "GN" 2160 #endif 2161 2162 /* Default description for PANU role service */ 2163 #ifndef PAN_PANU_DEFAULT_DESCRIPTION 2164 #define PAN_PANU_DEFAULT_DESCRIPTION "PANU" 2165 #endif 2166 2167 /* Default Security level for PANU role. */ 2168 #ifndef PAN_PANU_SECURITY_LEVEL 2169 #define PAN_PANU_SECURITY_LEVEL 0 2170 #endif 2171 2172 /* Default Security level for GN role. */ 2173 #ifndef PAN_GN_SECURITY_LEVEL 2174 #define PAN_GN_SECURITY_LEVEL 0 2175 #endif 2176 2177 /* Default Security level for NAP role. */ 2178 #ifndef PAN_NAP_SECURITY_LEVEL 2179 #define PAN_NAP_SECURITY_LEVEL 0 2180 #endif 2181 2182 2183 2184 2185 /****************************************************************************** 2186 ** 2187 ** GAP 2188 ** 2189 ******************************************************************************/ 2190 2191 #ifndef GAP_INCLUDED 2192 #define GAP_INCLUDED FALSE 2193 #endif 2194 2195 /* This is set to enable use of GAP L2CAP connections. */ 2196 #ifndef GAP_CONN_INCLUDED 2197 #define GAP_CONN_INCLUDED TRUE 2198 #endif 2199 2200 /* This is set to enable posting event for data write */ 2201 #ifndef GAP_CONN_POST_EVT_INCLUDED 2202 #define GAP_CONN_POST_EVT_INCLUDED FALSE 2203 #endif 2204 2205 /* The maximum number of simultaneous GAP L2CAP connections. */ 2206 #ifndef GAP_MAX_CONNECTIONS 2207 #define GAP_MAX_CONNECTIONS 8 2208 #endif 2209 2210 /****************************************************************************** 2211 ** 2212 ** CTP 2213 ** 2214 ******************************************************************************/ 2215 2216 #ifndef CTP_INCLUDED 2217 #define CTP_INCLUDED FALSE 2218 #endif 2219 2220 /* To include CTP gateway functionality or not. */ 2221 #ifndef CTP_GW_INCLUDED 2222 #define CTP_GW_INCLUDED TRUE 2223 #endif 2224 2225 /* The number of terminals supported. */ 2226 #ifndef CTP_MAX_NUM_TLS 2227 #define CTP_MAX_NUM_TLS 7 2228 #endif 2229 2230 /* If the controller can not support sniff mode when the SCO is up, set this to FALSE. */ 2231 #ifndef CTP_USE_SNIFF_ON_SCO 2232 #define CTP_USE_SNIFF_ON_SCO FALSE 2233 #endif 2234 2235 /* When ACL link between TL and GW is idle for more than this amount of seconds, the ACL may be put to low power mode. */ 2236 #ifndef CTP_TL_IDLE_TIMEOUT 2237 #define CTP_TL_IDLE_TIMEOUT 90 2238 #endif 2239 2240 /* To include CTP terminal functionality or not. */ 2241 #ifndef CTP_TL_INCLUDED 2242 #define CTP_TL_INCLUDED TRUE 2243 #endif 2244 2245 /* To include CTP device discovery functionality or not. */ 2246 #ifndef CTP_DISCOVERY_INCLUDED 2247 #define CTP_DISCOVERY_INCLUDED TRUE 2248 #endif 2249 2250 /* set to TRUE for controllers that do not support multi-point */ 2251 #ifndef CTP_TL_WAIT_DISC 2252 #define CTP_TL_WAIT_DISC TRUE 2253 #endif 2254 2255 /* The CTP inquiry database size. */ 2256 #ifndef CTP_INQ_DB_SIZE 2257 #define CTP_INQ_DB_SIZE CTP_DISC_REC_SIZE 2258 #endif 2259 2260 /* The CTP discovery record size. */ 2261 #ifndef CTP_DISC_REC_SIZE 2262 #define CTP_DISC_REC_SIZE 60 2263 #endif 2264 2265 /* CTP TL would try to re-establish L2CAP channel after channel is disconnected for this amount of seconds. */ 2266 #ifndef CTP_GUARD_LINK_LOST 2267 #define CTP_GUARD_LINK_LOST 1 2268 #endif 2269 2270 /* The link policy bitmap. */ 2271 #ifndef CTP_DEFAULT_LINK_POLICY 2272 #define CTP_DEFAULT_LINK_POLICY 0x000F 2273 #endif 2274 2275 /* The minimum period interval used for the sniff and park modes. */ 2276 #ifndef CTP_DEF_LOWPWR_MIN_PERIOD 2277 #define CTP_DEF_LOWPWR_MIN_PERIOD 0x100 2278 #endif 2279 2280 /* The maximum period interval used for the sniff and park modes. */ 2281 #ifndef CTP_DEF_LOWPWR_MAX_PERIOD 2282 #define CTP_DEF_LOWPWR_MAX_PERIOD 0x1E0 2283 #endif 2284 2285 /* The number of baseband receive slot sniff attempts. */ 2286 #ifndef CTP_DEF_LOWPWR_ATTEMPT 2287 #define CTP_DEF_LOWPWR_ATTEMPT 0x200 2288 #endif 2289 2290 /* The number of baseband receive slots for sniff timeout. */ 2291 #ifndef CTP_DEF_LOWPWR_TIMEOUT 2292 #define CTP_DEF_LOWPWR_TIMEOUT 0x200 2293 #endif 2294 2295 /* This is set if CTP is to use park mode. */ 2296 #ifndef CTP_PARK_INCLUDED 2297 #define CTP_PARK_INCLUDED TRUE 2298 #endif 2299 2300 /* This is set if CTP is to use sniff mode. */ 2301 #ifndef CTP_SNIFF_INCLUDED 2302 #define CTP_SNIFF_INCLUDED TRUE 2303 #endif 2304 2305 /* To include CTP data exchange functionality or not. */ 2306 #ifndef CTP_DATA_EXCHG_FEATURE 2307 #define CTP_DATA_EXCHG_FEATURE FALSE 2308 #endif 2309 2310 /* To include CTP GW intercom functionality or not. */ 2311 #ifndef CTP_GW_INTERCOM_FEATURE 2312 #define CTP_GW_INTERCOM_FEATURE FALSE 2313 #endif 2314 2315 /* The MTU size for L2CAP channel. */ 2316 #ifndef CTP_MTU_SIZE 2317 #define CTP_MTU_SIZE 200 2318 #endif 2319 2320 /* The L2CAP PSM for the data exchange feature. */ 2321 #ifndef CTP_DATA_EXCHG_PSM 2322 #define CTP_DATA_EXCHG_PSM 13 2323 #endif 2324 2325 /* The flush timeout for L2CAP channels. */ 2326 #ifndef CTP_FLUSH_TO 2327 #define CTP_FLUSH_TO 0xFFFF 2328 #endif 2329 2330 /* The default service name for CTP. */ 2331 #ifndef CTP_DEFAULT_SERVICE_NAME 2332 #define CTP_DEFAULT_SERVICE_NAME "Cordless Telephony" 2333 #endif 2334 2335 /* The CTP security level. */ 2336 #ifndef CTP_SECURITY_LEVEL 2337 #define CTP_SECURITY_LEVEL (BTM_SEC_IN_AUTHORIZE | BTM_SEC_IN_AUTHENTICATE | BTM_SEC_IN_ENCRYPT) 2338 #endif 2339 2340 /* The number of lines to the external network. */ 2341 #ifndef CTP_MAX_LINES 2342 #define CTP_MAX_LINES 1 2343 #endif 2344 2345 /* Test if the number of resources in TCS is consistent with CTP setting. */ 2346 #ifndef CTP_TEST_FULL_TCS 2347 #define CTP_TEST_FULL_TCS TRUE 2348 #endif 2349 2350 /* The default inquiry mode. */ 2351 #ifndef CTP_DEFAULT_INQUIRY_MODE 2352 #define CTP_DEFAULT_INQUIRY_MODE BTM_GENERAL_INQUIRY 2353 #endif 2354 2355 /* The default inquiry duration. */ 2356 #ifndef CTP_DEFAULT_INQ_DURATION 2357 #define CTP_DEFAULT_INQ_DURATION 4 2358 #endif 2359 2360 /* The maximum number of inquiry responses. */ 2361 #ifndef CTP_DEFAULT_INQ_MAX_RESP 2362 #define CTP_DEFAULT_INQ_MAX_RESP 3 2363 #endif 2364 2365 /* When TL does not create another L2CAP channel within this period of time GW declares that it's "Connected Limited". */ 2366 #ifndef CTP_TL_CONN_TIMEOUT 2367 #define CTP_TL_CONN_TIMEOUT 5 2368 #endif 2369 2370 /* The delay for ACL to completely disconnect (for intercom) before sending the connect request to GW. */ 2371 #ifndef CTP_RECONNECT_DELAY 2372 #define CTP_RECONNECT_DELAY 5 2373 #endif 2374 2375 /* How many times to retry connection when it has failed. */ 2376 #ifndef CTP_RETRY_ON_CONN_ERR 2377 #define CTP_RETRY_ON_CONN_ERR 5 2378 #endif 2379 2380 /****************************************************************************** 2381 ** 2382 ** ICP 2383 ** 2384 ******************************************************************************/ 2385 2386 #ifndef ICP_INCLUDED 2387 #define ICP_INCLUDED FALSE 2388 #endif 2389 2390 /* The ICP default MTU. */ 2391 #ifndef ICP_MTU_SIZE 2392 #define ICP_MTU_SIZE 100 2393 #endif 2394 2395 /* The ICP security level. */ 2396 #ifndef ICP_SECURITY_LEVEL 2397 #define ICP_SECURITY_LEVEL BTM_SEC_NONE 2398 #endif 2399 2400 /* The default service name for ICP. */ 2401 #ifndef ICP_DEFAULT_SERVICE_NAME 2402 #define ICP_DEFAULT_SERVICE_NAME "Intercom" 2403 #endif 2404 2405 /* The flush timeout for L2CAP channels. */ 2406 #ifndef ICP_FLUSH_TO 2407 #define ICP_FLUSH_TO 0xFFFF 2408 #endif 2409 2410 /****************************************************************************** 2411 ** 2412 ** SPP 2413 ** 2414 ******************************************************************************/ 2415 2416 #ifndef SPP_INCLUDED 2417 #define SPP_INCLUDED FALSE 2418 #endif 2419 2420 /* The SPP default MTU. */ 2421 #ifndef SPP_DEFAULT_MTU 2422 #define SPP_DEFAULT_MTU 127 2423 #endif 2424 2425 /* The interval, in seconds, that a client tries to reconnect to a service. */ 2426 #ifndef SPP_RETRY_CONN_INTERVAL 2427 #define SPP_RETRY_CONN_INTERVAL 1 2428 #endif 2429 2430 /* The SPP discoverable mode: limited or general. */ 2431 #ifndef SPP_DISCOVERABLE_MODE 2432 #define SPP_DISCOVERABLE_MODE BTM_GENERAL_DISCOVERABLE 2433 #endif 2434 2435 /* The maximum number of inquiry results returned in by inquiry procedure. */ 2436 #ifndef SPP_DEF_INQ_MAX_RESP 2437 #define SPP_DEF_INQ_MAX_RESP 10 2438 #endif 2439 2440 /* The SPP discovery record size. */ 2441 #ifndef SPP_DISC_REC_SIZE 2442 #define SPP_DISC_REC_SIZE 60 2443 #endif 2444 2445 #ifndef SPP_MAX_RECS_PER_DEVICE 2446 #define SPP_MAX_RECS_PER_DEVICE (SPP_DB_SIZE / SPP_DISC_REC_SIZE) 2447 #endif 2448 2449 /* Inquiry duration in 1.28 second units. */ 2450 #ifndef SPP_DEF_INQ_DURATION 2451 #define SPP_DEF_INQ_DURATION 9 2452 #endif 2453 2454 /* keep the raw data received from SDP server in database. */ 2455 #ifndef SDP_RAW_DATA_INCLUDED 2456 #define SDP_RAW_DATA_INCLUDED TRUE 2457 #endif 2458 2459 /* TRUE, to allow JV to create L2CAP connection on SDP PSM. */ 2460 #ifndef SDP_FOR_JV_INCLUDED 2461 #define SDP_FOR_JV_INCLUDED FALSE 2462 #endif 2463 2464 /* Inquiry duration in 1.28 second units. */ 2465 #ifndef SDP_DEBUG 2466 #define SDP_DEBUG TRUE 2467 #endif 2468 2469 /****************************************************************************** 2470 ** 2471 ** HSP2, HFP 2472 ** 2473 ******************************************************************************/ 2474 2475 #ifndef HSP2_INCLUDED 2476 #define HSP2_INCLUDED FALSE 2477 #endif 2478 2479 /* Include the ability to perform inquiry for peer devices. */ 2480 #ifndef HSP2_INQUIRY_INCLUDED 2481 #define HSP2_INQUIRY_INCLUDED TRUE 2482 #endif 2483 2484 /* Include Audio Gateway specific code. */ 2485 #ifndef HSP2_AG_INCLUDED 2486 #define HSP2_AG_INCLUDED TRUE 2487 #endif 2488 2489 /* Include Headset Specific Code. */ 2490 #ifndef HSP2_HS_INCLUDED 2491 #define HSP2_HS_INCLUDED TRUE 2492 #endif 2493 2494 /* Include the ability to open an SCO connection for In-Band Ringing. */ 2495 #ifndef HSP2_IB_RING_INCLUDED 2496 #define HSP2_IB_RING_INCLUDED TRUE 2497 #endif 2498 2499 /* Include the ability to repeat a ring. */ 2500 #ifndef HSP2_AG_REPEAT_RING 2501 #define HSP2_AG_REPEAT_RING TRUE 2502 #endif 2503 2504 #ifndef HSP2_APP_CLOSES_ON_CKPD 2505 #define HSP2_APP_CLOSES_ON_CKPD FALSE 2506 #endif 2507 2508 2509 /* Include the ability to park a connection. */ 2510 #ifndef HSP2_PARK_INCLUDED 2511 #define HSP2_PARK_INCLUDED TRUE 2512 #endif 2513 2514 /* Include HSP State Machine debug trace messages. */ 2515 #ifndef HSP2_FSM_DEBUG 2516 #define HSP2_FSM_DEBUG TRUE 2517 #endif 2518 2519 /* The Module's Inquiry Scan Window. */ 2520 #ifndef HSP2_INQ_SCAN_WINDOW 2521 #define HSP2_INQ_SCAN_WINDOW 0 2522 #endif 2523 2524 /* The Module's Inquiry Scan Interval. */ 2525 #ifndef HSP2_INQ_SCAN_INTERVAL 2526 #define HSP2_INQ_SCAN_INTERVAL 0 2527 #endif 2528 2529 /* The Module's Page Scan Interval. */ 2530 #ifndef HSP2_PAGE_SCAN_INTERVAL 2531 #define HSP2_PAGE_SCAN_INTERVAL 0 2532 #endif 2533 2534 /* The Module's Page Scan Window. */ 2535 #ifndef HSP2_PAGE_SCAN_WINDOW 2536 #define HSP2_PAGE_SCAN_WINDOW 0 2537 #endif 2538 2539 /* The Park Mode's Minimum Beacon Period. */ 2540 #ifndef HSP2_BEACON_MIN_PERIOD 2541 #define HSP2_BEACON_MIN_PERIOD 450 2542 #endif 2543 2544 /* The Park Mode's Maximum Beacon Period. */ 2545 #ifndef HSP2_BEACON_MAX_PERIOD 2546 #define HSP2_BEACON_MAX_PERIOD 500 2547 #endif 2548 2549 /* The duration of the inquiry in seconds. */ 2550 #ifndef HSP2_INQ_DURATION 2551 #define HSP2_INQ_DURATION 4 2552 #endif 2553 2554 /* Maximum number of peer responses during an inquiry. */ 2555 #ifndef HSP2_INQ_MAX_NUM_RESPS 2556 #define HSP2_INQ_MAX_NUM_RESPS 3 2557 #endif 2558 2559 /* Maximum number of times to retry an inquiry prior to failure. */ 2560 #ifndef HSP2_MAX_INQ_RETRY 2561 #define HSP2_MAX_INQ_RETRY 6 2562 #endif 2563 2564 /* Maximum number of times to retry an RFCOMM connection prior to failure. */ 2565 #ifndef HSP2_MAX_CONN_RETRY 2566 #define HSP2_MAX_CONN_RETRY 3 2567 #endif 2568 2569 /* If the connect request failed for authentication reasons, do not retry */ 2570 #ifndef HSP2_NO_RETRY_ON_AUTH_FAIL 2571 #define HSP2_NO_RETRY_ON_AUTH_FAIL TRUE 2572 #endif 2573 2574 /* Maximum number of characters in an HSP2 device name. */ 2575 #ifndef HSP2_MAX_NAME_LEN 2576 #define HSP2_MAX_NAME_LEN 32 2577 #endif 2578 2579 /* The minimum speaker and/or microphone gain setting. */ 2580 #ifndef HSP2_MIN_GAIN 2581 #define HSP2_MIN_GAIN 0 2582 #endif 2583 2584 /* The maximum speaker and/or microphone setting. */ 2585 #ifndef HSP2_MAX_GAIN 2586 #define HSP2_MAX_GAIN 15 2587 #endif 2588 2589 /* The default value to send on an AT+CKPD. */ 2590 #ifndef HSP2_KEYPRESS_DEFAULT 2591 #define HSP2_KEYPRESS_DEFAULT 200 2592 #endif 2593 2594 /* Maximum amount a data that can be received per RFCOMM frame. */ 2595 #ifndef HSP2_MAX_RFC_READ_LEN 2596 #define HSP2_MAX_RFC_READ_LEN 128 2597 #endif 2598 2599 /* The time in seconds to wait for completion of a partial AT command or response from the peer. */ 2600 #ifndef HSP2_AT_TO_INTERVAL 2601 #define HSP2_AT_TO_INTERVAL 30 2602 #endif 2603 2604 /* The time to wait before repeating a ring to a peer Headset. */ 2605 #ifndef HSP2_REPEAT_RING_TO 2606 #define HSP2_REPEAT_RING_TO 4 2607 #endif 2608 2609 /* Time to wait for a response for an AT command */ 2610 #ifndef HSP2_AT_RSP_TO 2611 #define HSP2_AT_RSP_TO 20 2612 #endif 2613 2614 /* SCO packet type(s) to use (bitmask: see spec), 0 - device default (recommended) */ 2615 #ifndef HSP2_SCO_PKT_TYPES 2616 #define HSP2_SCO_PKT_TYPES ((UINT16)0x0000) 2617 #endif 2618 2619 /* The default settings of the SCO voice link. */ 2620 #ifndef HSP2_DEFAULT_VOICE_SETTINGS 2621 #define HSP2_DEFAULT_VOICE_SETTINGS (HCI_INP_CODING_LINEAR | HCI_INP_DATA_FMT_2S_COMPLEMENT | HCI_INP_SAMPLE_SIZE_16BIT | HCI_AIR_CODING_FORMAT_CVSD) 2622 #endif 2623 2624 #ifndef HSP2_MAX_AT_CMD_LENGTH 2625 #define HSP2_MAX_AT_CMD_LENGTH 16 2626 #endif 2627 2628 #ifndef HSP2_MAX_AT_VAL_LENGTH 2629 #if (defined(HFP_INCLUDED) && HFP_INCLUDED == TRUE) 2630 #define HSP2_MAX_AT_VAL_LENGTH 310 2631 #else 2632 #define HSP2_MAX_AT_VAL_LENGTH 5 2633 #endif 2634 #endif 2635 2636 2637 #ifndef HSP2_SDP_DB_SIZE 2638 #define HSP2_SDP_DB_SIZE 300 2639 #endif 2640 2641 2642 /****************************************************************************** 2643 ** 2644 ** HFP 2645 ** 2646 ******************************************************************************/ 2647 2648 #ifndef HFP_INCLUDED 2649 #define HFP_INCLUDED FALSE 2650 #endif 2651 2652 /* Include Audio Gateway specific code. */ 2653 #ifndef HFP_AG_INCLUDED 2654 #define HFP_AG_INCLUDED TRUE 2655 #endif 2656 2657 /* Include Hand Free Specific Code. */ 2658 #ifndef HFP_HF_INCLUDED 2659 #define HFP_HF_INCLUDED TRUE 2660 #endif 2661 2662 /* Use AT interface instead of full blown API */ 2663 #ifndef AT_INTERFACE 2664 #define AT_INTERFACE FALSE 2665 #endif 2666 2667 /* HFP Manages SCO establishement for various procedures */ 2668 #ifndef HFP_SCO_MGMT_INCLUDED 2669 #define HFP_SCO_MGMT_INCLUDED TRUE 2670 #endif 2671 2672 /* CCAP compliant features and behavior desired */ 2673 #ifndef CCAP_COMPLIANCE 2674 #define CCAP_COMPLIANCE TRUE 2675 #endif 2676 2677 /* Caller ID string, part of +CLIP result code */ 2678 #ifndef HFP_MAX_CLIP_INFO 2679 #define HFP_MAX_CLIP_INFO 45 2680 #endif 2681 2682 #ifndef HFP_RPT_PEER_INFO_INCLUDED 2683 #define HFP_RPT_PEER_INFO_INCLUDED TRUE /* Reporting of peer features enabled */ 2684 #endif 2685 2686 /****************************************************************************** 2687 ** 2688 ** HID 2689 ** 2690 ******************************************************************************/ 2691 2692 /* HID Device Role Included */ 2693 #ifndef HID_DEV_INCLUDED 2694 #define HID_DEV_INCLUDED FALSE 2695 #endif 2696 2697 #ifndef HID_DEV_PM_INCLUDED 2698 #define HID_DEV_PM_INCLUDED TRUE 2699 #endif 2700 2701 /* The HID Device is a virtual cable */ 2702 #ifndef HID_DEV_VIRTUAL_CABLE 2703 #define HID_DEV_VIRTUAL_CABLE TRUE 2704 #endif 2705 2706 /* The HID device initiates the reconnections */ 2707 #ifndef HID_DEV_RECONN_INITIATE 2708 #define HID_DEV_RECONN_INITIATE TRUE 2709 #endif 2710 2711 /* THe HID device is normally connectable */ 2712 #ifndef HID_DEV_NORMALLY_CONN 2713 #define HID_DEV_NORMALLY_CONN FALSE 2714 #endif 2715 2716 /* The device is battery powered */ 2717 #ifndef HID_DEV_BATTERY_POW 2718 #define HID_DEV_BATTERY_POW TRUE 2719 #endif 2720 2721 /* Device is capable of waking up the host */ 2722 #ifndef HID_DEV_REMOTE_WAKE 2723 #define HID_DEV_REMOTE_WAKE TRUE 2724 #endif 2725 2726 /* Device needs host to close SDP channel after SDP is over */ 2727 #ifndef HID_DEV_SDP_DISABLE 2728 #define HID_DEV_SDP_DISABLE TRUE 2729 #endif 2730 2731 #ifndef HID_DEV_MTU_SIZE 2732 #define HID_DEV_MTU_SIZE 64 2733 #endif 2734 2735 #ifndef HID_DEV_FLUSH_TO 2736 #define HID_DEV_FLUSH_TO 0xffff 2737 #endif 2738 2739 #ifndef HID_DEV_PAGE_SCAN_WIN 2740 #define HID_DEV_PAGE_SCAN_WIN (0) 2741 #endif 2742 2743 #ifndef HID_DEV_PAGE_SCAN_INT 2744 #define HID_DEV_PAGE_SCAN_INT (0) 2745 #endif 2746 2747 #ifndef HID_DEV_MAX_CONN_RETRY 2748 #define HID_DEV_MAX_CONN_RETRY (15) 2749 #endif 2750 2751 #ifndef HID_DEV_REPAGE_WIN 2752 #define HID_DEV_REPAGE_WIN (1) 2753 #endif 2754 2755 #ifndef HID_DEV_SVC_NAME 2756 #define HID_DEV_SVC_NAME "HID" 2757 #endif 2758 2759 #ifndef HID_DEV_SVC_DESCR 2760 #define HID_DEV_SVC_DESCR "3-button mouse and keyboard" 2761 #endif 2762 2763 #ifndef HID_DEV_PROVIDER_NAME 2764 #define HID_DEV_PROVIDER_NAME "Widcomm" 2765 #endif 2766 2767 #ifndef HID_DEV_REL_NUM 2768 #define HID_DEV_REL_NUM 0x0100 2769 #endif 2770 2771 #ifndef HID_DEV_PARSER_VER 2772 #define HID_DEV_PARSER_VER 0x0111 2773 #endif 2774 2775 #ifndef HID_DEV_SUBCLASS 2776 #define HID_DEV_SUBCLASS COD_MINOR_POINTING 2777 #endif 2778 2779 #ifndef HID_DEV_COUNTRY_CODE 2780 #define HID_DEV_COUNTRY_CODE 0x33 2781 #endif 2782 2783 #ifndef HID_DEV_SUP_TOUT 2784 #define HID_DEV_SUP_TOUT 0x8000 2785 #endif 2786 2787 #ifndef HID_DEV_NUM_LANGS 2788 #define HID_DEV_NUM_LANGS 1 2789 #endif 2790 2791 #ifndef HID_DEV_INACT_TIMEOUT 2792 #define HID_DEV_INACT_TIMEOUT 60 2793 #endif 2794 2795 #ifndef HID_DEV_BUSY_MODE_PARAMS 2796 #define HID_DEV_BUSY_MODE_PARAMS { 320, 160, 10, 20, HCI_MODE_ACTIVE } 2797 #endif 2798 2799 #ifndef HID_DEV_IDLE_MODE_PARAMS 2800 #define HID_DEV_IDLE_MODE_PARAMS { 320, 160, 10, 20, HCI_MODE_SNIFF } 2801 #endif 2802 2803 #ifndef HID_DEV_SUSP_MODE_PARAMS 2804 #define HID_DEV_SUSP_MODE_PARAMS { 640, 320, 0, 0, HCI_MODE_PARK } 2805 #endif 2806 2807 #ifndef HID_DEV_MAX_DESCRIPTOR_SIZE 2808 #define HID_DEV_MAX_DESCRIPTOR_SIZE 128 /* Max descriptor size */ 2809 #endif 2810 2811 #ifndef HID_DEV_LANGUAGELIST 2812 #define HID_DEV_LANGUAGELIST {0x35, 0x06, 0x09, 0x04, 0x09, 0x09, 0x01, 0x00} 2813 #endif 2814 2815 #ifndef HID_DEV_LINK_SUPERVISION_TO 2816 #define HID_DEV_LINK_SUPERVISION_TO 0x8000 2817 #endif 2818 2819 #ifndef HID_CONTROL_POOL_ID 2820 #define HID_CONTROL_POOL_ID 2 2821 #endif 2822 2823 #ifndef HID_INTERRUPT_POOL_ID 2824 #define HID_INTERRUPT_POOL_ID 2 2825 #endif 2826 2827 /************************************************************************* 2828 ** Definitions for Both HID-Host & Device 2829 */ 2830 #ifndef HID_MAX_SVC_NAME_LEN 2831 #define HID_MAX_SVC_NAME_LEN 32 2832 #endif 2833 2834 #ifndef HID_MAX_SVC_DESCR_LEN 2835 #define HID_MAX_SVC_DESCR_LEN 32 2836 #endif 2837 2838 #ifndef HID_MAX_PROV_NAME_LEN 2839 #define HID_MAX_PROV_NAME_LEN 32 2840 #endif 2841 2842 /************************************************************************* 2843 ** Definitions for HID-Host 2844 */ 2845 #ifndef HID_HOST_INCLUDED 2846 #define HID_HOST_INCLUDED TRUE 2847 #endif 2848 2849 #ifndef HID_HOST_MAX_DEVICES 2850 #define HID_HOST_MAX_DEVICES 7 2851 #endif 2852 2853 #ifndef HID_HOST_MTU 2854 #define HID_HOST_MTU 640 2855 #endif 2856 2857 #ifndef HID_HOST_FLUSH_TO 2858 #define HID_HOST_FLUSH_TO 0xffff 2859 #endif 2860 2861 #ifndef HID_HOST_MAX_CONN_RETRY 2862 #define HID_HOST_MAX_CONN_RETRY (3) 2863 #endif 2864 2865 #ifndef HID_HOST_REPAGE_WIN 2866 #define HID_HOST_REPAGE_WIN (2) 2867 #endif 2868 2869 2870 /****************************************************************************** 2871 ** 2872 ** DUN and FAX 2873 ** 2874 ******************************************************************************/ 2875 2876 #ifndef DUN_INCLUDED 2877 #define DUN_INCLUDED FALSE 2878 #endif 2879 2880 2881 /****************************************************************************** 2882 ** 2883 ** GOEP 2884 ** 2885 ******************************************************************************/ 2886 2887 #ifndef GOEP_INCLUDED 2888 #define GOEP_INCLUDED FALSE 2889 #endif 2890 2891 /* This is set to enable GOEP non-blocking file system access functions. */ 2892 #ifndef GOEP_FS_INCLUDED 2893 #define GOEP_FS_INCLUDED FALSE 2894 #endif 2895 2896 /* GOEP authentication key size. */ 2897 #ifndef GOEP_MAX_AUTH_KEY_SIZE 2898 #define GOEP_MAX_AUTH_KEY_SIZE 16 2899 #endif 2900 2901 /* Maximum size of the realm authentication string. */ 2902 #ifndef GOEP_MAX_AUTH_REALM_SIZE 2903 #define GOEP_MAX_AUTH_REALM_SIZE 16 2904 #endif 2905 2906 /* Realm Character Set */ 2907 #ifndef GOEP_REALM_CHARSET 2908 #define GOEP_REALM_CHARSET 0 /* ASCII */ 2909 #endif 2910 2911 /* This is set to the maximum length of path name allowed in the system (_MAX_PATH). */ 2912 #ifndef GOEP_MAX_PATH_SIZE 2913 #define GOEP_MAX_PATH_SIZE 255 2914 #endif 2915 2916 /* Specifies whether or not client's user id is required during obex authentication */ 2917 #ifndef GOEP_SERVER_USERID_REQUIRED 2918 #define GOEP_SERVER_USERID_REQUIRED FALSE 2919 #endif 2920 2921 /* This is set to the maximum length of file name allowed in the system (_MAX_FNAME). */ 2922 #ifndef GOEP_MAX_FILE_SIZE 2923 #define GOEP_MAX_FILE_SIZE 128 2924 #endif 2925 2926 /* Character used as path separator */ 2927 #ifndef GOEP_PATH_SEPARATOR 2928 #define GOEP_PATH_SEPARATOR ((char) 0x5c) /* 0x2f ('/'), or 0x5c ('\') */ 2929 #endif 2930 2931 /****************************************************************************** 2932 ** 2933 ** OPP 2934 ** 2935 ******************************************************************************/ 2936 2937 #ifndef OPP_INCLUDED 2938 #define OPP_INCLUDED FALSE 2939 #endif 2940 2941 /* This is set to enable OPP client capabilities. */ 2942 #ifndef OPP_CLIENT_INCLUDED 2943 #define OPP_CLIENT_INCLUDED FALSE 2944 #endif 2945 2946 /* This is set to enable OPP server capabilities. */ 2947 #ifndef OPP_SERVER_INCLUDED 2948 #define OPP_SERVER_INCLUDED FALSE 2949 #endif 2950 2951 /* if the optional formating functions are to be included or not */ 2952 #ifndef OPP_FORMAT_INCLUDED 2953 #define OPP_FORMAT_INCLUDED FALSE 2954 #endif 2955 2956 /* Maximum number of client sessions allowed by server */ 2957 #ifndef OPP_MAX_SRVR_SESS 2958 #define OPP_MAX_SRVR_SESS 3 2959 #endif 2960 2961 /****************************************************************************** 2962 ** 2963 ** FTP 2964 ** 2965 ******************************************************************************/ 2966 2967 #ifndef FTP_INCLUDED 2968 #define FTP_INCLUDED FALSE 2969 #endif 2970 2971 /* This is set to enable FTP client capabilities. */ 2972 #ifndef FTP_CLIENT_INCLUDED 2973 #define FTP_CLIENT_INCLUDED TRUE 2974 #endif 2975 2976 /* This is set to enable FTP server capabilities. */ 2977 #ifndef FTP_SERVER_INCLUDED 2978 #define FTP_SERVER_INCLUDED TRUE 2979 #endif 2980 2981 /****************************************************************************** 2982 ** 2983 ** XML Parser 2984 ** 2985 ******************************************************************************/ 2986 2987 #ifndef XML_STACK_SIZE 2988 #define XML_STACK_SIZE 7 2989 #endif 2990 2991 /****************************************************************************** 2992 ** 2993 ** BPP Printer 2994 ** 2995 ******************************************************************************/ 2996 #ifndef BPP_DEBUG 2997 #define BPP_DEBUG FALSE 2998 #endif 2999 3000 #ifndef BPP_INCLUDED 3001 #define BPP_INCLUDED FALSE 3002 #endif 3003 3004 #ifndef BPP_SND_INCLUDED 3005 #define BPP_SND_INCLUDED FALSE 3006 #endif 3007 3008 /* Maximum number of senders allowed to connect simultaneously 3009 ** The maximum is 6 or (OBX_NUM_SERVERS / 2), whichever is smaller 3010 */ 3011 #ifndef BPP_PR_MAX_CON 3012 #define BPP_PR_MAX_CON 3 3013 #endif 3014 3015 /* Service Name. maximum length: 248 3016 #ifndef BPP_SERVICE_NAME 3017 #define BPP_SERVICE_NAME "Basic Printing" 3018 #endif 3019 */ 3020 /* Document Format Supported. ASCII comma-delimited list of MIME type:version string 3021 #ifndef BPP_DOC_FORMAT_SUPPORTED 3022 #define BPP_DOC_FORMAT_SUPPORTED "application/vnd.pwg-xhtml-print:1.0,application/vnd.hp-PCL:5E,application/PDF" 3023 #endif 3024 3025 #ifndef BPP_DOC_FORMAT_SUPPORTED_LEN 3026 #define BPP_DOC_FORMAT_SUPPORTED_LEN 77 3027 #endif 3028 */ 3029 /* Character repertoires. 3030 #ifndef BPP_CHARACTER_REPERTOIRES 3031 #define BPP_CHARACTER_REPERTOIRES {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01} 3032 #endif 3033 */ 3034 /* XHTML formats. 3035 #ifndef BPP_XHTML_PRINT_FORMATS 3036 #define BPP_XHTML_PRINT_FORMATS "image/gif:89A,image/jpeg" 3037 #endif 3038 3039 #ifndef BPP_XHTML_PRINT_FORMATS_LEN 3040 #define BPP_XHTML_PRINT_FORMATS_LEN 24 3041 #endif 3042 */ 3043 /* Color supported. 3044 #ifndef BPP_COLOR_SUPORTED 3045 #define BPP_COLOR_SUPORTED FALSE 3046 #endif 3047 */ 3048 /* 1284 ID string. First 2 bytes are the length. 3049 #ifndef BPP_1284ID 3050 #define BPP_1284ID "\x00\x48MANUFACTURER:ACME Manufacturing;COMMAND SET:PCL,MPL;MODEL:LaserBeam \?;" 3051 #endif 3052 3053 #ifndef BPP_1284ID_LEN 3054 #define BPP_1284ID_LEN 72 3055 #endif 3056 */ 3057 /* Printer name. 3058 #ifndef BPP_PRINTER_NAME 3059 #define BPP_PRINTER_NAME "My Printer" 3060 #endif 3061 3062 #ifndef BPP_PRINTER_NAME_LEN 3063 #define BPP_PRINTER_NAME_LEN 10 3064 #endif 3065 */ 3066 3067 /* Printer location. 3068 #ifndef BPP_PRINTER_LOCATION 3069 #define BPP_PRINTER_LOCATION "Hotel Lobby" 3070 #endif 3071 3072 #ifndef BPP_PRINTER_LOCATION_LEN 3073 #define BPP_PRINTER_LOCATION_LEN 11 3074 #endif 3075 */ 3076 /* Duplex printing supported. 3077 #ifndef BPP_DUPLEX_SUPPORTED 3078 #define BPP_DUPLEX_SUPPORTED TRUE 3079 #endif 3080 */ 3081 3082 /* Media types supported. 3083 #ifndef BPP_MEDIA_TYPES_SUPPORTED 3084 #define BPP_MEDIA_TYPES_SUPPORTED "stationary,continuous-long,photographic-high-gloss,cardstock" 3085 #endif 3086 3087 #ifndef BPP_MEDIA_TYPES_SUPPORTED_LEN 3088 #define BPP_MEDIA_TYPES_SUPPORTED_LEN 60 3089 #endif 3090 */ 3091 /* Maximum media with supported. 3092 #ifndef BPP_MAX_MEDIA_WIDTH 3093 #define BPP_MAX_MEDIA_WIDTH 205 3094 #endif 3095 */ 3096 /* Maximum media length supported. 3097 #ifndef BPP_MAX_MEDIA_LENGTH 3098 #define BPP_MAX_MEDIA_LENGTH 285 3099 #endif 3100 */ 3101 /* the maximum string len for the media size of medium loaded */ 3102 #ifndef BPP_MEDIA_SIZE_LEN 3103 #define BPP_MEDIA_SIZE_LEN 33 3104 #endif 3105 3106 /* Debug Trace the SOAP object, if TRUE */ 3107 #ifndef BPP_TRACE_XML 3108 #define BPP_TRACE_XML TRUE 3109 #endif 3110 3111 /* in case that the SOAP object does not all come in one OBEX packet, 3112 * this size of data may be kept in the BPP control block for continuing parsing. 3113 * The maximum is the size of the biggest GKI buffer (GKI_MAX_BUF_SIZE) */ 3114 #ifndef BPP_SOAP_KEEP_SIZE 3115 #define BPP_SOAP_KEEP_SIZE 200 3116 #endif 3117 3118 3119 /****************************************************************************** 3120 ** 3121 ** BIP 3122 ** 3123 ******************************************************************************/ 3124 #ifndef BIP_INCLUDED 3125 #define BIP_INCLUDED FALSE 3126 #endif 3127 3128 /* TRUE to include imaging initiator */ 3129 #ifndef BIP_INITR_INCLUDED 3130 #define BIP_INITR_INCLUDED FALSE 3131 #endif 3132 3133 /* TRUE to include imaging responder */ 3134 #ifndef BIP_RSPDR_INCLUDED 3135 #define BIP_RSPDR_INCLUDED FALSE 3136 #endif 3137 3138 /* TRUE to include image push feature */ 3139 #ifndef BIP_PUSH_INCLUDED 3140 #define BIP_PUSH_INCLUDED TRUE 3141 #endif 3142 3143 /* TRUE to include image pull feature */ 3144 #ifndef BIP_PULL_INCLUDED 3145 #define BIP_PULL_INCLUDED TRUE 3146 #endif 3147 3148 /* TRUE to include advanced image printing feature */ 3149 #ifndef BIP_PRINTING_INCLUDED 3150 #define BIP_PRINTING_INCLUDED TRUE 3151 #endif 3152 3153 /* TRUE to include automatic archive feature */ 3154 #ifndef BIP_ARCHIVE_INCLUDED 3155 #define BIP_ARCHIVE_INCLUDED TRUE 3156 #endif 3157 3158 /* TRUE to include remote camera feature */ 3159 #ifndef BIP_CAMERA_INCLUDED 3160 #define BIP_CAMERA_INCLUDED TRUE 3161 #endif 3162 3163 /* TRUE to include remote display feature */ 3164 #ifndef BIP_DISPLAY_INCLUDED 3165 #define BIP_DISPLAY_INCLUDED TRUE 3166 #endif 3167 3168 /* TRUE to include sanity check code for API functions */ 3169 #ifndef BIP_SANITY_CHECKS 3170 #define BIP_SANITY_CHECKS TRUE 3171 #endif 3172 3173 /* TRUE to show the received XML object in trace for conformance tests */ 3174 #ifndef BIP_TRACE_XML 3175 #define BIP_TRACE_XML TRUE 3176 #endif 3177 3178 /* in case that the received XML object is not complete, the XML parser state machine needs 3179 * to keep a copy of the data from the last '<' 3180 * This macro specifies the maximun amount of data for this purpose */ 3181 #ifndef BIP_XML_CARRY_OVER_LEN 3182 #define BIP_XML_CARRY_OVER_LEN 100 3183 #endif 3184 3185 /* minimum 4, maximum is 255. The value should be set to the maximum size of encoding string + 1. JPEG2000. 3186 * If vendor specific format is supported, it might be bigger than 9 */ 3187 #ifndef BIP_IMG_ENCODE_SIZE 3188 #define BIP_IMG_ENCODE_SIZE 9 3189 #endif 3190 3191 /* MIME type: text/plain */ 3192 #ifndef BIP_TYPE_SIZE 3193 #define BIP_TYPE_SIZE 20 3194 #endif 3195 3196 /* example: iso-8895-1 */ 3197 #ifndef BIP_CHARSET_SIZE 3198 #define BIP_CHARSET_SIZE 10 3199 #endif 3200 3201 /* friendly name */ 3202 #ifndef BIP_FNAME_SIZE 3203 #define BIP_FNAME_SIZE 20 3204 #endif 3205 3206 /* service name */ 3207 #ifndef BIP_SNAME_SIZE 3208 #define BIP_SNAME_SIZE 60 3209 #endif 3210 3211 /* temporary storage file name(for file system access, may include path) */ 3212 #ifndef BIP_TEMP_NAME_SIZE 3213 #define BIP_TEMP_NAME_SIZE 200 3214 #endif 3215 3216 /* image file name */ 3217 #ifndef BIP_IMG_NAME_SIZE 3218 #define BIP_IMG_NAME_SIZE 200 3219 #endif 3220 3221 /* attachment file name */ 3222 #ifndef BIP_ATT_NAME_SIZE 3223 #define BIP_ATT_NAME_SIZE 200 3224 #endif 3225 3226 /* object (image, attachment, thumbnail) file name (may be used for file system) */ 3227 #ifndef BIP_OBJ_NAME_SIZE 3228 #define BIP_OBJ_NAME_SIZE 200 3229 #endif 3230 3231 3232 3233 /****************************************************************************** 3234 ** 3235 ** HCRP 3236 ** 3237 ******************************************************************************/ 3238 3239 #ifndef HCRP_INCLUDED 3240 #define HCRP_INCLUDED FALSE 3241 #endif 3242 3243 /* This is set to enable server. */ 3244 #ifndef HCRP_SERVER_INCLUDED 3245 #define HCRP_SERVER_INCLUDED FALSE 3246 #endif 3247 3248 /* This is set to enable client. */ 3249 #ifndef HCRP_CLIENT_INCLUDED 3250 #define HCRP_CLIENT_INCLUDED FALSE 3251 #endif 3252 3253 /* TRUE enables the notification option of the profile. */ 3254 #ifndef HCRP_NOTIFICATION_INCLUDED 3255 #define HCRP_NOTIFICATION_INCLUDED TRUE 3256 #endif 3257 3258 /* TRUE enables the vendor specific option of the profile. */ 3259 #ifndef HCRP_VENDOR_SPEC_INCLUDED 3260 #define HCRP_VENDOR_SPEC_INCLUDED TRUE 3261 #endif 3262 3263 /* TRUE enables state machine traces. */ 3264 #ifndef HCRP_FSM_DEBUG 3265 #define HCRP_FSM_DEBUG FALSE 3266 #endif 3267 3268 /* TRUE enables protocol message traces. */ 3269 #ifndef HCRP_PROTO_DEBUG 3270 #define HCRP_PROTO_DEBUG FALSE 3271 #endif 3272 3273 /* Maximum length used to store the service name (Minimum 1). */ 3274 #ifndef HCRP_MAX_SERVICE_NAME_LEN 3275 #define HCRP_MAX_SERVICE_NAME_LEN 32 3276 #endif 3277 3278 /* Maximum length used to store the device name (Minimum 1). */ 3279 #ifndef HCRP_MAX_DEVICE_NAME_LEN 3280 #define HCRP_MAX_DEVICE_NAME_LEN 32 3281 #endif 3282 3283 /* Maximum length of device location (Minimum 1) */ 3284 #ifndef HCRP_MAX_DEVICE_LOC_LEN 3285 #define HCRP_MAX_DEVICE_LOC_LEN 32 3286 #endif 3287 3288 /* Maximum length used to store the friendly name (Minimum 1). */ 3289 #ifndef HCRP_MAX_FRIENDLY_NAME_LEN 3290 #define HCRP_MAX_FRIENDLY_NAME_LEN 32 3291 #endif 3292 3293 /* Maximum length used to store the 1284 id string (Minimum 2 byte length field). */ 3294 #ifndef HCRP_MAX_SDP_1284_ID_LEN 3295 #define HCRP_MAX_SDP_1284_ID_LEN 128 3296 #endif 3297 3298 /* Maximum length for parameters to be processed for vendor specific commands. */ 3299 #ifndef HCRP_MAX_VEND_SPEC_LEN 3300 #define HCRP_MAX_VEND_SPEC_LEN 4 3301 #endif 3302 3303 /* Number of seconds to wait for 2nd GAP to open. */ 3304 #ifndef HCRP_OPEN_CHAN_TOUT 3305 #define HCRP_OPEN_CHAN_TOUT 5 3306 #endif 3307 3308 /* Number of seconds to wait for 2nd GAP to close. */ 3309 #ifndef HCRP_CLOSE_CHAN_TOUT 3310 #define HCRP_CLOSE_CHAN_TOUT 3 3311 #endif 3312 3313 /* Number of seconds to wait for the application to respond to a protocol request. */ 3314 #ifndef HCRP_APPL_RSP_TOUT 3315 #define HCRP_APPL_RSP_TOUT 5 3316 #endif 3317 3318 /* Number of seconds to wait for the peer device to respond to a protocol request. */ 3319 #ifndef HCRP_CMD_RSP_TOUT 3320 #define HCRP_CMD_RSP_TOUT 7 3321 #endif 3322 3323 /* Number of seconds between subsequent credit requests to the server when the send watermark has been exceeded. */ 3324 #ifndef HCRP_CREDIT_REQ_UPDATES 3325 #define HCRP_CREDIT_REQ_UPDATES 1 3326 #endif 3327 3328 /* Maximum number of results to return in a HCRP_FindServices search. */ 3329 #ifndef HCRP_MAX_SEARCH_RESULTS 3330 #define HCRP_MAX_SEARCH_RESULTS 1 3331 #endif 3332 3333 /* Maximum number of bytes to be reserved for searching for the client's notification record. */ 3334 #ifndef HCRP_MAX_NOTIF_DISC_BUF 3335 #define HCRP_MAX_NOTIF_DISC_BUF 300 3336 #endif 3337 3338 /* Maximum number of clients the server will allow to be registered for notifications. */ 3339 #ifndef HCRP_MAX_NOTIF_CLIENTS 3340 #define HCRP_MAX_NOTIF_CLIENTS 3 3341 #endif 3342 3343 /* Spec says minimum of two notification retries. */ 3344 #ifndef HCRP_NOTIF_NUM_RETRIES 3345 #define HCRP_NOTIF_NUM_RETRIES 4 3346 #endif 3347 3348 /************************************************************************* 3349 ** Definitions for Multi-Client Server HCRP 3350 ** Note: Many of the above HCRP definitions are also used 3351 ** Maximum number of clients allowed to connect simultaneously 3352 ** Must be less than ((GAP_MAX_CONNECTIONS - 1) / 2) 3353 */ 3354 #ifndef HCRPM_MAX_CLIENTS 3355 #define HCRPM_MAX_CLIENTS 3 3356 #endif 3357 3358 3359 /****************************************************************************** 3360 ** 3361 ** PAN 3362 ** 3363 ******************************************************************************/ 3364 3365 #ifndef PAN_INCLUDED 3366 #define PAN_INCLUDED FALSE 3367 #endif 3368 3369 3370 /****************************************************************************** 3371 ** 3372 ** SAP 3373 ** 3374 ******************************************************************************/ 3375 3376 #ifndef SAP_SERVER_INCLUDED 3377 #define SAP_SERVER_INCLUDED FALSE 3378 #endif 3379 3380 3381 /************************************************************************* 3382 * A2DP Definitions 3383 */ 3384 #ifndef A2D_INCLUDED 3385 #define A2D_INCLUDED TRUE 3386 #endif 3387 3388 /* TRUE to include SBC utility functions */ 3389 #ifndef A2D_SBC_INCLUDED 3390 #define A2D_SBC_INCLUDED A2D_INCLUDED 3391 #endif 3392 3393 /* TRUE to include MPEG-1,2 (mp3) utility functions */ 3394 #ifndef A2D_M12_INCLUDED 3395 #define A2D_M12_INCLUDED A2D_INCLUDED 3396 #endif 3397 3398 /* TRUE to include MPEG-2,4 (aac) utility functions */ 3399 #ifndef A2D_M24_INCLUDED 3400 #define A2D_M24_INCLUDED A2D_INCLUDED 3401 #endif 3402 3403 /****************************************************************************** 3404 ** 3405 ** AVCTP 3406 ** 3407 ******************************************************************************/ 3408 3409 #ifndef AVCT_INCLUDED 3410 #define AVCT_INCLUDED TRUE 3411 #endif 3412 3413 /* Number of simultaneous ACL links to different peer devices. */ 3414 #ifndef AVCT_NUM_LINKS 3415 #define AVCT_NUM_LINKS 2 3416 #endif 3417 3418 /* Number of simultaneous AVCTP connections. */ 3419 #ifndef AVCT_NUM_CONN 3420 #define AVCT_NUM_CONN 3 3421 #endif 3422 3423 /* Pool ID where to reassemble the SDU. 3424 This Pool allows buffers to be used that are larger than 3425 the L2CAP_MAX_MTU. */ 3426 #ifndef AVCT_BR_USER_RX_POOL_ID 3427 #define AVCT_BR_USER_RX_POOL_ID HCI_ACL_POOL_ID 3428 #endif 3429 3430 /* Pool ID where to hold the SDU. 3431 This Pool allows buffers to be used that are larger than 3432 the L2CAP_MAX_MTU. */ 3433 #ifndef AVCT_BR_USER_TX_POOL_ID 3434 #define AVCT_BR_USER_TX_POOL_ID HCI_ACL_POOL_ID 3435 #endif 3436 3437 /* 3438 GKI Buffer Pool ID used to hold MPS segments during SDU reassembly 3439 */ 3440 #ifndef AVCT_BR_FCR_RX_POOL_ID 3441 #define AVCT_BR_FCR_RX_POOL_ID HCI_ACL_POOL_ID 3442 #endif 3443 3444 /* 3445 GKI Buffer Pool ID used to hold MPS segments used in (re)transmissions. 3446 L2CAP_DEFAULT_ERM_POOL_ID is specified to use the HCI ACL data pool. 3447 Note: This pool needs to have enough buffers to hold two times the window size negotiated 3448 in the tL2CAP_FCR_OPTIONS (2 * tx_win_size) to allow for retransmissions. 3449 The size of each buffer must be able to hold the maximum MPS segment size passed in 3450 tL2CAP_FCR_OPTIONS plus BT_HDR (8) + HCI preamble (4) + L2CAP_MIN_OFFSET (11 - as of BT 2.1 + EDR Spec). 3451 */ 3452 #ifndef AVCT_BR_FCR_TX_POOL_ID 3453 #define AVCT_BR_FCR_TX_POOL_ID HCI_ACL_POOL_ID 3454 #endif 3455 3456 /* AVCTP Browsing channel FCR Option: 3457 Size of the transmission window when using enhanced retransmission mode. Not used 3458 in basic and streaming modes. Range: 1 - 63 3459 */ 3460 #ifndef AVCT_BR_FCR_OPT_TX_WINDOW_SIZE 3461 #define AVCT_BR_FCR_OPT_TX_WINDOW_SIZE 10 3462 #endif 3463 3464 /* AVCTP Browsing channel FCR Option: 3465 Number of transmission attempts for a single I-Frame before taking 3466 Down the connection. Used In ERTM mode only. Value is Ignored in basic and 3467 Streaming modes. 3468 Range: 0, 1-0xFF 3469 0 - infinite retransmissions 3470 1 - single transmission 3471 */ 3472 #ifndef AVCT_BR_FCR_OPT_MAX_TX_B4_DISCNT 3473 #define AVCT_BR_FCR_OPT_MAX_TX_B4_DISCNT 20 3474 #endif 3475 3476 /* AVCTP Browsing channel FCR Option: Retransmission Timeout 3477 The AVRCP specification set a value in the range of 300 - 2000 ms 3478 Timeout (in msecs) to detect Lost I-Frames. Only used in Enhanced retransmission mode. 3479 Range: Minimum 2000 (2 secs) when supporting PBF. 3480 */ 3481 #ifndef AVCT_BR_FCR_OPT_RETX_TOUT 3482 #define AVCT_BR_FCR_OPT_RETX_TOUT 2000 3483 #endif 3484 3485 /* AVCTP Browsing channel FCR Option: Monitor Timeout 3486 The AVRCP specification set a value in the range of 300 - 2000 ms 3487 Timeout (in msecs) to detect Lost S-Frames. Only used in Enhanced retransmission mode. 3488 Range: Minimum 12000 (12 secs) when supporting PBF. 3489 */ 3490 #ifndef AVCT_BR_FCR_OPT_MONITOR_TOUT 3491 #define AVCT_BR_FCR_OPT_MONITOR_TOUT 12000 3492 #endif 3493 3494 /****************************************************************************** 3495 ** 3496 ** AVRCP 3497 ** 3498 ******************************************************************************/ 3499 3500 #ifndef AVRC_INCLUDED 3501 #define AVRC_INCLUDED TRUE 3502 #endif 3503 3504 /****************************************************************************** 3505 ** 3506 ** MCAP 3507 ** 3508 ******************************************************************************/ 3509 #ifndef MCA_INCLUDED 3510 #define MCA_INCLUDED FALSE 3511 #endif 3512 3513 /* TRUE to support Clock Synchronization OpCodes */ 3514 #ifndef MCA_SYNC_INCLUDED 3515 #define MCA_SYNC_INCLUDED FALSE 3516 #endif 3517 3518 /* The MTU size for the L2CAP configuration on control channel. 48 is the minimal */ 3519 #ifndef MCA_CTRL_MTU 3520 #define MCA_CTRL_MTU 60 3521 #endif 3522 3523 /* The maximum number of registered MCAP instances. */ 3524 #ifndef MCA_NUM_REGS 3525 #define MCA_NUM_REGS 3 3526 #endif 3527 3528 /* The maximum number of control channels (to difference devices) per registered MCAP instances. */ 3529 #ifndef MCA_NUM_LINKS 3530 #define MCA_NUM_LINKS 3 3531 #endif 3532 3533 /* The maximum number of MDEP (including HDP echo) per registered MCAP instances. */ 3534 #ifndef MCA_NUM_DEPS 3535 #define MCA_NUM_DEPS 3 3536 #endif 3537 3538 /* The maximum number of MDL link per control channel. */ 3539 #ifndef MCA_NUM_MDLS 3540 #define MCA_NUM_MDLS 4 3541 #endif 3542 3543 /* Pool ID where to reassemble the SDU. */ 3544 #ifndef MCA_USER_RX_POOL_ID 3545 #define MCA_USER_RX_POOL_ID HCI_ACL_POOL_ID 3546 #endif 3547 3548 /* Pool ID where to hold the SDU. */ 3549 #ifndef MCA_USER_TX_POOL_ID 3550 #define MCA_USER_TX_POOL_ID HCI_ACL_POOL_ID 3551 #endif 3552 3553 /* 3554 GKI Buffer Pool ID used to hold MPS segments during SDU reassembly 3555 */ 3556 #ifndef MCA_FCR_RX_POOL_ID 3557 #define MCA_FCR_RX_POOL_ID HCI_ACL_POOL_ID 3558 #endif 3559 3560 /* 3561 GKI Buffer Pool ID used to hold MPS segments used in (re)transmissions. 3562 L2CAP_DEFAULT_ERM_POOL_ID is specified to use the HCI ACL data pool. 3563 Note: This pool needs to have enough buffers to hold two times the window size negotiated 3564 in the tL2CAP_FCR_OPTIONS (2 * tx_win_size) to allow for retransmissions. 3565 The size of each buffer must be able to hold the maximum MPS segment size passed in 3566 tL2CAP_FCR_OPTIONS plus BT_HDR (8) + HCI preamble (4) + L2CAP_MIN_OFFSET (11 - as of BT 2.1 + EDR Spec). 3567 */ 3568 #ifndef MCA_FCR_TX_POOL_ID 3569 #define MCA_FCR_TX_POOL_ID HCI_ACL_POOL_ID 3570 #endif 3571 3572 /* MCAP control channel FCR Option: 3573 Size of the transmission window when using enhanced retransmission mode. 3574 1 is defined by HDP specification for control channel. 3575 */ 3576 #ifndef MCA_FCR_OPT_TX_WINDOW_SIZE 3577 #define MCA_FCR_OPT_TX_WINDOW_SIZE 1 3578 #endif 3579 3580 /* MCAP control channel FCR Option: 3581 Number of transmission attempts for a single I-Frame before taking 3582 Down the connection. Used In ERTM mode only. Value is Ignored in basic and 3583 Streaming modes. 3584 Range: 0, 1-0xFF 3585 0 - infinite retransmissions 3586 1 - single transmission 3587 */ 3588 #ifndef MCA_FCR_OPT_MAX_TX_B4_DISCNT 3589 #define MCA_FCR_OPT_MAX_TX_B4_DISCNT 20 3590 #endif 3591 3592 /* MCAP control channel FCR Option: Retransmission Timeout 3593 The AVRCP specification set a value in the range of 300 - 2000 ms 3594 Timeout (in msecs) to detect Lost I-Frames. Only used in Enhanced retransmission mode. 3595 Range: Minimum 2000 (2 secs) when supporting PBF. 3596 */ 3597 #ifndef MCA_FCR_OPT_RETX_TOUT 3598 #define MCA_FCR_OPT_RETX_TOUT 2000 3599 #endif 3600 3601 /* MCAP control channel FCR Option: Monitor Timeout 3602 The AVRCP specification set a value in the range of 300 - 2000 ms 3603 Timeout (in msecs) to detect Lost S-Frames. Only used in Enhanced retransmission mode. 3604 Range: Minimum 12000 (12 secs) when supporting PBF. 3605 */ 3606 #ifndef MCA_FCR_OPT_MONITOR_TOUT 3607 #define MCA_FCR_OPT_MONITOR_TOUT 12000 3608 #endif 3609 3610 /* MCAP control channel FCR Option: Maximum PDU payload size. 3611 The maximum number of payload octets that the local device can receive in a single PDU. 3612 */ 3613 #ifndef MCA_FCR_OPT_MPS_SIZE 3614 #define MCA_FCR_OPT_MPS_SIZE 1000 3615 #endif 3616 3617 /* Shared transport */ 3618 #ifndef NFC_SHARED_TRANSPORT_ENABLED 3619 #define NFC_SHARED_TRANSPORT_ENABLED FALSE 3620 #endif 3621 3622 /****************************************************************************** 3623 ** 3624 ** SER 3625 ** 3626 ******************************************************************************/ 3627 3628 #ifndef SER_INCLUDED 3629 #define SER_INCLUDED FALSE 3630 #endif 3631 3632 /* Task which runs the serial application. */ 3633 #ifndef SER_TASK 3634 #define SER_TASK BTE_APPL_TASK 3635 #endif 3636 3637 /* Mailbox used by serial application. */ 3638 #ifndef SER_MBOX 3639 #define SER_MBOX TASK_MBOX_1 3640 #endif 3641 3642 /* Mailbox mask. */ 3643 #ifndef SER_MBOX_MASK 3644 #define SER_MBOX_MASK TASK_MBOX_1_EVT_MASK 3645 #endif 3646 3647 /* TX path application event. */ 3648 #ifndef SER_TX_PATH_APPL_EVT 3649 #define SER_TX_PATH_APPL_EVT EVENT_MASK(APPL_EVT_3) 3650 #endif 3651 3652 /* RX path application event. */ 3653 #ifndef SER_RX_PATH_APPL_EVT 3654 #define SER_RX_PATH_APPL_EVT EVENT_MASK(APPL_EVT_4) 3655 #endif 3656 3657 /****************************************************************************** 3658 ** 3659 ** Sleep Mode (Low Power Mode) 3660 ** 3661 ******************************************************************************/ 3662 3663 #ifndef HCILP_INCLUDED 3664 #define HCILP_INCLUDED TRUE 3665 #endif 3666 3667 /****************************************************************************** 3668 ** 3669 ** RPC 3670 ** 3671 ******************************************************************************/ 3672 3673 #ifndef RPC_INCLUDED 3674 #define RPC_INCLUDED FALSE 3675 #endif 3676 3677 /* RPCT task mailbox ID for messages coming from rpcgen code. */ 3678 #ifndef RPCT_MBOX 3679 #define RPCT_MBOX TASK_MBOX_0 3680 #endif 3681 3682 /* RPCT task event for mailbox. */ 3683 #ifndef RPCT_RPC_MBOX_EVT 3684 #define RPCT_RPC_MBOX_EVT TASK_MBOX_0_EVT_MASK 3685 #endif 3686 3687 /* RPCT task event from driver indicating RX data is ready. */ 3688 #ifndef RPCT_RX_READY_EVT 3689 #define RPCT_RX_READY_EVT APPL_EVT_0 3690 #endif 3691 3692 /* RPCT task event from driver indicating data TX is done. */ 3693 #ifndef RPCT_TX_DONE_EVT 3694 #define RPCT_TX_DONE_EVT APPL_EVT_1 3695 #endif 3696 3697 /* RPCT task event indicating data is in the circular buffer. */ 3698 #ifndef RPCT_UCBUF_EVT 3699 #define RPCT_UCBUF_EVT APPL_EVT_2 3700 #endif 3701 3702 /* Task ID of RPCGEN task. */ 3703 #ifndef RPCGEN_TASK 3704 #define RPCGEN_TASK BTU_TASK 3705 #endif 3706 3707 /* RPCGEN task event for messages coming from RPCT. */ 3708 #ifndef RPCGEN_MSG_EVT 3709 #define RPCGEN_MSG_EVT TASK_MBOX_1_EVT_MASK 3710 #endif 3711 3712 #ifndef RPCGEN_MSG_MBOX 3713 #define RPCGEN_MSG_MBOX TASK_MBOX_1 3714 #endif 3715 3716 /* Size of circular buffer used to store diagnostic messages. */ 3717 #ifndef RPCT_UCBUF_SIZE 3718 #define RPCT_UCBUF_SIZE 2000 3719 #endif 3720 3721 /****************************************************************************** 3722 ** 3723 ** SAP - Sample applications 3724 ** 3725 ******************************************************************************/ 3726 3727 #ifndef MMI_INCLUDED 3728 #define MMI_INCLUDED FALSE 3729 #endif 3730 3731 /****************************************************************************** 3732 ** 3733 ** APPL - Application Task 3734 ** 3735 ******************************************************************************/ 3736 /* When TRUE indicates that an application task is to be run */ 3737 #ifndef APPL_INCLUDED 3738 #define APPL_INCLUDED TRUE 3739 #endif 3740 3741 /* When TRUE remote terminal code included (RPC MUST be included) */ 3742 #ifndef RSI_INCLUDED 3743 #define RSI_INCLUDED TRUE 3744 #endif 3745 3746 3747 3748 #define L2CAP_FEATURE_REQ_ID 73 3749 #define L2CAP_FEATURE_RSP_ID 173 3750 3751 3752 #define L2CAP_ENHANCED_FEATURES 0 3753 3754 3755 /****************************************************************************** 3756 ** 3757 ** BTA 3758 ** 3759 ******************************************************************************/ 3760 /* BTA EIR canned UUID list (default is dynamic) */ 3761 #ifndef BTA_EIR_CANNED_UUID_LIST 3762 #define BTA_EIR_CANNED_UUID_LIST FALSE 3763 #endif 3764 3765 /* Number of supported customer UUID in EIR */ 3766 #ifndef BTA_EIR_SERVER_NUM_CUSTOM_UUID 3767 #define BTA_EIR_SERVER_NUM_CUSTOM_UUID 8 3768 #endif 3769 3770 /* CHLD override for bluedroid */ 3771 #ifndef BTA_AG_CHLD_VAL_ECC 3772 #define BTA_AG_CHLD_VAL_ECC "(0,1,1x,2,2x,3)" 3773 #endif 3774 3775 #ifndef BTA_AG_CHLD_VAL 3776 #define BTA_AG_CHLD_VAL "(0,1,2,3)" 3777 #endif 3778 3779 /* Set the CIND to match HFP 1.5 */ 3780 #ifndef BTA_AG_CIND_INFO 3781 #define BTA_AG_CIND_INFO "(\"call\",(0,1)),(\"callsetup\",(0-3)),(\"service\",(0-1)),(\"signal\",(0-5)),(\"roam\",(0,1)),(\"battchg\",(0-5)),(\"callheld\",(0-2))" 3782 #endif 3783 3784 3785 /****************************************************************************** 3786 ** 3787 ** BTE 3788 ** 3789 ******************************************************************************/ 3790 #ifndef BTE_PLATFORM_IDLE 3791 #define BTE_PLATFORM_IDLE 3792 #endif 3793 3794 #ifndef BTE_IDLE_TASK_INCLUDED 3795 #define BTE_IDLE_TASK_INCLUDED FALSE 3796 #endif 3797 3798 #ifndef BTE_PLATFORM_INITHW 3799 #define BTE_PLATFORM_INITHW 3800 #endif 3801 3802 #ifndef BTE_BTA_CODE_INCLUDED 3803 #define BTE_BTA_CODE_INCLUDED FALSE 3804 #endif 3805 3806 /****************************************************************************** 3807 ** 3808 ** BTTRC 3809 ** 3810 ******************************************************************************/ 3811 /* Whether to parse and display traces-> Platform specific implementation */ 3812 #ifndef BTTRC_DISP 3813 #define BTTRC_DISP BTTRC_DispOnInsight 3814 #endif 3815 3816 /****************************************************************************** 3817 ** 3818 ** Tracing: Include trace header file here. 3819 ** 3820 ******************************************************************************/ 3821 3822 #include "bt_trace.h" 3823 3824 #endif /* BT_TARGET_H */ 3825 3826