cancel
Showing results for 
Search instead for 
Did you mean: 

TouchGFX would stuck with SPI LCD and NO RTOS

ali_dehbidi
Senior

Hi,

I have made this very simple project, when I step into code and just change the vsync_sem in debuge to 1 to force a render, The code would just call this function

  HAL::getInstance()->backPorchExited();

and never would retrun, it would stuck in there, How should I resolve this issue?0693W000003PA9PQAW.png

I expect the this force a call of this function

void TouchGFXHAL::flushFrameBuffer(const touchgfx::Rect& rect)

6 REPLIES 6
Alexandre RENOUX
Principal

Hello,

Can you give more information about what you are trying to do as well as your hardware setup and the GUI you want to display ?

/Alexandre

ali_dehbidi
Senior

A simple test, I just hand edited this function, to false

lockDMAToFrontPorch(false);

Now it would render! am I missing something?

Alexandre RENOUX
Principal

Hello,

Can you display some GUI on your screen ?

If by just adding lockDMAToFrontPorch(false); you can render but still not see anything on the display, it seems to me that the transfer of the rendered frame from RAM to Screen is not working properly.

lockDMAToFrontPorch() when set to true, means that the DMA will not fill the framebuffer before the whole frame is sent to the display. This prevents corruption of the framebuffer when the DMA is quicker than the sending of the frame. Of course this reduce performance but it usually prevents from seeing artifacts. If it was stuck when lockDMAToFrontPorch(true), this can mean that the framework was waiting for the previous frame to be sent before rendering again with DMA2D.

/Alexandre

ali_dehbidi
Senior

Thanks for the feedback, I can see GUI on screen, But shouldn't I change this code manualy!?

What is "this code" ?

If you are talking about lockDMAToFrontPorch(), yes you can add this line manually in the TouchGFXHAL.cpp. This file is meant for the developer to edit it however he wants.

/Alexandre

ali_dehbidi
Senior

changing the lockDMAToFrontPorch()  to false;

thanks for the help