Discuss STM32 and TouchGFX implementations, including configuration, debugging, and optimization.
Most recent activity
..
Hi,So far in AbstractDataGraph.cpp the library had:namespace touchgfx { AbstractDataGraph::AbstractDataGraph(int16_t capacity) : dataScale(1), alpha(255), topPadding(0), leftPadding(0), rightPadding(0), bottomPadding(0), maxCapacity(capacity), usedCapacity(0), gapBeforeIndex(0), clickAction()but it should be:namespace touchgfx { AbstractDataGraph::AbstractDataGraph(int16_t capacity) : dataScale(1), alpha(255), topPadding(0), leftPadding(0), rightPadding(0), bottomPadding(0), maxCapacity(capacity), usedCapacity(0), gapBeforeIndex(0), clickAction(), dragAction()i.e. the problem was that "dragAction" was never initialized and our application would crash. But not every time you dragged a Graph widget, but only sometimes (when you enter that screen and everything is initialized for maybe the 2nd or 3rd time, then with the wrong garbage data, it would crash)Here is our stacktrack where it would always crash. dragAction->isValid() would be called, even though dragAction was never initi
Hi all,I'm building a custom board with touchgfx and QSPI resources.Everything work well!I would like to know how is possible to remove loader to fast the debugger session: the external resource need more than 4Mbytes and loader everytime I start a debug session update the external memory. This process take about 1 and half minute. the problem is that I don't updating nothing on graphic design, but I'm adding only code to my project: everytime I program the uC everything is erased and reprogrammed.So I would like to have the possibility to run the project, loading the external QSPI resources needed by graphic stack and correct as fast as possible my code. Is it possible?( I'm know where remove the loader (on debug settings) and I know how to edit the linker to add/remove external reosurces: but if I edit the linker, Touchgfx don't know where load the picutres and fonts from) . how can I solve it?Thanks in advance
I try to connect LCD by SPI to Nucleo-767 and TouchGFX. LCD screen work perfect and I could draw on it without a problem, but I stuck with TouchGFX. I found that void TouchGFXHAL::flushFrameBuffer never call.Check this video - https://youtu.be/1UhEx7E_dH0What I did:New project for my boardMake timer for VSync each 15msAdd TouchGFX Generator packageAdd CRCIn TouchGFX settings set size 320x240 and RGB888.Open TouchGFX Designer, add button, and generate code.In code add start & callback for timer and call function for generate tickadd switch on led on board.LED doesn't light.Of course, I checked that timer callback works, led works.In debug mode I found that app stuck in lockFrameBuffer function.What I did wrong?
Hello. We have a need to work with a 16-bit 8080 style LCD interface. Would like to have the benefits of the latest TouchGFX tool (4.16.0) and STM32CubeMX to build quickly and debug our GUI screens. After some investigation, found the following kit which appears to be close to our hardware need:STM32L496G-DISCO Ran TouchGFX -> created a fresh project using this target kit -> imported the Pool Lights demo -> ran the simulator -> runs fine -> Generated the Code.Launched the STM32CubeMX .ioc file from the project folder -> toolchain requested to migrate to the current versions of the wizard code -> allowed for this update -> selected IAR compiler -> went back to TouchGFX to re-generate the code for the IAR target compiler -> returned to STM32CubeMX and built the project -> launched the IAR compiler -> compiled -> facing assorted errors.Same errors with Keil compiler. Screens are attached.Can anyone share if we are properly building for this targ
Hello, on my STM32H747-DISC1, I had huge issues with DMA2D and CLUT (it was freezing etc).I thought it's because cache maintenance, but anyway after doing everything correctly, DMA is still buggy. Finally I find out, that 90% of my DMA2D executions throws DMA2D_FLAG_CE, but anyway DMA2D renders it.Code: dma2d_handle.Init.Mode = DMA2D_R2M; dma2d_handle.Init.ColorMode = DMA2D_ARGB8888; dma2d_handle.Init.OutputOffset = Offset; dma2d_handle.Instance = DMA2D; if(HAL_DMA2D_Init(&dma2d_handle) == HAL_OK) { if(HAL_DMA2D_ConfigLayer(&dma2d_handle, layer_index) == HAL_OK) { if (HAL_DMA2D_Start(&dma2d_handle, ColorIndex, (uint32_t)dst, xSize, ySize) == HAL_OK) { HAL_DMA2D_PollForTransfer(&dma2d_handle, 10); // returns HAL_ERROR and HAL_DMA2D_FLAG_CE } } }Any ideas?
Hello, I have my project based on STM32H753I-EVAL with RGB LCD display and SDRAM.I'm using DMA2D to render lines with CLUT L8 (Pulling mode). Basically, I process data for one line (one line have 320 pixels), and then execute it 108 times (for height). I'm rendering this 30 times per second. But for some reason, it sometimes render black (so it's blinking) (where data are correct), or it just freeze (since it's polling mode, it's frozen in checking if transfer was finished). After it timeout, it tries once again, until after few seconds it starts work again and then again freeze. I would expect that somewhere in code I have issue, but the exactly same code, used on STM32F429-DISC1, it works absolutely fine. So it looks like it's not my code problem, but my several concerns are:1) SDRAM - I tried to verify if SDRAM have correct clock and configuration according to EVAL example, everything looks good2) Broken DMA IP Core inside H7?3) Other clock problemI'm totally out of ideas, since it
Hi All, I am working on TouchGFX using STMCubeIDE( STM32G474 Eval-Board). There is a need to implement external flash driver for the project. I am using QSPI for implementing the flash driver. In linker file I have memory definitions as below : /* Memories definition */MEMORY{ RAM (xrw) : ORIGIN = 0x20000000, LENGTH = 128K FLASH (rx) : ORIGIN = 0x8000000, LENGTH = 512K QSPI_FLASH (r) : ORIGIN = 0x9000000, LENGTH = 16M}/* Sections */.ARM.attributes 0 : { *(.ARM.attributes) } ExtFlashSection : { *(ExtFlashSection ExtFlashSection.*) *(.gnu.linkonce.r.*) . = ALIGN(0x4); } >QSPI_FLASHNow, While programming the external flash using STMCube Programmer, its not able to program it. The STMCubeIDE generates .elf file which I trying to program and CubeProgrammer fails to program for QSPI_FLASH region. Error Image below :-Please check if anybody can help
Hi,I have allocated memory in external sdram and set buffer using CanvasWidgetRenderer::setupBuffer() method. Generated base class for my view is allocating memory in internal RAM and in constructor is passing it to setupBuffer mehod. How to avoid this behaviour? Can I tell somehow to Designer that memory is allocated already?Definition:static const uint16_t CANVAS_BUFFER_SIZE = 12000; uint8_t canvasBuffer[CANVAS_BUFFER_SIZE];First line of view base class constructor:CanvasWidgetRenderer::setupBuffer(canvasBuffer, CANVAS_BUFFER_SIZE);
Hello,I am looking to perform a similar resource usage as explained here https://support.touchgfx.com/docs/basic-concepts/memory-usage/However, I am wondering if there is a guide that is available using freely available tools to dothe memory analysis on the deployed code.My environment is TouchGFX-Designer-4.16.0 and I am able to generate & deploy code toan STM32F769I-DISCO board. I don't have dedicated IDEs installed yet.I found C:/TouchGFXProjects/MyProjectName/gcc/Makefileand I see the lines linker_options that eventually leads me toTouchGFX\build\bin\application.map - Is this the correct file?Its contents is not summarized as shown in the examples, so I am wondering if there are post processing steps that can be done to that file.Or is there a better option?Is the expectation to be able to just open the .cproject file in STM32CubeIDE and do a build?An updated guide on the analysis based on STM32CubeIDE or VisualStudioCode maybe more accessible for more people that are just
I'm new to ST products and am trying to run the LCD_DSI_VideoMode_SingleBuffer example on the Eversion VGG128017-C TFT screen. I get the backlight to turn on, but never see anything. Does anyone know of any specific drivers for the VGG128017 family? Thanks
I'm using a texture mapper to rotate an arrow inside a circle. That works perfectly well as long as the arrow is included as image asset and this image is directly set as image in the texture mapper.As soon as I remove the arrow from the assets and place it on the SD card to have it dynamically loaded as dynamic bitmap, the following happens:The dynamic bitmap is displayed without any problems by an Image widget.The dynamic bitmap is NOT displayed by the TextureMapper widget.This happens for RGB, ARGB as well as L8 images (it does not matter if alpha is included in the clut or not). Dynamic bitmaps do not seem to be supported by TextureMapper.Is this a bug?Is there a plan in which version the TouchGFX TextureMapper supports dynamic bitmaps?Kind regards,Klemens Pleiner
with libjpeg or using hardware in polling, mode compression works fine.but when using DMA image is getting corrupted#include "jpeg_encode.h" #include "jpeglib.h" #include "jdata_conf.h" // variables used for dma mode uint32_t YCBCR_Size; uint32_t YCBCR_Index; uint32_t YCBCR_Packets; uint32_t YCBCR_Packet_Size; uint8_t *YCBCR_IMG; uint8_t Encoded_Flag; uint8_t DMA_Mode; uint32_t JPEG_Size; uint32_t JPEG_Encode_SW(uint8_t *img, // pointer input rgb map uint32_t img_x, // image width uint32_t img_y, // image hight uint8_t img_bytpp, // bytes per pixel uint8_t quality, // out jpeg quality uint8_t *jpg_out, // where out jpeg is stored, must be sizes appropriately uint32_t jpg_out_sz) // size of output buffer { struct jpeg_compress_struct cinfo; struct jpeg_error_mgr jerr; JSAMPROW row_pointer[1]; uint32_t row_stride; cinfo.err = jpeg_std_error(&jerr); jpeg_create_compress(&cinfo); cinfo.image_width = img_x; cinfo.image_h
Hi @Martin KJELDSEN : I want to develop some algorithmic controls based on GFX that need to get images per pixel,or how to push the processed data directly to FarmBuffer without changing the image?B,Rjack
My HPP#ifndef PRINT_PROGRESS_SCREENVIEW_HPP #define PRINT_PROGRESS_SCREENVIEW_HPP #include <gui_generated/print_progress_screen_screen/PRINT_PROGRESS_ScreenViewBase.hpp> #include <gui/print_progress_screen_screen/PRINT_PROGRESS_ScreenPresenter.hpp> class PRINT_PROGRESS_ScreenView : public PRINT_PROGRESS_ScreenViewBase { public: PRINT_PROGRESS_ScreenView(); virtual ~PRINT_PROGRESS_ScreenView() {} virtual void setupScreen(); virtual void tearDownScreen(); void handleTickEvent(); virtual void handleClickEvent(const ClickEvent& evt); virtual void handleGestureEvent(const GestureEvent& evt); virtual void DRAW_function(); virtual void ScreenEntered_function(); protected: Callback<PRINT_PROGRESS_ScreenView, const BoxWithBorder&, const ClickEvent&> Box3DClickedCallback; Callback<PRINT_PROGRESS_ScreenView, const BoxWithBorder&, const GestureEvent&> Box3DGestureCallback; void Box3DClickHandl
I'm currently evaluating several boards, but I'm having trouble downloading the application templates. The quoted error will appear sporadically through the download process... anywhere between 0% and 30% downloaded. My internet connection is definitely fine, we have not reported any issues there with other apps / browsers.Any idea what's happening?
HelloI have an Idea that involves getting video from a PC to an MCU or equivalent. I'm thinking to use ADV7611 to do the deserialization and use its output with the DCMI interface on an STM32. For me it seems like this would be possible as many of the STM32s support the 54MHz pixelclock that the Analog chip outputs. will this solution work?
Hi all,I'm planning to interface a DCMI camera with an STM32H743 running at 400MHz SYSCLK. What is the greatest pixel clock rate I can reliably use? The reference manual says "The maximum DCMI_PIXCLK period must be higher than 2.5 HCLK periods". Since DCMI is on AHB2 and the max HPRE clock is 200MHz, am I correct that the maximum pixel clock is 80MHz?Cheers,Martijn
Good day!I try to work with 1.3 TFT LCD 320RGB x 320 with ST7796DW driver using STM32L4R9ZG DSI in a video mode. I try to initialize the display using HAL_DSI_ShortWrite and HAL_DSI_LongWrite functions. But after only 3 commands (doesn't matter HAL_DSI_ShortWrite or HAL_DSI_LongWrite, registers and number of parameters) the 4th command returns HAL_TIMEOUT. Any ides what is the problem?Thank You!
HiI'm using stm32f767 and want to use LTDC with double framebuffer.Can i do this with one sdram?LTDC is fetching data from sdram(front buffer) and i have to prepare the back buffer at the same time(load data from sdcard into sdram)Internal sram capacity is not sufficient.How can this happen?LTDC and SDRAM are working and i can display image through LTDC from SDRAMLTDC is running at 30MHz and SDRAM clock is 90MHz.
Suppose there are two views: "Screen1" and "Screen2". Depending on which screen is active, we want to do something (like enable or disable an interrupt). Within the Model, what is the proper way to determine which screen is active? Is there an API that returns a string or number, and can someone point me to a simple example of the syntax? Thanks
HAL_StatusTypeDef HAL_DSI_LongWrite(DSI_HandleTypeDef *hdsi, uint32_t ChannelID, uint32_t Mode, uint32_t NbParams, uint32_t Param1, uint8_t *ParametersTable) { uint32_t uicounter, nbBytes, count; uint32_t tickstart; uint32_t fifoword; uint8_t *pparams = ParametersTable; /* Process locked */ __HAL_LOCK(hdsi); /* Check the parameters */ assert_param(IS_DSI_LONG_WRITE_PACKET_TYPE(Mode)); /* Get tick */ tickstart = HAL_GetTick(); /* Wait for Command FIFO Empty */ while ((hdsi->Instance->GPSR & DSI_GPSR_CMDFE) == 0U) { /* Check for the Timeout */ if ((HAL_GetTick() - tickstart) > DSI_TIMEOUT_VALUE) { /* Process Unlocked */ __HAL_UNLOCK(hdsi); return HAL_TIMEOUT; } }My STM32F469 with DSI LCD works ok. But on start and init LCD when sending commands sometimes display dont init. I debug and found this return used.I need help . How deal with this?
It is Value A in model.cppAttempt to initialize Value A from the model.cpp function.However, before Value A initializes, setupsrceen() in B_Screenview is executed first, indicating an incorrect value.I want to know how to initialize Value A in model.cpp before setupscreen() in B_Screenview runs.#TouchGFX
There is an image button.In Normal state, the image is displayed, and when the button is pressed, the B image is displayed.I looked at the functions to use this function. setBitmaps (const Bitmap & bitmapReleased, const Bitmap & bitmapPressed) If you use this function to set the boolean bpressInfo to zero.bitmapReleased displays A image, bitmapRressed displays B image.And if bpressInfo is 1, bitmapReleased is B image and bitmapRressed is A image.If the function is possible, can you show me a simple example?
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.