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.

RTOS/CC1310: check HWI/Error cause

Part Number: CC1310


Tool/software: TI-RTOS

Hi,

In some conditions (ex. memory allocation errors) CM3 throws error and goes Error handler and also in some conditions (ex. radio core crashes) CM3 throws HWI and goes hwi handler (in default while(1)).

I set handler functions for error and hwi and tested them. They work well. But in these functions, i want to learn cause of error or hard fault(such as radio, uart fault).

How can i obtain this information in runtime? Are there some spesific registers from which i can collect some information?

Edit: One more question -> How can i learn all the sources which cause hard fault and errors? (any document)

Best regards.

  • Hi,

    If you have setup you own (or using existing) hooks for the Error handler and the Hwi exception handler you should have access to the information you need in the arguments.

    For example, the Hwi exception hook function takes a "Hwi_ExcContext" pointer as its argument, this is basically a pointer to a struct listing the core registers and some thread information (handle and stack pointers. You can find information about this in the SYS/BIOS API documentation:

    dev.ti.com/.../Hwi.html

    You can also find information about the Error module inside this documentation:

    dev.ti.com/.../Error.html

    You still have to perform you own debugging in terms of what module is causing the problem (you should be able to deduce this from the core registers and thread information) or you could connect to the device with a debugger and use the CCS ROV. If you are debugging with the ROV, it can often help you unwind the call stack and point you to the problem.