2020-05-10 11:57 PM
We are in the initial evaluation stage of using the STM32L5R5ZI module for a custom board we are planning to build for an Engine Panel. Part of the Engine panel is also a LCD-TFT touch screen that we are hoping to drive using the built in LTDC controller which is part of this STM32 Module.
1) Are there any examples/tutorial for this module on how to configure the LTDC Controller and to drive the LCD-TFT especially a touch screen one?
2) One of the questions I had around while configuring the GPIO pins on the Nucleo board that supports this L4R5ZI module was, can we use any of the GPIO pins for the HSYNC, VSYNC, DE, LCD_CLK, and the RGB related pins or can we only choose GPIO pins that have been designated to have alternate functions for ex: LCD_HSYNC, LCD_VSYNC, LCD_CLK etc?
3) Also it seems like lot of the other settings around configuring the Clock frequencies, and other LTDC related settings are driven by the settings called out in the data sheet of the Display device of our choice. Is there any guidance as to how we need to tie/map those settings in the data sheet to the corresponding settings in the LTDC?
Thanks,
Yogesh
2020-05-11 09:06 AM
@Martin KJELDSEN any thoughts? We wanted try this out on a Nucleo board NUCLEO-L4R5ZI. and we want to be able to use the LTDC controller to drive the LCD, however since we want to be able to use the ZIO connectors for the GPIO PINS to connect to the external LCD display, are there any restrictions on only using pins that are classified to have an alternate functions of LCD_HSYNC, LCD_VSYNC etc.?
Thanks,
Yogesh
2020-05-11 03:44 PM
Only the pins classified to have an alternate function for LTDC.
You can refer to this AN for more details:
2020-05-11 11:26 PM
As far as TouchGFX L5 support goes, it's on the list of things to do - soon. LTDC examples will probably appear in CubeFW first, for general STM32 configuration. As AME Support Center said, you can only use the pins classified for LTDC.
Re your datasheet: There should be a pretty good mapping between the datasheet and what you can configure for LTDC in CubeMX. Try it out and let us know if you're having issues.
/Martin
2020-05-12 12:17 PM
Thanks AME Support and Martin for taking the time to respond and for the clarification. So in short when I look at the reference manual or the user manual for the L5 Module we plan to use, any of the pins that have the LCD_* alternate function assigned against them, when I load up this nucleo development board in CubeMX, all I have to do is choose those specific pins and choose the alternate function, so that LTDC peripheral can use those pins? Do I have do this explicitly or I don't have to even do that since the LTDC will use those pins as soon as I enable it? I am asking these questions, because eventually we will create a custom board of our own and we will have to tie these pins to the display panel and also I need the clarification because the concept of alternate functions has been a subject of confusion for me :).
@Martin KJELDSEN you mentioned that "TouchGFX L5 support goes, it's on the list of things to do", by that did you mean currently a TouchGFX example doesn't exist for the L5 board and that would be made available soon?
Thanks,
Yogesh
2020-05-12 01:07 PM
You've got an L4+ series board, not L5, your typo in the top post has confused the ST respondents..
Usually the Data Sheet enumerates the pin tables and alternate function multiplexor options.
https://www.st.com/resource/en/datasheet/stm32l4r5zi.pdf
Each pin has a small and finite number of options. The colour depth in use will determine the number of R, G and B pins involved. The clock, control and sync pins tend to have very few options/alternatives.
2020-05-13 01:36 AM
And by TouchGFX Support, i simply mean:
* Direct support in TouchGFX Generator to produce your TouchGFX HAL
* Complete Application Templates for STM32L5 based development boards.
/Martin
2020-05-13 05:41 PM
Thanks @Community member for taking the time to respond. I didn't realize I have been typing L5 :). I have gone thru' most of that document related to LTDC topics and the alternate function pins. Also we know the display we plan to use has a 24 bit bpp. so we will be using all the 24 RGB pins and more to control other things like clock, control and sync related pins. However all I was trying to get a clarification is whether I need to explicitly configure those pins in cubemx that have an alternate function of LCD_* defined or by just enabling the LTDC peripheral in cubemx, these pins automatically are used, without me having to choose and configure those pins?
Thanks,
Yogesh
2020-05-13 06:14 PM
Hello,
If you use CubeMx and enable LTDC it'll use the default LTDC alternate functions.
Then it is up to you to remap the LTDC pins to other possibilities. You need to refer to Table 17. Alternate function in the datasheet.
For example, CubeMx will use by default PE2 for LCD_R0. Then you can manually change it to use PG13 for LCD_R0.
LCD_CLK, LCD_HSYNC, and LCD_VSYNC have one single option: PD3, PE0, and PE1 respectively.
This is per the datasheet:
https://www.st.com/resource/en/datasheet/dm00366448.pdf
Hope it is clear for you now!
2020-05-14 10:01 AM
Thanks that helps a lot and clarifies my questions.
Thanks,
Yogesh