Hi,
I have several ESP8266 devices working nicely with ESPHome and Home Assistant but am struggling to get the initial compile and install to work on two new ESP32 devices. I’ve read the troubleshooting info in Github and other articles but not yet found a solution.
I am using the ESPHome interface in Home Assistant (as I did previously with the ESP8266 devices).
but when I get to the compile stage it is throwing up warnings, which may or may not have anything to do with it:
Compiling /data/ha-glow/.pioenvs/ha-glow/FrameworkArduino/esp32-hal-time.c.o
/data/cache/platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-spi.c: In function 'spiTransferBytesNL':
/data/cache/platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-spi.c:922:39: warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]
uint8_t * last_out8 = &result[c_longs-1];
^
/data/cache/platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-spi.c:923:40: warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]
uint8_t * last_data8 = &last_data;
^
Maybe as a result of this, but perhaps also not, I am then getting an error right at the end of the install process:
Archiving /data/ha-glow/.pioenvs/ha-glow/libFrameworkArduino.a
Linking /data/ha-glow/.pioenvs/ha-glow/firmware.elf
RAM: [= ] 12.6% (used 41180 bytes from 327680 bytes)
Flash: [===== ] 48.5% (used 889450 bytes from 1835008 bytes)
Building /data/ha-glow/.pioenvs/ha-glow/firmware.bin
esp32_create_combined_bin(["/data/ha-glow/.pioenvs/ha-glow/firmware.bin"], ["/data/ha-glow/.pioenvs/ha-glow/firmware.elf"])
Generating combined binary for serial flashing
Offset | File
- 0x1000 | /data/cache/platformio/packages/framework-arduinoespressif32/tools/sdk/bin/bootloader_dio_40m.bin
- 0x8000 | /data/ha-glow/.pioenvs/ha-glow/partitions.bin
- 0xe000 | /data/cache/platformio/packages/framework-arduinoespressif32/tools/partitions/boot_app0.bin
- 0x10000 | /data/ha-glow/.pioenvs/ha-glow/firmware.bin
Using esptool.py arguments: --chip esp32 merge_bin -o /data/ha-glow/.pioenvs/ha-glow/firmware-factory.bin --flash_size 4MB 0x1000 /data/cache/platformio/packages/framework-arduinoespressif32/tools/sdk/bin/bootloader_dio_40m.bin 0x8000 /data/ha-glow/.pioenvs/ha-glow/partitions.bin 0xe000 /data/cache/platformio/packages/framework-arduinoespressif32/tools/partitions/boot_app0.bin 0x10000 /data/ha-glow/.pioenvs/ha-glow/firmware.bin
Wrote 0xe92d0 bytes to file /data/ha-glow/.pioenvs/ha-glow/firmware-factory.bin, ready to flash to offset 0x0
======================== [SUCCESS] Took 150.39 seconds ========================
INFO Successfully compiled program.
esptool.py v3.2
Serial port /dev/ttyACM1
Connecting......................................
A fatal error occurred: Failed to connect to ESP32: No serial data received.
For troubleshooting steps visit: https://github.com/espressif/esptool#troubleshooting
INFO Upload with baud rate 460800 failed. Trying again with baud rate 115200.
esptool.py v3.2
Serial port /dev/ttyACM1
Connecting......................................
A fatal error occurred: Failed to connect to ESP32: No serial data received.
For troubleshooting steps visit: https://github.com/espressif/esptool#troubleshooting
I’m using HA 2021-12-10 on HA OS 7.2 on a Raspberry Pi 4 Model B. The ESP module is plugged into one of the USB ports on the Pi, which I selected during the guided installation process. The board is still bare, with nothing connected to any of the pins.
During the install I tried initially specifying a generic ESP32 and when it didn’t work, based on reading other posts, etc. I tried it as a NodeMCU-32S which most closely matches what’s on the device: “Espressif ESP32-WROOM-32”
There is a printed label on the packaging which says to press the ‘BOOT’ button during the initial connecting phase on the install. I have tried it with and without doing that, and for different durations, but with the same result.
Please can you help shed some light on this and perhaps suggest how I might resolve this?
Thanks,
Phil