Do not use Serial2 for ESP32C3, too (#1798)

src/esphome/components/logger/logger.cpp: In member function 'void esphome::logger::Logger::pre_setup()':
src/esphome/components/logger/logger.cpp:142:29: error: 'Serial2' was not declared in this scope
         this->hw_serial_ = &Serial2;
This commit is contained in:
André Klitzing 2021-05-18 09:16:51 +02:00 committed by GitHub
parent d3e291b442
commit dce9d59dfe
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -136,7 +136,7 @@ void Logger::pre_setup() {
break; break;
#ifdef ARDUINO_ARCH_ESP32 #ifdef ARDUINO_ARCH_ESP32
case UART_SELECTION_UART2: case UART_SELECTION_UART2:
#if !CONFIG_IDF_TARGET_ESP32S2 #if !CONFIG_IDF_TARGET_ESP32S2 && !CONFIG_IDF_TARGET_ESP32C3
// FIXME: Validate in config that UART2 can't be set for ESP32-S2 (only has // FIXME: Validate in config that UART2 can't be set for ESP32-S2 (only has
// UART0-UART1) // UART0-UART1)
this->hw_serial_ = &Serial2; this->hw_serial_ = &Serial2;