ESPHome
2024.11.1
esphome
esphome
components
esp32_ble_client
ble_characteristic.h
Go to the documentation of this file.
1
#pragma once
2
3
#ifdef USE_ESP32
4
5
#include "
esphome/components/esp32_ble_tracker/esp32_ble_tracker.h
"
6
7
#include "ble_descriptor.h"
8
9
#include <vector>
10
11
namespace
esphome
{
12
namespace
esp32_ble_client {
13
14
namespace
espbt
=
esphome::esp32_ble_tracker
;
15
16
class
BLEService;
17
18
class
BLECharacteristic
{
19
public
:
20
~BLECharacteristic
();
21
bool
parsed
=
false
;
22
espbt::ESPBTUUID
uuid
;
23
uint16_t
handle
;
24
esp_gatt_char_prop_t
properties
;
25
std::vector<BLEDescriptor *>
descriptors
;
26
void
parse_descriptors
();
27
void
release_descriptors
();
28
BLEDescriptor
*
get_descriptor
(
espbt::ESPBTUUID
uuid);
29
BLEDescriptor
*
get_descriptor
(uint16_t uuid);
30
BLEDescriptor
*
get_descriptor_by_handle
(uint16_t handle);
31
esp_err_t
write_value
(uint8_t *new_val, int16_t new_val_size);
32
esp_err_t
write_value
(uint8_t *new_val, int16_t new_val_size, esp_gatt_write_type_t write_type);
33
BLEService
*
service
;
34
};
35
36
}
// namespace esp32_ble_client
37
}
// namespace esphome
38
39
#endif // USE_ESP32
esphome::esp32_ble_client::BLECharacteristic::~BLECharacteristic
~BLECharacteristic()
Definition:
ble_characteristic.cpp:14
esp32_ble_tracker.h
esphome::esp32_ble_client::BLECharacteristic::properties
esp_gatt_char_prop_t properties
Definition:
ble_characteristic.h:24
esphome::esp32_ble::ESPBTUUID
Definition:
ble_uuid.h:14
esphome::esp32_ble_client::BLECharacteristic::write_value
esp_err_t write_value(uint8_t *new_val, int16_t new_val_size)
Definition:
ble_characteristic.cpp:92
esphome::esp32_ble_client::BLECharacteristic::release_descriptors
void release_descriptors()
Definition:
ble_characteristic.cpp:19
esphome::esp32_ble_client::BLECharacteristic::get_descriptor_by_handle
BLEDescriptor * get_descriptor_by_handle(uint16_t handle)
Definition:
ble_characteristic.cpp:71
esphome::esp32_ble_client::BLECharacteristic::parse_descriptors
void parse_descriptors()
Definition:
ble_characteristic.cpp:26
esphome::esp32_ble_client::BLECharacteristic::parsed
bool parsed
Definition:
ble_characteristic.h:21
esphome::esp32_ble_client::BLECharacteristic
Definition:
ble_characteristic.h:18
esphome::esp32_ble_client::BLECharacteristic::get_descriptor
BLEDescriptor * get_descriptor(espbt::ESPBTUUID uuid)
Definition:
ble_characteristic.cpp:59
esphome::esp32_ble_client::BLECharacteristic::service
BLEService * service
Definition:
ble_characteristic.h:33
esphome::esp32_ble_client::BLEDescriptor
Definition:
ble_descriptor.h:14
esphome::esp32_ble_tracker
Definition:
automation.h:9
esphome::esp32_ble_client::BLECharacteristic::descriptors
std::vector< BLEDescriptor * > descriptors
Definition:
ble_characteristic.h:25
esphome::esp32_ble_client::BLEService
Definition:
ble_service.h:18
esphome
Implementation of SPI Controller mode.
Definition:
a01nyub.cpp:7
esphome::esp32_ble_client::BLECharacteristic::uuid
espbt::ESPBTUUID uuid
Definition:
ble_characteristic.h:22
esphome::esp32_ble_client::BLECharacteristic::handle
uint16_t handle
Definition:
ble_characteristic.h:23
Generated by
1.8.13