From d6c6e8843a43380d0e21691e951aad87226cec27 Mon Sep 17 00:00:00 2001 From: lovyan03 <42724151+lovyan03@users.noreply.github.com> Date: Sun, 19 May 2024 19:45:37 +0900 Subject: [PATCH] tweak for ESP32C6 --- src/lgfx/v1/platforms/device.hpp | 8 +++++++- src/lgfx/v1/platforms/esp32/common.cpp | 7 ++++--- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/src/lgfx/v1/platforms/device.hpp b/src/lgfx/v1/platforms/device.hpp index 182886f4..961cadbf 100644 --- a/src/lgfx/v1/platforms/device.hpp +++ b/src/lgfx/v1/platforms/device.hpp @@ -21,7 +21,13 @@ Original Source: #include - #if defined (CONFIG_IDF_TARGET_ESP32C3) + #if defined (CONFIG_IDF_TARGET_ESP32C6) + + #include "esp32/Light_PWM.hpp" + #include "esp32/Bus_SPI.hpp" + #include "esp32/Bus_I2C.hpp" + + #elif defined (CONFIG_IDF_TARGET_ESP32C3) #include "esp32/Light_PWM.hpp" #include "esp32/Bus_SPI.hpp" diff --git a/src/lgfx/v1/platforms/esp32/common.cpp b/src/lgfx/v1/platforms/esp32/common.cpp index 41a10231..b738b393 100644 --- a/src/lgfx/v1/platforms/esp32/common.cpp +++ b/src/lgfx/v1/platforms/esp32/common.cpp @@ -110,12 +110,13 @@ Original Source: #if !defined (DMA_IN_PERI_SEL_CH0_REG) #define DMA_IN_PERI_SEL_CH0_REG GDMA_IN_PERI_SEL_CH0_REG #endif -#endif -#if (ESP_IDF_VERSION < ESP_IDF_VERSION_VAL(5, 3, 0)) - #define SOC_GDMA_PAIRS_PER_GROUP_MAX SOC_GDMA_PAIRS_PER_GROUP + #if !defined (SOC_GDMA_PAIRS_PER_GROUP_MAX) + #define SOC_GDMA_PAIRS_PER_GROUP_MAX SOC_GDMA_PAIRS_PER_GROUP + #endif #endif + #if defined ( ARDUINO ) #if __has_include () #include