-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
error: call of overloaded 'millis()' #18
Comments
Hi Oli, INFO ESPHome 2023.11.4 sensor.junctek_khf: [source /config/esphome/esphome-web-daa12b.yaml:40] [ah_total_used] is an invalid option for [sensor.junctek_khf]. Please check the indentation. Can you help me repair this error? |
@krasa's fix does indeed work, but I can't seem to use the rest of the repo for some reason I haven't had time to debug. @tfyoung I opened a PR that addresses the compilation issues without the other changes in @krasa's fork, if you'd be open to merging #23 it would make the component usable again. In the meantime, it's easy to use this PR like so external_components:
- source:
type: git
url: https://github.com/tfyoung/esphome-junctek_kgf.git
ref: pull/23/head
components: [junctek_kgf] |
MQTT Integration Example: Functional Code for Direct Implementation (Thanks to jbergler and @krasa) Enable MQTTmqtt: captive_portal: Publish sensor values to MQTTtime:
interval:
|
Hi.
I try to compile your code with esphome 2023.7.1 and get errors like that:
src/esphome/components/junctek_kgf/junctek_kgf.cpp: In member function 'void JuncTekKHF::handle_settings(const char*)': src/esphome/components/junctek_kgf/junctek_kgf.cpp:91:33: error: call of overloaded 'millis()' is ambiguous this->last_settings_ = millis(); ^ In file included from /config/.esphome/platformio/packages/framework-arduinoespressif32/cores/esp32/Arduino.h:36, from .piolibdeps/junctek-khf/ArduinoJson/src/ArduinoJson/Configuration.hpp:156, from .piolibdeps/junctek-khf/ArduinoJson/src/ArduinoJson.hpp:7, from .piolibdeps/junctek-khf/ArduinoJson/src/ArduinoJson.h:9, from src/esphome/components/json/json_util.h:11, from src/esphome/core/string_ref.h:10, from src/esphome/core/entity_base.h:5, from src/esphome/components/sensor/sensor.h:5, from src/esphome/components/junctek_kgf/junctek_kgf.h:4, from src/esphome/components/junctek_kgf/junctek_kgf.cpp:1: /config/.esphome/platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal.h:131:15: note: candidate: 'long unsigned int millis()' unsigned long millis(); ^~~~~~ In file included from src/esphome/components/uart/uart.h:5, from src/esphome/components/junctek_kgf/junctek_kgf.h:5, from src/esphome/components/junctek_kgf/junctek_kgf.cpp:1: src/esphome/core/hal.h:37:10: note: candidate: 'uint32_t esphome::millis()' uint32_t millis(); ^~~~~~ src/esphome/components/junctek_kgf/junctek_kgf.cpp: In member function 'void JuncTekKHF::handle_status(const char*)': src/esphome/components/junctek_kgf/junctek_kgf.cpp:133:30: error: call of overloaded 'millis()' is ambiguous this->last_stats_ = millis(); ^ In file included from /config/.esphome/platformio/packages/framework-arduinoespressif32/cores/esp32/Arduino.h:36,
Can you help me to get rid of this errors?
Thanks, Oli
The text was updated successfully, but these errors were encountered: