You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
from src/esphome/components/homekit/HAPAccessory.cpp:1:
src/esphome/components/homekit/switch.hpp:17:12: error: 'map' in namespace 'std' does not name a template type
17 | std::map<AInfo, const char*> accessory_info = {{NAME, NULL}, {MODEL, "HAP-SWITCH"}, {SN, NULL}, {MANUFACTURER, "rednblkx"}, {FW_REV, "0.1"}};
| ^~~
src/esphome/components/homekit/switch.hpp:8:1: note: 'std::map' is defined in header '<map>'; did you forget to '#include <map>'?
7 | #include <hap_apple_chars.h>
+++ |+#include <map>
8 |
src/esphome/components/homekit/switch.hpp:56:20: error: 'std::map' has not been declared
56 | void setInfo(std::map<AInfo, const char*> info) {
| ^~~
src/esphome/components/homekit/switch.hpp:56:28: error: expected ',' or '...' before '<' token
56 | void setInfo(std::map<AInfo, const char*> info) {
| ^
src/esphome/components/homekit/switch.hpp: In member function 'void esphome::homekit::SwitchEntity::setInfo(int)':
src/esphome/components/homekit/switch.hpp:57:14: error: 'map' is not a member of 'std'
57 | std::map<AInfo, const char*> merged_info;
| ^~~
src/esphome/components/homekit/switch.hpp:57:14: note: 'std::map' is defined in header '<map>'; did you forget to '#include <map>'?
src/esphome/components/homekit/switch.hpp:57:23: error: expected primary-expression before ',' token
57 | std::map<AInfo, const char*> merged_info;
| ^
src/esphome/components/homekit/switch.hpp:57:25: error: expected primary-expression before 'const'
57 | std::map<AInfo, const char*> merged_info;
| ^~~~~
src/esphome/components/homekit/switch.hpp:58:9: error: 'merged_info' was not declared in this scope
58 | merged_info.merge(info);
| ^~~~~~~~~~~
src/esphome/components/homekit/switch.hpp:58:27: error: 'info' was not declared in this scope
58 | merged_info.merge(info);
| ^~~~
src/esphome/components/homekit/switch.hpp:59:33: error: 'class esphome::homekit::SwitchEntity' has no member named 'accessory_info'
59 | merged_info.merge(this->accessory_info);
| ^~~~~~~~~~~~~~
src/esphome/components/homekit/switch.hpp:60:15: error: 'class esphome::homekit::SwitchEntity' has no member named 'accessory_info'
60 | this->accessory_info.swap(merged_info);
| ^~~~~~~~~~~~~~
src/esphome/components/homekit/switch.hpp: In member function 'void esphome::homekit::SwitchEntity::setup()':
src/esphome/components/homekit/switch.hpp:64:29: error: 'accessory_info' was not declared in this scope
64 | .model = strdup(accessory_info[MODEL]),
| ^~~~~~~~~~~~~~
Compiling .pioenvs/wasserzyklus/src/esphome/components/logger/logger_esp8266.cpp.o
Compiling .pioenvs/wasserzyklus/src/esphome/components/logger/logger_host.cpp.o
*** [.pioenvs/wasserzyklus/src/esphome/components/homekit/HAPAccessory.cpp.o] Error 1
src/esphome/components/homekit_base/HAPRootComponent.cpp: In constructor 'esphome::homekit::HAPRootComponent::HAPRootComponent(const char*, const char*, std::map<esphome::homekit::AInfo, const char*>)':
src/esphome/components/homekit_base/HAPRootComponent.cpp:48:27: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
48 | .hw_rev = "1.0",
| ^~~~~
src/esphome/components/homekit_base/HAPRootComponent.cpp:52:13: warning: missing initializer for member 'hap_acc_cfg_t::hw_finish' [-Wmissing-field-initializers]
52 | };
| ^
src/esphome/components/homekit_base/HAPRootComponent.cpp:49:23: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
49 | .pv = "1.1.0",
| ^~~~~~~
when I use light instead of switch (again, like in the example), everything works fine.
System: MacOS 14.6.1, ESPHome 2024.12.2 (installed via homebrew). cmake 3.16.4
Did I make a configuration error, or is this actually a bug?
The text was updated successfully, but these errors were encountered:
I have a simple configuration, mostly copied from the example.
When compiling I get the following errors
when I use light instead of switch (again, like in the example), everything works fine.
System: MacOS 14.6.1, ESPHome 2024.12.2 (installed via homebrew). cmake 3.16.4
Did I make a configuration error, or is this actually a bug?
The text was updated successfully, but these errors were encountered: