FreeRTOS Support Archive
The FreeRTOS support forum is used to obtain active support directly from Real
Time Engineers Ltd. In return for using our top quality software and services for
free, we request you play fair and do your bit to help others too! Sign up
to receive notifications of new support topics then help where you can.
This is a read only archive of threads posted to the FreeRTOS support forum.
The archive is updated every week, so will not always contain the very latest posts.
Use these archive pages to search previous posts. Use the Live FreeRTOS Forum
link to reply to a post, or start a new support thread.
[FreeRTOS Home] [Live FreeRTOS Forum] [FAQ] [Archive Top] [May 2014 Threads]
Hi, i'm new for rtos when i try to run my application with FreeRTOS i got a problem that i cant fix:
i try to run all my application without emwin gui the program works fine but when i add emwin task the program works few loops then goes into hardwarefault.
i comment all other task only run emwin task it works fine but when i add delay in emwin task like following code the program goes into hardwarefault too.
updated: i tired to hardware restart my board with above situations it looks about 20% chance that program will works and 80% with hardware fault. but if only run emwin gui without time delay the program is always work. i start to check if my board problem.
void taskinterfacedoUpdate(void *pvParameters){
for(;;){
dointerfacedoUpdate();
vTaskDelay( 10 / portTICKRATEMS );
}
}
my mcu is stm32f407zg i read many information about use freertos on stm32 and some program worked without emwin gui. i opened stack overflow & malloc fail hook looks not that problem
i increased stack size into 20k heap size into 25k rtos heap size into 30k but still not work
i tried to trace how the fault happen it look when i try to refresh screen the fault happened but the refresh API is packed in emwin so i cant trace it deeper
i create emwin task with following code same with other tasks
xTaskCreate( taskinterfacedoUpdate, "interfacedoUpdate",configMINIMALSTACKSIZE*8,NULL, interfaceTaskPRIO, &interfaceHandle );
which stack size is 4k prio is 7 it should be fine
i tried use heap_1/2/4 file to manage memory, all failed
any can give me any idea how to fix it? thanks
i create task of emwin with following code:
I know that this is not related to your question but the uGFX project (Free and open embedded GUI) is currently heavily searching for volunteers to test our brand new FreeRTOS port.
Probably you're interested? http://ugfx.org
~ Tectu
Sorry - I have never used emWin so don't know what to look for. The only advice I can provide is the normal STM32 stuff - make sure you are using a recent version of FreeRTOS to take advantage of the additional configASSERT() statements that were inserted to catch the most common misconfiguration issues - V7.6.0 or higher (and of course make sure configASSERT() is actually defined to something that will make you notice when it is called).
Regards.
Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.