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] [March 2015 Threads] config assert at heap 5Posted by crippler1 on March 10, 2015 Hi
I have a problem,
my config assert pops at configASSERT( pxEnd ) in pvPortMalloc function, when I try to create task
it means that pxEnd is not initialized.
any suggestions?
config assert at heap 5Posted by andymcc0 on March 10, 2015 Does this provide a clue?
void *pvPortMalloc( size_t xWantedSize )
{
BlockLink_t *pxBlock, *pxPreviousBlock, *pxNewBlockLink;
void *pvReturn = NULL;
/* The heap must be initialised before the first call to
prvPortMalloc(). */
configASSERT( pxEnd );
i.e. have you called vPortDefineHeapRegions() ?
Do you need heap_5.c with its segmented, user defined heap?
config assert at heap 5Posted by crippler1 on March 10, 2015 at the heap5.c pxEnd = NULL at declaration as static.
I don't see any change at pxEnd to any non zero value, at the all file.
config assert at heap 5Posted by crippler1 on March 10, 2015 as for the heap5 question
I am new to free rtos and i wrote simple main func that creates a task and runs it.
config assert at heap 5Posted by rtel on March 10, 2015 Andy made some suggestions as to what the problem might be, but I don't think you have answered either of his questions.
Regards.
config assert at heap 5Posted by crippler1 on March 10, 2015 I see that vPortDefineHeapRegions() contains the same assert check,
but I don't see the code that change the pxEnd before the assert check.
config assert at heap 5Posted by rtel on March 10, 2015
I see that vPortDefineHeapRegions() contains the same assert check,
Actually, it doesn't. It checks pxEnd is NULL to ensure you don't call
the function twice.
but I don't see the code that change the pxEnd before the assert check.
It is done in vPortDefineHeapRegions().
Regards.
config assert at heap 5Posted by crippler1 on March 10, 2015
config assert at heap 5Posted by rtel on March 10, 2015 Didn't I tell you that in my very last post in this thread?
config assert at heap 5Posted by crippler1 on March 10, 2015 Sorry for the dumb question:
should I use heap for every program that I write?
I have watch some tutorials for free RTOS, and I never saw heap functions at main.
config assert at heap 5Posted by rtel on March 10, 2015 http://www.freertos.org/a00111.html
Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.
|