Closed kennydossantos closed 2 years ago
Run the Read_User_Setup sketch, check the serial monitor output. Post a copy of the output here.
`[code] TFT_eSPI ver = 2.4.51 Processor = ESP32 Frequency = 240MHz Transactions = Yes Interface = SPI Display driver = 9341 Display width = 240 Display height = 320
MOSI = GPIO 23 SCK = GPIO 18 TFT_CS = GPIO 15 TFT_DC = GPIO 0 TFT_RST = GPIO 2 TOUCH_CS = GPIO 21
Font GLCD loaded Font 2 loaded Font 4 loaded Font 6 loaded Font 7 loaded Font 8 loaded Smooth font enabled
Display SPI frequency = 27.00 Touch SPI frequency = 2.50 [/code]`
I think that I've done it right, I couldn't upload it on the Arduino IDE it said "Error compiling for board ESP32 Dev Module, so I did it on the web arduino editor and I got this result.
I assumed you had it wired according to the sketch comments, viz:
//
// pin on TFT pin on ESP32 Dev Kit
// VCC V5 (+5 Volt)
// GND GND (DO NOT USE THE ONE NEXT TO V5!)
// CS G15 (chip select)
// RESET G4
// D/C G2 (device instruction)
// SDI G23 (SPI MOSI)
// SCK G18 (SPI clock)
// LED 3V3 (3.3>V for backlight)
// SDO G19 (SPI MISO)
// T_CLK G18 (Touch SPI clock)
// T_CS G21 (Chipselect Touch)
// T_DIN G23 (SPI MOSI)
// T_DO G19 (SPI MISO)
// T_IRQ not used, leave open!
//
The setup however allocates DC and RST to use different pins, is that what you intended?
How have you wired, it (I can't see clearly from the photos)?
Compare your wiring to the Read_User_Setup output.
Have you tried any other library examples?
Hi thanks for the fast responses, I have wired them as the code says. What do you mean I have allocated DC and RST to different pins, should they be connected to the same pin. And if so how do I do that with female-to-female wires?
I have compared the Read_User_Setup with my pins and these do not match with reality TFT_DC = GPIO 0 TFT_RST = GPIO 2
Use the pins reported by Read_User_Setup.
Oh, hahah now it works. Thank you so much, I only have one problem left. And that is that the touch is not working. Could you take a look?
Thanks
It looks like you have not connected all these pins: // T_CLK G18 (Touch SPI clock) // T_CS G21 (Chipselect Touch) // T_DIN G23 (SPI MOSI) // T_DO G19 (SPI MISO)
T_DO T_DIN Both pins are already connected but to different pins on the Screen.
For example it says T_DO G19, but SDO is also connected to G19 T_DIN G23 but SDI is also connected to G23
The other pins are connected.
Do you have any idea about my problem?
To minimise effort to resolve issues the following should be provided as a minimum: