16.5.12 STATUS and ERROR Codes

During the boot process or while interacting with a host debugger, the device may emit a 32-bit code indicating either a STATUS or an ERROR condition. These codes are primarily intended to assist the host debugger in interpreting the device's state, especially during interactive mode.

Note: Park Mode is a specialized recovery mechanism and may be supported by the debugger tool. Refer to the debugger’s user guide for instructions on entering Park Mode and performing recovery operations.

STATUS Codes

STATUS codes reflect the current state or progress of the boot process. Some of these codes are internal and used by the debugger to support IMODE commands. However, one key STATUS code is relevant to user application is shown below:

STATUS Code NameDefinitionCode
STATUS_BOOTOKIndicates that the entire boot sequence has completed successfully. The Device Access Level (DAL) is set to the final value as determined by the ROMCFG fuse.0x00000004

Once the boot process completes successfully, the device writes the STATUS_BOOTOK code to the DSU_REGS->DSU_BCC[1] register. Optionally, this register can be read by the first mutable application executable code to confirm that the device has booted correctly.

Note: If the boot operation fails, the device will not transfer control to the first mutable executable (FME) application code. In such cases, the STATUS_BOOTOK code will not be written, and the device may remain in interactive mode.

ERROR Codes

During the boot process, the device may encounter error conditions that prevent it from completing initialization. In such cases, the Boot ROM issues a 32-bit error code, which is written to the DSU_REGS->DSU_BCC[1] register.

The DSU_BCC[1] register retains the last value written by the device, allowing the user or host debugger to inspect the cause of the boot failure.

The presence of an error code indicates that the boot operation was interrupted and did not proceed to the first mutable application executable code.

Note: The list of error codes provided below is not exhaustive. Only those error codes are specified which users might experience during the product life cycle. The probable causes listed for each error are indicative and may vary depending on system conditions.

STATUS_ERR_HARDFAULT

CODE 0xEEEE0001

When the device encounters a HardFault during the boot operation, the Boot ROM issues the STATUS_ERR_HARDFAULT error code. This condition indicates a critical failure that prevents the device from completing the boot sequence.

Probable Causes:

While the exact cause may vary, one common scenario includes:

  • Unrecoverable Memory Read Error
  • Device malfunction due to unknown reason(s)

Device Behavior:

In response to this fault condition:

  • The device enters a wait state for approximately 350 milliseconds
  • After the wait period, the Boot ROM initiates a self-reset to attempt recovery
  • This cycle of issue error code → wait → reset → retry continues indefinitely until the fault condition is resolved

This behavior ensures that transient faults, such as power instability or temporary memory corruption glitch do not permanently stall the device. However, persistent faults will result in repeated resets, which may be observable during system monitoring.

STATUS_ERR_USERCFG

CODE 0xEEEE0004

This error indicates a failure in the boot configuration due to issues with the BOOTCFG1 and/or BOOTCFG1A fuses, or with the Firmware Metadata (FWMD) sequence numbers.

Probable Causes

  • Invalid or corrupted boot configuration fuses
  • The USERCFG1 or USERCFG1A fuses may contain memory faults or invalid values

Device Behavior

  • Upon detecting this condition, the Boot ROM halts the boot process and issues the STATUS_ERR_USERCFG error code.
  • The user may attempt to recover the device by:
    • Reprogramming the FWMD sequence numbers correctly
    • Ensuring valid values are written to USERCFG1 and USERCFG1A fuses
  • If the error persists despite corrective actions, it indicates that the device is no longer usable due to permanent configuration faults

STATUS_ERR_ROMCFG

CODE 0xEEEE0019

The device has detected unrecoverable faults in the ROMCFG fuse, which is critical for determining boot behavior and security configuration

Probable Causes

  • Double Memory Fault in ROMCFG fuse

Device Behavior

  • Upon encountering this fault, the Boot ROM issues the STATUS_ERR_ROMCFG error code and halts the boot process
  • The user may attempt to recover the device by reprogramming the ROMCFG fuse with valid values
  • If the error persists after reprogramming, it indicates a permanent fault in the ROMCFG fuse, rendering the device no longer usable

STATUS_MBIST_FAILED

CODE 0xEEEE0021

This error occurs when the MBIST on boot feature is enabled through the FRCFGMBIST fuse in ROMCFG and the device fails the MBIST (Memory Built-In Self-Test) during the boot process.

Probable Causes:

  • MBIST failure on device SRAM. The device detected a fault in one or more SRAM regions during the MBIST execution.

Device Behavior:

  • If MBIST fails, the device halts the boot process indefinitely and does not proceed to execute user application code.
  • The user may attempt to recover the device by performing a Power-on Reset (POR) and observing whether the device resumes normal boot operation.
  • This error condition is considered critical and may indicate a permanent fault in the memory subsystem.
Note: This error code STATUS_MBIST_FAILED is a special case which might require intervention from Microchip. If the issue persists, the user is advised to contact Microchip support for further diagnosis and resolution.