Open yaro24 opened 5 months ago
Who has the solution to the same problem?
Hello there, I pinned the commit before all the merges and confirm it is a regression.
Here for reference:
external_components:
- source: "github://geoffdavis/esphome-mitsubishiheatpump@31ed3068fcf0713873b157e28d0d36248a352d83"
Here for reference:
external_components: - source: "github://geoffdavis/esphome-mitsubishiheatpump@31ed3068fcf0713873b157e28d0d36248a352d83"
@FedericoAntoniazzi What do you mean exactly? Using that commit result in another compile error:
Compiling .pioenvs/mitsubishi-airco/lib05e/AsyncTCP-esphome/AsyncTCP.cpp.o
src/main.cpp: In function 'void setup()':
src/main.cpp:524:57: error: no matching function for call to 'MitsubishiHeatPump::MitsubishiHeatPump(HWCDC*)'
mitsubishiheatpump_id = new MitsubishiHeatPump(&Serial);
^
In file included from src/esphome.h:48,
from src/main.cpp:3:
src/esphome/components/mitsubishi_heatpump/espmhp.h:55:9: note: candidate: 'MitsubishiHeatPump::MitsubishiHeatPump(HardwareSerial*, uint32_t)'
MitsubishiHeatPump(
^~~~~~~~~~~~~~~~~~
src/esphome/components/mitsubishi_heatpump/espmhp.h:55:9: note: no known conversion for argument 1 from 'HWCDC*' to 'HardwareSerial*'
src/esphome/components/mitsubishi_heatpump/espmhp.h:44:7: note: candidate: 'MitsubishiHeatPump::MitsubishiHeatPump(const MitsubishiHeatPump&)'
class MitsubishiHeatPump : public PollingComponent, public climate::Climate {
^~~~~~~~~~~~~~~~~~
src/esphome/components/mitsubishi_heatpump/espmhp.h:44:7: note: no known conversion for argument 1 from 'HWCDC*' to 'const MitsubishiHeatPump&'
src/esphome/components/mitsubishi_heatpump/espmhp.h:44:7: note: candidate: 'MitsubishiHeatPump::MitsubishiHeatPump(MitsubishiHeatPump&&)'
src/esphome/components/mitsubishi_heatpump/espmhp.h:44:7: note: no known conversion for argument 1 from 'HWCDC*' to 'MitsubishiHeatPump&&'
Never mind, seems the ESP32-C3 with its default logger port being USB_CDC
together with this external component causes this compile error. Configuring the logger port as UART0
similarly to the ESP32 seems to work:
logger:
hardware_uart: UART0
baud_rate: 0
This got it working for me with a Wemos ESP32-S2-mini v1.0.0 https://www.wemos.cc/en/latest/s2/s2_mini.html
external_components:
- source: github://geoffdavis/esphome-mitsubishiheatpump@2.5.0
esphome:
platformio_options:
build_flags:
- -std=gnu++17
build_unflags:
- -std=gnu++11
esp32:
board: lolin_s2_mini
variant: esp32s2
framework:
type: arduino
https://github.com/SwiCago/HeatPump/issues/13#issuecomment-2222657355
Hello there, I pinned the commit before all the merges and confirm it is a regression.
Here for reference:
external_components: - source: "github://geoffdavis/esphome-mitsubishiheatpump@31ed3068fcf0713873b157e28d0d36248a352d83"
confirmed this version works for me
This got it working for me with a Wemos ESP32-S2-mini v1.0.0 https://www.wemos.cc/en/latest/s2/s2_mini.html
external_components: - source: github://geoffdavis/esphome-mitsubishiheatpump@2.5.0 esphome: platformio_options: build_flags: - -std=gnu++17 build_unflags: - -std=gnu++11 esp32: board: lolin_s2_mini variant: esp32s2 framework: type: arduino
Can confirm this worked for me on a cheap clone ESP32. Reverting to a previous commit also worked, but I'd rather be running the latest.
@adeptcain Thanks for tracking this down. Looks like one of the newer commits starting using C++17 code, and the ESP8266 toolchain is totally fine with it.
@SCUZNUTS and @yaro24 please verify that the "platformio_options" that @adeptcain provided work for your boards, and I'll update the documentation for the ESP32.
Can confirm, doing the above works for me;
esp32:
board: esp32-c3-devkitm-1
framework:
type: arduino
external_components:
- source: github://geoffdavis/esphome-mitsubishiheatpump
esphome:
platformio_options:
build_flags:
- -std=gnu++17
build_unflags:
- -std=gnu++11
@geoffdavis thanks, but it was @jonathandann who found the fix by the looks of it, I was just confirming it works for me :)
With both the current versions of mhp and esphome I can't compile the projects anymore.
Here's the config:
Here's the log output:
Please let me know if you need any more information or testing