Go Down

Topic: MCUFriend 2.4 inch lcd display showing white (Read 5265 times) previous topic - next topic

tunstsk

Hi, I bought a lcd touch display. It is a MCUFRIEND display (picture attached)

http://www.miniinthebox.com/da/diy-2-4-tft-lcd-touch-skaerm-skjold-udvidelseskort-til-arduino-uno_p2022293.html

I wanted to connect it to the Arduino Uno or Arduino Mega for some NeoPixel projects.

The problem is a can't seem to find the correct libraries to run this display and at first to display something...

But when I connect it to the board I just get a white screen and uploading a graphictest example the screen doesn't change at all and stays white. I got the touch screen to work and display the X and Y positions but nothing else.

Do you guys have some suggestions.

tunstsk

The images!

PaulRB

#2
Jan 22, 2017, 08:59 pm Last Edit: Jan 22, 2017, 09:06 pm by PaulRB

tunstsk

Doesn't work... still white screen.

found out that

LCD Driver Found = 6767

reg(0x0000) 67 67   ID: ILI9320, ILI9325, ILI9335, ...

Im sooo stuck for couple of days now

david_prentice

#4
Jan 22, 2017, 09:26 pm Last Edit: Jan 22, 2017, 09:27 pm by david_prentice
I suspect that your Red 2.4" Mcufriend Shield is 240x320 with a Himax HX8367-A controller.

I do not know of any existing Arduino library.   I have never heard of this controller on a shield.
Please run the LCD_ID_readreg.ino sketch and post the output from the Serial Terminal.

If you  are willing to do the testing,  I will add conditional support to the MCUFRIEND_kbv library.

David.

tunstsk

Big thanks! Serial output of LCD_ID_readreg.ino


Re 20 20 20 20 20 20 20 20 20   Adjust Control 2
reg(0x00F6) 00 00 00 00   Interface Control
 24 24 24   ILI9327
reg(0x00F2) 20 20 20 20 20 20 20 20 20 20 20 20   Adjust Control 2
reg(0x00F6) 00 00 00 00   Interface Control
Read Registers on MCUFRIEND UNO shield
controllers either read as single 16-bit
e.g. the ID is at readReg(0)
or as a sequence of 8-bit values
in special locations (first is dummy)

reg(0x0000) 67 67   ID: ILI9320, ILI9325, ILI9335, ...
reg(0x0004) 00 00 00 00   Manufacturer ID
reg(0x0009) 3F 3F 3F 3F 3F   Status Register
reg(0x000A) 00 00   Get Powsr Mode
reg(0x000C) 01 01   Get Pixel Format
reg(0x0061) 00 00   RDID1 HX8347-G
reg(0x0062) 80 80   RDID2 HX8347-G
reg(0x0063) 00 00   RDID3 HX8347-G
reg(0x0064) 00 00   RDID1 HX8347-A
reg(0x0065) 00 00   RDID2 HX8347-A
reg(0x0066) 00 00   RDID3 HX8347-A
reg(0x0067) 00 00   RDID Himax HX8347-A
reg(0x0070) 00 00   Panel Himax HX8347-A
reg(0x00A1) 00 00 00 00 00   RD_DDB SSD1963
reg(0x00B0) 00 00   RGB Interface Signal Control
reg(0x00B4) 00 00   Inversion Control
reg(0x00B6) 00 00 00 00 00   Display Control
reg(0x00B7) 00 00   Entry Mode Set
reg(0x00BF) 00 00 00 00 00 00   ILI9481, HX8357-B
reg(0x00C0) 00 00 00 00 00 00 00 00 00   Panel Control
reg(0x00C8) 00 00 00 00 00 00 00 00 00 00 00 00 00   GAMMA
reg(0x00CC) 00 00   Panel Control
reg(0x00D0) 00 00 00   Power Control
reg(0x00D2) 00 00 00 00 00   NVM Read
reg(0x00D3) 00 00 00 00   ILI9341, ILI9488
reg(0x00DA) 00 00   RDID1
reg(0x00DB) 00 00   RDID2
reg(0x00DC) 00 00   RDID3
reg(0x00E0) 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01   GAMMA-P
reg(0x00E1) 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49 49   GAMMA-N
reg(0x00EF) 24 24 24 24 24 24   ILI9327
reg(0x00F2) 20 20 20 20 20 20 20 20 20 20 20 20   Adjust Control 2
reg(0x00F6) 00 00 00 00   Interface Control

david_prentice

Download and install a current Release of the MCUFRIEND_kbv library v2.9.3
You will need to enable the HX8347-I controller.   I suggest that you disable SUPPORT_B509_7793 and SUPPORT_4535 if you are using a Uno.

MCUFRIEND_kbv.cpp:
Code: [Select]

#define SUPPORT_8347D             //HX8347-D, HX8347-G, HX8347-I +520 bytes, 0.27s


graphictest_kbv.ino:   in the setup() function
Code: [Select]

    ...
    if (g_identifier == 0x00D3 || g_identifier == 0xD3D3) g_identifier = 0x9481; // write-only shield

    if (g_identifier == 0x6767) g_identifier = 0x9595; // force the HX8367-A to use HX8347-I ID

    tft.begin(g_identifier);



