2024-03-21 07:34 AM
Starting a new STM32F4 project I decided it would be a good idea to update all the development tools.
TouchGFX v 4.23.2
STM32CubeMX v 6.11.0
STMCubeIDE v 1.15.0
A working .ioc file from the previous project release was upgraded using the latest STM32CubeMX. A couple of modes to main.c required to run the application and a compile was attempted. The following errors are generated:
../TouchGFX/target/generated/STM32DMA.cpp: In function 'void touchgfx::paint::argb8888::lineFromL8ARGB8888(uint8_t*, const uint8_t*, int16_t, uint8_t)':
../TouchGFX/target/generated/STM32DMA.cpp:760:9: error: 'L8ClutLoaded' was not declared in this scope
760 | if (L8ClutLoaded == 0)
| ^~~~~~~~~~~~
../TouchGFX/target/generated/STM32DMA.cpp: In function 'void touchgfx::paint::argb8888::lineFromL8RGB888(uint8_t*, const uint8_t*, int16_t, uint8_t)':
../TouchGFX/target/generated/STM32DMA.cpp:699:62: error: 'L8CLUT' was not declared in this scope
699 | WRITE_REG(DMA2D->FGCMAR, reinterpret_cast<uint32_t>(&L8CLUT->data));
| ^~~~~~
The project the .ioc file was upgraded from does not contain 'L8ClutLoaded'
TouchGFX default image configuration are shown below. All images used the default or ARG8888 or RGB888
In CubeMX the DMA2D is set as follows:
and LTDC settings:
and finally TouchGFX settings in CubeMX:
There are no indicated errors shown when code is generated from TouchGFX or CubeMX.
Did I miss upgrading something or changing a required setting?
Solved! Go to Solution.
2024-03-26 05:40 PM - edited 2024-03-26 06:08 PM
Hello @RLarr.1 ,
Try download and install the X-CUBE-TouchGFX manually into STM32CubeMX.
After download the package, you need to install it by using "From local" option in the Help >> "Manage Embedded Software Packages" option in STM32CubeMX (please see the screenshot below - "From local" option in the bottom left, with yellow color).
Then, select the X-CUBE-TOUCHGFX package (zip folder).
Hope this works for you!
2024-03-21 03:20 PM
2024-03-25 03:56 AM
Thank you for the reply. I had regenerated code, a few times. At least once after trying each thing I did in an attempt to get it to work. There are no indicated errors shown when code is generated from TouchGFX or CubeMX. I will try starting from scratch with the MXCube and see if I have better luck.
Thanks,
Raymond
2024-03-25 12:50 PM
I uninstalled CubeMX, TouchGFX and CubeIDE and started over. I got a good compile. However when I go back into the .ioc file I get the following message:
The embedded software packages manager and Software packs selector has TouchGFX4.23.0 but does not seem to like TouchGFX v 4.23.2 I have installed. This seems to be the root of the problem.
2024-03-26 09:22 AM
The above still did not resolve the issue. So far I have:
STM32DMA.cpp continues to contain the undefined "L8ClutLoaded" and "L8CLUT" variables.
Turns out the issue with undefined variables is caused by selecting XRGB8888 in the Framebuffer Pixel Format under the TouchGFX Generator in CubeMX. Selecting ARG8888 fixed the undefined variables issue.
There is still the issue that CubeMX does not recognize TouchGFX version 4.23.2.
2024-03-26 10:00 AM
For some reason the solution was marked as spam and removed.
I removed all the installed software and reinstalled and no difference. I changed the Framebuffer Pixel Format in the TouchGFX Generator in CubeMX from XRGB8888 to ARGB8888 and the issue with undefined variables went away.
There is still the issue with CubeMX not recognizing TouchGFX version 40.23.2. You just cannot go back into CubeMX after generating code in TouchGFX version 4.23.2.
2024-03-26 05:40 PM - edited 2024-03-26 06:08 PM
Hello @RLarr.1 ,
Try download and install the X-CUBE-TouchGFX manually into STM32CubeMX.
After download the package, you need to install it by using "From local" option in the Help >> "Manage Embedded Software Packages" option in STM32CubeMX (please see the screenshot below - "From local" option in the bottom left, with yellow color).
Then, select the X-CUBE-TOUCHGFX package (zip folder).
Hope this works for you!
2024-03-27 03:44 AM
Thank you. That solved the issue with CubeMX not recognizing TouchGFX version 40.23.2.
Both issues have been resolved.
Raymond