stm32f429 tft lcd ili9341 quotation

STM32F429 has also LTDC driver for LCD like that, but this driver we will use later. For now we will use SPI for driving in serial mode and some other pins for controlling.

Remember: This library can also be used, if you are not using STM32F429 Discovery. It can be used in previous STM32F4 Discovery board. All pins can be changed in defines.h file which is included in project.

stm32f429 tft lcd ili9341 quotation

Ahh yeah look at that! If you look closely, top right of the LCD, that’s obviously a flex connector for a resistive touch overlay (4 contacts running to the 4 sides of the LCD overlay).

A fair number of inexpensive baseboards/motherboards/accessories have also appeared for earlier versions. I hope Olimex puts out a couple nice STM32F429/427 boards.

I can see there is only a STLINK usb connector on board, so there is even no FS to expect. beside HS, I suppose does mean High Speed (480mbps). but HS anyway needs a separate physical layer USB chip for addition to STM32F4 chip and most likely this is chip is not present on this board anyway, because this is STM32F4+LCD+SDRAM demoboard and there is no need for USB at all.

I think Farnell’s 21€ will be accurate, as ST’s suggested USD price is $24. The placeholders for the STM32F429I-DISCO on element14 (a division of Farnell) and mouser show $42, which I think predates the later ST announcement. I think the ST announced $24 will hold, and the distributor prices will match that, as they have in the past.

I wouldn’t expect TI to hack profits from their calculator range, and HP have always been expensive, but ST could easily change their format to calculator-friendly. Clamshell design, LCD & battery in top half, CPU & keypad in bottom half, expansion pins to left / right of keypad makes a self contained unit.

HP Palm – Love the idea, hate the baguette (french bread loaf) layout. If I could get custom key covers, and surface-mount key switches, I’d be designing my own low-profile keypad to go with an LCD module. Top side keypad, bottom side CPU / RAM / USB / LCD driver / power regulation / expansion port.

Great find, thanks! Man, could they have buried the details on that guy any farther down into the document? I can’t help but feel like a quick pointer in the LCD section to “oh by the way there’s a touch screen, here’s how to talk to it” would have been a good idea.

It’s certainly useable in any other project where you have an onboard LCD controller. Especially any other project that happens to use a STM32F4. What difference would it have made if it had an external controller? Surely it’d have been on the same PCB. Were you hoping for a removeable SPI-interfaced module?

Look in the UM1670 user manual, paragraph 4.8: the tft includes an ILI9341 controller. The ILI9341 has it’s own graphics ram inside, it is not mapped into the STM32 address space. It is connected to the STM32 via a parallel bus. The ILI9341 and similar controllers are common on cheap chinese tfts. So it is no problem to source similar tfts for your final product after developing on the discovery board.

UM1670 in paragraph 4.8 also says that “The TFT LCD is a 2.41″ display of 262 K colors. Its definition is QVGA (240 x 320 dots) and is directly driven by the STM32F429ZIT6 using the RGB protocol”. ILI9341 has multiple modes of operation including direct RGB/HSYNC/VSYNC mode which bypasses internal GRAM. I don’t have the board yet but I assume display buffer is located in external SDRAM which is also on the board. The whole point of this kit is to show TFT and SDRAM interface in new STM32F4x9.

I’ve checked this discovery board firmware available from ST’s site (“STM32F429 discovery firmware package UM1662” number: STSW-STM32138, btw. finding it is a bit difficult – ST’s site is terrible):

Check again martin. Those lines have pullups to vdd and are connected to cpu pins. I have this board for some time and I can confirm that lcd is driven by lcd controller from cpu and frame buffer is in external dram which is also on the board.

stm32f429 tft lcd ili9341 quotation

Therefore, it may be more advantageous to use a driver chip, to avoid a lot of setup with external memory. Since it"s not just a software issue, but also the hardware doesn"t have all the support to perform the direct operation with the TFT display (it doesn"t accept STN either).

stm32f429 tft lcd ili9341 quotation

The STM32 LTDC has a peripheral called LTDC LCD TFT Display Controllerwhichprovides a digital parallel interface(DPI) for a variety of LCD and TFT panels. It sends RGB data in parallel to the display and generates signals for horizontal and vertical synchronization (HSYNC, VSYNC), as well as pixel clock (PCLK) and not data enable (DE) signals:

In this example I use the display on the STM32F429-Discovery board, which is driven by the ILI9341 display controller. The ILI9341 can drive a QVGA (Quarter VGA) 240×320 262,144 colors LCD display. The controller can be configured via SPI (or parallel interface, depending on the panel settings) to use a digital parallel 18 bit RGB interface (since only 6 lines per color channel are wired on the board to the LTDC). Since the display pixel format is less than 8 bit per channel (RGB666 in this case), the RGB display data lines are connected to the most significant bits of the LTDC controller RGB data lines:

Before enabling the LTDC we must configure the clock system. The LTDC uses a specific clock LCD_CLOCK to generate the pixel clock signal and it must be configured and enabled during the system initialization phase:

To display an image we must convert an image file to an array (possibly a const one, so it can be stored in flash memory) of bytes. To do this I used LCD image converter, a simple but powerful application that can convert a file to a variety of different pixel formats:

In this example the framebuffers have a RGB888 color depth and for a 240×320 display that makes 225 KiB of memory for each buffer (3 bytes per pixel x 240 x 320 pixels) so they must be stored in external SRAM (the STM32F429I-DISCOVERY has a 64Mbit external SRAM so we’re good). The FMC Flexible Memory Controller has to be initialized and the address of the two frame buffers has to be configured. Drawing on the framebuffer is a matter of writing the right bytes in order to change the color. Once all pixels are drawn (bytes are written) the buffers are switched and the code can draw the next frame:

stm32f429 tft lcd ili9341 quotation

now you will note we have the above #define for the DATA portion of the LCD/FSMC , now just because we define it there does not mean we have configured the hardware fully,

stm32f429 tft lcd ili9341 quotation

Please see the DT028CTFT for reference designs. The schematics between the A and the C are the same with the exception that the A does not have the IPS interface.

stm32f429 tft lcd ili9341 quotation

As many other folks in this community, I tried to rotate my STM32F429 TFT for landscape and I have almost encountered about all the problems reported on the web for this topic.Finally I have managed to fix all the issues, this information is provided as is without warranty of any kind, it is your responsibility to test and validate all the changes provided in this blog for your application.