Skip to content

More debug info (maybe core dump) on panic #7490

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
tannewt opened this issue Jan 26, 2023 · 7 comments
Open

More debug info (maybe core dump) on panic #7490

tannewt opened this issue Jan 26, 2023 · 7 comments
Labels
enhancement espressif applies to multiple Espressif chips
Milestone

Comments

@tannewt
Copy link
Member

tannewt commented Jan 26, 2023

We see hard faults after a while on ESP and they are difficult to debug. The IDF can produce core dumps. Perhaps we should set those up so we have more debug info after the fact.

It may require changing the partition table. We can do this along with IDF 5.0 because it may require partition changes too. We may be able to shrink the TinyUF2 partition too.

@tannewt tannewt added enhancement espressif applies to multiple Espressif chips labels Jan 26, 2023
@tannewt tannewt added this to the 9.0.0 milestone Jan 26, 2023
@bill88t
Copy link

bill88t commented Jan 27, 2023

I'd like to argue openocd & gdb with breakpoints & line by line execution cover most use cases of coredumps.

@dhalbert
Copy link
Collaborator

I'd like to argue openocd & gdb with breakpoints & line by line execution cover most use cases of coredumps.

Our aim here is to allow any user to send us a core dump after a hard crash, without having to do any set up. For our own purposes, yes, interactive debugging is great.

@d-c-d
Copy link

d-c-d commented Jan 27, 2023

Are there any ideas that can be gleaned from Memfault's collection and debug tools for core dumps?

@dhalbert
Copy link
Collaborator

dhalbert commented Jan 27, 2023

This is a specific feature of ESP-IDF. The "core dump" is not a full RAM dump, but an assortment of stuff that includes stack backtraces, registers, task info, etc. It's really more of a "state" dump. It would be generated when the panic handler runs. It is 64kB (or less) of stuff.

@d-c-d
Copy link

d-c-d commented Jan 28, 2023

Thanks - there are a lot of other ideas that Memfault uses to assist developers in collecting data besides full device coredumps; such as backtraces, debug registers, logs, and custom metrics. ( I have nothing to gain, but have learned from their interrupt blog ).

See their Design Documents
Looks like ESP-IDF Core Dump images have similar features - perhaps circuitpython and adafruit community could add some of the cloud collection and sharing features that Memfault provides to their IOT platform.

@tannewt
Copy link
Member Author

tannewt commented Apr 14, 2023

Here is an issue this would be nice for: #7405

@tannewt
Copy link
Member Author

tannewt commented Apr 14, 2023

Also helpful for #7230

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement espressif applies to multiple Espressif chips
Projects
None yet
Development

No branches or pull requests

4 participants