2019-12-15 06:01 AM
Hi,
I am using STM32F778AI with FMC SDRAM and MIPI-DSI for screen.
Before adding touchgfx SDRAM, DSI , Systick worked. After adding touchgfx it stopped working and stuck on HAL_Delay because Systick don't enter to interrupt.
Any help ?
David
2019-12-15 11:37 AM
how did you add the touchGFX? the graphics task take up a lot of space in the RTOS so setting the stack size for the task is vital. usually the 'defaultTask' have 4096 words of stacksize. Remember also to set the total heap size for the RTOS itself (should be more than your combined stacksizes times 4 because it's defined in words).
Could be something completely different but there's not much to go on :)
2019-12-16 12:45 AM
2019-12-16 01:10 AM
I'm not completely sure that the default configuration for TouchGFX changes the stacksize to the right size.
in your main.cpp, how much stack is allocated for the 'defaultTask' ?
in your RTOSConfig.h, how big is your total heap size?
2019-12-16 02:03 AM
I changed it to 2000 work stack size and 8112 bytes heap size.
Just to understand , why do you think it is freertos related ? Because SysTick don't fire before FreeRTOS launched
2019-12-17 02:22 AM
After more debugging I understand that all interrupts are not working after GRAPHICS_HW_Init();
It stuck in GRAPHICS_HW_Init(); becuase CubeMX generate HAL_Delay(1) inside.
But If I changed delay to loop delay it stuck on Hard Fault inside prvPortStartFirstTask .
I tried to make Stack and Heap larger ( exactly like in STM32F746Disco example ) - Stack size is 4096 word and Heap size is : 32768 bytes and I have still the same problem...
Any ideas ?
Thanks,
David