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.

CC2640R2F: Debugging in IAR Workbench gives CPU status unknown

Part Number: CC2640R2F

Hello,

I am able to dump code into CC2640R2F and run successfully but when try to debug CC2640R2F using XDS110 in IAR work bench but everytime I get an error saying " XDS reported an error unknown CPU status".

I'm not sure why this warning pops up. what could be the reason and how can I debug?

Thanks

Regards

-Noor

  • Noor,

    It would seem that your connection with the device is ending unexpectedly.

    Can you try running an out-of-the box example with your setup? Are you using custom hardware or one of our launchpads?

    I will assign someone to follow up.

    -Luis

  • Hi Luis,

    Thank you for the response.

    I tried an out of the box example with my setup and  mine is custom hardware, that example runs fine and it is not giving "unknown cpu status".

    The source code is provided by another company. Can you help me debug on this.

    Thanks

    -Noor

  • Hi Noor,

    If you haven't already, can you go through the thread that I've linked below with a similar issue and see if any of the solutions provided there help with your issue? If they do not provide any benefit, I can redirect you to someone who will be able to assist you with your custom hardware.

    e2e.ti.com/.../612934

    Best Regards,
    Alec

  • Hi,

    This is the code snippet where the XDS warning pops up. The exact line is highlighted

    AONWUCShutDownEnable(void)
    {
    // Ensure the JTAG domain is turned off;
    // otherwise MCU domain can't be turned off.
    HWREG(AON_WUC_BASE + AON_WUC_O_JTAGCFG) = 0; 

    // Enable shutdown of the device.
    HWREGBITW(AON_WUC_BASE + AON_WUC_O_CTL0, AON_WUC_CTL0_PWR_DWN_DIS_BITN) = 0;
    HWREG(AON_WUC_BASE + AON_WUC_O_SHUTDOWN) =AON_WUC_SHUTDOWN_EN;

    Can we debug when shutdown is present in code?. Because it is the point where the XDS warning mentioned above is popping up.

    Thank You

    Regards

    -Noor

     

  • Noor, 

    I think that should be fine. I am going to discuss with someone on the team that supports custom hardware to see if they can provide some input. Along with the thread I linked in my previous post, please also reference this section of the SDK documentation that discusses SW changes that need to perform in order to run the SDK on custom hardware. Some of it is unique to the BLE stack, but I believe most of it is still relevant.

    https://dev.ti.com/tirex/explore/content/simplelink_cc2640r2_sdk_4_30_00_08/docs/blestack/ble_user_guide/html/ble-stack-3.x-guide/ble-stack-3-index.html#running-the-sdk-on-custom-hardware

    Let me know if either of these documents help you make some headway.

    Best Regards,
    Alec

  • Hi Alec, 

    Thanks for the response. I am going through the threads which you have shared.

    I wanted to rephrase my question as it was not particularly clear in previous post.

    We have a custom hardware setup. while debugging it gives XDS warning  at the point mentioned in previous reply. My query is When JTAG is connected and MCU enters in AONWUCShutDownEnable(void) then MCU should not be turned off. but why is the debugger (XDS110) losing connection with MCU if it can't be turned off.

    Thanks for the help I really appreciate it.

    Regards

    -Noor

  • Hi Noor,

    My sincerest apologies for the delay. I spoke with our team who is more familiar with custom hardware, and they recommended you look at sections 5.6 and 5.7 of the TRM, which I will link below for your convenience. 
    https://www.ti.com/lit/ug/swcu117i/swcu117i.pdf


    Best Regards,
    Alec