SOLVED-BIG 7 inch TFT Looks great- 1 issue.

In my quest to go bigger and better on TFTs I occasionally run into an issue, I have found a new issue and need some education from the TFT experts out there.

Hardware: Mega, Screen http://dx.com/p/i082510-800-x-480-7-tft-touch-screen-module-153336

Docs: SSD 1963 http://www.techtoys.com.hk/Components/SSD1963QL9/SSD1963_1.1.pdf
Board http://seller.tradeglobals.com:8089/SRMImages/ProductRequirement/20121030/7寸彩屏模块原理图.pdf

And of course the UTFT.

When I first received the TFT I noticed it has to be the best built TFT I have received (comparing elecfreaks, itead, sainsmart, misc ebay) I am sure there are only a few manufacturers but the group that made this one really put some quality assurance into it.
A few details: received the screen, noted it is a 5v operating board (no shield..nice!) Plugged directly to mega using the pins specified by the UFTF library documents (this is not a supported display- I figured I would use this as a learning experience). On the Mega I am using pins 22-41 and 3.3V, 5V, both gnds. On the screen 3.3, 5v, both gnds, D0-D15, RS, CS, WR, RST, and left RD disconnected as I do not need to read back from the screen.
Plugged in BAM came on but mirrored, I expected this based on another post. Jumped on the web found a modification to the UTFT.cpp file
“Change rotation to: LCD_Write_COM(0x36); //rotation”
LCD_Write_DATA(0x03);
WOW looks great running the UTFT example for the SSD1963_800, it is actually faster than I expected! Running a bit of my code, I will admit refresh is as I expected – slow; for my applications this is fine.
Now the part I need help with – I have no blue. No pixel will display blue. Also the color scheme is in (B, G, R), as opposed to (R, G, B). I attempted to modify the .h file to change the order but to no avail.

So I am confessing my ignorance to the forum courts: I do not know enough to make successful changes in the UTFT.cpp file to accomplish my goals.
Hopeful someone might have a suggestion on how to educate myself on understanding this issue.

I don't know much about TFT's nor the SSD1963 so this is really a shot in the dark, but if it's anything like the SSD1289 then you might be initializing it incorrectly. Take a look at page 71 in the SSD1289 datasheet (http://www.kosmodrom.com.ua/el/STM32-TFT/SSD1289.pdf). It shows that you can use 262k and 65k color in 16-bit mode. Perhaps you're initializing it in one of the 262k color modes? That way the display would receive what it thinks is the red and green data, then presumably you would send a command to move to the next pixel and the blue data would never be received. Seeing as the library already had other errors (the rotation) this could be a likely possibility. I'm not sure about the whole B,G,R vs. R,G,B though.

bob,
Thanks, that's a great idea I will look into that. I believe it is something such as this holding me up.
Oh just as a side note, no error in the library I'm using a tft it is not designed for.

Well, found something odd but do not fully understand what I doing :cold_sweat:.

In the UTFT.cpp:
LCD_Write_COM(0xF0); //pixel data interface
LCD_Write_DATA(0x03);

In the SSD1963 doc:
"9.74 set_pixel_data_interface
Command 0xF0
Parameters 1
D/C D7 D6 D5 D4 D3 D2 D1 D0 Hex
Command 0 1 1 1 1 0 0 0 0 F0
Parameter1 1 0 0 0 0 A2 A1 A0 xx
Description
Set the pixel data format to 8-bit / 9-bit / 12-bit / 16-bit / 16-bit(565) / 18-bit / 24-bit in the parallel host processor
interface. This command is used for display data only, the command format is always 8 bit.
A[2:0] : Pixel Data Interface Format (POR = 101)
000 8-bit
001 12-bit
010 16-bit packed
011 16-bit (565 format)
100 18-bit
101 24-bit
110 9-bit
Others Reserved

  • Note : The un-used data bus will be driven to ground by SSD1963, so don’t connect the un-used data bus to
    MCU."

