This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

how to decode debug dump under TI-RTOS



I am using TM4C1294NCPDT ( EK-TM4C1294XL launchpad board ) with TI-RTOS and the firmware in DEBUG version are displaying this dump in the system console ( UART0 ):


{module#43}: line 1036: E_hardFault: FORCED {module#43}: line 1113: E_busFault: PRECISERR: Immediate Bus Fault, exact addr known, address: 6820219e Exception occurred in background thread at PC = 0x0001a7cc. Core 0: Exception occurred in ThreadType_Task. Task name: {unknown-instance-name}, handle: 0x20018af0. Task stack base: 0x20011120. Task stack size: 0x600. R0 = 0x000086dd R8 = 0x00000000 R1 = 0x20008d84 R9 = 0x00000000 R2 = 0x6820216e R10 = 0x00000000 R3 = 0x2146bf14 R11 = 0x20018828 R4 = 0x20018750 R12 = 0x00000000 R5 = 0x20006678 SP(R13) = 0x20011628 R6 = 0x200185ac LR(R14) = 0x00014f87 R7 = 0x00000002 PC(R15) = 0x0001a7cc PSR = 0x21000000 ICSR = 0x00423803 MMFSR = 0x00 BFSR = 0x82 UFSR = 0x0000 HFSR = 0x40000000 DFSR = 0x00000000 MMAR = 0x6820219e BFAR = 0x6820219e AFSR = 0x00000000 Terminating execution...

My question is: which document I need to study to learn how to decode this dump.

I mean, how to identify which "{module#43}" is it?

How to know which task is: "Task name: {unknown-instance-name}, handle: 0x20018af0."

Any feedback is welcome.

Thanks,

Sergio



  • Hi Sergio,

    The exception dump that you see on the console is a dump of the general purpose registers (r0-r14), program counter and various fault status registers that encode the type of the exception and in some cases the address of the instruction causing the exception.

    The SYS/BIOS (TI-RTOS kernel) exception handler decodes some of the fault status registers for you and prints the type of exception. In your case, the exception handler determined the cause was an Immediate bus fault accessing address 0x6820219e and the instruction that caused the exception was at 0x0001a7cc (PC).

    The PC, LR and SP register values in the exception dump can be used to get the callstack at the time the exception occurred and should be very helpful in debugging the problem. Checkout the below wiki page for more info on how to do this:

    http://processors.wiki.ti.com/index.php/SYS/BIOS_FAQs#4_Exception_Dump_Decoding_Using_the_CCS_Register_View

    Coming to the question about the module and task instance names, the module and instance names are not shown in the exception dump because some of the strings are not being loaded to the target. This is usually recommended to save space. You probably have the below code somewhere in your application's *.cfg file. Please change it as suggested below:

    var Text = xdc.useModule('xdc.runtime.Text');
    
    /* 
     * Uncomment this line to keep Error, Assert, and Log strings from being
     * loaded on the target.  These strings are placed in the .const section.
     * Setting this parameter to false will save space in the .const section.
     * Error, Assert and Log message will print raw ids and args instead of
     * a formatted message.
     */
    Text.isLoaded = false; <-------------- Comment this out or change to true

    Hope this helps.

    Best,

    Ashish

  • Hi Ashish Kapania

    Thank you very much.

    Your explanations are very clear and helpful.

    One more question: is there any kind of manual covering OFF-LINE debug issues? I mean, without using CCS connected to the board? Before release version, we used to test with debug version in field, without CCS support. So, debugging is limited.

    Thanks

    Sergio
  • Hi Sergio,

    I am not aware of any manual for offline or hostless debugging. In a hostless scenario where CCS is unavailable, you can always enable logging and get the logs via UART. Even the exception dumps can be captured through UART like you probably are already doing. The logs can be quite helpful in debugging issues. Please check the SYS/BIOS user guide for more info on how to enable and setup logging.

    Best,
    Ashish