stevstrong / Adafruit_TFTLCD_8bit_STM32

Adafruit TFT library using 8 bit parallel access ported to STM32
47 stars 18 forks source link

Problem after reset and readid #1

Closed zrafa closed 7 years ago

zrafa commented 7 years ago

Hi,

I have problems with this library. Reset works, and read id as well, but I am not sure if correctly. But, then, after readid, begin() does not work. Nor anything else.

I have a blue pill board. My LCD is this: http://www.elecfreaks.com/wiki/index.php?title=2.4%22_TFT_LCD:_TFT01-2.4 The version I have is the ili9325

Your library reports mine as ili9328. I do not know why. But, at least, it does, and I guess that wiring is okey (because reset() and readid() works).

But then comes begin(). It does not work. And after begin, anything I try fails. For example, readID() fails after begin() (still if it worked after reset).

And, I am not sure if the library reporting ili9328 (and not ili9325) is okey.

Do you have some ideas about what is happening? Could you assist me a bit to do some more steps? I do not know what else to try. I tested all the examples. Following the code I see that just reset() and readID() work.

Thanks in advance.

stevstrong commented 7 years ago

Could you please detail what exactly did you try and what exactly "does not work"? If the readID() returns 0x9328, then it is most probably correct. These small displays can have a broad range of controllers, and one cannot trust that it is 9325 just because the seller says so. I bought a board which was supposed to be have an ILI9341 controller, but turned out to be an ILI9328 one.

But if you want to double-check, you could use this sketch.

And then please attach some serial monitor window output.

Btw, these kind of issue you should post on stm32duino.com.

zrafa commented 7 years ago

Hello, this is the output with your sketch which read registers:

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) 93 28 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) 12 31 12 31 12 31 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

Which stepts could I do to go a bit further?

On 12/4/16, stevstrong notifications@github.com wrote:

Could you please detail what exactly did you try and what exactly "does not work"? If the readID() returns 0x9328, then it is most probably correct. These small displays can have a broad range of controllers, and one cannot trust that it is 9325 just because the seller says so. I bought a board which was supposed to be have an ILI9341 controller, but turned out to be an ILI9328 one.

But if you want to double-check, you could use this sketch.

And then please attach some serial monitor window output.

Btw, these kind of issue you should post on stm32duino.com.

-- You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub: https://github.com/stevstrong/Adafruit_TFTLCD_8bit_STM32/issues/1#issuecomment-264696024

stevstrong commented 7 years ago

OK, so your controller is evidently ILI9328, and the wiring seems to be right.

Please be sure that you are using the latest version of Arduino_STM32 from github.

Which sketch do you use and what do you get on serial monitor?

zrafa commented 7 years ago

Thanks for the info. I am using the latest version of Arduino_STM32 from github. But, that is not enough for my board, because I have a blue pill, which Arduino_STM32 from github does not support. So I am using this as well : https://github.com/danieleff/Arduino_Core_STM32F1.git

It brings the blue pill support.

BUt, if your sketch about reading registers work, and it seems that the wiring is okey. What do you think that should I work? (some little step to go further. I do not want to download big librarires and to try the whole thing, because that is that it is failing for me). I know that reset() works, readID() works, but then, after begin(), readID() fails and gives unknown id.

Thanks in advance

On 12/4/16, stevstrong notifications@github.com wrote:

OK, so your controller is evidently ILI9328, and the wiring seems to be right.

Please be sure that you are using the latest version of Arduino_STM32 from github.

Which sketch do you use and what do you get on serial monitor?

-- You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub: https://github.com/stevstrong/Adafruit_TFTLCD_8bit_STM32/issues/1#issuecomment-264698125

stevstrong commented 7 years ago

Are you using a custom hardware, not the common blue pill?

In this case please post on stm32duino.com forum. And also post the hardware/software data you own, otherwise is hard to give support.