prenticedavid / MCUFRIEND_kbv

MCUFRIEND_kbv Library for Uno 2.4, 2.8, 3.5, 3.6, 3.95 inch mcufriend Shields
Other
364 stars 182 forks source link

iLI9488 colors are off. #40

Closed turtiustrek closed 6 years ago

turtiustrek commented 6 years ago

Hi,I i have used your library for the ILi9488 MCUFRIEND Display made for Ardunio UNO and i confirmed it with the test sketch and it works but there were lines and boxes and it looked terrible and the colors were completely off! I changed the following settings in the .cpp file from 0x3A, 1, 0x55, //Interlace Pixel Format [XX] to 0x3A, 1, 0x36, //Interlace Pixel Format [XX] and it made improvement but the colors were not 'punchy' like red,green,blue were bit off. Any Solutions? Before: img_20180323_100738 After changes : img_20180323_111512 The display it self: 3 6tft-2

LCD_ID sketch: reg(0x0000) 00 00 ID: ILI9320, ILI9325, ILI9335, ... reg(0x0004) 00 54 80 66 Manufacturer ID reg(0x0009) 00 00 61 00 00 Status Register reg(0x000A) 00 08 Get Power Mode reg(0x000C) 00 06 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 93 30 93 30 RD_DDB SSD1963 reg(0x00B0) 00 00 RGB Interface Signal Control reg(0x00B4) 00 02 Inversion Control reg(0x00B6) 00 02 02 3B 3B Display Control reg(0x00B7) 00 06 Entry Mode Set reg(0x00BF) 00 00 00 00 00 00 ILI9481, HX8357-B reg(0x00C0) 00 0E 0E 0E 0E 0E 0E 0E 0E Panel Control reg(0x00C8) 00 B0 B0 B0 B0 B0 B0 B0 B0 B0 B0 B0 B0 GAMMA reg(0x00CC) 00 03 Panel Control reg(0x00D0) 00 00 00 Power Control reg(0x00D2) 00 00 00 00 0D NVM Read reg(0x00D3) 00 00 94 88 ILI9341, ILI9488 reg(0x00D4) 00 97 00 00 Novatek ID reg(0x00DA) 00 54 RDID1 reg(0x00DB) 00 80 RDID2 reg(0x00DC) 00 66 RDID3 reg(0x00E0) 00 00 07 0C 05 13 09 36 AA 46 09 10 0D 1A 1E 0F GAMMA-P reg(0x00E1) 00 00 20 23 04 10 06 37 56 49 04 0C 0A 33 37 0F GAMMA-N reg(0x00EF) 00 00 00 00 00 00 ILI9327 reg(0x00F2) 00 58 04 12 02 22 22 FF 0A 90 14 88 Adjust Control 2 reg(0x00F6) 00 00 00 00 Interface Control

prenticedavid commented 6 years ago

I have answered your question on the Arduino.cc Forum. here

Your photo is very interesting. The "61503" might mean that it is a Renesas R61503U However the R61503 is a 176x220 controller. Your screen behaves like 9488_555 hardware problem.

David.

p.s. unrelated questions
Does anyone have a FocalTech FT1509 datasheet? Does anyone recognise a controller with ID=0x9401 and have a datasheet?

turtiustrek commented 6 years ago

Hmm i wasn't aware that manufactures can 'spoof'(or if that is what i can call it) there 'ids' interesting... anyways i need to know why to changes from 0x55 to 0x36 worked i mean in the datasheet there was nothing about this... i found this on a another forum Thanks :D and yes i have seen significance difference thanks :D ( how can i be this dumb and this time i didn't change any registers :D)

prenticedavid commented 6 years ago

As a general rule, different manufacturers have their own IDs and part numbers.

Sometimes "popular" controllers are made by different makes. e.g. Ilitek ILI9325 Himax HX8347-B has ID=0x9325 Raydium RM68050 has ID=0x9325

The Raydium RM680140 has ID=0x9486 and an undocumented register that tells you it is 6814

Likewise, the popular 132x162 controllers like ST7735S have MANY competitors that will return the same ID=0x7C89F0 or the ILI9163C with ID=0x548066. In fact reg(0x04)=0x548066uL is returned by many controllers of many geometries.

It is handy that the MIPI spec enables User programs to behave the same. Most of the screens appearing on Ebay at the moment are probably obsolete Phone replacement screens. These 10-15 year old controllers often have "features". (which is why they are obsolete)

turtiustrek commented 6 years ago

Well this sums it up i never have been this confused like right now but thanks for clearing this up :D also another off topic question (sorry) the controller i got does it have SPI? since the datasheet does suggest that but since you said that the 'rule' is the 'different manufacturers have their own IDs and part numbers.' does it imply to this display? and how can i be certain who produced this display without poking around the display it self. ( gee wiz i am really sorry for the inconvenience)

prenticedavid commented 6 years ago

Your Uno shield has got a microSD that works with SPI. As shown by your Tiger photo on the Arduino forum.

The TFT has an 8080-8 8-bit parallel interface. You can NOT use SPI. Anyway, your screen is badly cracked.

Please continue these conversations on the Arduino Forum. GitHub issues are more suited to source code programming problems.

David.