component/bt : api category

This commit is contained in:
Tian Hao 2016-11-05 20:40:07 +08:00
parent 084248e211
commit 224acf37f6
19 changed files with 37 additions and 60 deletions

View file

@ -12,10 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "bt_app_sec.h"
#include <stdlib.h> // standard library
#include <string.h>
#include "esp_sec_api.h"
extern void srand (unsigned int seed);

View file

@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "bt_gap_api.h"
#include "esp_gap_api.h"
#include "bta_api.h"
#include "bt_trace.h"

View file

@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "bt_app_api.h"
#include "esp_gatt_api.h"
#include "btm_ble_api.h"
//#include "btm_ble_int.h"

View file

@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "bt_sdp_api.h"
#include "esp_sdp_api.h"
esp_err_t esp_bt_sdp_enable(bt_sdp_cb_t *cback)

View file

@ -1,5 +1,5 @@
#ifndef __BT_API_COMMON_H__
#define __BT_API_COMMON_H__
#ifndef __ESP_BT_COMMON_H__
#define __ESP_BT_COMMON_H__
#include <stdint.h>
@ -10,4 +10,4 @@ typedef tBT_UUID esp_bt_uuid_t; /* tBT_UUID in "bt_types.h" */
typedef BD_ADDR esp_bd_addr_t; /* BD_ADDR in bt_types.h */
#endif /* __BT_API_COMMON_H__ */
#endif /* __ESP_BT_COMMON_H__ */

View file

@ -1,6 +1,5 @@
#ifndef _BT_APP_DEFS_H__
#define _BT_APP_DEFS_H__
#ifndef __ESP_BT_DEFS_H__
#define __ESP_BT_DEFS_H__
#include "bta_api.h"
@ -329,4 +328,4 @@ extern void ble_set_scan_rsp(esp_ble_adv_data_cfg_t *scan_rsp_data,
#endif ///_BT_APP_DEFS_H__
#endif ///__ESP_BT_DEFS_H__

View file

@ -1,10 +1,10 @@
#ifndef __BT_GAP_API_H__
#define __BT_GAP_API_H__
#ifndef __ESP_GAP_API_H__
#define __ESP_GAP_API_H__
#include <stdint.h>
#include "esp_err.h"
#include "bt_api_common.h"
#include "esp_bt_common.h"
enum {
BT_SCAN_MODE_NONE,
@ -15,4 +15,4 @@ typedef uint16_t bt_scan_mode_t;
esp_err_t esp_bt_gap_set_scan_mode(bt_scan_mode_t mode);
#endif /* __BT_GAP_API_H__ */
#endif /* __ESP_GAP_API_H__ */

View file

@ -1,19 +1,8 @@
// Copyright 2015-2016 Espressif Systems (Shanghai) PTE LTD
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef __ESP_GATT_API_H__
#define __ESP_GATT_API_H__
#include "bt_types.h"
#include "bt_app_defs.h"
#include "esp_bt_defs.h"
#include "bta_gatt_api.h"
#include "bt_prf_sys.h"
@ -921,4 +910,4 @@ void esp_ble_gatts_close(uint16_t conn_id);
void esp_prf_app_register(uint8_t prf_id, void *p_cback);
#endif /* __ESP_GATT_API_H__ */

View file

@ -1,9 +1,9 @@
#ifndef __BT_SDP_API_H__
#define __BT_SDP_API_H__
#ifndef __ESP_SDP_API_H__
#define __ESP_SDP_API_H__
#include <stdint.h>
#include "esp_err.h"
#include "bt_api_common.h"
#include "esp_bt_common.h"
#include "bta_sdp_api.h"
#include "bt_sdp.h"
@ -113,6 +113,5 @@ bool esp_bt_sdp_add_service_class_id_list(uint32_t handle,
uint16_t *p_service_uuids);
bool esp_bt_sdp_delete_attribute(uint32_t handle, uint16_t attr_id);
/**********************************************************************************************/
/**********************************************************************************************/
#endif /* __BT_SDP_API_H__ */
#endif /* __ESP_SDP_API_H__ */

View file

@ -1,16 +1,5 @@
// Copyright 2015-2016 Espressif Systems (Shanghai) PTE LTD
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef __ESP_SEC_API_H__
#define __ESP_SEC_API_H__
#include "bt_types.h"
@ -76,3 +65,4 @@ void app_ble_sec_gen_ltk(UINT8 key_size);
void app_ble_security_start(void);
#endif /* __ESP_SEC_API_H__ */

View file

@ -3,7 +3,7 @@
#include "bta_api.h"
#include "btm_ble_api.h"
#include "bt_app_defs.h"
#include "esp_bt_defs.h"
typedef struct
{

View file

@ -18,7 +18,7 @@
#include "bt_target.h"
#include "gatt_api.h"
#include "gattdefs.h"
#include "bt_app_api.h"
#include "esp_gatt_api.h"
#define KEY_SUCCESS GATT_SUCCESS
#define KEY_ILLEGAL_PARAM GATT_ILLEGAL_PARAMETER
@ -123,4 +123,4 @@ void button_msg_notify(uint16_t len, uint8_t *button_msg);
extern button_env_cb_t button_cb_env;
#endif ///BUT_PROFILE_CFG
#endif ///BUT_PROFILE_CFG

View file

@ -28,7 +28,7 @@
#include "bt_target.h"
#include "gatt_api.h"
#include "gattdefs.h"
#include "bt_app_api.h"
#include "esp_gatt_api.h"
#define DIS_SUCCESS GATT_SUCCESS
#define DIS_ILLEGAL_PARAM GATT_ILLEGAL_PARAMETER

View file

@ -20,7 +20,7 @@
#include "bta_gatts_int.h"
#include "bta_gatt_api.h"
#include "bt_types.h"
#include "bt_app_defs.h"
#include "esp_bt_defs.h"
#define ATT_HANDLE_LEN 0x0002

View file

@ -27,7 +27,7 @@ COMPONENT_ADD_INCLUDEDIRS := bluedroid/bta/include \
bluedroid/stack/sdp/include \
bluedroid/stack/smp/include \
bluedroid/stack/include \
bluedroid/stack_api/include \
bluedroid/api/include \
bluedroid/include \
include
@ -77,7 +77,7 @@ COMPONENT_SRCDIRS := bluedroid/bta/dm \
bluedroid/stack/sdp \
bluedroid/stack/smp \
bluedroid/stack \
bluedroid/stack_api \
bluedroid/api \
bluedroid \
.

View file

@ -31,7 +31,7 @@
#include "btm_api.h"
#include "bt_types.h"
#include "gattc_profile.h"
#include "bt_app_api.h"
#include "esp_gatt_api.h"
#define BT_BD_ADDR_STR "%02x:%02x:%02x:%02x:%02x:%02x"
#define BT_BD_ADDR_HEX(addr) addr[0], addr[1], addr[2], addr[3], addr[4], addr[5]

View file

@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "bt_app_defs.h"
#include "esp_bt_defs.h"
/*******************************************************************************

View file

@ -47,12 +47,12 @@
#include "app_button.h"
#include "hid_le_prf.h"
#include "bt_app_api.h"
#include "esp_gatt_api.h"
//
#include "hcimsgs.h"
#include "bt_app_defs.h"
#include "esp_bt_defs.h"
#define BT_BD_ADDR_STR "%02x:%02x:%02x:%02x:%02x:%02x"