Move esp32_ble_server to its own component (#1898)

This commit is contained in:
Jesse Hills
2021-06-12 08:31:15 +12:00
parent 4b91cfb7f9
commit 575badc690
24 changed files with 204 additions and 158 deletions
@@ -0,0 +1,18 @@
#include "ble_2902.h"
#include "esphome/components/esp32_ble/ble_uuid.h"
#ifdef ARDUINO_ARCH_ESP32
namespace esphome {
namespace esp32_ble_server {
BLE2902::BLE2902() : BLEDescriptor(esp32_ble::ESPBTUUID::from_uint16(0x2902)) {
this->value_.attr_len = 2;
uint8_t data[2] = {0, 0};
memcpy(this->value_.attr_value, data, 2);
}
} // namespace esp32_ble_server
} // namespace esphome
#endif