(resolved) stack overflow in task memory_task?

User avatar
mzimmers
Posts: 643
Joined: Wed Mar 07, 2018 11:54 pm
Location: USA

(resolved) stack overflow in task memory_task?

Postby mzimmers » Mon Jan 13, 2020 8:35 pm

Hi all -

This error crept up this morning. It occurs about 630 ticks into boot.

Code: Select all

***ERROR*** A stack overflow in task memory_task has been detected.
(WROVER, V4.0 IDF)

Any ideas on what to do? Thanks...
Last edited by mzimmers on Tue Jan 21, 2020 8:51 pm, edited 2 times in total.

User avatar
mzimmers
Posts: 643
Joined: Wed Mar 07, 2018 11:54 pm
Location: USA

Re: stack overflow in task memory_task?

Postby mzimmers » Mon Jan 13, 2020 11:31 pm

As additional information, sometimes upon boot, I get this message instead:

Code: Select all

E (30492) phy_init: failed to allocate memory for RF calibration data
The app manages a few calls to heap_caps_get_free_size before it crashes:

Code: Select all

I (7710) memreport: memReport(): there are 8728 MALLOC_CAP_8BIT bytes free.
I (7720) memreport: memReport(): there are 61520 MALLOC_CAP_32BIT bytes free.
I (7720) memreport: memReport(): there are 61520 MALLOC_CAP_INTERNAL bytes free.
I (7730) memreport: memReport(): there are 0 MALLOC_CAP_SPIRAM bytes free.
I (7740) memreport: memReport(): there are 8728 MALLOC_CAP_DMA bytes free.
I'd *greatly* appreciate any assistance on this...thanks.

User avatar
mzimmers
Posts: 643
Joined: Wed Mar 07, 2018 11:54 pm
Location: USA

Re: stack overflow in task memory_task?

Postby mzimmers » Wed Jan 15, 2020 2:39 pm

Bump.

Any ideas on how I can chase this down? Thank you.

vonnieda
Posts: 145
Joined: Tue Nov 07, 2017 3:42 pm

Re: stack overflow in task memory_task?

Postby vonnieda » Wed Jan 15, 2020 7:17 pm

Is memory_task a task you created? If so, just increase the task stack size. Most likely you are using printf and the formatting is taking more stack memory than it originally did.

Jason

User avatar
mzimmers
Posts: 643
Joined: Wed Mar 07, 2018 11:54 pm
Location: USA

Re: stack overflow in task memory_task?

Postby mzimmers » Wed Jan 15, 2020 8:44 pm

Hi Jason -

Yes, it's a task I create. It's not an essential task, so I can get rid of it, but then other memory-related issues pop up. Currently, my wifi task throws this error:

Code: Select all

E (32104) phy_init: failed to allocate memory for RF calibration data
abort() was called at PC 0x4018fe46 on core 0
I'm guessing this is heap, not stack, which is why I was running the memcheck in the first place. But...something very squirrelly is happening with my memory management.

User avatar
mzimmers
Posts: 643
Joined: Wed Mar 07, 2018 11:54 pm
Location: USA

Re: stack overflow in task memory_task?

Postby mzimmers » Tue Jan 21, 2020 8:50 pm

Marking as resolved. I'm simply running out of memory.

Who is online

Users browsing this forum: Baidu [Spider], MicroController and 130 guests