I'm currently investigation the effects of memory fragmentation on the heap.
As far as I see, there is no documentation about pvPortMalloc() and the structures how the free list is managed.
Is there any way to get these details?
Sorry for the misunderstanding..
About memory management we recommended you to use esp_iot_rtos_sdk which using freeRTOS https://github.com/espressif/esp_iot_rtos_sdk, source code of memory management is \esp_iot_rtos_sdk-master\third_party\freertos\heap_4.c
Thanks for your interest in ESP8266 !
So I'm curios whether there are changes to that manager or not.
I ask because my app does dynamic memory allocation to parse incoming data, It receives quite a bit of packets. Randomly I'll get a Fatal Exception which occurs in the pvPortRealloc method. I don't have any code that uses realloc.
My printf traces are:
Avaliable - Attepting To Send: 61 bytes - Fatal exception (28):
ets Jan 8 2013,rst cause:2, boot mode:(3,6)
Its attempting to send 61 bytes via espconn_send(); then I get the fatal exception:
epc1 is in the pvPortRealloc Method.
epc3 is in the vPortExitCritical Method.
In previous cases, I've fixed fatal exceptions by reusing memory using memset to clear it, instead of free and malloc'ing a new pointer.
Who is online
Users browsing this forum: No registered users and 7 guests
Newbies Start Here
Are you new to ESP8266?
Unsure what to do?
Dunno where to start?
Start right here!
We also have a RTOS version and a MESH version too!
Complete listing of the official ESP8266 related documentation release by ESPRESSIF!
Must read here!