BuyDisplay 4.3" TFT LCD screen doesn't do anything (SSD1963 TFT_eSPI with ESP32)

Just bought a 4.3" tft lcd display from BuyDisplay (3.3V with the 40 pins) and I am using TFT_eSPI from Bodmer. Controlling it with ESP32 in 8-bit parallel mode. My issue is that although the backlight turns on (after wiring it to pin 18 and setting it to HIGH in setup()), that's it, nothing happens on the screen. I selected setup 50, wired it using the default pins, and this is the output of the Read_User_Setup example:

TFT_eSPI ver = 2.3.70
Processor = ESP32
Frequency = 240MHz
Transactions = Yes
Interface = Parallel
Display driver = 1963
Display width = 480
Display height = 800

TFT_CS = GPIO 33
TFT_DC = GPIO 15
TFT_RST = GPIO 32
TFT_WR = GPIO 4
TFT_RD = GPIO 2

TFT_D0 = GPIO 12
TFT_D1 = GPIO 13
TFT_D2 = GPIO 26
TFT_D3 = GPIO 25
TFT_D4 = GPIO 17
TFT_D5 = GPIO 16
TFT_D6 = GPIO 27
TFT_D7 = GPIO 14

Font GLCD loaded
Font 2 loaded
Font 4 loaded
Font 6 loaded
Font 7 loaded
Font 8 loaded
Smooth font enabled

I ran the Colour_Test example; the backlight turns on but nothing shows up. I ran the TFT_ReadWrite_Test, and it just keeps giving error (always reading 2695). I am currently using 30 cm wires, and I know shorter ones are better (ordered 10 cm ones) but I feel like the screen should at least display something, however ugly it may look. I double checked all the wiring to ESP32. Everything is as it should be in the documentation (with 8-bit mode, so only DB0-7 are wired to ESP32) except pin 8 is listed as "tearing effect" which I wasn't sure what to do with, so I left it not connected to anything. I do not need the touch screen so I left pins 33-36 disconnected. Not sure if that affects anything.

Pin documentation from BuyDisplay

You have made no attempt to configure the IM# pins to 8080-8 mode.

Or to post a link to the actual display that you have bought.

I believe that you have written to another thread where a punter has been successful with 8080-8 mode.

David.

I'm not sure what you mean by "configure the IM# pins to 8080-8 mode"

Also, this is my first post here so I think you are confusing me with someone else?

Thanks for the link. There is no mention of IM# pins or any jumpers.
It does not seem possible to configure hardware for 8080-8 or 8080-9 or 8080-18 or 8080-24 like you do with other makes of controller.

Checking the SSD1963 datasheet, you use command 0xF0

I suggest that you search for the recent "SSD1963 BuyDisplay" thread.
And look for any TFT_eSPI support for SSD1963 e.g.
C:\Users\ ...\Documents\Arduino\libraries\TFT_eSPI\User_Setups\Setup50_SSD1963_Parallel.h

David.

Thanks for the idea. I looked into it, but it looks like it should already be doing that. If you look in ..../TFT_eSPI/TFT_Drivers/SSD1963_init.h

writecommand(0xF0);   //pixel data interface
writedata(0x00);      //000 = 8 bit bus, 011 = 16 bit, 110 = 9 bit

I undid and redid all the wiring in case I had messed something up. Turns out, I had mixed up the write and read wires, or so I thought. I wired it up so that read on the ESP32 goes to write on the TFT, and read on the TFT goes to write on the ESP32. That yielded the same results as yesterday. I switched them around just to see what would happen, and lo and behold, I ran the write/read test sketch, and:

PASS 
 Pixel value written = 400
 Pixel value read    = 400

Now I am very confused. This happened with write connected to write and read connected to read. Is this not the incorrect wiring?

In any case, the screen still just stays black and I still haven't gotten any color out of it. I am starting to think there's either something really stupid I have messed up, or that the screen is broken.

Turns out, it was the "something really stupid." I plugged the ESP32 into the wall instead of my laptop and it works.

And now I am very baffled because it works from my laptop as well.

So TFT_eSPI is working 100% now.

As I said in an earlier message, I have never run SSD1963 in 8080-8 interface mode. Only used 8080-16 mode.

I might try 8080-8 on a Due tomorrow.
It is far too much work to try with an ESP32.

David.

Yes. I mean, I'm happy, but at the same time I am annoyed because I don't know why it worked. I am 90% sure I have the same wiring as yesterday. I uploaded the color test sketch from my laptop and nothing happened. I literally just unplugged the usb from my computer and plugged it into a phone charger that was in the wall, and the screen works, colors and everything. I plugged it back into my laptop thinking, oh well, it'll just be one extra step to test my sketches, and bam. It turns on.

I take it back. It worked for about an hour, then stopped. I have no idea when or why it decides to work or not work. I upload a sketch, it doesn't work. I plug into the wall, it works. I plug into my laptop, it works. I plug into my xbox, it works. I upload a new sketch, it works. I upload a new sketch, it doesn't work. Plug it into every socket in the house, doesn't work. It is very frustrating.

After more testing, the screen has some very annoying and frustrating behavior. It seems the screen does not want to initialize upon uploading a new sketch. Through serial monitor printouts I can tell the sketch is working and the screen is sending and receiving the correct data, but the screen just doesn't want to do anything. Sometimes, for whatever reason, after waiting a while and rebooting the esp32, the screen starts up fine and works perfectly. From that point on it will work every single time after. However, uploading a new sketch kills it, and even after waiting, some sketches never work at all. Clearly the screen works because some sketches work fine, but there is some weird bug and I do not know what is going on. Sketches with literally identical setup code don't do the same thing. I have gotten some shorter (10 cm) wires and that did not change anything. I am ready to give up and try to find a new/different screen.

No, I have not got around to plugging in SSD1963 and Due.

However, I have always been sceptical of ESP32 and 8080-8 Shields.
The Shield ensures robust and accurate wiring.

MCUFRIEND_kbv programs are reliable on the TTGO ESP32 board.
But less reliable on a ProtoShield + ESP32 module combination.
I would never trust 8080-8 with random floating Dupont wires.

I have not really made much use of TFT_eSPI with parallel displays.
TFT_eSPI is very reliable with SPI displays. I have had programs running for days.

David.

What gets me is the fact that once it decides to work, it works infallibly every time upon resetting or unplugging and re-plugging esp32. I really don't understand how that is possible