We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Dear all,
I'm using a LP2294 with 1 MB external RAM and Keil RealView. The RAM is configured at 0x81000000 in the options dialog. Now I want to use a dynamic memory allocation by using malloc. I want to allocate 85kB. But malloc returns 0 all the time. In the map file I can see, that the value for the memory allocation is at 0x81000254.
Does anybody knows what goes wrong?
Thanks for the help,
Christian
Dear Alex,
what a simple mistake. Now I set the heap and it works fine. Thanks a lot for the help. I there any recomondation for the heap value?
Regards,
Heap is the sum up all memory allocations like malloc, calloc and so on.
"There is no standard way to determine how much heap us used because:
1) The C standard does not require a heap 2) Different heap management schemes have different overheads 3) It depends on how good your implementation is at reusing freed memory"
But again if you analyze it simply it will be the sum up of all memory allocations like malloc, calloc and so on.