Run the graphictest_kbv sketch.    The HX8367-A datasheet is very similar  to the HX8347-I

If you are lucky,  you might get a display.   

Please make notes of anything that looks wrong.   e.g. colours,  directions,  mirroring, ...
Then make a report back to the Forum.

David.

tunstsk

Thanks, got it working by using what you said!

david_prentice

You still need to study the sketch.   i.e. does the Software Scroll work?  does Invert work ?

Every single test should work 100% with a HX8347-I.

Does the display look happy? i.e. no shakes or blurring.
Remove the sticky label first.    Everything looks horrible when the label is in the way.

David.

tunstsk

Thanks will do that!
Then I have to work with my neopixel project :)

HagenGoh

Hi David,
what if my Serial output from LCD_ID_readreg.ino are

" Read Registers on MCUFRIEND UNO shield
controllers either read as single 16-bit
e.g. the ID is at readReg(0)
or as a sequence of 8-bit values
in special locations (first is dummy)

reg(0x0000) 00 00   ID: ILI9320, ILI9325, ILI9335, ...
reg(0x0004) 04 04 04 04   Manufacturer ID
reg(0x0009) 01 01 01 01 01   Status Register
reg(0x000A) 00 00   Get Power Mode
reg(0x000C) 04 04   Get Pixel Format
reg(0x0061) 01 01   RDID1 HX8347-G
reg(0x0062) 00 00   RDID2 HX8347-G
reg(0x0063) 01 01   RDID3 HX8347-G
reg(0x0064) 04 04   RDID1 HX8347-A
reg(0x0065) 05 05   RDID2 HX8347-A
reg(0x0066) 04 04   RDID3 HX8347-A
reg(0x0067) 05 05   RDID Himax HX8347-A
reg(0x0070) 00 00   Panel Himax HX8347-A
reg(0x00A1) 81 81 81 81 81   RD_DDB SSD1963
reg(0x00B0) 80 80   RGB Interface Signal Control
reg(0x00B4) 84 84   Inversion Control
reg(0x00B6) 84 84 84 84 84   Display Control
reg(0x00B7) 85 85   Entry Mode Set
reg(0x00BF) 85 85 85 85 85 85   ILI9481, HX8357-B
reg(0x00C0) 80 80 80 80 80 80 80 80 80   Panel Control
reg(0x00C8) 80 80 80 80 80 80 80 80 80 80 80 80 80   GAMMA
reg(0x00CC) 84 84   Panel Control
reg(0x00D0) 80 80 80   Power Control
reg(0x00D2) 80 80 80 80 80   NVM Read
reg(0x00D3) 81 81 81 81   ILI9341, ILI9488
reg(0x00D4) 84 84 84 84   Novatek ID
reg(0x00DA) 80 80   RDID1
reg(0x00DB) 81 81   RDID2
reg(0x00DC) 84 84   RDID3
reg(0x00E0) 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80   GAMMA-P
reg(0x00E1) 81 81 81 81 81 81 81 81 81 81 81 81 81 81 81 81   GAMMA-N
reg(0x00EF) 85 85 85 85 85 85   ILI9327
reg(0x00F2) 80 80 80 80 80 80 80 80 80 80 80 80   Adjust Control 2
reg(0x00F6) 84 84 84 84   Interface Control  "

*i have used a few id identifier code ino, all display that my reg is 0x0000, so which driver i am using actually? i am stuck on this issue for long time TT

david_prentice

Please post a photo of the pcb.  e.g. link to the actual Ebay sale or your own photo.

Is there any text written on pcb.  e.g. OPEN-SMART or mcufriend ?

Install/Update library with Library Manager.

David.

camilo_cordoba

#12
Dec 14, 2017, 10:32 pm Last Edit: Dec 15, 2017, 02:13 pm by camilo_cordoba
Good day
I have one of the same MCUFRIEND 2.4 TFT LCD SHILED screens, I had the same partner problem that I could not make it work, but I already downloaded the MCUFRIEND_kbv v2.9.3 library and made the changes to enable the HX8347 driver and disable the other drivers and make the modifications in the code of the graphictest_kbv.ino and I made it work in the image viewing part.
The drawback is that now I can not operate the touch, I charge the three examples of the library of MCUFRIEND and none works, the screen is blank.
What could be the solution for the screen to work well the touch ?????
Thank you.

david_prentice

First off.   Upgrade to the current library version.    I doubt if 2.9.3 knows about HX8347.
Enable the SUPPORT_8347D as described in the how_to.

All your TFT sketches should work without any changes.

You might have to Calibrate  your Touch Screen.   And find which Touch pins are used.

Make notes on paper as you go.
If you have a problem,  you can tell me exactly what steps you made (from your notes)

David.

camilo_cordoba

Good day
Working a little more on the screens I have other screens with the 1580 driver, I have researched a lot and I have tried several drivers in the arduino codes to make them work but no driver manages to turn it completely blank.
What other driver can I use to replace the 1580 and that I managed to turn on the 2.4 TFT LCD screen with the MCUFRIEND 2.9.3 library?
Thank you

Go Up