Skip to content

Fault handler doc update #793

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

Merged
merged 3 commits into from
Oct 26, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 14 additions & 12 deletions docs/tutorials/debug/debug_fault_exception.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ Please look at the **Technical Reference Manual** and **Arm Architecture Referen

For example, Cortex-M0/M0+ processors (or any ARMv6M processors) do not have MemManage, BusFault and UsageFault exceptions implemented. In those cases, all exceptions are reported as HardFault exception. For ARMv7M processors, MemManage, BusFault and UsageFault exceptions trigger only if they are enabled in System Handler Control and State Register (**SHCSR**).

Below is an example of the crash dump (with a description of registers) that the Mbed OS fault exception handler generates.
Below is an example of the crash dump (with a description of registers) that the Mbed OS fault exception handler generates. Note that the system also invokes the Mbed OS error handler when an exception happens and prints out the error information, as well.

Please see the [Error API reference](/docs/development/apis/error-handling.html) for more about error information.

```
++ MbedOS Fault Handler ++
Expand Down Expand Up @@ -54,18 +56,18 @@ Mode : Thread - Processor mode at the time of exception
Priv : Privileged - Privilege level at the time of exception
Stack: PSP - Stack pointer in use at the time of exception

Thread Info:
Current:
State: 00000002 EntryFn: 00002595 Stack Size: 00001000 Mem: 20001EA0 SP: 20002E60
Next:
State: 00000002 EntryFn: 00002595 Stack Size: 00001000 Mem: 20001EA0 SP: 20002E60
Wait Threads:
State: 00000083 EntryFn: 00004205 Stack Size: 00000300 Mem: 20000E18 SP: 200010B0
Delay Threads:
Idle Thread:
State: 00000001 EntryFn: 00002715 Stack Size: 00000200 Mem: 20001118 SP: 200012D8

-- MbedOS Fault Handler --


++ MbedOS Error Info ++
Error Status: 0x80FF013D Code: 317 Module: 255
Error Message: Fault exception
Location: 0x5B25
Error Value: 0x5946
Current Thread: Id: 0x20001E80 Entry: 0x5D05 StackSize: 0x1000 StackMem: 0x20000E80 SP: 0x2002FF90
For more info, visit: https://armmbed.github.io/mbedos-error/?error=0x80FF013D
-- MbedOS Error Info --

```

### Analyzing crash dump
Expand Down