So I tried .._DATA(0x02) this ,I think, should equate to 16 bit packed. Blue shows up but with an odd shadow and green disappears.So it does not appear that is the issue.

Oh, how I wish I could view whats in this file- http://m2.img.dxcdn.com/CDDriver/153336.docx

SOLVED!!!!!!!!!
Had to switch the LCD Spec
LCD_Write_COM(0 x B0);
LCD_Write_DATA(0x24); to (0x04); oddly enough switching it to 18 bit.

AHHH now for a cold one and to bask in the glory.

Thanks Bob for getting me strated in the right direction!

Glad I could help. Setting register 0xB0 to 0x04 instead of 0x24 enables 18-bit mode instead of 24-bit mode. These LCDs typically have 18 data lines, although only 16 of them are usually broken out onto boards. Since you originally had 24-bit mode enabled, the LCD was looking for at least 2 data writes. When you switched it to 18-bit mode, it looked in register 0xF0 to see which interface to use: 5,6,5 RGB in this case.

I've just bought this exact TFT too...

Please can you help me

Can you tell me exactly which TFT library you downloaded
List all the changes you needed to make and to which files
The connections you ended up with that worked, is it as below?

Is this right for the connections ?

Does this look right / what about pins 22-32 ??


| PIN | LABEL | PIN | PIN
| NUM | TFT | ARD | FUNCTION
| | | |
| | | |
| 1 | 3v3 | >> | 3v3 power
| 2 | GND | >> | Ground
| 3 | D0 | 22 |
| 4 | D1 | 23 |
| 5 | D2 | 24 |
| 6 | D3 | 25 |
| 7 | D4 | 26 |
| 8 | D5 | 27 |
| 9 | D6 | 28 |
| 10 | D7 | 29 |
| 11 | D8 | 30 |
| 12 | D9 | 31 |
| 13 | D10 | 32 |
| 14 | D11 | 33 |
| 15 | D12 | 34 |
| 16 | D13 | 35 |
| 17 | D14 | 36 |
| 18 | D15 | 37 |
| 19 | CS | 39 ? |
| 20 | RS | 38 ? |
| 21 | WR | 40 ? |
| 22 | RD | n/c |
| 23 | RST | 41 ? |
| 24 | TE | | Don't know
| 25 | TD0 | | MISO?
| 26 | INT | | Don't know
| 27 | TD1 | | MOSI?
| 28 | PWM | | Don't know
| 29 | TSCK | | Don't know
| 30 | PCS | | Don't know
| 31 | TCS | | Don't know
| 32 | SDCS | | Don't know
| 5V | 5V | 5V | Backlight +
| 0V | 0V | 0V | Backlight GND

I'm actually wanting to get this running on a Due

Also, did you get the micro SD card reader working too ??

I think I've found the relevant places to make the mods in the software but no graphics yet :frowning:

If you use the UTFT library most questions can be answered by the associated documentation. Pins- depends on what functions you plan to use with the screen I.e. SD card, touch, flash, etc..
The above post require knowledge of how to modify code. Reading through these post, reading the documentation from the chip manufacturer, and reading other forums will allow you to get things started.
Best of luck.

997_1:
If you use the UTFT library most questions can be answered by the associated documentation. Pins- depends on what functions you plan to use with the screen I.e. SD card, touch, flash, etc..
The above post require knowledge of how to modify code. Reading through these post, reading the documentation from the chip manufacturer, and reading other forums will allow you to get things started.
Best of luck.

I would just like to get the display working first....

I have the same screen and I have located the code parts that you have mentioned.

I have GND, 5v and 3v3 attached as mentioned

I have D0-D15 attached as mentioned which go to 22-37

I have then attached RS,CS,WR & RST as you stated in your opening post ie 38-41 with RD not connected.

I was just hoping that you might have missed something in your description as all I get is the backlight.

