#include <hardware/bluetooth.h>

本文档定义了Android中蓝牙硬件接口的头文件`<hardware/bluetooth.h>`,包含蓝牙设备名称、扫描模式、状态、输入输出能力等枚举类型,以及错误状态、设备属性结构体等,用于蓝牙适配器和远程设备的交互操作。


/*
 * Copyright (C) 2012 The Android Open Source Project
 *
 * 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 ANDROID_INCLUDE_BLUETOOTH_H
#define ANDROID_INCLUDE_BLUETOOTH_H

#include <stdbool.h>
#include <stdint.h>
#include <sys/cdefs.h>
#include <sys/types.h>

#include "avrcp/avrcp.h"
#include "bluetooth/uuid.h"
#include "raw_address.h"

/**
 * The Bluetooth Hardware Module ID
 */

#define BT_HARDWARE_MODULE_ID "bluetooth"
#define BT_STACK_MODULE_ID "bluetooth"

/** Bluetooth profile interface IDs */
#define BT_PROFILE_HANDSFREE_ID "handsfree"
#define BT_PROFILE_HANDSFREE_CLIENT_ID "handsfree_client"
#define BT_PROFILE_ADVANCED_AUDIO_ID "a2dp"
#define BT_PROFILE_ADVANCED_AUDIO_SINK_ID "a2dp_sink"
#define BT_PROFILE_SOCKETS_ID "socket"
#define BT_PROFILE_HIDHOST_ID "hidhost"
#define BT_PROFILE_HIDDEV_ID "hiddev"
#define BT_PROFILE_PAN_ID "pan"
#define BT_PROFILE_MAP_CLIENT_ID "map_client"
#define BT_PROFILE_SDP_CLIENT_ID "sdp"
#define BT_PROFILE_GATT_ID "gatt"
#define BT_PROFILE_AV_RC_ID "avrcp"
#define BT_PROFILE_AV_RC_CTRL_ID "avrcp_ctrl"
#define BT_PROFILE_HEARING_AID_ID "hearing_aid"

/** Bluetooth Device Name */
typedef struct { uint8_t name[249]; } __attribute__((packed)) bt_bdname_t;

/** Bluetooth Adapter Visibility Modes*/
typedef enum {
  BT_SCAN_MODE_NONE,
  BT_SCAN_MODE_CONNECTABLE,
  BT_SCAN_MODE_CONNECTABLE_DISCOVERABLE
} bt_scan_mode_t;

/** Bluetooth Adapter State */
typedef enum { BT_STATE_OFF, BT_STATE_ON } bt_state_t;

/** Bluetooth Adapter Input Output Capabilities which determine Pairing/Security
 */
typedef enum {
  BT_IO_CAP_OUT,    /* DisplayOnly */
  BT_IO_CAP_IO,     /* DisplayYesNo */
  BT_IO_CAP_IN,     /* KeyboardOnly */
  BT_IO_CAP_NONE,   /* NoInputNoOutput */
  BT_IO_CAP_KBDISP, /* Keyboard display */
  BT_IO_CAP_MAX,
  BT_IO_CAP_UNKNOWN = 0xFF /* Unknown value */
} bt_io_cap_t;

/** Bluetooth Error Status */
/** We need to build on this */

typedef enum {
  BT_STATUS_SUCCESS,
  BT_STATUS_FAIL,
  BT_STATUS_NOT_READY,
  BT_STATUS_NOMEM,
  BT_STATUS_BUSY,
  BT_STATUS_DONE, /* request already completed */
  BT_STATUS_UNSUPPORTED,
  BT_STATUS_PARM_INVALID,
  BT_STATUS_UNHANDLED,
  BT_STATUS_AUTH_FAILURE,
  BT_STATUS_RMT_DEV_DOWN,
  BT_STATUS_AUTH_REJECTED,
  BT_STATUS_JNI_ENVIRONMENT_ERROR,
  BT_STATUS_JNI_THREAD_ATTACH_ERROR,
  BT_STATUS_WAKELOCK_ERROR
} bt_status_t;

/** Bluetooth PinKey Code */
typedef struct { uint8_t pin[16]; } __attribute__((packed)) bt_pin_code_t;

typedef struct {
  uint8_t status;
  uint8_t ctrl_state;   /* stack reported state */
  uint64_t tx_time;     /* in ms */
  uint64_t rx_time;     /* in ms */
  uint64_t idle_time;   /* in ms */
  uint64_t energy_used; /* a product of mA, V and ms */
} __attribute__((packed)) bt_activity_energy_info;

typedef struct {
  int32_t app_uid;
  uint64_t tx_bytes;
  uint64_t rx_bytes;
} __attribute__((packed)) bt_uid_traffic_t;

/** Bluetooth Adapter Discovery state */
typedef enum {
  BT_DISCOVERY_STOPPED,
  BT_DISCOVERY_STARTED
} bt_discovery_state_t;

/** Bluetooth ACL connection state */
typedef enum {
  BT_ACL_STATE_CONNECTED,
  BT_ACL_STATE_DISCONNECTED
} bt_acl_state_t;

/** Bluetooth SDP service record */
typedef struct {
  bluetooth::Uuid uuid;
  uint16_t channel;
  char name[256];  // what's the maximum length
} bt_service_record_t;

/** Bluetooth Remote Version info */
typedef struct {
  int version;
  int sub_ver;
  int manufacturer;
} bt_remote_version_t;

typedef struct {
  uint16_t version_supported;
  uint8_t local_privacy_enabled;
  uint8_t max_adv_instance;
  uint8_t rpa_offload_supported;
  uint8_t max_irk_list_size;
  uint8_t max_adv_filter_supported;
  uint8_t activity_energy_info_supported;
  uint16_t scan_result_storage_size;
  uint16_t total_trackable_advertisers;
  bool extended_scan_support;
  bool debug_logging_supported;
  bool le_2m_phy_supported;
  bool le_coded_phy_supported;
  bool le_extended_advertising_supported;
  bool le_periodic_advertising_supported;
  uint16_t le_maximum_advertising_data_length;
} bt_local_le_features_t;

