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] [July 2015 Threads] Freertos Heap adjust in RX62NPosted by neona-embedded on July 28, 2015 We are trying to reduce the freertos heapsize in Renesas RX62N. Default heap size is 45K. We are using heap_2.c. When we reduce heap size to 2K, the code is getting stuck at vApplicationMallocFailedHook(). Can anyone help in solving this issue?
Freertos Heap adjust in RX62NPosted by davedoors on July 28, 2015 How much heap do you need? It seems more than 2K. Set the heap larger than you need, alocate all the objects you need, then call xPortGetFreeHeapSize() to see how much is left. You can then set configTOTALHEAPSIZE to exactly what is needed.
If you use heap2 (heap4 is normal now) and nothing calls malloc then make sure you dont also allocate a C heap as it wont be used. The size of the C heap is normally set in a linker script.
Freertos Heap adjust in RX62NPosted by neona-embedded on July 29, 2015 Thankyou for the reply. We are using heap2.c. We have read in some forums that we can set configTOTALHEAPSIZE 0 since heap2.c is not using heap memory. But if we set 0, vApplicationMallocFailedHook() is coming. Can we avoid this? We can give maximum 15K heap memory. We have 4 tasks. But then also this error was there.
Freertos Heap adjust in RX62NPosted by rtel on July 29, 2015 You cannot set that constant to 0 if you are using heep2, only if you are using heep3. You have the source code for the heap implementations so you can see why very quickly. Please also read the memory management pages on the FreeRTOS.org site.
Regards.
Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.
|