فهرست منبع

component/bt : fix compile error

Tian Hao 9 سال پیش
والد
کامیت
758a9e5f06

+ 2 - 1
components/bt/bluedroid/api/esp_gattc_api.c

@@ -33,7 +33,8 @@ esp_err_t esp_ble_gattc_app_register(uint16_t app_id)
     btc_msg_t msg;
     btc_ble_gattc_args_t arg;
 
-    if (app_id < ESP_APP_ID_MIN || app_id > ESP_APP_ID_MAX) {
+    //if (app_id < ESP_APP_ID_MIN || app_id > ESP_APP_ID_MAX) {
+    if (app_id > ESP_APP_ID_MAX) {
         return ESP_ERR_INVALID_ARG;
     }
 

+ 2 - 1
components/bt/bluedroid/api/esp_gatts_api.c

@@ -30,7 +30,8 @@ esp_err_t esp_ble_gatts_app_register(uint16_t app_id)
     btc_msg_t msg;
     btc_ble_gatts_args_t arg;
 
-    if (app_id < ESP_APP_ID_MIN || app_id > ESP_APP_ID_MAX) {
+    //if (app_id < ESP_APP_ID_MIN || app_id > ESP_APP_ID_MAX) {
+    if (app_id > ESP_APP_ID_MAX) {
         return ESP_ERR_INVALID_ARG;
     }
 

+ 0 - 7
components/bt/bluedroid/btc/profile/std/gatt/btc_gatts.c

@@ -433,11 +433,4 @@ void btc_gatts_cb_handler(btc_msg_t *msg)
     }
 
     btc_gatts_cb_param_copy_free(msg, p_data);
-
-    //ets_printf("yyy\n");
 }
-
-
-
-
-

+ 1 - 1
components/bt/bluedroid/include/bt_trace.h

@@ -271,7 +271,7 @@ inline void trc_dump_buffer(uint8_t *prefix, uint8_t *data, uint16_t len)
 #ifndef LOG_LEVEL
 #define LOG_LEVEL   LOG_LEVEL_INFO
 #endif
-#define LOG_ERROR(fmt, args...)         do {if (LOG_LEVEL >= LOG_LEVEL_ERROR) printf(fmt,## args);} while(0)
+#define LOG_ERROR(fmt, args...)         do {if (LOG_LEVEL >= LOG_LEVEL_ERROR) BT_PRINTF(fmt,## args);} while(0)
 #define LOG_WARN(fmt, args...)          do {if (LOG_LEVEL >= LOG_LEVEL_WARN) BT_PRINTF(fmt,## args);} while(0)
 #define LOG_INFO(fmt, args...)          do {if (LOG_LEVEL >= LOG_LEVEL_INFO) BT_PRINTF(fmt,## args);} while(0)
 #define LOG_DEBUG(fmt, args...)         do {if (LOG_LEVEL >= LOG_LEVEL_DEBUG) BT_PRINTF(fmt,## args);} while(0)