Go Down

Topic: Looking for LCD GURU - s6d0139 driver need init tips - 2.6" LCD from ebay (Read 30376 times) previous topic - next topic

Andfj

Couldn't identify the driver. I'm giving up on this screen now. (Normally I wouldn't) but I need one to function for a project in school. So don't have more time.

zoomx

In the page I linked there is a sketch to help to identify the driver.

Andfj

Yea, I used that link. And still couldn't determine it :) But on to a new lcd that works. No touch functions though.

david_prentice

Seriously,   if you used the diagnostic tool to identify the controller,   all you have to is say what ID that it found.   Ebay adverts often untrue.

Simply saying "it don't work" is not going to get any sensible advice.

Likewise,   it is wise to post a link to your actual display.    If it is a regular mcufriend style UNO shield,   it has a resistive touch screen on A1,A2,D7,D6 pins.

David.

Wirregar

#49
Jan 11, 2017, 07:24 am Last Edit: Jan 11, 2017, 08:03 am by Wirregar Reason: Added Photos - Fixed some text
I am joining the queue of people stuck with this display from mcufriend.com

No identifying information printed on the shield except the web address mcufriend.com.
it is supposedly a 2.8" TFT touchscreen (with SD Card reader). It looks just like so many others.

I cannot get the screen working
I can get the touch screen workmen and read values.
I have not tried the SD Ram Card, as I can't write to the screen.

When I run the "LCD ID Reader" sketch, I get an ID out of it:  0x4535.
When I run the Adafruit_TFTLCD graphics test sketch, it returns an ID of 0x4141

And a dump of the registers (from the LCD ID Reader test) are below;

Code: [Select]
Initializing LCD...
Reading ID...0x4535
Loading LCD registers...
Filling the screen...
Done filling...
If your screen filled red, you may be able to use the library at http://misc.ws
Register 0x00 : 0x4535
Register 0x01 : 0x0100
Register 0x02 : 0x0300
Register 0x03 : 0x1030
Register 0x04 : 0x0000
Register 0x05 : 0x0000
Register 0x06 : 0x0000
Register 0x07 : 0x0133
Register 0x08 : 0x0202
Register 0x09 : 0x0000
Register 0x0A : 0x0000
Register 0x0B : 0x0000
Register 0x0C : 0x0000
Register 0x0D : 0x0000
Register 0x0E : 0x0000
Register 0x0F : 0x0000
Register 0x10 : 0x1730
Register 0x11 : 0x0037
Register 0x12 : 0x0018
Register 0x13 : 0x1700
Register 0x14 : 0x0000
Register 0x15 : 0x0030
Register 0x16 : 0x0000
Register 0x17 : 0x0001
Register 0x18 : 0x0000
Register 0x19 : 0x0000
Register 0x1A : 0x0000
Register 0x1B : 0x0000
Register 0x1C : 0x0000
Register 0x1D : 0x0000
Register 0x1E : 0x0000
Register 0x1F : 0x0000
Register 0x20 : 0x0000
Register 0x21 : 0x0000
Register 0x22 : 0xF800
Register 0x23 : 0x0000
Register 0x24 : 0x0000
Register 0x25 : 0x0000
Register 0x26 : 0x0000
Register 0x27 : 0x0000
Register 0x28 : 0x0000
Register 0x29 : 0x0000
Register 0x2A : 0x0000
Register 0x2B : 0x0000
Register 0x2C : 0x0000
Register 0x2D : 0x0000
Register 0x2E : 0x0000
Register 0x2F : 0x0000
Register 0x30 : 0x0001
Register 0x31 : 0x0606
Register 0x32 : 0x0304
Register 0x33 : 0x0202
Register 0x34 : 0x0202
Register 0x35 : 0x0103
Register 0x36 : 0x0105
Register 0x37 : 0x0404
Register 0x38 : 0x0404
Register 0x39 : 0x0404
Register 0x3A : 0x0101
Register 0x3B : 0x0101
Register 0x3C : 0x0700
Register 0x3D : 0x0207
Register 0x3E : 0x0001
Register 0x3F : 0x0001
Register 0x40 : 0x0000
Register 0x41 : 0x0000
Register 0x42 : 0x007F
Register 0x43 : 0x0000
Register 0x44 : 0x0000
Register 0x45 : 0x0000
Register 0x46 : 0x0000
Register 0x47 : 0x0000
Register 0x48 : 0x0000
Register 0x49 : 0x0000
Register 0x4A : 0x0000
Register 0x4B : 0x0000
Register 0x4C : 0x0000
Register 0x4D : 0x0000
Register 0x4E : 0x0000
Register 0x4F : 0x0000
Register 0x50 : 0x0000
Register 0x51 : 0x00EF
Register 0x52 : 0x0000
Register 0x53 : 0x013F
Register 0x54 : 0x0000
Register 0x55 : 0x0000
Register 0x56 : 0x0000
Register 0x57 : 0x0000
Register 0x58 : 0x0000
Register 0x59 : 0x0000
Register 0x5A : 0x0000
Register 0x5B : 0x0000
Register 0x5C : 0x0000
Register 0x5D : 0x0000
Register 0x5E : 0x0000
Register 0x5F : 0x0000
Register 0x60 : 0x2700
Register 0x61 : 0x0001
Register 0x62 : 0x0000
Register 0x63 : 0x0000
Register 0x64 : 0x0000
Register 0x65 : 0x0000
Register 0x66 : 0x0000
Register 0x67 : 0x0000
Register 0x68 : 0x0000
Register 0x69 : 0x0000
Register 0x6A : 0x0000
Register 0x6B : 0x0000
Register 0x6C : 0x0000
Register 0x6D : 0x0000
Register 0x6E : 0x0000
Register 0x6F : 0x0000
Register 0x70 : 0x0000
Register 0x71 : 0x0000
Register 0x72 : 0x0000
Register 0x73 : 0xAAAA
Register 0x74 : 0xAAAA
Register 0x75 : 0x0000
Register 0x76 : 0x0000
Register 0x77 : 0x0000
Register 0x78 : 0x0000
Register 0x79 : 0x0000
Register 0x7A : 0x0000
Register 0x7B : 0x0000
Register 0x7C : 0x0000
Register 0x7D : 0x0000
Register 0x7E : 0x0000
Register 0x7F : 0x0000
Register 0x80 : 0x0000
Register 0x81 : 0x0000
Register 0x82 : 0x0000
Register 0x83 : 0x0000
Register 0x84 : 0x0000
Register 0x85 : 0x0000
Register 0x86 : 0x0000
Register 0x87 : 0x0000
Register 0x88 : 0x0000
Register 0x89 : 0x0000
Register 0x8A : 0x0000
Register 0x8B : 0x0000
Register 0x8C : 0x0000
Register 0x8D : 0x0000
Register 0x8E : 0x0000
Register 0x8F : 0x0000
Register 0x90 : 0x0010
Register 0x91 : 0x0000
Register 0x92 : 0x0000
Register 0x93 : 0x0003
Register 0x94 : 0x0000
Register 0x95 : 0x0101
Register 0x96 : 0x0000
Register 0x97 : 0x0000
Register 0x98 : 0x0000
Register 0x99 : 0x0000
Register 0x9A : 0x000A
Register 0x9B : 0x0000
Register 0x9C : 0x0000
Register 0x9D : 0x0000
Register 0x9E : 0x0000
Register 0x9F : 0x0000
Register 0xA0 : 0x0000
Register 0xA1 : 0x0000
Register 0xA2 : 0x0002
Register 0xA3 : 0x0000
Register 0xA4 : 0x0000
Register 0xA5 : 0x0000
Register 0xA6 : 0x0000
Register 0xA7 : 0x0000
Register 0xA8 : 0x0000
Register 0xA9 : 0x0000
Register 0xAA : 0x0000
Register 0xAB : 0x0000
Register 0xAC : 0x0000
Register 0xAD : 0x0000
Register 0xAE : 0x0000
Register 0xAF : 0x0000
Register 0xB0 : 0x0000
Register 0xB1 : 0x0000
Register 0xB2 : 0x0000
Register 0xB3 : 0x0000
Register 0xB4 : 0x0000
Register 0xB5 : 0x0000
Register 0xB6 : 0x0000
Register 0xB7 : 0x0000
Register 0xB8 : 0x0000
Register 0xB9 : 0x0000
Register 0xBA : 0x0000
Register 0xBB : 0x0000
Register 0xBC : 0x0000
Register 0xBD : 0x0000
Register 0xBE : 0x0000
Register 0xBF : 0x0000
Register 0xC0 : 0x0000
Register 0xC1 : 0x0000
Register 0xC2 : 0x0000
Register 0xC3 : 0x0000
Register 0xC4 : 0x0000
Register 0xC5 : 0x0000
Register 0xC6 : 0x0000
Register 0xC7 : 0x0000
Register 0xC8 : 0x0000
Register 0xC9 : 0x0000
Register 0xCA : 0x0000
Register 0xCB : 0x0000
Register 0xCC : 0x0000
Register 0xCD : 0x0000
Register 0xCE : 0x0000
Register 0xCF : 0x0000
Register 0xD0 : 0x0000
Register 0xD1 : 0x0000
Register 0xD2 : 0x0000
Register 0xD3 : 0x0000
Register 0xD4 : 0x0000
Register 0xD5 : 0x0000
Register 0xD6 : 0x0000
Register 0xD7 : 0x0000
Register 0xD8 : 0x0000
Register 0xD9 : 0x0000
Register 0xDA : 0x0000
Register 0xDB : 0x0000
Register 0xDC : 0x0000
Register 0xDD : 0x0000
Register 0xDE : 0x0000
Register 0xDF : 0x0000
Register 0xE0 : 0x0000
Register 0xE1 : 0x0000
Register 0xE2 : 0x0000
Register 0xE3 : 0x0000
Register 0xE4 : 0x0000
Register 0xE5 : 0x0000
Register 0xE6 : 0x0000
Register 0xE7 : 0x0000
Register 0xE8 : 0x0000
Register 0xE9 : 0x0000
Register 0xEA : 0x0000
Register 0xEB : 0x0000
Register 0xEC : 0x0000
Register 0xED : 0x0000
Register 0xEE : 0x0000
Register 0xEF : 0x0000
Register 0xF0 : 0x0000
Register 0xF1 : 0x0000
Register 0xF2 : 0x0000
Register 0xF3 : 0x0000
Register 0xF4 : 0x0000
Register 0xF5 : 0x0000
Register 0xF6 : 0x0000
Register 0xF7 : 0x0000
Register 0xF8 : 0x0000
Register 0xF9 : 0x0000
Register 0xFA : 0x0000
Register 0xFB : 0x0000
Register 0xFC : 0x0000
Register 0xFD : 0x0000
Register 0xFE : 0x0000
Register 0xFF : 0x0000


When running the LCD ID reader sketch (V1.2) The top 1/4 of the screen fills with RED, the rest stays as random colour horizontal lines. (see attached photo)
When using any other sketch, no screen update appears, the screen is a dull white.


Any pointers from anyone?

Thanks
Darryl

david_prentice

You have an LGDP4535 controller.   It is supported by MCUFRIEND_kbv library.   There might be other libraries.   

Why not Google for Arduino LGDP4535 ?

David.

Wirregar

You have an LGDP4535 controller.   It is supported by MCUFRIEND_kbv library.   There might be other libraries.   

Why not Google for Arduino LGDP4535 ?
I will - Now that I have info to help me.

thank you

Wirregar

You have an LGDP4535 controller.   It is supported by MCUFRIEND_kbv library.   There might be other libraries.   

Why not Google for Arduino LGDP4535 ?

David.
And success - Thank you.


david_prentice

The LGDP4535 can not do Band Scroll.   Everything else should work.

Please report if anything else does not work properly.
I do not own a LGDP4535 Shield.   I have to rely on User feedback. 

David.

Wirregar

The LGDP4535 can not do Band Scroll.   Everything else should work.

Please report if anything else does not work properly.
I do not own a LGDP4535 Shield.   I have to rely on User feedback. 

David.

Thanks David,
Dont think I will be using Band Scroll, so that shouldn't effect me.

I did note that although I am using a shield, I had to disable  the use shield option in AdaLGDP4535TFTLCD.h

Code: [Select]

// **** IF USING THE LCD BREAKOUT BOARD, COMMENT OUT THIS NEXT LINE. ****
// **** IF USING THE LCD SHIELD, LEAVE THE LINE ENABLED:             ****

//#define USE_ADAFRUIT_SHIELD_PINOUT 1


If I enabled this, I had compile errors, if I disabled this, and use the following;

Code: [Select]

Adafruit_TFTLCD tft(LCD_CS, LCD_CD, LCD_WR, LCD_RD, LCD_RESET);
// If using the shield, all control and data lines are fixed, and
// a simpler declaration can optionally be used:
// Adafruit_TFTLCD tft;


it worked.  Is this known?

Do you want a LGDP4535 Shield?  Happy to send you one..

Rgds,
Darryl


david_prentice

My library is called MCUFRIEND_kbv.   Some Beta versions may disable SUPPORT_4535.

My standard test sketch (graphictest_kbv.ino)  will only "fit" on a Uno if I disable some less common controllers.  Your Mega2560 has got plenty of memory.   

It looks as if you are using a hacked Adafruit_TFTLCD library.   Please post a link to the actual library that you found,

You can run my example sketch and just report whether everything works.
There is no point in me having a shield on my desk if everything is ok.
Even then,  it is reasonably easy to test things remotely.

David.

Wirregar

I used this library;

AdaLGDP4535TFTLCD found on the arduino forum.

It Seems to work ok so far.

Wirregar

My library is called MCUFRIEND_kbv.   Some Beta versions may disable SUPPORT_4535.

My standard test sketch (graphictest_kbv.ino)  will only "fit" on a Uno if I disable some less common controllers.  Your Mega2560 has got plenty of memory.    

It looks as if you are using a hacked Adafruit_TFTLCD library.   Please post a link to the actual library that you found,

You can run my example sketch and just report whether everything works.
There is no point in me having a shield on my desk if everything is ok.
Even then,  it is reasonably easy to test things remotely.
Ok, so I downloaded and installed MCUFRIEND_kbv from Github
I am running a UNO by default so all tests below are on a UNO with my TFT shield (LGDP4535)

Here is the result of your example files (loaded from examples folder, not modified and compiled/run);

aspect_kbv - Nothing on screen - Output on Serial Monitor "ID = 0x4535"
graphictest_kvb - Nothing on screen - Output on Serial Monitor "ID = 0x4535"

LCD_ID_readreg - Nothing on Screen - Serial Monitor Output below;
Code: [Select]

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) 45 35 ID: ILI9320, ILI9325, ILI9335, ...
reg(0x0004) 00 00 00 00 Manufacturer ID
reg(0x0009) 00 00 00 00 00 Status Register
reg(0x000A) 00 00 Get Powsr Mode
reg(0x000C) 00 00 Get Pixel Format
reg(0x0061) 00 00 RDID1 HX8347-G
reg(0x0062) 00 00 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) 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 GAMMA-P
reg(0x00E1) 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 GAMMA-N
reg(0x00EF) 00 00 00 00 00 00 ILI9327
reg(0x00F2) 00 00 00 00 00 00 00 00 00 00 00 00 Adjust Control 2
reg(0x00F6) 00 00 00 00 Interface Control


