backPorchExited() hangs and never returns in tick() function ?
Hello,
I have STM32F4 discovery and trying to integrate TouchGFX with SPI TFT LCD. I implemented the necessary hooks specifically flushFrameBuffer() function.
However, my issue is that backPorchExited() never returns and hangs my touchgfx thread, eg:
for (;;)
{
OSWrappers::waitForVSync();
backPorchExited();
}backPorchExited() actually calls tick() function which belongs to libtouchgfx-float-abi-hard.a. I cannot step into library as no source is available and I do not know what it is doing.
My question is what could possibly hangs in tick() function. I found a hint that is it hangs after calling sampleTouch() function.
My second question is what function call is used to force touchgfx to render the full frame buffer. The reason I ask is when I force flushFrameBuffer in HAL initialize function, there is no valid data in framebuffer, it is supposed to be an image as generated in touchgfx designer. Someone here suggested this should work ?! What could be missing ?
void TouchGFXGeneratedHAL::initialize()
{
HAL::initialize();
registerEventListener(*(touchgfx::Application::getInstance()));
setFrameBufferStartAddresses((void*)frameBuf, (void*)0, (void*)0);
/*
* Set whether the DMA transfers are locked to the TFT update cycle. If
* locked, DMA transfer will not begin until the TFT controller has finished
* updating the display. If not locked, DMA transfers will begin as soon as
* possible. Default is true (DMA is locked with TFT).
*/
lockDMAToFrontPorch(false);
touchgfx::Rect r(0,0,240,320);
flushFrameBuffer(r);
}Best regards,
BD.