Hi David, this is amazing stuff!
I am particularly interested in seeing if your irk_enrollment component can be used to feed IRKs to the Private BLE Device integration that is now in HA core.
I am having trouble getting it to build.
I tried using the component block in my yaml, but it seems that esphome now requires the parent directory to be named components for it to consider importing it.
After cloning your repo locally and creating a symlink, it complained about not finding the text_sensor.h, adding an empty text_sensor: block to my yaml fixed that (the build setup seemed to not realise it needed to copy it in).
Now I am getting:
src/esphome/components/irk_enrollment/irk_enrollment.cpp: In member function 'virtual void esphome::irk_enrollment::IrkEnrollmentComponent::setup()':
src/esphome/components/irk_enrollment/irk_enrollment.cpp:39:84: error: no matching function for call to 'esphome::esp32_ble_server::BLEServer::create_service(int, bool)'
this->service_ = esp32_ble_server::global_ble_server->create_service(0x1812, true);
^
In file included from src/esphome/components/irk_enrollment/irk_enrollment.h:14,
from src/esphome/components/irk_enrollment/irk_enrollment.cpp:1:
src/esphome/components/esp32_ble_server/ble_server.h:54:8: note: candidate: 'void esphome::esp32_ble_server::BLEServer::create_service(esphome::esp32_ble::ESPBTUUID, bool, uint16_t, uint8_t)'
void create_service(ESPBTUUID uuid, bool advertise = false, uint16_t num_handles = 15, uint8_t inst_id = 0);
^~~~~~~~~~~~~~
src/esphome/components/esp32_ble_server/ble_server.h:54:8: note: no known conversion for argument 1 from 'int' to 'esphome::esp32_ble::ESPBTUUID'
Compiling .pioenvs/ttgotest/src/esphome/components/light/esp_color_correction.o
In file included from src/esphome/components/sensor/sensor.h:3,
from src/esphome/core/application.h:16,
from src/esphome/components/irk_enrollment/irk_enrollment.cpp:3:
src/esphome/components/irk_enrollment/irk_enrollment.cpp: In member function 'virtual void esphome::irk_enrollment::IrkEnrollmentComponent::loop()':
src/esphome/components/irk_enrollment/irk_enrollment.cpp:71:17: error: format '%s' expects argument of type 'char*', but argument 5 has type 'std::__cxx11::basic_string<char>' [-Werror=format=]
ESP_LOGI(TAG, " irk: %s", irkStr);
^~~~~~~~~~~~~~~
src/esphome/core/log.h:72:36: note: in definition of macro 'ESPHOME_LOG_FORMAT'
#define ESPHOME_LOG_FORMAT(format) format
^~~~~~
src/esphome/core/log.h:151:28: note: in expansion of macro 'esph_log_i'
#define ESP_LOGI(tag, ...) esph_log_i(tag, __VA_ARGS__)
^~~~~~~~~~
src/esphome/components/irk_enrollment/irk_enrollment.cpp:71:3: note: in expansion of macro 'ESP_LOGI'
ESP_LOGI(TAG, " irk: %s", irkStr);
^~~~~~~~
Compiling .pioenvs/ttgotest/src/esphome/components/light/esp_hsv_color.o
cc1plus: some warnings being treated as errors
*** [.pioenvs/ttgotest/src/esphome/components/irk_enrollment/irk_enrollment.o] Error 1
I suspect that it's just that some things have changed in esphome since you wrote the component.
Is this component something you'd be interested in updating for the current esphome (assuming it's not just something bone-headed I'm doing on my end, which is entirely possible!), or perhaps submitting to esphome for inclusion in core? I couldn't find a license statement so thought I'd check in with you to see what you are up for before getting in too deep myself :-)
There's a feature request in the esphome tracker that I'll link to this issue as well.
Hi David, this is amazing stuff!
I am particularly interested in seeing if your irk_enrollment component can be used to feed IRKs to the Private BLE Device integration that is now in HA core.
I am having trouble getting it to build.
I tried using the component block in my yaml, but it seems that esphome now requires the parent directory to be named
componentsfor it to consider importing it.After cloning your repo locally and creating a symlink, it complained about not finding the text_sensor.h, adding an empty
text_sensor:block to my yaml fixed that (the build setup seemed to not realise it needed to copy it in).Now I am getting:
I suspect that it's just that some things have changed in esphome since you wrote the component.
Is this component something you'd be interested in updating for the current esphome (assuming it's not just something bone-headed I'm doing on my end, which is entirely possible!), or perhaps submitting to esphome for inclusion in core? I couldn't find a license statement so thought I'd check in with you to see what you are up for before getting in too deep myself :-)
There's a feature request in the esphome tracker that I'll link to this issue as well.