10b966c5eSopenharmony_ci/****************************************************************************** 20b966c5eSopenharmony_ci * 30b966c5eSopenharmony_ci * Copyright 2009-2012 Broadcom Corporation 40b966c5eSopenharmony_ci * 50b966c5eSopenharmony_ci * Licensed under the Apache License, Version 2.0 (the "License"); 60b966c5eSopenharmony_ci * you may not use this file except in compliance with the License. 70b966c5eSopenharmony_ci * You may obtain a copy of the License at: 80b966c5eSopenharmony_ci * 90b966c5eSopenharmony_ci * http://www.apache.org/licenses/LICENSE-2.0 100b966c5eSopenharmony_ci * 110b966c5eSopenharmony_ci * Unless required by applicable law or agreed to in writing, software 120b966c5eSopenharmony_ci * distributed under the License is distributed on an "AS IS" BASIS, 130b966c5eSopenharmony_ci * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 140b966c5eSopenharmony_ci * See the License for the specific language governing permissions and 150b966c5eSopenharmony_ci * limitations under the License. 160b966c5eSopenharmony_ci * 170b966c5eSopenharmony_ci ******************************************************************************/ 180b966c5eSopenharmony_ci 190b966c5eSopenharmony_ci/****************************************************************************** 200b966c5eSopenharmony_ci * 210b966c5eSopenharmony_ci * Filename: bt_hci_bdroid.h 220b966c5eSopenharmony_ci * 230b966c5eSopenharmony_ci * Description: A wrapper header file of bt_hci_lib.h 240b966c5eSopenharmony_ci * 250b966c5eSopenharmony_ci * Contains definitions specific for interfacing with Bluedroid 260b966c5eSopenharmony_ci * Bluetooth stack 270b966c5eSopenharmony_ci * 280b966c5eSopenharmony_ci ******************************************************************************/ 290b966c5eSopenharmony_ci 300b966c5eSopenharmony_ci#ifndef BT_VENDOR_HCI_BDROID_H 310b966c5eSopenharmony_ci#define BT_VENDOR_HCI_BDROID_H 320b966c5eSopenharmony_ci 330b966c5eSopenharmony_ci#ifdef HAS_BDROID_BUILDCFG 340b966c5eSopenharmony_ci#include "bdroid_buildcfg.h" 350b966c5eSopenharmony_ci#endif 360b966c5eSopenharmony_ci 370b966c5eSopenharmony_ci/****************************************************************************** 380b966c5eSopenharmony_ci * Constants & Macros 390b966c5eSopenharmony_ci *****************************************************************************/ 400b966c5eSopenharmony_ci#define HCI_ACL_MAX_SIZE 1024 410b966c5eSopenharmony_ci#define HCI_MAX_FRAME_SIZE (HCI_ACL_MAX_SIZE + 4) 420b966c5eSopenharmony_ci 430b966c5eSopenharmony_ci/* Host/Controller lib internal event ID */ 440b966c5eSopenharmony_citypedef enum { 450b966c5eSopenharmony_ci HC_EVENT_LPM_IDLE_TIMEOUT, 460b966c5eSopenharmony_ci} bthc_event_t; 470b966c5eSopenharmony_ci 480b966c5eSopenharmony_ci/* Message event mask across Host/Controller lib and stack */ 490b966c5eSopenharmony_ci#define MSG_EVT_MASK 0xFF00 /* eq. BT_EVT_MASK */ 500b966c5eSopenharmony_ci#define MSG_SUB_EVT_MASK 0x00FF /* eq. BT_SUB_EVT_MASK */ 510b966c5eSopenharmony_ci 520b966c5eSopenharmony_ci/* Message event ID passed from Host/Controller lib to stack */ 530b966c5eSopenharmony_ci#define MSG_HC_TO_STACK_HCI_ERR 0x1300 /* eq. BT_EVT_TO_BTU_HCIT_ERR */ 540b966c5eSopenharmony_ci#define MSG_HC_TO_STACK_HCI_ACL 0x1100 /* eq. BT_EVT_TO_BTU_HCI_ACL */ 550b966c5eSopenharmony_ci#define MSG_HC_TO_STACK_HCI_SCO 0x1200 /* eq. BT_EVT_TO_BTU_HCI_SCO */ 560b966c5eSopenharmony_ci#define MSG_HC_TO_STACK_HCI_EVT 0x1000 /* eq. BT_EVT_TO_BTU_HCI_EVT */ 570b966c5eSopenharmony_ci#define MSG_HC_TO_STACK_L2C_SEG_XMIT 0x1900 /* BT_EVT_TO_BTU_L2C_SEG_XMIT */ 580b966c5eSopenharmony_ci 590b966c5eSopenharmony_ci/* Message event ID passed from stack to vendor lib */ 600b966c5eSopenharmony_ci#define MSG_STACK_TO_HC_HCI_ACL 0x2100 /* eq. BT_EVT_TO_LM_HCI_ACL */ 610b966c5eSopenharmony_ci#define MSG_STACK_TO_HC_HCI_SCO 0x2200 /* eq. BT_EVT_TO_LM_HCI_SCO */ 620b966c5eSopenharmony_ci#define MSG_STACK_TO_HC_HCI_CMD 0x2000 /* eq. BT_EVT_TO_LM_HCI_CMD */ 630b966c5eSopenharmony_ci 640b966c5eSopenharmony_ci/* Local Bluetooth Controller ID for BR/EDR */ 650b966c5eSopenharmony_ci#define LOCAL_BR_EDR_CONTROLLER_ID 0 660b966c5eSopenharmony_ci 670b966c5eSopenharmony_ci#define BT_HC_HDR_SIZE (sizeof(HC_BT_HDR)) 680b966c5eSopenharmony_ci/****************************************************************************** 690b966c5eSopenharmony_ci * Extern variables and functions 700b966c5eSopenharmony_ci *****************************************************************************/ 710b966c5eSopenharmony_ci 720b966c5eSopenharmony_ci/****************************************************************************** 730b966c5eSopenharmony_ci * Functions 740b966c5eSopenharmony_ci *****************************************************************************/ 750b966c5eSopenharmony_ci#endif