HardFaults when using TouchGFX TextArea::setTypedText()
Hello everyone,
I am experiencing a HardFault on an STM32F746G-DISCO board while working with TouchGFX. The issue seems to be related to code automatically generated by the TouchGFX Generator in STM32CubeMX.
The fault occurs when my application tries to set text on a TextArea widget. The debugger stops inside the HardFault_Handler, and the call stack clearly indicates the issue originates from the setTypedText() function chain.
Here is the relevant part of the call stack from the debugger:
HardFault_Handler()
touchgfx::TextArea::getTextWidth()
touchgfx::TextArea::resizeToCurrentText()
touchgfx::TextArea::setTypedText()
... (my application code, which was generated by the generator)
It seems that a call to setTypedText(), which is part of the generated code, is leading to the HardFault. I suspect this might be caused by an uninitialized TextArea object or a configuration issue within the generator, but I'm having trouble pinpointing the exact cause.
Has anyone encountered a similar issue with code generated by the TouchGFX Generator? Any guidance on what to investigate would be greatly appreciated.
Thank you.