Cowasaki,
I understand you, "just want to get it working". Anything related with arduino other than base examples is challenging and requires research. Understand I have my hands full of other projects and life too.
I feel I should not have to say this, but in order to be of assistance I need- the IDE, the board, shield used (if any), code posted, modifications made to code listed and displayed. If you read through other forum post you find this is all the bare min. you must O.P. to get the proper help. Right now you are asking for help and I don't even know if you have a library installed. I hope you can see how I cannot be of assistance as you have not provided enough information.

997_1:
Cowasaki,
I understand you, "just want to get it working". Anything related with arduino other than base examples is challenging and requires research. Understand I have my hands full of other projects and life too.
I feel I should not have to say this, but in order to be of assistance I need- the IDE, the board, shield used (if any), code posted, modifications made to code listed and displayed. If you read through other forum post you find this is all the bare min. you must O.P. to get the proper help. Right now you are asking for help and I don't even know if you have a library installed. I hope you can see how I cannot be of assistance as you have not provided enough information.

Sorry, I thought I had mentioned my position......

  • I have the exact same screen you have with the 32pin header and 2 pin 5v backlight connection
  • I will be using the same UTFT library and have located the changes you said.
  • I am not using a shield, I am simply connecting it with a set of leads as per the table I posted (ie 5v, 3v3 & GND to corresponding connections on the screen, D0-D15 to pins 22-37, then RS to 38, CS to 39, WR to 40, RST to 41)
  • The IDE is version 1.52 and I am using a due. (the software compiles and uploads correctly)

Basically I ordered the 40 pin 3v3 version of the screen but I have been sent the wrong one, the 32 pin version. I am assuming that the voltage is still the same (unless they got that wrong too) so it should not actually matter too much if the connections are as I think ie as per the above.

So basically I connected the screen to the computer as per the connection table I showed and ran the demo for the 7" screen. (this is prior to making any software changes. I expected to get the same faulty output you did and then make your suggested changes to correct them)

I get no output but the backlight is on because it is hard wired on via the 5v connection.

I was initially just checking that my connections matched your connections as per the table.... I have no reason to think my screen is faulty or anything like that but no way to check it either just at he moment. I have ordered a shield just to rule out that issue but it could take a while to arrive and would rather get it working without the shield if at all possible.

I do appreciate any time you can spare to look over the above but first I was just checking that I had interpreted your connection scheme correctly.

Thanks..

I am not sure of the 32 pin option. Please post your code. Also please ask the manufacturer to send you the PCB diagram to verify the pin connection is the same as the one posted above. Make sure you are initializing on the ssd1963_800.
I have never installed a screen on a duo, I actually never run a screen on anything but a mega. In the event you get this to fire off you will quickly see why. The 7" is a daughnting task for the mega, much less a smaller chip.
If you really want to get into TFTs you might want to start smaller. Understanding how things work is vital and it is much easier to do once you have used one of the popular screens, ie the sainsmart 3.2.

Lastly, the changes noted above are for an exact configuration, leaning outside of this you will be on your own. Modifications to the .h and .cqq file are nessecary.
I apologize I can't be more help but you see above when I had my issues is was a matter of hours of trial and error and reading multiple forum postings trying to get to the heart of the issue. In less you are running a screen many people have used your troubles will be isolated to your experience.
Post the code, request the docs and post, post the link to the product, and I will make an effort to assist you.

I've just received a CTE TFT shield and connected it up getting exactly the same mirrored image that you got so basically I now need to implement that software change THEN reverse engineer the shield to work out where each line goes to then it is sorted.

In the demo program "CTE_70inch_800x480" the demo routine upto to sin wave demo just produce bars of colour with black vertical lines then move them around !!

Everything from the sine wave onwards works as expected.

Many thanks.... I will post once I've edited the software.....

I've edited the UTFT.cpp file with the change you suggested i.e....

LCD_Write_COM(0x36); //rotation
LCD_Write_DATA(0x03); //was 0x22 ****

in the section starting:

#ifndef DISABLE_SSD1963_800
case SSD1963_800:
Serial1.println("ccc");

but it's still reversed......

Having a mess now...