# Core Firmware SOS Panic Codes

**URL:** <https://community.particle.io/t/core-firmware-sos-panic-codes/4337>\
**Category:** Troubleshooting\
**Created:** [May 13, 2014, 2:49pm UTC](https://community.particle.io/t/core-firmware-sos-panic-codes/4337 "2014-05-13T14:49:51Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![joky](https://avatars.discourse-cdn.com/v4/letter/j/d26b3c/32.png) [@joky](https://community.particle.io/u/joky)\
**Post date:** [October 21, 2016, 12:45pm UTC](https://community.particle.io/t/core-firmware-sos-panic-codes/4337/5 "2016-10-21T12:45:58Z")

</div>

Hi,

I do some external logging for my electron devices. In 0.6.0-rc2 you can use System.resetReason() and System.resetReasonData() for panic codes. While I found the values for resetReasons quite easy in the git-repository, I didn’t find the resetReasonCodes.

If you’re looking for the translation of the resetCodes and Panic-Codes - here they are:

**System.resetReason():**

```
RESET_REASON_NONE = 0,
RESET_REASON_UNKNOWN = 10, // Unspecified reason
// Hardware
RESET_REASON_PIN_RESET = 20, // Reset from the NRST pin
RESET_REASON_POWER_MANAGEMENT = 30, // Low-power management reset
RESET_REASON_POWER_DOWN = 40, // Power-down reset
RESET_REASON_POWER_BROWNOUT = 50, // Brownout reset
RESET_REASON_WATCHDOG = 60, // Watchdog reset
// Software
RESET_REASON_UPDATE = 70, // Successful firmware update
RESET_REASON_UPDATE_ERROR = 80, // Generic update error
RESET_REASON_UPDATE_TIMEOUT = 90, // Update timeout
RESET_REASON_FACTORY_RESET = 100, // Factory reset requested
RESET_REASON_SAFE_MODE = 110, // Safe mode requested
RESET_REASON_DFU_MODE = 120, // DFU mode requested
RESET_REASON_PANIC = 130, // System panic (additional data may contain panic code)
RESET_REASON_USER = 140 // User-requested reset

```

**System.resetReasonData:**

```
HardFault: 1
MemManage: 3
BusFault: 4
UsageFault: 5
OutOfHeap: 8
AssertionFailure: 10
StackOverflow: 13
```

---

_[View the full topic](https://community.particle.io/t/core-firmware-sos-panic-codes/4337)._
