Same old story. I bought some displays from ebay but I can’t get them to work. However, this story is just a bit different.
I tried the driver from the vendor, but all I get is a white screen (the backlight is on). I tried a few other drivers, with the same effect. I found some modified UTFT drivers at the following Youtube link. (I had to use Code tags to keep the video from being embedded). The link to the modified library is in the first comment.
At first, I had the same white screen. Then, I noticed that when I went to program the Arduino Uno, the display would show graphics for a few seconds, then go all white again. This is repeatable and the graphics on the screen are whatever is currently being drawn, so the program is obviously running.
Why would programming the Arduino cause the graphics to appear briefly? More importantly, what do I need to change to make them appear all the time, as they should?
After more fooling around, I found that it has something to do with the Arduino Reset. Whenever I press Reset, whatever image was being drawn at the time appears on the screen. This is presumably from the screens internal RAM buffer.
Some slight progress.
Using the modified UTFT library, the demo program is assuming a SPFD5408B controller for the 2.6" display. When I press the Uno's Reset and get an image (as I mentioned above), everything is swapped left/right and the text is mirrored.
I noticed that some code in the demo program that reads the LCD ID was commented out. Uncommenting a few lines gave me an ID of "9325", which matches ILI9325C and D, not the SPFD5408B this display was supposed to have.
Using ILI9325D_8, the text is correct, not mirrored. So, it seems that I had the wrong controller. Even with the change in controller, I still get nothing but a white screen, unless I press reset on the Uno to freeze the LCD at some point during the program run. I have checked that the pin assignments are correct. I am fresh out of ideas. Can anyone help?
With some additional information (like a link to the datasheet of your display) help could be provided more easily.
It’s from ebay. There is no datahseet.
If you look at the ebay listing, there is a picture of the bottom of the board with the pinout silkscreened. This is similar to other 2.4", 2.6" and 2.8" boards found on ebay.
Try this driver.
Hope this help.
ATFT.zip (1.33 MB)
That looks very much like the library that came with the display. I tried it anyway, but it still does the same as the other libraries I have tried.
Just in case anyone else comes across this thread while trying to get one of these cheap Chinese 2.6" TFTs to work...
I had the same experience that the display would only show for a brief moment when the Arduino was undergoing a reset, and showed a blank white screen the rest of the time while the sketch was running. This was mostly using the Adafruit_TFTLCD library which recognises the driver as an ILI9325. I then discovered (while using a Nano, but the same is true for a Uno as well) that the display would work (with caveats, see below) if the Arduino was NOT connected to USB, but running off an external power supply instead. I have no idea why this should be the case, as there are no connections to D0 and D1, but it is consistently the case for me that the display is always white if USB is connected, but may work if it is not. So it's worth giving that a try if you have this issue, and don't need to have a simultaneous serial connection.
Unfortunately, in my case there is also clearly a fault in the TFT display as well. Sometimes the display remains white, sometimes it is bright with low contrast (actually due to white lines across the display on alternate rows) and occasionally is perfect. This depends in an apparently random but very sensitive way on the angle the display is held, how it's been handled and so on. Presumably there are bad contacts internally (or between the TFT and the shield) causing these problems. I think in my case the display is heading for the waste bin...
BTW, the micro SD card slot on these shields is a joke. There are no voltage level shifters, so it can only work if you have a card which will work out-of-spec on 5V. Needless to say, most won't.