Discuss STM32 and TouchGFX implementations, including configuration, debugging, and optimization.
Most recent activity
Hello,My TouchGFX application (without an operating system) receives events from a communication channel, and in some cases, there are icons on the screen that need to change visibility based on the received state. The events are acquired during the normal polling cycle of the application. When, for example, an alarm arrives, the icon with the exclamation mark is displayed in this way: void sHomeView::updateErrorView(bool error) { imgCommErr.setVisible(error); imgCommErr.invalidate(); } But invalidation does nothing; the screen portion is not redrawn.The invalidation is not lost; it remains latent until another successful redraw event is triggered — for example, if a button is tapped, the imgCommErr object is also redrawn, as are any other objects that are in the same abnormal state.To get it working as expected I need to call invalidation in this way: static bool needToInvalidate = false; static bool visibility = false; void sHomeView::onTick() { if (needToInvalidat
Hello!I have problem with initialization MIPI DSI interface on STM32H747. I use this interface for connect round LCD display with the St7797 display controller. But the problem is that when sending a sequence of LP commands to initialize the display, there is no data on the D0P and D0N lines. In this case, the signal is constantly present on the CLK lines. I am attaching a test project with settings. Tell me where the problem might be?UPDATE: If use LTDC controller, video data present on data line.But there is nothing on the data lines when sending init commands to display.I am attaching a test CubeIDE project with interface initialization.Regards, Alex
We developed a project based on this evaluation board and now we are in the final steps of making a product out of it.We need a similar TFT display to the one in the evaluation board (with similar Touch IC) but the problem is that we cannot find one.The display on the board is AM640480G5TNQW-T00H made by Ampire. Ampire do not provide any datasheet of this display. It is only 640X480 pixels.We are looking for a replacement which is pin compatible and software compatible with Ampire display but with higher resolution (800X600 or more). Size of about 5".We forwarded those specs to some TFT manufacturers along with AN4861 and most of them asked to see a datasheet of Ampire's display. We cannot provide one, it is not on the web and Ampire does not answers any E-mails sent to them - not for purchasing and not for information.Most of the manufacturers want to know which driver is used by the Ampire display. I wonder if anyone has the datasheet of this display or can tell me which driver IC is
Hi,in this touchGFX documentation page ( MIPI-DSI Video Mode | TouchGFX Documentation ) under the "DSIHOST / LTDC Initialization sequence" section it says:"The call to MX_DSIHOST_DSI_Init() must be done before MX_LTDC_Init(). This should be handled by STM32CubeMX. If this is not correct, take care to fix the order in a user code section." But this is the CubeMX generated code where it calls MX_LTDC_Init() before MX_DSIHOST_DSI_Init(): /* Initialize all configured peripherals */ MX_GPIO_Init(); MX_LTDC_Init(); MX_RTC_Init(); MX_OCTOSPI1_Init(); MX_ADC1_Init(); MX_TIM1_Init(); MX_TIM8_Init(); MX_UART5_Init(); MX_ICACHE_Init(); MX_DSIHOST_DSI_Init(); MX_CRC_Init(); MX_I2C4_Init(); /* USER CODE BEGIN 2 */ /* USER CODE END 2 */ It looks like MX is generating it incorrectly... And swapping those lines every single time you change something in MX would be an insanely annoying thing to have to do (not to mention all sorts of other poten
Hello,I am currently using NUCLEO-G071RB with X-NUCLEO-GFX01M2, where I have implemented an animation that periodically updates a part of the display.When setting the animation interval to 100ms, I noticed that the main loop’s while execution time exceeds 100ms, causing delays in execution. To achieve smoother animation, I want to shorten the animation interval. 1. How can I reduce the delay in the main loop execution?2. Could the delay be due to the low clock speed of the MCU or the fact that the display uses SPI communication?3. If I switch to an MCU with a higher clock speed and use a MIPI DSI or RGB interface, how can I migrate my existing SPI display-based project to the new hardware?Any insights or guidance would be greatly appreciated.Thank you!
I port GuiLite on my board with stm32h7, when I develop with multi layer app, I found when I use DMA2A to transfer data on two layers. the screen get some blink like.video_down_load_link:https://img.nickyam.com/file/BAACAgUAAyEGAASS2zT1AAIChGfS0ygzo2_DOJzfenk8GhO85HxiAAKSFwACqduRVpJFr-w2KqwkNgQ.mp4the releate code as below HAL_LTDC_SetAddress_NoReload(&hltdc, (uint32_t)fb, LTDC_LAYER_1); HAL_LTDC_Reload(&hltdc, LTDC_RELOAD_VERTICAL_BLANKING); g_ltdc_sem4sync.value = 1; while(g_ltdc_sem4sync.value); thread_sleep(1000); int ret; ret = HAL_DMA2D_Start(&hdma2d, (uint32_t)fb + (current_active_rect.m_top * 800 + current_active_rect.m_left) * 4, (uint32_t)m_fb + (current_active_rect.m_top * 800 + current_active_rect.m_left) * 4, current_active_rect.width(), current_active_rect.height()); I wonder how could this happen ?
Hi, when I click generate code, sometimes it gets into a loop of just loading, I've attached a screenshot. When I click generate code again, it usually builds, but it does this quite often.
here i am again , having trouble.. I'm part way though tutorial 4 ( Tutorial 4: Creating a Scroll Wheel with Custom Behavior | TouchGFX Documentation) . it gives 2 pieces of code to put in and then says when u run the simulator you'll get this image of scroll wheel with icons changing.. I get a load of errors. I have very little c++ knowledge i'm used to embedded c. So i do have a bit of a learning curve but i feel as if there is a step missing or a piece of code missing.. Compiling generated/gui_generated/src/containers/MenuElementBase.cpp Compiling generated/gui_generated/src/screen1_screen/Screen1ViewBase.cpp Compiling generated/gui_generated/src/common/FrontendApplicationBase.cpp Compiling generated/simulator/src/video/SoftwareMJPEGDecoder.cpp In file included from generated/gui_generated/include/gui_generated/screen1_screen/Screen1ViewBase.hpp:13:0, from gui/include/gui/screen1_screen/Screen1View.hpp:4, from generated/gui_generated/include/gui_generate
I want to programmatically scroll up and down a scrollList. I want a button push or something in the application to trigger scrolling up or down one item or 1 page.The goal is a list of error codes. Right now they are just strings with numbers between 1 and 6.I tried it with animateToItem, but I get strange behavior.My list has 3.5 items visible, so 4 drawable items. The array scrollListListItems generated by TouchGFX is 5 drawable items.It has up to 6 items in the list. But the number is variable (I used checkmarks to add or remove items from the list).If I shorten my list to 5 items no scrolling happens programmatically.The indexes of the items are not in order in the drawables. For instance 5,1,2,3,4.void ErrorScreenView::scrollUpFunction(void) { int16_t minIndex = INT16_MAX; int16_t maxIndex = -1; for (int i = 0; i < scrollListListItems.getNumberOfDrawables(); i++) { int16_t itemIndex = scrollList.getItem(i); if (itemIndex >= 0) { minIndex = std::min(minIndex,
Using Touchgfx at the same time with writing to external QuadSPI-Flash was not possible, because for writing it has to be switched away from memory mapped mode.Now I have seen that Touchgfx 4.25 has some changes.Is it possible now, to present one screen during flash operation, which does not need to access the memory mapped flash during that time? Maybe by copiing the fonts, images and texts to RAM?
Hello to all,I am working on a stm32h745i-disk project that uses keyboard and I would like to hide the characters in the password field.how can I do it? i.e. I don't understand when you press a key on the keyboard where do you type so that it is shown above the keyboard before you hit ok and it is passed to the GUI with “Unicode::strncpy(ContrasenaBuffer, keyboard.getBuffer(), CONTRASENA_SIZE);”The video guide I used was:https://www.youtube.com/watch?v=Tkz9099a7a4testing and trying to understand the keyboard related files I could only hide them once you hit ok and they show up in the GUI using two buffers where one is filled with “*”. I would like to do something similar to the video (minute 5:38) https://www.youtube.com/watch?v=0--7qFmWZMQbut in my touchGFX code and later add a button to show the password if I want to but I guess I can do that later if I can solve this. I share my View.cpp and the keyboard thing.please ignore Login_inicioView::Validacion_usuario() as it is s
Hello,I am working on a TouchGFX project using the STM32H7S78-DK board and implementing dynamic text updates on the display. The text fields should display data read from Flash memory, such as firmware version, name, and model. However, the text is not updating as expected.I have followed various examples and modified my implementation accordingly.Here is my code, /*********************************************************************************/ /********** THIS FILE IS GENERATED BY TOUCHGFX DESIGNER, DO NOT MODIFY ***********/ /*********************************************************************************/ #ifndef ABOUTVIEWBASE_HPP #define ABOUTVIEWBASE_HPP #include <gui/common/FrontendApplication.hpp> #include <mvp/View.hpp> #include <gui/about_screen/AboutPresenter.hpp> #include <touchgfx/widgets/Box.hpp> #include <touchgfx/EasingEquations.hpp> #include <touchgfx/mixins/FadeAnimator.hpp> #include <touchgfx/widgets/TextArea.hpp> #in
since the background image is set well and I use a invisible button, the clicked event can't be triggered when i click the '1' button; but if I set the '1' button is visible , the clicked even can be triggered , how to modify this ?
I am trying to pause or stop a dynamic graph when data has scrolled to the right hand side once. I will then use a second and third etc., dynamic graph on top to display further 'screen shots' of data, to create a stack of overlays.Is it possible to stop the graph scrolling after a given time, or number of data samples?ThanksIan
hello, i want to switch 5 images within the same window as following picture illustration; could you have any sample to me for reference ?
Hi,as you can see in the first screenshot, in the X-CUBE-TOUCHGFX settings (TouchGFX Generator tab) the LTDC option for the Application Tick Source is not available. And at the bottom it says "LTDC in only available if enabled".LTDC is enabled and configured (second screenshot). Does it need to be configured and/or enabled in some other ways or some other place too?Thank you :)
I finished the program and verify well within simulator , but load into STM32H747 board, then list following error message;
I’ve encountered a bug in TouchGFX version 4.25 when working with TextAreas. If you manually assign an ID to a TextArea, such as "id_txt_config_ntp", and then duplicate the TextArea (using copy and paste), the second generated one remains linked to the first. Even if you change the ID of the second one, any modification made to either of them affects both.
From what I read we should be able to save JPEG images to an SD card, and then load these into a dynamic bitmap via a combination of FatFS (or whatever) and LibJPEG, in order to display. A couple of questions:Could a texture mapper then use this image, so that we can apply scale and rotate?Are scale and rotate purely done in software, I assume this is the case, but maybe it depends on the MCU?I will be using the STM32U5G9J-DK2 for testing.Many Thanks,Anthony
Hello Friends. Now i have started working on bigger display with TouchGFX Custom Boards. Im using 10.1 inch 1024x600 touch display. using QUADSPI,SDRAM, FMC and LTDC. Through TouchGFX Designer i taken one backgoround image, one Text Area buffer and one Digital clock. when im not updating digital clock data and text area im getting proper display.but when i starts updating digital clock in void screenView::handleTickEvent() then my display starts flickering and white lines appearing on display. my LTDC configuration:void MX_LTDC_Init(void) { /* USER CODE BEGIN LTDC_Init 0 */ /* USER CODE END LTDC_Init 0 */ LTDC_LayerCfgTypeDef pLayerCfg = {0}; /* USER CODE BEGIN LTDC_Init 1 */ /* USER CODE END LTDC_Init 1 */ hltdc.Instance = LTDC; hltdc.Init.HSPolarity = LTDC_HSPOLARITY_AL; hltdc.Init.VSPolarity = LTDC_VSPOLARITY_AL; hltdc.Init.DEPolarity = LTDC_DEPOLARITY_AL; hltdc.Init.PCPolarity = LTDC_PCPOLARITY_IPC; hltdc.Init.HorizontalSync = 40; hlt
Hi,Iam using a STM32F746 DISCO Board to use SDMMC in a TOUCHGFX Application but Iam not able to get past if(f_mkfs((TCHAR const*)SDPath, FM_ANY, 0, rtext, sizeof(rtext)) != FR_OK) function. It gives error here. Even If I comment this section and reach fopen command it returns FR_DISK_ERR. However When I simply run the standalone SDMMC example ,it works and writes data to SD card.Why is that the same example does not work with Touchgfx application?The only difference I could see is of Clock speed between two applications. One is at 50Hz & other is at 48Hz.Im Prototyping my project on disco board before I go into custom design. Kindly help!!
I have a screen with only 1 line of text and I get a Hard Fault when I try to run it. I get the fault here at the glyph->dataOffset:const uint8_t* GeneratedFont::getPixelData(const GlyphNode* glyph) const{const uint8_t* const* table = (const uint8_t* const*)glyphData;return &(table[glyph->unicode / 2048][glyph->dataOffset]);}I have everything stored in internal flash and it is initialized before TouchGFX
Hi!I am confounded by a problem I've encountered when migrating to TouchGFX 4.25.0. The following change is being made by the auto-generated code in TouchGFXGeneratedHal.cpp:When that change is included, my FW will result in a black screen. However, when I revert it back, the screen displays it's GUI just fine. You might say, "well, that function must be returning false and you're entering the conditional and hanging in the while loop," which I agree is the mostly likely answer. However, any time I try to debug it - the function returns true, the conditional is skipped over, and the screen is still black. The following breakpoint will never be hit (it's my only breakpoint):What am I missing? I feel like I'm going crazy. Thanks,Julia
Hi Everybody, I need some infos about graphic assets upgrade while main APP and TouchGFX is running. I have a customer board composed by STM32H743xxx , 2 QSPI and obiously a parallel RGB LCD screen managed by LTDC. The scope is to update the main APP and the graphic assets by a simple bootloader: while main APP is running I will receive new data and I will save them into the secondary QSPI memory. QSPI memory are connected in dual mode with separated lines (both for signals and for CS). in this way, in your opinion, Can the system access to the secondary memory (in writing mode) without disturb the graphic application? If I'm not wrong I only need to change the linker script from: QUADSPI (rx) : ORIGIN = 0x90000000, LENGTH = 16M ExtFlashSection : { *(ExtFlashSection ExtFlashSection.*) *(.gnu.linkonce.r.*) . = ALIGN(0x4); } >QUADSPI FontFlashSection : { *(FontFlashSection FontFlashSection.*) *(.gnu.linkonce.r.*) . = ALIGN(0x4); } >QUADSPI TextFlashSec
I've updated from TouchGFX Designer 4.24 to 4.25 and I've noticed that the example projects won't load the previews. Same machine, same internet connection4.254.24
ST Community highlights – April to June 2026
Already have an account? Login
No account yet? Create an account
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.