Where do you configure the TFT_eSPI library for your display? Just including the library is not enough. You have to setup all the defines or an include file for the display.
The official Wiki for the board (no touch version) at
Compiling .pio/build/esp32-s3-devkitc-1/liba86/SPI/SPI.cpp.o
In file included from src/main.cpp:2:
lib/TFT_eSPI/TFT_eSPI.h:973:8: warning: #warning >>>>------>> TOUCH_CS pin not defined, TFT_eSPI touch functions will not be available! [-Wcpp]
973 | #warning >>>>------>> TOUCH_CS pin not defined, TFT_eSPI touch functions will not be available!
| ^~~~~~~
src/main.cpp:11:2: warning: #warning "Right screen type defiend" [-Wcpp]
11 | #warning "Right screen type defiend"
| ^~~~~~~
And press “upload and monitor” again. What’s the output?
Also, what is the platform and packages that PlatformIO uses? That’s printed at the beginning of the build output. For me, I’m on (pioarduino) platform 54.3.20 with Arduino-ESP 3.2.0
Arduino cores before 2.0.16 did not define REG_SPI_BASE, so TFT_eSPI defines it in this case to always DR_REG_SPI2_BASE as a bugfix. Arduino cores after 2.0.16 do define it to
Long story short the REG_SPI_BASE in IDF is wrong. Submitted a PR and espressif IDF messed the PR up by changing it. In my private fork i have corrected. To make the Bodmer TFT_eSPI (which is outdated BTW.) you have to manually override which SPI is used
its working thank you, but if exists this “bug” i should comment line lib/TFT_eSPI/USer_Setup_select.h:27 ?
I have this warnings without comment:
Compiling .pio/build/esp32-s3-devkitc-1/liba86/SPI/SPI.cpp.o
In file included from lib/TFT_eSPI/User_Setup_Select.h:158,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/../TFT_eSPI_Setups/Setup207_GC9A01.h:2: warning: "USER_SETUP_INFO" redefined
#define USER_SETUP_INFO "ESP32-S3-Touch-LCD-1.28"
In file included from lib/TFT_eSPI/User_Setup_Select.h:27,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/User_Setup.h:12: note: this is the location of the previous definition
#define USER_SETUP_INFO "User_Setup"
In file included from lib/TFT_eSPI/User_Setup_Select.h:158,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/../TFT_eSPI_Setups/Setup207_GC9A01.h:16: warning: "TFT_MISO" redefined
#define TFT_MISO -1
In file included from lib/TFT_eSPI/User_Setup_Select.h:27,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/User_Setup.h:170: note: this is the location of the previous definition
#define TFT_MISO PIN_D6 // Automatically assigned with ESP8266 if not defined
In file included from lib/TFT_eSPI/User_Setup_Select.h:158,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/../TFT_eSPI_Setups/Setup207_GC9A01.h:17: warning: "TFT_MOSI" redefined
#define TFT_MOSI 11
In file included from lib/TFT_eSPI/User_Setup_Select.h:27,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/User_Setup.h:171: note: this is the location of the previous definition
#define TFT_MOSI PIN_D7 // Automatically assigned with ESP8266 if not defined
In file included from lib/TFT_eSPI/User_Setup_Select.h:158,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/../TFT_eSPI_Setups/Setup207_GC9A01.h:18: warning: "TFT_SCLK" redefined
#define TFT_SCLK 10
In file included from lib/TFT_eSPI/User_Setup_Select.h:27,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/User_Setup.h:172: note: this is the location of the previous definition
#define TFT_SCLK PIN_D5 // Automatically assigned with ESP8266 if not defined
In file included from lib/TFT_eSPI/User_Setup_Select.h:158,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/../TFT_eSPI_Setups/Setup207_GC9A01.h:19: warning: "TFT_CS" redefined
#define TFT_CS 9 // Chip select control pin
In file included from lib/TFT_eSPI/User_Setup_Select.h:27,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/User_Setup.h:174: note: this is the location of the previous definition
#define TFT_CS PIN_D8 // Chip select control pin D8
In file included from lib/TFT_eSPI/User_Setup_Select.h:158,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/../TFT_eSPI_Setups/Setup207_GC9A01.h:20: warning: "TFT_DC" redefined
#define TFT_DC 8 // Data Command control pin
In file included from lib/TFT_eSPI/User_Setup_Select.h:27,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/User_Setup.h:175: note: this is the location of the previous definition
#define TFT_DC PIN_D3 // Data Command control pin
In file included from lib/TFT_eSPI/User_Setup_Select.h:158,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/../TFT_eSPI_Setups/Setup207_GC9A01.h:21: warning: "TFT_RST" redefined
#define TFT_RST 12
In file included from lib/TFT_eSPI/User_Setup_Select.h:27,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/User_Setup.h:176: note: this is the location of the previous definition
#define TFT_RST PIN_D4 // Reset pin (could connect to NodeMCU RST, see next line)
In file included from lib/TFT_eSPI/User_Setup_Select.h:158,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/../TFT_eSPI_Setups/Setup207_GC9A01.h:35: warning: "SPI_FREQUENCY" redefined
#define SPI_FREQUENCY 80000000
In file included from lib/TFT_eSPI/User_Setup_Select.h:27,
from lib/TFT_eSPI/TFT_eSPI.h:69,
from src/main.cpp:2:
lib/TFT_eSPI/User_Setup.h:363: note: this is the location of the previous definition
#define SPI_FREQUENCY 27000000
In file included from src/main.cpp:2:
lib/TFT_eSPI/TFT_eSPI.h:973:8: warning: #warning >>>>------>> TOUCH_CS pin not defined, TFT_eSPI touch functions will not be available! [-Wcpp]
#warning >>>>------>> TOUCH_CS pin not defined, TFT_eSPI touch functions will not be available!