readpixel_kbv - Nothing on Screen - output on Serial Monitor: "readID = 0x4535"
scroll_kbv - Nothing on Screen - Nothing on Serial Monitor
testcard_kbv - Nothing on screen - Output on Serial Monitor: "TFT ID = 0x4535"
Touch_shield_kbv - Nothing on Screen - Output on serial Monitor;
Code: [Select]

Found unknown LCD driver
ID=0x4535
Screen is 240x320
Calibration is:
LEFT = 920 RT  = 150
TOP  = 940 BOT = 120
Wiring is: PORTRAIT
YP=15 XM=16
YM=7 XP=6


Thats about it, some of the others, similar result, nothing on screen with any example.

I didn't run any SD sketches, I haven't any SD libraries loaded. and I skipped a few touchscreen ones as there no screen display, I cant follow screen prompts for touchscreen alignment/testing.


Hope that helps.
Thanks



david_prentice

As I explained in message #55,  some "less usual" controllers are disabled in the library because it gets too big for a Uno.   (the library supports over 40 controllers)

The library that you have installed is v2.9.2-Beta
I have just updated the Master on GitHub to v2.9.3-Beta

Please exit the IDE.
Delete the MCUFRIEND_kbv folder from the libraries folder.

Run the IDE again.   Reinstall the library from the Sketch menu.   v2.9.3 should be found by the Library Manager.   The LGDP4535 is "enabled" in the updated library.

David.

Wirregar

Thanks David, I reloaded the libraries (Note- they weren't found via the library manager, I manually added them from GitHub).

Re-ran the tests, all is good, in fact it is great, seems to be faster than the other library and your examples show more options in use. 

I'm converting everything to mcufriend_kbv now,
Thank you.



Go Up