/* Bluetooth Adapter and Remote Device property types */
typedef enum {
  /* Properties common to both adapter and remote device */
  /**
   * Description - Bluetooth Device Name
   * Access mode - Adapter name can be GET/SET. Remote device can be GET
   * Data type   - bt_bdname_t
   */
  BT_PROPERTY_BDNAME = 0x1,
  /**
   * Description - Bluetooth Device Address
   * Access mode - Only GET.
   * Data type   - RawAddress
   */
  BT_PROPERTY_BDADDR,
  /**
&nb

报错d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZL8_stop_btv+0x18): undefined reference to `esp_spp_disconnect' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZL8_stop_btv+0x1c): undefined reference to `esp_spp_deinit' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZL16_spp_send_bufferv+0xc): undefined reference to `esp_spp_write' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZL8btSetPinv+0xc): undefined reference to `esp_bt_gap_set_pin' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZN15BluetoothSerial5beginE6Stringb+0x38): undefined reference to `esp_bt_gap_register_callback' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZN15BluetoothSerial5beginE6Stringb+0x3c): undefined reference to `esp_spp_register_callback' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZN15BluetoothSerial5beginE6Stringb+0x40): undefined reference to `esp_spp_init' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZN15BluetoothSerial5beginE6Stringb+0x44): undefined reference to `esp_bt_gap_set_security_param' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZN15BluetoothSerial5beginE6Stringb+0x48): undefined reference to `esp_bt_gap_set_cod' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZL10esp_spp_cb18esp_spp_cb_event_tP18esp_spp_cb_param_t+0x28): undefined reference to `esp_bt_gap_set_scan_mode' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZL10esp_spp_cb18esp_spp_cb_event_tP18esp_spp_cb_param_t+0x2c): undefined reference to `esp_spp_start_srv' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZL10esp_spp_cb18esp_spp_cb_event_tP18esp_spp_cb_param_t+0x30): undefined reference to `esp_spp_connect' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZL13esp_bt_gap_cb21esp_bt_gap_cb_event_tP21esp_bt_gap_cb_param_t+0x20): undefined reference to `esp_bt_gap_resolve_eir_data' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZL13esp_bt_gap_cb21esp_bt_gap_cb_event_tP21esp_bt_gap_cb_param_t+0x2c): undefined reference to `esp_bt_gap_cancel_discovery' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZL13esp_bt_gap_cb21esp_bt_gap_cb_event_tP21esp_bt_gap_cb_param_t+0x30): undefined reference to `esp_spp_start_discovery' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZL13esp_bt_gap_cb21esp_bt_gap_cb_event_tP21esp_bt_gap_cb_param_t+0x40): undefined reference to `esp_bt_gap_pin_reply' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o:(.literal._ZL13esp_bt_gap_cb21esp_bt_gap_cb_event_tP21esp_bt_gap_cb_param_t+0x44): undefined reference to `esp_bt_gap_ssp_confirm_reply' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o: in function `_stop_bt()': D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:714: undefined reference to `esp_spp_disconnect' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:715: undefined reference to `esp_spp_deinit' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o: in function `_spp_send_buffer()': D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:189: undefined reference to `esp_spp_write' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o: in function `btSetPin()': D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:153: undefined reference to `esp_bt_gap_set_pin' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o: in function `BluetoothSerial::begin(String, bool)': D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:651: undefined reference to `esp_bt_gap_register_callback' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o: in function `_init_bt': D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:664: undefined reference to `esp_spp_register_callback' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:664: undefined reference to `esp_spp_init' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:691: undefined reference to `esp_bt_gap_set_security_param' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:695: undefined reference to `esp_bt_gap_set_cod' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o: in function `esp_spp_cb(esp_spp_cb_event_t, esp_spp_cb_param_t*)': D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:265: undefined reference to `esp_bt_gap_set_scan_mode' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:271: undefined reference to `esp_spp_start_srv' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:284: undefined reference to `esp_spp_disconnect' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:364: undefined reference to `esp_spp_connect' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:388: undefined reference to `esp_spp_disconnect' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o: in function `esp_bt_gap_cb(esp_bt_gap_cb_event_t, esp_bt_gap_cb_param_t*)': D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:128: undefined reference to `esp_bt_gap_resolve_eir_data' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o: in function `get_name_from_eir': D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:130: undefined reference to `esp_bt_gap_resolve_eir_data' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: C:\Users\YL\AppData\Local\arduino\sketches\F636E5A98FDBB535A1CB89E56A45F6EF\libraries\BluetoothSerial\BluetoothSerial.cpp.o: in function `esp_bt_gap_cb(esp_bt_gap_cb_event_t, esp_bt_gap_cb_param_t*)': D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:457: undefined reference to `esp_bt_gap_cancel_discovery' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:458: undefined reference to `esp_spp_start_discovery' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:547: undefined reference to `esp_bt_gap_pin_reply' d:/yl/documents/arduino/arduimo_project/hardware/esp32/tools/xtensa-esp32s3-elf-gcc/esp-2021r2-patch5-8.4.0/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld.exe: D:\YL\Documents\Arduino\arduimo_project\hardware\esp32\hardware\esp32\2.0.7\libraries\BluetoothSerial\src/BluetoothSerial.cpp:558: undefined reference to `esp_bt_gap_ssp_confirm_reply' collect2.exe: error: ld returned 1 exit status exit status 1 Compilation error: exit status 1
最新发布
11-15
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值