This is the top of my yaml:
esphome:
name: myesp32s2
friendly_name: myESP32S2
esp32:
board: lolin_s2_mini #esp32-s2-saola-1
framework:
type: arduino
# Enable logging
logger:
# Enable Home Assistant API
api:
encryption:
key: "....."
ota:
password: "....."
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: "Myesp32S2 Fallback Hotspot"
password: "....."
captive_portal:
uart:
- id: uart_2
tx_pin: GPIO39 #marked as TXD on WEMOS ESP32S2 D1
rx_pin: GPIO37 #marked as RXD
baud_rate: 115200
stop_bits: 1
parity: none
… and this is the compilation errors:
INFO ESPHome 2023.6.5
INFO Reading configuration /config/esphome/myesp32s2.yaml...
INFO Generating C++ source...
INFO Compiling app...
Processing myesp32s2 (board: lolin_s2_mini; framework: arduino; platform: platformio/[email protected])
--------------------------------------------------------------------------------
HARDWARE: ESP32S2 240MHz, 320KB RAM, 4MB Flash
- toolchain-riscv32-esp @ 8.4.0+2021r2-patch5
- toolchain-xtensa-esp32s2 @ 8.4.0+2021r2-patch5
Dependency Graph
|-- AsyncTCP-esphome @ 1.2.2
|-- WiFi @ 2.0.0
|-- FS @ 2.0.0
|-- Update @ 2.0.0
|-- ESPAsyncWebServer-esphome @ 2.1.0
|-- DNSServer @ 2.0.0
|-- ESPmDNS @ 2.0.0
|-- noise-c @ 0.1.4
|-- Wire @ 2.0.0
Compiling /data/myesp32s2/.pioenvs/myesp32s2/src/esphome/components/uart/uart_component_esp32_arduino.cpp.o
Compiling /data/myesp32s2/.pioenvs/myesp32s2/src/main.cpp.o
src/esphome/components/uart/uart_component_esp32_arduino.cpp: In member function 'virtual void esphome::uart::ESP32ArduinoUARTComponent::setup()':
src/esphome/components/uart/uart_component_esp32_arduino.cpp:91:25: error: cannot convert 'USBCDC*' to 'HardwareSerial*' in assignment
this->hw_serial_ = &Serial;
^~~~~~
*** [/data/myesp32s2/.pioenvs/myesp32s2/src/esphome/components/uart/uart_component_esp32_arduino.cpp.o] Error 1
========================= [FAILED] Took 12.53 seconds =========================
Thanks for any help you can offer.
Regards, Martin